From 4656d793e87ed7bac4ed91358ff6869ea5e44158 Mon Sep 17 00:00:00 2001 From: blikblum Date: Wed, 30 Dec 2009 11:00:45 +0000 Subject: [PATCH] * Call DoHeaderMouseMove only if inside header * Don't adjust the coordinates passed to DoHeaderMouseMove since they already in client coordinates git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@1097 8e941d3f-bd1b-0410-a28a-d453659cc2b4 --- components/virtualtreeview-new/trunk/VirtualTrees.pas | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/components/virtualtreeview-new/trunk/VirtualTrees.pas b/components/virtualtreeview-new/trunk/VirtualTrees.pas index a2dab7233..f74efc317 100644 --- a/components/virtualtreeview-new/trunk/VirtualTrees.pas +++ b/components/virtualtreeview-new/trunk/VirtualTrees.pas @@ -9988,10 +9988,9 @@ begin P := Point(XPos,YPos); //P := Treeview.ScreenToClient(Point(XPos, YPos)); - //todo: see if OnHeaderMouseMove is fired even if not inside header - Treeview.DoHeaderMouseMove(GetShiftState, P.X, P.Y + Integer(FHeight)); if not InHeader(P) then Exit; + Treeview.DoHeaderMouseMove(GetShiftState, P.X, P.Y); if ((AdjustHoverColumn(P)) or ((FDownIndex >= 0) and (FHoverIndex <> FDownIndex))) then begin // We need a mouse leave detection from here for the non client area. The best solution available would be the @@ -10000,12 +9999,14 @@ begin // (although, I don't like it...). KillTimer(Treeview.Handle, HeaderTimer); SetTimer(Treeview.Handle, HeaderTimer, 50, nil); + // todo: under lcl, the hint is show even if HintMouseMessage is not implemented + // Is it necessary here? // use Delphi's internal hint handling for header hints too if hoShowHint in FOptions then begin // client coordinates! XPos := P.x; - YPos := P.y + Integer(FHeight); + YPos := P.y; Application.HintMouseMessage(Treeview, Message); end; end;