Update of /cvsroot/instantobjects/Source/Core
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv15887
Modified Files:
InstantPresentation.pas
Log Message:
Fix for a bug that would cause intermittent AVs when using InstantExposer components. Sometimes when a dataset refresh is done the InstantBookmark section of the current buffer does not contain a valid InstantObject instance.
Index: InstantPresentation.pas
===================================================================
RCS file: /cvsroot/instantobjects/Source/Core/InstantPresentation.pas,v
retrieving revision 1.24
retrieving revision 1.25
diff -C2 -d -r1.24 -r1.25
*** InstantPresentation.pas 24 Nov 2005 22:49:45 -0000 1.24
--- InstantPresentation.pas 9 Dec 2005 23:52:21 -0000 1.25
***************
*** 382,385 ****
--- 382,386 ----
procedure DoAfterInsert; override;
procedure DoBeforeDelete; override;
+ procedure DoBeforeRefresh; override;
function FindContentModifiedObjectBuffer(AObject: TObject): PChar; virtual;
function GetRecInfoUpdateStatus(ARecBuffer: PChar): TUpdateStatus; virtual;
***************
*** 1483,1492 ****
if Active then
begin
- // TODO: This Reset should not be necessary.
- // It is a hack to avoid intermittent AVs.
- // Further investigation is required to find
- // the actual problem. - SM (24 Nov 2005)
- Reset;
-
Refresh;
DoAfterScroll;
--- 1484,1487 ----
***************
*** 2207,2210 ****
--- 2202,2211 ----
end;
+ procedure TInstantCustomExposer.DoBeforeRefresh;
+ begin
+ LoadRecord(RecNo, CurrentBuffer);
+ inherited;
+ end;
+
procedure TInstantCustomExposer.DoBeforeScroll;
begin
|