Ignore:
Timestamp:
Jan 7, 2024, 11:23:36 PM (4 months ago)
Author:
chronos
Message:
  • Fixed: Avoid repeatedly calling Term form resize and repaint in case of fractional scaling.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Packages/DpiControls/Dpi.Controls.pas

    r482 r523  
    10281028
    10291029procedure TControl.NativeFormResize(Sender: TObject);
    1030 begin
    1031   BoundsRect := ScaleRectFromNative(GetNativeControl.BoundsRect);
     1030var
     1031  R: TRect;
     1032begin
     1033  R := ScaleRectFromNative(GetNativeControl.BoundsRect);
     1034  FLeft := R.Left;
     1035  FTop := R.Top;
     1036  FWidth := R.Width;
     1037  FHeight := R.Height;
    10321038  DoFormResize;
    10331039end;
     
    10701076
    10711077procedure TControl.UpdateBounds;
    1072 var
    1073   R: TRect;
    10741078begin
    10751079  GetNativeControl.BoundsRect := ScaleRectToNative(BoundsRect);
    1076   R := ScaleRectToNative(BoundsRect);
    1077   //WriteLog(Name + ' ' + IntToStr(R.Left) + ', ' + IntToStr(R.Top) + ', ' + IntToStr(R.Width) + ', ' + IntToStr(R.Height))
    10781080end;
    10791081
Note: See TracChangeset for help on using the changeset viewer.