mirror of
https://github.com/atom/atom.git
synced 2026-01-22 21:38:10 -05:00
Use Pane::onDidAddItem instead of ::observeItems
The former includes the index at which the item was added and the latter does not.
This commit is contained in:
@@ -34,7 +34,7 @@ class PaneView extends View
|
||||
setModel: (@model) ->
|
||||
@subscriptions = new CompositeDisposable
|
||||
@subscriptions.add @model.observeActiveItem(@onActiveItemChanged)
|
||||
@subscriptions.add @model.observeItems(@onItemAdded)
|
||||
@subscriptions.add @model.onDidAddItem(@onItemAdded)
|
||||
@subscriptions.add @model.onDidRemoveItem(@onItemRemoved)
|
||||
@subscriptions.add @model.onDidMoveItem(@onItemMoved)
|
||||
@subscriptions.add @model.onWillDestroyItem(@onBeforeItemDestroyed)
|
||||
|
||||
Reference in New Issue
Block a user