Ignore:
Timestamp:
Jun 24, 2010, 4:18:03 PM (14 years ago)
Author:
george
Message:
  • Opravy a rozšíření funkčností některých tříd
File:
1 edited

Legend:

Unmodified
Added
Removed
  • PersistentForm/UPersistentForm.pas

    r29 r31  
    3030var
    3131  RestoredLeft, RestoredTop, RestoredWidth, RestoredHeight: Integer;
     32  RestoredWindowState: TWindowState;
    3233begin
    3334  with TRegistryEx.Create do
     
    4849      if Form.Top > (Screen.Height - 50) then
    4950        Form.Top := Screen.Height - 50;
    50       Form.WindowState := TWindowState(ReadIntegerWithDefault('WindowState', Integer(wsNormal)));
    51       if Form.WindowState = wsMaximized then begin
     51      RestoredWindowState := TWindowState(ReadIntegerWithDefault('WindowState', Integer(wsNormal)));
     52      if RestoredWindowState = wsMaximized then begin
    5253        RestoredWidth := ReadIntegerWithDefault('RestoredWidth', Form.RestoredWidth);
    5354        RestoredHeight := ReadIntegerWithDefault ('RestoredHeight', Form.RestoredHeight);
     
    5657        Form.SetRestoredBounds(RestoredLeft, RestoredTop, RestoredWidth, RestoredHeight);
    5758      end;
     59      Form.WindowState := RestoredWindowState;
    5860
    5961      if ReadBoolWithDefault('Visible', False) then Form.Show;
Note: See TracChangeset for help on using the changeset viewer.