[SSE] Open context menu while loading application

This commit is contained in:
Julia Radzhabova 2018-12-06 14:00:25 +03:00 committed by Alexey Golubev
parent ba72dba53b
commit 3bce27a587

View file

@ -215,12 +215,6 @@ define([
if (documentHolderEl) { if (documentHolderEl) {
documentHolderEl.on({ documentHolderEl.on({
keydown: function(e) {
if (e.keyCode == e.F10 && e.shiftKey) {
e.stopEvent();
me.showObjectMenu(e);
}
},
mousedown: function(e) { mousedown: function(e) {
if (e.target.localName == 'canvas' && e.button != 2) { if (e.target.localName == 'canvas' && e.button != 2) {
Common.UI.Menu.Manager.hideAll(); Common.UI.Menu.Manager.hideAll();
@ -1433,7 +1427,7 @@ define([
} }
if (isimagemenu || isshapemenu || ischartmenu) { if (isimagemenu || isshapemenu || ischartmenu) {
if (!showMenu && !documentHolder.imgMenu.isVisible()) return; if (!documentHolder.imgMenu || !showMenu && !documentHolder.imgMenu.isVisible()) return;
isimagemenu = isshapemenu = ischartmenu = false; isimagemenu = isshapemenu = ischartmenu = false;
var has_chartprops = false, var has_chartprops = false,
@ -1500,7 +1494,7 @@ define([
if (showMenu) this.showPopupMenu(documentHolder.imgMenu, {}, event); if (showMenu) this.showPopupMenu(documentHolder.imgMenu, {}, event);
documentHolder.mnuShapeSeparator.setVisible(documentHolder.mnuShapeAdvanced.isVisible() || documentHolder.mnuChartEdit.isVisible() || documentHolder.mnuImgAdvanced.isVisible()); documentHolder.mnuShapeSeparator.setVisible(documentHolder.mnuShapeAdvanced.isVisible() || documentHolder.mnuChartEdit.isVisible() || documentHolder.mnuImgAdvanced.isVisible());
} else if (istextshapemenu || istextchartmenu) { } else if (istextshapemenu || istextchartmenu) {
if (!showMenu && !documentHolder.textInShapeMenu.isVisible()) return; if (!documentHolder.textInShapeMenu || !showMenu && !documentHolder.textInShapeMenu.isVisible()) return;
documentHolder.pmiTextAdvanced.textInfo = undefined; documentHolder.pmiTextAdvanced.textInfo = undefined;
@ -1560,7 +1554,7 @@ define([
if (showMenu) this.showPopupMenu(documentHolder.textInShapeMenu, {}, event); if (showMenu) this.showPopupMenu(documentHolder.textInShapeMenu, {}, event);
} else if (!this.permissions.isEditMailMerge && !this.permissions.isEditDiagram || (seltype !== Asc.c_oAscSelectionType.RangeImage && seltype !== Asc.c_oAscSelectionType.RangeShape && } else if (!this.permissions.isEditMailMerge && !this.permissions.isEditDiagram || (seltype !== Asc.c_oAscSelectionType.RangeImage && seltype !== Asc.c_oAscSelectionType.RangeShape &&
seltype !== Asc.c_oAscSelectionType.RangeChart && seltype !== Asc.c_oAscSelectionType.RangeChartText && seltype !== Asc.c_oAscSelectionType.RangeShapeText)) { seltype !== Asc.c_oAscSelectionType.RangeChart && seltype !== Asc.c_oAscSelectionType.RangeChartText && seltype !== Asc.c_oAscSelectionType.RangeShapeText)) {
if (!showMenu && !documentHolder.ssMenu.isVisible()) return; if (!documentHolder.ssMenu || !showMenu && !documentHolder.ssMenu.isVisible()) return;
var iscelledit = this.api.isCellEdited, var iscelledit = this.api.isCellEdited,
formatTableInfo = cellinfo.asc_getFormatTableInfo(), formatTableInfo = cellinfo.asc_getFormatTableInfo(),