mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-04-09 01:48:03 +02:00
LazReport: Protecting dataset bookmarks on building report is now off by default (it should protect users from hitting sqldb bookmarks bugs see issue #26132 and issue #26146) could be enabled again with a report option.
git-svn-id: trunk@52241 -
This commit is contained in:
parent
05d443d108
commit
0e7a106ef0
@ -90,7 +90,10 @@ type
|
||||
TfrFrameBorders = set of TfrFrameBorder;
|
||||
TfrFrameStyle = (frsSolid,frsDash, frsDot, frsDashDot, frsDashDotDot,frsDouble);
|
||||
TfrPageType = (ptReport, ptDialog); //todo: - remove this
|
||||
TfrReportOption = (roIgnoreFieldNotFound, roIgnoreSymbolNotFound, roHideDefaultFilter, roDontUpgradePreparedReport);
|
||||
TfrReportOption = (roIgnoreFieldNotFound, roIgnoreSymbolNotFound, roHideDefaultFilter,
|
||||
roDontUpgradePreparedReport, // on saving an old prepared report don't update to current version
|
||||
roSaveAndRestoreBookmarks // try to save and later restore dataset bookmarks on building report
|
||||
);
|
||||
TfrReportOptions = set of TfrReportOption;
|
||||
TfrObjectType = (otlReportView, otlUIControl);
|
||||
|
||||
@ -8548,10 +8551,13 @@ begin
|
||||
inc(DetailCount);
|
||||
end;
|
||||
|
||||
if Assigned(MasterReport.OnFormPageBookmarks) then
|
||||
MasterReport.OnFormPageBookmarks(MasterReport, true)
|
||||
else
|
||||
BackupBookmarks;
|
||||
if roSaveAndRestoreBookmarks in MasterReport.Options theN
|
||||
begin
|
||||
if Assigned(MasterReport.OnFormPageBookmarks) then
|
||||
MasterReport.OnFormPageBookmarks(MasterReport, true)
|
||||
else
|
||||
BackupBookmarks;
|
||||
end;
|
||||
|
||||
HasGroups := Bands[btGroupHeader].Objects.Count > 0;
|
||||
{$IFDEF DebugLR}
|
||||
@ -8560,10 +8566,14 @@ begin
|
||||
{$ENDIF}
|
||||
DisableControls;
|
||||
DoLoop(1);
|
||||
if Assigned(MasterReport.OnFormPageBookmarks) then
|
||||
MasterReport.OnFormPageBookmarks(MasterReport, false)
|
||||
else
|
||||
RestoreBookmarks; // this also enablecontrols
|
||||
|
||||
if roSaveAndRestoreBookmarks in MasterReport.Options then
|
||||
begin
|
||||
if Assigned(MasterReport.OnFormPageBookmarks) then
|
||||
MasterReport.OnFormPageBookmarks(MasterReport, false)
|
||||
else
|
||||
RestoreBookmarks; // this also enablecontrols
|
||||
end;
|
||||
EnableControls;
|
||||
|
||||
if Mode = pmNormal then
|
||||
|
Loading…
Reference in New Issue
Block a user