mirror of https://github.com/vitalif/phantomjs
WebPage: new constants for modifiers keys
Declares in event.modifiers all constants needed for the fifth parameter of sendEvent. http://code.google.com/p/phantomjs/issues/detail?id=1056 https://github.com/ariya/phantomjs/issues/110561.9
parent
63dc1e2c8f
commit
b16a5348a9
|
@ -467,6 +467,14 @@ function decorateNewPage(opts, page) {
|
||||||
definePageCallbackHandler(page, handlers, "onPrompt", "_getJsPromptCallback");
|
definePageCallbackHandler(page, handlers, "onPrompt", "_getJsPromptCallback");
|
||||||
|
|
||||||
page.event = {};
|
page.event = {};
|
||||||
|
page.event.modifier = {
|
||||||
|
shift: 0x02000000,
|
||||||
|
ctrl: 0x04000000,
|
||||||
|
alt: 0x08000000,
|
||||||
|
meta: 0x10000000,
|
||||||
|
keypad: 0x20000000
|
||||||
|
};
|
||||||
|
|
||||||
page.event.key = {
|
page.event.key = {
|
||||||
'0': 48,
|
'0': 48,
|
||||||
'1': 49,
|
'1': 49,
|
||||||
|
|
Loading…
Reference in New Issue