diff options
author | Jose Antonio Marquez | 2012-05-07 10:38:04 -0700 |
---|---|---|
committer | Jose Antonio Marquez | 2012-05-07 10:38:04 -0700 |
commit | 5293ede5f3493900df93da33197416d853f8d907 (patch) | |
tree | 3155deaea5616fa09fc96c84567419fec5f288a2 /js/helper-classes/3D/draw-utils.js | |
parent | 9c0bda09a502472768f6dd5090a882d11be58d23 (diff) | |
parent | 30e837ade2da7cb20caf7c5a69faf0888736bb9a (diff) | |
download | ninja-5293ede5f3493900df93da33197416d853f8d907.tar.gz |
Merge branch 'refs/heads/Ninja-DOM-Architecture' into Document
Diffstat (limited to 'js/helper-classes/3D/draw-utils.js')
-rwxr-xr-x | js/helper-classes/3D/draw-utils.js | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/js/helper-classes/3D/draw-utils.js b/js/helper-classes/3D/draw-utils.js index 88830964..f869f65e 100755 --- a/js/helper-classes/3D/draw-utils.js +++ b/js/helper-classes/3D/draw-utils.js | |||
@@ -584,18 +584,10 @@ var DrawUtils = exports.DrawUtils = Montage.create(Component, { | |||
584 | var ptOnPlane = MathUtils.getPointOnPlane(this._workingPlane); | 584 | var ptOnPlane = MathUtils.getPointOnPlane(this._workingPlane); |
585 | 585 | ||
586 | // define the grid parameters | 586 | // define the grid parameters |
587 | var width, | 587 | var width = this.snapManager.getStageWidth(), |
588 | height, | 588 | height = this.snapManager.getStageHeight(), |
589 | nLines = 10; | 589 | nLines = 10; |
590 | 590 | ||
591 | // if(this.application.ninja.documentController.webTemplate) { | ||
592 | if(this.application.ninja.currentDocument.documentRoot.id !== "UserContent") { | ||
593 | width = this.application.ninja.currentDocument.documentRoot.scrollWidth; | ||
594 | height = this.application.ninja.currentDocument.documentRoot.scrollHeight; | ||
595 | } else { | ||
596 | width = this.snapManager.getStageWidth(); | ||
597 | height = this.snapManager.getStageHeight(); | ||
598 | } | ||
599 | // get a matrix from working plane space to the world | 591 | // get a matrix from working plane space to the world |
600 | var mat = this.getPlaneToWorldMatrix(zAxis, ptOnPlane); | 592 | var mat = this.getPlaneToWorldMatrix(zAxis, ptOnPlane); |
601 | var tMat = Matrix.Translation( [0.5*width, 0.5*height, 0] ); | 593 | var tMat = Matrix.Translation( [0.5*width, 0.5*height, 0] ); |