       .map((activePane) => activePane is this)
       .distinctUntilChanged()
 
-  destroyingItem: false
-
   constructor: (params) ->
     super
 

    @emit 'before-item-destroyed', item
    if @promptToSaveItem(item)
      @emit 'item-destroyed', item
      @destroyingItem = true
      @removeItem(item)
      @destroyingItem = false
      item.destroy?()
      true
    else


    @subscribe @items.onRemoval (item, index) =>
      @unsubscribe item if typeof item.on is 'function'

    @when @$focused, => @makeActive()

