Remove Workspace:openSingletonSync

This commit is contained in:
probablycorey
2014-02-12 14:11:41 -08:00
parent 4e2218b005
commit e550d8a3bc
2 changed files with 1 additions and 24 deletions

View File

@@ -51,7 +51,7 @@ class WorkspaceView extends View
Delegator.includeInto(this)
@delegatesProperty 'fullScreen', 'destroyedItemUris', toProperty: 'model'
@delegatesMethods 'open', 'openSync', 'openSingletonSync', 'reopenItemSync',
@delegatesMethods 'open', 'openSync', 'reopenItemSync',
'saveActivePaneItem', 'saveActivePaneItemAs', 'saveAll', 'destroyActivePaneItem',
'destroyActivePane', 'increaseFontSize', 'decreaseFontSize', toProperty: 'model'

View File

@@ -111,29 +111,6 @@ class Workspace extends Model
@activePane.activate() if activatePane
editor
# Deprecated
openSingletonSync: (uri, options={}) ->
{initialLine, split} = options
# TODO: Remove deprecated changeFocus option
activatePane = options.activatePane ? options.changeFocus ? true
uri = atom.project.relativize(uri)
if pane = @paneContainer.paneForUri(uri)
editor = pane.itemForUri(uri)
else
pane = switch split
when 'left'
@activePane.findLeftmostSibling()
when 'right'
@activePane.findOrCreateRightmostSibling()
else
@activePane
editor = atom.project.openSync(uri, {initialLine})
pane.activateItem(editor)
pane.activate() if activatePane
editor
# Public: Reopens the last-closed item uri if it hasn't already been reopened.
reopenItemSync: ->
if uri = @destroyedItemUris.pop()