[DE] Lock controls when document is protected (read only mode)
This commit is contained in:
parent
ca9b1bcf22
commit
b898aee927
|
@ -111,6 +111,7 @@ define([
|
|||
Common.NotificationCenter.on('collaboration:sharing', this.changeAccessRights.bind(this));
|
||||
Common.NotificationCenter.on('collaboration:sharingdeny', this.onLostEditRights.bind(this));
|
||||
Common.NotificationCenter.on('protect:wslock', _.bind(this.onChangeProtectSheet, this));
|
||||
Common.NotificationCenter.on('protect:doclock', _.bind(this.onChangeProtectDocument, this));
|
||||
|
||||
this.userCollection.on('reset', _.bind(this.onUpdateUsers, this));
|
||||
this.userCollection.on('add', _.bind(this.onUpdateUsers, this));
|
||||
|
@ -890,6 +891,7 @@ define([
|
|||
});
|
||||
}
|
||||
me.onChangeProtectSheet();
|
||||
me.onChangeProtectDocument();
|
||||
if (me.view) {
|
||||
me.lockToolbar(Common.enumLock.hideComments, !Common.localStorage.getBool(me.view.appPrefix + "settings-livecomment", true), {array: [me.view.btnCommentRemove, me.view.btnCommentResolve]});
|
||||
me.lockToolbar(Common.enumLock['Objects'], !!this._state.wsProps['Objects'], {array: [me.view.btnCommentRemove, me.view.btnCommentResolve]});
|
||||
|
@ -1011,6 +1013,20 @@ define([
|
|||
this.lockToolbar(Common.enumLock['Objects'], !!this._state.wsProps['Objects'], {array: [this.view.btnCommentRemove, this.view.btnCommentResolve]});
|
||||
},
|
||||
|
||||
onChangeProtectDocument: function(props) {
|
||||
if (!props) {
|
||||
var docprotect = this.getApplication().getController('DocProtection');
|
||||
props = docprotect ? docprotect.getDocProps() : null;
|
||||
}
|
||||
if (props) {
|
||||
this._state.docProtection = props;
|
||||
this.lockToolbar(Common.enumLock.docLockView, props.docLock && (props.lockMode===Asc.c_oAscProtection.View));
|
||||
this.lockToolbar(Common.enumLock.docLockForms, props.docLock && (props.lockMode===Asc.c_oAscProtection.Forms));
|
||||
this.lockToolbar(Common.enumLock.docLockReview, props.docLock && (props.lockMode===Asc.c_oAscProtection.Review));
|
||||
this.lockToolbar(Common.enumLock.docLockComments, props.docLock && (props.lockMode===Asc.c_oAscProtection.Comments));
|
||||
}
|
||||
},
|
||||
|
||||
textInserted: '<b>Inserted:</b>',
|
||||
textDeleted: '<b>Deleted:</b>',
|
||||
textParaInserted: '<b>Paragraph Inserted</b> ',
|
||||
|
|
|
@ -259,7 +259,7 @@ define([
|
|||
caption: this.txtAccept,
|
||||
split: !this.appConfig.canUseReviewPermissions,
|
||||
iconCls: 'toolbar__icon btn-review-save',
|
||||
lock: [_set.reviewChangelock, _set.isReviewOnly, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect],
|
||||
lock: [_set.reviewChangelock, _set.isReviewOnly, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.docLockView],
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'bottom',
|
||||
dataHintOffset: 'small'
|
||||
|
@ -271,7 +271,7 @@ define([
|
|||
caption: this.txtReject,
|
||||
split: !this.appConfig.canUseReviewPermissions,
|
||||
iconCls: 'toolbar__icon btn-review-deny',
|
||||
lock: [_set.reviewChangelock, _set.isReviewOnly, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect],
|
||||
lock: [_set.reviewChangelock, _set.isReviewOnly, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.docLockView],
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'bottom',
|
||||
dataHintOffset: 'small'
|
||||
|
@ -284,7 +284,7 @@ define([
|
|||
caption: this.txtCompare,
|
||||
split: true,
|
||||
iconCls: 'toolbar__icon btn-compare',
|
||||
lock: [_set.hasCoeditingUsers, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect],
|
||||
lock: [_set.hasCoeditingUsers, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.docLockView],
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'bottom',
|
||||
dataHintOffset: 'small'
|
||||
|
@ -294,7 +294,7 @@ define([
|
|||
this.btnTurnOn = new Common.UI.Button({
|
||||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-ic-review',
|
||||
lock: [_set.previewReviewMode, _set.viewFormMode, _set.lostConnect],
|
||||
lock: [_set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.docLockView],
|
||||
caption: this.txtTurnon,
|
||||
split: !this.appConfig.isReviewOnly,
|
||||
enableToggle: true,
|
||||
|
@ -309,7 +309,7 @@ define([
|
|||
this.btnPrev = new Common.UI.Button({
|
||||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-review-prev',
|
||||
lock: [_set.previewReviewMode, _set.viewFormMode, _set.lostConnect],
|
||||
lock: [_set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.docLockView],
|
||||
caption: this.txtPrev,
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'bottom',
|
||||
|
@ -320,7 +320,7 @@ define([
|
|||
this.btnNext = new Common.UI.Button({
|
||||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-review-next',
|
||||
lock: [_set.previewReviewMode, _set.viewFormMode, _set.lostConnect],
|
||||
lock: [_set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.docLockView],
|
||||
caption: this.txtNext,
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'bottom',
|
||||
|
@ -336,7 +336,7 @@ define([
|
|||
this.btnReviewView = new Common.UI.Button({
|
||||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-ic-reviewview',
|
||||
lock: [_set.viewFormMode, _set.lostConnect],
|
||||
lock: [_set.viewFormMode, _set.lostConnect, _set.docLockView],
|
||||
caption: this.txtView,
|
||||
menu: new Common.UI.Menu({
|
||||
cls: 'ppm-toolbar',
|
||||
|
@ -404,7 +404,7 @@ define([
|
|||
this.btnCoAuthMode = new Common.UI.Button({
|
||||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-ic-coedit',
|
||||
lock: [_set.viewFormMode, _set.lostConnect],
|
||||
lock: [_set.viewFormMode, _set.lostConnect, _set.docLockView],
|
||||
caption: this.txtCoAuthMode,
|
||||
menu: true,
|
||||
dataHint: '1',
|
||||
|
@ -450,7 +450,7 @@ define([
|
|||
caption: this.txtCommentRemove,
|
||||
split: true,
|
||||
iconCls: 'toolbar__icon btn-rem-comment',
|
||||
lock: [_set.previewReviewMode, _set.viewFormMode, _set.hideComments, _set['Objects'], _set.lostConnect],
|
||||
lock: [_set.previewReviewMode, _set.viewFormMode, _set.hideComments, _set['Objects'], _set.lostConnect, _set.docLockView],
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'bottom',
|
||||
dataHintOffset: 'small'
|
||||
|
@ -461,7 +461,7 @@ define([
|
|||
caption: this.txtCommentResolve,
|
||||
split: true,
|
||||
iconCls: 'toolbar__icon btn-resolve-all',
|
||||
lock: [_set.previewReviewMode, _set.viewFormMode, _set.hideComments, _set['Objects'], _set.lostConnect],
|
||||
lock: [_set.previewReviewMode, _set.viewFormMode, _set.hideComments, _set['Objects'], _set.lostConnect, _set.docLockView],
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'bottom',
|
||||
dataHintOffset: 'small'
|
||||
|
@ -731,7 +731,7 @@ define([
|
|||
var button = new Common.UI.Button({
|
||||
cls : 'btn-toolbar',
|
||||
iconCls : 'toolbar__icon btn-ic-review',
|
||||
lock: [Common.enumLock.viewMode, Common.enumLock.previewReviewMode, Common.enumLock.viewFormMode, Common.enumLock.lostConnect],
|
||||
lock: [Common.enumLock.viewMode, Common.enumLock.previewReviewMode, Common.enumLock.viewFormMode, Common.enumLock.lostConnect, Common.enumLock.docLockView],
|
||||
hintAnchor : 'top',
|
||||
hint : this.tipReview,
|
||||
split : !this.appConfig.isReviewOnly,
|
||||
|
@ -778,7 +778,7 @@ define([
|
|||
button = new Common.UI.Button({
|
||||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon btn-ic-docspell',
|
||||
lock: [Common.enumLock.viewMode, Common.enumLock.viewFormMode, Common.enumLock.previewReviewMode],
|
||||
lock: [Common.enumLock.viewMode, Common.enumLock.viewFormMode, Common.enumLock.previewReviewMode, Common.enumLock.docLockView],
|
||||
hintAnchor : 'top',
|
||||
hint: this.tipSetSpelling,
|
||||
enableToggle: true,
|
||||
|
@ -794,7 +794,7 @@ define([
|
|||
button = new Common.UI.Button({
|
||||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon btn-ic-doclang',
|
||||
lock: [Common.enumLock.viewMode, Common.enumLock.previewReviewMode, Common.enumLock.viewFormMode, Common.enumLock.noSpellcheckLangs, Common.enumLock.lostConnect],
|
||||
lock: [Common.enumLock.viewMode, Common.enumLock.previewReviewMode, Common.enumLock.viewFormMode, Common.enumLock.noSpellcheckLangs, Common.enumLock.lostConnect, Common.enumLock.docLockView],
|
||||
hintAnchor : 'top',
|
||||
hint: this.tipSetDocLang,
|
||||
dataHint: '0',
|
||||
|
|
|
@ -46,6 +46,13 @@ define([
|
|||
], function () {
|
||||
'use strict';
|
||||
|
||||
Asc.c_oAscProtection = {
|
||||
View: 1,
|
||||
Forms: 2,
|
||||
Review: 3,
|
||||
Comments: 4
|
||||
};
|
||||
|
||||
if (!Common.enumLock)
|
||||
Common.enumLock = {};
|
||||
|
||||
|
@ -121,9 +128,12 @@ define([
|
|||
btn = result;
|
||||
if (result == 'ok') {
|
||||
// var props = me.api.asc_getProtectedDocument();
|
||||
// props.asc_setLockMode(props);
|
||||
// props.asc_setType(props);
|
||||
// props.asc_setLockPwd(value);
|
||||
// me.api.asc_setProtectedDocument(props);
|
||||
|
||||
me.view.btnProtectDoc.toggle(true, true); // test
|
||||
me.onChangeProtectDocument(); // test
|
||||
}
|
||||
Common.NotificationCenter.trigger('edit:complete');
|
||||
}
|
||||
|
@ -136,8 +146,10 @@ define([
|
|||
} else {
|
||||
var me = this,
|
||||
btn,
|
||||
props = me.api.asc_getProtectedDocument();
|
||||
if (props.asc_isPassword()) {
|
||||
// props = me.api.asc_getProtectedDocument();
|
||||
props = undefined; // test
|
||||
// if (props.asc_isPassword()) {
|
||||
if (props && props.asc_isPassword()) {
|
||||
var win = new Common.Views.OpenDialog({
|
||||
title: me.view.txtWBUnlockTitle,
|
||||
closable: true,
|
||||
|
@ -161,8 +173,10 @@ define([
|
|||
|
||||
win.show();
|
||||
} else {
|
||||
props.asc_setLockPwd();
|
||||
me.api.asc_setProtectedDocument(props);
|
||||
me.view.btnProtectDoc.toggle(false, true); // test
|
||||
me.onChangeProtectDocument(); // test
|
||||
// props.asc_setLockPwd();
|
||||
// me.api.asc_setProtectedDocument(props);
|
||||
}
|
||||
}
|
||||
},
|
||||
|
@ -179,24 +193,37 @@ define([
|
|||
},
|
||||
|
||||
onChangeProtectDocument: function() {
|
||||
// this.view && this.view.btnProtectDoc.toggle(this.api.asc_isProtectedDocument(), true);
|
||||
// var isProtected = this.api.asc_isProtectedDocument();
|
||||
var isProtected = this.view.btnProtectDoc.isActive(); // test
|
||||
this.view && this.view.btnProtectDoc.toggle(isProtected, true);
|
||||
var props = this.getDocProps(true);
|
||||
Common.NotificationCenter.trigger('protect:doclock', props);
|
||||
},
|
||||
|
||||
getDocProps: function(update) {
|
||||
if (!this.appConfig || !this.appConfig.isEdit && !this.appConfig.isRestrictedEdit) return;
|
||||
|
||||
if (update || !this._state.protection) {
|
||||
var docProtected = !!this.api.asc_isProtectedDocument(),
|
||||
if (update || !this._state.docProtection) {
|
||||
// var docProtected = !!this.api.asc_isProtectedDocument(),
|
||||
// type;
|
||||
//
|
||||
// if (docProtected) {
|
||||
// var props = this.api.asc_getProtectedDocument();
|
||||
// type = props.asc_getType();
|
||||
// }
|
||||
|
||||
// test //////
|
||||
var docProtected = this.view.btnProtectDoc.isActive(),
|
||||
type;
|
||||
|
||||
if (docProtected) {
|
||||
var props = this.api.asc_getProtectedDocument();
|
||||
type = props.asc_getLockMode();
|
||||
type = Asc.c_oAscProtection.View;
|
||||
}
|
||||
this._state.protection = {docLock: docProtected, lockMode: type};
|
||||
/////////////
|
||||
this._state.docProtection = {docLock: docProtected, lockMode: type};
|
||||
}
|
||||
|
||||
return this._state.protection;
|
||||
return this._state.docProtection;
|
||||
}
|
||||
|
||||
}, DE.Controllers.DocProtection || {}));
|
||||
|
|
|
@ -226,7 +226,7 @@ define([
|
|||
this.api.asc_registerCallback('asc_onShowContentControlsActions',_.bind(this.onShowContentControlsActions, this));
|
||||
this.api.asc_registerCallback('asc_onHideContentControlsActions',_.bind(this.onHideContentControlsActions, this));
|
||||
}
|
||||
|
||||
Common.NotificationCenter.on('protect:doclock', _.bind(this.onChangeProtectDocument, this));
|
||||
this.documentHolder.setApi(this.api);
|
||||
}
|
||||
|
||||
|
@ -585,7 +585,9 @@ define([
|
|||
showObjectMenu: function(event, docElement, eOpts){
|
||||
var me = this;
|
||||
if (me.api){
|
||||
var obj = (me.mode.isEdit && !me._isDisabled) ? me.fillMenuProps(me.api.getSelectedElements()) : me.fillViewMenuProps(me.api.getSelectedElements());
|
||||
var lockMode = this.documentHolder.docProtection ? this.documentHolder.docProtection.lockMode : undefined;
|
||||
var obj = (me.mode.isEdit && !(me._isDisabled || lockMode===Asc.c_oAscProtection.View || lockMode===Asc.c_oAscProtection.Comments || lockMode===Asc.c_oAscProtection.Forms)) ?
|
||||
me.fillMenuProps(me.api.getSelectedElements()) : me.fillViewMenuProps(me.api.getSelectedElements());
|
||||
if (obj) me.showPopupMenu(obj.menu_to_show, obj.menu_props, event, docElement, eOpts);
|
||||
}
|
||||
},
|
||||
|
@ -612,7 +614,9 @@ define([
|
|||
var me = this,
|
||||
currentMenu = me.documentHolder.currentMenu;
|
||||
if (currentMenu && currentMenu.isVisible() && currentMenu !== me.documentHolder.hdrMenu){
|
||||
var obj = (me.mode.isEdit && !me._isDisabled) ? me.fillMenuProps(selectedElements) : me.fillViewMenuProps(selectedElements);
|
||||
var lockMode = me.documentHolder.docProtection ? me.documentHolder.docProtection.lockMode : undefined;
|
||||
var obj = (me.mode.isEdit && !(me._isDisabled || lockMode===Asc.c_oAscProtection.View || lockMode===Asc.c_oAscProtection.Comments || lockMode===Asc.c_oAscProtection.Forms)) ?
|
||||
me.fillMenuProps(selectedElements) : me.fillViewMenuProps(selectedElements);
|
||||
if (obj) {
|
||||
if (obj.menu_to_show===currentMenu) {
|
||||
currentMenu.options.initMenu(obj.menu_props);
|
||||
|
@ -1180,7 +1184,8 @@ define([
|
|||
},
|
||||
|
||||
onDoubleClickOnChart: function(chart) {
|
||||
if (this.mode.isEdit && !this._isDisabled) {
|
||||
var lockMode = this.documentHolder.docProtection ? this.documentHolder.docProtection.lockMode : undefined;
|
||||
if (this.mode.isEdit && !(this._isDisabled || lockMode===Asc.c_oAscProtection.View || lockMode===Asc.c_oAscProtection.Comments || lockMode===Asc.c_oAscProtection.Forms)) {
|
||||
var diagramEditor = this.getApplication().getController('Common.Controllers.ExternalDiagramEditor').getView('Common.Views.ExternalDiagramEditor');
|
||||
if (diagramEditor && chart) {
|
||||
diagramEditor.setEditMode(true);
|
||||
|
@ -1191,7 +1196,8 @@ define([
|
|||
},
|
||||
|
||||
onDoubleClickOnTableOleObject: function(chart) {
|
||||
if (this.mode.isEdit && !this._isDisabled) {
|
||||
var lockMode = this.documentHolder.docProtection ? this.documentHolder.docProtection.lockMode : undefined;
|
||||
if (this.mode.isEdit && !(this._isDisabled || lockMode===Asc.c_oAscProtection.View || lockMode===Asc.c_oAscProtection.Comments || lockMode===Asc.c_oAscProtection.Forms)) {
|
||||
var oleEditor = this.getApplication().getController('Common.Controllers.ExternalOleEditor').getView('Common.Views.ExternalOleEditor');
|
||||
if (oleEditor && chart) {
|
||||
oleEditor.setEditMode(true);
|
||||
|
@ -1895,7 +1901,8 @@ define([
|
|||
this.api.asc_ViewCertificate(datavalue); //certificate id
|
||||
break;
|
||||
case 2:
|
||||
Common.NotificationCenter.trigger('protect:signature', 'visible', this._isDisabled, datavalue);//guid, can edit settings for requested signature
|
||||
var lockMode = this.documentHolder.docProtection ? this.documentHolder.docProtection.lockMode : undefined;
|
||||
Common.NotificationCenter.trigger('protect:signature', 'visible', this._isDisabled || lockMode===Asc.c_oAscProtection.View || lockMode===Asc.c_oAscProtection.Comments || lockMode===Asc.c_oAscProtection.Forms, datavalue);//guid, can edit settings for requested signature
|
||||
break;
|
||||
case 3:
|
||||
var me = this;
|
||||
|
@ -2310,6 +2317,16 @@ define([
|
|||
|
||||
editComplete: function() {
|
||||
this.documentHolder && this.documentHolder.fireEvent('editcomplete', this.documentHolder);
|
||||
},
|
||||
|
||||
onChangeProtectDocument: function(props) {
|
||||
if (!props) {
|
||||
var docprotect = this.getApplication().getController('DocProtection');
|
||||
props = docprotect ? docprotect.getDocProps() : null;
|
||||
}
|
||||
if (props) {
|
||||
this.documentHolder && (this.documentHolder.docProtection = props);
|
||||
}
|
||||
}
|
||||
});
|
||||
});
|
|
@ -76,6 +76,7 @@ define([
|
|||
// this.api.asc_registerCallback('asc_onShowContentControlsActions',_.bind(this.onShowContentControlsActions, this));
|
||||
// this.api.asc_registerCallback('asc_onHideContentControlsActions',_.bind(this.onHideContentControlsActions, this));
|
||||
}
|
||||
Common.NotificationCenter.on('protect:doclock', _.bind(this.onChangeProtectDocument, this));
|
||||
return this;
|
||||
},
|
||||
|
||||
|
@ -430,6 +431,21 @@ define([
|
|||
if (tab !== 'forms') {
|
||||
this.tipSaveForm && this.tipSaveForm.close();
|
||||
}
|
||||
},
|
||||
|
||||
onChangeProtectDocument: function(props) {
|
||||
if (!props) {
|
||||
var docprotect = this.getApplication().getController('DocProtection');
|
||||
props = docprotect ? docprotect.getDocProps() : null;
|
||||
}
|
||||
if (props) {
|
||||
this._state.docProtection = props;
|
||||
var arr = this.view.getButtons();
|
||||
Common.Utils.lockControls(Common.enumLock.docLockView, props.docLock && (props.lockMode===Asc.c_oAscProtection.View)), {array: arr};
|
||||
Common.Utils.lockControls(Common.enumLock.docLockForms, props.docLock && (props.lockMode===Asc.c_oAscProtection.Forms), {array: arr});
|
||||
Common.Utils.lockControls(Common.enumLock.docLockReview, props.docLock && (props.lockMode===Asc.c_oAscProtection.Review), {array: arr});
|
||||
Common.Utils.lockControls(Common.enumLock.docLockComments, props.docLock && (props.lockMode===Asc.c_oAscProtection.Comments), {array: arr});
|
||||
}
|
||||
}
|
||||
|
||||
}, DE.Controllers.FormsTab || {}));
|
||||
|
|
|
@ -108,6 +108,7 @@ define([
|
|||
this.api.asc_registerCallback('asc_onAscReplaceCurrentTOF',_.bind(this.onAscReplaceCurrentTOF, this));
|
||||
this.api.asc_registerCallback('asc_onAscTOFUpdate',_.bind(this.onAscTOFUpdate, this));
|
||||
}
|
||||
Common.NotificationCenter.on('protect:doclock', _.bind(this.onChangeProtectDocument, this));
|
||||
return this;
|
||||
},
|
||||
|
||||
|
@ -570,6 +571,20 @@ define([
|
|||
Common.NotificationCenter.trigger('edit:complete', me.toolbar);
|
||||
}
|
||||
})).show();
|
||||
},
|
||||
|
||||
onChangeProtectDocument: function(props) {
|
||||
if (!props) {
|
||||
var docprotect = this.getApplication().getController('DocProtection');
|
||||
props = docprotect ? docprotect.getDocProps() : null;
|
||||
}
|
||||
if (props) {
|
||||
this._state.docProtection = props;
|
||||
this.lockToolbar(Common.enumLock.docLockView, props.docLock && (props.lockMode===Asc.c_oAscProtection.View));
|
||||
this.lockToolbar(Common.enumLock.docLockForms, props.docLock && (props.lockMode===Asc.c_oAscProtection.Forms));
|
||||
this.lockToolbar(Common.enumLock.docLockReview, props.docLock && (props.lockMode===Asc.c_oAscProtection.Review));
|
||||
this.lockToolbar(Common.enumLock.docLockComments, props.docLock && (props.lockMode===Asc.c_oAscProtection.Comments));
|
||||
}
|
||||
}
|
||||
|
||||
}, DE.Controllers.Links || {}));
|
||||
|
|
|
@ -57,7 +57,7 @@ define([
|
|||
onLaunch: function (view) {
|
||||
this.toolbar = view;
|
||||
this.editMode = true;
|
||||
|
||||
this._state = {};
|
||||
return this;
|
||||
},
|
||||
|
||||
|
@ -98,7 +98,7 @@ define([
|
|||
this.api.asc_registerCallback('asc_onImgWrapStyleChanged', this.onApiWrappingStyleChanged.bind(this));
|
||||
this.api.asc_registerCallback('asc_onCoAuthoringDisconnect', this.onApiCoAuthoringDisconnect.bind(this));
|
||||
this.api.asc_registerCallback('asc_onFocusObject', this.onApiFocusObject.bind(this));
|
||||
|
||||
Common.NotificationCenter.on('protect:doclock', _.bind(this.onChangeProtectDocument, this));
|
||||
return this;
|
||||
},
|
||||
|
||||
|
@ -255,6 +255,20 @@ define([
|
|||
|
||||
this.api.ImgApply(props);
|
||||
this.toolbar.fireEvent('editcomplete', this.toolbar);
|
||||
},
|
||||
|
||||
onChangeProtectDocument: function(props) {
|
||||
if (!props) {
|
||||
var docprotect = this.getApplication().getController('DocProtection');
|
||||
props = docprotect ? docprotect.getDocProps() : null;
|
||||
}
|
||||
if (props) {
|
||||
this._state.docProtection = props;
|
||||
this.toolbar.lockToolbar(Common.enumLock.docLockView, props.docLock && (props.lockMode===Asc.c_oAscProtection.View));
|
||||
this.toolbar.lockToolbar(Common.enumLock.docLockForms, props.docLock && (props.lockMode===Asc.c_oAscProtection.Forms));
|
||||
this.toolbar.lockToolbar(Common.enumLock.docLockReview, props.docLock && (props.lockMode===Asc.c_oAscProtection.Review));
|
||||
this.toolbar.lockToolbar(Common.enumLock.docLockComments, props.docLock && (props.lockMode===Asc.c_oAscProtection.Comments));
|
||||
}
|
||||
}
|
||||
}
|
||||
})());
|
||||
|
|
|
@ -54,7 +54,7 @@ define([
|
|||
initialize: function() {
|
||||
this.editMode = true;
|
||||
this._initSettings = true;
|
||||
|
||||
this._state = {};
|
||||
this.addListeners({
|
||||
'RightMenu': {
|
||||
'rightmenuclick': this.onRightMenuClick
|
||||
|
@ -89,6 +89,7 @@ define([
|
|||
setApi: function(api) {
|
||||
this.api = api;
|
||||
this.api.asc_registerCallback('asc_onUpdateSignatures', _.bind(this.onApiUpdateSignatures, this));
|
||||
Common.NotificationCenter.on('protect:doclock', _.bind(this.onChangeProtectDocument, this));
|
||||
this.api.asc_registerCallback('asc_onCoAuthoringDisconnect',_.bind(this.onCoAuthoringDisconnect, this));
|
||||
Common.NotificationCenter.on('api:disconnect', _.bind(this.onCoAuthoringDisconnect, this));
|
||||
},
|
||||
|
@ -156,7 +157,10 @@ define([
|
|||
this._settings[Common.Utils.documentSettingsType.Signature].locked = false;
|
||||
|
||||
var isChart = false,
|
||||
isSmartArtInternal = false;
|
||||
isSmartArtInternal = false,
|
||||
lockMode = this._state.docProtection ? this._state.docProtection.lockMode : undefined;
|
||||
lockMode = (lockMode===Asc.c_oAscProtection.View || lockMode===Asc.c_oAscProtection.Forms || lockMode===Asc.c_oAscProtection.Comments);
|
||||
|
||||
var control_props = this.api.asc_IsContentControl() ? this.api.asc_GetContentControlProperties() : null,
|
||||
control_lock = false;
|
||||
for (i=0; i<SelectedObjects.length; i++)
|
||||
|
@ -185,7 +189,7 @@ define([
|
|||
if (value.get_ShapeProperties().asc_getTextArtProperties()) {
|
||||
this._settings[Common.Utils.documentSettingsType.TextArt].props = value;
|
||||
this._settings[Common.Utils.documentSettingsType.TextArt].hidden = 0;
|
||||
this._settings[Common.Utils.documentSettingsType.TextArt].locked = value.get_Locked() || content_locked;
|
||||
this._settings[Common.Utils.documentSettingsType.TextArt].locked = value.get_Locked() || content_locked || lockMode;
|
||||
}
|
||||
}
|
||||
control_lock = control_lock || value.get_Locked();
|
||||
|
@ -197,11 +201,11 @@ define([
|
|||
}
|
||||
this._settings[settingsType].props = value;
|
||||
this._settings[settingsType].hidden = 0;
|
||||
this._settings[settingsType].locked = value.get_Locked() || content_locked;
|
||||
this._settings[settingsType].locked = value.get_Locked() || content_locked || lockMode;
|
||||
if (!this._settings[Common.Utils.documentSettingsType.MailMerge].locked) // lock MailMerge-InsertField, если хотя бы один объект locked
|
||||
this._settings[Common.Utils.documentSettingsType.MailMerge].locked = value.get_Locked();
|
||||
this._settings[Common.Utils.documentSettingsType.MailMerge].locked = value.get_Locked() || lockMode;
|
||||
if (!this._settings[Common.Utils.documentSettingsType.Signature].locked) // lock Signature, если хотя бы один объект locked
|
||||
this._settings[Common.Utils.documentSettingsType.Signature].locked = value.get_Locked();
|
||||
this._settings[Common.Utils.documentSettingsType.Signature].locked = value.get_Locked() || lockMode;
|
||||
}
|
||||
|
||||
if (control_props && control_props.get_FormPr() && this.rightmenu.formSettings) {
|
||||
|
@ -210,7 +214,7 @@ define([
|
|||
spectype==Asc.c_oAscContentControlSpecificType.ComboBox || spectype==Asc.c_oAscContentControlSpecificType.DropDownList || spectype==Asc.c_oAscContentControlSpecificType.None) {
|
||||
settingsType = Common.Utils.documentSettingsType.Form;
|
||||
this._settings[settingsType].props = control_props;
|
||||
this._settings[settingsType].locked = control_lock;
|
||||
this._settings[settingsType].locked = control_lock || lockMode;
|
||||
this._settings[settingsType].hidden = 0;
|
||||
if (control_props.get_FormPr().get_Fixed())
|
||||
this._settings[Common.Utils.documentSettingsType.TextArt].hidden = 1;
|
||||
|
@ -466,6 +470,19 @@ define([
|
|||
case Asc.c_oAscTypeSelectElement.Header:
|
||||
return Common.Utils.documentSettingsType.Header;
|
||||
}
|
||||
},
|
||||
|
||||
onChangeProtectDocument: function(props) {
|
||||
if (!props) {
|
||||
var docprotect = this.getApplication().getController('DocProtection');
|
||||
props = docprotect ? docprotect.getDocProps() : null;
|
||||
}
|
||||
if (props) {
|
||||
this._state.docProtection = props;
|
||||
}
|
||||
var selectedElements = this.api.getSelectedElements();
|
||||
if (selectedElements.length > 0)
|
||||
this.onFocusObject(selectedElements);
|
||||
}
|
||||
});
|
||||
});
|
|
@ -122,7 +122,7 @@ define([
|
|||
me.statusbar.$el.find('.hide-select-tools').removeClass('hide-select-tools');
|
||||
}
|
||||
});
|
||||
|
||||
Common.NotificationCenter.on('protect:doclock', _.bind(this.onChangeProtectDocument, this));
|
||||
Common.NotificationCenter.on('app:ready', me.onAppReady.bind(me));
|
||||
},
|
||||
|
||||
|
@ -358,6 +358,14 @@ define([
|
|||
}
|
||||
},
|
||||
|
||||
onChangeProtectDocument: function(props) {
|
||||
if (!props) {
|
||||
var docprotect = this.getApplication().getController('DocProtection');
|
||||
props = docprotect ? docprotect.getDocProps() : null;
|
||||
}
|
||||
props && this.statusbar.onChangeProtectDocument(props);
|
||||
},
|
||||
|
||||
zoomText : 'Zoom {0}%',
|
||||
textHasChanges : 'New changes have been tracked',
|
||||
textTrackChanges: 'The document is opened with the Track Changes mode enabled',
|
||||
|
|
|
@ -430,6 +430,7 @@ define([
|
|||
this.api.asc_registerCallback('asc_onCoAuthoringDisconnect', _.bind(this.onApiCoAuthoringDisconnect, this));
|
||||
Common.NotificationCenter.on('api:disconnect', _.bind(this.onApiCoAuthoringDisconnect, this));
|
||||
}
|
||||
Common.NotificationCenter.on('protect:doclock', _.bind(this.onChangeProtectDocument, this));
|
||||
},
|
||||
|
||||
onChangeCompactView: function(view, compact) {
|
||||
|
@ -3263,7 +3264,7 @@ define([
|
|||
this.btnsComment = Common.Utils.injectButtons(this.toolbar.$el.find('.slot-comment'), 'tlbtn-addcomment-', 'toolbar__icon btn-menu-comments', this.toolbar.capBtnComment,
|
||||
[ Common.enumLock.paragraphLock, Common.enumLock.headerLock, Common.enumLock.richEditLock, Common.enumLock.plainEditLock, Common.enumLock.richDelLock, Common.enumLock.plainDelLock,
|
||||
Common.enumLock.cantAddQuotedComment, Common.enumLock.imageLock, Common.enumLock.inSpecificForm, Common.enumLock.inImage, Common.enumLock.lostConnect, Common.enumLock.disableOnStart,
|
||||
Common.enumLock.previewReviewMode, Common.enumLock.viewFormMode ],
|
||||
Common.enumLock.previewReviewMode, Common.enumLock.viewFormMode, Common.enumLock.docLockView ],
|
||||
undefined, undefined, undefined, '1', 'bottom');
|
||||
if ( this.btnsComment.length ) {
|
||||
var _comments = DE.getController('Common.Controllers.Comments').getView();
|
||||
|
@ -3331,6 +3332,20 @@ define([
|
|||
})).show();
|
||||
},
|
||||
|
||||
onChangeProtectDocument: function(props) {
|
||||
if (!props) {
|
||||
var docprotect = this.getApplication().getController('DocProtection');
|
||||
props = docprotect ? docprotect.getDocProps() : null;
|
||||
}
|
||||
if (props) {
|
||||
this._state.docProtection = props;
|
||||
this.toolbar.lockToolbar(Common.enumLock.docLockView, props.docLock && (props.lockMode===Asc.c_oAscProtection.View));
|
||||
this.toolbar.lockToolbar(Common.enumLock.docLockForms, props.docLock && (props.lockMode===Asc.c_oAscProtection.Forms));
|
||||
this.toolbar.lockToolbar(Common.enumLock.docLockReview, props.docLock && (props.lockMode===Asc.c_oAscProtection.Review));
|
||||
this.toolbar.lockToolbar(Common.enumLock.docLockComments, props.docLock && (props.lockMode===Asc.c_oAscProtection.Comments));
|
||||
}
|
||||
},
|
||||
|
||||
textEmptyImgUrl : 'You need to specify image URL.',
|
||||
textWarning : 'Warning',
|
||||
textFontSizeErr : 'The entered value is incorrect.<br>Please enter a numeric value between 1 and 300',
|
||||
|
|
|
@ -79,7 +79,7 @@ define([
|
|||
iconCls: 'toolbar__icon protect-workbook',
|
||||
enableToggle: true,
|
||||
caption: this.txtProtectDoc,
|
||||
lock : [_set.lostConnect, _set.coAuth],
|
||||
lock : [_set.lostConnect, _set.coAuth, _set.previewReviewMode, _set.viewFormMode],
|
||||
dataHint : '1',
|
||||
dataHintDirection: 'bottom',
|
||||
dataHintOffset: 'small'
|
||||
|
|
|
@ -152,6 +152,7 @@ define([
|
|||
signGuid = (value.imgProps && value.imgProps.value && me.mode.isSignatureSupport) ? value.imgProps.value.asc_getSignatureId() : undefined,
|
||||
signProps = (signGuid) ? me.api.asc_getSignatureSetup(signGuid) : null,
|
||||
isInSign = !!signProps && me._canProtect,
|
||||
lockMode = me.docProtection ? me.docProtection.lockMode : undefined,
|
||||
control_lock = (value.paraProps) ? (!value.paraProps.value.can_DeleteBlockContentControl() || !value.paraProps.value.can_EditBlockContentControl() ||
|
||||
!value.paraProps.value.can_DeleteInlineContentControl() || !value.paraProps.value.can_EditInlineContentControl()) : false,
|
||||
canComment = !isInChart && me.api.can_AddQuotedComment() !== false && me.mode.canCoAuthoring && me.mode.canComments && !me._isDisabled && !control_lock,
|
||||
|
@ -169,7 +170,7 @@ define([
|
|||
}
|
||||
|
||||
me.menuViewUndo.setVisible(me.mode.canCoAuthoring && me.mode.canComments && !me._isDisabled);
|
||||
me.menuViewUndo.setDisabled(!me.api.asc_getCanUndo());
|
||||
me.menuViewUndo.setDisabled(!me.api.asc_getCanUndo() || lockMode===Asc.c_oAscProtection.View || lockMode===Asc.c_oAscProtection.Forms);
|
||||
me.menuViewCopySeparator.setVisible(isInSign);
|
||||
|
||||
var isRequested = (signProps) ? signProps.asc_getRequested() : false;
|
||||
|
@ -187,15 +188,15 @@ define([
|
|||
}
|
||||
|
||||
me.menuViewAddComment.setVisible(canComment);
|
||||
me.menuViewAddComment.setDisabled(value.paraProps && value.paraProps.locked === true);
|
||||
me.menuViewAddComment.setDisabled(value.paraProps && value.paraProps.locked === true || lockMode===Asc.c_oAscProtection.View || lockMode===Asc.c_oAscProtection.Forms);
|
||||
|
||||
var disabled = value.paraProps && value.paraProps.locked === true;
|
||||
var cancopy = me.api && me.api.can_CopyCut();
|
||||
me.menuViewCopy.setDisabled(!cancopy);
|
||||
me.menuViewCut.setVisible(me._fillFormMode && canEditControl);
|
||||
me.menuViewCut.setDisabled(disabled || !cancopy);
|
||||
me.menuViewCut.setDisabled(disabled || !cancopy || lockMode===Asc.c_oAscProtection.View || lockMode===Asc.c_oAscProtection.Comments);
|
||||
me.menuViewPaste.setVisible(me._fillFormMode && canEditControl);
|
||||
me.menuViewPaste.setDisabled(disabled);
|
||||
me.menuViewPaste.setDisabled(disabled || lockMode===Asc.c_oAscProtection.View || lockMode===Asc.c_oAscProtection.Comments);
|
||||
me.menuViewPrint.setVisible(me.mode.canPrint && !me._fillFormMode);
|
||||
me.menuViewPrint.setDisabled(!cancopy);
|
||||
|
||||
|
|
|
@ -169,7 +169,7 @@ define([
|
|||
this.btnTextField = new Common.UI.Button({
|
||||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-text-field',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.controlPlain, _set.contentLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.controlPlain, _set.contentLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: this.capBtnText,
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'bottom',
|
||||
|
@ -180,7 +180,7 @@ define([
|
|||
this.btnComboBox = new Common.UI.Button({
|
||||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-combo-box',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.controlPlain, _set.contentLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.controlPlain, _set.contentLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: this.capBtnComboBox,
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'bottom',
|
||||
|
@ -191,7 +191,7 @@ define([
|
|||
this.btnDropDown = new Common.UI.Button({
|
||||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-dropdown',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.controlPlain, _set.contentLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.controlPlain, _set.contentLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: this.capBtnDropDown,
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'bottom',
|
||||
|
@ -202,7 +202,7 @@ define([
|
|||
this.btnCheckBox = new Common.UI.Button({
|
||||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-checkbox',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.controlPlain, _set.contentLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.controlPlain, _set.contentLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: this.capBtnCheckBox,
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'bottom',
|
||||
|
@ -213,7 +213,7 @@ define([
|
|||
this.btnRadioBox = new Common.UI.Button({
|
||||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-radio-button',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.controlPlain, _set.contentLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.controlPlain, _set.contentLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: this.capBtnRadioBox,
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'bottom',
|
||||
|
@ -224,7 +224,7 @@ define([
|
|||
this.btnImageField = new Common.UI.Button({
|
||||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-insertimage',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.controlPlain, _set.contentLock, _set.complexForm, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.controlPlain, _set.contentLock, _set.complexForm, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: this.capBtnImage,
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'bottom',
|
||||
|
@ -235,7 +235,7 @@ define([
|
|||
this.btnEmailField = new Common.UI.Button({
|
||||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-email',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.controlPlain, _set.contentLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.controlPlain, _set.contentLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: this.capBtnEmail,
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'bottom',
|
||||
|
@ -246,7 +246,7 @@ define([
|
|||
this.btnPhoneField = new Common.UI.Button({
|
||||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-phone',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.controlPlain, _set.contentLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.controlPlain, _set.contentLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: this.capBtnPhone,
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'bottom',
|
||||
|
@ -257,7 +257,7 @@ define([
|
|||
this.btnComplexField = new Common.UI.Button({
|
||||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon complex-field',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.controlPlain, _set.contentLock, _set.complexForm, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.controlPlain, _set.contentLock, _set.complexForm, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: this.capBtnComplex,
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'bottom',
|
||||
|
@ -268,7 +268,7 @@ define([
|
|||
this.btnViewForm = new Common.UI.Button({
|
||||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-sheet-view',
|
||||
lock: [ _set.previewReviewMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [ _set.previewReviewMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: this.capBtnView,
|
||||
enableToggle: true,
|
||||
dataHint: '1',
|
||||
|
@ -280,7 +280,7 @@ define([
|
|||
this.btnClearFields = new Common.UI.Button({
|
||||
cls : 'btn-toolbar',
|
||||
iconCls : 'toolbar__icon btn-clearstyle',
|
||||
lock: [ _set.previewReviewMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [ _set.previewReviewMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption : this.textClearFields,
|
||||
dataHint : '1',
|
||||
dataHintDirection: 'left',
|
||||
|
@ -291,7 +291,7 @@ define([
|
|||
this.btnHighlight = new Common.UI.ButtonColored({
|
||||
cls : 'btn-toolbar',
|
||||
iconCls : 'toolbar__icon btn-highlight',
|
||||
lock: [ _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [ _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption : this.textHighlight,
|
||||
menu : true,
|
||||
additionalItems: [ this.mnuNoFormsColor = new Common.UI.MenuItem({
|
||||
|
@ -316,7 +316,7 @@ define([
|
|||
this.btnPrevForm = new Common.UI.Button({
|
||||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon previous-field',
|
||||
lock: [ _set.previewReviewMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [ _set.previewReviewMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: this.capBtnPrev,
|
||||
// disabled: this.appConfig.isEdit && this.appConfig.canFeatureContentControl && this.appConfig.canFeatureForms, // disable only for edit mode
|
||||
dataHint: '1',
|
||||
|
@ -328,7 +328,7 @@ define([
|
|||
this.btnNextForm = new Common.UI.Button({
|
||||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon next-field',
|
||||
lock: [ _set.previewReviewMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [ _set.previewReviewMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: this.capBtnNext,
|
||||
// disabled: this.appConfig.isEdit && this.appConfig.canFeatureContentControl && this.appConfig.canFeatureForms, // disable only for edit mode,
|
||||
dataHint: '1',
|
||||
|
|
|
@ -169,13 +169,13 @@ define([
|
|||
$host = me.toolbar.$el;
|
||||
|
||||
this.btnsContents = Common.Utils.injectButtons($host.find('.btn-slot.btn-contents'), '', 'toolbar__icon btn-contents', me.capBtnInsContents,
|
||||
[_set.inHeader, _set.richEditLock, _set.plainEditLock, _set.richDelLock, _set.plainDelLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
[_set.inHeader, _set.richEditLock, _set.plainEditLock, _set.richDelLock, _set.plainDelLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
true, true, undefined, '1', 'bottom', 'small');
|
||||
this.btnsNotes = Common.Utils.injectButtons($host.find('.btn-slot.slot-notes'), '', 'toolbar__icon btn-notes', me.capBtnInsFootnote,
|
||||
[_set.paragraphLock, _set.inEquation, _set.inImage, _set.inHeader, _set.controlPlain, _set.richEditLock, _set.plainEditLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
[_set.paragraphLock, _set.inEquation, _set.inImage, _set.inHeader, _set.controlPlain, _set.richEditLock, _set.plainEditLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
true, true, undefined, '1', 'bottom', 'small');
|
||||
this.btnsHyperlink = Common.Utils.injectButtons($host.find('.btn-slot.slot-inshyperlink'), '', 'toolbar__icon btn-inserthyperlink', me.capBtnInsLink,
|
||||
[_set.paragraphLock, _set.headerLock, _set.hyperlinkLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
[_set.paragraphLock, _set.headerLock, _set.hyperlinkLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
undefined, undefined, undefined, '1', 'bottom', 'small');
|
||||
Array.prototype.push.apply(this.paragraphControls, this.btnsContents.concat(this.btnsNotes, this.btnsHyperlink));
|
||||
|
||||
|
@ -183,7 +183,7 @@ define([
|
|||
parentEl: $host.find('#slot-btn-contents-update'),
|
||||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon btn-update',
|
||||
lock: [ _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [ _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: this.capBtnContentsUpdate,
|
||||
split: true,
|
||||
menu: true,
|
||||
|
@ -197,7 +197,7 @@ define([
|
|||
parentEl: $host.find('#slot-btn-add-text'),
|
||||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon add-text',
|
||||
lock: [ _set.cantAddTextTOF, _set.inHeader, _set.inFootnote, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [ _set.cantAddTextTOF, _set.inHeader, _set.inFootnote, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: this.capBtnAddText,
|
||||
menu: new Common.UI.Menu({
|
||||
items: []
|
||||
|
@ -212,7 +212,7 @@ define([
|
|||
parentEl: $host.find('#slot-btn-bookmarks'),
|
||||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-bookmarks',
|
||||
lock: [_set.paragraphLock, _set.inHeader, _set.headerLock, _set.controlPlain, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.paragraphLock, _set.inHeader, _set.headerLock, _set.controlPlain, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: this.capBtnBookmarks,
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'bottom',
|
||||
|
@ -224,7 +224,7 @@ define([
|
|||
parentEl: $host.find('#slot-btn-caption'),
|
||||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-caption',
|
||||
lock: [_set.inHeader, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.inHeader, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: this.capBtnCaption,
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'bottom',
|
||||
|
@ -236,7 +236,7 @@ define([
|
|||
parentEl: $host.find('#slot-btn-crossref'),
|
||||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-cross-reference',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.controlPlain, _set.richEditLock, _set.plainEditLock, _set.contentLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.controlPlain, _set.richEditLock, _set.plainEditLock, _set.contentLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: this.capBtnCrossRef,
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'bottom',
|
||||
|
@ -248,7 +248,7 @@ define([
|
|||
parentEl: $host.find('#slot-btn-tof'),
|
||||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon btn-contents',
|
||||
lock: [_set.inHeader, _set.richEditLock, _set.plainEditLock, _set.richDelLock, _set.plainDelLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.inHeader, _set.richEditLock, _set.plainEditLock, _set.richDelLock, _set.plainDelLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: this.capBtnTOF,
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'left',
|
||||
|
@ -260,7 +260,7 @@ define([
|
|||
parentEl: $host.find('#slot-btn-tof-update'),
|
||||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon btn-update',
|
||||
lock: [_set.paragraphLock, _set.inHeader, _set.richEditLock, _set.plainEditLock, _set.richDelLock, _set.plainDelLock, _set.cantUpdateTOF, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.paragraphLock, _set.inHeader, _set.richEditLock, _set.plainEditLock, _set.richDelLock, _set.plainDelLock, _set.cantUpdateTOF, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: this.capBtnContentsUpdate,
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'left',
|
||||
|
|
|
@ -43,12 +43,6 @@ define([
|
|||
], function () {
|
||||
'use strict';
|
||||
|
||||
Asc.c_oAscProtection = {
|
||||
View: 1,
|
||||
Forms: 2,
|
||||
Review: 3,
|
||||
Comments: 4
|
||||
};
|
||||
DE.Views.ProtectDialog = Common.UI.Window.extend(_.extend({
|
||||
|
||||
initialize : function (options) {
|
||||
|
|
|
@ -176,7 +176,8 @@ define([
|
|||
_.extend(this, options);
|
||||
this.pages = new DE.Models.Pages({current:1, count:1});
|
||||
this.pages.on('change', _.bind(_updatePagesCaption,this));
|
||||
this.state = {};
|
||||
this._state = {};
|
||||
this._isDisabled = false;
|
||||
|
||||
var me = this;
|
||||
this.$layout = $(this.template({
|
||||
|
@ -399,8 +400,18 @@ define([
|
|||
},
|
||||
|
||||
SetDisabled: function(disable) {
|
||||
this.btnLanguage.setDisabled(disable || this.langMenu.items.length<1);
|
||||
this.btnTurnReview && this.btnTurnReview.setDisabled(disable);
|
||||
this._isDisabled = disable;
|
||||
var lockMode = this._state.docProtection ? this._state.docProtection.lockMode : undefined;
|
||||
lockMode = (lockMode===Asc.c_oAscProtection.View || lockMode===Asc.c_oAscProtection.Forms || lockMode===Asc.c_oAscProtection.Comments);
|
||||
this.btnLanguage.setDisabled(disable || this.langMenu.items.length<1 || lockMode);
|
||||
this.btnTurnReview && this.btnTurnReview.setDisabled(disable || lockMode);
|
||||
},
|
||||
|
||||
onChangeProtectDocument: function(props) {
|
||||
if (props) {
|
||||
this._state.docProtection = props;
|
||||
this.SetDisabled(this._isDisabled);
|
||||
}
|
||||
},
|
||||
|
||||
onApiCoAuthoringDisconnect: function() {
|
||||
|
|
|
@ -201,7 +201,7 @@ define([
|
|||
id: 'id-toolbar-btn-save',
|
||||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon no-mask ' + this.btnSaveCls,
|
||||
lock: [_set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
signals: ['disabled'],
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'top',
|
||||
|
@ -214,7 +214,7 @@ define([
|
|||
id: 'id-toolbar-btn-undo',
|
||||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon btn-undo',
|
||||
lock: [_set.undoLock, _set.previewReviewMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.undoLock, _set.previewReviewMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
signals: ['disabled'],
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'bottom',
|
||||
|
@ -226,7 +226,7 @@ define([
|
|||
id: 'id-toolbar-btn-redo',
|
||||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon btn-redo',
|
||||
lock: [_set.redoLock, _set.previewReviewMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.redoLock, _set.previewReviewMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
signals: ['disabled'],
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'bottom',
|
||||
|
@ -238,7 +238,7 @@ define([
|
|||
id: 'id-toolbar-btn-copy',
|
||||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon btn-copy',
|
||||
lock: [_set.copyLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.copyLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'top',
|
||||
dataHintTitle: 'C'
|
||||
|
@ -249,7 +249,7 @@ define([
|
|||
id: 'id-toolbar-btn-paste',
|
||||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon btn-paste',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'top',
|
||||
dataHintTitle: 'V'
|
||||
|
@ -260,7 +260,7 @@ define([
|
|||
id: 'id-toolbar-btn-cut',
|
||||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon btn-cut',
|
||||
lock: [_set.copyLock, _set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.imageLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.copyLock, _set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.imageLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'top',
|
||||
dataHintTitle: 'X'
|
||||
|
@ -281,7 +281,7 @@ define([
|
|||
id: 'id-toolbar-btn-incfont',
|
||||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon btn-incfont',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'top'
|
||||
});
|
||||
|
@ -291,7 +291,7 @@ define([
|
|||
id: 'id-toolbar-btn-decfont',
|
||||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon btn-decfont',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'top'
|
||||
});
|
||||
|
@ -301,7 +301,7 @@ define([
|
|||
id: 'id-toolbar-btn-bold',
|
||||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon btn-bold',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
enableToggle: true,
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'bottom'
|
||||
|
@ -312,7 +312,7 @@ define([
|
|||
id: 'id-toolbar-btn-italic',
|
||||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon btn-italic',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
enableToggle: true,
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'bottom'
|
||||
|
@ -323,7 +323,7 @@ define([
|
|||
id: 'id-toolbar-btn-underline',
|
||||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon btn-underline',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
enableToggle: true,
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'bottom'
|
||||
|
@ -334,7 +334,7 @@ define([
|
|||
id: 'id-toolbar-btn-strikeout',
|
||||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon btn-strikeout',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
enableToggle: true,
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'bottom'
|
||||
|
@ -345,7 +345,7 @@ define([
|
|||
id: 'id-toolbar-btn-superscript',
|
||||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon btn-superscript',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.inEquation, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.inEquation, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
enableToggle: true,
|
||||
toggleGroup: 'superscriptGroup',
|
||||
dataHint: '1',
|
||||
|
@ -357,7 +357,7 @@ define([
|
|||
id: 'id-toolbar-btn-subscript',
|
||||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon btn-subscript',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.inEquation, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.inEquation, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
enableToggle: true,
|
||||
toggleGroup: 'superscriptGroup',
|
||||
dataHint: '1',
|
||||
|
@ -370,7 +370,7 @@ define([
|
|||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon btn-highlight',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.inChart, _set.inSmartart, _set.inSmartartInternal, _set.previewReviewMode, _set.viewFormMode,
|
||||
_set.lostConnect, _set.disableOnStart],
|
||||
_set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
enableToggle: true,
|
||||
allowDepress: true,
|
||||
split: true,
|
||||
|
@ -395,7 +395,7 @@ define([
|
|||
id: 'id-toolbar-btn-fontcolor',
|
||||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon btn-fontcolor',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
split: true,
|
||||
menu: true,
|
||||
auto: true,
|
||||
|
@ -410,7 +410,7 @@ define([
|
|||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon btn-paracolor',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.inChart, _set.inSmartart, _set.inSmartartInternal, _set.previewReviewMode, _set.viewFormMode,
|
||||
_set.lostConnect, _set.disableOnStart],
|
||||
_set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
split: true,
|
||||
transparent: true,
|
||||
menu: true,
|
||||
|
@ -425,7 +425,7 @@ define([
|
|||
id: 'id-toolbar-btn-case',
|
||||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon btn-change-case',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
menu: new Common.UI.Menu({
|
||||
items: [
|
||||
{caption: this.mniSentenceCase, value: Asc.c_oAscChangeTextCaseType.SentenceCase},
|
||||
|
@ -444,7 +444,7 @@ define([
|
|||
id: 'id-toolbar-btn-align-left',
|
||||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon btn-align-left',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
enableToggle: true,
|
||||
toggleGroup: 'alignGroup',
|
||||
dataHint: '1',
|
||||
|
@ -456,7 +456,7 @@ define([
|
|||
id: 'id-toolbar-btn-align-center',
|
||||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon btn-align-center',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
enableToggle: true,
|
||||
toggleGroup: 'alignGroup',
|
||||
dataHint: '1',
|
||||
|
@ -468,7 +468,7 @@ define([
|
|||
id: 'id-toolbar-btn-align-right',
|
||||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon btn-align-right',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
enableToggle: true,
|
||||
toggleGroup: 'alignGroup',
|
||||
dataHint: '1',
|
||||
|
@ -480,7 +480,7 @@ define([
|
|||
id: 'id-toolbar-btn-align-just',
|
||||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon btn-align-just',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
enableToggle: true,
|
||||
toggleGroup: 'alignGroup',
|
||||
dataHint: '1',
|
||||
|
@ -492,7 +492,7 @@ define([
|
|||
id: 'id-toolbar-btn-decoffset',
|
||||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon btn-decoffset',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.inSmartartInternal, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.inSmartartInternal, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'top'
|
||||
});
|
||||
|
@ -502,7 +502,7 @@ define([
|
|||
id: 'id-toolbar-btn-incoffset',
|
||||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon btn-incoffset',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.inSmartartInternal, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.inSmartartInternal, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'top'
|
||||
});
|
||||
|
@ -512,7 +512,7 @@ define([
|
|||
id: 'id-toolbar-btn-linespace',
|
||||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon btn-linespace',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
menu: new Common.UI.Menu({
|
||||
style: 'min-width: 60px;',
|
||||
items: [
|
||||
|
@ -534,7 +534,7 @@ define([
|
|||
id: 'id-toolbar-btn-hidenchars',
|
||||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon btn-paragraph',
|
||||
lock: [ _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [ _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
enableToggle: true,
|
||||
split: true,
|
||||
menu: new Common.UI.Menu({
|
||||
|
@ -555,7 +555,7 @@ define([
|
|||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon btn-setmarkers',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.inChart, _set.inSmartart, _set.inSmartartInternal, _set.previewReviewMode, _set.viewFormMode,
|
||||
_set.lostConnect, _set.disableOnStart],
|
||||
_set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
enableToggle: true,
|
||||
toggleGroup: 'markersGroup',
|
||||
split: true,
|
||||
|
@ -572,7 +572,7 @@ define([
|
|||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon btn-numbering',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.inChart, _set.inSmartart, _set.inSmartartInternal, _set.previewReviewMode, _set.viewFormMode,
|
||||
_set.lostConnect, _set.disableOnStart],
|
||||
_set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
enableToggle: true,
|
||||
toggleGroup: 'markersGroup',
|
||||
split: true,
|
||||
|
@ -589,7 +589,7 @@ define([
|
|||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon btn-multilevels',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.inChart, _set.inSmartart, _set.inSmartartInternal, _set.previewReviewMode, _set.viewFormMode,
|
||||
_set.lostConnect, _set.disableOnStart],
|
||||
_set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
menu: true,
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'top',
|
||||
|
@ -622,7 +622,7 @@ define([
|
|||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-inserttable',
|
||||
lock: [_set.headerLock, _set.richEditLock, _set.plainEditLock, _set.inEquation, _set.controlPlain, _set.richDelLock, _set.plainDelLock, _set.cantAddTable, _set.previewReviewMode,
|
||||
_set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
_set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: me.capBtnInsTable,
|
||||
menu: new Common.UI.Menu({
|
||||
items: [
|
||||
|
@ -645,7 +645,7 @@ define([
|
|||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-insertimage',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.inEquation, _set.controlPlain, _set.richDelLock, _set.plainDelLock, _set.contentLock, _set.cantAddImagePara,
|
||||
_set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
_set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: me.capBtnInsImage,
|
||||
menu: new Common.UI.Menu({
|
||||
items: [
|
||||
|
@ -666,7 +666,7 @@ define([
|
|||
caption: me.capBtnInsChart,
|
||||
iconCls: 'toolbar__icon btn-insertchart',
|
||||
lock: [ _set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.controlPlain, _set.richDelLock, _set.plainDelLock, _set.contentLock,
|
||||
_set.chartLock, _set.cantAddChart, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
_set.chartLock, _set.cantAddChart, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
menu: true,
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'bottom',
|
||||
|
@ -679,7 +679,7 @@ define([
|
|||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-text',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.inEquation, _set.controlPlain, _set.contentLock, _set.inFootnote, _set.previewReviewMode, _set.viewFormMode,
|
||||
_set.lostConnect, _set.disableOnStart],
|
||||
_set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: me.capBtnInsTextbox,
|
||||
enableToggle: true,
|
||||
dataHint: '1',
|
||||
|
@ -693,7 +693,7 @@ define([
|
|||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-textart',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.inEquation, _set.controlPlain, _set.richDelLock, _set.plainDelLock, _set.contentLock, _set.inFootnote, _set.cantAddImagePara,
|
||||
_set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
_set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: me.capBtnInsTextart,
|
||||
menu: new Common.UI.Menu({
|
||||
cls: 'menu-shapes',
|
||||
|
@ -711,7 +711,7 @@ define([
|
|||
id: 'id-toolbar-btn-editheader',
|
||||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-editheader',
|
||||
lock: [ _set.previewReviewMode, _set.viewFormMode, _set.inEquation, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [ _set.previewReviewMode, _set.viewFormMode, _set.inEquation, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: me.capBtnInsHeader,
|
||||
menu: true,
|
||||
dataHint: '1',
|
||||
|
@ -745,7 +745,7 @@ define([
|
|||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-datetime',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.richDelLock, _set.plainDelLock, _set.noParagraphSelected, _set.previewReviewMode,
|
||||
_set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
_set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: me.capBtnDateTime,
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'bottom',
|
||||
|
@ -758,7 +758,7 @@ define([
|
|||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-blankpage',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.inEquation, _set.richDelLock, _set.plainDelLock, _set.inHeader, _set.inFootnote, _set.inControl,
|
||||
_set.cantPageBreak, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
_set.cantPageBreak, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: me.capBtnBlankPage,
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'bottom',
|
||||
|
@ -771,7 +771,7 @@ define([
|
|||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-insertshape',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.inEquation, _set.controlPlain, _set.contentLock, _set.inFootnote, _set.previewReviewMode, _set.viewFormMode,
|
||||
_set.lostConnect, _set.disableOnStart],
|
||||
_set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: me.capBtnInsShape,
|
||||
enableToggle: true,
|
||||
menu: new Common.UI.Menu({cls: 'menu-shapes menu-insert-shape'}),
|
||||
|
@ -786,7 +786,7 @@ define([
|
|||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-insertequation',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.inChart, _set.controlPlain, _set.richDelLock, _set.plainDelLock, _set.cantAddEquation,
|
||||
_set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
_set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: me.capBtnInsEquation,
|
||||
split: true,
|
||||
menu: new Common.UI.Menu({cls: 'menu-shapes'}),
|
||||
|
@ -801,7 +801,7 @@ define([
|
|||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-symbol',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.richDelLock, _set.plainDelLock, _set.noParagraphSelected, _set.previewReviewMode,
|
||||
_set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
_set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: me.capBtnInsSymbol,
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'bottom',
|
||||
|
@ -814,7 +814,7 @@ define([
|
|||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-dropcap',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.inEquation, _set.controlPlain, _set.dropcapLock, _set.previewReviewMode, _set.viewFormMode,
|
||||
_set.lostConnect, _set.disableOnStart],
|
||||
_set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: me.capBtnInsDropcap,
|
||||
menu: new Common.UI.Menu({
|
||||
cls: 'ppm-toolbar shifted-right',
|
||||
|
@ -858,7 +858,7 @@ define([
|
|||
id: 'tlbtn-controls',
|
||||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-controls',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: me.capBtnInsControls,
|
||||
menu: new Common.UI.Menu({
|
||||
cls: 'ppm-toolbar shifted-right',
|
||||
|
@ -944,7 +944,7 @@ define([
|
|||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-columns',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.controlPlain, _set.inImage, _set.docPropsLock, _set.previewReviewMode, _set.viewFormMode,
|
||||
_set.lostConnect, _set.disableOnStart],
|
||||
_set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: me.capBtnColumns,
|
||||
menu: new Common.UI.Menu({
|
||||
cls: 'ppm-toolbar shifted-right',
|
||||
|
@ -1003,7 +1003,7 @@ define([
|
|||
id: 'tlbtn-pageorient',
|
||||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-pageorient',
|
||||
lock: [_set.docPropsLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.docPropsLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: me.capBtnPageOrient,
|
||||
menu: new Common.UI.Menu({
|
||||
cls: 'ppm-toolbar',
|
||||
|
@ -1045,7 +1045,7 @@ define([
|
|||
id: 'tlbtn-pagemargins',
|
||||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-pagemargins',
|
||||
lock: [_set.docPropsLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.docPropsLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: me.capBtnMargins,
|
||||
menu: new Common.UI.Menu({
|
||||
items: [
|
||||
|
@ -1108,7 +1108,7 @@ define([
|
|||
id: 'tlbtn-pagesize',
|
||||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-pagesize',
|
||||
lock: [_set.docPropsLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.docPropsLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: me.capBtnPageSize,
|
||||
menu: new Common.UI.Menu({
|
||||
restoreHeight: true,
|
||||
|
@ -1232,7 +1232,7 @@ define([
|
|||
id: 'tlbtn-line-numbers',
|
||||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-line-numbering',
|
||||
lock: [_set.docPropsLock, _set.inImagePara, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.docPropsLock, _set.inImagePara, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: me.capBtnLineNumbers,
|
||||
menu: new Common.UI.Menu({
|
||||
cls: 'ppm-toolbar',
|
||||
|
@ -1285,7 +1285,7 @@ define([
|
|||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon btn-clearstyle',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.inChart, _set.inSmartart, _set.inSmartartInternal, _set.previewReviewMode, _set.viewFormMode,
|
||||
_set.lostConnect, _set.disableOnStart],
|
||||
_set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'top'
|
||||
});
|
||||
|
@ -1295,7 +1295,7 @@ define([
|
|||
id: 'id-toolbar-btn-copystyle',
|
||||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon btn-copystyle',
|
||||
lock: [ _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [ _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
enableToggle: true,
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'bottom'
|
||||
|
@ -1306,7 +1306,7 @@ define([
|
|||
id: 'id-toolbar-btn-colorschemas',
|
||||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon btn-colorschemas',
|
||||
lock: [_set.docSchemaLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.docSchemaLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
menu: new Common.UI.Menu({
|
||||
cls: 'shifted-left',
|
||||
items: [],
|
||||
|
@ -1322,7 +1322,7 @@ define([
|
|||
id: 'id-toolbar-btn-mailrecepients',
|
||||
cls: 'btn-toolbar',
|
||||
iconCls: 'toolbar__icon btn-mailmerge',
|
||||
lock: [_set.mmergeLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.mmergeLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
dataHint: '1',
|
||||
dataHintDirection: 'bottom',
|
||||
menu: new Common.UI.Menu({
|
||||
|
@ -1338,7 +1338,7 @@ define([
|
|||
me.btnImgAlign = new Common.UI.Button({
|
||||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-img-align',
|
||||
lock: [_set.imageLock, _set.contentLock, _set.inImageInline, _set.noObjectSelected, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.imageLock, _set.contentLock, _set.inImageInline, _set.noObjectSelected, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: me.capImgAlign,
|
||||
menu: true,
|
||||
dataHint: '1',
|
||||
|
@ -1349,7 +1349,7 @@ define([
|
|||
me.btnImgGroup = new Common.UI.Button({
|
||||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-img-group',
|
||||
lock: [_set.imageLock, _set.contentLock, _set.inImageInline, _set.noObjectSelected, _set.cantGroup, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.imageLock, _set.contentLock, _set.inImageInline, _set.noObjectSelected, _set.cantGroup, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: me.capImgGroup,
|
||||
menu: true,
|
||||
dataHint: '1',
|
||||
|
@ -1359,7 +1359,7 @@ define([
|
|||
me.btnImgForward = new Common.UI.Button({
|
||||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-img-frwd',
|
||||
lock: [_set.cantArrange, _set.lostConnect, _set.contentLock, _set.noObjectSelected, _set.inSmartartInternal, _set.previewReviewMode, _set.viewFormMode, _set.disableOnStart],
|
||||
lock: [_set.cantArrange, _set.lostConnect, _set.contentLock, _set.noObjectSelected, _set.inSmartartInternal, _set.previewReviewMode, _set.viewFormMode, _set.disableOnStart, _set.docLockView],
|
||||
caption: me.capImgForward,
|
||||
split: true,
|
||||
menu: true,
|
||||
|
@ -1370,7 +1370,7 @@ define([
|
|||
me.btnImgBackward = new Common.UI.Button({
|
||||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-img-bkwd',
|
||||
lock: [_set.cantArrange, _set.lostConnect, _set.contentLock, _set.noObjectSelected, _set.inSmartartInternal, _set.previewReviewMode, _set.viewFormMode, _set.disableOnStart],
|
||||
lock: [_set.cantArrange, _set.lostConnect, _set.contentLock, _set.noObjectSelected, _set.inSmartartInternal, _set.previewReviewMode, _set.viewFormMode, _set.disableOnStart, _set.docLockView],
|
||||
caption: me.capImgBackward,
|
||||
split: true,
|
||||
menu: true,
|
||||
|
@ -1381,7 +1381,7 @@ define([
|
|||
me.btnImgWrapping = new Common.UI.Button({
|
||||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-img-wrap',
|
||||
lock: [_set.cantWrap, _set.imageLock, _set.contentLock, _set.noObjectSelected, _set.lostConnect, _set.previewReviewMode, _set.viewFormMode, _set.disableOnStart],
|
||||
lock: [_set.cantWrap, _set.imageLock, _set.contentLock, _set.noObjectSelected, _set.lostConnect, _set.previewReviewMode, _set.viewFormMode, _set.disableOnStart, _set.docLockView],
|
||||
caption: me.capImgWrapping,
|
||||
menu: true,
|
||||
dataHint: '1',
|
||||
|
@ -1392,7 +1392,7 @@ define([
|
|||
me.btnWatermark = new Common.UI.Button({
|
||||
cls: 'btn-toolbar x-huge icon-top',
|
||||
iconCls: 'toolbar__icon btn-watermark',
|
||||
lock: [_set.headerLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.headerLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
caption: me.capBtnWatermark,
|
||||
menu: new Common.UI.Menu({
|
||||
cls: 'ppm-toolbar',
|
||||
|
@ -1431,7 +1431,7 @@ define([
|
|||
this.cmbFontSize = new Common.UI.ComboBox({
|
||||
cls: 'input-group-nr',
|
||||
menuStyle: 'min-width: 55px;',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
hint: this.tipFontSize,
|
||||
data: [
|
||||
{value: 8, displayValue: "8"},
|
||||
|
@ -1461,7 +1461,7 @@ define([
|
|||
cls: 'input-group-nr',
|
||||
menuCls: 'scrollable-menu',
|
||||
menuStyle: 'min-width: 325px;',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.previewReviewMode, _set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
hint: this.tipFontName,
|
||||
store: new Common.Collections.Fonts(),
|
||||
dataHint: '1',
|
||||
|
@ -1480,7 +1480,7 @@ define([
|
|||
this.listStyles = new Common.UI.ComboDataView({
|
||||
cls: 'combo-styles',
|
||||
lock: [_set.paragraphLock, _set.headerLock, _set.richEditLock, _set.plainEditLock, _set.inChart, _set.inSmartart, _set.inSmartartInternal, _set.previewReviewMode,
|
||||
_set.viewFormMode, _set.lostConnect, _set.disableOnStart],
|
||||
_set.viewFormMode, _set.lostConnect, _set.disableOnStart, _set.docLockView],
|
||||
itemWidth: itemWidth,
|
||||
itemHeight: itemHeight,
|
||||
style: 'min-width:150px;',
|
||||
|
@ -1738,7 +1738,7 @@ define([
|
|||
this.btnsPageBreak = Common.Utils.injectButtons($host.find('.btn-slot.btn-pagebreak'), '', 'toolbar__icon btn-pagebreak', this.capBtnInsPagebreak,
|
||||
[Common.enumLock.paragraphLock, Common.enumLock.headerLock, Common.enumLock.richEditLock, Common.enumLock.plainEditLock, Common.enumLock.inEquation, Common.enumLock.richDelLock,
|
||||
Common.enumLock.plainDelLock, Common.enumLock.inHeader, Common.enumLock.inFootnote, Common.enumLock.inControl, Common.enumLock.cantPageBreak, Common.enumLock.previewReviewMode,
|
||||
Common.enumLock.viewFormMode, Common.enumLock.lostConnect, Common.enumLock.disableOnStart],
|
||||
Common.enumLock.viewFormMode, Common.enumLock.lostConnect, Common.enumLock.disableOnStart, Common.enumLock.docLockView],
|
||||
true, true, undefined, '1', 'bottom', 'small');
|
||||
Array.prototype.push.apply(this.paragraphControls, this.btnsPageBreak);
|
||||
Array.prototype.push.apply(this.lockControls, this.btnsPageBreak);
|
||||
|
|
Loading…
Reference in a new issue