33
|
1 |
/*
|
|
2 |
* Copyright (c) 2002-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: This file contains the data structure and message code
|
|
15 |
* definitions needed by both the server and the client
|
|
16 |
* interfaces at compile time.
|
|
17 |
*
|
|
18 |
*/
|
|
19 |
|
|
20 |
|
|
21 |
#ifndef SATSOPCODES_H
|
|
22 |
#define SATSOPCODES_H
|
|
23 |
|
|
24 |
// INCLUDES
|
|
25 |
|
|
26 |
#include <e32base.h>
|
|
27 |
#include <languages.hrh> // Contains new language definitions for Series 60.
|
|
28 |
|
|
29 |
// CONSTANTS
|
|
30 |
// Contains the full path name of the executable to be loaded.
|
|
31 |
_LIT( KSatServerNameAndPath, "z:\\sys\\bin\\SatServer.exe" );
|
|
32 |
|
|
33 |
// A version must be specified when creating a session with the server.
|
|
34 |
const TUint KSatServerMajorVersionNumber = 0;
|
|
35 |
const TUint KSatServerMinorVersionNumber = 1;
|
|
36 |
const TUint KSatServerBuildVersionNumber = 1;
|
|
37 |
|
|
38 |
// Number of message slots
|
|
39 |
const TInt KSatMessageSlots = 42;
|
|
40 |
|
|
41 |
// Max number of message arguments
|
|
42 |
const TInt KSatMaxMessageArguments = 4;
|
|
43 |
|
|
44 |
// DATA TYPES
|
|
45 |
|
|
46 |
// Operation codes used in message passing between client and server
|
|
47 |
enum TSatServerRequest
|
|
48 |
{
|
|
49 |
ESatSNone, // Illegal service request.
|
|
50 |
// Server test commands
|
|
51 |
ESatSDisplayText,
|
|
52 |
ESatSNotifyTest,
|
|
53 |
ESatSNotifyTestCancel,
|
|
54 |
ESatSShutdown,
|
|
55 |
// Proactive commands (asynchronous)
|
|
56 |
ESatSProactiveDisplayText,
|
|
57 |
ESatSProactiveGetInkey,
|
|
58 |
ESatSProactiveGetInput,
|
|
59 |
ESatSProactiveSetUpMenu,
|
|
60 |
ESatSProactiveSelectItem,
|
|
61 |
ESatSProactivePlayTone,
|
|
62 |
ESatSProactiveRefresh,
|
|
63 |
ESatSProactiveQuery, // for Send SM and Set Up Call
|
|
64 |
ESatSProactiveEvent, // for server event notification
|
|
65 |
ESatSProactiveNotification,
|
|
66 |
|
|
67 |
// Envelope commands (synchronous)
|
|
68 |
ESatSActiveMenuSelection,
|
|
69 |
|
|
70 |
// Command responses (synchronous)
|
|
71 |
ESatSProactiveDisplayTextResponse,
|
|
72 |
ESatSProactiveGetInkeyResponse,
|
|
73 |
ESatSProactiveGetInputResponse,
|
|
74 |
ESatSProactiveSetUpMenuResponse,
|
|
75 |
ESatSProactiveSelectItemResponse,
|
|
76 |
ESatSProactivePlayToneResponse,
|
|
77 |
ESatSProactiveQueryResponse,
|
|
78 |
ESatSProactiveEventResponse,
|
|
79 |
ESatSProactiveNotificationResponse,
|
|
80 |
|
|
81 |
ESatSProactiveRefreshResponse,
|
|
82 |
|
|
83 |
// Session indicators (for internal use)
|
|
84 |
ESatSOpenUiSubSession,
|
|
85 |
ESatSGetSIMAppStatus,
|
|
86 |
ESatSCloseUiSubSession,
|
|
87 |
|
|
88 |
// Refresh handling
|
|
89 |
ESatSOpenRefreshSubSession,
|
|
90 |
ESatSCloseRefreshSubSession,
|
|
91 |
ESatSRefreshAllowed,
|
|
92 |
ESatSNotifyAllowRefresh,
|
|
93 |
ESatSNotityAllowRefreshCancel,
|
|
94 |
ESatSNotifyRefresh,
|
|
95 |
ESatSCancelNotifyRefresh,
|
|
96 |
ESatSRefreshEFRead,
|
|
97 |
|
|
98 |
// Icon handling
|
|
99 |
ESatSOpenIconSubSession,
|
|
100 |
ESatSCloseIconSubSession,
|
|
101 |
ESatSGetIconInfo,
|
|
102 |
ESatSGetIconInstance,
|
|
103 |
ESatSIconInstanceGot,
|
|
104 |
|
|
105 |
// SetUpIdleMode response
|
|
106 |
ESatSIdleModeResponse,
|
|
107 |
|
|
108 |
ESatSSessionTerminated
|
|
109 |
};
|
|
110 |
|
|
111 |
// String array to convert Symbian TLanguage enums to
|
|
112 |
// ISO 639-1 language codes.
|
|
113 |
//
|
|
114 |
// See "http://lcweb.loc.gov/standards/iso639-2/englangn.html"
|
|
115 |
typedef const TText* TLangString;
|
|
116 |
struct SLangString
|
|
117 |
{
|
|
118 |
TInt iId;
|
|
119 |
TLangString iString;
|
|
120 |
};
|
|
121 |
|
|
122 |
const SLangString KLangStrings[] =
|
|
123 |
{
|
|
124 |
{ ELangEnglish, _S( "en" ) },
|
|
125 |
{ ELangFrench, _S( "fr" ) },
|
|
126 |
{ ELangGerman, _S( "de" ) },
|
|
127 |
{ ELangSpanish, _S( "es" ) },
|
|
128 |
{ ELangItalian, _S( "it" ) },
|
|
129 |
{ ELangSwedish, _S( "sv" ) },
|
|
130 |
{ ELangDanish, _S( "da" ) },
|
|
131 |
{ ELangNorwegian, _S( "no" ) },
|
|
132 |
{ ELangFinnish, _S( "fi" ) },
|
|
133 |
|
|
134 |
// Following three languages are not listed in ISO 639-1 specification.
|
|
135 |
// Decisions based on parent language.
|
|
136 |
{ ELangAmerican, _S( "en" ) },
|
|
137 |
{ ELangSwissFrench, _S( "fr" ) },
|
|
138 |
{ ELangSwissGerman, _S( "de" ) },
|
|
139 |
|
|
140 |
{ ELangPortuguese, _S( "pt" ) },
|
|
141 |
{ ELangTurkish, _S( "tr" ) },
|
|
142 |
{ ELangIcelandic, _S( "is" ) },
|
|
143 |
{ ELangRussian, _S( "ru" ) },
|
|
144 |
{ ELangHungarian, _S( "hu" ) },
|
|
145 |
{ ELangDutch, _S( "nl" ) },
|
|
146 |
|
|
147 |
// Following five languages are not listed in ISO 639-1 specification.
|
|
148 |
// Decisions based on parent language.
|
|
149 |
{ ELangBelgianFlemish, _S( "nl" ) },
|
|
150 |
{ ELangAustralian, _S( "en" ) }, // ISO 639-2 "aus"
|
|
151 |
{ ELangBelgianFrench, _S( "fr" ) },
|
|
152 |
{ ELangAustrian, _S( "de" ) },
|
|
153 |
{ ELangNewZealand, _S( "en" ) },
|
|
154 |
|
|
155 |
{ ELangInternationalFrench, _S( "fr" ) },
|
|
156 |
{ ELangCzech, _S( "cs" ) },
|
|
157 |
{ ELangSlovak, _S( "sk" ) },
|
|
158 |
{ ELangPolish, _S( "pl" ) },
|
|
159 |
{ ELangSlovenian, _S( "sl" ) },
|
|
160 |
|
|
161 |
// Following three languages are not listed in ISO 639-1 specification.
|
|
162 |
// Decisions based on parent language.
|
|
163 |
{ ELangTaiwanChinese, _S( "zh" ) },
|
|
164 |
{ ELangHongKongChinese, _S( "zh" ) },
|
|
165 |
{ ELangPrcChinese, _S( "zh" ) },
|
|
166 |
|
|
167 |
{ ELangJapanese, _S( "ja" ) },
|
|
168 |
{ ELangThai, _S( "th" ) },
|
|
169 |
{ ELangAfrikaans, _S( "af" ) },
|
|
170 |
{ ELangAlbanian, _S( "sq" ) },
|
|
171 |
{ ELangAmharic, _S( "am" ) },
|
|
172 |
|
|
173 |
{ ELangArabic, _S( "ar" ) },
|
|
174 |
{ ELangArmenian, _S( "hy" ) },
|
|
175 |
{ ELangTagalog, _S( "tl" ) },
|
|
176 |
{ ELangBelarussian, _S( "be" ) },
|
|
177 |
{ ELangBengali, _S( "bn" ) },
|
|
178 |
{ ELangBulgarian, _S( "bg" ) },
|
|
179 |
{ ELangBurmese, _S( "my" ) },
|
|
180 |
{ ELangCatalan, _S( "ca" ) },
|
|
181 |
{ ELangCroatian, _S( "hr" ) },
|
|
182 |
|
|
183 |
// Following language is not listed in ISO 639-1 specification.
|
|
184 |
// Decisions based on parent language.
|
|
185 |
{ ELangCanadianEnglish, _S( "en" ) },
|
|
186 |
|
|
187 |
{ ELangInternationalEnglish, _S( "en" ) },
|
|
188 |
|
|
189 |
// Following language is not listed in ISO 639-1 specification.
|
|
190 |
// Decisions based on parent language.
|
|
191 |
{ ELangSouthAfricanEnglish, _S( "en" ) },
|
|
192 |
|
|
193 |
{ ELangEstonian, _S( "et" ) },
|
|
194 |
{ ELangFarsi, _S( "fa" ) },
|
|
195 |
|
|
196 |
// Following language is not listed in ISO 639-1 specification.
|
|
197 |
// Decisions based on parent language.
|
|
198 |
{ ELangCanadianFrench, _S( "fr" ) },
|
|
199 |
|
|
200 |
{ ELangScotsGaelic, _S( "gd" ) },
|
|
201 |
{ ELangGeorgian, _S( "ka" ) },
|
|
202 |
{ ELangGreek, _S( "el" ) },
|
|
203 |
|
|
204 |
// Following language is not listed in ISO 639-1 specification.
|
|
205 |
// Decisions based on parent language.
|
|
206 |
{ ELangCyprusGreek, _S( "el" ) },
|
|
207 |
|
|
208 |
{ ELangGujarati, _S( "gu" ) },
|
|
209 |
{ ELangHebrew, _S( "he" ) },
|
|
210 |
{ ELangHindi, _S( "hi" ) },
|
|
211 |
{ ELangIndonesian, _S( "id" ) },
|
|
212 |
{ ELangIrish, _S( "ga" ) },
|
|
213 |
|
|
214 |
// Following language is not listed in ISO 639-1 specification.
|
|
215 |
// Decisions based on parent language.
|
|
216 |
{ ELangSwissItalian, _S( "it" ) },
|
|
217 |
|
|
218 |
{ ELangKannada, _S( "kn" ) },
|
|
219 |
{ ELangKazakh, _S( "kk" ) },
|
|
220 |
{ ELangKhmer, _S( "km" ) },
|
|
221 |
{ ELangKorean, _S( "ko" ) },
|
|
222 |
{ ELangLao, _S( "lo" ) },
|
|
223 |
{ ELangLatvian, _S( "lv" ) },
|
|
224 |
{ ELangLithuanian, _S( "lt" ) },
|
|
225 |
{ ELangMacedonian, _S( "mk" ) },
|
|
226 |
{ ELangMalay, _S( "ms" ) },
|
|
227 |
{ ELangMalayalam, _S( "ml" ) },
|
|
228 |
{ ELangMarathi, _S( "mr" ) },
|
|
229 |
{ ELangMoldavian, _S( "mo" ) },
|
|
230 |
{ ELangMongolian, _S( "mn" ) },
|
|
231 |
{ ELangNorwegianNynorsk, _S( "nn" ) },
|
|
232 |
|
|
233 |
// Following language is not listed in ISO 639-1 specification.
|
|
234 |
// Decisions based on parent language.
|
|
235 |
{ ELangBrazilianPortuguese, _S( "pt" ) },
|
|
236 |
|
|
237 |
{ ELangPunjabi, _S( "pa" ) },
|
|
238 |
{ ELangRomanian, _S( "ro" ) },
|
|
239 |
{ ELangSerbian, _S( "sr" ) },
|
|
240 |
{ ELangSinhalese, _S( "si" ) },
|
|
241 |
{ ELangSomali, _S( "so" ) },
|
|
242 |
{ ELangInternationalSpanish, _S( "es" ) },
|
|
243 |
|
|
244 |
// Following language is not listed in ISO 639-1 specification.
|
|
245 |
// Decisions based on parent language.
|
|
246 |
{ ELangLatinAmericanSpanish, _S( "es" ) },
|
|
247 |
|
|
248 |
{ ELangSwahili, _S( "sw" ) },
|
|
249 |
|
|
250 |
// Following language is not listed in ISO 639-1 specification.
|
|
251 |
// Decisions based on parent language.
|
|
252 |
{ ELangFinlandSwedish, _S( "sv" ) },
|
|
253 |
|
|
254 |
{ ELangReserved1, _S( "en" ) },
|
|
255 |
{ ELangTamil, _S( "ta" ) },
|
|
256 |
{ ELangTelugu, _S( "te" ) },
|
|
257 |
{ ELangTibetan, _S( "bo" ) },
|
|
258 |
{ ELangTigrinya, _S( "ti" ) },
|
|
259 |
|
|
260 |
// Following language is not listed in ISO 639-1 specification.
|
|
261 |
// Decisions based on parent language.
|
|
262 |
{ ELangCyprusTurkish, _S( "tr" ) },
|
|
263 |
|
|
264 |
{ ELangTurkmen, _S( "tk" ) },
|
|
265 |
{ ELangUkrainian, _S( "uk" ) },
|
|
266 |
{ ELangUrdu, _S( "ur" ) },
|
|
267 |
{ ELangReserved2, _S( "en" ) },
|
|
268 |
{ ELangVietnamese, _S( "vi" ) },
|
|
269 |
{ ELangWelsh, _S( "cy" ) },
|
|
270 |
{ ELangZulu, _S( "zu" ) },
|
|
271 |
|
|
272 |
// Series 60 added language codes.
|
|
273 |
{ KLangTaiwanEnglish, _S( "en" ) },
|
|
274 |
{ KLangHongKongEnglish, _S( "en" ) },
|
|
275 |
{ KLangPrcEnglish, _S( "en" ) },
|
|
276 |
{ KLangJapaneseEnglish, _S( "en" ) },
|
|
277 |
{ KLangThaiEnglish, _S( "en" ) },
|
|
278 |
};
|
|
279 |
|
|
280 |
#define KNUMLANGSTRINGS ( sizeof( KLangStrings ) / sizeof( SLangString ) )
|
|
281 |
|
|
282 |
#endif // SATSOPCODES_H
|
|
283 |
|
|
284 |
// End of File
|