Changeset 29 for trunk/UAcronym.pas


Ignore:
Timestamp:
Jul 12, 2016, 4:41:03 PM (8 years ago)
Author:
chronos
Message:
  • Added: New import source state called Enabled to allow to select only currently needed imports for importing from all sources.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/UAcronym.pas

    r28 r29  
    163163    procedure DoPassword(Sender: TObject; var RepeatRequest : Boolean);
    164164  public
     165    Enabled: Boolean;
    165166    Name: string;
    166167    URL: string;
     
    618619procedure TImportSource.Assign(Source: TImportSource);
    619620begin
     621  Enabled := Source.Enabled;
    620622  Name := Source.Name;
    621623  URL := Source.URL;
    622624  Format := Source.Format;
     625  LastTime := Source.LastTime;
     626  ItemCount := Source.ItemCount;
    623627end;
    624628
     
    629633  if Assigned(Format) then WriteInteger(Node, 'ImportFormat', Format.Id)
    630634    else WriteInteger(Node, 'ImportFormat', -1);
     635  WriteBoolean(Node, 'Enabled', Enabled);
    631636end;
    632637
     
    636641  URL := ReadString(Node, 'URL', '');
    637642  Format := Sources.AcronymDb.ImportFormats.SearchById(ReadInteger(Node, 'ImportFormat', -1));
     643  Enabled := ReadBoolean(Node, 'Enabled', True);
    638644end;
    639645
     
    641647begin
    642648  Format := nil;
     649  Enabled := True;
    643650end;
    644651
Note: See TracChangeset for help on using the changeset viewer.