FreeCalypso > hg > fc-tourmaline
diff src/ui/bmi/mmiLists.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 | 65f0ce5bd32f |
line wrap: on
line diff
--- a/src/ui/bmi/mmiLists.c Sun Nov 08 05:12:05 2020 +0000 +++ b/src/ui/bmi/mmiLists.c Sun Nov 08 06:39:16 2020 +0000 @@ -2,27 +2,27 @@ CONDAT (UK) -******************************************************************************** +******************************************************************************** This software product is the property of Condat (UK) Ltd and may not be - disclosed to any third party without the express permission of the owner. - + disclosed to any third party without the express permission of the owner. + ******************************************************************************** - $Project name: Basic MMI - $Project code: BMI (6349) + $Project name: Basic MMI + $Project code: BMI (6349) $Module: MMI $File: MmiLists.c - $Revision: 1.0 - - $Author: Condat(UK) - $Date: 22/02/01 - + $Revision: 1.0 + + $Author: Condat(UK) + $Date: 22/02/01 + ******************************************************************************** - + Description: - + ******************************************************************************** @@ -35,10 +35,10 @@ Mar 30, 2007 REF: OMAPS00122691 x0039928 Description: COMBO: No melody heard on parsing over different volums in tones menu Solution: E_MELODY_START event is sent to play the melody. - + xrashmic 8 Sep 2006, OMAPS00091618 Removed redundant code introduced during integration - + June 19, 2006 REF: DRT OMAPS00076378 x0012849 : Jagannatha Description: MIDI files should play while browsing Solution: Event will be generated upon press of Menu up and down key. @@ -47,34 +47,34 @@ Description: Header Toggling Solution: Implemented the toggling of header when displaying the length text in SELECT ITEM and SET UP MENU - May 18, 2006 REF: DRT OMAPS00076438 xdeepadh + May 18, 2006 REF: DRT OMAPS00076438 xdeepadh Description: Scrolling not implemented in Imageviewer Solution: The support for scrolling has been provided. May 03, 2006 REF: DRT OMAPS00076439 xdeepadh - Description: Image viewer back not working - Solution: The Preview List will be repopulated, when the list window is + Description: Image viewer back not working + Solution: The Preview List will be repopulated, when the list window is resumed. May 03, 2006 REF: DRT OMAPS00076376 xdeepadh Description: File Viewer-N5.12 issues (very unstable) Solution: The keys are blocked until the view or preview is completed. - + Dec 22, 2005 REF: ENH xdeepadh Description: Image Viewer Application Solution: Implemeted the Image Viewer to view the jpeg images xrashmic 5 Oct, 2005 MMI-SPR-29356, MMI-SPR-29357 - Using the MenuSelect Key for requesting the help info in STK menu. Storing the info that + Using the MenuSelect Key for requesting the help info in STK menu. Storing the info that MenuSelectKey was pressed in a list view. - + May 24, 2005 REF: CRR 29358 x0021334 Description: CT_PTCRB 27.22.4.9.8 fails: wrong terminal response Fix: The implementation is now based on timer. After the specified timeout period the control comes back to SAT main menu, if there is no selection done by the user. - 25/10/00 Original Condat(UK) BMI version. - + 25/10/00 Original Condat(UK) BMI version. + $End *******************************************************************************/ @@ -187,7 +187,7 @@ #endif /* START: 05-June-2006, x0045876 (OMAPS00060424 - Header Toggle) */ -MfwHnd g_win; +MfwHnd g_win; extern MfwHnd g_title_timer; /* END: 05-June-2006, x0045876 (OMAPS00060424 - Header Toggle) */ @@ -229,14 +229,14 @@ /******************************************************************************* - $Function: listIconsDisplayListMenu + $Function: listIconsDisplayListMenu $Description: Creates a list menu from data stored in NVRAM. $Returns: none. - $Arguments: - + $Arguments: + *******************************************************************************/ MfwHnd winIconsLists; T_MFW listIconsDisplayListMenu (MfwHnd Parent, ListMenuData *Data, ListCbFunc cbFunc,int inUnicode) @@ -264,7 +264,7 @@ /* cq12719. if insufficient memory for listdata then delete window and Free allocated memory.16-03-04.MZ */ if(NULL != winLists) winDelete(winLists); - + TRACE_EVENT ("(ListIconsWinInfo *)ALLOC_MEMORY fails"); return LISTS_FAIL; } @@ -299,8 +299,8 @@ ListData->MenuListsAttr.mode = MNU_LEFT | MNU_LIST | MNU_CUR_LINE; else ListData->MenuListsAttr.mode |= Data->Attr->mode; - - ListData->MenuListsAttr.font = Data->Font; + + ListData->MenuListsAttr.font = Data->Font; ListData->MenuListsAttr.items = Data->List; ListData->MenuListsAttr.nItems = Data->ListLength; @@ -318,11 +318,11 @@ ListData->MenuData->listCol = COLOUR_LIST_XX; //Set-up colour ListData->MenuData->Attr = &ListData->MenuListsAttr; /* copy data*/ ListData->MenuLists = mnuCreate(winLists, &ListData->MenuListsAttr, - E_MNU_SELECT | E_MNU_ESCAPE| E_MNU_POSTDRAW, + E_MNU_SELECT | E_MNU_ESCAPE| E_MNU_POSTDRAW, (MfwCb)listsIconsListCbMenu); ListData->MenuData->win = winLists; Data->win = winLists; - mnuScrollMode(ListData->MenuLists,0); + mnuScrollMode(ListData->MenuLists,0); if (Data->Strings) mnuLang (ListData->MenuLists,0); else @@ -337,7 +337,7 @@ mnuUnhide(ListData->MenuLists); displaySoftKeys(ListData->MenuData->LeftSoftKey,ListData->MenuData->RightSoftKey); winShow(winLists); - + } } return Status; @@ -388,10 +388,10 @@ MenuHandle = mfwControl(data->MenuLists); data->MenuData->Reason = LISTS_REASON_SCROLL; data->MenuData->CursorPosition = MenuHandle->lCursor[MenuHandle->level]; - data->MenuData->ListPosition = MenuHandle->lCursor[MenuHandle->level]; + data->MenuData->ListPosition = MenuHandle->lCursor[MenuHandle->level]; // Send event to indicate that the user has scrolled list items - SEND_EVENT(data->Parent, LISTS_REASON_SCROLL, 0, NULL); - } + SEND_EVENT(data->Parent, LISTS_REASON_SCROLL, 0, NULL); + } break; case KCD_MNUDOWN: /* highlight next entry */ @@ -400,15 +400,15 @@ MenuHandle = mfwControl(data->MenuLists); data->MenuData->Reason = LISTS_REASON_SCROLL; data->MenuData->CursorPosition = MenuHandle->lCursor[MenuHandle->level]; - data->MenuData->ListPosition = MenuHandle->lCursor[MenuHandle->level]; + data->MenuData->ListPosition = MenuHandle->lCursor[MenuHandle->level]; // Send event to indicate that the user has scrolled list items - SEND_EVENT(data->Parent, LISTS_REASON_SCROLL, 0, NULL); - } + SEND_EVENT(data->Parent, LISTS_REASON_SCROLL, 0, NULL); + } break; case KCD_MNUSELECT: //xrashmic 5 Oct, 2005 MMI-SPR-29356, MMI-SPR-29357 //Menu Select Key was pressed, storing this for future use. - data->MenuData->selectKey = TRUE; + data->MenuData->selectKey = TRUE; //Break is delibrately not used here. The control should pass through the KCD_LEFT case. case KCD_LEFT: /* activate this entry */ MenuHandle = mfwControl(data->MenuLists); @@ -425,7 +425,7 @@ /* SPR998 - SH - check if callback exists before calling it! */ if (data->Callback) data->Callback(data->Parent, data->MenuData); - + if (data->MenuData->autoDestroy) { /* START: 05-June-2006, x0045876 (OMAPS00060424 - Header Toggle) */ @@ -452,7 +452,7 @@ data->MenuData->ListPosition = MenuHandle->lCursor[MenuHandle->level]; /* True cursor position in list menu. */ /*NM, p023 end */ data->Callback(data->Parent, data->MenuData); - //July 10, 2007 REF: DRT OMAPS00135679 x0073106 + //July 10, 2007 REF: DRT OMAPS00135679 x0073106 /*if (data->MenuData->autoDestroy) {*/ /* START: 05-June-2006, x0045876 (OMAPS00060424 - Header Toggle) */ @@ -482,14 +482,14 @@ /******************************************************************************* - $Function: listsWinEvent + $Function: listsWinEvent $Description: window event handler $Returns: none. - $Arguments: - + $Arguments: + *******************************************************************************/ static int listsIconsWinEvent(MfwEvt e, MfwWin *w) { @@ -500,14 +500,14 @@ switch (e) { case E_WIN_VISIBLE: - SEND_EVENT(ListData->Parent,LISTS_REASON_VISIBLE,0,(void*)ListData); + SEND_EVENT(ListData->Parent,LISTS_REASON_VISIBLE,0,(void*)ListData); break; case MfwWinResume: - SEND_EVENT(ListData->Parent,LISTS_REASON_RESUME,0,(void*)ListData); - break; + SEND_EVENT(ListData->Parent,LISTS_REASON_RESUME,0,(void*)ListData); + break; case MfwWinSuspend: - SEND_EVENT(ListData->Parent,LISTS_REASON_SUSPEND,0,(void*)ListData); - break; + SEND_EVENT(ListData->Parent,LISTS_REASON_SUSPEND,0,(void*)ListData); + break; } return MFW_EVENT_CONSUMED; } @@ -556,14 +556,14 @@ /******************************************************************************* - $Function: listsListCbMenu + $Function: listsListCbMenu $Description: List menu handler. (mfw callback function) $Returns: none. - $Arguments: - + $Arguments: + *******************************************************************************/ int listsIconsListCbMenu(MfwEvt EventCode, MfwMnu *MenuHandle) { @@ -591,7 +591,7 @@ ListData->MenuData->CursorPosition = MenuHandle->lCursor[MenuHandle->level]; ListData->MenuData->ListPosition = MenuHandle->lCursor[MenuHandle->level]; /* True cursor position in list menu. */ /*NM, p023*/ - + /* SPR998 - SH - check if callback exists before calling it! */ if (ListData->Callback) ListData->Callback(ListData->Parent, ListData->MenuData); @@ -600,7 +600,7 @@ case E_MNU_POSTDRAW: { T_MFW_WIN * winIconsLists_data = ((T_MFW_HDR *)winIconsLists)->data; - ListIconsWinInfo* winIconsListsData = (ListIconsWinInfo *)winIconsLists_data->user; + ListIconsWinInfo* winIconsListsData = (ListIconsWinInfo *)winIconsLists_data->user; winIconsListsData->ExitReason = LISTS_REASON_DRAWCOMPLETE; winIconsListsData->MenuData->Reason = LISTS_REASON_DRAWCOMPLETE; winIconsListsData->MenuData->CursorPosition = MenuHandle->lCursor[MenuHandle->level]; @@ -635,22 +635,22 @@ } } /* END: 05-June-2006, x0045876 (OMAPS00060424 - Header Toggle) */ - + winDelete (win); FREE_MEMORY ((void*) ListData, sizeof (ListIconsWinInfo)); - + } /******************************************************************************* - $Function: listDisplayListMenu + $Function: listDisplayListMenu $Description: Creates a list menu from data stored in NVRAM. $Returns: none. - $Arguments: - + $Arguments: + *******************************************************************************/ T_MFW listDisplayListMenu (MfwHnd Parent, ListMenuData *Data, ListCbFunc cbFunc,int inUnicode) { @@ -677,7 +677,7 @@ /* cq12719. if insufficient memory for listdata then delete window and Free allocated memory.16-03-04.MZ */ if(NULL != winLists) winDelete(winLists); - + TRACE_EVENT ("(ListWinInfo *)ALLOC_MEMORY fails"); return LISTS_FAIL; } @@ -712,8 +712,8 @@ ListData->MenuListsAttr.mode = MNU_LEFT | MNU_LIST | MNU_CUR_LINE; else ListData->MenuListsAttr.mode |= Data->Attr->mode; - - ListData->MenuListsAttr.font = Data->Font; + + ListData->MenuListsAttr.font = Data->Font; ListData->MenuListsAttr.items = Data->List; ListData->MenuListsAttr.nItems = Data->ListLength; @@ -731,11 +731,11 @@ ListData->MenuData.listCol = COLOUR_LIST_XX; //Set-up colour ListData->MenuData.Attr = &ListData->MenuListsAttr; /* copy data*/ ListData->MenuLists = mnuCreate(winLists, &ListData->MenuListsAttr, - E_MNU_SELECT | E_MNU_ESCAPE, + E_MNU_SELECT | E_MNU_ESCAPE, (MfwCb)listsListCbMenu); ListData->MenuData.win = winLists; Data->win = winLists; - mnuScrollMode(ListData->MenuLists,1); + mnuScrollMode(ListData->MenuLists,1); if (Data->Strings) mnuLang (ListData->MenuLists,0); else @@ -759,14 +759,14 @@ /******************************************************************************* - $Function: listsKeyEvent + $Function: listsKeyEvent $Description: Keyboard event handler $Returns: none. - $Arguments: - + $Arguments: + *******************************************************************************/ static int listsKeyEvent (MfwEvt e, MfwKbd *k) /* list keyboard event handler */ @@ -815,17 +815,17 @@ if(getMelodyListStatus()== TRUE) { MenuHandle = mfwControl(data->MenuLists); - + data->MenuData.Reason = LISTS_REASON_SCROLL; data->MenuData.CursorPosition = MenuHandle->lCursor[MenuHandle->level]; - data->MenuData.ListPosition = MenuHandle->lCursor[MenuHandle->level]; - SEND_EVENT(data->Parent,E_START_MELODY,0,(void*)data); + data->MenuData.ListPosition = MenuHandle->lCursor[MenuHandle->level]; + SEND_EVENT(data->Parent,E_START_MELODY,0,(void*)data); } - + if(getScrollStatus() == TRUE) { // Send event to indicate that the user has scrolled list items - SEND_EVENT(data->Parent, LISTS_REASON_SCROLL, 0, NULL); + SEND_EVENT(data->Parent, LISTS_REASON_SCROLL, 0, NULL); } break; case KCD_MNUDOWN: /* highlight next entry */ @@ -837,23 +837,23 @@ if(getMelodyListStatus()== TRUE) { MenuHandle = mfwControl(data->MenuLists); - + data->MenuData.Reason = LISTS_REASON_SCROLL; data->MenuData.CursorPosition = MenuHandle->lCursor[MenuHandle->level]; - data->MenuData.ListPosition = MenuHandle->lCursor[MenuHandle->level]; + data->MenuData.ListPosition = MenuHandle->lCursor[MenuHandle->level]; SEND_EVENT(data->Parent,E_START_MELODY,0,(void*)data); } - + if(getScrollStatus() == TRUE) { // Send event to indicate that the user has scrolled list items - SEND_EVENT(data->Parent, LISTS_REASON_SCROLL, 0, NULL); - } + SEND_EVENT(data->Parent, LISTS_REASON_SCROLL, 0, NULL); + } break; case KCD_MNUSELECT: //xrashmic 5 Oct, 2005 MMI-SPR-29356, MMI-SPR-29357 //Menu Select Key was pressed, storing this for future use. - data->MenuData.selectKey = TRUE; + data->MenuData.selectKey = TRUE; //Break is delibrately not used here. The control should pass through the KCD_LEFT case. case KCD_LEFT: /* activate this entry */ mnuSelect(data->MenuLists); @@ -875,7 +875,7 @@ /* SPR998 - SH - check if callback exists before calling it! */ if (data->Callback) data->Callback(data->Parent, &data->MenuData); - + if (data->MenuData.autoDestroy) { /* START: 05-June-2006, x0045876 (OMAPS00060424 - Header Toggle) */ @@ -931,14 +931,14 @@ /******************************************************************************* - $Function: listsWinEvent + $Function: listsWinEvent $Description: window event handler $Returns: none. - $Arguments: - + $Arguments: + *******************************************************************************/ static int listsWinEvent(MfwEvt e, MfwWin *w) { @@ -949,14 +949,14 @@ switch (e) { case E_WIN_VISIBLE: - SEND_EVENT(ListData->Parent,LISTS_REASON_VISIBLE,0,(void*)ListData); - break; + SEND_EVENT(ListData->Parent,LISTS_REASON_VISIBLE,0,(void*)ListData); + break; case MfwWinResume: - SEND_EVENT(ListData->Parent,LISTS_REASON_RESUME,0,(void*)ListData); - break; + SEND_EVENT(ListData->Parent,LISTS_REASON_RESUME,0,(void*)ListData); + break; case MfwWinSuspend: - SEND_EVENT(ListData->Parent,LISTS_REASON_SUSPEND,0,(void*)ListData); - break; + SEND_EVENT(ListData->Parent,LISTS_REASON_SUSPEND,0,(void*)ListData); + break; } return MFW_EVENT_CONSUMED; } @@ -1004,14 +1004,14 @@ /******************************************************************************* - $Function: listsListCbMenu + $Function: listsListCbMenu $Description: List menu handler. (mfw callback function) $Returns: none. - $Arguments: - + $Arguments: + *******************************************************************************/ int listsListCbMenu(MfwEvt EventCode, MfwMnu *MenuHandle) { @@ -1041,7 +1041,7 @@ ListData->MenuData.CursorPosition = MenuHandle->lCursor[MenuHandle->level]; ListData->MenuData.ListPosition = MenuHandle->lCursor[MenuHandle->level]; /* True cursor position in list menu. */ /*NM, p023*/ - + /* SPR998 - SH - check if callback exists before calling it! */ if (ListData->Callback) ListData->Callback(ListData->Parent, &ListData->MenuData); @@ -1049,7 +1049,7 @@ default: Status = LISTS_FAIL; - TRACE_EVENT("Activation 77 error"); + TRACE_EVENT("Activation 77 error"); break; } @@ -1089,9 +1089,9 @@ } } /* END: 05-June-2006, x0045876 (OMAPS00060424 - Header Toggle) */ - + winDelete (win); FREE_MEMORY ((void*) ListData, sizeof (ListWinInfo)); - + }