18
|
1 |
/*
|
|
2 |
* Copyright (c) 2007 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: Blid application startup view's control class definition.
|
|
15 |
*
|
|
16 |
*/
|
|
17 |
|
|
18 |
|
|
19 |
|
|
20 |
#ifndef __CBLIDMAINCONTROL_H__
|
|
21 |
#define __CBLIDMAINCONTROL_H__
|
|
22 |
|
|
23 |
// SYSTEM INCLUDES
|
|
24 |
#include <alf/alfcontrol.h>
|
|
25 |
|
|
26 |
// USER INCLUDE
|
|
27 |
// INCLUDES
|
|
28 |
//#include "CBlidBaseContainer.h"
|
|
29 |
//#include "CBlidBaseView.h"
|
|
30 |
|
|
31 |
//FORWARD DCLERATION
|
|
32 |
class CEikStatusPane;
|
|
33 |
class CAlfEnv;
|
|
34 |
class CBlidBaseView;
|
|
35 |
class CAlfAnchorLayout;
|
|
36 |
class CAlfTextVisual;
|
|
37 |
class MBlidLocation;
|
|
38 |
class CBlidLocSettingsLauncher;
|
|
39 |
class CAknMessageQueryDialog;
|
|
40 |
class CAlfImageLoaderUtil;
|
|
41 |
class CAlfImageVisual;
|
|
42 |
class CAlfTexture;
|
|
43 |
|
|
44 |
/*!
|
|
45 |
@class CBlidMainControl
|
|
46 |
|
|
47 |
@discussion
|
|
48 |
*/
|
|
49 |
class CBlidMainControl : public CAlfControl
|
|
50 |
{
|
|
51 |
public:
|
|
52 |
/*!
|
|
53 |
@function NewL
|
|
54 |
|
|
55 |
@discussion Create a CBlidMainControl object, which will draw itself to aRect
|
|
56 |
* Two-phased constructor
|
|
57 |
* @param aKeyProcessor
|
|
58 |
* @param aParent
|
|
59 |
* @param aRect A rectangle for drawing.
|
|
60 |
* @return The newly created object.
|
|
61 |
|
|
62 |
@result a pointer to the created instance of CBlidMainControl
|
|
63 |
*/
|
|
64 |
static CBlidMainControl* NewL( CAlfEnv& aEnv,
|
|
65 |
const TRect& aRect,
|
|
66 |
CBlidBaseView& aView );
|
|
67 |
|
|
68 |
/*!
|
|
69 |
@function ~CBlidMainControl
|
|
70 |
|
|
71 |
@discussion Destroy the object and release all memory objects
|
|
72 |
*/
|
|
73 |
~CBlidMainControl();
|
|
74 |
|
|
75 |
|
|
76 |
private:
|
|
77 |
/*!
|
|
78 |
@function CBlidMainControl
|
|
79 |
|
|
80 |
@discussion Perform the first phase of two phase construction
|
|
81 |
*/
|
|
82 |
CBlidMainControl( CAlfEnv& aEnv,
|
|
83 |
CBlidBaseView& aView );
|
|
84 |
|
|
85 |
/*!
|
|
86 |
@function ConstructL
|
|
87 |
|
|
88 |
@discussion Perform the second phase construction of a CBlidMainControl object
|
|
89 |
*/
|
|
90 |
void ConstructL( const TRect& aRect );
|
|
91 |
|
|
92 |
public:
|
|
93 |
/*!
|
|
94 |
@function UpdateL
|
|
95 |
|
|
96 |
@discussion Called by Location model to update the current location
|
|
97 |
*/
|
|
98 |
void UpdateL();
|
|
99 |
|
|
100 |
/*!
|
|
101 |
@function MakeTitleL
|
|
102 |
|
|
103 |
@discussion Set the title
|
|
104 |
@param aResourceText
|
|
105 |
*/
|
|
106 |
void MakeTitleL( TInt aResourceText );
|
|
107 |
|
|
108 |
/*!
|
|
109 |
@function SetErrorCode
|
|
110 |
|
|
111 |
@discussion Sets the error code
|
|
112 |
@param aErrorCode
|
|
113 |
*/
|
|
114 |
void SetErrorCode( TInt aErrorCode );
|
|
115 |
|
|
116 |
/*!
|
|
117 |
@function SetOnlineMode
|
|
118 |
|
|
119 |
@discussion Sets the online mode
|
|
120 |
@param aOnlineMode
|
|
121 |
*/
|
|
122 |
void SetOnlineMode( TBool aOnlineMode );
|
|
123 |
|
|
124 |
/*!
|
|
125 |
@function CreateNaviPaneL
|
|
126 |
|
|
127 |
@discussion Create the navigation pane
|
|
128 |
*/
|
|
129 |
void CreateNaviPaneL();
|
|
130 |
|
|
131 |
/*!
|
|
132 |
@function LaunchPositioningSettingsViewL
|
|
133 |
|
|
134 |
@discussion Launches the positioning settings view
|
|
135 |
*/
|
|
136 |
void LaunchPositioningSettingsViewL( );
|
|
137 |
|
|
138 |
/*!
|
|
139 |
@function DeleteDialogResource
|
|
140 |
|
|
141 |
@discussion Delete the dialog resources
|
|
142 |
*/
|
|
143 |
void DeleteDialogResource( );
|
|
144 |
|
|
145 |
/*!
|
|
146 |
@function UpdateDisplayLayoutL
|
|
147 |
|
|
148 |
@discussion Update the diaply layout when there is achange in app resource
|
|
149 |
*/
|
|
150 |
void UpdateDisplayLayoutL();
|
|
151 |
|
|
152 |
private:
|
|
153 |
/*!
|
|
154 |
@function StatusPane
|
|
155 |
|
|
156 |
@discussion Retruns the status pane
|
|
157 |
*/
|
|
158 |
CEikStatusPane* StatusPane() const;
|
|
159 |
|
|
160 |
/*!
|
|
161 |
@function DispMsgQueryWithLinkL
|
|
162 |
|
|
163 |
@discussion Displays a message query with a link
|
|
164 |
@param aHeadingText
|
|
165 |
@param aMsgQueryText
|
|
166 |
@param aLinkText
|
|
167 |
@param aLinkShow
|
|
168 |
@param aCallBack
|
|
169 |
*/
|
|
170 |
TInt DispMsgQueryWithLinkL(TInt aHeadingText,
|
|
171 |
TInt aMsgQueryText,
|
|
172 |
TInt aLinkText,
|
|
173 |
TBool aLinkShow,
|
|
174 |
TCallBack aCallBack );
|
|
175 |
|
|
176 |
/*!
|
|
177 |
@function CreateSearchingTextL
|
|
178 |
|
|
179 |
@discussion Creates the searching text visual
|
|
180 |
*/
|
|
181 |
void CreateSearchingTextL();
|
|
182 |
|
|
183 |
/*!
|
|
184 |
@function CreateAnimationL
|
|
185 |
|
|
186 |
@discussion Creates the image visuals for animation
|
|
187 |
*/
|
|
188 |
void CreateAnimationL();
|
|
189 |
|
|
190 |
/*!
|
|
191 |
@function UpdateAnimation
|
|
192 |
|
|
193 |
@discussion Changes the image visual in orser to animate
|
|
194 |
*/
|
|
195 |
void UpdateAnimation();
|
|
196 |
|
|
197 |
/*!
|
|
198 |
@function Tick
|
|
199 |
|
|
200 |
@discussion Timer callback
|
|
201 |
@param aObject
|
|
202 |
*/
|
|
203 |
static TInt Tick(TAny* aObject); // functions for TCallBack protocol
|
|
204 |
|
|
205 |
private:
|
|
206 |
/// Reference to the view to handle resource change
|
|
207 |
CAlfEnv& iEnv;
|
|
208 |
CBlidBaseView& iView;
|
|
209 |
CAlfAnchorLayout* iMainLayout;
|
|
210 |
CAlfTextVisual* iSearchTextVisual;
|
|
211 |
TInt iErrorCode;
|
|
212 |
TBool iOnlineMode;
|
|
213 |
MBlidLocation* iLocation;
|
|
214 |
///Own: count for 30 sec PSY unavailaility
|
|
215 |
static TInt iPSYTimeoutCount;
|
|
216 |
TInt iButtonId;
|
|
217 |
CBlidLocSettingsLauncher* iLauncher;
|
|
218 |
TBool isSettingsLaunched;
|
|
219 |
HBufC* iHeadPaneText;
|
|
220 |
HBufC* iMsgQueryText;
|
|
221 |
HBufC* iLinkText;
|
|
222 |
HBufC* iMsgQText;
|
|
223 |
TBool isDialogLaunched;
|
|
224 |
|
|
225 |
CPeriodic* iPeriodic; // periodic timer active object
|
|
226 |
TInt iDisplayIcon; // Current svg animation icon
|
|
227 |
CAlfImageVisual* iAnimationVisual;
|
|
228 |
TRect iAnimationRect;
|
|
229 |
RPointerArray<CAlfTexture> iTextures;
|
|
230 |
TBool isAccessoryRequired;
|
|
231 |
|
|
232 |
public:
|
|
233 |
CAknMessageQueryDialog* iDialog;
|
|
234 |
};
|
|
235 |
|
|
236 |
#endif // __CBLIDMAINCONTROL_H__
|