diff options
author | hwc487 | 2012-02-28 12:58:09 -0800 |
---|---|---|
committer | hwc487 | 2012-02-28 12:58:09 -0800 |
commit | 347fc28227d822e9fea3fa823fae79cf14ea041c (patch) | |
tree | 180e7ee1ad092397b05c0452e75d456fa0a3abb7 /js/io/ui/file-picker/file-input-field.reel | |
parent | ed16298e4323b733f6dc957c307dc07036fa3569 (diff) | |
parent | 7c9291a5bab4abd849547f8878f6fb962fc88250 (diff) | |
download | ninja-347fc28227d822e9fea3fa823fae79cf14ea041c.tar.gz |
Merge branch 'master' of github.com:Motorola-Mobility/ninja-internal into integration
Diffstat (limited to 'js/io/ui/file-picker/file-input-field.reel')
-rwxr-xr-x | js/io/ui/file-picker/file-input-field.reel/file-input-field.js | 21 |
1 files changed, 4 insertions, 17 deletions
diff --git a/js/io/ui/file-picker/file-input-field.reel/file-input-field.js b/js/io/ui/file-picker/file-input-field.reel/file-input-field.js index 235be8ad..651fd7fa 100755 --- a/js/io/ui/file-picker/file-input-field.reel/file-input-field.js +++ b/js/io/ui/file-picker/file-input-field.reel/file-input-field.js | |||
@@ -9,24 +9,13 @@ var Montage = require("montage/core/core").Montage, | |||
9 | 9 | ||
10 | var FileInputField = exports.FileInputField = Montage.create(Component, { | 10 | var FileInputField = exports.FileInputField = Montage.create(Component, { |
11 | 11 | ||
12 | hasReel: { | ||
13 | value: true | ||
14 | }, | ||
15 | |||
16 | willDraw: { | ||
17 | enumerable: false, | ||
18 | value: function() {} | ||
19 | }, | ||
20 | draw: { | ||
21 | enumerable: false, | ||
22 | value: function() {} | ||
23 | }, | ||
24 | didDraw: { | 12 | didDraw: { |
25 | enumerable: false, | 13 | enumerable: false, |
26 | value: function() { | 14 | value: function() { |
27 | var that = this; | 15 | var that = this; |
28 | this.findDirectory.identifier = "findDirectory"; | 16 | this.findDirectory.identifier = "findDirectory"; |
29 | this.findDirectory.addEventListener("click", function(evt){that.handleFindDirectoryClick(evt);}, false); | 17 | |
18 | this.findDirectory.addEventListener("click", this, false); | ||
30 | 19 | ||
31 | this.eventManager.addEventListener("pickerSelectionsDone", function(evt){that.handleFileInputPickerSelectionsDone(evt);}, false); | 20 | this.eventManager.addEventListener("pickerSelectionsDone", function(evt){that.handleFileInputPickerSelectionsDone(evt);}, false); |
32 | 21 | ||
@@ -60,8 +49,6 @@ var FileInputField = exports.FileInputField = Montage.create(Component, { | |||
60 | 49 | ||
61 | handleFindDirectoryClick: { | 50 | handleFindDirectoryClick: { |
62 | value: function(evt){ | 51 | value: function(evt){ |
63 | var openFilePicker = document.createEvent("Events"); | ||
64 | openFilePicker.initEvent("openFilePicker", false, false); | ||
65 | var settings = {}; | 52 | var settings = {}; |
66 | if(this.selectDirectory === true){ | 53 | if(this.selectDirectory === true){ |
67 | settings.inFileMode = false; | 54 | settings.inFileMode = false; |
@@ -71,8 +58,8 @@ var FileInputField = exports.FileInputField = Montage.create(Component, { | |||
71 | settings.pickerName = this.pickerName || "fileSelector"; | 58 | settings.pickerName = this.pickerName || "fileSelector"; |
72 | } | 59 | } |
73 | settings.callback = this.filePickerCallback.bind(this); | 60 | settings.callback = this.filePickerCallback.bind(this); |
74 | openFilePicker.settings = settings; | 61 | |
75 | this.eventManager.dispatchEvent(openFilePicker); | 62 | NJevent("openFilePicker", settings); |
76 | } | 63 | } |
77 | }, | 64 | }, |
78 | 65 | ||