diff options
author | Armen Kesablyan | 2012-06-19 01:03:59 -0700 |
---|---|---|
committer | Armen Kesablyan | 2012-06-19 01:03:59 -0700 |
commit | 2e13a73e4ee980a6f73f6ff48b2a195eb209a7db (patch) | |
tree | d352f5e769eae0e1b7b76ccbeafa9b174b1a9918 /js/components/hottextunit.reel/hottextunit.js | |
parent | 244e608645778746d1a3b5aa0d4c0868f7c5c272 (diff) | |
parent | c59eb371559a3061ce53223e249ca97daace5968 (diff) | |
download | ninja-2e13a73e4ee980a6f73f6ff48b2a195eb209a7db.tar.gz |
Merge branch 'refs/heads/master' into binding
Conflicts:
js/components/layout/tools-list.reel/tools-list.html
js/components/layout/tools-properties.reel/tools-properties.html
js/document/document-html.js
js/document/templates/app/main.js
js/panels/Panel.reel/Panel.js
node_modules/montage/ui/native-control.js
Signed-off-by: Armen Kesablyan <armen@motorola.com>
Diffstat (limited to 'js/components/hottextunit.reel/hottextunit.js')
-rwxr-xr-x | js/components/hottextunit.reel/hottextunit.js | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/js/components/hottextunit.reel/hottextunit.js b/js/components/hottextunit.reel/hottextunit.js index 448eb9d7..2a89db03 100755 --- a/js/components/hottextunit.reel/hottextunit.js +++ b/js/components/hottextunit.reel/hottextunit.js | |||
@@ -40,11 +40,14 @@ var HotTextUnit = exports.HotTextUnit = Montage.create(HotText, { | |||
40 | if(this._acceptableUnits.indexOf(value) !== -1) | 40 | if(this._acceptableUnits.indexOf(value) !== -1) |
41 | { | 41 | { |
42 | this._units = value; | 42 | this._units = value; |
43 | this._unitsModified = true; | ||
43 | this.needsDraw = true; | 44 | this.needsDraw = true; |
44 | 45 | ||
45 | this._setEventFlags("change", false); | 46 | this._setEventFlags("change", true); |
46 | this._dispatchActionEvent(); | 47 | this._dispatchActionEvent(); |
47 | } | 48 | } |
49 | } else { | ||
50 | this._unitsModified = false; | ||
48 | } | 51 | } |
49 | } | 52 | } |
50 | }, | 53 | }, |
@@ -89,13 +92,13 @@ var HotTextUnit = exports.HotTextUnit = Montage.create(HotText, { | |||
89 | var match = (unitsString.replace(noSpaces, "$2")).toLowerCase(); | 92 | var match = (unitsString.replace(noSpaces, "$2")).toLowerCase(); |
90 | if(match) | 93 | if(match) |
91 | { | 94 | { |
92 | Object.getPropertyDescriptor(this, "units").set.call(this, match); | 95 | this.units = match; |
93 | } | 96 | } |
94 | } | 97 | } |
95 | 98 | ||
96 | this._setEventFlags("change", false); | 99 | this._setEventFlags("change", false); |
97 | // Moving this call to after setting the value since value changes are dispatching events before units are set | 100 | // Moving this call to after setting the value since value changes are dispatching events before units are set |
98 | Object.getPropertyDescriptor(this, "value").set.call(this, this.inputFunction(inputString), false); | 101 | this.value = this.inputFunction(inputString); |
99 | } | 102 | } |
100 | }, | 103 | }, |
101 | 104 | ||