textinput/peninputarc/src/peninputlayoutcontrol/peninputlayoutbubblectrl.cpp
branchRCL_3
changeset 56 8152b1f1763a
parent 50 5a1685599b76
equal deleted inserted replaced
50:5a1685599b76 56:8152b1f1763a
    64     SetHidenFlag(ETrue);
    64     SetHidenFlag(ETrue);
    65     }
    65     }
    66         
    66         
    67 EXPORT_C CBubbleCtrl::~CBubbleCtrl()
    67 EXPORT_C CBubbleCtrl::~CBubbleCtrl()
    68     {
    68     {
    69 	Close();
       
    70 	
       
    71     if ( iText )
    69     if ( iText )
    72         delete iText;
    70         delete iText;
    73     
    71     
    74     if( iForgroundBmp )
    72     if( iForgroundBmp )
    75 		{
    73 		{
   100 		iForgroundBmpMask = NULL;
    98 		iForgroundBmpMask = NULL;
   101 		}    
    99 		}    
   102 		
   100 		
   103     iForgroundBmp = aBmpId;
   101     iForgroundBmp = aBmpId;
   104     iForgroundBmpMask = aMaskBmpId;
   102     iForgroundBmpMask = aMaskBmpId;
   105     iBgSkinId = aBgSkinId;
   103     iBgSkinId = aBgSkinId;    
   106     
       
   107     iNeedRedraw = ETrue;
       
   108     }
   104     }
   109 
   105 
   110 EXPORT_C void CBubbleCtrl::Popup(const TRect& aRect)
   106 EXPORT_C void CBubbleCtrl::Popup(const TRect& aRect)
   111     {
   107     {
   112     //SetRect(aRect);
   108     //SetRect(aRect);
   230 		// notify sever to draw the bubble bitmap on the screen
   226 		// notify sever to draw the bubble bitmap on the screen
   231         if(UiLayout()->NotDrawToLayoutDevice())
   227         if(UiLayout()->NotDrawToLayoutDevice())
   232             {
   228             {
   233             struct SData
   229             struct SData
   234                 {
   230                 {
   235             	TUint32 ctrl;
       
   236                 TBool flag;
   231                 TBool flag;
   237                 TRect pos;
   232                 TRect pos;
   238                 CFbsBitmap* bmp;
   233                 CFbsBitmap* bmp;
   239                 CFbsBitmap* mask;
   234                 CFbsBitmap* mask;
   240                 } data;
   235                 } data;
   241                 
   236                 
   242             data.ctrl = (TUint32)this;
       
   243             data.flag = ETrue;
   237             data.flag = ETrue;
   244             data.pos = Rect();
   238             data.pos = Rect();
   245             data.bmp = iBitmap;
   239             data.bmp = iBitmap;
   246             data.mask = iMaskBitmap;
   240             data.mask = iMaskBitmap;
   247             TPtrC ptr;
   241             TPtrC ptr;
   276 		
   270 		
   277     iForgroundBmp = aBmpId;
   271     iForgroundBmp = aBmpId;
   278     iForgroundBmpMask = aMaskBmpId;
   272     iForgroundBmpMask = aMaskBmpId;
   279     iFirstBmpId = aFirstBmpId;
   273     iFirstBmpId = aFirstBmpId;
   280     iMiddleBmpId =  aMiddleBmpId;
   274     iMiddleBmpId =  aMiddleBmpId;
   281     iLastBmpId = aLastBmpId;
   275     iLastBmpId = aLastBmpId;    
   282     
       
   283     iNeedRedraw = ETrue;    
       
   284     }
   276     }
   285 
   277 
   286 EXPORT_C void CBubbleCtrl::Close()
   278 EXPORT_C void CBubbleCtrl::Close()
   287     {
   279     {
   288     TRect rect = Rect();
   280     TRect rect = Rect();
   319         {
   311         {
   320         if(UiLayout()->NotDrawToLayoutDevice())
   312         if(UiLayout()->NotDrawToLayoutDevice())
   321             {
   313             {
   322             struct SData
   314             struct SData
   323                 {
   315                 {
   324             	TUint32 ctrl;
       
   325                 TBool flag;
   316                 TBool flag;
   326                 TRect pos;
   317                 TRect pos;
   327                 CFbsBitmap* bmp;
   318                 CFbsBitmap* bmp;
   328                 } data;
   319                 } data;
   329                 
   320                 
   330             data.ctrl = (TUint32)this;
       
   331             data.flag = EFalse;
   321             data.flag = EFalse;
   332             data.pos = Rect();
   322             data.pos = Rect();
   333             data.bmp = iBitmap;
   323             data.bmp = iBitmap;
   334             
   324             
   335             TPtrC ptr;
   325             TPtrC ptr;