зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1490366 - Part 3: Select the first item in richlistbox on focus r=dao
Differential Revision: https://phabricator.services.mozilla.com/D8282 --HG-- extra : moz-landing-system : lando
This commit is contained in:
Родитель
8af21b79fd
Коммит
aaf946de3d
|
@ -888,6 +888,10 @@
|
|||
if (this.getRowCount() > 0) {
|
||||
if (this.currentIndex == -1) {
|
||||
this.currentIndex = this.getIndexOfFirstVisibleRow();
|
||||
let currentItem = this.getItemAtIndex(this.currentIndex);
|
||||
if (currentItem) {
|
||||
this.selectItem(currentItem);
|
||||
}
|
||||
} else {
|
||||
this.currentItem._fireEvent("DOMMenuItemActive");
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче