X-Git-Url: http://deadsoftware.ru/gitweb?a=blobdiff_plain;f=src%2Feditor%2Ff_main.pas;h=ab72ebed255b1f37ebdc343f7d1b789e295fd384;hb=a26127e6f072c41c76ea5ce4f15fb768286f0ea8;hp=8fd1fa3372b6a4e87fe52580603a0f3a82def031;hpb=6f0e2f411ed57b45f4665c44d89d3c5e6d890a9a;p=d2df-editor.git diff --git a/src/editor/f_main.pas b/src/editor/f_main.pas index 8fd1fa3..ab72ebe 100644 --- a/src/editor/f_main.pas +++ b/src/editor/f_main.pas @@ -1795,6 +1795,7 @@ procedure FullClear(); begin RemoveSelectFromObjects(); ClearMap(); + LoadSky(gMapInfo.SkyName); UndoBuffer := nil; slInvalidTextures.Clear(); MapCheckForm.lbErrorList.Clear(); @@ -4032,10 +4033,13 @@ var begin config := TConfig.CreateFile(EditorDir+'Editor.cfg'); - config.WriteInt('Editor', 'XPos', Left); - config.WriteInt('Editor', 'YPos', Top); - config.WriteInt('Editor', 'Width', Width); - config.WriteInt('Editor', 'Height', Height); + if WindowState <> wsMaximized then + begin + config.WriteInt('Editor', 'XPos', Left); + config.WriteInt('Editor', 'YPos', Top); + config.WriteInt('Editor', 'Width', Width); + config.WriteInt('Editor', 'Height', Height); + end; config.WriteBool('Editor', 'Maximize', WindowState = wsMaximized); config.WriteBool('Editor', 'Minimap', ShowMap); config.WriteInt('Editor', 'PanelProps', PanelProps.ClientWidth); @@ -6107,6 +6111,8 @@ begin PreviewMode := not PreviewMode; (Sender as TMenuItem).Checked := PreviewMode; + + FormResize(Self); end; procedure TMainForm.miLayer1Click(Sender: TObject);