wgui.h
上传用户:lqx1163
上传日期:2014-08-13
资源大小:9183k
文件大小:33k
源码类别:

MTK

开发平台:

C/C++

  1. /*****************************************************************************
  2. *  Copyright Statement:
  3. *  --------------------
  4. *  This software is protected by Copyright and the information contained
  5. *  herein is confidential. The software may not be copied and the information
  6. *  contained herein may not be used or disclosed except with the written
  7. *  permission of MediaTek Inc. (C) 2005
  8. *
  9. *  BY OPENING THIS FILE, BUYER HEREBY UNEQUIVOCALLY ACKNOWLEDGES AND AGREES
  10. *  THAT THE SOFTWARE/FIRMWARE AND ITS DOCUMENTATIONS ("MEDIATEK SOFTWARE")
  11. *  RECEIVED FROM MEDIATEK AND/OR ITS REPRESENTATIVES ARE PROVIDED TO BUYER ON
  12. *  AN "AS-IS" BASIS ONLY. MEDIATEK EXPRESSLY DISCLAIMS ANY AND ALL WARRANTIES,
  13. *  EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE IMPLIED WARRANTIES OF
  14. *  MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE OR NONINFRINGEMENT.
  15. *  NEITHER DOES MEDIATEK PROVIDE ANY WARRANTY WHATSOEVER WITH RESPECT TO THE
  16. *  SOFTWARE OF ANY THIRD PARTY WHICH MAY BE USED BY, INCORPORATED IN, OR
  17. *  SUPPLIED WITH THE MEDIATEK SOFTWARE, AND BUYER AGREES TO LOOK ONLY TO SUCH
  18. *  THIRD PARTY FOR ANY WARRANTY CLAIM RELATING THERETO. MEDIATEK SHALL ALSO
  19. *  NOT BE RESPONSIBLE FOR ANY MEDIATEK SOFTWARE RELEASES MADE TO BUYER'S
  20. *  SPECIFICATION OR TO CONFORM TO A PARTICULAR STANDARD OR OPEN FORUM.
  21. *
  22. *  BUYER'S SOLE AND EXCLUSIVE REMEDY AND MEDIATEK'S ENTIRE AND CUMULATIVE
  23. *  LIABILITY WITH RESPECT TO THE MEDIATEK SOFTWARE RELEASED HEREUNDER WILL BE,
  24. *  AT MEDIATEK'S OPTION, TO REVISE OR REPLACE THE MEDIATEK SOFTWARE AT ISSUE,
  25. *  OR REFUND ANY SOFTWARE LICENSE FEES OR SERVICE CHARGE PAID BY BUYER TO
  26. *  MEDIATEK FOR SUCH MEDIATEK SOFTWARE AT ISSUE. 
  27. *
  28. *  THE TRANSACTION CONTEMPLATED HEREUNDER SHALL BE CONSTRUED IN ACCORDANCE
  29. *  WITH THE LAWS OF THE STATE OF CALIFORNIA, USA, EXCLUDING ITS CONFLICT OF
  30. *  LAWS PRINCIPLES.  ANY DISPUTES, CONTROVERSIES OR CLAIMS ARISING THEREOF AND
  31. *  RELATED THERETO SHALL BE SETTLED BY ARBITRATION IN SAN FRANCISCO, CA, UNDER
  32. *  THE RULES OF THE INTERNATIONAL CHAMBER OF COMMERCE (ICC).
  33. *
  34. *****************************************************************************/
  35. /*******************************************************************************
  36.  * Filename:
  37.  * ---------
  38.  *  wgui.h
  39.  *
  40.  * Project:
  41.  * --------
  42.  *   MAUI
  43.  *
  44.  * Description:
  45.  * ------------
  46.  *  Common definitions for GUI.
  47.  *
  48.  *  Author:
  49.  * -------
  50.  *  Leo Hu (MTK00563)
  51.  *
  52.  *==============================================================================
  53.  *  HISTORY
  54.  * Below this line, this part is controlled by PVCS VM. DO NOT MODIFY!! 
  55.  *------------------------------------------------------------------------------
  56.  * removed!
  57.  *
  58.  * removed!
  59.  * removed!
  60.  * removed!
  61.  *
  62.  * removed!
  63.  * removed!
  64.  * removed!
  65.  *
  66.  * removed!
  67.  * removed!
  68.  * removed!
  69.  *
  70.  * removed!
  71.  * removed!
  72.  * removed!
  73.  *
  74.  * removed!
  75.  * removed!
  76.  * removed!
  77.  *
  78.  * removed!
  79.  * removed!
  80.  * removed!
  81.  *
  82.  * removed!
  83.  * removed!
  84.  * removed!
  85.  * removed!
  86.  *
  87.  * removed!
  88.  * removed!
  89.  * removed!
  90.  *
  91.  * removed!
  92.  * removed!
  93.  * removed!
  94.  *
  95.  * removed!
  96.  * removed!
  97.  * removed!
  98.  *
  99.  * removed!
  100.  * removed!
  101.  * removed!
  102.  *
  103.  * removed!
  104.  * removed!
  105.  * removed!
  106.  *
  107.  * removed!
  108.  * removed!
  109.  * removed!
  110.  *
  111.  * removed!
  112.  * removed!
  113.  * removed!
  114.  *
  115.  * removed!
  116.  * removed!
  117.  * removed!
  118.  *
  119.  * removed!
  120.  * removed!
  121.  * removed!
  122.  *
  123.  * removed!
  124.  * removed!
  125.  * removed!
  126.  *
  127.  * removed!
  128.  * removed!
  129.  * removed!
  130.  *
  131.  * removed!
  132.  * removed!
  133.  * removed!
  134.  *
  135.  * removed!
  136.  * removed!
  137.  * removed!
  138.  *
  139.  * removed!
  140.  * removed!
  141.  * removed!
  142.  *
  143.  * removed!
  144.  * removed!
  145.  * removed!
  146.  *
  147.  * removed!
  148.  * removed!
  149.  * removed!
  150.  *
  151.  * removed!
  152.  * removed!
  153.  * removed!
  154.  *
  155.  * removed!
  156.  * removed!
  157.  * removed!
  158.  *
  159.  * removed!
  160.  * removed!
  161.  * removed!
  162.  *
  163.  * removed!
  164.  * removed!
  165.  * removed!
  166.  *
  167.  * removed!
  168.  * removed!
  169.  * removed!
  170.  *
  171.  * removed!
  172.  * removed!
  173.  * removed!
  174.  *
  175.  * removed!
  176.  * removed!
  177.  * removed!
  178.  *
  179.  * removed!
  180.  * removed!
  181.  * removed!
  182.  *
  183.  * removed!
  184.  * removed!
  185.  * removed!
  186.  *
  187.  * removed!
  188.  * removed!
  189.  * removed!
  190.  *
  191.  * removed!
  192.  * removed!
  193.  * removed!
  194.  *
  195.  *------------------------------------------------------------------------------
  196.  * Upper this line, this part is controlled by PVCS VM. DO NOT MODIFY!! 
  197.  *==============================================================================
  198.  *******************************************************************************/
  199. /**
  200.  * Copyright Notice
  201.  * (c) 2002 - 2003, Pixtel Communications, Inc., 1489 43rd Ave. W.,
  202.  * Vancouver, B.C. V6M 4K8 Canada. All Rights Reserved.
  203.  *  (It is illegal to remove this copyright notice from this software or any
  204.  *  portion of it)
  205.  */
  206.  
  207. /**********************************************************************************
  208. Filename: wgui.h
  209. Author: manju
  210. Date Created: August-07-2002
  211. Contains: PixTel UI wrapper routines header
  212. Contains several parts and has been split to multiple
  213. code files. See other files named wgui_*.c and wgui_*.h
  214. This file contains common functions and data (prototypes only).
  215. **********************************************************************************/
  216. #ifndef __WGUI_H__
  217. #define __WGUI_H__
  218. #include "MMI_features.h"
  219. #include "EventsGprot.h"
  220. #include "globalconstants.h"
  221. #include "DateTimeType.h"
  222. #include "gui.h"
  223. #include "gui_buttons.h"
  224. #include "gui_scrollbars.h"
  225. #include "gui_inputs.h"
  226. #include "gui_generic_menuitems.h"
  227. #include "gui_fixed_menuitems.h"
  228. #include "gui_generic_menus.h"
  229. #include "gui_fixed_menus.h"
  230. #include "gui_windows.h"
  231. #include "gui_dynamic_menus.h"
  232. #include "wgui_draw_manager.h"
  233. /*
  234. ** Typedef
  235. */
  236. typedef S32 MMI_key_code_type;
  237. typedef S32 MMI_key_event_type;
  238. typedef U16 UI_string_ID_type;
  239. typedef U16 UI_image_ID_type;
  240. typedef U16 UI_audio_ID_type;//101205 audio resource Calvin add
  241. typedef MYTIME UI_time;
  242. /*
  243. ** Define
  244. */
  245. #define KEYBOARD_KEY_DOWN 256
  246. #define KEYBOARD_KEY_UP 257
  247. #define STRING_ID_NULL 0
  248. #define IMAGE_ID_NULL 0
  249. #define MMI_BG_GREYSCALE_VALUE (40)//102605 greyscale Calvin modified
  250. #define MMI_BG_GREYSCALE_BLACK_VALUE (40)
  251. #define MMI_EDITOR_BG_OPACITY             (current_MMI_theme->bg_opacity_low)
  252. /* Settings */
  253. /* Timeouts: All in milliseconds */
  254. #define MMI_MENU_SHORTCUT_TIMEOUT (600)
  255. #define MMI_MULTITAP_TIMEOUT (600)
  256. /* Dimensions and co-ordinates */
  257. /* All values in pixels */
  258. #define MMI_SUBLCD_TITLE_HEIGHT 15
  259. /* UI_STYLE_1 for 128x128 screen */
  260. #ifdef __MMI_MAINLCD_128X128__
  261. //START VIJAY PMT 20050930
  262. #if defined( __MMI_UI_SMALL_SCREEN_SUPPORT__)
  263. #define MMI_SMALL_SCREEN_X_OFFSET (9)
  264. #define MMI_SMALL_SCREEN_Y_OFFSET (9)
  265. #define MMI_SMALL_LIST_LEFT_OFFSET 2
  266. #define MMI_SMALL_LIST_SCREEN_WIDTH ((MAIN_LCD_DEVICE_WIDTH*3)/4)
  267. #endif /* UI_SMALL_CATEGORY_EDITOR*/
  268. //END VIJAY PMT 20050930
  269. #ifdef __MMI_UI_DALMATIAN_STATUSBAR__
  270. #define MMI_STATUS_BAR_WIDTH (76)
  271.    #define MMI_STATUS_BAR_HEIGHT (20)
  272. #define MMI_SINGLE_STATUS_BAR_HEIGHT (16)
  273. #else
  274.    #define MMI_STATUS_BAR_HEIGHT (16)
  275. #endif
  276.         #define MMI_TITLE_PADDING                           (0)
  277. #define MMI_TITLE_X (0)
  278. #define MMI_TITLE_Y (0)
  279. #define MMI_TITLE_WIDTH (MAIN_LCD_DEVICE_WIDTH)
  280. #define MMI_TITLE_HEIGHT (18)
  281. #define MMI_CONTENT_X (0)
  282. #define MMI_CONTENT_Y (MMI_TITLE_HEIGHT)
  283. #define MMI_CONTENT_WIDTH (MAIN_LCD_DEVICE_WIDTH)
  284. #define MMI_CONTENT_HEIGHT (MAIN_LCD_DEVICE_HEIGHT-MMI_BUTTON_BAR_HEIGHT-MMI_TITLE_HEIGHT)
  285. #ifdef __MMI_UI_DALMATIAN_SOFTKEYS__
  286. #define MMI_BUTTON_BAR_HEIGHT (20)
  287. #define MMI_SOFTKEY_WIDTH (74)
  288. #define MMI_SOFTKEY_HEIGHT (16)
  289. #define BAR_CONTENT_GAP (2)
  290. #else
  291. #define MMI_BUTTON_BAR_HEIGHT (18)
  292. #define MMI_SOFTKEY_WIDTH (50)
  293. #define MMI_SOFTKEY_HEIGHT (18)
  294. #endif
  295. #define MMI_POP_UP_DIALOG_WIDTH (MAIN_LCD_DEVICE_WIDTH-20)
  296. #define MMI_POP_UP_DIALOG_HEIGHT (MAIN_LCD_DEVICE_HEIGHT-MMI_BUTTON_BAR_HEIGHT-MMI_TITLE_HEIGHT-6)
  297. #define MMI_POP_UP_DIALOG_X ((MAIN_LCD_DEVICE_WIDTH>>1)-(MMI_POP_UP_DIALOG_WIDTH>>1))
  298. #define MMI_POP_UP_DIALOG_Y (MMI_TITLE_HEIGHT+3)
  299. #define MMI_POP_UP_DIALOG_FULL_HEIGHT (MAIN_LCD_DEVICE_HEIGHT-(MMI_BUTTON_BAR_HEIGHT>>1)-MMI_TITLE_HEIGHT)
  300. #if defined(__MMI_UI_DALMATIAN_STATUSBAR__) || defined(__MMI_UI_DALMATIAN_SOFTKEYS__)
  301. #define MMI_MENUITEM_HEIGHT (17)
  302. #define MMI_ICONTEXT_MENUITEM_HEIGHT (17)
  303. #define MMI_INLINE_EDIT_MENUITEM_HEIGHT (17)
  304. #else
  305. #define MMI_MENUITEM_HEIGHT (18)
  306. #define MMI_ICONTEXT_MENUITEM_HEIGHT (18)
  307. #define MMI_INLINE_EDIT_MENUITEM_HEIGHT (18)
  308. #endif
  309. #define MMI_MULTIROW_MENUITEM_HEIGHT (39)
  310. //PMT VIKAS START 20051217
  311. #ifdef __MMI_UI_TAB_PANE__
  312. #define MMI_TAB_HEIGHT (18)
  313. #endif
  314. //PMT VIKAS END 20051217
  315. #if 0
  316. #ifdef __MMI_EDITABLE_AUDIO_EQUALIZER__
  317. /* under construction !*/
  318. /* under construction !*/
  319. /* under construction !*/
  320. /* under construction !*/
  321. /* under construction !*/
  322. /* under construction !*/
  323. /* under construction !*/
  324. #endif
  325. #endif
  326. /* UI_STYLE_2 for 128x160 screen */
  327. #elif defined __MMI_MAINLCD_128X160__
  328. //START VIJAY PMT 20050930
  329. #if defined( __MMI_UI_SMALL_SCREEN_SUPPORT__)
  330. #define MMI_SMALL_SCREEN_X_OFFSET (9)
  331. #define MMI_SMALL_SCREEN_Y_OFFSET (11)
  332. #define MMI_SMALL_LIST_LEFT_OFFSET 2
  333. #define MMI_SMALL_LIST_SCREEN_WIDTH ((MAIN_LCD_DEVICE_WIDTH*3)/4)
  334. #endif /* UI_SMALL_CATEGORY_EDITOR*/
  335. //END VIJAY PMT 20050930
  336. #if defined( __MMI_UI_DALMATIAN_STATUSBAR__)
  337. #define MMI_STATUS_BAR_WIDTH (76)
  338.     #define MMI_STATUS_BAR_HEIGHT (22)
  339. #define MMI_SINGLE_STATUS_BAR_HEIGHT (18)
  340. #define MMI_TITLE_HEIGHT (22)
  341. #else
  342. #define MMI_TITLE_HEIGHT (20)
  343. #define MMI_STATUS_BAR_HEIGHT (18)
  344. #endif
  345.         #define MMI_TITLE_PADDING                           (0)
  346. #define MMI_TITLE_X (0)
  347. #define MMI_TITLE_Y (0)
  348. #define MMI_TITLE_WIDTH (MAIN_LCD_DEVICE_WIDTH)
  349. #define MMI_CONTENT_X (0)
  350. #define MMI_CONTENT_Y (MMI_TITLE_HEIGHT)
  351. #define MMI_CONTENT_WIDTH (MAIN_LCD_DEVICE_WIDTH)
  352. #define MMI_CONTENT_HEIGHT (MAIN_LCD_DEVICE_HEIGHT-MMI_BUTTON_BAR_HEIGHT-MMI_TITLE_HEIGHT)
  353. #ifdef __MMI_UI_DALMATIAN_SOFTKEYS__
  354. #define MMI_BUTTON_BAR_HEIGHT (22)
  355. #define MMI_SOFTKEY_WIDTH (74)
  356. #define MMI_SOFTKEY_HEIGHT (18)
  357. #define BAR_CONTENT_GAP (2)
  358. #else
  359. #define MMI_BUTTON_BAR_HEIGHT (20)
  360. #define MMI_SOFTKEY_WIDTH (50)
  361. #define MMI_SOFTKEY_HEIGHT (19)
  362. #endif
  363. #define MMI_POP_UP_DIALOG_WIDTH (MAIN_LCD_DEVICE_WIDTH-20)
  364. #define MMI_POP_UP_DIALOG_HEIGHT (MAIN_LCD_DEVICE_HEIGHT-MMI_BUTTON_BAR_HEIGHT-MMI_TITLE_HEIGHT-4)
  365. #define MMI_POP_UP_DIALOG_X ((MAIN_LCD_DEVICE_WIDTH>>1)-(MMI_POP_UP_DIALOG_WIDTH>>1))
  366. #define MMI_POP_UP_DIALOG_Y (MMI_TITLE_HEIGHT+2)
  367. #define MMI_POP_UP_DIALOG_FULL_HEIGHT (MAIN_LCD_DEVICE_HEIGHT-(MMI_BUTTON_BAR_HEIGHT>>1)-MMI_TITLE_HEIGHT+2)
  368. #define MMI_MENUITEM_HEIGHT (17)
  369. #define MMI_ICONTEXT_MENUITEM_HEIGHT (17)
  370. #define MMI_INLINE_EDIT_MENUITEM_HEIGHT (17)
  371. #define MMI_MULTIROW_MENUITEM_HEIGHT (39)
  372. //PMT VIKAS START 20051217
  373. #ifdef __MMI_UI_TAB_PANE__
  374. #define MMI_TAB_HEIGHT (20)
  375. #endif
  376. //PMT VIKAS END 20051217
  377. #if 0
  378. #ifdef __MMI_EDITABLE_AUDIO_EQUALIZER__
  379. /* under construction !*/
  380. /* under construction !*/
  381. /* under construction !*/
  382. /* under construction !*/
  383. /* under construction !*/
  384. /* under construction !*/
  385. /* under construction !*/
  386. #endif
  387. #endif
  388. /* UI_STYLE_3 for 176x220 screen */
  389. #elif defined __MMI_MAINLCD_176X220__
  390. //START VIJAY PMT 20050930
  391. #if defined( __MMI_UI_SMALL_SCREEN_SUPPORT__)
  392. #define MMI_SMALL_SCREEN_X_OFFSET (12)
  393. #define MMI_SMALL_SCREEN_Y_OFFSET (15)
  394. #define MMI_SMALL_LIST_LEFT_OFFSET 2
  395. #define MMI_SMALL_LIST_SCREEN_WIDTH ((MAIN_LCD_DEVICE_WIDTH*3)/4)
  396. #endif /* UI_SMALL_CATEGORY_EDITOR*/
  397. //END VIJAY PMT 20050930
  398. #if defined(__MMI_UI_TECHNO_IDLESCREEN_BAR__)
  399. #define MMI_IDLESCREEN_BAR_HEIGHT (60)
  400. #define MMI_SIGNAL_X (0)
  401. #define MMI_SIGNAL_Y (0)
  402. #ifdef __MMI_UI_TECHNO_STATUS_ICON__
  403. #define MMI_SIGNAL_WIDTH (12)
  404. #else
  405. #define MMI_SIGNAL_WIDTH (5)
  406. #endif
  407. #define ANALOG_BACKGROUND_X (MMI_SIGNAL_X + MMI_SIGNAL_WIDTH)
  408. #define ANALOG_BACKGROUND_Y (MMI_STATUS_BAR_HEIGHT)
  409. #define ANALOG_BACKGROUND_WIDTH (60)
  410. #endif
  411. //PMT VIKAS START 20051202
  412.    #if defined( __MMI_UI_DALMATIAN_STATUSBAR__)
  413. #define MMI_STATUS_BAR_WIDTH (104)
  414.     #define MMI_STATUS_BAR_HEIGHT (23)
  415. #define MMI_SINGLE_STATUS_BAR_HEIGHT (19)
  416.    #else
  417. #define MMI_STATUS_BAR_HEIGHT (18)
  418.    #endif
  419. //PMT VIKAS END 20051202
  420.         #define MMI_TITLE_PADDING                           (0)
  421. #define MMI_TITLE_X (0)
  422. #define MMI_TITLE_Y (MMI_STATUS_BAR_HEIGHT)
  423. #define MMI_TITLE_WIDTH (MAIN_LCD_DEVICE_WIDTH)
  424. #define MMI_TITLE_HEIGHT (24)
  425. #define MMI_CONTENT_X (0)
  426. #define MMI_CONTENT_Y (MMI_TITLE_Y+MMI_TITLE_HEIGHT)
  427. #define MMI_CONTENT_WIDTH (MAIN_LCD_DEVICE_WIDTH)
  428. #define MMI_CONTENT_HEIGHT (MAIN_LCD_DEVICE_HEIGHT-MMI_BUTTON_BAR_HEIGHT-MMI_TITLE_HEIGHT-MMI_STATUS_BAR_HEIGHT)
  429. #if defined(__MMI_UI_TECHNO_SOFTKEYS__)
  430. #define MMI_SOFTKEY_WIDTH (75)
  431.    #define MMI_BUTTON_BAR_HEIGHT (20)
  432. #define MMI_SOFTKEY_HEIGHT (20)
  433. #elif defined( __MMI_UI_DALMATIAN_SOFTKEYS__)
  434. #define MMI_BUTTON_BAR_HEIGHT (24)
  435. #define MMI_SOFTKEY_WIDTH (104)
  436. #define MMI_SOFTKEY_HEIGHT (19)
  437. #else
  438. #define MMI_BUTTON_BAR_HEIGHT (20)
  439. #define MMI_SOFTKEY_WIDTH (70)
  440. #define MMI_SOFTKEY_HEIGHT (20)
  441. #endif
  442. #if defined(__MMI_UI_DALMATIAN_STATUSBAR__) || (defined __MMI_UI_DALMATIAN_SOFTKEYS__)
  443.      #define BAR_CONTENT_GAP (1)
  444. #endif
  445. #define MMI_POP_UP_DIALOG_WIDTH (MAIN_LCD_DEVICE_WIDTH-40)
  446. #define MMI_POP_UP_DIALOG_HEIGHT (MAIN_LCD_DEVICE_HEIGHT-MMI_BUTTON_BAR_HEIGHT-MMI_TITLE_HEIGHT-MMI_TITLE_Y-20)
  447. #define MMI_POP_UP_DIALOG_X ((MAIN_LCD_DEVICE_WIDTH>>1)-(MMI_POP_UP_DIALOG_WIDTH>>1))
  448. #define MMI_POP_UP_DIALOG_Y (MMI_TITLE_Y+(MMI_TITLE_HEIGHT+10))
  449. #define MMI_POP_UP_DIALOG_FULL_HEIGHT (MMI_POP_UP_DIALOG_HEIGHT)
  450. #if defined(__MMI_UI_DALMATIAN_STATUSBAR__) || defined(__MMI_UI_DALMATIAN_SOFTKEYS__)
  451. #define MMI_MENUITEM_HEIGHT (20)
  452. #define MMI_ICONTEXT_MENUITEM_HEIGHT (20)
  453. #define MMI_INLINE_EDIT_MENUITEM_HEIGHT (20)
  454. #else
  455. #define MMI_MENUITEM_HEIGHT (22)
  456. #define MMI_ICONTEXT_MENUITEM_HEIGHT (22)
  457. #define MMI_INLINE_EDIT_MENUITEM_HEIGHT (22)
  458. #endif
  459. #define MMI_MULTIROW_MENUITEM_HEIGHT (39)
  460. #if 0
  461. #ifdef __MMI_EDITABLE_AUDIO_EQUALIZER__
  462. /* under construction !*/
  463. /* under construction !*/
  464. /* under construction !*/
  465. /* under construction !*/
  466. /* under construction !*/
  467. /* under construction !*/
  468. /* under construction !*/
  469. #endif //__MMI_EDITABLE_AUDIO_EQUALIZER__
  470. #endif
  471. #define MMI_ROTATED_LCD_WIDTH (MAIN_LCD_DEVICE_HEIGHT)
  472. #define MMI_ROTATED_LCD_HEIGHT (MAIN_LCD_DEVICE_WIDTH)
  473. #define MMI_ROTATED_TITLE_WIDTH (155)
  474. #define MMI_ROTATED_TITLE_HEIGHT (MMI_TITLE_HEIGHT)
  475. #define MMI_ROTATED_CONTENT_WIDTH (155)
  476. #define MMI_ROTATED_CONTENT_HEIGHT (MMI_CONTENT_HEIGHT-MMI_MENUITEM_HEIGHT)
  477. #define MMI_ROTATED_TITLE_X (10)
  478. #define MMI_ROTATED_TITLE_Y ((MMI_ROTATED_LCD_HEIGHT -  MMI_ROTATED_CONTENT_HEIGHT - MMI_ROTATED_TITLE_HEIGHT)/2)
  479. #define MMI_ROTATED_CONTENT_X (10)
  480. #define MMI_ROTATED_CONTENT_Y (MMI_ROTATED_TITLE_Y + MMI_ROTATED_TITLE_HEIGHT)
  481. #define MMI_ROTATED_POP_UP_DIALOG_X (MMI_ROTATED_CONTENT_X + 7)
  482. #define MMI_ROTATED_POP_UP_DIALOG_Y (MMI_ROTATED_TITLE_Y + MMI_ROTATED_TITLE_HEIGHT + 7)
  483. #define MMI_ROTATED_POP_UP_DIALOG_WIDTH (MMI_ROTATED_CONTENT_WIDTH - 15)
  484. #define MMI_ROTATED_POP_UP_DIALOG_HEIGHT (MMI_ROTATED_LCD_HEIGHT - MMI_ROTATED_POP_UP_DIALOG_Y - 20)
  485. #define MMI_ROTATED_POP_UP_DIALOG_FULL_HEIGHT (MMI_ROTATED_POP_UP_DIALOG_HEIGHT)
  486. #define MMI_ROTATED_BUTTON_BAR_X (MMI_ROTATED_CONTENT_X + MMI_ROTATED_CONTENT_WIDTH + 3 /* leave space for border frame */)
  487. #define MMI_ROTATED_BUTTON_BAR_Y (0)
  488. #define MMI_ROTATED_BUTTON_BAR_WIDTH (MMI_ROTATED_LCD_WIDTH - MMI_ROTATED_CONTENT_X - MMI_ROTATED_CONTENT_WIDTH - 3)
  489. #define MMI_ROTATED_BUTTON_BAR_HEIGHT (MMI_ROTATED_LCD_HEIGHT)
  490. #define MMI_ROTATED_SOFTKEY_WIDTH (MMI_ROTATED_BUTTON_BAR_WIDTH)
  491. #define MMI_ROTATED_SOFTKEY_HEIGHT (MMI_SOFTKEY_HEIGHT)
  492. //PMT VIKAS START 20051217
  493. #ifdef __MMI_UI_TAB_PANE__
  494. #define MMI_TAB_HEIGHT (22)
  495. #endif
  496. //PMT VIKAS END 20051217
  497. /* UI_STYLE_4 for 240x320 screen */
  498. #elif defined __MMI_MAINLCD_240X320__
  499. //START VIJAY PMT 20050930
  500. #if defined( __MMI_UI_SMALL_SCREEN_SUPPORT__)
  501. #define MMI_SMALL_SCREEN_X_OFFSET (16)
  502. #define MMI_SMALL_SCREEN_Y_OFFSET (22)
  503. #define MMI_SMALL_LIST_LEFT_OFFSET 2
  504. #define MMI_SMALL_LIST_SCREEN_WIDTH ((MAIN_LCD_DEVICE_WIDTH*3)/4)
  505. #endif /* UI_SMALL_CATEGORY_EDITOR*/
  506. //END VIJAY PMT 20050930
  507. #if defined(__MMI_UI_TECHNO_IDLESCREEN_BAR__)
  508. #define MMI_IDLESCREEN_BAR_HEIGHT (80)
  509. #define MMI_SIGNAL_X (0)
  510. #define MMI_SIGNAL_Y (0)
  511. #ifdef __MMI_UI_TECHNO_STATUS_ICON__
  512. #define MMI_SIGNAL_WIDTH (20)
  513. #else
  514. #define MMI_SIGNAL_WIDTH (5)
  515. #endif
  516. #define ANALOG_BACKGROUND_X (MMI_SIGNAL_X + MMI_SIGNAL_WIDTH)
  517. #define ANALOG_BACKGROUND_Y (MMI_STATUS_BAR_HEIGHT)
  518. #define ANALOG_BACKGROUND_WIDTH (80)
  519. #endif
  520. #if defined( __MMI_UI_DALMATIAN_STATUSBAR__)
  521. #define MMI_STATUS_BAR_WIDTH (135)
  522.     #define MMI_STATUS_BAR_HEIGHT (28)
  523. #define MMI_SINGLE_STATUS_BAR_HEIGHT (24)
  524. #else
  525. #define MMI_STATUS_BAR_HEIGHT (18)
  526. #endif
  527.         #define MMI_TITLE_PADDING                           (4)
  528. #define MMI_TITLE_X (0)
  529. #define MMI_TITLE_Y (MMI_STATUS_BAR_HEIGHT)
  530. #define MMI_TITLE_WIDTH (MAIN_LCD_DEVICE_WIDTH)
  531. #define MMI_CONTENT_X (0)
  532. #define MMI_CONTENT_Y (MMI_TITLE_Y+MMI_TITLE_HEIGHT)
  533. #define MMI_CONTENT_WIDTH (MAIN_LCD_DEVICE_WIDTH)
  534. #define MMI_CONTENT_HEIGHT (MAIN_LCD_DEVICE_HEIGHT-MMI_BUTTON_BAR_HEIGHT-MMI_TITLE_HEIGHT-MMI_STATUS_BAR_HEIGHT)
  535. #if defined(__MMI_UI_DALMATIAN_STATUSBAR__) || (defined __MMI_UI_DALMATIAN_SOFTKEYS__)
  536. #define MMI_BUTTON_BAR_HEIGHT (28)
  537. #define MMI_SOFTKEY_WIDTH (135)
  538. #define MMI_SOFTKEY_HEIGHT (24)
  539. #define MMI_TITLE_HEIGHT (40)
  540. #define BAR_CONTENT_GAP (1)
  541. #else
  542. #define MMI_BUTTON_BAR_HEIGHT (24)
  543. //KP Jerry modify on 2007-3-30 start
  544. #ifdef __MMI_24X24_CHINESE_FONT__
  545. #define MMI_SOFTKEY_WIDTH (80)
  546. #else
  547. #define MMI_SOFTKEY_WIDTH (70)
  548. #endif
  549. //KP Jerry modify on 2007-3-30 end
  550. #define MMI_SOFTKEY_HEIGHT (24)
  551. #define MMI_TITLE_HEIGHT (58)
  552. #endif
  553. #define MMI_POP_UP_DIALOG_WIDTH (MAIN_LCD_DEVICE_WIDTH-24)
  554. #define MMI_POP_UP_DIALOG_HEIGHT (MAIN_LCD_DEVICE_HEIGHT-MMI_BUTTON_BAR_HEIGHT-MMI_TITLE_HEIGHT-MMI_TITLE_Y-50)
  555. #define MMI_POP_UP_DIALOG_X ((MAIN_LCD_DEVICE_WIDTH>>1)-(MMI_POP_UP_DIALOG_WIDTH>>1))
  556. #define MMI_POP_UP_DIALOG_Y (MMI_TITLE_Y+(MMI_TITLE_HEIGHT+20))
  557. #define MMI_POP_UP_DIALOG_FULL_HEIGHT MMI_POP_UP_DIALOG_HEIGHT
  558. #if defined(__MMI_UI_DALMATIAN_STATUSBAR__) || (defined __MMI_UI_DALMATIAN_SOFTKEYS__)
  559. #define MMI_MENUITEM_HEIGHT (29)
  560. #define MMI_ICONTEXT_MENUITEM_HEIGHT (29)
  561. #define MMI_INLINE_EDIT_MENUITEM_HEIGHT (29)
  562. #else
  563. #define MMI_MENUITEM_HEIGHT (30)
  564. #define MMI_ICONTEXT_MENUITEM_HEIGHT (30)
  565. #define MMI_INLINE_EDIT_MENUITEM_HEIGHT (30)
  566. #endif
  567. #define MMI_MULTIROW_MENUITEM_HEIGHT (48)
  568. //PMT VIKAS START 20051217
  569. #ifdef __MMI_UI_TAB_PANE__
  570. #define MMI_TAB_HEIGHT (30)
  571. #endif
  572. //PMT VIKAS END 20051217
  573. #if 0
  574. #ifdef __MMI_EDITABLE_AUDIO_EQUALIZER__
  575. /* under construction !*/
  576. /* under construction !*/
  577. /* under construction !*/
  578. /* under construction !*/
  579. /* under construction !*/
  580. /* under construction !*/
  581. /* under construction !*/
  582. #endif //__MMI_EDITABLE_AUDIO_EQUALIZER__
  583. #endif
  584. #ifdef __MMI_TOUCH_IDLESCREEN_SHORTCUTS__
  585. #define WGUI_TOUCH_IDLESCREEN_SHORTCUTS_HEIGHT 50//110105 status bar1 Calvin: this should be moved to .h
  586. #endif
  587. #define MMI_ROTATED_LCD_WIDTH (MAIN_LCD_DEVICE_HEIGHT)
  588. #define MMI_ROTATED_LCD_HEIGHT (MAIN_LCD_DEVICE_WIDTH)
  589. #define MMI_ROTATED_TITLE_WIDTH (230)
  590. #define MMI_ROTATED_TITLE_HEIGHT (MMI_TITLE_HEIGHT)
  591. #define MMI_ROTATED_CONTENT_WIDTH (230)
  592. #define MMI_ROTATED_CONTENT_HEIGHT (MMI_CONTENT_HEIGHT-(MMI_MENUITEM_HEIGHT << 1))
  593. #define MMI_ROTATED_TITLE_X (15)
  594. #define MMI_ROTATED_TITLE_Y ((MMI_ROTATED_LCD_HEIGHT -  MMI_ROTATED_CONTENT_HEIGHT - MMI_ROTATED_TITLE_HEIGHT)/2)
  595. #define MMI_ROTATED_CONTENT_X (15)
  596. #define MMI_ROTATED_CONTENT_Y (MMI_ROTATED_TITLE_Y + MMI_ROTATED_TITLE_HEIGHT)
  597. #define MMI_ROTATED_POP_UP_DIALOG_X (MMI_ROTATED_CONTENT_X + 10)
  598. #define MMI_ROTATED_POP_UP_DIALOG_Y (MMI_ROTATED_TITLE_Y + MMI_ROTATED_TITLE_HEIGHT + 10)
  599. #define MMI_ROTATED_POP_UP_DIALOG_WIDTH (MMI_ROTATED_CONTENT_WIDTH - 15)
  600. #define MMI_ROTATED_POP_UP_DIALOG_HEIGHT (MMI_ROTATED_LCD_HEIGHT - MMI_ROTATED_POP_UP_DIALOG_Y - 20)
  601. #define MMI_ROTATED_POP_UP_DIALOG_FULL_HEIGHT (MMI_ROTATED_POP_UP_DIALOG_HEIGHT)
  602. #define MMI_ROTATED_BUTTON_BAR_X (MMI_ROTATED_CONTENT_X + MMI_ROTATED_CONTENT_WIDTH + 3 /* leave space for border frame */)
  603. #define MMI_ROTATED_BUTTON_BAR_Y (0)
  604. #define MMI_ROTATED_BUTTON_BAR_WIDTH (MMI_ROTATED_LCD_WIDTH - MMI_ROTATED_CONTENT_X - MMI_ROTATED_CONTENT_WIDTH - 3)
  605. #define MMI_ROTATED_BUTTON_BAR_HEIGHT (MMI_ROTATED_LCD_HEIGHT)
  606. #define MMI_ROTATED_SOFTKEY_WIDTH (MMI_ROTATED_BUTTON_BAR_WIDTH)
  607. #define MMI_ROTATED_SOFTKEY_HEIGHT (MMI_SOFTKEY_HEIGHT)
  608. #else
  609. #error "No UI Style is Specified!!"
  610. #endif
  611. #define MMI_MATRIX_BAR_WIDTH (MAIN_LCD_DEVICE_WIDTH)
  612. #define MMI_MATRIX_BAR_HEIGHT (19)
  613. #define MMI_MATRIX_BAR_X (0)
  614. #define MMI_MATRIX_BAR_Y (MAIN_LCD_DEVICE_HEIGHT-MMI_BUTTON_BAR_HEIGHT-MMI_MATRIX_BAR_HEIGHT+1)
  615. #define MMI_MULTITAP_X (2)
  616. #define MMI_MULTITAP_WIDTH (MAIN_LCD_DEVICE_WIDTH-4)
  617. #if defined(__MMI_MAINLCD_240X320__)
  618.    #define MMI_MULTITAP_HEIGHT (24)
  619. #else
  620.    #define MMI_MULTITAP_HEIGHT (17)
  621. #endif
  622. #ifdef __MMI_UI_DALMATIAN_SOFTKEYS__
  623. #define MMI_MULTITAP_Y (MAIN_LCD_DEVICE_HEIGHT-MMI_BUTTON_BAR_HEIGHT-MMI_MULTITAP_HEIGHT -1)
  624. #else
  625. #define MMI_MULTITAP_Y (MAIN_LCD_DEVICE_HEIGHT-MMI_BUTTON_BAR_HEIGHT-MMI_MULTITAP_HEIGHT-2)     //Old: (MAIN_LCD_DEVICE_HEIGHT-MMI_BUTTON_BAR_HEIGHT-MMI_MULTITAP_HEIGHT) //KP Jerry modify on 2007-4-29
  626. #endif
  627. #define MMI_SINGLELINE_INPUTBOX_X (5)
  628. #define MMI_SINGLELINE_INPUTBOX_Y (40)
  629. #define MMI_SINGLELINE_INPUTBOX_WIDTH (MAIN_LCD_DEVICE_WIDTH-10)
  630. #if defined(__MMI_MAINLCD_240X320__)
  631. #define MMI_SINGLELINE_INPUTBOX_HEIGHT (26)
  632. #else
  633. #define MMI_SINGLELINE_INPUTBOX_HEIGHT (20)
  634. #endif
  635. #define MMI_MULTILINE_INPUTBOX_X (0)
  636. #define MMI_MULTILINE_INPUTBOX_Y (20)
  637. #define MMI_MULTILINE_INPUTBOX_WIDTH (MAIN_LCD_DEVICE_WIDTH)
  638. #define MMI_MULTILINE_INPUTBOX_HEIGHT (MAIN_LCD_DEVICE_HEIGHT-82)
  639. #define MMI_GENERAL_INPUTBOX_X (0)
  640. #define MMI_GENERAL_INPUTBOX_Y (20)
  641. #define MMI_GENERAL_INPUTBOX_WIDTH (MAIN_LCD_DEVICE_WIDTH)
  642. #define MMI_GENERAL_INPUTBOX_HEIGHT (MAIN_LCD_DEVICE_HEIGHT-82)
  643. /* Tab bar */
  644. #if defined(__MMI_MAINLCD_240X320__)
  645. #define MMI_HORIZONTAL_TAB_BAR_TAB_WIDTH (60)
  646. #elif defined( __MMI_MAINLCD_176X220__)
  647. #define MMI_HORIZONTAL_TAB_BAR_TAB_WIDTH (44)
  648. #else
  649. #define MMI_HORIZONTAL_TAB_BAR_TAB_WIDTH (42)
  650. #endif
  651. #if defined(__MMI_MAINLCD_240X320__)
  652. #define MMI_HORIZONTAL_TAB_BAR_FOCUSED_TAB_WIDTH (60)
  653. #else
  654. #define MMI_HORIZONTAL_TAB_BAR_FOCUSED_TAB_WIDTH (44)
  655. #endif
  656. #define MMI_HORIZONTAL_TAB_BAR_X (MMI_TITLE_X)
  657. #define MMI_HORIZONTAL_TAB_BAR_Y (MMI_TITLE_Y)
  658. #define MMI_HORIZONTAL_TAB_BAR_WIDTH (MMI_TITLE_WIDTH)
  659. #if defined(__MMI_MAINLCD_240X320__)
  660. #define MMI_HORIZONTAL_TAB_BAR_TAB_AREA_HEIGHT (28)
  661. #else
  662. #define MMI_HORIZONTAL_TAB_BAR_TAB_AREA_HEIGHT (20)
  663. #endif
  664. #if defined(__MMI_MAINLCD_240X320__)
  665. #define MMI_HORIZONTAL_TAB_BAR_HINT_AREA_HEIGHT (26)
  666. #elif defined(__MMI_MAINLCD_176X220__) || defined(__MMI_MAINLCD_128X160__)
  667. #define MMI_HORIZONTAL_TAB_BAR_HINT_AREA_HEIGHT (20)
  668. #else
  669. #define MMI_HORIZONTAL_TAB_BAR_HINT_AREA_HEIGHT (0)
  670. #endif
  671. #define MMI_CONTENT_WIDTH_WITH_H_TAB (MMI_content_width)
  672. #define MMI_CONTENT_HEIGHT_WITH_H_TAB (MMI_content_height + MMI_TITLE_HEIGHT - MMI_HORIZONTAL_TAB_BAR_TAB_AREA_HEIGHT - MMI_HORIZONTAL_TAB_BAR_HINT_AREA_HEIGHT)
  673. #define MMI_CONTENT_X_WITH_H_TAB (MMI_content_x)
  674. #define MMI_CONTENT_Y_WITH_H_TAB (MMI_content_y + MMI_HORIZONTAL_TAB_BAR_TAB_AREA_HEIGHT + MMI_HORIZONTAL_TAB_BAR_HINT_AREA_HEIGHT - MMI_TITLE_HEIGHT)
  675. #define MMI_DROPDOWN_MENUITEM_HEIGHT (18)
  676. #if !defined(__MMI_TOUCH_SCREEN__)
  677. //W06.03 Adjust the height of the information bar for 240*320
  678. #if defined(__MMI_MAINLCD_240X320__)
  679. #define INFORMATION_BAR_HEIGHT  (22)
  680. #else
  681. #define INFORMATION_BAR_HEIGHT  (12)
  682. #endif
  683. #else
  684. #if defined(__MMI_MAINLCD_240X320__)
  685. #define INFORMATION_BAR_HEIGHT  (22)
  686. #else
  687. #define INFORMATION_BAR_HEIGHT  (18)
  688. #endif
  689. #endif
  690. #define MMI_POP_UP_DIALOG_FULL_Y (((MAIN_LCD_DEVICE_HEIGHT-MMI_POP_UP_DIALOG_FULL_HEIGHT)>>1) + 6)
  691. #if defined (__MMI_MAINLCD_240X320__)
  692. //KP Jerry modify on 2006-11-9 start
  693. #if defined(__P02_QVGA__)
  694. #define MMI_DIALING_KEYPAD_COLOMNS (3)
  695. #define MMI_DIALING_KEYPAD_ROWS (4)
  696. #define MMI_DIALING_KEYPAD_LAYER_WIDTH        (240)      //Old:(218)    
  697. #define MMI_DIALING_KEYPAD_LAYER_HEIGHT (226)      //Old:(177) 
  698. #define MMI_DIALING_KEYPAD_LAYER_X ((MAIN_LCD_DEVICE_WIDTH-MMI_DIALING_KEYPAD_LAYER_WIDTH)>>1)
  699. #define MMI_DIALING_KEYPAD_LAYER_Y (MAIN_LCD_DEVICE_HEIGHT-MMI_DIALING_KEYPAD_LAYER_HEIGHT-MMI_BUTTON_BAR_HEIGHT)      //Old:(((MAIN_LCD_DEVICE_HEIGHT-MMI_DIALING_KEYPAD_LAYER_HEIGHT)>>1)+20)    //KP Jerry modify on 2006-11-10
  700. #define MMI_DIALING_KEYPAD_X (7)         //Old:(14) 
  701. #define MMI_DIALING_KEYPAD_Y (2)         //Old:(5) 
  702. #define MMI_DIALING_KEYPAD_WIDTH (240)      //Old:(218)
  703. #define MMI_DIALING_KEYPAD_HEIGHT (226)      //Old:(177)
  704. #define MMI_DIALING_KEY_WIDTH (72)        //Old:(37)
  705. #define MMI_DIALING_KEY_HEIGHT (42)        //Old:(37)
  706. #define MMI_DIALING_KEY_HORIZONTAL_GAP        (6)          //Old:(12) 
  707.   #define MMI_DIALING_KEY_VERTICAL_GAP (3)          //Old:(5)
  708. #define MMI_DIALING_BOX_HEIGHT (MAIN_LCD_DEVICE_HEIGHT-MMI_DIALING_KEYPAD_LAYER_HEIGHT-MMI_BUTTON_BAR_HEIGHT-MMI_STATUS_BAR_HEIGHT)        //Old:(66)     //KP Jerry modify on 2006-11-10
  709. /* For function key on idlescreen */
  710. #if defined (__MMI_TOUCH_DIAL_SCREEN_WITH_FUNCTION__)
  711. #define MMI_DIALING_KEYPAD_FUNC_COLOMNS (3)          //Old:(1)     
  712. #define MMI_DIALING_KEYPAD_FUNC_ROWS (1)          //Old:(2)
  713. #define MMI_DIALING_KEYPAD_FUNC_X (7)          //Old:(165)
  714. #define MMI_DIALING_KEYPAD_FUNC_Y (183)       //Old:(33)
  715. #define MMI_DIALING_FUNC_KEY_WIDTH (72)         //Old:(37)
  716. #define MMI_DIALING_FUNC_KEY_HEIGHT (42)        //Old:(37)
  717. #define MMI_DIALING_FUNC_KEY_HORIZONTAL_GAP (6)          //Old:(12)
  718. #define MMI_DIALING_FUNC_KEY_VERTICAL_GAP        (3)          //Old:(27)
  719. #endif
  720. #elif defined(__P08_QVGA__) || defined(__S03_QVGA__)
  721. #define MMI_DIALING_KEYPAD_COLOMNS (3)
  722. #define MMI_DIALING_KEYPAD_ROWS (4)
  723. #define MMI_DIALING_KEYPAD_LAYER_WIDTH        (240)      //Old:(218)    
  724. #define MMI_DIALING_KEYPAD_LAYER_HEIGHT (199)      //Old:(177) 
  725. #define MMI_DIALING_KEYPAD_LAYER_X ((MAIN_LCD_DEVICE_WIDTH-MMI_DIALING_KEYPAD_LAYER_WIDTH)>>1)
  726. #define MMI_DIALING_KEYPAD_LAYER_Y (MAIN_LCD_DEVICE_HEIGHT-MMI_DIALING_KEYPAD_LAYER_HEIGHT-MMI_BUTTON_BAR_HEIGHT)      //Old:(((MAIN_LCD_DEVICE_HEIGHT-MMI_DIALING_KEYPAD_LAYER_HEIGHT)>>1)+20)    //KP Jerry modify on 2006-11-10
  727. #define MMI_DIALING_KEYPAD_X (5)         //Old:(14) 
  728. #define MMI_DIALING_KEYPAD_Y (3)         //Old:(5) 
  729. #define MMI_DIALING_KEYPAD_WIDTH (240)      //Old:(218)
  730. #define MMI_DIALING_KEYPAD_HEIGHT (199)      //Old:(177)
  731. #define MMI_DIALING_KEY_WIDTH (71)        //Old:(37)
  732. #define MMI_DIALING_KEY_HEIGHT (37)        //Old:(37)
  733. #define MMI_DIALING_KEY_HORIZONTAL_GAP        (8)          //Old:(12) 
  734.   #define MMI_DIALING_KEY_VERTICAL_GAP (2)          //Old:(5)
  735. #define MMI_DIALING_BOX_HEIGHT (MAIN_LCD_DEVICE_HEIGHT-MMI_DIALING_KEYPAD_LAYER_HEIGHT-MMI_BUTTON_BAR_HEIGHT-MMI_STATUS_BAR_HEIGHT)        //Old:(66)     //KP Jerry modify on 2006-11-10
  736. /* For function key on idlescreen */
  737. #if defined (__MMI_TOUCH_DIAL_SCREEN_WITH_FUNCTION__)
  738. #define MMI_DIALING_KEYPAD_FUNC_COLOMNS (3)          //Old:(1)     
  739. #define MMI_DIALING_KEYPAD_FUNC_ROWS (1)          //Old:(2)
  740. #define MMI_DIALING_KEYPAD_FUNC_X (5)          //Old:(165)
  741. #define MMI_DIALING_KEYPAD_FUNC_Y (159)       //Old:(33)
  742. #define MMI_DIALING_FUNC_KEY_WIDTH (71)         //Old:(37)
  743. #define MMI_DIALING_FUNC_KEY_HEIGHT        (37)        //Old:(37)
  744. #define MMI_DIALING_FUNC_KEY_HORIZONTAL_GAP (8)          //Old:(12)
  745. #define MMI_DIALING_FUNC_KEY_VERTICAL_GAP        (2)          //Old:(27)
  746. #endif
  747. #endif/*__P02_QVGA__*/
  748. //KP Jerry modify on 2006-11-9 end
  749. #else
  750. #define MMI_DIALING_KEYPAD_COLOMNS (3)
  751. #define MMI_DIALING_KEYPAD_ROWS (4)
  752. #define MMI_DIALING_KEYPAD_LAYER_WIDTH (176)
  753. #define MMI_DIALING_KEYPAD_LAYER_HEIGHT (200)
  754. #define MMI_DIALING_KEYPAD_LAYER_X (0)
  755. #define MMI_DIALING_KEYPAD_LAYER_Y (50)
  756. #define MMI_DIALING_KEYPAD_X (10)//(16)   //jerson modify 20070529
  757. #define MMI_DIALING_KEYPAD_Y (8)//(7)
  758. #define MMI_DIALING_KEYPAD_WIDTH (154)//(145)
  759. #define MMI_DIALING_KEYPAD_HEIGHT (137)
  760. #define MMI_DIALING_KEY_WIDTH (39)
  761. #define MMI_DIALING_KEY_HEIGHT (31)
  762. #define MMI_DIALING_KEY_HORIZONTAL_GAP (19)//(14)
  763. #define MMI_DIALING_KEY_VERTICAL_GAP (5)
  764. #define MMI_DIALING_BOX_HEIGHT (33)
  765. /* For function key on idlescreen */
  766. #if defined (__MMI_TOUCH_DIAL_SCREEN_WITH_FUNCTION__)
  767. #define MMI_DIALING_KEYPAD_FUNC_COLOMNS (1)
  768. #define MMI_DIALING_KEYPAD_FUNC_ROWS (2)
  769. #define MMI_DIALING_KEYPAD_FUNC_X (165)
  770. #define MMI_DIALING_KEYPAD_FUNC_Y (33)
  771. #define MMI_DIALING_FUNC_KEY_WIDTH (37)
  772. #define MMI_DIALING_FUNC_KEY_HEIGHT (37)
  773. #define MMI_DIALING_FUNC_KEY_HORIZONTAL_GAP (12)
  774. #define MMI_DIALING_FUNC_KEY_VERTICAL_GAP (27)
  775. #endif
  776. #endif
  777. /* Upper bound of the number of menu items in one screen */
  778. #define MMI_MAX_MENUITEMS_IN_CONTENT (MMI_CONTENT_HEIGHT/MMI_MENUITEM_HEIGHT + 2) /* the magic number 2 is for safety. At least 1. */
  779. #ifdef __MMI_TOUCH_SCREEN__
  780. #define MMI_PASSWD_KEYBOARD_START_X (0)
  781. #define MMI_PASSWD_KEYBOARD_START_Y (138)
  782. #endif
  783. /* Macros defined for title bar buttons used in Touch Panel support */
  784. #if defined(__MMI_MAINLCD_240X320__)
  785. #define MMI_TITLEBAR_BUTTON_GAP  (20)
  786. #define MMI_TITLEBAR_BUTTON_WIDTH  (19)
  787. #define MMI_TITLEBAR_BUTTON_HEIGHT  (17)
  788. #elif defined(__MMI_MAINLCD_176X220__)
  789. #define MMI_TITLEBAR_BUTTON_GAP  (10)
  790. #define MMI_TITLEBAR_BUTTON_WIDTH  (15)
  791. #define MMI_TITLEBAR_BUTTON_HEIGHT  (15)
  792. #else
  793. #define MMI_TITLEBAR_BUTTON_GAP  (1)
  794. #define MMI_TITLEBAR_BUTTON_WIDTH  (15)
  795. #define MMI_TITLEBAR_BUTTON_HEIGHT  (15)
  796. #endif
  797. /*
  798. ** Extern Global Variable
  799. */
  800. extern U8 MMI_disable_title_shortcut_display;
  801. extern S32 MMI_status_bar_height;
  802. extern S32 MMI_content_x;
  803. extern S32 MMI_content_y;
  804. extern S32 MMI_content_width;
  805. extern S32 MMI_content_height;
  806. extern S32 MMI_pop_up_dialog_x;
  807. extern S32 MMI_pop_up_dialog_y;
  808. extern S32 MMI_pop_up_dialog_width;
  809. extern S32 MMI_pop_up_dialog_height;
  810. extern S32 MMI_pop_up_dialog_full_height;
  811. /*
  812. ** Extern Global Function
  813. */
  814. extern void wgui_init(void);
  815. extern void MMI_dummy_function(void);
  816. extern void register_keyboard_key_handler(void (*f)(S32 vkey_code,S32 key_state));
  817. extern void register_keyboard_input_handler(void (*f)(S32 vkey_code));
  818. extern void register_keyboard_global_key_handler(void (*f)(S32 vkey_code,S32 key_state));
  819. extern void register_keyboard_global_input_handler(void (*f)(S32 vkey_code));
  820. extern void clear_keyboard_key_handler(void);
  821. extern void clear_keyboard_input_handler(void);
  822. extern void clear_keyboard_global_key_handler(void);
  823. extern void clear_keyboard_global_input_handler(void);
  824. /* key handling wrappers */
  825. extern void clear_key_handlers(void);
  826. extern void clear_category_screen_key_handlers(void);
  827. extern void register_key_input_handler(void (*f)(MMI_key_code_type key_code,MMI_key_event_type key_event));
  828. extern void register_key_up_handler(void (*f)(MMI_key_code_type key_code));
  829. extern void register_key_down_handler(void (*f)(MMI_key_code_type key_code));
  830. extern void register_MMI_key_input_handler(void);
  831. extern void register_MMI_stroke_key_input_handler(void);
  832. #ifdef __MMI_MULTITAP_THAI__
  833. extern void register_MMI_key_input_extend_handler(void);
  834. #endif
  835. extern void clear_key_input_handler(void);
  836. extern void clear_key_down_handler(void);
  837. extern void clear_key_up_handler(void);
  838. extern void clear_MMI_key_input_handler(void);
  839. extern void MMI_key_input_handler(MMI_key_code_type key_code,MMI_key_event_type key_event);
  840. #endif