aboutsummaryrefslogtreecommitdiff
path: root/js/controllers/document-controller.js
diff options
context:
space:
mode:
authorValerio Virgillito2012-05-18 16:36:07 -0700
committerValerio Virgillito2012-05-18 16:36:07 -0700
commite7c288fe8f5d3a9e5c9f0eb0a045c6c195a0e7b8 (patch)
tree0b0ac15a0dd11a5996bd0c357693df62d1029669 /js/controllers/document-controller.js
parentfdfba499f0b84360b96096fa866a981e96e8756c (diff)
parent1056a45e0cbf92d578324ce70b8a17183320e64b (diff)
downloadninja-e7c288fe8f5d3a9e5c9f0eb0a045c6c195a0e7b8.tar.gz
Merge branch 'dom-architecture' of github.com:Motorola-Mobility/ninja-internal into dom-architecture
Diffstat (limited to 'js/controllers/document-controller.js')
-rwxr-xr-xjs/controllers/document-controller.js15
1 files changed, 8 insertions, 7 deletions
diff --git a/js/controllers/document-controller.js b/js/controllers/document-controller.js
index 7721d32d..f6b850b2 100755
--- a/js/controllers/document-controller.js
+++ b/js/controllers/document-controller.js
@@ -145,18 +145,19 @@ var DocumentController = exports.DocumentController = Montage.create(Component,
145 value: function(event) { 145 value: function(event) {
146 // 146 //
147 if((typeof this.activeDocument !== "undefined") && this.application.ninja.coreIoApi.cloudAvailable()){ 147 if((typeof this.activeDocument !== "undefined") && this.application.ninja.coreIoApi.cloudAvailable()){
148 // 148 //Currently we don't need a callback handler
149 this.activeDocument.model.save(this.testCallback.bind(this)); //this.fileSaveResult.bind(this) 149 //this.activeDocument.model.save(this.saveExecuted.bind(this));
150 this.activeDocument.model.save();
150 } else { 151 } else {
151 //Error: 152 //Error: cloud not available and/or no active document
152 } 153 }
153 } 154 }
154 }, 155 },
155 testCallback: { 156 ////////////////////////////////////////////////////////////////////
157 //
158 saveExecuted: {
156 value: function (value) { 159 value: function (value) {
157 console.log(value); 160 //File saved, any callbacks or events should go here
158 //TODO: Move this to the model.save()
159 this.activeDocument.model.needsSave = false;
160 } 161 }
161 }, 162 },
162 //////////////////////////////////////////////////////////////////// 163 ////////////////////////////////////////////////////////////////////