From 9778cfa82d59f84c30b469f4ff363fbe64017739 Mon Sep 17 00:00:00 2001 From: "Julia.Svinareva" Date: Tue, 21 Nov 2023 20:20:31 +0300 Subject: [PATCH 1/2] [DE PE SSE PDF] Fix focus and disabling of plugin buttons --- apps/common/main/lib/component/SideMenu.js | 3 ++- apps/common/main/lib/view/Plugins.js | 1 + apps/documenteditor/main/app/controller/LeftMenu.js | 1 + apps/pdfeditor/main/app/controller/LeftMenu.js | 1 + apps/presentationeditor/main/app/controller/LeftMenu.js | 1 + apps/spreadsheeteditor/main/app/controller/LeftMenu.js | 1 + 6 files changed, 7 insertions(+), 1 deletion(-) diff --git a/apps/common/main/lib/component/SideMenu.js b/apps/common/main/lib/component/SideMenu.js index bff4e986ca..76ccaf2dec 100644 --- a/apps/common/main/lib/component/SideMenu.js +++ b/apps/common/main/lib/component/SideMenu.js @@ -46,6 +46,7 @@ define([ Common.UI.SideMenu = Backbone.View.extend((function () { return { + buttons: [], btnMoreContainer: undefined, render: function () { @@ -123,7 +124,7 @@ define([ caption: btn.hint, iconImg: btn.options.iconImg, template: _.template([ - '', + '', '', '<%= caption %>', '' diff --git a/apps/common/main/lib/view/Plugins.js b/apps/common/main/lib/view/Plugins.js index 0fcc87e9b5..964d44fd12 100644 --- a/apps/common/main/lib/view/Plugins.js +++ b/apps/common/main/lib/view/Plugins.js @@ -333,6 +333,7 @@ define([ dataHintDirection: 'bottom', dataHintOffset: 'small' }); + this.lockedControls.push(btn); return btn; }, diff --git a/apps/documenteditor/main/app/controller/LeftMenu.js b/apps/documenteditor/main/app/controller/LeftMenu.js index f4b77cf723..b709a2fabe 100644 --- a/apps/documenteditor/main/app/controller/LeftMenu.js +++ b/apps/documenteditor/main/app/controller/LeftMenu.js @@ -645,6 +645,7 @@ define([ this.viewmode = viewmode; this.leftMenu.panelSearch && this.leftMenu.panelSearch.setSearchMode(this.viewmode ? 'no-replace' : 'search'); + this.leftMenu.setDisabledPluginButtons(this.viewmode); }, SetDisabled: function(disable, options) { diff --git a/apps/pdfeditor/main/app/controller/LeftMenu.js b/apps/pdfeditor/main/app/controller/LeftMenu.js index a6edca1336..e01776f2d6 100644 --- a/apps/pdfeditor/main/app/controller/LeftMenu.js +++ b/apps/pdfeditor/main/app/controller/LeftMenu.js @@ -568,6 +568,7 @@ define([ var viewmode = this._state.disableEditing; if (this.viewmode === viewmode) return; this.viewmode = viewmode; + this.leftMenu.setDisabledPluginButtons(this.viewmode); }, SetDisabled: function(disable, options) { diff --git a/apps/presentationeditor/main/app/controller/LeftMenu.js b/apps/presentationeditor/main/app/controller/LeftMenu.js index 843ac706df..8025102d9d 100644 --- a/apps/presentationeditor/main/app/controller/LeftMenu.js +++ b/apps/presentationeditor/main/app/controller/LeftMenu.js @@ -498,6 +498,7 @@ define([ this.viewmode = mode; this.leftMenu.panelSearch && this.leftMenu.panelSearch.setSearchMode(this.viewmode ? 'no-replace' : 'search'); + this.leftMenu.setDisabledPluginButtons(this.viewmode); }, onApiServerDisconnect: function(enableDownload) { diff --git a/apps/spreadsheeteditor/main/app/controller/LeftMenu.js b/apps/spreadsheeteditor/main/app/controller/LeftMenu.js index 6097f5b311..10810f4c00 100644 --- a/apps/spreadsheeteditor/main/app/controller/LeftMenu.js +++ b/apps/spreadsheeteditor/main/app/controller/LeftMenu.js @@ -629,6 +629,7 @@ define([ this.viewmode = mode; this.leftMenu.panelSearch && this.leftMenu.panelSearch.setSearchMode(this.viewmode ? 'no-replace' : 'search'); + this.leftMenu.setDisabledPluginButtons(this.viewmode); }, onApiServerDisconnect: function(enableDownload) { From 22b08215aaae94b78690906fd3ea2f4355ff1b73 Mon Sep 17 00:00:00 2001 From: "Julia.Svinareva" Date: Wed, 22 Nov 2023 17:20:29 +0300 Subject: [PATCH 2/2] [SSE] Fix bug 49203 --- apps/spreadsheeteditor/main/app/controller/DocumentHolder.js | 1 + apps/spreadsheeteditor/main/app/view/PivotSettings.js | 1 + 2 files changed, 2 insertions(+) diff --git a/apps/spreadsheeteditor/main/app/controller/DocumentHolder.js b/apps/spreadsheeteditor/main/app/controller/DocumentHolder.js index be7bcee6b2..8ba243fc35 100644 --- a/apps/spreadsheeteditor/main/app/controller/DocumentHolder.js +++ b/apps/spreadsheeteditor/main/app/controller/DocumentHolder.js @@ -192,6 +192,7 @@ define([ me.onCellsRange(status); }, 'tabs:dragend': _.bind(me.onDragEndMouseUp, me), + 'pivot:dragend': _.bind(me.onDragEndMouseUp, me), 'protect:wslock': _.bind(me.onChangeProtectSheet, me) }); Common.Gateway.on('processmouse', _.bind(me.onProcessMouse, me)); diff --git a/apps/spreadsheeteditor/main/app/view/PivotSettings.js b/apps/spreadsheeteditor/main/app/view/PivotSettings.js index 1be0a5a448..05e73dd360 100644 --- a/apps/spreadsheeteditor/main/app/view/PivotSettings.js +++ b/apps/spreadsheeteditor/main/app/view/PivotSettings.js @@ -208,6 +208,7 @@ define([ onDragEnd: function() { this._dragEl && this._dragEl.remove(); this._dragEl = null; + Common.NotificationCenter.trigger('pivot:dragend', this); }, onFieldsDragStart: function (item, index, event) {