74 |
|
FOnEventAlert: TEventAlert; |
75 |
|
FRegistered: boolean; |
76 |
|
FDeferredRegister: boolean; |
77 |
+ |
FStartEvent: boolean; |
78 |
|
procedure EventHandler(Sender: IEvents); |
79 |
|
procedure ProcessEvents; |
80 |
|
procedure EventChange(sender: TObject); |
124 |
|
FBase.BeforeDatabaseDisconnect := @DoBeforeDatabaseDisconnect; |
125 |
|
FBase.AfterDatabaseConnect := @DoAfterDatabaseConnect; |
126 |
|
FEvents := TStringList.Create; |
127 |
+ |
FStartEvent := true; |
128 |
|
with TStringList( FEvents) do |
129 |
|
begin |
130 |
|
OnChange := @EventChange; |
152 |
|
i: integer; |
153 |
|
begin |
154 |
|
if (csDestroying in ComponentState) or (FEventIntf = nil) then Exit; |
155 |
+ |
CancelAlerts := false; |
156 |
|
EventCounts := FEventIntf.ExtractEventCounts; |
157 |
+ |
if FStartEvent then |
158 |
+ |
FStartEvent := false {ignore the first one} |
159 |
+ |
else |
160 |
|
if assigned(FOnEventAlert) then |
161 |
|
begin |
162 |
|
CancelAlerts := false; |