uifw/AvKon/src/aknmessagequerycontrol.cpp
branchRCL_3
changeset 9 0aa5fbdfbc30
parent 0 2f259fa3e83a
child 18 fcdfafb36fe7
equal deleted inserted replaced
8:71dd06cfe933 9:0aa5fbdfbc30
   133     
   133     
   134     HBufC* msgBuf = aMessage->AllocLC();
   134     HBufC* msgBuf = aMessage->AllocLC();
   135     TPtr message( msgBuf->Des() );
   135     TPtr message( msgBuf->Des() );
   136     if( iListQLayout )
   136     if( iListQLayout )
   137         {
   137         {
   138         TruncateTextForListQLayout( message );
   138         TruncateTextForListQLayoutL( message );
   139         iEdwin->SetTextL( &message );
   139         iEdwin->SetTextL( &message );
   140         LayoutEditorL(); 
   140         LayoutEditorL(); 
   141         }
   141         }
   142 
   142 
   143     if ( message.Locate('\n') != KErrNotFound )
   143     if ( message.Locate('\n') != KErrNotFound )
   796             CEikScrollBar::EVertical) == grabbingComponent;
   796             CEikScrollBar::EVertical) == grabbingComponent;
   797         }
   797         }
   798     return grabbing;
   798     return grabbing;
   799     }
   799     }
   800 
   800 
   801 void CAknMessageQueryControl::TruncateTextForListQLayout( TDes& aMessage )
   801 void CAknMessageQueryControl::TruncateTextForListQLayoutL( TDes& aMessage )
   802     {
   802     {
   803     if( !iListQLayout )
   803     if( !iListQLayout )
   804         return;
   804         return;
   805 
   805 
   806     delete iFullMessage;
   806     delete iFullMessage;
   827         iLinesPerPage = 3;  // Should be AknLayoutScalable_Apps::loc_type_pane_t1_ParamLimits().LastRow();
   827         iLinesPerPage = 3;  // Should be AknLayoutScalable_Apps::loc_type_pane_t1_ParamLimits().LastRow();
   828         HBufC* msgBuf = iFullMessage->AllocLC() ;
   828         HBufC* msgBuf = iFullMessage->AllocLC() ;
   829         TPtr message( msgBuf->Des() );
   829         TPtr message( msgBuf->Des() );
   830         iEdwin->SetTextL( &message );
   830         iEdwin->SetTextL( &message );
   831         LayoutEditorL(); 
   831         LayoutEditorL(); 
   832         TruncateTextForListQLayout( message );
   832         TruncateTextForListQLayoutL( message );
   833         iEdwin->SetTextL( &message );
   833         iEdwin->SetTextL( &message );
   834         CleanupStack::PopAndDestroy( msgBuf );  // After all usages of message        
   834         CleanupStack::PopAndDestroy( msgBuf );  // After all usages of message        
   835         iNumberOfLines = iEdwin->TextLayout()->NumFormattedLines();
   835         iNumberOfLines = iEdwin->TextLayout()->NumFormattedLines();
   836         }
   836         }
   837     else
   837     else