fix(workspace): Remember whether sidebar is hidden #190

This commit is contained in:
Ben Gotow 2015-10-26 10:51:30 -07:00
parent abca03b13d
commit 6d7743ae93

View file

@ -51,7 +51,7 @@ class WorkspaceStore extends NylasStore
@SidebarItem = WorkspaceSidebarItem @SidebarItem = WorkspaceSidebarItem
@SidebarItems = SidebarItems = {} @SidebarItems = SidebarItems = {}
@_hiddenLocations = {} @_hiddenLocations = atom.config.get('core.workspace.hiddenLocations') || {}
@_sheetStack = [] @_sheetStack = []
if atom.isMainWindow() if atom.isMainWindow()
@ -86,6 +86,9 @@ class WorkspaceStore extends NylasStore
delete @_hiddenLocations[location.id] delete @_hiddenLocations[location.id]
else else
@_hiddenLocations[location.id] = location @_hiddenLocations[location.id] = location
atom.config.set('core.workspace.hiddenLocations', @_hiddenLocations)
@trigger(@) @trigger(@)
_onSetFocus: ({collection, item}) => _onSetFocus: ({collection, item}) =>