ViewVC Help
View File | Revision Log | Show Annotations | Download File | View Changeset | Root Listing
root/public/ibx/trunk/runtime/IBEvents.pas
(Generate patch)

Comparing ibx/trunk/runtime/IBEvents.pas (file contents):
Revision 45 by tony, Tue Dec 6 10:33:46 2016 UTC vs.
Revision 143 by tony, Fri Feb 23 12:11:21 2018 UTC

# Line 27 | Line 27
27   {    IBX For Lazarus (Firebird Express)                                  }
28   {    Contributor: Tony Whyman, MWA Software http://www.mwasoftware.co.uk }
29   {    Portions created by MWA Software are copyright McCallum Whyman      }
30 < {    Associates Ltd 2011                                                 }
30 > {    Associates Ltd 2011 - 2018                                               }
31   {                                                                        }
32   {************************************************************************}
33  
# Line 74 | Line 74 | type
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);
# Line 123 | Line 124 | begin
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;
# Line 150 | Line 152 | var EventCounts: TEventCounts;
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;

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines