mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-13 12:09:21 +02:00
IDEIntf: OI: fixed position of hint
git-svn-id: trunk@18423 -
This commit is contained in:
parent
b63c3586fb
commit
97c23626c2
@ -2900,6 +2900,7 @@ var
|
|||||||
PointedRow:TOIpropertyGridRow;
|
PointedRow:TOIpropertyGridRow;
|
||||||
Window: TWinControl;
|
Window: TWinControl;
|
||||||
HintType: TPropEditHint;
|
HintType: TPropEditHint;
|
||||||
|
ClientPosition: TPoint;
|
||||||
begin
|
begin
|
||||||
if FHintTimer<>nil then
|
if FHintTimer<>nil then
|
||||||
FHintTimer.Enabled := False;
|
FHintTimer.Enabled := False;
|
||||||
@ -2911,13 +2912,13 @@ begin
|
|||||||
if not(Assigned(Window)) then Exit;
|
if not(Assigned(Window)) then Exit;
|
||||||
If (Window<>Self) and (not IsParentOf(Window)) then exit;
|
If (Window<>Self) and (not IsParentOf(Window)) then exit;
|
||||||
|
|
||||||
Position := ScreenToClient(Position);
|
ClientPosition := ScreenToClient(Position);
|
||||||
if ((Position.X <=0) or (Position.X >= Width) or (Position.Y <= 0)
|
if ((ClientPosition.X <=0) or (ClientPosition.X >= Width)
|
||||||
or (Position.Y >= Height)) then
|
or (ClientPosition.Y <= 0) or (ClientPosition.Y >= Height)) then
|
||||||
Exit;
|
Exit;
|
||||||
|
|
||||||
AHint := '';
|
AHint := '';
|
||||||
Index:=MouseToIndex(Position.Y,false);
|
Index:=MouseToIndex(ClientPosition.Y,false);
|
||||||
if (Index>=0) and (Index<FRows.Count) then
|
if (Index>=0) and (Index<FRows.Count) then
|
||||||
begin
|
begin
|
||||||
//IconX:=GetTreeIconX(Index);
|
//IconX:=GetTreeIconX(Index);
|
||||||
@ -2939,7 +2940,6 @@ begin
|
|||||||
|
|
||||||
if AHint = '' then Exit;
|
if AHint = '' then Exit;
|
||||||
Rect := FHintWindow.CalcHintRect(0,AHint,nil); //no maxwidth
|
Rect := FHintWindow.CalcHintRect(0,AHint,nil); //no maxwidth
|
||||||
Position := Mouse.CursorPos;
|
|
||||||
Rect.Left := Position.X+10;
|
Rect.Left := Position.X+10;
|
||||||
Rect.Top := Position.Y+10;
|
Rect.Top := Position.Y+10;
|
||||||
Rect.Right := Rect.Left + Rect.Right+3;
|
Rect.Right := Rect.Left + Rect.Right+3;
|
||||||
|
Loading…
Reference in New Issue
Block a user