mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-04-22 11:19:26 +02:00
LazReport, add keyboard acceleration to move/resize report objects, from Domingo Alvarez Duarte, issue #14782
git-svn-id: trunk@27865 -
This commit is contained in:
parent
fe03967bf5
commit
f7517a370c
@ -2940,6 +2940,15 @@ var
|
||||
StepX, StepY: Integer;
|
||||
i, tx, ty, tx1, ty1, d, d1: Integer;
|
||||
t, t1: TfrView;
|
||||
|
||||
procedure CheckStepFactor(var pStep: integer; aValue: integer);
|
||||
begin
|
||||
if (ssAlt in Shift) or (Shift = [ssShift,ssCtrl]) then
|
||||
pStep := aValue * 10
|
||||
else
|
||||
pStep := aValue;
|
||||
end;
|
||||
|
||||
begin
|
||||
{$IFNDEF EXTOI}
|
||||
if (ActiveControl<>nil) and (ActiveControl.Parent=ObjInsp.fPropertyGrid) then
|
||||
@ -3018,10 +3027,10 @@ begin
|
||||
end;
|
||||
if SelNum > 0 then
|
||||
begin
|
||||
if Key = vk_Up then StepY := -1
|
||||
else if Key = vk_Down then StepY := 1
|
||||
else if Key = vk_Left then StepX := -1
|
||||
else if Key = vk_Right then StepX := 1;
|
||||
if Key = vk_Up then CheckStepFactor(StepY, -1)
|
||||
else if Key = vk_Down then CheckStepFactor(StepY, 1)
|
||||
else if Key = vk_Left then CheckStepFactor(StepX, -1)
|
||||
else if Key = vk_Right then CheckStepFactor(StepX, 1);
|
||||
if (StepX <> 0) or (StepY <> 0) then
|
||||
begin
|
||||
if ssCtrl in Shift then
|
||||
|
Loading…
Reference in New Issue
Block a user