diff --git a/apps/common/main/lib/component/ComboBox.js b/apps/common/main/lib/component/ComboBox.js index 490c834905..708719924e 100644 --- a/apps/common/main/lib/component/ComboBox.js +++ b/apps/common/main/lib/component/ComboBox.js @@ -232,7 +232,7 @@ define([ }, onBeforeShowMenu: function(e) { - Common.NotificationCenter.trigger('menu:show'); + Common.NotificationCenter.trigger('menu:show', this); this.trigger('show:before', this, e); if (this.options.hint) { var tip = this.cmpEl.data('bs.tooltip'); @@ -274,7 +274,7 @@ define([ onAfterHideMenu: function(e) { this.cmpEl.find('.dropdown-toggle').blur(); this.trigger('hide:after', this, e); - Common.NotificationCenter.trigger('menu:hide'); + Common.NotificationCenter.trigger('menu:hide', this); }, onAfterKeydownMenu: function(e) { diff --git a/apps/common/main/lib/component/Menu.js b/apps/common/main/lib/component/Menu.js index 636785a7e9..3cc78f0892 100644 --- a/apps/common/main/lib/component/Menu.js +++ b/apps/common/main/lib/component/Menu.js @@ -147,7 +147,7 @@ define([ }, template: _.template([ - '
' + '' ].join('')), initialize : function(options) { @@ -410,7 +410,7 @@ define([ }, onBeforeShowMenu: function(e) { - Common.NotificationCenter.trigger('menu:show'); + Common.NotificationCenter.trigger('menu:show', this); if (this.mustLayout) { delete this.mustLayout; @@ -441,7 +441,7 @@ define([ onAfterHideMenu: function(e) { this.trigger('hide:after', this, e); - Common.NotificationCenter.trigger('menu:hide'); + Common.NotificationCenter.trigger('menu:hide', this); }, onAfterKeydownMenu: function(e) { diff --git a/apps/common/main/lib/controller/Comments.js b/apps/common/main/lib/controller/Comments.js index 2101fc52c8..a4510b8ab4 100644 --- a/apps/common/main/lib/controller/Comments.js +++ b/apps/common/main/lib/controller/Comments.js @@ -1079,7 +1079,6 @@ define([ if (dialog) { if (this.popoverComments.length) { _.delay(function() { - me.api.asc_enableKeyEvents(false); dialog.commentsView.setFocusToTextBox(); }, 200); return; @@ -1234,7 +1233,6 @@ define([ var panel = $('.new-comment-ct', this.view.el); if (panel && panel.length) { if ('none' !== panel.css('display')) { - this.api.asc_enableKeyEvents(false); this.view.txtComment.focus(); } diff --git a/apps/documenteditor/main/app/controller/Main.js b/apps/documenteditor/main/app/controller/Main.js index 6b38ea688b..a7834fa6c8 100644 --- a/apps/documenteditor/main/app/controller/Main.js +++ b/apps/documenteditor/main/app/controller/Main.js @@ -155,18 +155,11 @@ define([ // Syncronize focus with api $(document.body).on('focus', 'input, textarea', function(e) { if (!/area_id/.test(e.target.id)) { - me.api.asc_enableKeyEvents(false); if (/msg-reply/.test(e.target.className)) me.dontCloseDummyComment = true; } }); - $("#editor_sdk").focus(function (e) { - if (!me.isModalShowed) { - me.api.asc_enableKeyEvents(true); - } - }); - $(document.body).on('blur', 'input, textarea', function(e) { if (!me.isModalShowed) { /* @@ -206,21 +199,13 @@ define([ } }, 'settings:unitschanged':_.bind(this.unitsChanged, this), - 'dataview:focus': function(e){ - me.api.asc_enableKeyEvents(false); - }, 'dataview:blur': function(e){ - if (!me.isModalShowed) { - me.api.asc_enableKeyEvents(true); - me.onEditComplete(); - } - }, - 'menu:show': function(e){ - me.api.asc_enableKeyEvents(false); - }, - 'menu:hide': function(e){ if (!me.isModalShowed) - me.api.asc_enableKeyEvents(true); + me.onEditComplete(); + }, + 'menu:hide': function(menu){ + if (!me.isModalShowed && menu.options.allowEditComplete) + me.onEditComplete(); }, 'edit:complete': _.bind(me.onEditComplete, me) }); diff --git a/apps/documenteditor/main/app/controller/Toolbar.js b/apps/documenteditor/main/app/controller/Toolbar.js index 9514c1a30f..002844f7e4 100644 --- a/apps/documenteditor/main/app/controller/Toolbar.js +++ b/apps/documenteditor/main/app/controller/Toolbar.js @@ -201,7 +201,6 @@ define([ toolbar.btnNumbers.on('click', _.bind(this.onNumbers, this)); toolbar.cmbFontName.on('selected', _.bind(this.onFontNameSelect, this)); toolbar.cmbFontName.on('show:after', _.bind(this.onComboOpen, this, true)); - toolbar.cmbFontName.on('hide:after', _.bind(this.onHideMenus, this)); toolbar.cmbFontName.on('combo:blur', _.bind(this.onComboBlur, this)); toolbar.cmbFontName.on('combo:focusin', _.bind(this.onComboOpen, this, false)); toolbar.cmbFontSize.on('selected', _.bind(this.onFontSizeSelect, this)); @@ -210,7 +209,6 @@ define([ toolbar.cmbFontSize.on('combo:blur', _.bind(this.onComboBlur, this)); toolbar.cmbFontSize.on('combo:focusin', _.bind(this.onComboOpen, this, false)); toolbar.cmbFontSize.on('show:after', _.bind(this.onComboOpen, this, true)); - toolbar.cmbFontSize.on('hide:after', _.bind(this.onHideMenus, this)); toolbar.mnuMarkersPicker.on('item:click', _.bind(this.onSelectBullets, this, toolbar.btnMarkers)); toolbar.mnuNumbersPicker.on('item:click', _.bind(this.onSelectBullets, this, toolbar.btnNumbers)); toolbar.mnuMultilevelPicker.on('item:click', _.bind(this.onSelectBullets, this, toolbar.btnMultilevels)); @@ -1107,7 +1105,6 @@ define([ msg: this.textFontSizeErr, callback: function() { _.defer(function(btn) { - me.api.asc_enableKeyEvents(false); $('input', combo.cmpEl).focus(); }) } @@ -2554,10 +2551,6 @@ define([ Common.component.Analytics.trackEvent('ToolBar', 'Highlight Color'); }, - onHideMenus: function(e){ - Common.NotificationCenter.trigger('edit:complete', this.toolbar); - }, - onSetupCopyStyleButton: function () { this.modeAlwaysSetStyle = false; diff --git a/apps/documenteditor/main/app/view/DocumentHolder.js b/apps/documenteditor/main/app/view/DocumentHolder.js index 5f8a2755a6..1ba4350806 100644 --- a/apps/documenteditor/main/app/view/DocumentHolder.js +++ b/apps/documenteditor/main/app/view/DocumentHolder.js @@ -110,9 +110,6 @@ define([ menu.alignPosition(); } _.delay(function() { - var value = Common.localStorage.getItem("de-settings-inputmode"); // only for hieroglyphs mode - if (value!==null && parseInt(value) == 1) - me.api.asc_enableKeyEvents(false); menu.cmpEl.focus(); }, 10); @@ -1616,7 +1613,6 @@ define([ addComment: function(item, e, eOpt){ if (this.api && this.mode.canCoAuthoring && this.mode.isEdit && this.mode.canComments) { this.suppressEditComplete = true; - this.api.asc_enableKeyEvents(false); var controller = DE.getController('Common.Controllers.Comments'); if (controller) { diff --git a/apps/documenteditor/main/app/view/MailMergeSettings.js b/apps/documenteditor/main/app/view/MailMergeSettings.js index 2ff261def8..c01b61a88d 100644 --- a/apps/documenteditor/main/app/view/MailMergeSettings.js +++ b/apps/documenteditor/main/app/view/MailMergeSettings.js @@ -108,6 +108,7 @@ define([ menu : new Common.UI.Menu({ style: 'min-width: 190px;max-width: 400px;', maxHeight: 200, + allowEditComplete: true, items: [] }).on('render:after', function(mnu) { this.scroller = new Common.UI.Scroller({ @@ -220,6 +221,7 @@ define([ menuStyle: 'min-width: 190px;', editable: false, data: this._arrMergeSrc, + allowEditComplete: true, lock: [_set.noRecipients, _set.lostConnect] }); this.cmbMergeTo.setValue(this._arrMergeSrc[0].value); diff --git a/apps/documenteditor/main/app/view/ParagraphSettings.js b/apps/documenteditor/main/app/view/ParagraphSettings.js index 3b60b32167..774c377926 100644 --- a/apps/documenteditor/main/app/view/ParagraphSettings.js +++ b/apps/documenteditor/main/app/view/ParagraphSettings.js @@ -100,6 +100,7 @@ define([ menuStyle: 'min-width: 85px;', editable: false, data: this._arrLineRule, + allowEditComplete: true, disabled: this._locked }); this.cmbLineRule.setValue(''); @@ -158,6 +159,7 @@ define([ style: "width:45px;", disabled: this._locked, menu : new Common.UI.Menu({ + allowEditComplete: true, items: [ { template: _.template('') }, { template: _.template('' + me.textNewColor + '') } @@ -199,7 +201,6 @@ define([ this.numSpacingAfter.on('change', _.bind(this.onNumSpacingAfterChange, this)); this.chAddInterval.on('change', _.bind(this.onAddIntervalChange, this)); this.cmbLineRule.on('selected', _.bind(this.onLineRuleSelect, this)); - this.cmbLineRule.on('hide:after', _.bind(this.onHideMenus, this)); $(this.el).on('click', '#paragraph-advanced-link', _.bind(this.openAdvancedSettings, this)); $(this.el).on('click', '#paragraph-color-new', _.bind(this.addNewColor, this)); this.TextOnlySettings = $('.text-only'); @@ -478,10 +479,6 @@ define([ this.mnuColorPicker.updateColors(Common.Utils.ThemeColor.getEffectColors(), Common.Utils.ThemeColor.getStandartColors()); }, - onHideMenus: function(e){ - this.fireEvent('editcomplete', this); - }, - setLocked: function (locked) { this._locked = locked; }, diff --git a/apps/documenteditor/main/app/view/ShapeSettings.js b/apps/documenteditor/main/app/view/ShapeSettings.js index e408d1a8dc..084ee72889 100644 --- a/apps/documenteditor/main/app/view/ShapeSettings.js +++ b/apps/documenteditor/main/app/view/ShapeSettings.js @@ -141,6 +141,7 @@ define([ style: 'width: 100%;', menuStyle: 'min-width: 190px;', editable: false, + allowEditComplete: true, data: this._arrFillSrc }); this.cmbFillSrc.setValue(this._arrFillSrc[0].value); @@ -150,6 +151,7 @@ define([ this.btnBackColor = new Common.UI.ColorButton({ style: "width:45px;", menu : new Common.UI.Menu({ + allowEditComplete: true, items: [ { template: _.template('') }, { template: _.template('' + me.textNewColor + '') } @@ -217,6 +219,7 @@ define([ this.btnFGColor = new Common.UI.ColorButton({ style: "width:45px;", menu : new Common.UI.Menu({ + allowEditComplete: true, items: [ { template: _.template('') }, { template: _.template('' + me.textNewColor + '') } @@ -258,6 +261,7 @@ define([ this.btnBGColor = new Common.UI.ColorButton({ style: "width:45px;", menu : new Common.UI.Menu({ + allowEditComplete: true, items: [ { template: _.template('') }, { template: _.template('' + me.textNewColor + '') } @@ -322,6 +326,7 @@ define([ cls: 'input-group-nr', menuStyle: 'min-width: 90px;', editable: false, + allowEditComplete: true, data: this._arrFillType }); this.cmbFillType.setValue(this._arrFillType[0].value); @@ -382,6 +387,7 @@ define([ cls: 'input-group-nr', menuStyle: 'min-width: 90px;', editable: false, + allowEditComplete: true, data: this._arrGradType }); this.cmbGradType.setValue(this._arrGradType[0].value); @@ -431,6 +437,7 @@ define([ this.btnGradColor = new Common.UI.ColorButton({ style: "width:45px;", menu : new Common.UI.Menu({ + allowEditComplete: true, items: [ { template: _.template('') }, { template: _.template('' + me.textNewColor + '') } @@ -491,6 +498,7 @@ define([ this.cmbBorderSize = new Common.UI.ComboBorderSizeEditable({ el: $('#shape-combo-border-size'), style: "width: 93px;", + allowEditComplete: true, txtNoBorders: this.txtNoBorders }) .on('selected', _.bind(this.onBorderSizeSelect, this)) @@ -504,6 +512,7 @@ define([ this.btnBorderColor = new Common.UI.ColorButton({ style: "width:45px;", menu : new Common.UI.Menu({ + allowEditComplete: true, items: [ { template: _.template('') }, { template: _.template('' + me.textNewColor + '') } @@ -545,6 +554,7 @@ define([ this.cmbBorderType = new Common.UI.ComboBorderType({ el: $('#shape-combo-border-type'), style: "width: 93px;", + allowEditComplete: true, menuStyle: 'min-width: 93px;' }).on('selected', _.bind(this.onBorderTypeSelect, this)) .on('combo:blur', _.bind(this.onComboBlur, this, false)); @@ -589,6 +599,7 @@ define([ menu : new Common.UI.Menu({ menuAlign: 'tr-br', cls: 'menu-shapes', + allowEditComplete: true, items: [] }) }); diff --git a/apps/documenteditor/main/app/view/Statusbar.js b/apps/documenteditor/main/app/view/Statusbar.js index ce82c50ae5..bcf6ed0f9c 100644 --- a/apps/documenteditor/main/app/view/Statusbar.js +++ b/apps/documenteditor/main/app/view/Statusbar.js @@ -208,7 +208,6 @@ define([ this.btnLanguage.cmpEl.on({ 'show.bs.dropdown': function () { _.defer(function(){ - me.api.asc_enableKeyEvents(false); me.btnLanguage.cmpEl.find('ul').focus(); }, 100); }, @@ -234,7 +233,6 @@ define([ }); this.cntZoom.cmpEl.on('show.bs.dropdown', function () { _.defer(function(){ - me.api.asc_enableKeyEvents(false); me.cntZoom.cmpEl.find('ul').focus(); }, 100); } @@ -351,7 +349,6 @@ define([ if (me.api && box) { box.focus(); // for IE box.parent().removeClass('open'); - me.api.asc_enableKeyEvents(true); } } diff --git a/apps/documenteditor/main/app/view/TableSettings.js b/apps/documenteditor/main/app/view/TableSettings.js index 033b01d73e..43f5effc92 100644 --- a/apps/documenteditor/main/app/view/TableSettings.js +++ b/apps/documenteditor/main/app/view/TableSettings.js @@ -216,6 +216,7 @@ define([ this.cmbBorderSize = new Common.UI.ComboBorderSize({ el: $('#table-combo-border-size'), + allowEditComplete: true, style: "width: 93px;" }); this.BorderSize = this.cmbBorderSize.store.at(1).get('value'); @@ -226,6 +227,7 @@ define([ this.btnBorderColor = new Common.UI.ColorButton({ style: "width:45px;", menu : new Common.UI.Menu({ + allowEditComplete: true, items: [ { template: _.template('') }, { template: _.template('' + me.textNewColor + '') } @@ -266,6 +268,7 @@ define([ this.btnBackColor = new Common.UI.ColorButton({ style: "width:45px;", menu : new Common.UI.Menu({ + allowEditComplete: true, items: [ { template: _.template('') }, { template: _.template('' + me.textNewColor + '') } @@ -306,6 +309,7 @@ define([ cls: 'btn-icon-default', iconCls: 'btn-edit-table', menu : new Common.UI.Menu({ + allowEditComplete: true, menuAlign: 'tr-br', items: [ { caption: this.selectRowText, value: 0 }, diff --git a/apps/documenteditor/main/app/view/TextArtSettings.js b/apps/documenteditor/main/app/view/TextArtSettings.js index bfc5760699..e3a0f7e8f6 100644 --- a/apps/documenteditor/main/app/view/TextArtSettings.js +++ b/apps/documenteditor/main/app/view/TextArtSettings.js @@ -139,6 +139,7 @@ define([ style: 'width: 100%;', menuStyle: 'min-width: 190px;', editable: false, + allowEditComplete: true, data: this._arrFillSrc }); this.cmbFillSrc.setValue(this._arrFillSrc[0].value); @@ -148,6 +149,7 @@ define([ this.btnBackColor = new Common.UI.ColorButton({ style: "width:45px;", menu : new Common.UI.Menu({ + allowEditComplete: true, items: [ { template: _.template('') }, { template: _.template('' + me.textNewColor + '') } @@ -222,6 +224,7 @@ define([ cls: 'input-group-nr', menuStyle: 'min-width: 90px;', editable: false, + allowEditComplete: true, data: this._arrGradType }); this.cmbGradType.setValue(this._arrGradType[0].value); @@ -270,6 +273,7 @@ define([ this.btnGradColor = new Common.UI.ColorButton({ style: "width:45px;", menu : new Common.UI.Menu({ + allowEditComplete: true, items: [ { template: _.template('') }, { template: _.template('' + me.textNewColor + '') } @@ -330,6 +334,7 @@ define([ this.cmbBorderSize = new Common.UI.ComboBorderSizeEditable({ el: $('#textart-combo-border-size'), style: "width: 93px;", + allowEditComplete: true, txtNoBorders: this.txtNoBorders }) .on('selected', _.bind(this.onBorderSizeSelect, this)) @@ -343,6 +348,7 @@ define([ this.btnBorderColor = new Common.UI.ColorButton({ style: "width:45px;", menu : new Common.UI.Menu({ + allowEditComplete: true, items: [ { template: _.template('') }, { template: _.template('' + me.textNewColor + '') } @@ -384,6 +390,7 @@ define([ this.cmbBorderType = new Common.UI.ComboBorderType({ el: $('#textart-combo-border-type'), style: "width: 93px;", + allowEditComplete: true, menuStyle: 'min-width: 93px;' }).on('selected', _.bind(this.onBorderTypeSelect, this)) .on('combo:blur', _.bind(this.onComboBlur, this, false)); diff --git a/apps/documenteditor/main/app/view/Toolbar.js b/apps/documenteditor/main/app/view/Toolbar.js index 622c01bb7c..80d44b92b1 100644 --- a/apps/documenteditor/main/app/view/Toolbar.js +++ b/apps/documenteditor/main/app/view/Toolbar.js @@ -244,6 +244,7 @@ define([ split : true, menu : new Common.UI.Menu({ style: 'min-width: 100px;', + allowEditComplete: true, items: [ { template: _.template('') }, { caption: '--' }, @@ -264,6 +265,7 @@ define([ hint : this.tipFontColor, split : true, menu : new Common.UI.Menu({ + allowEditComplete: true, items: [ { id : 'id-toolbar-menu-auto-fontcolor', @@ -285,6 +287,7 @@ define([ hint : this.tipPrColor, split : true, menu : new Common.UI.Menu({ + allowEditComplete: true, items: [ { template: _.template('') }, { template: _.template('' + this.textNewColor + '') } @@ -346,6 +349,7 @@ define([ icls : 'btn-align-left', menu : new Common.UI.Menu({ cls: 'ppm-toolbar', + allowEditComplete: true, items: [ { caption: this.tipAlignLeft + Common.Utils.String.platformKey('Ctrl+L'), @@ -408,6 +412,7 @@ define([ hint : this.tipLineSpace, menu : new Common.UI.Menu({ style: 'min-width: 60px;', + allowEditComplete: true, items: [ { caption: '1.0', value: 1.0, checkable: true, toggleGroup: 'linesize' }, { caption: '1.15', value: 1.15, checkable: true, toggleGroup: 'linesize' }, @@ -429,6 +434,7 @@ define([ split : true, menu : new Common.UI.Menu({ style: 'min-width: 60px;', + allowEditComplete: true, items: [ { caption: this.mniHiddenChars, value: 'characters', checkable: true }, { caption: this.mniHiddenBorders, value: 'table', checkable: true } @@ -491,6 +497,7 @@ define([ iconCls : 'btn-inserttable', hint : this.tipInsertTable, menu : new Common.UI.Menu({ + allowEditComplete: true, items: [ { template: _.template('') }, { caption: this.mniCustomTable, value: 'custom' } @@ -505,6 +512,7 @@ define([ iconCls : 'btn-insertimage', hint : this.tipInsertImage, menu : new Common.UI.Menu({ + allowEditComplete: true, items: [ { caption: this.mniImageFromFile, value: 'file' }, { caption: this.mniImageFromUrl, value: 'url' } @@ -560,6 +568,7 @@ define([ hint : this.tipPageBreak, split : true, menu : new Common.UI.Menu({ + allowEditComplete: true, items : [ {caption: this.textInsPageBreak}, {caption: this.textInsColumnBreak, value: 'column'}, @@ -595,6 +604,7 @@ define([ iconCls : 'btn-editheader', hint : this.tipEditHeader, menu : new Common.UI.Menu({ + allowEditComplete: true, items: [ { caption: this.mniEditHeader, value: 'header' }, { caption: this.mniEditFooter, value: 'footer' }, @@ -645,6 +655,7 @@ define([ hint : this.tipDropCap, menu : new Common.UI.Menu({ cls: 'ppm-toolbar', + allowEditComplete: true, items: [ { caption: this.textNone, iconCls: 'mnu-dropcap-none', checkable: true, toggleGroup: 'menuDropCap', value: Asc.c_oAscDropCap.None, checked: true }, { caption: this.textInText, iconCls: 'mnu-dropcap-intext', checkable: true, toggleGroup: 'menuDropCap', value: Asc.c_oAscDropCap.Drop }, @@ -663,6 +674,7 @@ define([ hint : this.tipColumns, menu : new Common.UI.Menu({ cls: 'ppm-toolbar', + allowEditComplete: true, items: [ { caption: this.textColumnsOne, iconCls: 'mnu-columns-one', checkable: true, toggleGroup: 'menuColumns', value: 0 }, { caption: this.textColumnsTwo, iconCls: 'mnu-columns-two', checkable: true, toggleGroup: 'menuColumns', value: 1 }, @@ -681,6 +693,7 @@ define([ hint : this.tipPageOrient, menu : new Common.UI.Menu({ cls: 'ppm-toolbar', + allowEditComplete: true, items: [ { caption: this.textPortrait, iconCls: 'mnu-orient-portrait', checkable: true, toggleGroup: 'menuOrient', value: true }, { caption: this.textLandscape, iconCls: 'mnu-orient-landscape', checkable: true, toggleGroup: 'menuOrient', value: false } @@ -704,6 +717,7 @@ define([ iconCls : 'btn-pagemargins', hint : this.tipPageMargins, menu : new Common.UI.Menu({ + allowEditComplete: true, items: [ { caption: this.textMarginsLast, checkable: true, template: pageMarginsTemplate, toggleGroup: 'menuPageMargins'}, //top,left,bottom,right { caption: this.textMarginsNormal, checkable: true, template: pageMarginsTemplate, toggleGroup: 'menuPageMargins', value: [20, 30, 20, 15] }, @@ -728,6 +742,7 @@ define([ iconCls : 'btn-pagesize', hint : this.tipPageSize, menu : new Common.UI.Menu({ + allowEditComplete: true, items: [ { caption: 'US Letter', subtitle: '21,59cm x 27,94cm', template: pageSizeTemplate, checkable: true, toggleGroup: 'menuPageSize', value: [215.9, 279.4] }, { caption: 'US Legal', subtitle: '21,59cm x 35,56cm', template: pageSizeTemplate, checkable: true, toggleGroup: 'menuPageSize', value: [215.9, 355.6] }, @@ -772,6 +787,7 @@ define([ iconCls : 'btn-colorschemas', hint : this.tipColorSchemas, menu : new Common.UI.Menu({ + allowEditComplete: true, items: [], maxHeight : 600, restoreHeight: 600 @@ -818,6 +834,7 @@ define([ menu : new Common.UI.Menu({ cls: 'pull-right', style: 'min-width: 180px;', + allowEditComplete: true, items: [ this.mnuitemCompactToolbar = new Common.UI.MenuItem({ caption : this.textCompactView, @@ -1104,6 +1121,7 @@ define([ cls: 'input-group-nr', menuStyle: 'min-width: 55px;', hint: this.tipFontSize, + allowEditComplete: true, data: [ { value: 8, displayValue: "8" }, { value: 9, displayValue: "9" }, @@ -1130,6 +1148,7 @@ define([ menuCls: 'scrollable-menu', menuStyle: 'min-width: 325px;', hint: this.tipFontName, + allowEditComplete: true, store: new Common.Collections.Fonts() }); this.paragraphControls.push(this.cmbFontName); @@ -1548,6 +1567,7 @@ define([ if (this.mnuColorSchema == null) { this.mnuColorSchema = new Common.UI.Menu({ + allowEditComplete: true, maxHeight : 600, restoreHeight: 600 }).on('render:after', function(mnu) {