textinput/peninputarc/inc/peninputlayoutcontrolinc/peninputlayoutbubblectrl.h
branchRCL_3
changeset 12 5e18d8c489d6
parent 5 a47de9135b21
child 20 ebd48d2de13c
equal deleted inserted replaced
11:c8fb4cf7b3ae 12:5e18d8c489d6
    91     void Freeze();
    91     void Freeze();
    92     
    92     
    93     void UnFreeze( TBool aUpdate = ETrue );
    93     void UnFreeze( TBool aUpdate = ETrue );
    94     inline void SetTextColorIndex( TInt aTxtClrIndex );
    94     inline void SetTextColorIndex( TInt aTxtClrIndex );
    95     inline TInt TextColorIndex() const;
    95     inline TInt TextColorIndex() const;
       
    96 
       
    97     inline void SetLangCode( TInt aLangCode );
       
    98 
    96 protected:
    99 protected:
    97     IMPORT_C CBubbleCtrl(const TRect& aRect,
   100     IMPORT_C CBubbleCtrl(const TRect& aRect,
    98                 CFepUiLayout* aUiLayout,
   101                 CFepUiLayout* aUiLayout,
    99                 TInt aCtrlId);
   102                 TInt aCtrlId);
   100                     
   103                     
   101     IMPORT_C void ConstructL(TInt aBmpId, TInt aMaskId);
   104     IMPORT_C void ConstructL(TInt aBmpId, TInt aMaskId);
   102        
   105        
   103 private:
   106 private:
       
   107     TRect GetRect();
       
   108        
       
   109 private:
   104     CFbsBitmap* iForgroundBmp;
   110     CFbsBitmap* iForgroundBmp;
   105     CFbsBitmap* iForgroundBmpMask;
   111     CFbsBitmap* iForgroundBmpMask;
   106     
   112     
   107     TAknsItemID iBgSkinId;
   113     TAknsItemID iBgSkinId;
   108     TAknsItemID iFirstBmpId;
   114     TAknsItemID iFirstBmpId;
   125     
   131     
   126     TBool iNeedRedraw; // redraw flag after text changed.
   132     TBool iNeedRedraw; // redraw flag after text changed.
   127     TInt iTextColorIndex;    
   133     TInt iTextColorIndex;    
   128     TSize iIconOffset;
   134     TSize iIconOffset;
   129     TSize iIconSize;
   135     TSize iIconSize;
       
   136 	
       
   137 public:
       
   138     IMPORT_C virtual void SetRect(const TRect& aRect);
       
   139     void SetBmpDevice(CFbsBitGc* aGc,CFbsBitmapDevice* aDevice);
       
   140     void CreateBmpDevL();
       
   141     inline void SetOffset(TPoint& aPt);
       
   142 protected:    
       
   143     IMPORT_C void HandleResourceChange(TInt aType);
       
   144 private:
       
   145     
       
   146         
       
   147 private:
       
   148     CFbsBitmap* iBitmap;
       
   149     CFbsBitmap* iMaskBitmap;
       
   150     
       
   151     TPoint iOffset;
       
   152     TInt iReserved1;
       
   153     
       
   154     TInt iLangCode;
   130     };
   155     };
   131     
   156 
       
   157 inline void CBubbleCtrl::SetOffset(TPoint& aPt)
       
   158     {
       
   159     iOffset = aPt;
       
   160     }
       
   161 
   132 inline void CBubbleCtrl::SetTextColorIndex( TInt aTxtClrIndex )
   162 inline void CBubbleCtrl::SetTextColorIndex( TInt aTxtClrIndex )
   133 	{
   163 	{
   134 	iTextColorIndex = aTxtClrIndex;	
   164 	iTextColorIndex = aTxtClrIndex;	
   135 	}
   165 	}
   136 	
   166 	
   148 inline void CBubbleCtrl::GetText( TDes& aText )
   178 inline void CBubbleCtrl::GetText( TDes& aText )
   149     {
   179     {
   150     aText.Copy( *iText );
   180     aText.Copy( *iText );
   151     }
   181     }
   152 
   182 
       
   183 inline void CBubbleCtrl::SetLangCode( TInt aLangCode )
       
   184     {
       
   185     iLangCode = aLangCode;
       
   186     }
       
   187 
   153 class CTooltipBubbleCtrl: public CBubbleCtrl
   188 class CTooltipBubbleCtrl: public CBubbleCtrl
   154     {
   189     {
   155 public: 
   190 public: 
   156     //constructor and destructor
   191     //constructor and destructor
   157     /**
   192     /**