* Fix the position of the header popup menu

git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@1098 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
blikblum
2009-12-30 11:22:56 +00:00
parent 4656d793e8
commit 2d3c5a3d89

View File

@ -9629,6 +9629,8 @@ begin
if ((Abs(FDragStart.X - P.X) > DragManager.DragThreshold) or
(Abs(FDragStart.Y - P.Y) > DragManager.DragThreshold)) then
begin
Logger.Send([lcDrag], 'HandleHeaderMouseMove - DragIndex: %d - DownIndex: %d',
[FColumns.FDragIndex, FColumns.FDownIndex]);
KillTimer(Treeview.Handle, HeaderTimer);
I := FColumns.FDownIndex;
FColumns.FDownIndex := NoColumn;
@ -9881,7 +9883,8 @@ begin
FColumns.FHoverIndex := NoColumn;
Treeview.DoStateChange([], [tsScrollPending, tsScrolling]);
Menu.PopupComponent := Treeview;
Menu.Popup(XPos, YPos);
P := Treeview.ClientToScreen(Point(XPos, YPos));
Menu.Popup(P.X, P.Y);
HandleMessage := True;
end;
end;