Class: hotkey
快捷键设置
View source: hotkey.js.
Arguments:
vui.hotkey (event, key, name, callback)
- event - (String) keydown 其它为keypress|keyup
- key - (String) 键值esc,enter...
- name - (String) 快捷键对应回调时会用的名称
- callback - (Function) 回调函数
Example:
vui.hotkey({event:'keydown',key:'enter',name:'hotkeyName'},function(){ alert('todo'); });