Ignore:
Timestamp:
Sep 7, 2012, 10:31:31 PM (12 years ago)
Author:
chronos
Message:
  • Přidáno: Udržovní inforamce o instalovaných modulech v databázi.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Packages/ModularSystem/UModularSystem.pas

    r92 r93  
    5858  end;
    5959
     60  TModuleEvent = procedure (Sender: TObject; Module: TModule) of object;
     61
    6062  { TModuleManager }
    6163
     
    6365  private
    6466    FAPI: TAPI;
     67    FOnModuleChange: TModuleEvent;
    6568    procedure SetAPI(AValue: TAPI);
    6669  public
     
    8487    destructor Destroy; override;
    8588    property API: TAPI read FAPI write SetAPI;
     89    property OnModuleChange: TModuleEvent read FOnModuleChange write FOnModuleChange;
    8690  end;
    8791
     
    328332  Manager.InstallDependencies(Identification, Dependencies);
    329333  FInstalled := True;
     334  if Assigned(Manager.FOnModuleChange) then
     335    Manager.FOnModuleChange(Manager, Self);
    330336end;
    331337
     
    336342  Manager.UninstallDependencies(Identification);
    337343  FInstalled := False;
     344  if Assigned(Manager.FOnModuleChange) then
     345    Manager.FOnModuleChange(Manager, Self);
    338346end;
    339347
     
    370378begin
    371379  FInstalled := Value;
     380  if Assigned(Manager.FOnModuleChange) then
     381    Manager.FOnModuleChange(Manager, Self);
    372382end;
    373383
Note: See TracChangeset for help on using the changeset viewer.