[DE] debug "FileMenu"

This commit is contained in:
Maxim Kadushkin 2017-04-20 13:29:44 +03:00
parent 6e867fb9f0
commit 0875b47bab
2 changed files with 8 additions and 8 deletions

View file

@ -353,7 +353,7 @@ define([
clickToolbarTab: function (tab, e) {
if (tab == 'file')
this.leftMenu.showMenu('file'); else
this.leftMenu.close();
this.leftMenu.menuFile.hide();
},
/** coauthoring begin **/
@ -577,6 +577,11 @@ define([
return false;
case 'escape':
// if (!this.leftMenu.isOpened()) return true;
if ( this.leftMenu.menuFile.isVisible() ) {
this.leftMenu.menuFile.hide();
return false;
}
var statusbar = DE.getController('Statusbar');
var menu_opened = statusbar.statusbar.$el.find('.open > [data-toggle="dropdown"]');
if (menu_opened.length) {
@ -590,8 +595,8 @@ define([
return false;
}
}
if (this.leftMenu.menuFile.isVisible() || this.leftMenu.btnAbout.pressed || this.leftMenu.btnPlugins.pressed ||
$(e.target).parents('#left-menu').length ) {
if (this.leftMenu.btnAbout.pressed || this.leftMenu.btnPlugins.pressed ||
$(e.target).parents('#left-menu').length ) {
this.leftMenu.close();
Common.NotificationCenter.trigger('layout:changed', 'leftmenu');
return false;

View file

@ -178,10 +178,6 @@ define([
this.supressEvents = true;
this.btnAbout.toggle(false);
if ( this.menuFile.isVisible() ) {
this.menuFile.hide();
}
if (btn.options.action == 'search') {
} else {
if (btn.pressed) {
@ -259,7 +255,6 @@ define([
if ( this.menuFile.isVisible() ) {
this.menuFile.hide();
} else {
this.btnAbout.toggle(false);
this.$el.width(SCALE_MIN);
/** coauthoring begin **/