diff --git a/src/editor/f_main.pas b/src/editor/f_main.pas
index 8fd1fa3372b6a4e87fe52580603a0f3a82def031..2216151be62ac733692ba26562c2dfebd06c9a35 100644 (file)
--- a/src/editor/f_main.pas
+++ b/src/editor/f_main.pas
begin
RemoveSelectFromObjects();
ClearMap();
+ LoadSky(gMapInfo.SkyName);
UndoBuffer := nil;
slInvalidTextures.Clear();
MapCheckForm.lbErrorList.Clear();
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);
PreviewMode := not PreviewMode;
(Sender as TMenuItem).Checked := PreviewMode;
+
+ FormResize(Self);
end;
procedure TMainForm.miLayer1Click(Sender: TObject);
cmd, mapWAD, mapToRun: String;
opt: LongWord;
time: Integer;
- lpMsgBuf: PChar;
begin
// Сохраняем временную карту:
time := 0;