emailuis/uicomponents/src/fscontrolbuttonvisualiser.cpp
branchRCL_3
changeset 8 e1b6206813b4
parent 1 12c456ceeff2
child 12 f5907b1a1053
equal deleted inserted replaced
4:e7aa27f58ae1 8:e1b6206813b4
  1241     // If there is no text in the button, center the icon to the button
  1241     // If there is no text in the button, center the icon to the button
  1242     if( !iLabelFirstLine || iLabelFirstLine->Text().Length() == 0 )
  1242     if( !iLabelFirstLine || iLabelFirstLine->Text().Length() == 0 )
  1243         {
  1243         {
  1244         TSize oldIconSize = iconA.Size();
  1244         TSize oldIconSize = iconA.Size();
  1245         iconA.SetRect( TPoint( 
  1245         iconA.SetRect( TPoint( 
  1246                 iconA.iTl .iX + ( buttonSize.iWidth - oldIconSize.iWidth ) / 2, 
  1246                             ( buttonSize.iWidth - oldIconSize.iWidth ) / 2, 
  1247                 iconA.iTl .iY + ( buttonSize.iHeight - oldIconSize.iHeight ) / 2 ),
  1247                             ( buttonSize.iHeight - oldIconSize.iHeight ) / 2 ),
  1248                 oldIconSize );
  1248                             oldIconSize );
  1249         }
  1249         }
  1250     iconA.SetHeight( buttonSize.iHeight );
  1250     iconA.SetHeight( buttonSize.iHeight );
  1251     text1.SetHeight( buttonSize.iHeight );
  1251     text1.SetHeight( buttonSize.iHeight );
  1252     
  1252     
  1253     if ( iButtonModel->ContainsElement( ECBElemIconA ) )
  1253     if ( iButtonModel->ContainsElement( ECBElemIconA ) )