Move saveAll and specs to PaneContainer

And simplify the specs… we don't *really* need to save. We can just
ensure that save is called on everything.
This commit is contained in:
Nathan Sobo
2013-03-01 16:44:27 -07:00
committed by probablycorey
parent e4bf73b41c
commit 7ebce683c6
4 changed files with 16 additions and 31 deletions

View File

@@ -36,6 +36,9 @@ class PaneContainer extends View
getRoot: ->
@children().first().view()
saveAll: ->
pane.saveItems() for pane in @getPanes()
getPanes: ->
@find('.pane').views()

View File

@@ -148,7 +148,7 @@ class RootView extends View
super
saveAll: ->
pane.saveItems() for pane in @getPanes()
@panes.saveAll()
eachPane: (callback) ->
@panes.eachPane(callback)