From fc13ef1e806116bb7ece5bb06604fa4f5714a6ed Mon Sep 17 00:00:00 2001 From: Nivesh Rajbhandari Date: Thu, 19 Jul 2012 10:55:22 -0700 Subject: Squashed commit of the following: commit 0285afe3d4bd458a51f11241f13ea6ffdb0283ed Merge: 2f9f5e3 16d06ba Author: Nivesh Rajbhandari Date: Thu Jul 19 10:54:25 2012 -0700 Merge branch 'refs/heads/ninja-mqg734-master' into StageToolDrawingOptimizations commit 2f9f5e369eb96f6c81b5e4bcbe09b418825e2864 Author: Nivesh Rajbhandari Date: Wed Jul 18 17:15:19 2012 -0700 Fixed selection bounds not drawing in nested tags. Signed-off-by: Nivesh Rajbhandari commit b0a3507f9d27579ad511c69314a09136d7f7c6a0 Author: Nivesh Rajbhandari Date: Wed Jul 18 11:07:44 2012 -0700 Layout info needs to redraw if stage is updated. Signed-off-by: Nivesh Rajbhandari commit 63c5e0bf52c33706ba597cb69f7794e287bd0f06 Author: Nivesh Rajbhandari Date: Tue Jul 17 15:40:54 2012 -0700 Per feedback from QE, we are still going to draw tool feedback on each mouse move so the selection bounds are not out of sync with the elements. Signed-off-by: Nivesh Rajbhandari commit 0599a742092b985c4002977e501e3b457173f1d9 Author: Nivesh Rajbhandari Date: Tue Jul 17 15:28:25 2012 -0700 Fixed grid not drawing correctly when switching documents and when adding/removing elements. Signed-off-by: Nivesh Rajbhandari commit fd9410606ee6358910d65b2cb5f71812fd44a7c4 Author: Nivesh Rajbhandari Date: Tue Jul 17 11:36:09 2012 -0700 Updated drawing feedback to handle matrix 2d values entered via CSS Panel. Signed-off-by: Nivesh Rajbhandari commit 559c16c7ac8c9f40b94a011a6f932d4f97df66a7 Author: Nivesh Rajbhandari Date: Mon Jul 16 17:14:28 2012 -0700 IKNinja-751 - Selection boundary doesn't follow the transform applied in the CSS Panel. Signed-off-by: Nivesh Rajbhandari commit e2da5340159db5cd6f75bf6c9b7eb9cbf959e5cd Merge: 7cc5de3 5146f22 Author: Nivesh Rajbhandari Date: Mon Jul 16 15:36:28 2012 -0700 Merge branch 'refs/heads/ninja-mqg734-master' into StageToolDrawingOptimizations commit 7cc5de39e41b4220f53c91b15b0cf0ed53e0b0f6 Author: Nivesh Rajbhandari Date: Mon Jul 16 14:52:06 2012 -0700 Check if ownerDocument.defaultValue is null. Signed-off-by: Nivesh Rajbhandari commit 5ae97995a28a4b06fb7f8703eb8090ea16d88acd Merge: d17974d 0ede302 Author: Nivesh Rajbhandari Date: Mon Jul 16 09:27:22 2012 -0700 Merge branch 'refs/heads/ninja-mqg734-master' into StageToolDrawingOptimizations commit d17974d77273bb635311cb6466f4427cf4d9e5d4 Author: Nivesh Rajbhandari Date: Mon Jul 16 08:45:05 2012 -0700 Pass in selectedElements array directly to drawUtils when drawing selection bounds instead of creating a duplicate array. Signed-off-by: Nivesh Rajbhandari commit 0b1ea3144cb3e2c1d272f60da32423d0604ace3b Author: Nivesh Rajbhandari Date: Fri Jul 13 14:03:40 2012 -0700 Fixed line tool not drawing the width and height info. Signed-off-by: Nivesh Rajbhandari commit b9c70e8d9ae324aa21fa5490edc71d8503bcefbc Author: Nivesh Rajbhandari Date: Fri Jul 13 12:42:25 2012 -0700 Used cached offsetWidth and offsetHeight. Signed-off-by: Nivesh Rajbhandari commit 9e17ac7124745ba745014efe149b31dee4fe658f Author: Nivesh Rajbhandari Date: Thu Jul 12 16:25:41 2012 -0700 Converting tabs to spaces … again! Signed-off-by: Nivesh Rajbhandari commit 351726c951bb73c28f0e15ea1ab32e85cc735688 Author: Nivesh Rajbhandari Date: Thu Jul 12 16:14:31 2012 -0700 Tabs should be 4 spaces. Signed-off-by: Nivesh Rajbhandari commit 250c419aa2dbcb10f012817ee7039aca77cb2518 Merge: 3f8d61a 2880e1d Author: Nivesh Rajbhandari Date: Thu Jul 12 16:08:31 2012 -0700 Merge branch 'refs/heads/ninja-mqg734-master' into StageToolDrawingOptimizations commit 3f8d61a676da3992947ed9a2ed0e449780fcfbe0 Author: Nivesh Rajbhandari Date: Thu Jul 12 15:53:44 2012 -0700 Rotate tool was not working immediately after switching selection and selection bounds were not drawing after resizing canvases. Signed-off-by: Nivesh Rajbhandari commit e2e1f81e3b6917e1032e1b99b79c266937f3bb25 Author: Nivesh Rajbhandari Date: Thu Jul 12 12:15:59 2012 -0700 Single draw cycle for stage updates and tool drawings. Signed-off-by: Nivesh Rajbhandari commit 95a90b4c95ee3163c97bea317144366674e49ade Author: Nivesh Rajbhandari Date: Mon Jun 18 11:46:38 2012 -0700 Single draw cycle for the stage and layout. Signed-off-by: Nivesh Rajbhandari commit 21966b1515d80d2161a14e5a19bc66f3f49a92ce Author: Nivesh Rajbhandari Date: Fri Jun 15 13:33:14 2012 -0700 Cache element offsets, including offsetParent. Signed-off-by: Nivesh Rajbhandari commit 80c563c8ba06149691c6c1e754dd9a5e43bc7d4b Author: Nivesh Rajbhandari Date: Mon Jul 9 17:30:00 2012 -0700 Open materials editor popup next to PI button. Signed-off-by: Nivesh Rajbhandari Signed-off-by: Nivesh Rajbhandari --- js/tools/Rotate3DToolBase.js | 1 - js/tools/SelectionTool.js | 2 -- js/tools/Translate3DToolBase.js | 1 - js/tools/modifier-tool-base.js | 3 --- 4 files changed, 7 deletions(-) (limited to 'js/tools') diff --git a/js/tools/Rotate3DToolBase.js b/js/tools/Rotate3DToolBase.js index e36e23c4..545aedad 100755 --- a/js/tools/Rotate3DToolBase.js +++ b/js/tools/Rotate3DToolBase.js @@ -485,7 +485,6 @@ exports.Rotate3DToolBase = Montage.create(ModifierToolBase, { if(len === 1) { this.target = this.application.ninja.selectedElements[0]; - drawUtils.addElement(this.target); viewUtils.pushViewportObj( this.target ); var eltCtr = viewUtils.getCenterOfProjection(); diff --git a/js/tools/SelectionTool.js b/js/tools/SelectionTool.js index 923ed819..a136113b 100755 --- a/js/tools/SelectionTool.js +++ b/js/tools/SelectionTool.js @@ -102,7 +102,6 @@ var SelectionTool = exports.SelectionTool = Montage.create(ModifierToolBase, { } this.isDrawing = true; - this.application.ninja.stage.showSelectionBounds = false; this._use3DMode = false; @@ -183,7 +182,6 @@ var SelectionTool = exports.SelectionTool = Montage.create(ModifierToolBase, { point = webkitConvertPointFromPageToNode(this.application.ninja.stage.canvas, new WebKitPoint(event.pageX, event.pageY)); this.isDrawing = false; - this.application.ninja.stage.showSelectionBounds = true; if(this._escape) { this._escape = false; this._isSelecting = false; diff --git a/js/tools/Translate3DToolBase.js b/js/tools/Translate3DToolBase.js index 57a379e4..b5008666 100755 --- a/js/tools/Translate3DToolBase.js +++ b/js/tools/Translate3DToolBase.js @@ -302,7 +302,6 @@ exports.Translate3DToolBase = Montage.create(ModifierToolBase, if(len) { if(len === 1) { this.target = this.application.ninja.selectedElements[0]; - drawUtils.addElement(this.target); viewUtils.pushViewportObj( this.target ); var eltCtr = viewUtils.getCenterOfProjection(); diff --git a/js/tools/modifier-tool-base.js b/js/tools/modifier-tool-base.js index 9b855e66..c772e36c 100755 --- a/js/tools/modifier-tool-base.js +++ b/js/tools/modifier-tool-base.js @@ -480,7 +480,6 @@ exports.ModifierToolBase = Montage.create(DrawingTool, { if(this._target) { this.isDrawing = true; - this.application.ninja.stage.showSelectionBounds = false; this._updateTargets(); if(this._canSnap) @@ -798,7 +797,6 @@ exports.ModifierToolBase = Montage.create(DrawingTool, { if(len === 1) { this.target = this.application.ninja.selectedElements[0]; - drawUtils.addElement(this.target); } else { @@ -882,7 +880,6 @@ exports.ModifierToolBase = Montage.create(DrawingTool, { new WebKitPoint(event.pageX, event.pageY)); this.isDrawing = false; - this.application.ninja.stage.showSelectionBounds = true; if(this._escape) { this._escape = false; return; -- cgit v1.2.3 From 71795a786342b3d84ef904dc448b4ce840a44810 Mon Sep 17 00:00:00 2001 From: Nivesh Rajbhandari Date: Thu, 19 Jul 2012 13:37:04 -0700 Subject: IKNINJA-1924 - Hovering over panel resizers after collapsing and expanding panel causes error. Canvas sizes were not updated when using the splitter to toggle collapse/expansion of panels. This was fixed by the StageDrawingFixes pull request. We should also guard agains null value in stage's getElement routine. Signed-off-by: Nivesh Rajbhandari --- js/tools/ShapeTool.js | 34 ---------------------------------- 1 file changed, 34 deletions(-) (limited to 'js/tools') diff --git a/js/tools/ShapeTool.js b/js/tools/ShapeTool.js index 26ed9c6f..ecc0dca3 100755 --- a/js/tools/ShapeTool.js +++ b/js/tools/ShapeTool.js @@ -70,7 +70,6 @@ exports.ShapeTool = Montage.create(DrawingTool, { this.doDraw(event); } else { this.doSnap(event); - this._showFeedbackOnMouseMove(event); } this.drawLastSnap(); // Required cleanup for both Draw/Feedbacks @@ -159,39 +158,6 @@ exports.ShapeTool = Montage.create(DrawingTool, { } }, - /** Show a border when mousing - * over existing canvas elements to signal to the user that - * the drawing operation will act on the targeted canvas. - **/ - _showFeedbackOnMouseMove: { - value: function (event) { - // TODO - This call is causing the canvas to redraw 3 times per mouse move - var targetedObject = this.application.ninja.stage.getElement(event, true); - - if (targetedObject) { - if((targetedObject.nodeName === "CANVAS") && !ShapesController.isElementAShape(targetedObject)) - { - if (targetedObject !== this._targetedElement) { - if(this._targetedElement) - { - this._targetedElement.classList.remove("active-element-outline"); - } - this._targetedElement = targetedObject; - this._targetedElement.classList.add("active-element-outline"); - } - } - else if (this._targetedElement) { - this._targetedElement.classList.remove("active-element-outline"); - this._targetedElement = null; - } - } - else if (this._targetedElement) { - this._targetedElement.classList.remove("elem-red-outline"); - this._targetedElement = null; - } - } - }, - RenderShape: { value: function (w, h, planeMat, midPt) -- cgit v1.2.3