зеркало из https://github.com/mozilla/gecko-dev.git
Bug 960248 - Fix range adjustments when on a label. r=yzen
This commit is contained in:
Родитель
61df69f208
Коммит
79adfff128
|
@ -343,13 +343,14 @@ function scroll(aMessage) {
|
|||
|
||||
function adjustRange(aMessage) {
|
||||
function sendUpDownKey(aAccessible) {
|
||||
let evt = content.document.createEvent('KeyboardEvent');
|
||||
let keycode = aMessage.json.direction == 'forward' ?
|
||||
content.KeyEvent.DOM_VK_DOWN : content.KeyEvent.DOM_VK_UP;
|
||||
evt.initKeyEvent(
|
||||
"keypress", false, true, null, false, false, false, false, keycode, 0);
|
||||
if (aAccessible.DOMNode) {
|
||||
aAccessible.DOMNode.dispatchEvent(evt);
|
||||
let acc = Utils.getEmbeddedControl(aAccessible) || aAccessible;
|
||||
if (acc.DOMNode) {
|
||||
let evt = content.document.createEvent('KeyboardEvent');
|
||||
let keycode = aMessage.json.direction == 'forward' ?
|
||||
content.KeyEvent.DOM_VK_DOWN : content.KeyEvent.DOM_VK_UP;
|
||||
evt.initKeyEvent(
|
||||
"keypress", false, true, null, false, false, false, false, keycode, 0);
|
||||
acc.DOMNode.dispatchEvent(evt);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче