Nokia N97 SDK
Example Applications Guide

COpenCHelloGlibEventExView Class Reference

Inheritance diagram for COpenCHelloGlibEventExView:

List of all members.

Detailed Description

Definition at line 23 of file openchelloglibeventexview.h.


Public Member Functions

virtual  ~COpenCHelloGlibEventExView ()
void  Draw (const TRect &aRect) const
virtual void  SizeChanged ()
void  SetText (TDesC &aText)

Static Public Member Functions

static COpenCHelloGlibEventExView *  NewL (const TRect &aRect)
static COpenCHelloGlibEventExView *  NewLC (const TRect &aRect)

Private Member Functions

void  ConstructL (const TRect &aRect)
  COpenCHelloGlibEventExView ()

Private Attributes

TBuf< 30 >  iText


Constructor & Destructor Documentation

COpenCHelloGlibEventExView::~COpenCHelloGlibEventExView (   )  [virtual]
 

~COpenCHelloGlibEventExView Virtual Destructor.

Definition at line 80 of file openchelloglibeventexview.cpp.

00081     {
00082     // No implementation required
00083     }

COpenCHelloGlibEventExView::COpenCHelloGlibEventExView (   )  [private]
 

COpenCHelloGlibEventExView. C++ default constructor.

Definition at line 69 of file openchelloglibeventexview.cpp.

00070     {
00071     // No implementation required
00072     }


Member Function Documentation

COpenCHelloGlibEventExView * COpenCHelloGlibEventExView::NewL (  const TRect &  aRect  )  [static]
 

NewL. Two-phased constructor. Create a COpenCHelloGlibEventExView object, which will draw itself to aRect.

Parameters:
aRect  The rectangle this view will be drawn to.
Returns:
a pointer to the created instance of COpenCHelloGlibEventExView.

Definition at line 27 of file openchelloglibeventexview.cpp.

References NewLC().

Referenced by COpenCHelloGlibEventExUi::ConstructL().

00028     {
00029     COpenCHelloGlibEventExView* self = COpenCHelloGlibEventExView::NewLC( aRect );
00030     CleanupStack::Pop( self );
00031     return self;
00032     }

COpenCHelloGlibEventExView * COpenCHelloGlibEventExView::NewLC (  const TRect &  aRect  )  [static]
 

NewLC. Two-phased constructor. Create a COpenCHelloGlibEventExView object, which will draw itself to aRect.

Parameters:
aRect  Rectangle this view will be drawn to.
Returns:
A pointer to the created instance of COpenCHelloGlibEventExView.

Definition at line 39 of file openchelloglibeventexview.cpp.

References ConstructL().

Referenced by NewL().

00040     {
00041     COpenCHelloGlibEventExView* self = new ( ELeave ) COpenCHelloGlibEventExView;
00042     CleanupStack::PushL( self );
00043     self->ConstructL( aRect );
00044     return self;
00045     }

void COpenCHelloGlibEventExView::Draw (  const TRect &  aRect  )  const
 

From CCoeControl, Draw Draw this COpenCHelloGlibEventExView to the screen.

Parameters:
aRect  the rectangle of this view that needs updating

Definition at line 91 of file openchelloglibeventexview.cpp.

References iText.

00092     {
00093     // Get the standard graphics context
00094     CWindowGc& gc = SystemGc();
00095 
00096     // Gets the control's extent
00097     TRect drawRect( Rect());
00098 
00099     // Clears the screen
00100     gc.Clear( drawRect );
00101     
00102     gc.UseFont(CEikonEnv::Static()->NormalFont());
00103     gc.DrawText(iText, TPoint(2, drawRect.Height()/2 + CEikonEnv::Static()->NormalFont()->HeightInPixels()/2));
00104     gc.DiscardFont();
00105     
00106         }

void COpenCHelloGlibEventExView::SizeChanged (   )  [virtual]
 

From CoeControl, SizeChanged. Called by framework when the view size is changed.

Definition at line 113 of file openchelloglibeventexview.cpp.

00114     {  
00115     DrawNow();
00116     }

void COpenCHelloGlibEventExView::ConstructL (  const TRect &  aRect  )  [private]
 

ConstructL 2nd phase constructor. Perform the second phase construction of a COpenCHelloGlibEventExView object.

Parameters:
aRect  The rectangle this view will be drawn to.

Definition at line 52 of file openchelloglibeventexview.cpp.

Referenced by NewLC().

00053     {
00054     // Create a window for this application view
00055     CreateWindowL();
00056 
00057     // Set the windows size
00058     SetRect( aRect );
00059 
00060     // Activate the window, which makes it ready to be drawn
00061     ActivateL();
00062     }


Member Data Documentation

TBuf<30> COpenCHelloGlibEventExView::iText [private]
 

Text message to be displayed by the view

Definition at line 89 of file openchelloglibeventexview.h.

Referenced by Draw(), and SetText().


The documentation for this class was generated from the following files:

© Nokia 2009

Back to top