Changeset 290 for trunk/UNation.pas


Ignore:
Timestamp:
Mar 25, 2019, 12:51:41 AM (6 years ago)
Author:
chronos
Message:
  • Modified: List and item forms for BuildingKind and Nation converted to generic forms.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/UNation.pas

    r285 r290  
    1414  TNation = class(TItem)
    1515    Color: TColor;
    16     function GetFields: TItemFields; override;
     16    class function GetFields: TItemFields; override;
    1717    procedure GetValue(Index: Integer; out Value); override;
    1818    procedure SetValue(Index: Integer; var Value); override;
    1919    class function GetClassSysName: string; override;
     20    class function GetClassName: string; override;
    2021  end;
    2122
     
    2829resourcestring
    2930  SNation = 'Nation';
     31  SColor = 'Color';
    3032
    3133
     
    3739{ TNation }
    3840
    39 function TNation.GetFields: TItemFields;
     41class function TNation.GetFields: TItemFields;
    4042begin
    4143  Result := inherited;
    42   Result.AddField(2, 'Color', 'Color', dtColor);
     44  Result.AddField(2, 'Color', SColor, dtColor);
    4345end;
    4446
     
    6264end;
    6365
     66class function TNation.GetClassName: string;
     67begin
     68  Result := SNation;
     69end;
     70
    6471{ TNations }
    6572
Note: See TracChangeset for help on using the changeset viewer.