Changeset 94 for trunk/Forms


Ignore:
Timestamp:
Sep 27, 2022, 12:04:27 AM (2 years ago)
Author:
chronos
Message:
  • Fixed: Night and day state in clock.
  • Fixed: Translation of short days of weeks names.
Location:
trunk/Forms
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Forms/UFormMain.lfm

    r87 r94  
    4040  object Translator1: TTranslator
    4141    POFilesFolder = 'Languages'
     42    OnTranslate = Translator1Translate
    4243    Left = 496
    4344    Top = 358
  • trunk/Forms/UFormMain.pas

    r93 r94  
    3838    procedure PaintBox1Resize(Sender: TObject);
    3939    procedure Timer1Timer(Sender: TObject);
     40    procedure Translator1Translate(Sender: TObject);
    4041  private
    4142    Initialized: Boolean;
     
    6263  UFormImages, UPixelPointer;
    6364
     65resourcestring
     66  SMondayShort = 'MON';
     67  STuesdayShort = 'TUE';
     68  SWednesdayShort = 'WED';
     69  SThrusdayShort = 'THU';
     70  SFridayShort = 'FRI';
     71  SSaturdayShort = 'SAT';
     72  SSundayShort = 'SUN';
     73
    6474{ TFormMain }
    6575
     
    177187  if Engine.RedrawPending then
    178188    PaintBox1.Repaint;
     189end;
     190
     191procedure TFormMain.Translator1Translate(Sender: TObject);
     192begin
     193  FormatSettings.ShortDayNames[1] := SSundayShort;
     194  FormatSettings.ShortDayNames[2] := SMondayShort;
     195  FormatSettings.ShortDayNames[3] := STuesdayShort;
     196  FormatSettings.ShortDayNames[4] := SWednesdayShort;
     197  FormatSettings.ShortDayNames[5] := SThrusdayShort;
     198  FormatSettings.ShortDayNames[6] := SFridayShort;
     199  FormatSettings.ShortDayNames[7] := SSaturdayShort;
    179200end;
    180201
Note: See TracChangeset for help on using the changeset viewer.