Commit 48e14fb9 authored by Sergey.Luzyanin's avatar Sergey.Luzyanin Committed by Alexander.Trofimov

Bug 24709 - После открытия контекстного меню для группы и отдельной...

Bug 24709 - После открытия контекстного меню для группы и отдельной автофигуры, выделение сбрасывается с объектов 

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@56628 954022d7-b5bf-4e40-9824-e11837661b57
parent 25ea7119
"use strict"; "use strict";
function CShapeColor(r, g, b) function CShapeColor(r, g, b){
{
this.r = r; this.r = r;
this.g = g; this.g = g;
this.b = b; this.b = b;
this.darken = function() this.darken = function ()
{ {
var hslColor = RGBToHSL(this); var hslColor = RGBToHSL(this);
hslColor.l*=0.9; hslColor.l *= 0.9;
return HSLToRGB(hslColor); return HSLToRGB(hslColor);
}; };
this.darkenLess = function() this.darkenLess = function ()
{ {
var hslColor = RGBToHSL(this); var hslColor = RGBToHSL(this);
hslColor.l*=0.85; hslColor.l *= 0.85;
return HSLToRGB(hslColor); return HSLToRGB(hslColor);
}; };
this.lighten = function() this.lighten = function () {
{
var hslColor = RGBToHSL(this); var hslColor = RGBToHSL(this);
hslColor.l*= 1.1; hslColor.l *= 1.1;
if(hslColor.l > 1) if(hslColor.l > 1)
{ {
hslColor.l = 1; hslColor.l = 1;
......
...@@ -318,7 +318,7 @@ function handleMouseUpPreMoveState(drawingObjects, e, x, y, pageIndex, bWord) ...@@ -318,7 +318,7 @@ function handleMouseUpPreMoveState(drawingObjects, e, x, y, pageIndex, bWord)
var state = drawingObjects.curState; var state = drawingObjects.curState;
state.drawingObjects.clearPreTrackObjects(); state.drawingObjects.clearPreTrackObjects();
state.drawingObjects.changeCurrentState(new NullState(state.drawingObjects)); state.drawingObjects.changeCurrentState(new NullState(state.drawingObjects));
if(!state.shift && !state.ctrl && state.bInside && state.majorObjectIsSelected) if(!state.shift && !state.ctrl && state.bInside && state.majorObjectIsSelected && e.Button !== g_mouse_button_right)
{ {
switch (state.majorObject.getObjectType()) switch (state.majorObject.getObjectType())
{ {
......
...@@ -278,6 +278,7 @@ DrawingObjectsController.prototype.onMouseDown = function(e, x, y) ...@@ -278,6 +278,7 @@ DrawingObjectsController.prototype.onMouseDown = function(e, x, y)
{ {
e.ShiftKey = e.shiftKey; e.ShiftKey = e.shiftKey;
e.CtrlKey = e.metaKey || e.ctrlKey; e.CtrlKey = e.metaKey || e.ctrlKey;
e.Button = e.button;
var ret = this.curState.onMouseDown(e, x, y, 0); var ret = this.curState.onMouseDown(e, x, y, 0);
this.updateOverlay(); this.updateOverlay();
this.updateSelectionState(); this.updateSelectionState();
...@@ -290,6 +291,7 @@ DrawingObjectsController.prototype.onMouseMove = function(e, x, y) ...@@ -290,6 +291,7 @@ DrawingObjectsController.prototype.onMouseMove = function(e, x, y)
{ {
e.ShiftKey = e.shiftKey; e.ShiftKey = e.shiftKey;
e.CtrlKey = e.metaKey || e.ctrlKey; e.CtrlKey = e.metaKey || e.ctrlKey;
e.Button = e.button;
this.curState.onMouseMove(e, x, y, 0); this.curState.onMouseMove(e, x, y, 0);
}; };
DrawingObjectsController.prototype.OnMouseMove = DrawingObjectsController.prototype.onMouseMove; DrawingObjectsController.prototype.OnMouseMove = DrawingObjectsController.prototype.onMouseMove;
...@@ -299,6 +301,7 @@ DrawingObjectsController.prototype.onMouseUp = function(e, x, y) ...@@ -299,6 +301,7 @@ DrawingObjectsController.prototype.onMouseUp = function(e, x, y)
{ {
e.ShiftKey = e.shiftKey; e.ShiftKey = e.shiftKey;
e.CtrlKey = e.metaKey || e.ctrlKey; e.CtrlKey = e.metaKey || e.ctrlKey;
e.Button = e.button;
this.curState.onMouseUp(e, x, y, 0); this.curState.onMouseUp(e, x, y, 0);
}; };
DrawingObjectsController.prototype.OnMouseUp = DrawingObjectsController.prototype.onMouseUp; DrawingObjectsController.prototype.OnMouseUp = DrawingObjectsController.prototype.onMouseUp;
......
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