Add RootView.modifiedBuffers()

This commit is contained in:
Corey Johnson
2012-06-12 10:49:34 -07:00
parent 321e7b6129
commit aa32655542

View File

@@ -123,6 +123,14 @@ class RootView extends View
editors: ->
@panes.find('.editor').map -> $(this).view()
modifiedBuffers: ->
modifiedBuffers = []
for editor in @editors()
for session in editor.editSessions
modifiedBuffers.push session.buffer if session.buffer.isModified()
modifiedBuffers
activeEditor: ->
if (editor = @panes.find('.editor.active')).length
editor.view()