Changeset 156


Ignore:
Timestamp:
Aug 19, 2024, 8:35:07 AM (4 months ago)
Author:
chronos
Message:
  • Modified: Automatically open example file on first start.
Location:
trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Core.pas

    r153 r156  
    267267    if (DesignDPI.X <> DPI.X) or (DesignDPI.Y <> DPI.Y) then begin
    268268      //ApplyToAll(DesignDPI);
    269 {      for I := 0 to Screen.FormCount - 1 do
     269      for I := 0 to Screen.FormCount - 1 do
    270270      if (Screen.Forms[I].WindowState = wsNormal) or
    271271        (Screen.Forms[I].WindowState = wsMinimized) then begin
     
    273273        ScaleDimensions(Screen.Forms[I], StoredDimension);
    274274      end;
    275  }     ScaleImageList(ImageListMain, DesignDPI);
     275      ScaleImageList(ImageListMain, DesignDPI);
    276276    end;
    277277  end;
  • trunk/Forms/FormMain.pas

    r155 r156  
    212212  PageControlMain.TabIndex := 0;
    213213  try
     214    if Core.Core.LastOpenedList.Items.Count = 0 then
     215      Core.Core.LastOpenedList.Items.Add(CombinePaths(Core.Core.DataDir, ExamplesDir + DirectorySeparator + 'Sierpinski.b'));
     216
    214217    if Core.Core.OpenProjectOnStart and (Core.Core.LastOpenedList.Items.Count > 0) and
    215218      FileExists(Core.Core.LastOpenedList.Items[0]) then
     
    744747begin
    745748  if Core.Core.LastOpenedList.Items.Count > 0 then
    746     FileName := Core.Core.LastOpenedList.Items[0]
    747     else FileName := CombinePaths(Core.Core.DataDir, ExamplesDir);
     749    FileName := Core.Core.LastOpenedList.Items[0];
    748750  OpenDialog1.InitialDir := ExtractFileDir(FileName);
    749751  OpenDialog1.FileName := ExtractFileName(FileName);
Note: See TracChangeset for help on using the changeset viewer.