|
|
@ -45,7 +45,7 @@ function Files (storage) { |
|
|
|
return false |
|
|
|
return false |
|
|
|
} |
|
|
|
} |
|
|
|
if (!exists) { |
|
|
|
if (!exists) { |
|
|
|
event.trigger('fileAdded', [path]) |
|
|
|
event.trigger('fileAdded', [path, false]) |
|
|
|
} else { |
|
|
|
} else { |
|
|
|
event.trigger('fileChanged', [path]) |
|
|
|
event.trigger('fileChanged', [path]) |
|
|
|
} |
|
|
|
} |
|
|
@ -58,7 +58,7 @@ function Files (storage) { |
|
|
|
this.addReadOnly = function (path, content) { |
|
|
|
this.addReadOnly = function (path, content) { |
|
|
|
if (!storage.exists(path)) { |
|
|
|
if (!storage.exists(path)) { |
|
|
|
readonly[path] = content |
|
|
|
readonly[path] = content |
|
|
|
event.trigger('fileAdded', [path]) |
|
|
|
event.trigger('fileAdded', [path, true]) |
|
|
|
return true |
|
|
|
return true |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|