reset selection after locking

This commit is contained in:
antelle 2016-07-16 13:01:19 +03:00
parent 4fa9167555
commit 0ee53071b7
No known key found for this signature in database
GPG Key ID: 26C38FADD3BDF3CA
2 changed files with 2 additions and 1 deletions

View File

@ -150,7 +150,7 @@ var AppModel = Backbone.Model.extend({
this.menu.filesSection.removeAllItems();
this.tags.splice(0, this.tags.length);
this.filter = {};
this.refresh();
this.menu.select({ item: this.menu.allItemsItem });
},
closeFile: function(file) {

View File

@ -19,6 +19,7 @@ var MenuModel = Backbone.Model.extend({
this.menus = {};
this.allItemsSection = new MenuSectionModel([{ title: Locale.menuAllItems, icon: 'th-large', active: true,
shortcut: Keys.DOM_VK_A, filterKey: '*' }]);
this.allItemsItem = this.allItemsSection.get('items').models[0];
this.groupsSection = new GroupsMenuModel();
this.colorsSection = new MenuSectionModel([{ title: Locale.menuColors, icon: 'bookmark', shortcut: Keys.DOM_VK_C,
cls: 'menu__item-colors', filterKey: 'color', filterValue: true }]);