diff options
author | Nivesh Rajbhandari | 2012-03-30 11:04:47 -0700 |
---|---|---|
committer | Nivesh Rajbhandari | 2012-03-30 11:04:47 -0700 |
commit | 80782d5d0721463f716f0a7241afd09a38543199 (patch) | |
tree | 2dfb0531f2498afcad5afe95f8e338d0f1d34161 /js/components/tools-properties/brush-properties.reel/brush-properties.js | |
parent | 5b4f6b1618cf571a6bce5a631f976a008e04a64e (diff) | |
parent | f4949cab544886702e7ad6eeaa6215125c7b067a (diff) | |
download | ninja-80782d5d0721463f716f0a7241afd09a38543199.tar.gz |
Merge branch 'refs/heads/ninja-internal' into WebGLFileIO
Signed-off-by: Nivesh Rajbhandari <mqg734@motorola.com>
Diffstat (limited to 'js/components/tools-properties/brush-properties.reel/brush-properties.js')
-rwxr-xr-x | js/components/tools-properties/brush-properties.reel/brush-properties.js | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/js/components/tools-properties/brush-properties.reel/brush-properties.js b/js/components/tools-properties/brush-properties.reel/brush-properties.js index e6faa0f0..fdcd50f8 100755 --- a/js/components/tools-properties/brush-properties.reel/brush-properties.js +++ b/js/components/tools-properties/brush-properties.reel/brush-properties.js | |||
@@ -9,6 +9,33 @@ var Component = require("montage/ui/component").Component; | |||
9 | var ToolProperties = require("js/components/tools-properties/tool-properties").ToolProperties; | 9 | var ToolProperties = require("js/components/tools-properties/tool-properties").ToolProperties; |
10 | 10 | ||
11 | exports.BrushProperties = Montage.create(ToolProperties, { | 11 | exports.BrushProperties = Montage.create(ToolProperties, { |
12 | _subPrepare: { | ||
13 | value: function() { | ||
14 | this.handleChange(null); | ||
15 | this._useCalligraphic.addEventListener("change", this, false); | ||
16 | this._doSmoothing.addEventListener("change", this, false); | ||
17 | } | ||
18 | }, | ||
19 | handleChange: { | ||
20 | value: function(event) { | ||
21 | if(this._useCalligraphic.checked) { | ||
22 | this._strokeAngle.element.style["display"] = ""; | ||
23 | this._strokeAngle.visible = true; | ||
24 | this._angleLabel.style["display"] = ""; | ||
25 | } else { | ||
26 | this._strokeAngle.element.style["display"] = "none"; | ||
27 | this._strokeAngle.visible = false; | ||
28 | this._angleLabel.style["display"] = "none"; | ||
29 | } | ||
30 | if(this._doSmoothing.checked) { | ||
31 | this._smoothingAmount.element.style["display"] = ""; | ||
32 | this._smoothingAmount.visible = true; | ||
33 | } else { | ||
34 | this._smoothingAmount.element.style["display"] = "none"; | ||
35 | this._smoothingAmount.visible = false; | ||
36 | } | ||
37 | } | ||
38 | }, | ||
12 | strokeSize: { | 39 | strokeSize: { |
13 | get: function() { return this._strokeSize; } | 40 | get: function() { return this._strokeSize; } |
14 | }, | 41 | }, |
@@ -18,6 +45,9 @@ exports.BrushProperties = Montage.create(ToolProperties, { | |||
18 | doSmoothing:{ | 45 | doSmoothing:{ |
19 | get: function() {return this._doSmoothing.checked; } | 46 | get: function() {return this._doSmoothing.checked; } |
20 | }, | 47 | }, |
48 | smoothingAmount:{ | ||
49 | get: function() {return this._smoothingAmount;} | ||
50 | }, | ||
21 | useCalligraphic: { | 51 | useCalligraphic: { |
22 | get: function() {return this._useCalligraphic.checked;} | 52 | get: function() {return this._useCalligraphic.checked;} |
23 | }, | 53 | }, |