18 |
18 |
19 |
19 |
20 #ifndef CXNEFFECTMANAGER_H |
20 #ifndef CXNEFFECTMANAGER_H |
21 #define CXNEFFECTMANAGER_H |
21 #define CXNEFFECTMANAGER_H |
22 |
22 |
23 // INCLUDES |
23 // System incldues |
24 #include <e32base.h> |
24 #include <e32base.h> |
25 |
25 |
26 // CLASS DECLARATION |
26 // User includes |
|
27 |
|
28 // Forward declarations |
27 class CXnPluginData; |
29 class CXnPluginData; |
28 class CXnViewData; |
30 class CXnViewData; |
29 class CXnNode; |
31 class CXnNode; |
30 |
32 |
|
33 // Constants |
|
34 |
|
35 // Control effect context ids |
|
36 #define KGfxContextAddWidget TUid::Uid( 0x102750F4 ) |
|
37 #define KGfxContextRemoveWidget TUid::Uid( 0x102750F4 ) |
|
38 #define KGfxContextActivateNextView TUid::Uid( 0x102750F1 ) |
|
39 #define KGfxContextActivatePrevView TUid::Uid( 0x102750F2 ) |
|
40 #define KGfxContextBgAppear TUid::Uid( 0x102750F3 ) |
|
41 |
|
42 // Control effect action ids |
|
43 #define KGfxControlActionAppear 3 |
|
44 #define KGfxControlActionDisappear 4 |
|
45 |
|
46 // Full screen effect ids |
|
47 #define KGfxContextOpenWallpaperView 1007 |
|
48 #define KGfxContextCloseWallpaperView 1008 |
|
49 |
|
50 // Class declaration |
31 /** |
51 /** |
32 * Struct which holds needed info of effect. |
52 * Struct which holds needed info of effect. |
33 */ |
53 */ |
34 NONSHARABLE_STRUCT( TXnEffect ) |
54 NONSHARABLE_STRUCT( TXnEffect ) |
35 { |
55 { |
45 * @since S60 v5.0 |
65 * @since S60 v5.0 |
46 */ |
66 */ |
47 NONSHARABLE_CLASS( CXnEffectManager ) : public CBase |
67 NONSHARABLE_CLASS( CXnEffectManager ) : public CBase |
48 { |
68 { |
49 public: |
69 public: |
|
70 // constructor and destructor |
|
71 |
50 /** |
72 /** |
51 * Two-phased constructor. |
73 * Two-phased constructor. |
52 * @return new instance of CXnEffectManager. |
74 * @return new instance of CXnEffectManager. |
53 */ |
75 */ |
54 static CXnEffectManager* NewL(); |
76 static CXnEffectManager* NewL(); |
55 |
77 |
56 /** |
78 /** |
57 * Destructor. |
79 * Destructor. |
58 */ |
80 */ |
59 ~CXnEffectManager(); |
81 ~CXnEffectManager(); |
|
82 |
|
83 public: |
|
84 // new functions |
60 |
85 |
61 /** |
86 /** |
62 * Begin handling of fullscreen effect. |
87 * Begin handling of fullscreen effect. |
|
88 * |
|
89 * @since S60 5.2 |
63 * @param aId effect id |
90 * @param aId effect id |
64 * @aView view data |
91 * @aView view data |
65 */ |
92 */ |
66 void BeginFullscreenEffectL( TInt aId, CXnViewData& aView ); |
93 void BeginFullscreenEffectL( TInt aId, CXnViewData& aView ); |
67 |
94 |
68 /** |
95 /** |
69 * When UiRendered is called effect is ended and will be drawn |
96 * When UiRendered is called effect is ended and will be drawn |
|
97 * |
|
98 * @since S60 5.2 |
70 */ |
99 */ |
71 void UiRendered(); |
100 void UiRendered(); |
72 |
101 |
73 /** |
102 /** |
74 * When UiLayouted is called effect is started if it was not started earlier. |
103 * When UiLayouted is called effect is started if it was not started earlier. |
|
104 * |
|
105 * @since S60 5.2 |
75 */ |
106 */ |
76 void UiLayouted(); |
107 void UiLayouted(); |
77 |
108 |
78 private: |
109 private: |
|
110 // new functions |
|
111 |
79 /** |
112 /** |
80 * Starts fullscreen effect. |
113 * Starts fullscreen effect. |
|
114 * |
|
115 * @since S60 5.2 |
81 * @param aEffect effect data |
116 * @param aEffect effect data |
82 * @return ETrue if effect started, otherwise EFalse |
117 * @return ETrue if effect started, otherwise EFalse |
83 */ |
118 */ |
84 TBool DoBeginFullscreenEffect( TXnEffect& aEffect ); |
119 TBool DoBeginFullscreenEffect( TXnEffect& aEffect ); |
85 |
120 |
86 /** |
121 /** |
87 * Removes and destroys effect from effect list. |
122 * Removes and destroys effect from effect list. |
|
123 * |
|
124 * @since S60 5.2 |
88 * @param aEffect effect data |
125 * @param aEffect effect data |
89 */ |
126 */ |
90 void RemoveEffect( TXnEffect* aEffect ); |
127 void RemoveEffect( TXnEffect* aEffect ); |
91 |
128 |
|
129 private: |
|
130 // constructors |
|
131 |
92 /** |
132 /** |
93 * C++ default constructor. |
133 * C++ default constructor |
94 */ |
134 */ |
95 CXnEffectManager(); |
135 CXnEffectManager(); |
96 |
136 |
97 /** |
137 /** |
98 * By default Symbian 2nd phase constructor is private. |
138 * 2nd phase constructor |
99 */ |
139 */ |
100 void ConstructL(); |
140 void ConstructL(); |
101 |
141 |
102 private: // data |
142 private: |
103 /** |
143 // data |
104 * List of started effects. |
144 |
105 */ |
145 /** List of started effects, owned */ |
106 RPointerArray<TXnEffect> iEffects; |
146 RPointerArray<TXnEffect> iEffects; |
107 }; |
147 }; |
108 |
148 |
109 #endif // CXNEFFECTMANAGER_H |
149 #endif // CXNEFFECTMANAGER_H |
110 |
150 |
111 // End of File |
151 // End of File |