Menu Component: set atttibute "oo_editor_input" for getting focus and keyboard events.

This commit is contained in:
Julia Radzhabova 2016-07-06 13:59:54 +03:00
parent 4a2fee8579
commit f415118e05
2 changed files with 3 additions and 1 deletions

View file

@ -147,7 +147,7 @@ define([
},
template: _.template([
'<ul class="dropdown-menu <%= options.cls %>" style="<%= options.style %>" role="menu"></ul>'
'<ul class="dropdown-menu <%= options.cls %>" oo_editor_input="true" style="<%= options.style %>" role="menu"></ul>'
].join('')),
initialize : function(options) {

View file

@ -566,6 +566,7 @@ define([
cyclic: false,
items: []
}).on('render:after', function(mnu) {
mnu.cmpEl.removeAttr('oo_editor_input').attr('oo_editor_keyboard', true);
this.scroller = new Common.UI.Scroller({
el: $(this.el).find('.dropdown-menu '),
useKeyboard: this.enableKeyEvents && !this.handleSelect,
@ -581,6 +582,7 @@ define([
cyclic: false,
items: []
}).on('render:after', function(mnu) {
mnu.cmpEl.removeAttr('oo_editor_input').attr('oo_editor_keyboard', true);
this.scroller = new Common.UI.Scroller({
el: $(this.el).find('.dropdown-menu '),
useKeyboard: this.enableKeyEvents && !this.handleSelect,