diff options
author | Pushkar Joshi | 2012-02-24 12:08:49 -0800 |
---|---|---|
committer | Pushkar Joshi | 2012-02-24 12:08:49 -0800 |
commit | 03ca7a5ed13c25faaa9100bb666e062fd15335e6 (patch) | |
tree | c51112223ceb9121cd595a60335eb2795215590f /js/stage/layout.js | |
parent | fcb12cc09eb3cd3b42bd215877ba18f449275b75 (diff) | |
parent | 053fc63a2950c7a5ee4ebf98033b64d474a3c46e (diff) | |
download | ninja-03ca7a5ed13c25faaa9100bb666e062fd15335e6.tar.gz |
Merge branch 'pentool' into brushtool
Conflicts:
imports/codemirror/mode/scheme/scheme.js
js/tools/BrushTool.js
Diffstat (limited to 'js/stage/layout.js')
-rwxr-xr-x[-rw-r--r--] | js/stage/layout.js | 29 |
1 files changed, 24 insertions, 5 deletions
diff --git a/js/stage/layout.js b/js/stage/layout.js index 1a491210..56bb70bf 100644..100755 --- a/js/stage/layout.js +++ b/js/stage/layout.js | |||
@@ -195,11 +195,30 @@ exports.Layout = Montage.create(Component, { | |||
195 | bounds3D[j] = tmpPt; | 195 | bounds3D[j] = tmpPt; |
196 | } | 196 | } |
197 | 197 | ||
198 | // Draw the Item ouline | 198 | if(item.uuid === this.application.ninja.currentSelectedContainer.uuid) { |
199 | this._dashedLine(bounds3D[3][0] - 0.5,bounds3D[3][1]- 0.5,bounds3D[0][0] + 2.5, bounds3D[0][1] - 0.5,[5,5]); | 199 | this.ctx.save(); |
200 | this._dashedLine(bounds3D[0][0] - 0.5, bounds3D[0][1] - 0.5, bounds3D[1][0]- 0.5, bounds3D[1][1] + 0.5, [5,5] ); | 200 | this.ctx.strokeStyle = "#C61F00"; |
201 | this._dashedLine(bounds3D[1][0] - 0.5 , bounds3D[1][1] + 0.5, bounds3D[2][0]+ 0.5, bounds3D[2][1] + 0.5, [5,5] ); | 201 | |
202 | this._dashedLine(bounds3D[2][0] + 0.5, bounds3D[2][1] + 0.5, bounds3D[3][0] + 0.5, bounds3D[3][1] - 0.5, [5,5] ); | 202 | this.ctx.beginPath(); |
203 | |||
204 | this.ctx.moveTo( bounds3D[3][0] + 0.5 , bounds3D[3][1] - 0.5 ); | ||
205 | |||
206 | this.ctx.lineTo( bounds3D[0][0] - 0.5 , bounds3D[0][1] - 0.5 ); | ||
207 | this.ctx.lineTo( bounds3D[1][0] - 0.5 , bounds3D[1][1] + 0.5 ); | ||
208 | this.ctx.lineTo( bounds3D[2][0] + 0.5 , bounds3D[2][1] + 0.5 ); | ||
209 | this.ctx.lineTo( bounds3D[3][0] + 0.5 , bounds3D[3][1] + 0.5 ); | ||
210 | |||
211 | this.ctx.closePath(); | ||
212 | this.ctx.stroke(); | ||
213 | |||
214 | this.ctx.restore(); | ||
215 | } else { | ||
216 | // Draw the Item ouline | ||
217 | this._dashedLine(bounds3D[3][0] - 0.5,bounds3D[3][1]- 0.5,bounds3D[0][0] + 2.5, bounds3D[0][1] - 0.5,[5,5]); | ||
218 | this._dashedLine(bounds3D[0][0] - 0.5, bounds3D[0][1] - 0.5, bounds3D[1][0]- 0.5, bounds3D[1][1] + 0.5, [5,5] ); | ||
219 | this._dashedLine(bounds3D[1][0] - 0.5 , bounds3D[1][1] + 0.5, bounds3D[2][0]+ 0.5, bounds3D[2][1] + 0.5, [5,5] ); | ||
220 | this._dashedLine(bounds3D[2][0] + 0.5, bounds3D[2][1] + 0.5, bounds3D[3][0] + 0.5, bounds3D[3][1] - 0.5, [5,5] ); | ||
221 | } | ||
203 | 222 | ||
204 | // Draw the Label is all mode | 223 | // Draw the Label is all mode |
205 | if(this.layoutView === "layoutAll") { | 224 | if(this.layoutView === "layoutAll") { |