Document methods

This commit is contained in:
Nathan Sobo 2013-12-11 11:02:56 -08:00
parent e275b6c414
commit e5bf70544e

View File

@ -322,14 +322,17 @@ class WorkspaceView extends View
atom.project?.destroy()
super
# Private: Adds the destroyed item's uri to the list of items to reopen.
onPaneItemDestroyed: (e, item) =>
if uri = item.getUri?()
@destroyedItemUris.push(uri)
# Public: Reopens the last-closed item uri if it hasn't already been reopened.
reopenItemSync: ->
if uri = @destroyedItemUris.pop()
@openSync(uri)
# Private: Removes the item's uri from the list of potential items to reopen.
itemOpened: (item) ->
if uri = item.getUri?()
_.remove(@destroyedItemUris, uri)