Disallow activation of destroyed panes

Signed-off-by: Max Brunsfeld <maxbrunsfeld@gmail.com>
This commit is contained in:
Nathan Sobo
2014-11-07 15:45:21 -07:00
committed by Max Brunsfeld
parent 6934b83acc
commit 33fde29acb

View File

@@ -502,6 +502,8 @@ class Pane extends Model
# Public: Makes this pane the *active* pane, causing it to gain focus.
activate: ->
throw new Error("Pane has been destroyed") if @isDestroyed()
@container?.setActivePane(this)
@emit 'activated'
@emitter.emit 'did-activate'