aboutsummaryrefslogtreecommitdiff
path: root/js/io/ui/new-file-dialog/new-file-location.reel
diff options
context:
space:
mode:
authorAnanya Sen2012-03-22 10:38:44 -0700
committerAnanya Sen2012-03-22 10:38:44 -0700
commit2557f463c1cfe2d0dd8ea187c184755bd141dab4 (patch)
treea842cee837b5d0c5a314bdd98b3c96eb98f154da /js/io/ui/new-file-dialog/new-file-location.reel
parent61a419422b1a05a779fd9a66c53de3fa8ab5f65a (diff)
downloadninja-2557f463c1cfe2d0dd8ea187c184755bd141dab4.tar.gz
IKNINJA-1302 : For File>New and File>SaveAll dialogs, 'ESC' key now triggers Cancel button and 'Enter' key now triggers OK button. For File picker, the 'ESC' now triggers the Cancel button.
Signed-off-by: Ananya Sen <Ananya.Sen@motorola.com> Conflicts: js/io/ui/new-file-dialog/new-file-workflow-controller.js Signed-off-by: Ananya Sen <Ananya.Sen@motorola.com>
Diffstat (limited to 'js/io/ui/new-file-dialog/new-file-location.reel')
-rwxr-xr-xjs/io/ui/new-file-dialog/new-file-location.reel/new-file-location.js6
1 files changed, 6 insertions, 0 deletions
diff --git a/js/io/ui/new-file-dialog/new-file-location.reel/new-file-location.js b/js/io/ui/new-file-dialog/new-file-location.reel/new-file-location.js
index 0e1e09a4..c4b7ea99 100755
--- a/js/io/ui/new-file-dialog/new-file-location.reel/new-file-location.js
+++ b/js/io/ui/new-file-dialog/new-file-location.reel/new-file-location.js
@@ -34,6 +34,12 @@ var NewFileLocation = exports.NewFileLocation = Montage.create(Component, {
34 newFileNameSetEvent.newFileName = this.newFileName.value; 34 newFileNameSetEvent.newFileName = this.newFileName.value;
35 this.eventManager.dispatchEvent(newFileNameSetEvent); 35 this.eventManager.dispatchEvent(newFileNameSetEvent);
36 } 36 }
37 if(evt.keyCode === 13){
38 var enterPressedEvent = document.createEvent("Events");
39 enterPressedEvent.initEvent("enterPressed", false, false);
40 enterPressedEvent.newFileName = this.newFileName.value;
41 this.eventManager.dispatchEvent(enterPressedEvent);
42 }
37 } 43 }
38 } 44 }
39 45