[DE PE] Fix view tab
This commit is contained in:
parent
be3619a340
commit
0e75d15d57
|
@ -116,17 +116,17 @@ define([
|
||||||
|
|
||||||
onAppReady: function (config) {
|
onAppReady: function (config) {
|
||||||
var me = this;
|
var me = this;
|
||||||
|
if (me.view) {
|
||||||
(new Promise(function (accept, reject) {
|
(new Promise(function (accept, reject) {
|
||||||
accept();
|
accept();
|
||||||
})).then(function(){
|
})).then(function(){
|
||||||
me.view.setEvents();
|
me.view.setEvents();
|
||||||
});
|
});
|
||||||
if (me.view.btnNavigation) {
|
|
||||||
me.getApplication().getController('LeftMenu').leftMenu.btnNavigation.on('toggle', function (btn, state) {
|
me.getApplication().getController('LeftMenu').leftMenu.btnNavigation.on('toggle', function (btn, state) {
|
||||||
if (state !== me.view.btnNavigation.pressed)
|
if (state !== me.view.btnNavigation.pressed)
|
||||||
me.view.turnNavigation(state);
|
me.view.turnNavigation(state);
|
||||||
});
|
});
|
||||||
}
|
|
||||||
|
|
||||||
var menuItems = [],
|
var menuItems = [],
|
||||||
currentTheme = Common.UI.Themes.currentThemeId() || Common.UI.Themes.defaultThemeId();
|
currentTheme = Common.UI.Themes.currentThemeId() || Common.UI.Themes.defaultThemeId();
|
||||||
|
@ -148,6 +148,7 @@ define([
|
||||||
this.view.btnDarkDocument.setDisabled(value !== 'theme-dark');
|
this.view.btnDarkDocument.setDisabled(value !== 'theme-dark');
|
||||||
}, this));
|
}, this));
|
||||||
}
|
}
|
||||||
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
onZoomChange: function (percent, type) {
|
onZoomChange: function (percent, type) {
|
||||||
|
|
|
@ -135,11 +135,13 @@ define([
|
||||||
|
|
||||||
onAppReady: function (config) {
|
onAppReady: function (config) {
|
||||||
var me = this;
|
var me = this;
|
||||||
|
if (me.view) {
|
||||||
(new Promise(function (accept, reject) {
|
(new Promise(function (accept, reject) {
|
||||||
accept();
|
accept();
|
||||||
})).then(function () {
|
})).then(function () {
|
||||||
me.view.setEvents();
|
me.view.setEvents();
|
||||||
});
|
});
|
||||||
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
onChangeZoomValue: function (value) {
|
onChangeZoomValue: function (value) {
|
||||||
|
@ -172,7 +174,7 @@ define([
|
||||||
this.api.asc_ShowNotes(checked);
|
this.api.asc_ShowNotes(checked);
|
||||||
Common.localStorage.setBool('pe-hidden-notes', !checked);
|
Common.localStorage.setBool('pe-hidden-notes', !checked);
|
||||||
this.view.fireEvent('notes:hide', [!checked]);
|
this.view.fireEvent('notes:hide', [!checked]);
|
||||||
Common.NotificationCenter.trigger('edit:complete', me.view);
|
Common.NotificationCenter.trigger('edit:complete', this.view);
|
||||||
}
|
}
|
||||||
|
|
||||||
}, PE.Controllers.ViewTab || {}));
|
}, PE.Controllers.ViewTab || {}));
|
||||||
|
|
Loading…
Reference in a new issue