Commit 5fb4f39f authored by Dmitry.Vikulov's avatar Dmitry.Vikulov Committed by Alexander.Trofimov

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@47598 954022d7-b5bf-4e40-9824-e11837661b57
parent 09e7c43c
...@@ -186,6 +186,7 @@ function RotateState(drawingObjectsController, drawingObjects, majorObject) ...@@ -186,6 +186,7 @@ function RotateState(drawingObjectsController, drawingObjects, majorObject)
{ {
this.drawingObjectsController.trackEnd(); this.drawingObjectsController.trackEnd();
this.drawingObjectsController.changeCurrentState(new NullState(this.drawingObjectsController, this.drawingObjects)); this.drawingObjectsController.changeCurrentState(new NullState(this.drawingObjectsController, this.drawingObjects));
asc.editor.asc_endAddShape();
} }
} }
...@@ -368,6 +369,7 @@ function MoveState(drawingObjectsController, drawingObjects, startX, startY) ...@@ -368,6 +369,7 @@ function MoveState(drawingObjectsController, drawingObjects, startX, startY)
this.drawingObjectsController.trackEnd(); this.drawingObjectsController.trackEnd();
this.drawingObjectsController.clearTrackObjects(); this.drawingObjectsController.clearTrackObjects();
this.drawingObjectsController.changeCurrentState(new NullState(this.drawingObjectsController, this.drawingObjects)); this.drawingObjectsController.changeCurrentState(new NullState(this.drawingObjectsController, this.drawingObjects));
asc.editor.asc_endAddShape();
} }
} }
......
...@@ -1059,7 +1059,11 @@ ...@@ -1059,7 +1059,11 @@
this.handlers.trigger("setShiftKey", event.shiftKey); this.handlers.trigger("setShiftKey", event.shiftKey);
// shapes // shapes
if ( asc.editor.isStartAddShape ) { var graphicsInfo = t.handlers.trigger("getGraphicsInfo", coord.x, coord.y);
if ( graphicsInfo && graphicsInfo.isShape )
asc.editor.isStartAddShape = true;
if ( asc.editor.isStartAddShape || graphicsInfo ) {
t.handlers.trigger("shapeMouseDown", event, coord.x, coord.y); t.handlers.trigger("shapeMouseDown", event, coord.x, coord.y);
return; return;
} }
......
...@@ -201,7 +201,8 @@ ...@@ -201,7 +201,8 @@
// shapes // shapes
"shapeMouseDown": function () {self._onShapeMouseDown.apply(self, arguments);}, "shapeMouseDown": function () {self._onShapeMouseDown.apply(self, arguments);},
"shapeMouseMove": function () {self._onShapeMouseMove.apply(self, arguments);}, "shapeMouseMove": function () {self._onShapeMouseMove.apply(self, arguments);},
"shapeMouseUp": function () {self._onShapeMouseUp.apply(self, arguments);} "shapeMouseUp": function () {self._onShapeMouseUp.apply(self, arguments);},
"getGraphicsInfo": function () {return self._onGetGraphicsInfo.apply(self, arguments);}
}); });
this.model.handlers.add("cleanCellCache", function (wsId, range, canChangeColWidth) { this.model.handlers.add("cleanCellCache", function (wsId, range, canChangeColWidth) {
...@@ -668,6 +669,11 @@ ...@@ -668,6 +669,11 @@
ws.objectRender.shapeMouseUp(e, x, y); ws.objectRender.shapeMouseUp(e, x, y);
}, },
_onGetGraphicsInfo: function (x, y) {
var ws = this.getWorksheet();
return ws.objectRender.checkCursorDrawingObject(x, y);
},
_onMouseDblClick: function (x, y, isHideCursor, isCoord, callback) { _onMouseDblClick: function (x, y, isHideCursor, isCoord, callback) {
var res = false; var res = false;
var ws = this.getWorksheet(); var ws = this.getWorksheet();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment