selected item might be gone

This commit is contained in:
j 2016-03-16 08:28:12 +01:00
parent cb875c86df
commit da08120ff4

View file

@ -332,9 +332,10 @@ Ox.AnnotationPanel = function(options, self) {
} }
}, },
hide: function() { hide: function() {
self.options.selected var folder = self.options.selected
? getFolder(self.options.selected).gainFocus() ? getFolder(self.options.selected)
: that.triggerEvent('focus'); : null;
folder ? folder.gainFocus() : that.triggerEvent('focus');
} }
}) })
.appendTo(self.$menubar); .appendTo(self.$menubar);