Add Buffer.reload()

This commit is contained in:
Corey Johnson
2012-07-16 16:12:09 -07:00
parent 611eb93219
commit 5914b6cc2a
2 changed files with 16 additions and 0 deletions

View File

@@ -33,6 +33,11 @@ class Buffer
destroy: ->
@file?.off()
reload: ->
@setText(fs.read(@file.getPath()))
@modified = false
@modifiedOnDisk = false
getPath: ->
@file?.getPath()