refactoring
This commit is contained in:
parent
dbf06b62fe
commit
456f4dcc2d
|
@ -140,9 +140,10 @@ define([
|
|||
el.html(this.template(this.model.toJSON()));
|
||||
el.addClass('item');
|
||||
el.toggleClass('selected', this.model.get('selected') && this.model.get('allowSelected'));
|
||||
el.off('click').on('click', _.bind(this.onClick, this));
|
||||
el.off('dblclick').on('dblclick', _.bind(this.onDblClick, this));
|
||||
el.off('contextmenu').on('contextmenu', _.bind(this.onContextMenu, this));
|
||||
el.off('click dblclick contextmenu');
|
||||
el.on({ 'click': _.bind(this.onClick, this),
|
||||
'dblclick': _.bind(this.onDblClick, this),
|
||||
'contextmenu': _.bind(this.onContextMenu, this) });
|
||||
el.toggleClass('disabled', !!this.model.get('disabled'));
|
||||
|
||||
if (!_.isUndefined(this.model.get('cls')))
|
||||
|
|
|
@ -909,15 +909,12 @@ define([
|
|||
applyModeCommonElements: function() {
|
||||
window.editor_elements_prepared = true;
|
||||
|
||||
var value = Common.localStorage.getItem("sse-hidden-title");
|
||||
value = this.appOptions.isEdit && (value!==null && parseInt(value) == 1);
|
||||
|
||||
var app = this.getApplication(),
|
||||
viewport = app.getController('Viewport').getView('Viewport'),
|
||||
statusbarView = app.getController('Statusbar').getView('Statusbar');
|
||||
|
||||
if (this.headerView) {
|
||||
this.headerView.setVisible(!this.appOptions.nativeApp && !value && !this.appOptions.isEditMailMerge &&
|
||||
this.headerView.setVisible(!this.appOptions.nativeApp && !this.appOptions.isEditMailMerge &&
|
||||
!this.appOptions.isDesktopApp && !this.appOptions.isEditDiagram);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue