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

minor fixes

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@47670 954022d7-b5bf-4e40-9824-e11837661b57
parent 615dd7ce
......@@ -2119,15 +2119,13 @@ function DrawingObjects() {
}
_this._uploadMessage = function(event) {
if (null != event && null != event.data) {
if ( null != event && null != event.data ) {
var data = JSON.parse(event.data);
if(null != data && null != data.type)
if ( null != data && null != data.type )
{
if(PostMessageType.UploadImage == data.type)
{
if(c_oAscServerError.NoError == data.error)
{
if ( PostMessageType.UploadImage == data.type ) {
if(c_oAscServerError.NoError == data.error) {
var sheetId = null;
if(null != data.input)
sheetId = data.input.sheetId;
......@@ -2138,8 +2136,7 @@ function DrawingObjects() {
else
worksheet.model.workbook.handlers.trigger("asc_onEndAction", c_oAscAsyncActionType.BlockInteraction, c_oAscAsyncAction.LoadImage);
}
else
{
else {
worksheet.model.workbook.handlers.trigger("asc_onError", _mapAscServerErrorToAscError(data.error), c_oAscError.Level.NoCritical);
worksheet.model.workbook.handlers.trigger("asc_onEndAction", c_oAscAsyncActionType.BlockInteraction, c_oAscAsyncAction.LoadImage);
}
......
......@@ -46,8 +46,6 @@ function CImage(drawingBase, drawingObjects)
this.group = null;
this.x = null;
this.y = null;
this.x = null;
this.y = null;
this.extX = null;
......
......@@ -242,7 +242,7 @@ function RotateState(drawingObjectsController, drawingObjects, majorObject)
this.drawingObjectsController.clearTrackObjects();
this.drawingObjects.selectGraphicObject();
this.drawingObjectsController.changeCurrentState(new NullState(this.drawingObjectsController, this.drawingObjects));
asc.editor.asc_endAddShape();
asc["editor"].asc_endAddShape();
};
this.drawSelection = function(drawingDocument)
......@@ -305,7 +305,7 @@ function ResizeState(drawingObjectsController, drawingObjects, majorObject, card
this.drawingObjectsController.clearTrackObjects();
this.drawingObjects.selectGraphicObject();
this.drawingObjectsController.changeCurrentState(new NullState(this.drawingObjectsController, this.drawingObjects));
asc.editor.asc_endAddShape();
asc["editor"].asc_endAddShape();
};
this.drawSelection = function(drawingDocument)
......@@ -398,7 +398,7 @@ function TrackNewShapeState(drawingObjectsController, drawingObjects)
this.drawingObjectsController.clearTrackObjects();
this.drawingObjects.selectGraphicObject();
this.drawingObjectsController.changeCurrentState(new NullState(this.drawingObjectsController, this.drawingObjects));
asc.editor.asc_endAddShape();
asc["editor"].asc_endAddShape();
};
this.drawSelection = function(drawingDocument)
......@@ -513,7 +513,7 @@ function MoveState(drawingObjectsController, drawingObjects, startX, startY, rec
this.drawingObjectsController.clearTrackObjects();
this.drawingObjects.selectGraphicObject();
this.drawingObjectsController.changeCurrentState(new NullState(this.drawingObjectsController, this.drawingObjects));
asc.editor.asc_endAddShape();
asc["editor"].asc_endAddShape();
};
this.drawSelection = function(drawingDocument)
......
......@@ -1061,9 +1061,9 @@
// shapes
var graphicsInfo = t.handlers.trigger("getGraphicsInfo", coord.x, coord.y);
if ( graphicsInfo && graphicsInfo.isShape )
asc.editor.isStartAddShape = true;
asc["editor"].isStartAddShape = true;
if ( asc.editor.isStartAddShape ) {
if ( asc["editor"].isStartAddShape ) {
t.handlers.trigger("shapeMouseDown", event, coord.x, coord.y);
return;
}
......@@ -1203,7 +1203,7 @@
// shapes
var coord = this._getCoordinates(event);
if ( asc.editor.isStartAddShape ) {
if ( asc["editor"].isStartAddShape ) {
this.handlers.trigger("shapeMouseUp", event, coord.x, coord.y);
return;
}
......@@ -1252,7 +1252,7 @@
t.hasCursor = true;
// shapes
if ( asc.editor.isStartAddShape ) {
if ( asc["editor"].isStartAddShape ) {
t.handlers.trigger("shapeMouseMove", event, coord.x, coord.y);
t.handlers.trigger("updateWorksheet", t.element[0], coord.x, coord.y, event.ctrlKey, function(info){t.targetInfo = info;});
return;
......
......@@ -5029,7 +5029,7 @@
var lockInfo = undefined;
var isLocked = false;
if ( asc.editor.isStartAddShape )
if ( asc["editor"].isStartAddShape )
return {cursor: kCurFillHandle, target: "shape", col: -1, row: -1};
var drawingInfo = this.objectRender.checkCursorDrawingObject(x, y);
......@@ -5916,9 +5916,9 @@
var drawingInfo = this.objectRender.checkCursorDrawingObject(x, y);
if ( drawingInfo ) {
if ( drawingInfo.isShape )
asc.editor.isStartAddShape = true;
asc["editor"].isStartAddShape = true;
else
asc.editor.isStartAddShape = false;
asc["editor"].isStartAddShape = false;
}
// move active range to coordinates x,y
......
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