WEB开发网
开发学院手机开发Android 开发 Android事件处理分 阅读

Android事件处理分

 2010-09-10 00:47:00 来源:WEB开发网   
核心提示:.probe = pxa27x_keypad_probe,.remove = __devexit_p(pxa27x_keypad_remove),.suspend = pxa27x_keypad_suspend,.resume = pxa27x_keypad_resume,.driver = {.name = &quo

.probe = pxa27x_keypad_probe,

.remove = __devexit_p(pxa27x_keypad_remove),

.suspend = pxa27x_keypad_suspend,

.resume = pxa27x_keypad_resume,

.driver = {

.name = "pxa27x-keypad",

.owner = THIS_MODULE,

},

};

ANDROID_ROOT 为环境变量,在android的命令模式下通过 printenv 可以知道它为: system

所以 keylayoutFilename 为:/system/usr/keylayout/pxa27x-keypad.kl

pxa27x-keypad.kl 定义了按键映射,具体内容如下:

+ expand sourceview plaincopy to clipboardprint?

·········10········20········30········40········50········60········70········80········90········100·······110·······120·······130·······140·······150

# NUMERIC KEYS 3x4

key 2 1

key 3 2

key 4 3

key 5 4

key 6 5

key 7 6

key 8 7

key 9 8

key 10 9

key 11 0

key 83 POUND

key 55 STAR

# FUNCTIONAL KEYS

key 231 MENU WAKE_DROPPED

key 192 BACK WAKE_DROPPED

key 193 HOME WAKE

key 107 DEL WAKE

key 102 CALL WAKE_DROPPED

key 158 ENDCALL WAKE_DROPPED

key 28 DPAD_CENTER WAKE

key 115 VOLUME_UP

key 114 VOLUME_DOWN

# NUMERIC KEYS 3x4

key 2 1

key 3 2

key 4 3

key 5 4

key 6 5

key 7 6

key 8 7

key 9 8

key 10 9

key 11 0

key 83 POUND

key 55 STAR

# FUNCTIONAL KEYS

key 231 MENU WAKE_DROPPED

key 192 BACK WAKE_DROPPED

key 193 HOME WAKE

key 107 DEL WAKE

key 102 CALL WAKE_DROPPED

key 158 ENDCALL WAKE_DROPPED

上一页  3 4 5 6 7 8 9  下一页

Tags:Android 事件 处理

编辑录入:coldstar [复制链接] [打 印]
赞助商链接