emailuis/emailui/src/FreestyleEmailUiLayoutHandler.cpp
branchRCL_3
changeset 11 0396474f30f5
parent 1 12c456ceeff2
child 12 4ce476e64c59
equal deleted inserted replaced
10:f5907b1a1053 11:0396474f30f5
    24 #include <alf/alfstatic.h>
    24 #include <alf/alfstatic.h>
    25 
    25 
    26 #include <aknlayoutscalable_apps.cdl.h>
    26 #include <aknlayoutscalable_apps.cdl.h>
    27 #include <aknlayoutscalable_avkon.cdl.h>
    27 #include <aknlayoutscalable_avkon.cdl.h>
    28 #include <layoutmetadata.cdl.h>
    28 #include <layoutmetadata.cdl.h>
       
    29 #include <fslayoutmanager.h>
    29 
    30 
    30 // For generic treelist layout data setting
    31 // For generic treelist layout data setting
    31 #include "fstreelist.h"
    32 #include "fstreelist.h"
    32 
    33 
    33 // INTERNAL INCLUDE FILES
    34 // INTERNAL INCLUDE FILES
   470     buttonRect.Move( cbr.iTl ); // relative to control bar
   471     buttonRect.Move( cbr.iTl ); // relative to control bar
   471     
   472     
   472     if( landscape )
   473     if( landscape )
   473         {
   474         {
   474         TSize menuSize = rect.Size();
   475         TSize menuSize = rect.Size();
   475 
   476         if ( !CFsLayoutManager::IsMirrored() )
   476         // position left from the button
   477            {
   477         rect.SetRect( TPoint( buttonRect.iTl.iX - menuSize.iWidth, 
   478         	// position left from the button
       
   479             rect.SetRect( TPoint( buttonRect.iTl.iX - menuSize.iWidth, 
   478                 buttonRect.Center().iY - menuSize.iHeight / 2 ), menuSize );
   480                 buttonRect.Center().iY - menuSize.iHeight / 2 ), menuSize );
       
   481            }
       
   482         else
       
   483            {
       
   484            // position right from the button
       
   485            rect.SetRect( TPoint( buttonRect.Width(), 
       
   486                        buttonRect.Center().iY - menuSize.iHeight / 2 ), menuSize );
       
   487            }
   479         }
   488         }
   480     else
   489     else
   481         {
   490         {
   482         // position below the button
   491         // position below the button
   483         rect.Move( 0, buttonRect.iBr.iY - rect.iTl.iY );
   492         rect.Move( 0, buttonRect.iBr.iY - rect.iTl.iY );
  1939     
  1948     
  1940     TAknLayoutRect listRect;
  1949     TAknLayoutRect listRect;
  1941     listRect.LayoutRect( mainPaneRect, 
  1950     listRect.LayoutRect( mainPaneRect, 
  1942                         AknLayoutScalable_Apps::main_sp_fs_listscroll_pane_te_cp01( var ));
  1951                         AknLayoutScalable_Apps::main_sp_fs_listscroll_pane_te_cp01( var ));
  1943     TRect rect = listRect.Rect();
  1952     TRect rect = listRect.Rect();
  1944 
  1953   
  1945     // if control bar is required, reserve space on top of the listbox  
  1954     // if control bar is required, reserve space on top of the listbox  
  1946     if( aControlsOnTop && landscape )
  1955     if( aControlsOnTop && landscape )
  1947         {
  1956         {
  1948         TAknLayoutRect listRect2;
  1957         TAknLayoutRect listRect2;
  1949         listRect2.LayoutRect( mainPaneRect, 
  1958         listRect2.LayoutRect( mainPaneRect,