Commit 78fb2052 authored by Sergey.Luzyanin's avatar Sergey.Luzyanin Committed by Alexander.Trofimov

Bug 20297 - Двойной клик не обрабатывается в режиме редактирования...

Bug 20297 - Двойной клик не обрабатывается в режиме редактирования надписей/заголовков внутри диаграммы;
Убрал мигание селекта при тройном клике

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@57178 954022d7-b5bf-4e40-9824-e11837661b57
parent b737f1ea
...@@ -481,8 +481,8 @@ DrawingObjectsController.prototype = ...@@ -481,8 +481,8 @@ DrawingObjectsController.prototype =
group.selection.textSelection = object; group.selection.textSelection = object;
} }
this.changeCurrentState(new TextAddState(this, object)); this.changeCurrentState(new TextAddState(this, object));
//if(e.ClickCount < 2) if(e.ClickCount < 2)
this.updateSelectionState(); this.updateSelectionState();
return true; return true;
} }
else else
......
...@@ -234,7 +234,10 @@ function handleGroup(drawing, drawingObjectsController, e, x, y, group, pageInde ...@@ -234,7 +234,10 @@ function handleGroup(drawing, drawingObjectsController, e, x, y, group, pageInde
cur_grouped_object.selection.textSelection = title; cur_grouped_object.selection.textSelection = title;
title.selectionSetStart(e, x, y, pageIndex); title.selectionSetStart(e, x, y, pageIndex);
drawingObjectsController.changeCurrentState(new TextAddState(drawingObjectsController, title)); drawingObjectsController.changeCurrentState(new TextAddState(drawingObjectsController, title));
drawingObjectsController.updateSelectionState(); if(e.ClickCount <= 1)
{
drawingObjectsController.updateSelectionState();
}
return true; return true;
} }
else else
...@@ -294,7 +297,10 @@ function handleChart(drawing, drawingObjectsController, e, x, y, group, pageInde ...@@ -294,7 +297,10 @@ function handleChart(drawing, drawingObjectsController, e, x, y, group, pageInde
drawing.selection.textSelection = title; drawing.selection.textSelection = title;
title.selectionSetStart(e, x, y, pageIndex); title.selectionSetStart(e, x, y, pageIndex);
drawingObjectsController.changeCurrentState(new TextAddState(drawingObjectsController, title)); drawingObjectsController.changeCurrentState(new TextAddState(drawingObjectsController, title));
drawingObjectsController.updateSelectionState(); if(e.ClickCount <= 1)
{
drawingObjectsController.updateSelectionState();
}
return true; return true;
} }
else else
...@@ -375,7 +381,10 @@ function handleInlineChart(drawing, drawingObjectsController, e, x, y, pageIndex ...@@ -375,7 +381,10 @@ function handleInlineChart(drawing, drawingObjectsController, e, x, y, pageIndex
drawing.selection.textSelection = title; drawing.selection.textSelection = title;
title.selectionSetStart(e, x, y, pageIndex); title.selectionSetStart(e, x, y, pageIndex);
drawingObjectsController.changeCurrentState(new TextAddState(drawingObjectsController, title)); drawingObjectsController.changeCurrentState(new TextAddState(drawingObjectsController, title));
drawingObjectsController.updateSelectionState(); if(e.ClickCount <= 1)
{
drawingObjectsController.updateSelectionState();
}
return true; return true;
} }
else else
......
...@@ -922,6 +922,7 @@ TextAddState.prototype = ...@@ -922,6 +922,7 @@ TextAddState.prototype =
onMouseUp: function(e, x, y, pageIndex) onMouseUp: function(e, x, y, pageIndex)
{ {
this.majorObject.selectionSetEnd(e, x, y, pageIndex); this.majorObject.selectionSetEnd(e, x, y, pageIndex);
this.drawingObjects.updateSelectionState();
this.drawingObjects.changeCurrentState(new NullState(this.drawingObjects)); this.drawingObjects.changeCurrentState(new NullState(this.drawingObjects));
} }
......
...@@ -287,8 +287,11 @@ DrawingObjectsController.prototype.onMouseDown = function(e, x, y) ...@@ -287,8 +287,11 @@ DrawingObjectsController.prototype.onMouseDown = function(e, x, y)
e.Button = e.button; e.Button = e.button;
e.Type = g_mouse_event_type_down; e.Type = g_mouse_event_type_down;
var ret = this.curState.onMouseDown(e, x, y, 0); var ret = this.curState.onMouseDown(e, x, y, 0);
this.updateOverlay(); if(e.ClickCount < 2)
this.updateSelectionState(); {
this.updateOverlay();
this.updateSelectionState();
}
return ret; return ret;
}; };
......
...@@ -199,7 +199,10 @@ NullState.prototype = ...@@ -199,7 +199,10 @@ NullState.prototype =
{ {
this.drawingObjects.checkChartTextSelection(); this.drawingObjects.checkChartTextSelection();
this.drawingObjects.resetInternalSelection(); this.drawingObjects.resetInternalSelection();
this.drawingObjects.updateOverlay(); if(e.ClickCount < 2)
{
this.drawingObjects.updateOverlay();
}
} }
if(!b_no_handle_selected) if(!b_no_handle_selected)
{ {
......
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