Ignore:
Timestamp:
May 7, 2020, 8:39:24 PM (5 years ago)
Author:
chronos
Message:
  • Fixed: Locale configuration in configuration was not working as expected. ModalResult of Ok and Cancel buttons was opposite. Selected locale was not applied during application startup.
  • Fixed: Updating fullscreen mode after changeing mode in configuration window.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Packages/CevoComponents/ScreenTools.pas

    r192 r194  
    199199  Gamma: Integer; // global gamma correction (cent)
    200200
     201procedure LoadAssets;
    201202procedure UnitInit;
    202203procedure UnitDone;
     
    14861487  P: integer;
    14871488begin
    1488   for Section := Low(TFontType) to High(TFontType) do
    1489     UniFont[Section] := TFont.Create;
    1490 
    14911489  Section := ftNormal;
    14921490  AssignFile(FontScript, LocalizedFilePath('Fonts.txt'));
    14931491  try
    1494     Reset(fontscript);
    1495     while not EOF(FontScript) do begin
     1492    Reset(FontScript);
     1493    while not Eof(FontScript) do begin
    14961494      ReadLn(FontScript, s);
    14971495      if s <> '' then
     
    15491547end;
    15501548
     1549procedure LoadAssets;
     1550begin
     1551  LoadPhrases;
     1552  LoadFonts;
     1553  LoadGraphicFile(Templates, GetGraphicsDir + DirectorySeparator +
     1554    'Templates.png', gfNoGamma);
     1555  LoadGraphicFile(Colors, GetGraphicsDir + DirectorySeparator + 'Colors.png');
     1556  LoadGraphicFile(Paper, GetGraphicsDir + DirectorySeparator + 'Paper.jpg');
     1557  LoadGraphicFile(BigImp, GetGraphicsDir + DirectorySeparator + 'Icons.png');
     1558end;
     1559
    15511560procedure UnitInit;
     1561var
     1562  Section: TFontType;
    15521563begin
    15531564  Gamma := 100;
     
    15591570  {$ENDIF}
    15601571
    1561   LoadPhrases;
    1562 
    15631572  LogoBuffer := TBitmap.Create;
    15641573  LogoBuffer.PixelFormat := pf24bit;
    15651574  LogoBuffer.SetSize(wBBook, hBBook);
    15661575
    1567   LoadFonts;
     1576  for Section := Low(TFontType) to High(TFontType) do
     1577    UniFont[Section] := TFont.Create;
    15681578
    15691579  nGrExt := 0;
     
    15721582  Templates := TBitmap.Create;
    15731583  Templates.PixelFormat := pf24bit;
    1574   LoadGraphicFile(Templates, GetGraphicsDir + DirectorySeparator +
    1575     'Templates.png', gfNoGamma);
    15761584  Colors := TBitmap.Create;
    15771585  Colors.PixelFormat := pf24bit;
    1578   LoadGraphicFile(Colors, GetGraphicsDir + DirectorySeparator + 'Colors.png');
    15791586  Paper := TBitmap.Create;
    15801587  Paper.PixelFormat := pf24bit;
    1581   LoadGraphicFile(Paper, GetGraphicsDir + DirectorySeparator + 'Paper.jpg');
    15821588  BigImp := TBitmap.Create;
    15831589  BigImp.PixelFormat := pf24bit;
    1584   LoadGraphicFile(BigImp, GetGraphicsDir + DirectorySeparator + 'Icons.png');
    15851590  MainTexture.Image := TBitmap.Create;
    15861591  MainTextureAge := -2;
     
    15881593  InitOrnamentDone := False;
    15891594  GenerateNames := True;
     1595
     1596  LoadAssets;
    15901597end;
    15911598
Note: See TracChangeset for help on using the changeset viewer.