|
1 /* |
|
2 * Copyright (c) 2008 Nokia Corporation and/or its subsidiary(-ies). |
|
3 * All rights reserved. |
|
4 * This component and the accompanying materials are made available |
|
5 * under the terms of "Eclipse Public License v1.0" |
|
6 * which accompanies this distribution, and is available |
|
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
8 * |
|
9 * Initial Contributors: |
|
10 * Nokia Corporation - initial contribution. |
|
11 * |
|
12 * Contributors: |
|
13 * |
|
14 * Description: Alf system effects |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 |
|
20 |
|
21 #ifndef ALFGFXEFFECTS_H |
|
22 #define ALFGFXEFFECTS_H |
|
23 |
|
24 #include <e32base.h> |
|
25 #include <alf/AlfTransEffectPlugin.h> |
|
26 #include "alftfxplugincommon.hrh" |
|
27 #include "../../../../ServerCore/Inc/alfwindowfxplugin.h" |
|
28 #include "wsserverdrawercontroller.h" |
|
29 |
|
30 // CONSTANTS |
|
31 const TUid KAlfGfxImplUid = { KAlfGfxImplUidValue }; |
|
32 |
|
33 class CAlfServerDrawer; |
|
34 class CRepositoryHandler; |
|
35 class CPolicyHandler; |
|
36 |
|
37 // CLASS DECLARATION |
|
38 |
|
39 /** |
|
40 * System effects class for ALF server plugin |
|
41 * |
|
42 * @since |
|
43 */ |
|
44 NONSHARABLE_CLASS( CAlfGfxEffects ): public CAlfWindowFxPlugin, MEndChecker /*, public MAlfTransEffectPlugin */ |
|
45 { |
|
46 public: // Construction and destruction |
|
47 |
|
48 /** |
|
49 * Create a new instance of the interface |
|
50 * |
|
51 * @return pointer to the instance |
|
52 */ |
|
53 static CAlfWindowFxPlugin* NewFxPluginL(); |
|
54 |
|
55 /** |
|
56 * 2nd phase constructor. Called by framework to complete construction of a plugin. |
|
57 * Must have base call from deriving class to complete construction |
|
58 */ |
|
59 void ConstructL(const CAlfWindowManager& aMgr, TInt aAlfBufferFormat); |
|
60 |
|
61 /** |
|
62 * Destructor |
|
63 */ |
|
64 ~CAlfGfxEffects(); |
|
65 |
|
66 // From CAlfWindowManager - implemented |
|
67 |
|
68 /** Synch message from client */ |
|
69 void HandleMessageL(const TDesC8& aMessage, TPtr8& aResponse); |
|
70 |
|
71 /** Asynch message from client */ |
|
72 void HandleMessageL(const TDesC8& aMessage, const RMessage2& aClientMessage); |
|
73 |
|
74 /** Cancel asynch message(s) from client */ |
|
75 void CancelMessage(TInt aMessageId); |
|
76 |
|
77 /** |
|
78 * From CAlfWindowManager - not implemented |
|
79 */ |
|
80 void PrepareFrameL(TUint aEstimatedFrameInterval); |
|
81 |
|
82 void WindowUpdated(TInt aWindowId, TInt aEventType); |
|
83 |
|
84 public: |
|
85 |
|
86 void EndExpired(); |
|
87 |
|
88 private: // From MAlfTransEffectPlugin |
|
89 // - not supported |
|
90 |
|
91 TInt GetSupportedEffects( RArray<TInt>& aSupportedEffectIds ); |
|
92 TInt StartPhase( TInt aPhaseId, TInt aEffectId, CAlfSrvEffectEnv& aEffectEnv, const TDesC8* aParams ); |
|
93 TInt Abort() { return KErrNone; }; |
|
94 TInt AddEventObserver( MAlfTransEffectObserver* /*aObserver*/, TInt /*aEvents*/, const TDesC8* /*aParams*/ ) { return KErrNone; }; |
|
95 TInt RemoveEventObserver( MAlfTransEffectObserver* /*aObserver*/, TInt /*aEvents*/ ) { return KErrNone; }; |
|
96 TInt GetEventState( TInt /*aEvent*/, TInt* /*aState*/, TDes8* /*aParams*/ ) { return KErrNone; }; |
|
97 |
|
98 private: // New |
|
99 /** |
|
100 * Leaving version of StartPhase(). |
|
101 */ |
|
102 TInt DoStartPhaseL( TInt aPhaseId, TInt aEffectId, CAlfSrvEffectEnv& aEffectEnv, const TDesC8* aParams ); |
|
103 |
|
104 void ShowVisibleGroupsAndMakeNonTransparentL(CAlfSrvEffectEnv& aEffectEnv); |
|
105 void HideGroupsAndMakeTransparentL(CAlfSrvEffectEnv& aEffectEnv); |
|
106 |
|
107 // checks that resource directory is on z drive |
|
108 TInt VerifyResourceLocation(const TDesC& aResourceDir); |
|
109 |
|
110 |
|
111 private: // Construction and destruction |
|
112 |
|
113 /** |
|
114 * C++ contructor |
|
115 */ |
|
116 CAlfGfxEffects(); |
|
117 #ifdef _DEBUG |
|
118 void PrintRequestInfo(TInt aOperation, TInt aAction ); |
|
119 #endif |
|
120 |
|
121 private: // data |
|
122 |
|
123 CAlfServerDrawer* iEngine; |
|
124 CRepositoryHandler* iSysDisable; |
|
125 CPolicyHandler* iPolicyHandler; |
|
126 |
|
127 /** |
|
128 * The wanted time (in milliseconds) for a frame in listbox animations. |
|
129 */ |
|
130 TInt iListBoxFrameTime; |
|
131 |
|
132 /** |
|
133 * The minimum time (in milliseconds) between frames in listbox animations. |
|
134 */ |
|
135 TInt iListBoxMinFrameTime; |
|
136 |
|
137 /** |
|
138 * The wanted time (in milliseconds) for a frame in control animations. |
|
139 */ |
|
140 TInt iControlFrameTime; |
|
141 |
|
142 /** |
|
143 * The minimum time (in milliseconds) between frames in control animatins. |
|
144 */ |
|
145 TInt iControlMinFrameTime; |
|
146 |
|
147 TInt iTransitionTime; |
|
148 TInt iTransitionMinTime; |
|
149 |
|
150 RArray<TInt> iActiveSyncronizedGroups; |
|
151 |
|
152 CEndCheck* iSyncronizedGroupDefitionEndChecker; |
|
153 |
|
154 }; |
|
155 |
|
156 #endif // ALFGFXEFFECTS_H |