diff options
author | Valerio Virgillito | 2012-02-08 17:49:02 -0800 |
---|---|---|
committer | Valerio Virgillito | 2012-02-08 17:49:02 -0800 |
commit | 88e80d512bdd125e6d604541c291f699bf5df564 (patch) | |
tree | b6d17d50401cb3da3de7d34d8e7f92dcf59fc14a /js/panels/properties | |
parent | 26c470085263ab40a30fc8095bfe3763df5be981 (diff) | |
download | ninja-88e80d512bdd125e6d604541c291f699bf5df564.tar.gz |
Correcting the PI lock for height which had a bug in the original pull request.
Signed-off-by: Valerio Virgillito <valerio@motorola.com>
Diffstat (limited to 'js/panels/properties')
-rw-r--r-- | js/panels/properties/sections/position-and-size.reel/position-and-size.js | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/js/panels/properties/sections/position-and-size.reel/position-and-size.js b/js/panels/properties/sections/position-and-size.reel/position-and-size.js index e539257d..49117090 100644 --- a/js/panels/properties/sections/position-and-size.reel/position-and-size.js +++ b/js/panels/properties/sections/position-and-size.reel/position-and-size.js | |||
@@ -149,6 +149,7 @@ exports.PosSize = Montage.create(Component, { | |||
149 | this.application.ninja.selectedElements.length ? items = this.application.ninja.selectedElements : items = [this.application.ninja.currentDocument.documentRoot]; | 149 | this.application.ninja.selectedElements.length ? items = this.application.ninja.selectedElements : items = [this.application.ninja.currentDocument.documentRoot]; |
150 | 150 | ||
151 | if(this.bindButton.value) { | 151 | if(this.bindButton.value) { |
152 | |||
152 | var newWidth = Math.round(this.aspectRatioHeight * this.heightControl.value); | 153 | var newWidth = Math.round(this.aspectRatioHeight * this.heightControl.value); |
153 | 154 | ||
154 | if(!isFinite(newWidth)) newWidth = this.heightControl.value; | 155 | if(!isFinite(newWidth)) newWidth = this.heightControl.value; |
@@ -181,12 +182,10 @@ exports.PosSize = Montage.create(Component, { | |||
181 | this.heightControl.value = newHeight; | 182 | this.heightControl.value = newHeight; |
182 | this.application.ninja.elementMediator.setProperty(items, "height", [newHeight + "px"] , "Change", "pi"); | 183 | this.application.ninja.elementMediator.setProperty(items, "height", [newHeight + "px"] , "Change", "pi"); |
183 | 184 | ||
184 | } else { | ||
185 | |||
186 | this.application.ninja.elementMediator.setProperty(items, "width", [this.widthControl.value + "px"] , "Change", "pi", prevPosition); | ||
187 | this.savedPosition = null; | ||
188 | } | 185 | } |
189 | 186 | ||
187 | this.application.ninja.elementMediator.setProperty(items, "width", [this.widthControl.value + "px"] , "Change", "pi", prevPosition); | ||
188 | this.savedPosition = null; | ||
190 | 189 | ||
191 | } | 190 | } |
192 | 191 | ||