prevent chrome from scrolling in horizontal icon lists
This commit is contained in:
parent
0211be527c
commit
a5fc65833d
1 changed files with 5 additions and 3 deletions
|
@ -182,9 +182,11 @@
|
||||||
}
|
}
|
||||||
if (focused !== null) {
|
if (focused !== null) {
|
||||||
Ox.UI.elements[focused].triggerEvent('key_' + key);
|
Ox.UI.elements[focused].triggerEvent('key_' + key);
|
||||||
// fixme: oxdb context browser suggests we should add left and right keys here
|
if (
|
||||||
if (['down', 'space', 'up'].indexOf(key) > -1 && !Ox.UI.elements[focused].hasClass('OxInput')) {
|
['down', 'left', 'right', 'space', 'up'].indexOf(key) > -1 &&
|
||||||
// prevent chrome from scrolling
|
!Ox.UI.elements[focused].hasClass('OxInput')
|
||||||
|
) {
|
||||||
|
// prevent Chrome from scrolling
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue