aboutsummaryrefslogtreecommitdiff
path: root/js
diff options
context:
space:
mode:
Diffstat (limited to 'js')
-rwxr-xr-xjs/tools/SelectionTool.js13
-rwxr-xr-xjs/tools/modifier-tool-base.js3
2 files changed, 2 insertions, 14 deletions
diff --git a/js/tools/SelectionTool.js b/js/tools/SelectionTool.js
index 48548271..f76a6d85 100755
--- a/js/tools/SelectionTool.js
+++ b/js/tools/SelectionTool.js
@@ -115,8 +115,7 @@ var SelectionTool = exports.SelectionTool = Montage.create(ModifierToolBase, {
115 HandleLeftButtonUp: { 115 HandleLeftButtonUp: {
116 value: function(event) { 116 value: function(event) {
117 var selectedItems, 117 var selectedItems,
118 point = webkitConvertPointFromPageToNode(this.application.ninja.stage.canvas, 118 point = webkitConvertPointFromPageToNode(this.application.ninja.stage.canvas, new WebKitPoint(event.pageX, event.pageY));
119 new WebKitPoint(event.pageX, event.pageY));
120 119
121 this.isDrawing = false; 120 this.isDrawing = false;
122 this.application.ninja.stage.showSelectionBounds = true; 121 this.application.ninja.stage.showSelectionBounds = true;
@@ -186,21 +185,11 @@ var SelectionTool = exports.SelectionTool = Montage.create(ModifierToolBase, {
186 185
187 HandleDoubleClick: { 186 HandleDoubleClick: {
188 value: function(event) { 187 value: function(event) {
189 /*
190 var selectedObject = stageManagerModule.stageManager.GetObjectFromPoint(event.layerX, event.layerY, this._canOperateOnStage);
191
192 if(selectedObject) {
193 if(selectionManagerModule.selectionManager.findSelectedElement(selectedObject) === -1) {
194 selectionManagerModule.selectionManager.setSingleSelection(selectedObject);
195 }
196 }
197 */
198 188
199 // Temporary Code for Breadcrumb 189 // Temporary Code for Breadcrumb
200 if(this.application.ninja.selectedElements.length > 0) { 190 if(this.application.ninja.selectedElements.length > 0) {
201 this.application.ninja.currentSelectedContainer = this.application.ninja.selectedElements[0]._element; 191 this.application.ninja.currentSelectedContainer = this.application.ninja.selectedElements[0]._element;
202 } else { 192 } else {
203 console.log(this.application.ninja.currentDocument.documentRoot.uuid);
204 this.application.ninja.currentSelectedContainer = this.application.ninja.currentDocument.documentRoot; 193 this.application.ninja.currentSelectedContainer = this.application.ninja.currentDocument.documentRoot;
205 } 194 }
206 195
diff --git a/js/tools/modifier-tool-base.js b/js/tools/modifier-tool-base.js
index 67b217c4..54bc06be 100755
--- a/js/tools/modifier-tool-base.js
+++ b/js/tools/modifier-tool-base.js
@@ -791,8 +791,7 @@ exports.ModifierToolBase = Montage.create(DrawingTool, {
791 HandleLeftButtonDown: { 791 HandleLeftButtonDown: {
792 value: function(event) { 792 value: function(event) {
793 793
794 var point = webkitConvertPointFromPageToNode(this.application.ninja.stage.canvas, 794 var point = webkitConvertPointFromPageToNode(this.application.ninja.stage.canvas, new WebKitPoint(event.pageX, event.pageY));
795 new WebKitPoint(event.pageX, event.pageY));
796 this.downPoint.x = point.x; 795 this.downPoint.x = point.x;
797 this.downPoint.y = point.y; 796 this.downPoint.y = point.y;
798 797