aboutsummaryrefslogtreecommitdiff
path: root/js/io/ui/new-file-dialog/new-file-location.reel/new-file-location.js
diff options
context:
space:
mode:
authorEric Guzman2012-04-05 18:42:40 -0700
committerEric Guzman2012-04-05 18:42:40 -0700
commit8ff9dde2053e41d85bb27d9c91808a30e551a138 (patch)
tree8eec67d632d82d3052ed470096eda13fd50a55c8 /js/io/ui/new-file-dialog/new-file-location.reel/new-file-location.js
parent4631d54ffb4942378835689e9f5d70ed95610822 (diff)
parent7656b6eac7aec59697c6cddbe2a507fe9e4aa187 (diff)
downloadninja-8ff9dde2053e41d85bb27d9c91808a30e551a138.tar.gz
Merge branch 'refs/heads/master' into CSSPanelUpdates
Diffstat (limited to 'js/io/ui/new-file-dialog/new-file-location.reel/new-file-location.js')
-rwxr-xr-xjs/io/ui/new-file-dialog/new-file-location.reel/new-file-location.js19
1 files changed, 11 insertions, 8 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 02579676..3582f1a5 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
@@ -24,6 +24,7 @@ var NewFileLocation = exports.NewFileLocation = Montage.create(Component, {
24 24
25 this.newFileName.addEventListener("keyup", this, false); 25 this.newFileName.addEventListener("keyup", this, false);
26 this.newFileName.addEventListener("paste", this, false); 26 this.newFileName.addEventListener("paste", this, false);
27 this.newFileName.addEventListener("search", this, false);
27 this.newFileName.focus(); 28 this.newFileName.focus();
28 this.newFileName.select(); 29 this.newFileName.select();
29 } 30 }
@@ -39,14 +40,16 @@ var NewFileLocation = exports.NewFileLocation = Montage.create(Component, {
39 40
40 handleKeyup:{ 41 handleKeyup:{
41 value:function(evt){ 42 value:function(evt){
42 if(this.newFileName.value !== "") { 43 var newFileNameSetEvent = document.createEvent("Events");
43 var newFileNameSetEvent = document.createEvent("Events"); 44 newFileNameSetEvent.initEvent("newFileNameSet", false, false);
44 newFileNameSetEvent.initEvent("newFileNameSet", false, false); 45 newFileNameSetEvent.newFileName = this.newFileName.value;
45 newFileNameSetEvent.newFileName = this.newFileName.value; 46 newFileNameSetEvent.keyCode = evt.keyCode;
46 newFileNameSetEvent.keyCode = evt.keyCode; 47 this.eventManager.dispatchEvent(newFileNameSetEvent);
47 this.eventManager.dispatchEvent(newFileNameSetEvent); 48 }
48 } 49 },
50 handleSearch:{
51 value:function(evt){
52 this.handleKeyup(evt);
49 } 53 }
50 } 54 }
51
52}); \ No newline at end of file 55}); \ No newline at end of file