diff options
author | Eric Guzman | 2012-03-29 16:29:04 -0700 |
---|---|---|
committer | Eric Guzman | 2012-03-29 16:29:04 -0700 |
commit | ccd57d8610a7839cf14b2c9e354b64acf53093a7 (patch) | |
tree | f11b4418483fd21831b72ca6dc0451422a25bfe2 /js/components/tools-properties/brush-properties.reel/brush-properties.js | |
parent | 7aefa059c79c9bef5c7a8a93cdfbd1ce55f69118 (diff) | |
parent | f4949cab544886702e7ad6eeaa6215125c7b067a (diff) | |
download | ninja-ccd57d8610a7839cf14b2c9e354b64acf53093a7.tar.gz |
Merge branch 'refs/heads/master' into PresetsPI
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 | }, |