comparison src/ui3/bmi/mmiDialogs.h @ 421:6a4d9f47793e

src/ui3/bmi: file renames to make the case consistent
author Mychaela Falconia <falcon@freecalypso.org>
date Sun, 21 Jan 2018 03:28:53 +0000
parents src/ui3/bmi/MmiDialogs.h@e8ddbb0837ed
children
comparison
equal deleted inserted replaced
420:e8ddbb0837ed 421:6a4d9f47793e
1 //#error MmiDialogs includiert
2 #ifndef _DEF_MMI_DIALOGS_H_
3 #define _DEF_MMI_DIALOGS_H_
4 /*******************************************************************************
5
6 CONDAT (UK)
7
8 ********************************************************************************
9
10 This software product is the property of Condat (UK) Ltd and may not be
11 disclosed to any third party without the express permission of the owner.
12
13 ********************************************************************************
14
15 $Project name: Basic MMI
16 $Project code: BMI (6349)
17 $Module: MmiDialogs
18 $File: MmiDialogs.h
19 $Revision: 1.0
20
21 $Author: Condat(UK)
22 $Date: 25/10/00
23
24 ********************************************************************************
25
26 Description:
27
28 MMI Information dialogue handling.
29
30
31 ********************************************************************************
32 $History: MmiDialogs.h
33
34 Apr 03, 2007 ER: OMAPS00122561 x0pleela
35 Description: [ACI] Phone lock feature has to be supported by ACI
36 Solution: Phone Lock ER implementation
37
38 Mar 11, 2006 REF:DR:OMAPS00061467 x0035544
39 Description: 27.22.4.13.3 SET UP CALL (display of icons) fails.
40 Solution: added the new structure T_SAT_IconData and defined its variable at the structures T_dialog_info
41 and T_DISPLAY_DATA.
42
43 Feb 24, 2005 REF: CRR MMI-SPR-29102 xnkulkar
44 Description: The phone resets when user presses the ''End All' key while the SMSs are being deleted.
45 Solution: As the user has already confirmed that all SMS messages are to be deleted, ''End All' key
46 press is ignored till the delete operation is over.
47 xrashmic 08 Feb, 2005 MMI-SPR-27853
48 Moved the T_dialog_info structure from MmiDialogs.c to MmiDialogs.h
49
50
51 xrashmic 08 Feb, 2005 MMI-SPR-27853
52 Moved the T_dialog_info structure from MmiDialogs.c to MmiDialogs.h
53
54 Jun 04,2004 CRR:13601 xpradipg - SASKEN
55 Description: CFO interrogation display : Timer to long
56 Fix: Timer is enabled for the information dialog. It times out after 5 seconds from the last key
57 press.
58 25/10/00 Original Condat(UK) BMI version.
59
60 $End
61
62 *******************************************************************************/
63 #include "mfw_mfw.h"
64 /* SPR#1428 - SH - New Editor changes */
65 #ifdef NEW_EDITOR
66 #include "ATBCommon.h"
67 #include "ATBDisplay.h"
68 #include "ATBEditor.h"
69 #else /* NEW_EDITOR */
70 #include "mfw_edt.h"
71 #endif /* NEW_EDITOR */
72 #include "mfw_icn.h"
73
74 #include "MmiMmi.h" //for 'DialogsDummy'
75 #include "Mmiicons.h"
76
77 //#include "font_bitmaps.h" //For t_font_bitmap definition
78
79 #define TIMER_EXIT 0x0BB8 /* Default SMS timer period - 3 secs. */
80 /* Information dialogue display times. */
81 #define ONE_SECS 0x03E8 /* 1000 milliseconds. */
82 #define TWO_SECS 0x07D0 /* 2000 milliseconds. */
83 #define THREE_SECS 0x0BB8 /* 3000 milliseconds. */
84 #define FOUR_SECS (4000)
85 #define FIVE_SECS 0x1388 /* 5000 milliseconds. */
86 #define SIX_SECS (6000)
87 #define TEN_SECS 0x2710 /* 10000 milliseconds. */
88 #define TWO_MIN 0x1D4C0 /* 2 min */
89 #define FOREVER 0xFFFF /* Infinite time period. */
90
91 #define SMS_PROMPTX 5
92 #define SMS_PROMPTY 45
93 #define PROMPTX 7
94 #define PROMPTY 17
95 #define INFO_TEXTX 6
96 #define INFO_TEXTY 15
97 #define INFO_TEXTY2 26
98 #define INFO_TEXTY3 37
99 #define FRAMEX1 4
100 #define FRAMEY1 14
101 #define FRAMEX2 92
102 #define FRAMEY2 52
103
104 #define DLG_BORDER_VERTICAL_0 0x0000 //leave no border
105 #define DLG_BORDER_VERTICAL_1 0x0001 //leave 25% of bitmap to the left/right unused
106 #define DLG_BORDER_VERTICAL_2 0x0002
107 #define DLG_BORDER_VERTICAL_3 0x0003
108 #define DLG_BORDER_VERTICAL 0x0003
109
110
111 #define DLG_BORDER_HORIZONTAL_0 0x0000
112 #define DLG_BORDER_HORIZONTAL_1 0x0004 //leave 25% of bitmap to the top/bottom unused
113 #define DLG_BORDER_HORIZONTAL_2 0x0008
114 #define DLG_BORDER_HORIZONTAL_3 0x000C
115 #define DLG_BORDER_HORIZONTAL 0x000C
116
117 #define DLG_INFO_LAYOUT_BOTTOM 0x0010 //display data on bottom of bitmap
118 #define DLG_INFO_LAYOUT_TOP 0x0020 //display data at top of bitmap
119 #define DLG_INFO_LAYOUT_LEFT 0x0040
120 #define DLG_INFO_LAYOUT_RIGHT 0x0080
121 #define DLG_INFO_LAYOUT_CENTRE 0x0000
122 #define DLG_INFO_LAYOUT_FILL 0x00F0 //move data to edges of available area
123
124
125 /*
126 * common template definitions
127 */
128 typedef void (*T_DIALOG_FUNC)(T_MFW_HND win, USHORT event, USHORT value, void * parameter);
129
130
131 typedef struct
132 {
133 T_DIALOG_FUNC dialog;
134 void * data;
135 } T_MMI_CONTROL;
136
137 #define ALLOC_MEMORY mfwAlloc
138 #define FREE_MEMORY mfwFree
139
140 extern void mmi_send_event (T_MFW_HND win, USHORT event, USHORT value, void * parameter);
141
142 #define SEND_EVENT(w,e,v,p) mmi_send_event(w,e,v,p)
143
144 /*
145 * End of common template definitions
146 */
147
148 /*
149 * Definitions from common dialog function
150 */
151
152 //Berlin_UK int
153 /* kk 011102
154 typedef void (*T_VOID_FUNC)();
155 typedef short (*T_SHORT_FUNC)();
156 */
157 //Berlin_UK int
158 //GW-SPR#762 wrap definitions
159 #define WRAP_STRING_1 (0x01)
160 #define WRAP_STRING_2 (0x02)
161
162 #define DLG_TYPE_NORMAL 0x01
163 #define DLG_TYPE_POPUP 0x02
164 //#define T_BITMAP t_font_bitmap - defined in Mmiicons.h
165
166 //x0035544 Feb 07, 2006 DR:OMAPS00061467
167 #ifdef FF_MMI_SAT_ICON
168 typedef struct
169 {
170 /* SAT ICON DATA */
171 U8 width; /* SAT Icon width */
172 U8 height; /* SAT Icon height */
173 char* dst; /* Icon data */
174 BOOL selfExplanatory;
175 } T_SAT_IconData;
176 #endif
177
178 typedef struct
179 {
180 char * TextString;
181 BOOL SoftKeyStrings; // SH - TRUE if we are providing strings for softkeys rather than IDs
182 USHORT LeftSoftKey;
183 USHORT RightSoftKey;
184 char *LSKString; // SH - Text for customised softkey
185 char *RSKString; // SH - Text for customised softkey
186 ULONG Time;
187 T_MFW_EVENT KeyEvents;
188 USHORT TextId;
189 USHORT Identifier;
190 char * TextString2;
191 USHORT TextId2;
192 T_VOID_FUNC Callback;
193 UBYTE WrapStrings; // GW-SPR#762 - bits 0,1 set=wrap string 1,2
194 //GW Added colour definition
195 U32 displayCol;
196
197 int dlgType; //Type of popup
198 T_BITMAP *bgdBitmap; //Bitmap for background image
199 MfwRect *dlgPos; //Position of dialog
200 MfwIcnAttr* icon_array;
201 int current_icon;
202 UBYTE number_of_frames;
203 UBYTE current_frame;
204 T_MFW_HND animation_timer;
205 int anim_time;
206 //x0035544 Feb 07, 2006 DR:OMAPS00061467
207 #ifdef FF_MMI_SAT_ICON
208 T_SAT_IconData IconData; //Sat icon information
209 #endif
210 } T_DISPLAY_DATA;
211
212 //xrashmic 08 Feb, 2005 MMI-SPR-27853
213 //Moved the sturcture from mmidialog.c to mmidialogs.h, need this structure to update the
214 // dialog screen with the send progress information
215 typedef struct
216 {
217 T_MMI_CONTROL mmi_control;
218 T_MFW_HND parent_win;
219 T_MFW_HND info_win;
220 T_MFW_HND info_tim;
221 T_MFW_HND info_kbd;
222 T_MFW_HND info_kbd_long;
223 T_MFW_HND icon;
224 /*
225 * animation fields
226 */
227 UBYTE number_of_frames;
228 UBYTE current_frame;
229 T_MFW_HND anim_time;
230 MfwIcnAttr *icon_array;
231 MfwIcnAttr *current_icon;
232 T_MFW_HND animation_timer;
233
234 /*
235 * internal data
236 */
237 char *TextString;
238 USHORT LeftSoftKey;
239 USHORT RightSoftKey;
240 char *LSKString; // SH - text for left soft key
241 char *RSKString; // SH - text for right soft key
242 BOOL SoftKeyStrings; // SH - TRUE if using text rather than IDs for soft keys
243 UBYTE WrapStrings; // GW - bits 0,1 set=wrap string 1,2
244 ULONG Time;
245 T_MFW_EVENT KeyEvents;
246 USHORT TextId;
247 USHORT Identifier;
248 char * TextString2;
249 USHORT TextId2;
250 T_VOID_FUNC Callback;
251
252 U32 dlgCol;
253 U32 dlgType;
254 T_BITMAP *dlgBgdBitmap;
255 int dlgSkFormat;
256 //x0035544 Feb 07, 2006 DR:OMAPS00061467
257 #ifdef FF_MMI_SAT_ICON
258 T_SAT_IconData IconData; //Sat icon information
259 #endif
260 } T_dialog_info;
261
262 typedef struct
263 {
264 USHORT TitleTextId;
265 char * TextString;
266 #ifdef NEW_EDITOR /* SPR#1428 - SH - New Editor changes */
267 T_ED_ATTR EditorAttrScroll;
268 #else /* NEW_EDITOR */
269 MfwEdtAttr EdtAttrScroll;
270 #endif /* NEW_EDITOR */
271 USHORT LeftSoftKey;
272 USHORT RightSoftKey;
273 ULONG Time;
274 T_MFW_EVENT KeyEvents;
275 USHORT Identifier;
276 T_VOID_FUNC Callback;
277 } T_SCROLL_DISPLAY_DATA;
278 /*
279 * Function expected from Info Dialog
280 */
281 #define INFO_TIMEOUT 1
282 #define INFO_KCD_LEFT 2
283 #define INFO_KCD_RIGHT 3
284 #define INFO_KCD_HUP 4
285 #define INFO_KCD_UP 5
286 #define INFO_KCD_DOWN 6
287 #define INFO_KCD_0_9 7
288 #define INFO_KCD_ALL 8
289 #define INFO_KCD_CLEAR 9
290 #define INFO_KCD_OFFHOOK 10
291 #define INFO_KCD_CALL 11
292
293 #define PROMPT_LENGTH 16
294
295 //x0pleela 02 Apr, 2007 ER: OMAPS00122561
296 #ifdef FF_PHONE_LOCK
297
298 T_MFW_HND phlock_info_dialog (T_MFW_HND parent_win,T_DISPLAY_DATA * display_info);
299 #endif //FF_PHONE_LOCK
300
301 extern T_MFW_HND info_dialog (T_MFW_HND parent_win,
302 T_DISPLAY_DATA * display_info);
303
304 T_MFW_HND info_dialog_softkeystrings (T_MFW_HND parent_win, T_DISPLAY_DATA * display_info);
305
306 extern T_MFW_HND mmi_dialog_information_screen(T_MFW_HND parent_win, int TxtId,char* text,
307 T_VOID_FUNC call_back, USHORT identifier);
308 extern T_MFW_HND mmi_dialog_information_screen_forever(MfwHnd win,int TextId, char* TextStr, int colour);
309
310 void dlg_zeroDisplayData( T_DISPLAY_DATA *displayInfo);
311 void dlg_initDisplayData_TextId( T_DISPLAY_DATA *displayInfo, int lsk, int rsk, int str1, int str2, int colId);
312 void dlg_initDisplayData_TextStr( T_DISPLAY_DATA *displayInfo, int lsk, int rsk,char *str1, char *str2, int colId);
313 void dlg_initDisplayData_events( T_DISPLAY_DATA *displayInfo, T_VOID_FUNC callback, int timer, T_MFW_EVENT keyEvents);
314
315 /*GB*/
316 void mmi_dialogs_insert_icon (T_MFW_HND win_dialog ,MfwIcnAttr *icon);
317 void mmi_dialogs_insert_animation (T_MFW_HND win_dialog ,S32 anim_time ,MfwIcnAttr *icon ,UBYTE number_of_frames);
318
319 void mmi_dialogs_insert_animation_new (T_DISPLAY_DATA *animateInfo , S32 anim_time ,MfwIcnAttr* icon ,UBYTE number_of_frames);
320 //Jun 04,2004 CRR:13601 xpradipg - SASKEN
321 //declaration for the function definition
322 extern void InfoDialogTimRestart(T_MFW_HND win);
323
324 // Feb 24, 2005 REF: CRR MMI-SPR-29102 xnkulkar
325 // Prototype declaration for the function 'mmi_dialog_information_screen_delete_all()'
326 T_MFW_HND mmi_dialog_information_screen_delete_all(MfwHnd win,int TextId, char* TextStr, int colour);
327
328 /*
329 * Internal events
330 */
331 #define DIALOG_INIT 200
332 #define DIALOG_DESTROY 201
333
334 // c018 rsa
335 typedef int DisplayData; // ??? rsa needed!?
336 typedef int DialogInfo; // ??? rsa needed!?
337
338 typedef enum
339 {
340 DIALOGS_REASON_NULL = DialogsDummy,
341 DIALOGS_REASON_TIMER,
342 DIALOGS_REASON_LEFTKEY,
343 DIALOGS_REASON_RIGHTKEY,
344 DIALOGS_REASON_CLEARKEY
345 }DialogReasons;
346
347 // end c018 rsa
348 #endif
349
350
351