Ignore:
Timestamp:
May 16, 2019, 11:35:07 PM (6 years ago)
Author:
chronos
Message:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/generator/Packages/Common/UScaleDPI.pas

    r167 r189  
    289289  //OldAutoSize: Boolean;
    290290begin
     291  //if not (Control is TCustomPage) then
     292  // Resize childs first
     293  if Control is TWinControl then begin
     294    WinControl := TWinControl(Control);
     295    if WinControl.ControlCount > 0 then begin
     296      for I := 0 to WinControl.ControlCount - 1 do begin
     297        if WinControl.Controls[I] is TControl then begin
     298          ScaleControl(WinControl.Controls[I], FromDPI);
     299        end;
     300      end;
     301    end;
     302  end;
     303
    291304  //if Control is TMemo then Exit;
    292305  //if Control is TForm then
     
    340353  end;
    341354
    342   //if not (Control is TCustomPage) then
    343   if Control is TWinControl then begin
    344     WinControl := TWinControl(Control);
    345     if WinControl.ControlCount > 0 then begin
    346       for I := 0 to WinControl.ControlCount - 1 do begin
    347         if WinControl.Controls[I] is TControl then begin
    348           ScaleControl(WinControl.Controls[I], FromDPI);
    349         end;
    350       end;
    351     end;
    352   end;
    353355  //if Control is TForm then
    354356  //  Control.EnableAutoSizing;
Note: See TracChangeset for help on using the changeset viewer.