mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-19 05:39:29 +02:00
LCL Carbon: fixed 0010872: Block select on the Carbon IDE doesn't work as expected
mouse moves are called only when there is really some change git-svn-id: trunk@14435 -
This commit is contained in:
parent
d0b3a6aebd
commit
1783c8195e
@ -334,6 +334,9 @@ var PrevKeyModifiers: UInt32 = 0;
|
||||
// Stores mouse up message to be fired on control hit after value is updated
|
||||
var SavedMouseUpMsg: TLMMouse;
|
||||
|
||||
// Stores last mouse pos to call mouse move only when it really has changed
|
||||
var LastMousePos: TPoint;
|
||||
|
||||
{$I carbonprivatecommon.inc}
|
||||
{$I carbonprivatecontrol.inc}
|
||||
{$I carbonprivatewindow.inc}
|
||||
|
@ -121,6 +121,8 @@ begin
|
||||
if Widget <> nil then
|
||||
begin
|
||||
P := Widget.GetMousePos;
|
||||
if (LastMousePos.X = P.X) and (LastMousePos.Y = P.Y) then Exit;
|
||||
LastMousePos := P;
|
||||
|
||||
if Widget is TCarbonControl then
|
||||
if cceDoAction in (Widget as TCarbonControl).GetValidEvents then
|
||||
@ -192,6 +194,8 @@ begin
|
||||
Msg.YPos := P.Y;
|
||||
Msg.Keys := GetCarbonMsgKeyState;
|
||||
|
||||
LastMousePos := P;
|
||||
|
||||
if (AWidget is TCarbonControl) and
|
||||
(cceHit in (AWidget as TCarbonControl).GetValidEvents) then
|
||||
begin
|
||||
|
Loading…
Reference in New Issue
Block a user