comparison g23m/condat/ms/src/bmi/AUIWap.h @ 0:509db1a7b7b8

initial import: leo2moko-r1
author Space Falcon <falcon@ivan.Harhan.ORG>
date Mon, 01 Jun 2015 03:24:05 +0000
parents
children
comparison
equal deleted inserted replaced
-1:000000000000 0:509db1a7b7b8
1 #ifdef FF_GPF_TCPIP
2
3 /*******************************************************************************
4
5 CONDAT (UK)
6
7 ********************************************************************************
8
9 This software product is the property of Condat (UK) Ltd and may not be
10 disclosed to any third party without the express permission of the owner.
11
12 ********************************************************************************
13
14 $Project name:
15 $Project code:
16 $Module:
17 $File: AUIWap.h
18 $Revision:
19
20 $Author: Condat(UK)
21 $Date:
22
23 ********************************************************************************
24
25 Description:
26 Some definitions and internal function prototypes for the WAP AUI.
27
28
29 ********************************************************************************
30
31 $History: AUIWap.h
32
33 xrashmic 23 Nov, 2005 MMI-SPR-OMAPS00047637
34 Removing unwanted screens in the callback of the "New mms" dialog screen.
35 Sepearted the call back funtion for the sending and receving mms info dialog screns.
36
37 xrashmic 17 Jul, 2005 MMI-SPR-31364
38 When it is detected that a very large page is being opened, the wap adapter sends a message.
39 We need to exit wap and display a error dialog as we have memory constraints.
40
41 May 16 2005 REF: MMI-SPR-29887 x0012849
42 To Implement the deferred MMS retrieval.
43
44 xreddymn Mar-05-2005 MMI-SPR-26144
45 Added states for MMS send cancel
46
47 xrashmic 08 Feb, 2005 MMI-SPR-27853
48
49 Dec 22, 2004 REF: CRR MFW-SPR-27847 xnkulkar
50 Description: MFW memory size variable changed from U16 -> U32
51 Solution: The use of variable U16 has been replaced with U32
52
53 xrashmic 26 Aug, 2004 MMI-SPR-23931
54
55 xrashmic 19 Aug, 2004 Bug: 2, 3, 36 and 42
56
57 15/05/2003 - SPR#1983 - SH - Updated to latest from 1.6.3 version.
58
59 $End
60
61 *******************************************************************************/
62
63 /* Events */
64 //xpradipg - Aug 4:changes for WAP2.0 Menu
65 #define WAP_INIT 200 /* initialise WAP browser */
66 #define WAP_SHOW_CARD 201 /* display the WAP card */
67
68 /* Edit modes
69 *
70 * Specify what to do after editing a URL.
71 */
72
73 enum
74 {
75 WAP_GOTO_URL,
76 WAP_ADD_BOOKMARK,
77 WAP_ADD_BOOKMARK_NAME,
78 WAP_EDIT_BOOKMARK,
79 WAP_EDIT_BOOKMARK_URL,
80 WAP_EDIT_HISTORY,
81 WAP_EDIT_HISTORY_URL,
82 WAP_EDIT_HOMEPAGE,
83 WAP_EDIT_APN,
84 WAP_EDIT_DOWNLOAD /* SPR#2086 - TEST */
85 };
86
87
88 /* Delete modes
89 *
90 * Specify what to do after delete confirmation screen.
91 */
92
93 enum
94 {
95 WAP_DELETE_BOOKMARK,
96 WAP_DELETE_HISTORY,
97 WAP_CLEAR_HISTORY,
98 WAP_DELETE_PROFILE /* SPR#2324 - SH */
99 };
100
101 /* Number edit modes
102 *
103 * Specify what to do after a numeric edit screen
104 */
105
106 enum
107 {
108 WAP_DIALUP_NUMBER,
109 WAP_IP_ADDRESS1,
110 WAP_IP_ADDRESS2,
111 WAP_PORT1,
112 WAP_PORT2,
113 WAP_RESPONSE_TIMER
114 //xpradipg - Aug 4,2004: changes for WAP 2.0 Menus
115
116 ,
117 WAP_NAME_SERVER1,
118 WAP_NAME_SERVER2
119
120
121 };
122
123
124 /* Options menu items
125 *
126 * These are the menu items in the options menu.
127 */
128
129 enum
130 {
131 WAP_ADDBOOKMARK,
132 WAP_BOOKMARKS,
133 WAP_GOTO,
134 WAP_HOMEPAGE,
135 WAP_BACK,
136 WAP_RELOAD,
137 WAP_EXIT,
138
139 MAX_OPTIONS /* Always have this at the end of the list */
140 };
141
142
143 /* T_WAP_BROWSER
144 *
145 * This structure holds all information about the wap browser window.
146 */
147
148 typedef struct
149 {
150 T_MMI_CONTROL mmi_control;
151 T_MFW_HND parent_win;
152 T_MFW_HND win;
153 T_MFW_HND kbd;
154 T_MFW_HND kbd_long;
155 } T_WAP_BROWSER;
156
157 /* SPR#1816 - SH
158 * T_WAP_STRING
159 * Dynamically allocated string. Used to store output text.
160 */
161
162 typedef struct
163 {
164 USHORT *text;
165 USHORT length;
166 }
167 T_WAP_STRING;
168
169
170
171 /* T_WAP_PUSH_DATA
172 *
173 * SPR#2086 - Data storage for PUSH
174 */
175
176 typedef struct
177 {
178 T_MFW_HND Sms_handler; /* Handler for SMS */
179 T_WAP_LIST *List;
180 SHORT list_ids[WAP_PUSH_MAX_MESSAGES];
181 UBYTE list_created;
182 SHORT service_indication; /* The current Service Indication to be loaded */
183 }
184 T_WAP_PUSH_DATA;
185
186
187
188 /* T_WAP_DATA
189 *
190 * All data for WAP can be accessed through this structure.
191 */
192
193 typedef struct
194 {
195 T_MFW_HND parent_win; /* The parent window */
196 T_MFW_HND edit_win; // ...input window
197 T_MFW_HND options_win; // ...options window
198 T_MFW_HND sub_options_win; /* SPR#2324 - SH - Sub-options window */
199 T_MFW_HND sub_sub_options_win; /* SPR#2324 - SH - Sub-sub-options window */
200 T_MFW_HND menu_win; // ...main WAP menu window
201 T_MFW_HND browser_win; // The browser window
202 T_MFW_HND list_win; // List window (bookmarks etc)
203 ListMenuData *list_data; // ...and its list data
204 T_MFW_HND optionsmenu_win; // The options menu window, accessible from browser
205 ListMenuData *optionsmenu_data; // ...and its list data
206 T_WAP_LIST *OptionsList; // The list of options menu items
207 T_MFW_HND temp_win; // Temporary window pointer storage
208 T_MFW_HND connect_win; // The "connecting" dialog window
209 T_MFW_HND error_win; /* SPR#1739 - SH - Error dialog */
210
211 //xrashmic 19 Aug, 2004 Bug: 2, 3, 36 and 42
212 T_MFW_HND mms_win;
213 int mms_win_type;
214 //xreddymn Feb-18-2005 MMI-SPR-26144: Set to 1 when user has
215 // canceled sending MMS
216 U8 mms_cancel;
217 U8 wapOutOfMem; //xrashmic 17 Jul, 2005 MMI-SPR-31364
218 T_WAP_APPLICATION application; /* SPR#2086 - Application type */
219 T_WAP_CB callback; /* SPR#2086 - Function called when WAP starts up */
220
221 char *Buffer; // Buffer for text input
222 char *Buffer2; // Second buffer for dual input dialogs
223 T_WAP_STRING Message; /* Buffer for text output */
224 USHORT *LeftSoftKey; // Text for custom left soft key
225 USHORT *RightSoftKey; // Text for custom right soft key
226 char *URLSelect; // The current URL that is selected in a list menu
227 UBYTE OptionSelect; // The number of the selected URL
228 UBYTE profile_store; //xrashmic 23 Dec, 2004 MMI-SPR-27623
229
230 UBYTE view_id; /* SPR#2086 - ID of the current view */
231 T_WAP_VIEW *View; // Pointer to current view
232 BOOL connected; // Are we connected?
233
234 void *gen_pointer; // Pointer to generic data
235 BOOL update_forbid; // If TRUE, forbids update to the WAP browser window
236 T_MFW_HND timer; /* SPR#1569 - SH - Mfw timer */
237 UBYTE call_waiting; /* SPR#1850 - SH - TRUE if incoming call is waiting */
238
239 T_WAP_PUSH_DATA *PushData; /* Data for WAP Push */
240
241 } T_WAP_DATA;
242
243
244 /* Window indicators
245 *
246 * These flags are used to specify which windows will be destroyed in WAP_destroy
247 */
248
249 #define WAP_WIN 0x0001
250 #define MENU_WIN 0x0002
251 #define OPTIONS_WIN 0x0004
252 #define LIST_WIN 0x0008
253 #define EDIT_WIN 0x0010
254 #define OPTIONSMENU_WIN 0x0020
255 #define BROWSER_WIN 0x0040
256 #define CONNECT_WIN 0x0080
257
258 #define RETURN_TO_MENU_FLAG 0x1000
259 #define ALL_WAP_FLAG 0x2000
260
261 /* SPR#2086 - ALL_WIN closes all windows of the current WAP Application, but now all views */
262 #define ALL_WIN (WAP_WIN | MENU_WIN | OPTIONS_WIN | LIST_WIN | EDIT_WIN | OPTIONSMENU_WIN | BROWSER_WIN | CONNECT_WIN)
263 /* RETURN_TO_MENU closes all windows, but not WAP itself. It has an extra flag */
264 #define RETURN_TO_MENU (RETURN_TO_MENU_FLAG | OPTIONS_WIN | LIST_WIN | EDIT_WIN | OPTIONSMENU_WIN | BROWSER_WIN | CONNECT_WIN)
265 /* SPR#2086 - ALL_WAP closes all windows, destroys all views and shuts down the browser */
266 #define ALL_WAP (ALL_WAP_FLAG | ALL_WIN)
267
268 //xrashmic 19 Aug, 2004 Bug: 2, 3, 36 and 42
269 //xrashmic 08 Feb, 2005 MMI-SPR-27853
270 typedef enum
271 {
272 MMS_TYPE_NONE=0,
273 MMS_TYPE_SEND_PROGRESS,
274 MMS_TYPE_SEND_SUCCESS,
275 MMS_TYPE_SEND_FAILED,
276 MMS_TYPE_RECIEVE_PROGRESS,
277 MMS_TYPE_RECIEVE_SUCCESS,
278 MMS_TYPE_RECIEVE_FAILED,
279 MMS_TYPE_PLEASEWAIT,
280 MMS_TYPE_ERROR,
281 // xreddymn Mar-05-2005: Window type for the "connecting" dialog
282 MMS_TYPE_SEND_START,
283 MMS_TYPE_NOTIFICATION_PROGRESS, // x0012849 May 16 2005 for 29887
284 MMS_TYPE_NOTIFICATION_RECEIVED // x0012849 May 16 2005 for 29887
285 }MMS_WIN_TYPE;
286
287 /* Prototypes for functions */
288
289 void AUI_wap_callback(UBYTE result);
290 T_MFW_HND AUI_please_wait(T_MFW_HND parent_win); /* SPR#1569 - SH - Added this function */
291 void AUI_please_wait_cb(T_MFW_HND win, USHORT identifier, SHORT reason); /* SPR#1569 - SH - Added this function */
292 void AUI_please_wait_destroy(void);
293 void AUI_menu_create(UBYTE result);
294 static void AUI_menu_cb(T_MFW_HND parent_win, UBYTE identifier, UBYTE reason);
295 void AUI_download_create(UBYTE result);
296 static void AUI_wap_shutdown(UBYTE result);
297 int AUI_homepage(MfwMnu* menu, MfwMnuItem* item);
298 /* SPR#2086 - Changed return type to void */
299 void AUI_create (T_MFW_HND parent_win, T_WAP_APPLICATION application, T_WAP_CB callback);
300 void AUI_destroy (USHORT windows); /* SPR#2086 */
301 T_WAP_DATA *AUI_wap_data (void);
302 /* SPR#2086 - Removed functions associated with main WAP window */
303 void AUI_connecting_dialog (ULONG status); /* SPR#2086 */
304 void AUI_connecting_dialog_cb (T_MFW_HND win, UBYTE identifier, UBYTE reason);
305 void AUI_prepare_to_connect();
306 void AUI_wap_start_load_URL(UBYTE result); /* SPR#2086 - added */
307 T_MFW_HND AUI_win_create (T_MFW_HND parent_win);
308 int AUI_win_destroy (T_MFW_HND win);
309 static int AUI_win_cb (T_MFW_EVENT event, T_MFW_WIN * win);
310 void AUI_win_control (T_MFW_HND win, USHORT event, SHORT value, void * parameter);
311 static int AUI_kbd_cb (T_MFW_EVENT event, T_MFW_KBD *keyboard);
312 static int AUI_kbd_long_cb(T_MFW_EVENT event, T_MFW_KBD *keyboard);
313 int AUI_edit(char *shortcut, USHORT identifier, USHORT prompt, USHORT maxlen);
314
315 /* SPR#2086 - Remove window parameter*/
316 //static T_MFW_HND AUI_edit_create(USHORT identifier, USHORT prompt, USHORT maxlen);
317 //liuyu add unicode support to follow 2112 updates
318 static T_MFW_HND AUI_edit_create(USHORT identifier, USHORT prompt, USHORT maxlen, BOOL unicode);
319
320 static void AUI_edit_cb(T_MFW_HND win, USHORT identifier, USHORT reason);
321 void AUI_list_redraw(USHORT list, USHORT TxtId); /* SPR#1684 - SH */
322 static void AUI_list_redraw_cb(T_MFW_HND win, USHORT identifier, SHORT reason); /* SPR#1684 - SH */
323 static void AUI_bookmarks_list_cb(T_MFW_HND win, ListMenuData *EntryListData);
324 static void AUI_history_list_cb(T_MFW_HND parent_win, ListMenuData *EntryListData);
325 static void AUI_profiles_list_cb(T_MFW_HND parent_win, ListMenuData *EntryListData);
326 static void AUI_profiles_setup_cb(T_MFW_HND win, ListMenuData *EntryListData);
327 /* SPR#2086 - Remove win parameter */
328 int AUI_entry_list (T_WAP_LIST *EntryList, ListCbFunc Callback, UBYTE pos);
329 static ListMenuData* AUI_entry_list_create (T_MFW_HND win, T_WAP_LIST *EntryList, ListCbFunc Callback, UBYTE pos);
330 int AUI_entry_goto(WAP_LIST_TYPE identifier);
331 int AUI_entry_delete(UBYTE identifier);
332 void AUI_entry_delete_cb(T_MFW_HND win, UBYTE identifier, UBYTE reason);
333 int AUI_entry_sendSMS(void);
334 static void AUI_profile_name_edit_cb(T_MFW_HND parent_win, UBYTE identifier, UBYTE reason);
335 static void AUI_username_cb(T_MFW_HND parent_win, UBYTE identifier, UBYTE reason);
336 static void AUI_password_cb(T_MFW_HND parent_win, UBYTE identifier, UBYTE reason);
337 /* SPR#2086 - Removed window parameter, made static void */
338 static void AUI_number_edit(int identifier, USHORT prompt);
339 static void AUI_number_edit_cb(T_MFW_HND parent_win, UBYTE identifier, UBYTE reason);
340 static void AUI_error_cb(T_MFW_HND win, USHORT identifier, SHORT reason); /* SPR#1793 - SH - Modified parameter types */
341 /* SPR#2086 - Remove window parameter*/
342 void AUI_info_dialog(USHORT TxtId1, USHORT TxtId2);
343 #ifdef NEW_EDITOR
344 void AUI_standard_editor(T_AUI_EDITOR_DATA *editor_data, USHORT identifier, USHORT mode, USHORT titleId, T_AUI_EDIT_CB Callback);
345 #else /* NEW_EDITOR */
346 void AUI_standard_editor(T_EDITOR_DATA *editor_data, char *buffer, U16 size, UBYTE mode, T_EDIT_CB callback);
347 #endif /* NEW_EDITOR */
348 static void AUI_input_cb(T_MFW_HND win, USHORT identifier, USHORT reason);
349 static void AUI_password_cb_1(T_MFW_HND win, USHORT identifier, USHORT reason);
350 static void AUI_password_cb_2(T_MFW_HND win, USHORT identifier, USHORT reason);
351 static void AUI_confirm_cb(T_MFW_HND win, USHORT identifier, USHORT reason);
352 static void AUI_info_cb(T_MFW_HND win, USHORT identifier, USHORT reason);
353 static void AUI_options_menu_cb(T_MFW_HND win, ListMenuData *EntryListData);
354 static void AUI_goto_cb(T_MFW_HND parent_win, USHORT identifier, USHORT reason);
355 void AUI_options_cb(T_MFW_HND parent_win, UBYTE identifier, UBYTE reason); /* SPR#2086 */
356 static USHORT AUI_textid_to_uc(USHORT *dest, int src, USHORT destlen);
357 static USHORT AUI_text_to_uc(USHORT *dest, USHORT *src, USHORT destlen);
358 void AUI_wap_string_alloc(T_WAP_STRING *string, USHORT size);
359 void AUI_wap_string_free(T_WAP_STRING *string);
360
361 void AUI_error_dialog(T_WAP_VIEW *View, SHORT errorCode);
362 //xrashmic 19 Aug, 2004 Bug: 2, 3, 36 and 42
363 void AUI_wap_error_dialog(T_WAP_VIEW *View, SHORT errorCode);
364
365
366 void AUI_wap_push_start();
367 void AUI_wap_push_destroy();
368 void AUI_wap_push_list_display();
369 void AUI_wap_push_list_destroy();
370
371 #ifdef FF_MMI_MMS
372 void AUI_mms_wap_start();
373 //xrashmic 08 Feb, 2005 MMI-SPR-27853
374 //xrashmic 19 Aug, 2004 Bug: 2, 3, 36 and 42
375 //xrashmic 23 Nov, 2005 MMI-SPR-OMAPS00047637
376 void AUI_mmssend_cb(T_MFW_HND win, USHORT identifier, USHORT reason);
377 void AUI_mmsrcv_cb(T_MFW_HND win, USHORT identifier, USHORT reason);
378
379 //xrashmic 26 Aug, 2004 MMI-SPR-23931
380 void AUI_ems_dialog();
381 #endif
382 //xrashmic 08 Feb, 2005 MMI-SPR-27853
383 T_MFW_HND information_dialog(USHORT TxtId1, USHORT TxtId2,char* Txt1, char* Txt2, USHORT SoftKeyTxtId1, USHORT SoftKeyTxtId2, int timer, T_MFW_EVENT keyEvents, T_VOID_FUNC callback);
384 static void AUI_profile_reset_cb(T_MFW_HND parent_win, USHORT identifier, SHORT reason); /* SPR#2324 - SH - added */
385 #else /* #ifdef FF_GPF_TCPIP */
386
387 /*******************************************************************************
388
389 CONDAT (UK)
390
391 ********************************************************************************
392
393 This software product is the property of Condat (UK) Ltd and may not be
394 disclosed to any third party without the express permission of the owner.
395
396 ********************************************************************************
397
398 $Project name:
399 $Project code:
400 $Module:
401 $File: AUIWap.h
402 $Revision:
403
404 $Author: Condat(UK)
405 $Date:
406
407 ********************************************************************************
408
409 Description:
410 Some definitions and internal function prototypes for the WAP AUI.
411
412
413 ********************************************************************************
414
415 $History: AUIWap.h
416
417 15/05/2003 - SPR#1983 - SH - Updated to latest from 1.6.3 version.
418
419 $End
420
421 *******************************************************************************/
422
423 /* Events */
424
425 #define WAP_INIT 200 /* initialise WAP browser */
426 #define WAP_SHOW_CARD 201 /* display the WAP card */
427
428 /* Edit modes
429 *
430 * Specify what to do after editing a URL.
431 */
432
433 enum
434 {
435 WAP_GOTO_URL,
436 WAP_ADD_BOOKMARK,
437 WAP_ADD_BOOKMARK_NAME,
438 WAP_EDIT_BOOKMARK,
439 WAP_EDIT_BOOKMARK_URL,
440 WAP_EDIT_HISTORY,
441 WAP_EDIT_HISTORY_URL,
442 WAP_EDIT_HOMEPAGE,
443 WAP_EDIT_APN
444 };
445
446
447 /* Delete modes
448 *
449 * Specify what to do after delete confirmation screen.
450 */
451
452 enum
453 {
454 WAP_DELETE_BOOKMARK,
455 WAP_DELETE_HISTORY,
456 WAP_CLEAR_HISTORY,
457 WAP_DELETE_PROFILE /* SPR#2324 - SH */
458 };
459
460 /* Number edit modes
461 *
462 * Specify what to do after a numeric edit screen
463 */
464
465 enum
466 {
467 WAP_DIALUP_NUMBER,
468 WAP_IP_ADDRESS1,
469 WAP_IP_ADDRESS2,
470 WAP_PORT1,
471 WAP_PORT2,
472 WAP_RESPONSE_TIMER
473
474 };
475
476
477 /* Options menu items
478 *
479 * These are the menu items in the options menu.
480 */
481
482 enum
483 {
484 WAP_ADDBOOKMARK,
485 WAP_BOOKMARKS,
486 WAP_GOTO,
487 WAP_HOMEPAGE,
488 WAP_BACK,
489 WAP_RELOAD,
490 WAP_EXIT,
491
492 MAX_OPTIONS /* Always have this at the end of the list */
493 };
494
495
496 /* T_WAP_BROWSER
497 *
498 * This structure holds all information about the wap browser window.
499 */
500
501 typedef struct
502 {
503 T_MMI_CONTROL mmi_control;
504 T_MFW_HND parent_win;
505 T_MFW_HND win;
506 T_MFW_HND kbd;
507 T_MFW_HND kbd_long;
508 } T_WAP_BROWSER;
509
510 /*
511 * T_WAP_STRING
512 * Dynamically allocated string. Used to store output text.
513 */
514
515 typedef struct
516 {
517 USHORT *text;
518 USHORT length;
519 }
520 T_WAP_STRING;
521
522
523 /* T_WAP_DATA
524 *
525 * All data for WAP can be accessed through this structure.
526 */
527
528 typedef struct
529 {
530 T_MMI_CONTROL mmi_control;
531 T_MFW_HND parent_win;
532 T_MFW_HND win; /* The WAP data window (sits behind all other windows) */
533 T_MFW_HND edit_win; /* ...input window */
534 T_MFW_HND options_win; /* ...options window */
535 T_MFW_HND sub_options_win; /* SPR#2324 - SH - Sub-options window */
536 T_MFW_HND sub_sub_options_win; /* SPR#2324 - SH - Sub-sub-options window */
537 T_MFW_HND menu_win; /* ...main WAP menu window */
538 T_MFW_HND browser_win; /* The browser window */
539 T_MFW_HND list_win; /* List window (bookmarks etc) */
540 ListMenuData *list_data; /* ...and its list data */
541 T_MFW_HND optionsmenu_win; /* The options menu window, accessible from browser */
542 ListMenuData *optionsmenu_data; /* ...and its list data */
543 T_WAP_LIST *OptionsList; /* The list of options menu items */
544 T_MFW_HND temp_win; /* Temporary window pointer storage */
545 T_MFW_HND connect_win; /* The "connecting" dialog window */
546 T_MFW_HND error_win; /* Error dialog window */
547
548 T_MFW_HND main_kbd;
549
550 char *Buffer; /* Buffer for text input */
551 char *Buffer2; /* Second buffer for dual input dialogs */
552 T_WAP_STRING Message; /* Buffer for text output */
553 USHORT *LeftSoftKey; /* Text for custom left soft key */
554 USHORT *RightSoftKey; /* Text for custom right soft key */
555 char *URLSelect; /* The current URL that is selected in a list menu */
556 UBYTE OptionSelect; /* The number of the selected URL */
557 UBYTE profile_store; /* SPR#2324 - SH - Temporary storage for profile ID */
558
559 T_WAP_VIEW *View; /* Pointer to current view */
560 BOOL connected; /* Are we connected? */
561
562 void *gen_pointer; /* Pointer to generic data */
563 BOOL update_forbid; /* If TRUE, forbids update to the WAP browser window */
564 T_MFW_HND timer; /* Mfw timer */
565 UBYTE call_waiting; /* TRUE if incoming call is waiting */
566 } T_WAP_DATA;
567
568
569 /* Window indicators
570 *
571 * These flags are used to specify which windows will be destroyed in AUI_destroy()
572 */
573
574 /* WAP_WIN - Shuts down the WAP application. WARNING: will not deallocate ALL memory */
575 #define WAP_WIN 0x0001
576
577 /* These are standard windows that can be destroyed */
578
579 #define MENU_WIN 0x0002
580 #define OPTIONS_WIN 0x0004
581 #define LIST_WIN 0x0008
582 #define EDIT_WIN 0x0010
583 #define OPTIONSMENU_WIN 0x0020
584 #define BROWSER_WIN 0x0040
585 #define CONNECT_WIN 0x0080
586
587 /* ALL_WIN - This completely shuts down the WAP application and all its windows */
588
589 #define ALL_WIN (WAP_WIN | MENU_WIN | OPTIONS_WIN | LIST_WIN | EDIT_WIN | OPTIONSMENU_WIN | BROWSER_WIN | CONNECT_WIN)
590
591 /* RETURN_TO_MENU - This closes all windows, but not WAP itself. It has an extra flag */
592
593 #define RETURN_TO_MENU (0x1000 | MENU_WIN | OPTIONS_WIN | LIST_WIN | EDIT_WIN | OPTIONSMENU_WIN | BROWSER_WIN | CONNECT_WIN)
594
595
596 /*******************************
597 * LOCAL FUNCTION PROTOTYPES *
598 *******************************/
599
600 T_MFW_HND AUI_please_wait(T_MFW_HND parent_win);
601 void AUI_please_wait_cb(T_MFW_HND win, USHORT identifier, SHORT reason);
602 static void AUI_menu_cb(T_MFW_HND parent_win, UBYTE identifier, UBYTE reason);
603 int AUI_homepage(MfwMnu* menu, MfwMnuItem* item);
604 T_MFW_HND AUI_create (T_MFW_HND parent_win);
605 T_WAP_DATA *AUI_wap_data (void);
606 void AUI_destroy (T_MFW_HND own_window, USHORT windows);
607 static int AUI_cb (T_MFW_EVENT event, T_MFW_WIN * win);
608 static int AUI_main_kbd_cb(T_MFW_EVENT event, T_MFW_KBD *keyboard);
609 void AUI_control (T_MFW_HND win, USHORT event, SHORT value, void * parameter);
610 T_MFW_HND AUI_connecting_dialog (T_MFW_HND win, ULONG status);
611 void AUI_connecting_dialog_cb (T_MFW_HND win, UBYTE identifier, UBYTE reason);
612 void AUI_connect_URL (T_MFW_HND win, char *URL);
613 T_MFW_HND AUI_win_create (T_MFW_HND parent_win);
614 int AUI_win_destroy (T_MFW_HND win);
615 static int AUI_win_cb (T_MFW_EVENT event, T_MFW_WIN * win);
616 void AUI_win_control (T_MFW_HND win, USHORT event, SHORT value, void * parameter);
617 static int AUI_kbd_cb (T_MFW_EVENT event, T_MFW_KBD *keyboard);
618 static int AUI_kbd_long_cb(T_MFW_EVENT event, T_MFW_KBD *keyboard);
619 int AUI_edit(char *shortcut, USHORT identifier, USHORT prompt, USHORT maxlen);
620 static T_MFW_HND AUI_edit_create(MfwHnd parent_win, USHORT identifier, USHORT prompt, USHORT maxlen, BOOL unicode);
621 static void AUI_edit_cb(T_MFW_HND win, USHORT identifier, SHORT reason);
622 static void AUI_list_redraw(USHORT list, USHORT TxtId);
623 static void AUI_list_redraw_cb(T_MFW_HND win, USHORT identifier, SHORT reason);
624 static void AUI_bookmarks_list_cb(T_MFW_HND win, ListMenuData *EntryListData);
625 static void AUI_history_list_cb(T_MFW_HND parent_win, ListMenuData *EntryListData);
626 static void AUI_profiles_list_cb(T_MFW_HND parent_win, ListMenuData *EntryListData);
627 static void AUI_profiles_setup_cb(T_MFW_HND win, ListMenuData *EntryListData);
628 static int AUI_entry_list (T_MFW_HND win, T_WAP_LIST *EntryList, ListCbFunc Callback, UBYTE pos);
629 static ListMenuData* AUI_entry_list_create (T_MFW_HND win, T_WAP_LIST *EntryList, ListCbFunc Callback, UBYTE pos);
630 int AUI_entry_goto(WAP_LIST_TYPE identifier);
631 int AUI_entry_delete(UBYTE identifier);
632 void AUI_entry_delete_cb(T_MFW_HND win, UBYTE identifier, UBYTE reason);
633 int AUI_entry_sendSMS(void);
634 static void AUI_profile_name_edit_cb(T_MFW_HND parent_win, UBYTE identifier, UBYTE reason);
635 static void AUI_username_cb(T_MFW_HND parent_win, USHORT identifier, SHORT reason);
636 static void AUI_password_cb(T_MFW_HND parent_win, USHORT identifier, SHORT reason);
637 int AUI_number_edit(T_MFW_HND parent_win, int identifier, USHORT prompt);
638 static void AUI_number_edit_cb(T_MFW_HND parent_win, USHORT identifier, SHORT reason);
639 static void AUI_error_cb(T_MFW_HND win, USHORT identifier, SHORT reason);
640 static void AUI_info_dialog(T_MFW_HND win, USHORT TxtId1, USHORT TxtId2);
641 #ifdef NEW_EDITOR
642 static void AUI_standard_editor(T_AUI_EDITOR_DATA *editor_data, USHORT identifier, USHORT mode, USHORT titleId, T_AUI_EDIT_CB Callback);
643 #else /* NEW_EDITOR */
644 static void AUI_standard_editor(T_EDITOR_DATA *editor_data, char *buffer, U16 size, UBYTE mode, T_EDIT_CB callback);
645 #endif /* NEW_EDITOR */
646 static void AUI_input_cb(T_MFW_HND win, USHORT identifier, SHORT reason);
647 static void AUI_password_cb_1(T_MFW_HND win, USHORT identifier, SHORT reason);
648 static void AUI_password_cb_2(T_MFW_HND win, USHORT identifier, SHORT reason);
649 static void AUI_confirm_cb(T_MFW_HND win, USHORT identifier, SHORT reason);
650 static void AUI_info_cb(T_MFW_HND win, USHORT identifier, SHORT reason);
651 static T_WAP_RES AUI_wap_options_menu_open(UBYTE contextType);
652 static void AUI_options_menu_cb(T_MFW_HND win, ListMenuData *EntryListData);
653 static void AUI_goto_cb(T_MFW_HND parent_win, USHORT identifier, SHORT reason);
654 static USHORT AUI_textid_to_uc(USHORT *dest, int src, USHORT destlen);
655 static USHORT AUI_text_to_uc(USHORT *dest, USHORT *src, USHORT destlen);
656 static void AUI_wap_string_alloc(T_WAP_STRING *string, USHORT size);
657 static void AUI_wap_string_free(T_WAP_STRING *string);
658 void AUI_error_dialog(T_WAP_VIEW *View, SHORT errorCode);
659
660 // Dec 22, 2004 REF: CRR MFW-SPR-27847 xnkulkar
661 // Description: MFW memory size variable changed from U16 -> U32
662 // Solution: The use of variable U16 has been replaced with U32
663 UBYTE* AUI_wap_memory_alloc(U32 size);
664 void AUI_wap_memory_free(UBYTE* address, U32 size);
665 /* SPR#2324 - SH */
666 static void AUI_access_menu(T_MFW_HND win, USHORT identifier, SHORT reason);
667 static void AUI_profiles_options_cb(T_MFW_HND parent_win, UBYTE identifier, UBYTE reason); /* SPR#2324 - SH - added */
668 static void AUI_profile_change_cb(T_MFW_HND parent_win, UBYTE identifier, UBYTE reason); /* SPR#2324 - SH - added */
669 static void AUI_profile_reset_cb(T_MFW_HND parent_win, USHORT identifier, SHORT reason); /* SPR#2324 - SH - added */
670
671 #endif /* ! #ifdef FF_GPF_TCPIP */