[SSE] Add focus for up/down buttons

This commit is contained in:
Julia Radzhabova 2021-04-15 02:19:18 +03:00
parent d0a4de80ec
commit f3a75b724d
3 changed files with 18 additions and 10 deletions

View file

@ -339,6 +339,11 @@
border: @scaled-one-px-value-ie solid @border-regular-control-ie;
border: @scaled-one-px-value solid @border-regular-control;
.border-radius(@border-radius-small);
&:focus:not(.disabled) {
border-color: @border-control-focus-ie;
border-color: @border-control-focus;
}
}
&:before,

View file

@ -150,7 +150,8 @@ define([
store: new Common.UI.DataViewStore(),
emptyText: '',
scrollAlwaysVisible: true,
itemTemplate: _.template('<div id="<%= id %>" class="list-item" style="min-height: 15px;"><%= value %></div>')
itemTemplate: _.template('<div id="<%= id %>" class="list-item" style="min-height: 15px;"><%= value %></div>'),
tabindex:1
});
this.seriesList.onKeyDown = _.bind(this.onListKeyDown, this, 'series');
this.seriesList.on('item:select', _.bind(this.onSelectSeries, this));
@ -199,7 +200,8 @@ define([
store: new Common.UI.DataViewStore(),
emptyText: '',
scrollAlwaysVisible: true,
itemTemplate: _.template('<div id="<%= id %>" class="list-item" style="min-height: 15px;"><%= value %></div>')
itemTemplate: _.template('<div id="<%= id %>" class="list-item" style="min-height: 15px;"><%= value %></div>'),
tabindex:1
});
this.btnEditCategory = new Common.UI.Button({
@ -210,17 +212,16 @@ define([
this.afterRender();
},
afterRender: function() {
this._setDefaults(this.chartSettings);
getFocusedComponents: function() {
return [this.txtDataRange, this.seriesList, this.btnAdd, this.btnEdit, this.btnDelete, this.btnUp, this.btnDown, this.btnSwitch, this.categoryList, this.btnEditCategory];
},
show: function() {
Common.Views.AdvancedSettingsWindow.prototype.show.apply(this, arguments);
getDefaultFocusableComponent: function () {
return this.txtDataRange;
},
var me = this;
_.delay(function(){
me.txtDataRange.cmpEl.find('input').focus();
},50);
afterRender: function() {
this._setDefaults(this.chartSettings);
},
close: function () {

View file

@ -216,6 +216,8 @@ define([ 'text!spreadsheeteditor/main/app/template/FormatRulesManagerDlg.templa
Common.UI.FocusManager.add(this, this.rulesList);
Common.UI.FocusManager.add(this, this.btnNew);
Common.UI.FocusManager.add(this, this.btnEdit);
Common.UI.FocusManager.add(this, this.btnUp);
Common.UI.FocusManager.add(this, this.btnDown);
Common.UI.FocusManager.add(this, this.btnDelete);