javauis/lcdui_akn/lcdui/src/CMIDCustomItem.cpp
branchRCL_3
changeset 77 7cee158cb8cd
parent 66 2455ef1f5bbc
child 83 26b2b12093af
--- a/javauis/lcdui_akn/lcdui/src/CMIDCustomItem.cpp	Tue Sep 14 21:06:50 2010 +0300
+++ b/javauis/lcdui_akn/lcdui/src/CMIDCustomItem.cpp	Wed Sep 15 12:05:25 2010 +0300
@@ -76,21 +76,21 @@
 }
 
 CMIDCustomItem::CMIDCustomItem(MMIDEnv& aEnv, CMIDUIManager* aUIManager)
-        : CMIDControlItem(EDefault, aUIManager)
-        , iEntered(EFalse)
-        , iSupportsInternalTraversal(ETrue)
-        , iEnv(aEnv)
-        , iResetFrameBuffer(ETrue)
-        , iDirectAreaAddedToDisplayable(EFalse)
-        , iS60SelectionKeyCompatibility(EFalse)
+    : CMIDControlItem(EDefault, aUIManager)
+    , iEntered(EFalse)
+    , iSupportsInternalTraversal(ETrue)
+    , iEnv(aEnv)
+    , iResetFrameBuffer(ETrue)
+    , iDirectAreaAddedToDisplayable(EFalse)
+    , iS60SelectionKeyCompatibility(EFalse)
 #ifndef RD_JAVA_NGA_ENABLED
-        , iDirectPaused(ETrue)
+    , iDirectPaused(ETrue)
 #endif
-        , iRestoreDirectContentWhenUnfaded(EFalse)
-        , iPreviousVisibility(EFalse)
-        , iConsumerWaitingForDSAResourcesCallback(NULL)
-        , iUiFixed(EFalse)
-        , iUiToBeFixedLater(EFalse)
+    , iRestoreDirectContentWhenUnfaded(EFalse)
+    , iPreviousVisibility(EFalse)
+    , iConsumerWaitingForDSAResourcesCallback(NULL)
+    , iUiFixed(EFalse)
+    , iUiToBeFixedLater(EFalse)
 {
     iMMidItem = this;
 
@@ -259,7 +259,7 @@
     {
         iDirectContent->MdcContainerDestroyed();
     }
-    
+
     if (iUiFixed && iForm)
     {
         iForm->CurrentDisplayable().ReleaseOrientation();
@@ -467,7 +467,8 @@
     iRequestedPreferredSize = CheckRequestedSize(aSize);
 
     if (iRequestedPreferredSize.iWidth == -1)
-    { // Width is not locked
+    {
+        // Width is not locked
         iPreferredSize.iWidth = Min(FormClientAreaWidth(),
                                     PreferredContentSize().iWidth + iContentMargins.iLeft + iContentMargins.iRight);
     }
@@ -484,7 +485,8 @@
 
 
     if (iRequestedPreferredSize.iHeight == -1)
-    { // Height is not locked
+    {
+        // Height is not locked
         iPreferredSize.iHeight = PreferredContentSize().iHeight + iContentMargins.iTop
                                  + iContentMargins.iBottom + LabelHeight();
     }
@@ -513,7 +515,8 @@
     DEBUG_INT("+ CMIDCustomItem::AdjustToSizeL - requested height = %d", requestedHeight);
 
     if (requestedHeight > availableHeight)
-    {// label + control do not fit
+    {
+        // label + control do not fit
         if (iLabelControl && iLabelControl->Text()->Length() > 0)
         {
             //reserve one line to the control
@@ -1347,7 +1350,7 @@
     {
         ChangeDirectContainerVisibility(ETrue);
     }
-    
+
     if (iUiToBeFixedLater && iForm)
     {
         iForm->CurrentDisplayable().FixOrientation();
@@ -1560,7 +1563,7 @@
 // From class MDirectContainer.
 // CMIDCustomItem::MdcFixUIOrientation(TBool aEnableFix)
 // ---------------------------------------------------------------------------
-// 
+//
 
 void CMIDCustomItem::MdcFixUIOrientation(TBool aEnableFix)
 {
@@ -1571,42 +1574,42 @@
     else
     {
         iEnv.ToLcduiObserver().InvokeLcduiEvent(*this, EUnFixUIOrientation);
-    }     
+    }
 }
 
 void CMIDCustomItem::HandleLcduiEvent(int aType)
 {
-   switch (aType)
-   {
-       case EFixUIOrientation:
-           if (!iUiFixed)
-           {
-               if (iForm)
-               {
-                   iForm->CurrentDisplayable().FixOrientation();
-                   iUiFixed = ETrue;
-                   iUiToBeFixedLater = EFalse;
-               }
-               else
-               {
-                   iUiToBeFixedLater = ETrue;
-               }
-           }
-           break;
-       case EUnFixUIOrientation:
-           if (iForm && iUiFixed)
-           {
-               iForm->CurrentDisplayable().ReleaseOrientation();
-               iUiFixed = EFalse;
-               iUiToBeFixedLater = EFalse;
-           }
-           break;    
+    switch (aType)
+    {
+    case EFixUIOrientation:
+        if (!iUiFixed)
+        {
+            if (iForm)
+            {
+                iForm->CurrentDisplayable().FixOrientation();
+                iUiFixed = ETrue;
+                iUiToBeFixedLater = EFalse;
+            }
+            else
+            {
+                iUiToBeFixedLater = ETrue;
+            }
+        }
+        break;
+    case EUnFixUIOrientation:
+        if (iForm && iUiFixed)
+        {
+            iForm->CurrentDisplayable().ReleaseOrientation();
+            iUiFixed = EFalse;
+            iUiToBeFixedLater = EFalse;
+        }
+        break;
     }
 }
 //
 // ---------------------------------------------------------------------------
 //
-void CMIDCustomItem::MdcAddContentBounds(const TRect& /*aRect*/)
+void CMIDCustomItem::MdcAddMMAPIContentBounds(const TRect& /*aRect*/)
 {
     iDirectAreaAddedToDisplayable = UpdateDirectContentBounds();
 }
@@ -1615,7 +1618,7 @@
 //
 // ---------------------------------------------------------------------------
 //
-void CMIDCustomItem::MdcRemoveContentBounds(const TRect& /*aRect*/)
+void CMIDCustomItem::MdcRemoveMMAPIContentBounds(const TRect& /*aRect*/)
 {
     if (iForm && iDirectAreaAddedToDisplayable)
     {