[PE][SSE] Fix Bug 38948
This commit is contained in:
parent
0a819bf668
commit
3165fa2da9
|
@ -607,7 +607,7 @@ define([
|
||||||
this._state.no_slides = (count<=0);
|
this._state.no_slides = (count<=0);
|
||||||
this.toolbar.lockToolbar(PE.enumLock.noSlides, this._state.no_slides, {array: this.toolbar.paragraphControls});
|
this.toolbar.lockToolbar(PE.enumLock.noSlides, this._state.no_slides, {array: this.toolbar.paragraphControls});
|
||||||
this.toolbar.lockToolbar(PE.enumLock.noSlides, this._state.no_slides, {array: [
|
this.toolbar.lockToolbar(PE.enumLock.noSlides, this._state.no_slides, {array: [
|
||||||
this.toolbar.btnChangeSlide, this.toolbar.btnPreview, this.toolbar.btnCopy, this.toolbar.btnPaste,
|
this.toolbar.btnChangeSlide, this.toolbar.btnPreview, this.toolbar.btnPrint, this.toolbar.btnCopy, this.toolbar.btnPaste,
|
||||||
this.toolbar.btnCopyStyle, this.toolbar.btnInsertTable, this.toolbar.btnInsertChart,
|
this.toolbar.btnCopyStyle, this.toolbar.btnInsertTable, this.toolbar.btnInsertChart,
|
||||||
this.toolbar.btnColorSchemas, this.toolbar.btnShapeAlign,
|
this.toolbar.btnColorSchemas, this.toolbar.btnShapeAlign,
|
||||||
this.toolbar.btnShapeArrange, this.toolbar.btnSlideSize, this.toolbar.listTheme
|
this.toolbar.btnShapeArrange, this.toolbar.btnSlideSize, this.toolbar.listTheme
|
||||||
|
|
|
@ -175,9 +175,9 @@ define([
|
||||||
id: 'id-toolbar-btn-print',
|
id: 'id-toolbar-btn-print',
|
||||||
cls: 'btn-toolbar',
|
cls: 'btn-toolbar',
|
||||||
iconCls: 'btn-print no-mask',
|
iconCls: 'btn-print no-mask',
|
||||||
lock: [_set.slideDeleted, _set.noSlides, _set.cantPrint]
|
lock: [_set.slideDeleted, _set.noSlides, _set.cantPrint, _set.disableOnStart]
|
||||||
});
|
});
|
||||||
me.paragraphControls.push(me.btnPrint);
|
me.slideOnlyControls.push(me.btnPrint);
|
||||||
|
|
||||||
me.btnSave = new Common.UI.Button({
|
me.btnSave = new Common.UI.Button({
|
||||||
id: 'id-toolbar-btn-save',
|
id: 'id-toolbar-btn-save',
|
||||||
|
|
|
@ -730,6 +730,7 @@ define([
|
||||||
|
|
||||||
me.fillTextArt(me.api.asc_getTextArtPreviews());
|
me.fillTextArt(me.api.asc_getTextArtPreviews());
|
||||||
me.updateThemeColors();
|
me.updateThemeColors();
|
||||||
|
toolbarController.activateControls();
|
||||||
}
|
}
|
||||||
|
|
||||||
rightmenuController.createDelayedElements();
|
rightmenuController.createDelayedElements();
|
||||||
|
|
|
@ -121,6 +121,7 @@ define([
|
||||||
this.editMode = true;
|
this.editMode = true;
|
||||||
this._isAddingShape = false;
|
this._isAddingShape = false;
|
||||||
this._state = {
|
this._state = {
|
||||||
|
activated: false,
|
||||||
prstyle: undefined,
|
prstyle: undefined,
|
||||||
clrtext: undefined,
|
clrtext: undefined,
|
||||||
pralign: undefined,
|
pralign: undefined,
|
||||||
|
@ -2915,6 +2916,11 @@ define([
|
||||||
this._state.namedrange_locked = (state == Asc.c_oAscDefinedNameReason.LockDefNameManager);
|
this._state.namedrange_locked = (state == Asc.c_oAscDefinedNameReason.LockDefNameManager);
|
||||||
},
|
},
|
||||||
|
|
||||||
|
activateControls: function() {
|
||||||
|
this.toolbar.lockToolbar(SSE.enumLock.disableOnStart, false, {array: [this.toolbar.btnPrint]});
|
||||||
|
this._state.activated = true;
|
||||||
|
},
|
||||||
|
|
||||||
DisableToolbar: function(disable, viewMode) {
|
DisableToolbar: function(disable, viewMode) {
|
||||||
if (viewMode!==undefined) this.editMode = !viewMode;
|
if (viewMode!==undefined) this.editMode = !viewMode;
|
||||||
disable = disable || !this.editMode;
|
disable = disable || !this.editMode;
|
||||||
|
|
|
@ -80,7 +80,8 @@ define([
|
||||||
multiselect: 'is-multiselect',
|
multiselect: 'is-multiselect',
|
||||||
cantHyperlink: 'cant-hyperlink',
|
cantHyperlink: 'cant-hyperlink',
|
||||||
commentLock: 'can-comment',
|
commentLock: 'can-comment',
|
||||||
cantModifyFilter: 'cant-filter'
|
cantModifyFilter: 'cant-filter',
|
||||||
|
disableOnStart: 'on-start'
|
||||||
};
|
};
|
||||||
|
|
||||||
SSE.Views.Toolbar = Common.UI.Mixtbar.extend(_.extend({
|
SSE.Views.Toolbar = Common.UI.Mixtbar.extend(_.extend({
|
||||||
|
@ -380,7 +381,7 @@ define([
|
||||||
id : 'id-toolbar-btn-print',
|
id : 'id-toolbar-btn-print',
|
||||||
cls : 'btn-toolbar',
|
cls : 'btn-toolbar',
|
||||||
iconCls : 'btn-print no-mask',
|
iconCls : 'btn-print no-mask',
|
||||||
lock : [_set.editCell, _set.cantPrint]
|
lock : [_set.editCell, _set.cantPrint, _set.disableOnStart]
|
||||||
});
|
});
|
||||||
|
|
||||||
me.btnSave = new Common.UI.Button({
|
me.btnSave = new Common.UI.Button({
|
||||||
|
@ -1258,6 +1259,7 @@ define([
|
||||||
if (cmp && _.isFunction(cmp.setDisabled))
|
if (cmp && _.isFunction(cmp.setDisabled))
|
||||||
cmp.setDisabled(true);
|
cmp.setDisabled(true);
|
||||||
});
|
});
|
||||||
|
this.lockToolbar(SSE.enumLock.disableOnStart, true, {array: [me.btnPrint]});
|
||||||
|
|
||||||
this.on('render:after', _.bind(this.onToolbarAfterRender, this));
|
this.on('render:after', _.bind(this.onToolbarAfterRender, this));
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue