diff --git a/apps/spreadsheeteditor/main/app/controller/DocumentHolder.js b/apps/spreadsheeteditor/main/app/controller/DocumentHolder.js index edf497e10..59a894376 100644 --- a/apps/spreadsheeteditor/main/app/controller/DocumentHolder.js +++ b/apps/spreadsheeteditor/main/app/controller/DocumentHolder.js @@ -1483,8 +1483,10 @@ define([ var pluginGuid = (documentHolder.mnuImgAdvanced.imageInfo) ? documentHolder.mnuImgAdvanced.imageInfo.asc_getPluginGuid() : null; documentHolder.menuImgReplace.setVisible(isimageonly && (pluginGuid===null || pluginGuid===undefined)); documentHolder.menuImgReplace.setDisabled(isObjLocked || pluginGuid===null); - - + documentHolder.mnuBringToFront.setDisabled(isObjLocked); + documentHolder.mnuSendToBack.setDisabled(isObjLocked); + documentHolder.mnuBringForward.setDisabled(isObjLocked); + documentHolder.mnuSendBackward.setDisabled(isObjLocked); var isInSign = !!signGuid; documentHolder.menuSignatureEditSign.setVisible(isInSign); diff --git a/apps/spreadsheeteditor/main/app/view/DocumentHolder.js b/apps/spreadsheeteditor/main/app/view/DocumentHolder.js index f518b031e..4ca60400e 100644 --- a/apps/spreadsheeteditor/main/app/view/DocumentHolder.js +++ b/apps/spreadsheeteditor/main/app/view/DocumentHolder.js @@ -605,6 +605,30 @@ define([ }) }); + me.mnuBringToFront = new Common.UI.MenuItem({ + caption : this.textArrangeFront, + iconCls : 'mnu-arrange-front', + type : 'arrange', + value : Asc.c_oAscDrawingLayerType.BringToFront + }); + me.mnuSendToBack = new Common.UI.MenuItem({ + caption : this.textArrangeBack, + iconCls : 'mnu-arrange-back', + type : 'arrange', + value : Asc.c_oAscDrawingLayerType.SendToBack + }); + me.mnuBringForward = new Common.UI.MenuItem({ + caption : this.textArrangeForward, + iconCls : 'mnu-arrange-forward', + type : 'arrange', + value : Asc.c_oAscDrawingLayerType.BringForward + }); + me.mnuSendBackward = new Common.UI.MenuItem({ + caption: this.textArrangeBackward, + iconCls : 'mnu-arrange-backward', + type : 'arrange', + value : Asc.c_oAscDrawingLayerType.SendBackward + }); this.imgMenu = new Common.UI.Menu({ items: [ me.pmiImgCut, @@ -614,27 +638,10 @@ define([ me.menuSignatureEditSign, me.menuSignatureEditSetup, me.menuEditSignSeparator, - { - caption : this.textArrangeFront, - iconCls : 'mnu-arrange-front', - type : 'arrange', - value : Asc.c_oAscDrawingLayerType.BringToFront - },{ - caption : this.textArrangeBack, - iconCls : 'mnu-arrange-back', - type : 'arrange', - value : Asc.c_oAscDrawingLayerType.SendToBack - },{ - caption : this.textArrangeForward, - iconCls : 'mnu-arrange-forward', - type : 'arrange', - value : Asc.c_oAscDrawingLayerType.BringForward - },{ - caption: this.textArrangeBackward, - iconCls : 'mnu-arrange-backward', - type : 'arrange', - value : Asc.c_oAscDrawingLayerType.SendBackward - }, + me.mnuBringToFront, + me.mnuSendToBack, + me.mnuBringForward, + me.mnuSendBackward, {caption: '--'}, me.mnuGroupImg, me.mnuUnGroupImg, diff --git a/apps/spreadsheeteditor/main/app/view/Toolbar.js b/apps/spreadsheeteditor/main/app/view/Toolbar.js index dcee358b6..e06de2902 100644 --- a/apps/spreadsheeteditor/main/app/view/Toolbar.js +++ b/apps/spreadsheeteditor/main/app/view/Toolbar.js @@ -1410,7 +1410,7 @@ define([ cls: 'btn-toolbar x-huge icon-top', iconCls: 'btn-img-align', caption: me.capImgAlign, - lock : [_set.selRange, _set.selRangeEdit, _set.cantGroup, _set.lostConnect, _set.coAuth], + lock : [_set.selRange, _set.selRangeEdit, _set.cantGroup, _set.lostConnect, _set.coAuth, _set.coAuthText], menu: true }); @@ -1418,7 +1418,7 @@ define([ cls: 'btn-toolbar x-huge icon-top', iconCls: 'btn-img-group', caption: me.capImgGroup, - lock : [_set.selRange, _set.selRangeEdit, _set.cantGroupUngroup, _set.lostConnect, _set.coAuth], + lock : [_set.selRange, _set.selRangeEdit, _set.cantGroupUngroup, _set.lostConnect, _set.coAuth, _set.coAuthText], menu: true }); me.btnImgForward = new Common.UI.Button({ @@ -1426,14 +1426,14 @@ define([ iconCls: 'btn-img-frwd', caption: me.capImgForward, split: true, - lock : [_set.selRange, _set.selRangeEdit, _set.lostConnect, _set.coAuth], + lock : [_set.selRange, _set.selRangeEdit, _set.lostConnect, _set.coAuth, _set.coAuthText], menu: true }); me.btnImgBackward = new Common.UI.Button({ cls: 'btn-toolbar x-huge icon-top', iconCls: 'btn-img-bkwd', caption: me.capImgBackward, - lock : [_set.selRange, _set.selRangeEdit, _set.lostConnect, _set.coAuth], + lock : [_set.selRange, _set.selRangeEdit, _set.lostConnect, _set.coAuth, _set.coAuthText], split: true, menu: true });