diff options
Diffstat (limited to 'node_modules/montage/ui/native-control.js')
-rw-r--r-- | node_modules/montage/ui/native-control.js | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/node_modules/montage/ui/native-control.js b/node_modules/montage/ui/native-control.js index 907711e2..7cf65bd5 100644 --- a/node_modules/montage/ui/native-control.js +++ b/node_modules/montage/ui/native-control.js | |||
@@ -28,10 +28,11 @@ var NativeControl = exports.NativeControl = Montage.create(Component, { | |||
28 | return this._element; | 28 | return this._element; |
29 | }, | 29 | }, |
30 | set: function(value) { | 30 | set: function(value) { |
31 | //var component = Object.getPrototypeOf(NativeControl); | ||
32 | // call super set | ||
33 | Object.getPropertyDescriptor(Component, "element").set.call(this, value); | 31 | Object.getPropertyDescriptor(Component, "element").set.call(this, value); |
34 | this.didSetElement(); | 32 | |
33 | if (value) { | ||
34 | this.didSetElement(); | ||
35 | } | ||
35 | } | 36 | } |
36 | }, | 37 | }, |
37 | 38 | ||
@@ -188,7 +189,7 @@ var NativeControl = exports.NativeControl = Montage.create(Component, { | |||
188 | this["_"+attributeName] = this._elementAttributeDescriptors[attributeName].value; | 189 | this["_"+attributeName] = this._elementAttributeDescriptors[attributeName].value; |
189 | } | 190 | } |
190 | } | 191 | } |
191 | 192 | this.needsDraw = true; | |
192 | } | 193 | } |
193 | }, | 194 | }, |
194 | 195 | ||
@@ -221,12 +222,9 @@ var NativeControl = exports.NativeControl = Montage.create(Component, { | |||
221 | 222 | ||
222 | } | 223 | } |
223 | } | 224 | } |
224 | 225 | delete this._elementAttributeValues[attributeName]; | |
225 | } | 226 | } |
226 | } | 227 | } |
227 | // the values have been flushed to the DOM. | ||
228 | this._elementAttributeValues = {}; | ||
229 | |||
230 | } | 228 | } |
231 | } | 229 | } |
232 | }); | 230 | }); |