|
1 /* |
|
2 * Copyright (c) 2002 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: Private constants for engine |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef PRIVATEENGINEDEFINITIONS_H |
|
20 #define PRIVATEENGINEDEFINITIONS_H |
|
21 |
|
22 #include <e32base.h> |
|
23 |
|
24 // Settings-manager constants |
|
25 // Flow controller...overwrited in the beginning of the app |
|
26 /*const TInt KDefaulFlowControllerValue = 333000; // 333000 |
|
27 const TInt KKeyNameMaxNumberLength = 5; // 65536 |
|
28 _LIT( KKeyNameFormatter, "%d" ); |
|
29 const TInt KMessageFlowMaxValue = 10; // Maximum value of setting slider |
|
30 const TInt KMessageFlowCoEfficientValue = 200; // CoEfficient, that is used |
|
31 // to calculate messages min |
|
32 // display interval with |
|
33 // level parameters (in msecs). |
|
34 // CoEfficient * level = result |
|
35 */ |
|
36 // Default values for settings |
|
37 const TInt KDefaultMessageFlowSettingLevel = 2; |
|
38 |
|
39 const TBool KDefaultAutoLogin = EFalse; |
|
40 const TBool KDefaultDefaultScreenNameInUse = EFalse; |
|
41 const TBool KDefaultFirstLoginDone = EFalse; |
|
42 const TBool KDefaultAutomaticPresenceUpdate = ETrue; |
|
43 const TBool KDefaultUpdateSelectedContacts = EFalse; |
|
44 const TBool KDefaultShowHistory = EFalse; |
|
45 const TBool KDefaultShowOffline = ETrue; |
|
46 const TBool KDefaultShowTimeStamps = ETrue; |
|
47 |
|
48 _LIT( KDefaultScreenName, "" ); |
|
49 |
|
50 // MEMORY SECTION USED WHEN CHECKING FREE SPACE (OOM SITUATIONS)/////////////// |
|
51 // This is used in consumed memory calculation (history). |
|
52 #ifdef _UNICODE |
|
53 const TInt KCharacterLengthInBytes = 2; |
|
54 #else |
|
55 const TInt KCharacterLengthInBytes = 1; |
|
56 #endif |
|
57 |
|
58 // Resource name ( CaEngine.rsc ) |
|
59 // remember add KDC_RESOURCE_FILES_DIR to beginning when using |
|
60 _LIT( KResourceEngineFilePathWithoutDrive, "CaEngineNG.rsc" ); |
|
61 |
|
62 // userid-part (wv:userid) length of groupid (wv:userid/resource@domain.fi) |
|
63 const TInt KGroupIdFirstPartMaxLength = 20; |
|
64 // resource-part (resource) length of groupid (wv:userid/resource@domain.fi) |
|
65 const TInt KGroupIdSecondPartMaxLength = 20; |
|
66 |
|
67 // wv-address resource separator |
|
68 _LIT( KResourceSeparator, "/" ); |
|
69 |
|
70 // Line end |
|
71 _LIT( KLineEnd, "\n" ); |
|
72 |
|
73 // Default timeout for invite when received invite does not contain timeout value (seconds) |
|
74 const TInt KDefaultInviteTimeout = 7200; |
|
75 // Treshold of invite expiry timeout in seconds (x < TIntMax / 1000000 ) |
|
76 const TInt KInviteTimeoutCycleLength = 1000; |
|
77 // Local echo |
|
78 const TBool KLocalEcho = ETrue; |
|
79 // No view is active |
|
80 const TInt KNoViewIsActive = -1; |
|
81 |
|
82 // ARRAY GRANULARITIES///////////////////////////////////////////////////////// |
|
83 // general array granularity |
|
84 const TInt KArrayGranularity = 3; |
|
85 |
|
86 // Increase chats by this amount |
|
87 const TInt KChatGranularity = 2; |
|
88 |
|
89 // Message buffer granularities///////////// |
|
90 // Send message buffer granularity |
|
91 /*const TInt KSendMessageGranularity = 5; |
|
92 // Incoming message buffer granularity |
|
93 const TInt KIncomingMessageGranularity = 5; |
|
94 // One message buffer granularity |
|
95 const TInt KOneMessageGranularity = 2; |
|
96 // Screen message buffer granularity |
|
97 const TInt KScreenMessageGranularity = 5; |
|
98 // ///////////////////////////////////////// |
|
99 |
|
100 // Chat groups granularity ( favorites ) |
|
101 const TInt KChatGroupsGranularity = 1;*/ |
|
102 // Joined members in a group |
|
103 const TInt KJoinedMembersArrayGranularity = 3; |
|
104 // Contacts granularity. This is all the "friends" |
|
105 /*const TInt KContacts = 1; |
|
106 |
|
107 // Group event observer granularities |
|
108 const TInt KGroupObserverGranularity = 2; |
|
109 */ |
|
110 // Search data granularities |
|
111 const TInt KSearchDataGranularity = 2; |
|
112 /* |
|
113 // Removed indexes granularity |
|
114 const TInt KRemovedIndexGranularity = 2; |
|
115 |
|
116 // //////////////////////////////////////////////////////////////////////////// |
|
117 |
|
118 // Max length of one IM message. Effects to the fragmentation of messages |
|
119 const TInt KMessageMaxLength = 128; |
|
120 |
|
121 // Maximum memory consumption section////////////////// |
|
122 const TInt KMaximumScreenMemoryConsumption = 2000; |
|
123 const TInt KMaximumIncomingMemoryConsumption = 2000; |
|
124 |
|
125 const TInt KMaximumSendMemoryConsumption = 500; |
|
126 // //////////////////////////////////////////////////// |
|
127 |
|
128 // Safety boundaries for screen buffer in split messages |
|
129 const TInt KUpperSafetyBoundary = 3; |
|
130 const TInt KLowerSafetyBoundary = 3; |
|
131 // ///////////////////////////////////////////////////// |
|
132 |
|
133 const TInt KTimerDelay = 1; |
|
134 */ |
|
135 |
|
136 |
|
137 // LOGGING (HISTORY) section/////////////////////////////////////////////////// |
|
138 // Clock section |
|
139 const TInt KMaxDateLength = 50; |
|
140 const TInt KMaxTimeLength = 20; |
|
141 |
|
142 _LIT( KFromMe, "O->" ); |
|
143 _LIT( KToMe, "->O" ); |
|
144 _LIT( KWhiteSpace, " " ); |
|
145 // LOGGING section ends//////////////////////////////////////////////////////// |
|
146 |
|
147 // LITERALS |
|
148 _LIT( KAt, "@" ); |
|
149 _LIT( KSlash, "/" ); |
|
150 _LIT( KWV, "wv:" ); |
|
151 _LIT( KPlus, "+" ); |
|
152 _LIT( KTabulator, "\t" ); |
|
153 _LIT( KPercent, "%" ); |
|
154 _LIT( KPercentHTTP, "%25" ); |
|
155 |
|
156 // "test character identity and accents, ignore case" |
|
157 const TInt KCollationLevel = 1; |
|
158 |
|
159 // For message fragmenting |
|
160 _LIT( KMessageContinuesString, "..." ); |
|
161 |
|
162 // UIDs//////////////////////////////////////////////////////////////////////// |
|
163 const TInt KUIDWVIDField = 1; |
|
164 const TInt KUIDNameField = 2; |
|
165 const TInt KUIDRealNameField = 3; |
|
166 |
|
167 const TInt KUIDGroupField = 4; |
|
168 const TInt KUIDGroupNameField = 5; |
|
169 const TInt KUIDGroupTopicField = 6; |
|
170 const TInt KUIDGroupWelcomeField = 7; |
|
171 const TInt KUIDGroupSizeField = 8; |
|
172 const TInt KUIDGroupAllowSearchField = 9; |
|
173 const TInt KUIDGroupAccessField = 10; |
|
174 const TInt KUIDGroupAllowWhisperingField = 11; |
|
175 const TInt KUIDGroupAdministratorField = 12; |
|
176 const TInt KUIDGroupIsFavouriteField = 13; |
|
177 const TInt KUIDGroupIsOpenField = 14; |
|
178 const TInt KUIDGroupAdministratorsField = 15; |
|
179 |
|
180 const TInt KUIDWatcherStateField = 30; |
|
181 // //////////////////////////////////////////////////////////////////////////// |
|
182 |
|
183 |
|
184 // Flow controller states |
|
185 enum TTimerStates |
|
186 { |
|
187 ETimerActivated, |
|
188 ETimerDeactivated |
|
189 }; |
|
190 |
|
191 // Request for our own inner mapping for operation codes and |
|
192 // completion functions |
|
193 enum TOperationRequests |
|
194 { |
|
195 EJoinGroup = 1, |
|
196 ECreateGroup = 2, |
|
197 ECreateAndJoinGroup = 3, |
|
198 ECreateAlreadyExistingFavouriteGroup = 4, |
|
199 ELeaveGroup = 5, |
|
200 EDeleteGroup = 6, |
|
201 EDeleteNonExistentGroup = 7, |
|
202 |
|
203 // GROUP PROPERTIES//////////////////////////////////////////////////////// |
|
204 // Used to get group name after join |
|
205 ENoNeedToGetGroupProperties = 10, |
|
206 // Used to get properties of a group we do not have |
|
207 EUnknownGroupGetPropertiesFromNetwork = 11, |
|
208 EAfterJoinGroupProperties = 12, |
|
209 EGroupProperties = 13, |
|
210 // //////////////////////////////////////////////////////////////////////// |
|
211 |
|
212 EJoinToNonFavouriteGroup = 14, |
|
213 |
|
214 EModifyMembersAccess = 15, |
|
215 EGroupMembers = 16, |
|
216 ESynchGroupMembers = 17, |
|
217 ESetGroupProperties = 18, |
|
218 EAddMembers = 19, |
|
219 ERemoveMembers = 20, |
|
220 |
|
221 // In application shutdown |
|
222 ELeaveInApplicationShutdown = 21, |
|
223 |
|
224 // Subscription |
|
225 ESubscribe = 30, |
|
226 EUnSubscribe = 31, |
|
227 ECheckSubscription = 32, |
|
228 ESetRejectList = 33, |
|
229 |
|
230 // Blocking |
|
231 EBlockRequest = 34, |
|
232 EUnBlockRequest = 35, |
|
233 EGetBlockedList = 36, |
|
234 |
|
235 // Access |
|
236 ELoginRequest = 37, |
|
237 ELogoutRequest = 38 |
|
238 |
|
239 }; |
|
240 |
|
241 // //////////////////////////////////////////////////////////////////////////// |
|
242 |
|
243 #endif // PRIVATEENGINEDEFINITIONS_H |
|
244 |
|
245 // End of File |