comparison src/ui/bmi/mmiBookPhonebook.c @ 92:c0052fe355d3

src/ui/bmi/*.[ch]: rm trailing white space
author Mychaela Falconia <falcon@freecalypso.org>
date Sun, 08 Nov 2020 06:39:16 +0000
parents 67bfe9f274f6
children ec9f955fc487
comparison
equal deleted inserted replaced
91:c3d28a37caad 92:c0052fe355d3
1 /******************************************************************************* 1 /*******************************************************************************
2 2
3 CONDAT (UK) 3 CONDAT (UK)
4 4
5 ******************************************************************************** 5 ********************************************************************************
6 6
7 This software product is the property of Condat (UK) Ltd and may not be 7 This software product is the property of Condat (UK) Ltd and may not be
8 disclosed to any third party without the express permission of the owner. 8 disclosed to any third party without the express permission of the owner.
9 9
10 ******************************************************************************** 10 ********************************************************************************
11 11
12 $Project name: Basic MMI 12 $Project name: Basic MMI
13 $Project code: BMI (6349) 13 $Project code: BMI (6349)
14 $Module: PhoneBook 14 $Module: PhoneBook
15 $File: MmiBookPhoneBook.c 15 $File: MmiBookPhoneBook.c
16 $Revision: 1.0 16 $Revision: 1.0
17 17
18 $Author: Condat(UK) 18 $Author: Condat(UK)
19 $Date: 25/10/00 19 $Date: 25/10/00
20 20
21 ******************************************************************************** 21 ********************************************************************************
22 22
23 Description 23 Description
24 24
25 This module provides the basic phone book functionality 25 This module provides the basic phone book functionality
26 26
27 27
28 ******************************************************************************** 28 ********************************************************************************
29 $History: MmiBookPhoneBook.c 29 $History: MmiBookPhoneBook.c
30 CRR: 25302 - xpradipg 10 Nov 2004 30 CRR: 25302 - xpradipg 10 Nov 2004
31 Description: Should be able to select the number fro the phonebook while 31 Description: Should be able to select the number fro the phonebook while
32 sending MMS/EMS. 32 sending MMS/EMS.
37 Aug 16, 2004 REF: CRR 24323 Deepa M.D 37 Aug 16, 2004 REF: CRR 24323 Deepa M.D
38 Bug:Clenup of sprintf used for tracing 38 Bug:Clenup of sprintf used for tracing
39 Fix:Replace the char buf[]; sprintf (buf, "...", ...); TRACE_EVENT (buf); statements by TRACE_EVENT_PX 39 Fix:Replace the char buf[]; sprintf (buf, "...", ...); TRACE_EVENT (buf); statements by TRACE_EVENT_PX
40 40
41 41
42 Sep 29, 2004 REF: CRR 25041 xvilliva 42 Sep 29, 2004 REF: CRR 25041 xvilliva
43 Bug: add new entry in the FDN , phone gets rebooted. 43 Bug: add new entry in the FDN , phone gets rebooted.
44 Fix: The global variable "menuFDN" is reset while menu is destroyed. 44 Fix: The global variable "menuFDN" is reset while menu is destroyed.
45 45
46 Jul 21, 2004 REF: CRR 13348 xvilliva 46 Jul 21, 2004 REF: CRR 13348 xvilliva
47 Bug: After selecting HPLMN manually, the idle screen is not shown. 47 Bug: After selecting HPLMN manually, the idle screen is not shown.
48 Fix: After phonebook menu is created, we store the window handle in a 48 Fix: After phonebook menu is created, we store the window handle in a
49 global. 49 global.
50 50
51 51
52 25/10/00 Original Condat(UK) BMI version. 52 25/10/00 Original Condat(UK) BMI version.
53 53
54 $End 54 $End
55 55
56 *******************************************************************************/ 56 *******************************************************************************/
57 57
58 58
59 /****************************************************************************** 59 /******************************************************************************
60 60
61 Include Files 61 Include Files
62 62
63 *******************************************************************************/ 63 *******************************************************************************/
64 #define ENTITY_MFW 64 #define ENTITY_MFW
65 65
66 /* includes */ 66 /* includes */
67 #include <string.h> 67 #include <string.h>
146 #include "MmiBookController.h" 146 #include "MmiBookController.h"
147 147
148 #include "mmiColours.h" 148 #include "mmiColours.h"
149 149
150 //Jul 21, 2004 REF: CRR 13348 xvilliva 150 //Jul 21, 2004 REF: CRR 13348 xvilliva
151 //This is a global variable used to store the handle, when 151 //This is a global variable used to store the handle, when
152 //phonebook menu is created. 152 //phonebook menu is created.
153 T_MFW_HND gPhbkMenu = NULL; 153 T_MFW_HND gPhbkMenu = NULL;
154 //Sep 29, 2004 REF: CRR 25041 xvilliva 154 //Sep 29, 2004 REF: CRR 25041 xvilliva
155 extern int menuFDN; 155 extern int menuFDN;
156 156
157 157
158 /******************************************************************************* 158 /*******************************************************************************
159 159
160 Private Methods 160 Private Methods
161 161
162 *******************************************************************************/ 162 *******************************************************************************/
163 163
164 /******************************************************************************* 164 /*******************************************************************************
165 165
166 $Function: bookPhonebookDialog 166 $Function: bookPhonebookDialog
167 167
168 $Description: Dialog function for the phone book application 168 $Description: Dialog function for the phone book application
169 169
170 $Returns: none 170 $Returns: none
171 171
172 $Arguments: win, window handle 172 $Arguments: win, window handle
173 event, event to be handled 173 event, event to be handled
174 value, not used 174 value, not used
175 parameter, reason for call 175 parameter, reason for call
176 176
177 *******************************************************************************/ 177 *******************************************************************************/
178 178
179 static void bookPhonebookDialog( T_MFW_HND win, USHORT event, SHORT value, void *parameter ) 179 static void bookPhonebookDialog( T_MFW_HND win, USHORT event, SHORT value, void *parameter )
180 { 180 {
181 T_MFW_WIN *win_data = ((T_MFW_HDR *) win)->data; 181 T_MFW_WIN *win_data = ((T_MFW_HDR *) win)->data;
205 205
206 /* deal with the different initialisation types 206 /* deal with the different initialisation types
207 */ 207 */
208 if ((bookPhoneBookLoading()==BOOK_FAILURE)&&(( *reason )!=PhbkMainMenu)) 208 if ((bookPhoneBookLoading()==BOOK_FAILURE)&&(( *reason )!=PhbkMainMenu))
209 { 209 {
210 T_DISPLAY_DATA display_info; 210 T_DISPLAY_DATA display_info;
211 211
212 dlg_initDisplayData_TextId( &display_info, TxtNull, TxtNull, TxtPleaseWait, TxtNull , COLOUR_STATUS_WAIT); 212 dlg_initDisplayData_TextId( &display_info, TxtNull, TxtNull, TxtPleaseWait, TxtNull , COLOUR_STATUS_WAIT);
213 dlg_initDisplayData_events( &display_info, (T_VOID_FUNC)NULL, THREE_SECS, KEY_CLEAR ); 213 dlg_initDisplayData_events( &display_info, (T_VOID_FUNC)NULL, THREE_SECS, KEY_CLEAR );
214 214
215 /* Call Info Screen 215 /* Call Info Screen
295 data->phbk->fromSMS = TRUE; 295 data->phbk->fromSMS = TRUE;
296 data->root_win = data->phbk->search_win; 296 data->root_win = data->phbk->search_win;
297 data->phbk->current.KindOfSearch = SEARCH_BY_NAME; 297 data->phbk->current.KindOfSearch = SEARCH_BY_NAME;
298 data->phbk->current.status.book = bookActiveBook(READ); 298 data->phbk->current.status.book = bookActiveBook(READ);
299 data->phbk->search_win = bookSearchStart( data->phbk->win ); 299 data->phbk->search_win = bookSearchStart( data->phbk->win );
300 300
301 } 301 }
302 break; 302 break;
303 //CRR: 25302 - xpradipg 10 Nov 2004 303 //CRR: 25302 - xpradipg 10 Nov 2004
304 //New case added to handle the retrival of number from MMS/EMS 304 //New case added to handle the retrival of number from MMS/EMS
305 case PhbkFromMms : 305 case PhbkFromMms :
309 data->phbk->fromMmsEms = TRUE; 309 data->phbk->fromMmsEms = TRUE;
310 data->root_win = data->phbk->search_win; 310 data->root_win = data->phbk->search_win;
311 data->phbk->current.KindOfSearch = SEARCH_BY_NAME; 311 data->phbk->current.KindOfSearch = SEARCH_BY_NAME;
312 data->phbk->current.status.book = bookActiveBook(READ); 312 data->phbk->current.status.book = bookActiveBook(READ);
313 data->phbk->search_win = bookSearchStart( data->phbk->win ); 313 data->phbk->search_win = bookSearchStart( data->phbk->win );
314 314
315 } 315 }
316 break; 316 break;
317 317
318 /*SH*/ 318 /*SH*/
319 case PhbkFromSmsSC : 319 case PhbkFromSmsSC :
323 data->phbk->fromSMSSC = TRUE; 323 data->phbk->fromSMSSC = TRUE;
324 data->root_win = data->phbk->search_win; 324 data->root_win = data->phbk->search_win;
325 data->phbk->current.KindOfSearch = SEARCH_BY_NAME; 325 data->phbk->current.KindOfSearch = SEARCH_BY_NAME;
326 data->phbk->current.status.book = bookActiveBook(READ); 326 data->phbk->current.status.book = bookActiveBook(READ);
327 data->phbk->search_win = bookSearchStart( data->phbk->win ); 327 data->phbk->search_win = bookSearchStart( data->phbk->win );
328 328
329 } 329 }
330 break; 330 break;
331 331
332 case PhbkFromDivert: 332 case PhbkFromDivert:
333 { 333 {
336 data->phbk->fromDivert = TRUE; 336 data->phbk->fromDivert = TRUE;
337 data->root_win = data->phbk->search_win; 337 data->root_win = data->phbk->search_win;
338 data->phbk->current.KindOfSearch = SEARCH_BY_NAME; 338 data->phbk->current.KindOfSearch = SEARCH_BY_NAME;
339 data->phbk->current.status.book = bookActiveBook(READ); 339 data->phbk->current.status.book = bookActiveBook(READ);
340 data->phbk->search_win = bookSearchStart( data->phbk->win ); 340 data->phbk->search_win = bookSearchStart( data->phbk->win );
341 341
342 } 342 }
343 343
344 break; 344 break;
345 /*SPR 1392, initialisation from call deflection*/ 345 /*SPR 1392, initialisation from call deflection*/
346 case PhbkFromDeflect: 346 case PhbkFromDeflect:
350 data->phbk->fromDeflect = TRUE; 350 data->phbk->fromDeflect = TRUE;
351 data->root_win = data->phbk->search_win; 351 data->root_win = data->phbk->search_win;
352 data->phbk->current.KindOfSearch = SEARCH_BY_NAME; 352 data->phbk->current.KindOfSearch = SEARCH_BY_NAME;
353 data->phbk->current.status.book = bookActiveBook(READ); 353 data->phbk->current.status.book = bookActiveBook(READ);
354 data->phbk->search_win = bookSearchStart( data->phbk->win ); 354 data->phbk->search_win = bookSearchStart( data->phbk->win );
355 355
356 } 356 }
357 357
358 break; 358 break;
359 359
360 default: 360 default:
392 /******************************************************************************* 392 /*******************************************************************************
393 393
394 $Function: bookPhonebookWindowCB 394 $Function: bookPhonebookWindowCB
395 395
396 $Description: Window call back for the phone book application 396 $Description: Window call back for the phone book application
397 397
398 $Returns: MFW_EVENT_CONSUMED if event is MfwWinVisible, otherwise 398 $Returns: MFW_EVENT_CONSUMED if event is MfwWinVisible, otherwise
399 MFW_EVENT_PASSED 399 MFW_EVENT_PASSED
400 400
401 $Arguments: e, event, w, window handle 401 $Arguments: e, event, w, window handle
402 402
403 *******************************************************************************/ 403 *******************************************************************************/
404 404
405 static int bookPhonebookWindowCB ( MfwEvt e, MfwWin *w ) 405 static int bookPhonebookWindowCB ( MfwEvt e, MfwWin *w )
406 { 406 {
407 TRACE_FUNCTION ("bookPhonebookWindowCB()"); 407 TRACE_FUNCTION ("bookPhonebookWindowCB()");
418 /******************************************************************************* 418 /*******************************************************************************
419 419
420 $Function: bookPhonebookCreate 420 $Function: bookPhonebookCreate
421 421
422 $Description: Create the phone book application 422 $Description: Create the phone book application
423 423
424 $Returns: Handle of the newly created window or NULL if error 424 $Returns: Handle of the newly created window or NULL if error
425 425
426 $Arguments: parent, handle of parent window 426 $Arguments: parent, handle of parent window
427 427
428 *******************************************************************************/ 428 *******************************************************************************/
429 429
430 static T_MFW_HND bookPhonebookCreate( MfwHnd parent ) 430 static T_MFW_HND bookPhonebookCreate( MfwHnd parent )
431 { 431 {
432 T_MFW_WIN *win_data; 432 T_MFW_WIN *win_data;
477 477
478 478
479 479
480 480
481 /******************************************************************************* 481 /*******************************************************************************
482 482
483 Public methods 483 Public methods
484 484
485 *******************************************************************************/ 485 *******************************************************************************/
486 486
487 /******************************************************************************* 487 /*******************************************************************************
488 488
489 $Function: bookPhonebookStart 489 $Function: bookPhonebookStart
490 490
491 $Description: Starts up the phone book application 491 $Description: Starts up the phone book application
492 492
493 $Returns: Handle of window or NULL if error 493 $Returns: Handle of window or NULL if error
494 494
495 $Arguments: parent, window, reason, for invocation 495 $Arguments: parent, window, reason, for invocation
496 496
497 *******************************************************************************/ 497 *******************************************************************************/
498 498
499 T_MFW_HND bookPhonebookStart( MfwHnd parent, int reason ) 499 T_MFW_HND bookPhonebookStart( MfwHnd parent, int reason )
500 { 500 {
501 T_MFW_HND win; 501 T_MFW_HND win;
517 /******************************************************************************* 517 /*******************************************************************************
518 518
519 $Function: bookPhonebookDestroy 519 $Function: bookPhonebookDestroy
520 520
521 $Description: Destroys the phone book application 521 $Description: Destroys the phone book application
522 522
523 $Returns: none 523 $Returns: none
524 524
525 $Arguments: window, to be destroyed 525 $Arguments: window, to be destroyed
526 526
527 *******************************************************************************/ 527 *******************************************************************************/
528 528
529 void bookPhonebookDestroy( MfwHnd window ) 529 void bookPhonebookDestroy( MfwHnd window )
530 { 530 {
531 T_MFW_WIN *win = ((T_MFW_HDR *)window)->data; 531 T_MFW_WIN *win = ((T_MFW_HDR *)window)->data;
557 if (data->menu_call_options_win) 557 if (data->menu_call_options_win)
558 bookMenuDestroy(data->menu_call_options_win); 558 bookMenuDestroy(data->menu_call_options_win);
559 559
560 if (data->menu_call_options_win_2) 560 if (data->menu_call_options_win_2)
561 { 561 {
562 menuFDN = 0 ;// Sep 29, 2004 REF: CRR 25041 xvilliva 562 menuFDN = 0 ;// Sep 29, 2004 REF: CRR 25041 xvilliva
563 bookMenuDestroy(data->menu_call_options_win_2); 563 bookMenuDestroy(data->menu_call_options_win_2);
564 } 564 }
565 565
566 if (data->name_details_win) 566 if (data->name_details_win)
567 bookDetailsDestroy(data->name_details_win); 567 bookDetailsDestroy(data->name_details_win);
583 583
584 } 584 }
585 585
586 586
587 /******************************************************************************* 587 /*******************************************************************************
588 588
589 End Of File 589 End Of File
590 590
591 *******************************************************************************/ 591 *******************************************************************************/