aboutsummaryrefslogtreecommitdiff
path: root/js/io/ui/save-as-dialog.reel/save-as-dialog.js
diff options
context:
space:
mode:
Diffstat (limited to 'js/io/ui/save-as-dialog.reel/save-as-dialog.js')
-rw-r--r--js/io/ui/save-as-dialog.reel/save-as-dialog.js12
1 files changed, 6 insertions, 6 deletions
diff --git a/js/io/ui/save-as-dialog.reel/save-as-dialog.js b/js/io/ui/save-as-dialog.reel/save-as-dialog.js
index d1f1c26b..4546e124 100644
--- a/js/io/ui/save-as-dialog.reel/save-as-dialog.js
+++ b/js/io/ui/save-as-dialog.reel/save-as-dialog.js
@@ -54,7 +54,7 @@ var SaveAsDialog = exports.SaveAsDialog = Montage.create(Component, {
54 this.newFileName.value = this.fileName; 54 this.newFileName.value = this.fileName;
55 this.fileInputField.newFileDirectory.value = this.folderUri; 55 this.fileInputField.newFileDirectory.value = this.folderUri;
56 56
57 this.newFileName.addEventListener("blur", function(evt){self.handleNewFileNameOnblur(evt);}, false); 57 this.newFileName.addEventListener("keyup", function(evt){self.handleNewFileNameOnkeyup(evt);}, false);
58 this.eventManager.addEventListener("newFileDirectorySet", function(evt){self.handleNewFileDirectorySet(evt);}, false); 58 this.eventManager.addEventListener("newFileDirectorySet", function(evt){self.handleNewFileDirectorySet(evt);}, false);
59 59
60 this.okButton.addEventListener("click", function(evt){self.handleOkButtonAction(evt);}, false); 60 this.okButton.addEventListener("click", function(evt){self.handleOkButtonAction(evt);}, false);
@@ -68,18 +68,18 @@ var SaveAsDialog = exports.SaveAsDialog = Montage.create(Component, {
68 value:function(evt){ 68 value:function(evt){
69 if(!!evt._event.newFileDirectory){ 69 if(!!evt._event.newFileDirectory){
70 this.folderUri = evt._event.newFileDirectory; 70 this.folderUri = evt._event.newFileDirectory;
71 if(this.folderUri !== ""){ 71 if(this.isValidUri(this.folderUri)){
72 this.enableOk(); 72 this.enableOk();
73 } 73 }
74 } 74 }
75 } 75 }
76 }, 76 },
77 77
78 handleNewFileNameOnblur:{ 78 handleNewFileNameOnkeyup:{
79 value:function(evt){ 79 value:function(evt){
80 this.fileName = this.newFileName.value; 80 this.fileName = this.newFileName.value;
81 if(this.fileName !== ""){ 81 if(this.fileName !== ""){
82 if(this.fileName !== ""){ 82 if(this.isValidFileName(this.fileName)){
83 this.enableOk(); 83 this.enableOk();
84 } 84 }
85 } 85 }
@@ -165,7 +165,7 @@ var SaveAsDialog = exports.SaveAsDialog = Montage.create(Component, {
165 }, 165 },
166 isValidFileName:{ 166 isValidFileName:{
167 value: function(fileName){ 167 value: function(fileName){
168 var status = this.isValidFileName(fileName); 168 var status = this.validateFileName(fileName);
169 if(fileName !== ""){ 169 if(fileName !== ""){
170 if(!status){ 170 if(!status){
171 this.showError("! Invalid file name."); 171 this.showError("! Invalid file name.");
@@ -198,7 +198,7 @@ var SaveAsDialog = exports.SaveAsDialog = Montage.create(Component, {
198 /*** 198 /***
199 * file name validation 199 * file name validation
200 */ 200 */
201 isValidFileName:{ 201 validateFileName:{
202 value: function(fileName){ 202 value: function(fileName){
203 var status = false; 203 var status = false;
204 if(fileName !== ""){ 204 if(fileName !== ""){