Changeset 622 for trunk/Back.pas


Ignore:
Timestamp:
Sep 15, 2024, 10:04:45 PM (2 months ago)
Author:
chronos
Message:
  • Modified: Show windows by default on primary screen if multiple monitors present.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Back.pas

    r468 r622  
    1818    procedure FormShow(Sender: TObject);
    1919    procedure FormCreate(Sender: TObject);
    20     procedure FormClose(Sender: TObject; var Action: TCloseAction);
    2120  private
    2221    Img: TBitmap;
     
    5453begin
    5554  if Assigned(Img) then
    56     BitBltCanvas(Canvas, Screen.Width - Img.Width - (Screen.Width - 800) *
    57       3 div 8, (Screen.Height - 600) div 3, Img.Width, Img.Height,
     55    BitBltCanvas(Canvas, Screen.PrimaryMonitor.Width - Img.Width - (Screen.PrimaryMonitor.Width - 800) *
     56      3 div 8, (Screen.PrimaryMonitor.Height - 600) div 3, Img.Width, Img.Height,
    5857      Img.Canvas, 0, 0);
    59 end;
    60 
    61 procedure TBackground.FormClose(Sender: TObject; var Action: TCloseAction);
    62 begin
    6358end;
    6459
     
    6863begin
    6964  if FullScreen then begin
     65    BoundsRect := Screen.PrimaryMonitor.BoundsRect;
    7066    WindowState := TWindowState.wsFullScreen;
    7167    if not Assigned(Img) then begin
Note: See TracChangeset for help on using the changeset viewer.