[DE] Add focus for checkbox
This commit is contained in:
parent
a6f7d17261
commit
9509869377
|
@ -337,6 +337,7 @@ define([ 'text!common/main/lib/template/AutoCorrectDialog.template',
|
|||
|
||||
this.btnsCategory[0].on('click', _.bind(this.onMathCategoryClick, this, false));
|
||||
this.btnsCategory[1].on('click', _.bind(this.onRecCategoryClick, this, false));
|
||||
this.btnsCategory[2].on('click', _.bind(this.onAutoformatCategoryClick, this, false));
|
||||
|
||||
this.afterRender();
|
||||
},
|
||||
|
@ -351,10 +352,12 @@ define([ 'text!common/main/lib/template/AutoCorrectDialog.template',
|
|||
},
|
||||
|
||||
getFocusedComponents: function() {
|
||||
return [
|
||||
this.inputReplace, this.inputBy, {cmp: this.mathList, selector: '.listview'}, // 0 tab
|
||||
this.inputRecFind, {cmp: this.mathRecList, selector: '.listview'} // 1 tab
|
||||
];
|
||||
var arr = [
|
||||
this.chReplaceType, this.inputReplace, this.inputBy, this.mathList, // 0 tab
|
||||
this.inputRecFind, this.mathRecList // 1 tab
|
||||
];
|
||||
arr = arr.concat(this.chNewRows ? [this.chNewRows] : [this.chQuotes, this.chHyphens, this.chBulleted, this.chNumbered]);
|
||||
return arr;
|
||||
},
|
||||
|
||||
getSettings: function() {
|
||||
|
@ -395,6 +398,7 @@ define([ 'text!common/main/lib/template/AutoCorrectDialog.template',
|
|||
var value = this.getActiveCategory();
|
||||
if (value==0) this.onMathCategoryClick(true);
|
||||
else if (value==1) this.onRecCategoryClick(true);
|
||||
else if (value==2) this.onAutoformatCategoryClick(true);
|
||||
},
|
||||
|
||||
close: function() {
|
||||
|
@ -417,6 +421,13 @@ define([ 'text!common/main/lib/template/AutoCorrectDialog.template',
|
|||
}
|
||||
},
|
||||
|
||||
onAutoformatCategoryClick: function(delay) {
|
||||
var me = this;
|
||||
_.delay(function(){
|
||||
me.chNewRows ? me.chNewRows.focus() : me.chQuotes.focus();
|
||||
},delay ? 50 : 0);
|
||||
},
|
||||
|
||||
onDelete: function() {
|
||||
var rec = this.mathList.getSelectedRec();
|
||||
if (rec) {
|
||||
|
|
|
@ -143,7 +143,7 @@ define([
|
|||
},
|
||||
|
||||
getFocusedComponents: function() {
|
||||
return [this.inputName, this.inputTitle, this.inputEmail, this.textareaInstructions];
|
||||
return [this.inputName, this.inputTitle, this.inputEmail, this.textareaInstructions, this.chDate];
|
||||
},
|
||||
|
||||
getDefaultFocusableComponent: function () {
|
||||
|
|
|
@ -71,7 +71,7 @@
|
|||
}
|
||||
}
|
||||
|
||||
&:focus {
|
||||
&:focus:not(.disabled) {
|
||||
input[type=checkbox] {
|
||||
+ label {
|
||||
border-color: @border-control-focus-ie;
|
||||
|
|
|
@ -249,7 +249,7 @@ define([
|
|||
},
|
||||
|
||||
getFocusedComponents: function() {
|
||||
return [this.txtName, {cmp: this.bookmarksList, selector: '.listview'}];
|
||||
return [this.txtName, this.bookmarksList, this.chHidden];
|
||||
},
|
||||
|
||||
afterRender: function() {
|
||||
|
|
|
@ -353,7 +353,7 @@ define([
|
|||
},
|
||||
|
||||
getFocusedComponents: function() {
|
||||
return [this.txtCaption, this.cmbPosition, this.cmbLabel, this.cmbNumbering, this.cmbChapter, this.cmbSeparator];
|
||||
return [this.txtCaption, this.cmbPosition, this.cmbLabel, this.chExclude, this.cmbNumbering, this.chChapter, this.cmbChapter, this.cmbSeparator];
|
||||
},
|
||||
|
||||
getDefaultFocusableComponent: function () {
|
||||
|
|
|
@ -358,8 +358,9 @@ define([ 'text!documenteditor/main/app/template/ControlSettingsDialog.template',
|
|||
getFocusedComponents: function() {
|
||||
return [
|
||||
this.txtName, this.txtTag, this.txtPlaceholder, this.cmbShow, // 0 tab
|
||||
{cmp: this.list, selector: '.listview'}, // 2 tab
|
||||
this.txtDate, {cmp: this.listFormats, selector: '.listview'}, this.cmbLang // 3 tab
|
||||
this.chLockDelete , this.chLockEdit, // 1 tab
|
||||
this.list, // 2 tab
|
||||
this.txtDate, this.listFormats, this.cmbLang // 3 tab
|
||||
];
|
||||
},
|
||||
|
||||
|
@ -370,6 +371,8 @@ define([ 'text!documenteditor/main/app/template/ControlSettingsDialog.template',
|
|||
setTimeout(function(){
|
||||
if (index==0) {
|
||||
me.txtName.focus();
|
||||
} else if (index==1) {
|
||||
me.chLockDelete.focus();
|
||||
} else if (index==2) {
|
||||
me.list.focus();
|
||||
} else if (index==3)
|
||||
|
|
|
@ -131,7 +131,7 @@ define([
|
|||
},
|
||||
|
||||
getFocusedComponents: function() {
|
||||
return [this.spnColumns, this.spnSpacing];
|
||||
return [this.spnColumns, this.spnSpacing, this.chSeparator];
|
||||
},
|
||||
|
||||
getDefaultFocusableComponent: function () {
|
||||
|
|
|
@ -176,7 +176,7 @@ define([
|
|||
},
|
||||
|
||||
getFocusedComponents: function() {
|
||||
return [this.cmbLang, {cmp: this.listFormats, selector: '.listview'}];
|
||||
return [this.cmbLang, this.listFormats, this.chUpdate];
|
||||
},
|
||||
|
||||
getDefaultFocusableComponent: function () {
|
||||
|
|
|
@ -718,7 +718,7 @@ define([
|
|||
|
||||
getFocusedComponents: function() {
|
||||
return [
|
||||
this.cmbWidth, this.spnWidth, this.cmbHeight, this.spnHeight, this.cmbHAlign, this.cmbHRelative, this.spnX, this.cmbVAlign, this.cmbVRelative, this.spnY, // 0 tab
|
||||
this.cmbWidth, this.spnWidth, this.cmbHeight, this.spnHeight, this.cmbHAlign, this.cmbHRelative, this.spnX, this.cmbVAlign, this.cmbVRelative, this.spnY, this.chMove, // 0 tab
|
||||
this.cmbFonts, this.spnRowHeight, this.numDistance, // 1 tab
|
||||
this.spnMarginTop, this.spnMarginLeft, this.spnMarginBottom, this.spnMarginRight // 3 tab
|
||||
];
|
||||
|
|
|
@ -1155,13 +1155,13 @@ define([ 'text!documenteditor/main/app/template/ImageSettingsAdvanced.templat
|
|||
getFocusedComponents: function() {
|
||||
return [
|
||||
this.spnWidth, this.spnHeight, // 0 tab
|
||||
this.spnShapeWidth , this.spnShapeWidthPc, this.cmbWidthPc, this.spnShapeHeight, this.spnShapeHeightPc, this.cmbHeightPc, // 1 tab
|
||||
this.spnAngle, // 2 tab
|
||||
this.spnShapeWidth , this.spnShapeWidthPc, this.cmbWidthPc, this.spnShapeHeight, this.spnShapeHeightPc, this.cmbHeightPc, this.chRatio, // 1 tab
|
||||
this.spnAngle, this.chFlipHor, this.chFlipVert, // 2 tab
|
||||
this.spnTop, this.spnLeft, this.spnBottom, this.spnRight, // 3 tab
|
||||
this.cmbHAlign , this.cmbHRelative, this.spnX, this.cmbHPosition, this.spnXPc, this.cmbHPositionPc,
|
||||
this.cmbVAlign , this.cmbVRelative, this.spnY, this.cmbVPosition, this.spnYPc, this.cmbVPositionPc, // 4 tab
|
||||
this.cmbVAlign , this.cmbVRelative, this.spnY, this.cmbVPosition, this.spnYPc, this.cmbVPositionPc, this.chMove, this.chOverlap, // 4 tab
|
||||
this.cmbCapType, this.cmbJoinType, // 5 tab
|
||||
this.spnMarginTop, this.spnMarginLeft, this.spnMarginBottom, this.spnMarginRight, // 6 tab
|
||||
this.chAutofit, this.spnMarginTop, this.spnMarginLeft, this.spnMarginBottom, this.spnMarginRight, // 6 tab
|
||||
this.inputAltTitle, this.textareaAltDescription // 7 tab
|
||||
];
|
||||
},
|
||||
|
@ -1196,7 +1196,7 @@ define([ 'text!documenteditor/main/app/template/ImageSettingsAdvanced.templat
|
|||
me.cmbCapType.focus();
|
||||
break;
|
||||
case 6:
|
||||
me.spnMarginTop.focus();
|
||||
me.chAutofit.focus();
|
||||
break;
|
||||
case 7:
|
||||
me.inputAltTitle.focus();
|
||||
|
|
|
@ -163,6 +163,7 @@ define([
|
|||
el: $('#line-numbers-combo-apply'),
|
||||
cls: 'input-group-nr',
|
||||
menuStyle: 'min-width: 150px;',
|
||||
takeFocusOnClose: true,
|
||||
editable: false,
|
||||
data: [
|
||||
{ displayValue: this.textSection, value: Asc.c_oAscSectionApplyType.Current },
|
||||
|
@ -177,6 +178,14 @@ define([
|
|||
this.updateMetricUnit();
|
||||
},
|
||||
|
||||
getFocusedComponents: function() {
|
||||
return [this.chAddLineNumbering, this.spnStartAt, this.spnFromText, this.spnCountBy, this.cmbApply];
|
||||
},
|
||||
|
||||
getDefaultFocusableComponent: function () {
|
||||
return this.chAddLineNumbering;
|
||||
},
|
||||
|
||||
afterRender: function() {
|
||||
},
|
||||
|
||||
|
|
|
@ -340,7 +340,7 @@ define([
|
|||
},
|
||||
|
||||
getFocusedComponents: function() {
|
||||
return [this.cmbFormat, this.cmbAlign, this.cmbSize, {cmp: this.levelsList, selector: '.listview'}];
|
||||
return [this.cmbFormat, this.cmbAlign, this.cmbSize, this.levelsList];
|
||||
},
|
||||
|
||||
getDefaultFocusableComponent: function () {
|
||||
|
|
|
@ -88,6 +88,14 @@ define([
|
|||
});
|
||||
},
|
||||
|
||||
getFocusedComponents: function() {
|
||||
return [this.chFootnote, this.chEndnote];
|
||||
},
|
||||
|
||||
getDefaultFocusableComponent: function () {
|
||||
return this.chFootnote;
|
||||
},
|
||||
|
||||
_handleInput: function(state) {
|
||||
if (this.options.handler) {
|
||||
this.options.handler.call(this, this, state);
|
||||
|
|
|
@ -1010,10 +1010,10 @@ define([ 'text!documenteditor/main/app/template/TableSettingsAdvanced.templat
|
|||
|
||||
getFocusedComponents: function() {
|
||||
return [
|
||||
this.nfWidth, this.cmbUnit, this.spnTableMarginTop, this.spnTableMarginLeft, this.spnTableMarginBottom, this.spnTableMarginRight, this.nfSpacing, // 0 tab
|
||||
this.nfPrefWidth, this.cmbPrefWidthUnit, this.spnMarginTop, this.spnMarginLeft, this.spnMarginBottom, this.spnMarginRight, // 1 tab
|
||||
this.chWidth, this.nfWidth, this.cmbUnit, this.chAutofit, this.spnTableMarginTop, this.spnTableMarginLeft, this.spnTableMarginBottom, this.spnTableMarginRight, this.chAllowSpacing, this.nfSpacing, // 0 tab
|
||||
this.chPrefWidth, this.nfPrefWidth, this.cmbPrefWidthUnit, this.chCellMargins, this.spnMarginTop, this.spnMarginLeft, this.spnMarginBottom, this.spnMarginRight, this.chWrapText, // 1 tab
|
||||
this.cmbHAlign , this.cmbHRelative, this.spnX, this.cmbHPosition,
|
||||
this.cmbVAlign , this.cmbVRelative, this.spnY, this.cmbVPosition, // 3 tab
|
||||
this.cmbVAlign , this.cmbVRelative, this.spnY, this.cmbVPosition, this.chMove, this.chOverlap, // 3 tab
|
||||
this.spnIndentLeft, this.spnDistanceTop, this.spnDistanceLeft, this.spnDistanceBottom, this.spnDistanceRight, // 4 tab
|
||||
this.inputAltTitle, this.textareaAltDescription // 5 tab
|
||||
];
|
||||
|
@ -1035,8 +1035,8 @@ define([ 'text!documenteditor/main/app/template/TableSettingsAdvanced.templat
|
|||
me.onCellCategoryClick(btn);
|
||||
if (!me.nfPrefWidth.isDisabled())
|
||||
me.nfPrefWidth.focus();
|
||||
else if (!me.spnMarginTop.isDisabled())
|
||||
me.spnMarginTop.focus();
|
||||
else
|
||||
me.chPrefWidth.focus();
|
||||
break;
|
||||
case 3:
|
||||
if (!me.cmbHAlign.isDisabled())
|
||||
|
|
|
@ -383,7 +383,7 @@ define(['text!documenteditor/main/app/template/WatermarkSettings.template',
|
|||
},
|
||||
|
||||
getFocusedComponents: function() {
|
||||
return [ this.cmbLang, this.cmbText, this.cmbFonts, this.cmbFontSize, this.cmbScale ];
|
||||
return [ this.cmbLang, this.cmbText, this.cmbFonts, this.chTransparency, this.cmbFontSize, this.cmbScale ];
|
||||
},
|
||||
|
||||
getDefaultFocusableComponent: function () {
|
||||
|
|
Loading…
Reference in a new issue