|
1 /* |
|
2 * Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). All rights reserved. |
|
3 * |
|
4 * This library is free software; you can redistribute it and/or |
|
5 * modify it under the terms of the GNU Lesser General Public |
|
6 * License as published by the Free Software Foundation; either |
|
7 * version 2 of the License, or (at your option) any later version. |
|
8 * |
|
9 * This library is distributed in the hope that it will be useful, |
|
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
|
12 * Lesser General Public License for more details. |
|
13 * |
|
14 * You should have received a copy of the GNU Lesser General Public |
|
15 * License along with this library; if not, write to the |
|
16 * Free Software Foundation, Inc., 59 Temple Place - Suite 330, |
|
17 * Boston, MA 02111-1307, USA. |
|
18 * |
|
19 * Description: |
|
20 * |
|
21 */ |
|
22 /* |
|
23 * ============================================================================== |
|
24 * Name : gstplayerappview.h |
|
25 * Part of : gstplayer |
|
26 * Interface : |
|
27 * Description : |
|
28 * Version : |
|
29 * |
|
30 |
|
31 * ============================================================================== |
|
32 */ |
|
33 |
|
34 #ifndef __GSTPLAYERAPPVIEW_H__ |
|
35 #define __GSTPLAYERAPPVIEW_H__ |
|
36 |
|
37 // INCLUDES |
|
38 #include <coecntrl.h> |
|
39 #include "RichTextEditor.h" |
|
40 |
|
41 // CLASS DECLARATION |
|
42 class CGSTPlayerAppView : public CCoeControl |
|
43 { |
|
44 public: // New methods |
|
45 |
|
46 /** |
|
47 * NewL. |
|
48 * Two-phased constructor. |
|
49 * Create a CGSTPlayerAppView object, which will draw itself to aRect. |
|
50 * @param aRect The rectangle this view will be drawn to. |
|
51 * @return a pointer to the created instance of CGSTPlayerAppView. |
|
52 */ |
|
53 static CGSTPlayerAppView* NewL( const TRect& aRect ); |
|
54 |
|
55 /** |
|
56 * NewLC. |
|
57 * Two-phased constructor. |
|
58 * Create a CGSTPlayerAppView object, which will draw itself |
|
59 * to aRect. |
|
60 * @param aRect Rectangle this view will be drawn to. |
|
61 * @return A pointer to the created instance of CGSTPlayerAppView. |
|
62 */ |
|
63 static CGSTPlayerAppView* NewLC( const TRect& aRect ); |
|
64 |
|
65 /** |
|
66 * ~CGSTPlayerAppView |
|
67 * Virtual Destructor. |
|
68 */ |
|
69 virtual ~CGSTPlayerAppView(); |
|
70 |
|
71 public: // Functions from base classes |
|
72 |
|
73 /** |
|
74 * From CCoeControl, Draw |
|
75 * Draw this CGSTPlayerAppView to the screen. |
|
76 * @param aRect the rectangle of this view that needs updating |
|
77 */ |
|
78 void Draw( const TRect& aRect ) const; |
|
79 |
|
80 /** |
|
81 * From CoeControl, SizeChanged. |
|
82 * Called by framework when the view size is changed. |
|
83 */ |
|
84 virtual void SizeChanged(); |
|
85 |
|
86 void DrawText(const TDesC& aText, const TRgb aRgb = KRgbBlack); |
|
87 |
|
88 private: // Constructors |
|
89 |
|
90 /** |
|
91 * ConstructL |
|
92 * 2nd phase constructor. |
|
93 * Perform the second phase construction of a |
|
94 * CGSTPlayerAppView object. |
|
95 * @param aRect The rectangle this view will be drawn to. |
|
96 */ |
|
97 void ConstructL(const TRect& aRect); |
|
98 |
|
99 |
|
100 /** |
|
101 * CGSTPlayerAppView. |
|
102 * C++ default constructor. |
|
103 */ |
|
104 CGSTPlayerAppView(); |
|
105 |
|
106 /** |
|
107 * From CoeControl,CountComponentControls. |
|
108 */ |
|
109 TInt CountComponentControls() const; |
|
110 |
|
111 /** |
|
112 * From CCoeControl,ComponentControl. |
|
113 */ |
|
114 CCoeControl* ComponentControl(TInt aIndex) const; |
|
115 |
|
116 CRichTextEditorRTE* iRte; |
|
117 |
|
118 }; |
|
119 |
|
120 #endif // __GSTPLAYERAPPVIEW_H__ |
|
121 |
|
122 // End of File |
|
123 |