Main Page | Class Hierarchy | Alphabetical List | Class List | File List | Class Members | File Members

CUIScreen.h

00001 /**********************************************************************
00002 
00003 Copyright (c) 2005, TomTom B.V.
00004 
00005 All rights reserved
00006 
00007 
00008 ***********************************************************************/
00009 
00010 
00011 #ifndef __CUISCREEN_H__
00012 #define __CUISCREEN_H__
00013 
00014 #include "CUIWidgetGroup.h"
00015 #include "MImage.h"
00016 #include "MUISkin.h"
00017 
00030 class CUIScreen: public CUIWidgetGroup 
00031 {
00032  public:
00034            CUIScreen( MColorScheme::EDefaultColorScheme aColorScheme );
00035   virtual ~CUIScreen();
00036   
00037   virtual void Draw();
00038   virtual void RestoreBackground( CUIRect& aRect );
00039   
00050   virtual void SetBackground( CDesktop::TColor aColor, MImage* aImage );
00051 
00053   virtual void SetColorSchemeType( MColorScheme::EDefaultColorScheme aType );
00054   
00059   virtual int  DoModal();  
00060 
00066   virtual void EndModal(); 
00067 
00068  public:
00069 
00071   enum EEditOptions
00072   {   
00073    KDisableNumeric   = 0x0001,  
00074    KOnlyUpperCase    = 0x0002,  
00075    KOnlyLowerCase    = 0x0004,  
00076    KOnlyNumeric      = 0x0008,  
00077    KDisableLocale    = 0x0010,  
00078    KDisableSpaces    = 0x0020,  
00079    KAutoLetterCase   = 0x0040,  
00080    KTransparentDraw  = 0x0080,  
00081    //KAutoSelect       = 0x0100,    /**< */
00082    KTransparentTitle = 0x0200,  
00083    KDefaultOptions   = KAutoLetterCase | KTransparentDraw | KTransparentTitle
00084   };
00085 
00086   enum { KMaxEditLen = 20 }; 
00098   static bool EditString( char* aString, unsigned int aMaxLen, EEditOptions aOptions );
00099 
00101   enum EMessageBoxOption
00102   {
00103    KBlueLabyrinth   = 0x01, 
00104    KGreenLabyrinth  = 0x02, 
00105    KRedLabyrinth    = 0x04, 
00107    KYesButton       = 0x08, 
00108    KNoButton        = 0x10, 
00109    KOKButton        = 0x20, 
00110    KCancelButton    = 0x40, 
00111    KContinueButton  = 0x80, 
00116    KNoModal         = 0x0100, 
00126   };
00127 
00128   typedef int EMessageBoxOptions; 
00150   static int MessageBox( 
00151               const char*                       aTitle, 
00152               const char*                       aText, 
00153               EMessageBoxOptions                aOptions     = KOKButton | KBlueLabyrinth, 
00154               MColorScheme::EDefaultColorScheme aColorScheme = MColorScheme::KSchemeInfo, 
00155               CDesktop::TColor                  aTitleColor  = 0,
00156               MImage*                           aBackground  = NULL );
00157 
00158  private:
00159   CUIScreen();
00160   CUIScreen( const CUIScreen& );
00161   CUIScreen& operator=( const CUIScreen& );
00162 
00163  public:
00164         CDesktop::TColor                  iBackgroundColor; 
00165   const MImage*                           iBackgroundImage; 
00166         int                               iModalResult;     
00167         MColorScheme::EDefaultColorScheme iColorScheme;     
00169  protected:
00170 
00172   MImage* GetImage() const 
00173     { 
00174      return 
00175       ( NULL != iBackgroundImage ) ?
00176        const_cast< MImage* >( iBackgroundImage ):
00177        MUISkin::GetCurrentSkin()->GetImage( MUISkin::KDesktopBackground );
00178   }
00179 };
00180 
00181 #endif // __CUISCREEN_H__
00182 

Generated on Fri Jul 15 16:46:44 2005 for TomTom GO User Interface library by doxygen 1.3.5