Changeset 313 for trunk/Packages/Common/ULanguages.pas
- Timestamp:
- Jan 18, 2022, 10:45:33 PM (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Packages/Common/ULanguages.pas
r308 r313 1 1 unit ULanguages; 2 2 3 {$mode objfpc}{$H+}3 {$mode delphi}{$H+} 4 4 5 5 interface 6 6 7 7 uses 8 Classes, SysUtils, Contnrs;8 Classes, SysUtils, fgl; 9 9 10 10 type … … 15 15 end; 16 16 17 { TLanguage List}18 19 TLanguage List = class(TObjectList)17 { TLanguages } 18 19 TLanguages = class(TFPGObjectList<TLanguage>) 20 20 function SearchByCode(ACode: string): TLanguage; 21 21 procedure AddNew(Code: string; Name: string); 22 constructor Create ;22 constructor Create(FreeObjects: Boolean = True); 23 23 end; 24 24 … … 223 223 224 224 225 { TLanguage List}226 227 function TLanguage List.SearchByCode(ACode: string): TLanguage;225 { TLanguages } 226 227 function TLanguages.SearchByCode(ACode: string): TLanguage; 228 228 var 229 229 I: Integer; … … 235 235 end; 236 236 237 procedure TLanguage List.AddNew(Code: string; Name: string);237 procedure TLanguages.AddNew(Code: string; Name: string); 238 238 var 239 239 NewItem: TLanguage; … … 245 245 end; 246 246 247 constructor TLanguage List.Create;247 constructor TLanguages.Create(FreeObjects: Boolean); 248 248 begin 249 inherited Create;249 inherited; 250 250 AddNew('', SLangAuto); 251 251 AddNew('aa', SLang_aa);
Note:
See TracChangeset
for help on using the changeset viewer.