mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-19 16:00:16 +02:00
parent
92e3aa746b
commit
cac42cb9d7
@ -123,6 +123,7 @@ Type
|
|||||||
Procedure AdjustSelectedBandsToContent;
|
Procedure AdjustSelectedBandsToContent;
|
||||||
Procedure ResetModified;
|
Procedure ResetModified;
|
||||||
Procedure SelectElement(E : TFPReportElement);
|
Procedure SelectElement(E : TFPReportElement);
|
||||||
|
Function GetSelection : TReportObjectArray;
|
||||||
// Will call selectionchanged, except when result=odrPage
|
// Will call selectionchanged, except when result=odrPage
|
||||||
Function DeleteSelection : TObjectDeleteResult;
|
Function DeleteSelection : TObjectDeleteResult;
|
||||||
// Various ways to get information
|
// Various ways to get information
|
||||||
@ -703,6 +704,11 @@ begin
|
|||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
function TReportObjectList.GetSelection: TReportObjectArray;
|
||||||
|
begin
|
||||||
|
Result:=GetSelectionArray(ssNone);
|
||||||
|
end;
|
||||||
|
|
||||||
function TReportObjectList.DeleteElement(O: TReportObject): TObjectDeleteResult;
|
function TReportObjectList.DeleteElement(O: TReportObject): TObjectDeleteResult;
|
||||||
|
|
||||||
Var
|
Var
|
||||||
|
@ -974,19 +974,26 @@ begin
|
|||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TFPReportDesignerForm.DoSelectionModifiedByOI(Sender: TObject);
|
procedure TFPReportDesignerForm.DoSelectionModifiedByOI(Sender: TObject);
|
||||||
|
|
||||||
|
Var
|
||||||
|
Sel : TReportObjectArray;
|
||||||
|
|
||||||
begin
|
begin
|
||||||
if Assigned(CurrentDesigner) then
|
if Assigned(CurrentDesigner) then
|
||||||
begin
|
begin
|
||||||
if (FOI.ObjectList.Count=1) and
|
if (FOI.ObjectList.SelectionCount=1) then
|
||||||
(FOI.ObjectList.Elements[0]=CurrentDesigner.Page) then
|
|
||||||
begin
|
begin
|
||||||
CurrentDesigner.UpdatePageParams;
|
Sel:=FOI.ObjectList.GetSelection;
|
||||||
CurrentDesigner.Reset;
|
if (Sel[0].IsPage) and (Sel[0].AsPage=CurrentDesigner.Page) then
|
||||||
CurrentDesigner.Objects.SelectElement(CurrentDesigner.Page);
|
begin
|
||||||
SetPageCaption(PCReport.ActivePage);
|
CurrentDesigner.UpdatePageParams;
|
||||||
end
|
CurrentDesigner.Reset;
|
||||||
else
|
CurrentDesigner.Objects.SelectElement(CurrentDesigner.Page);
|
||||||
CurrentDesigner.Invalidate;
|
SetPageCaption(PCReport.ActivePage);
|
||||||
|
end
|
||||||
|
else
|
||||||
|
CurrentDesigner.Invalidate;
|
||||||
|
end;
|
||||||
end;
|
end;
|
||||||
Modified:=True;
|
Modified:=True;
|
||||||
end;
|
end;
|
||||||
|
Loading…
Reference in New Issue
Block a user