mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-09-11 14:20:02 +02:00
lcl: fix visibility of pagecontrol pages after window recreation (bug #0011334)
git-svn-id: trunk@18185 -
This commit is contained in:
parent
37e866d1ea
commit
2967687379
@ -77,6 +77,7 @@ type
|
||||
function CanTab: boolean; override;
|
||||
function AutoSizeDelayed: boolean; override;
|
||||
function IsControlVisible: Boolean; override;
|
||||
function HandleObjectShouldBeVisible: boolean; override;
|
||||
function VisibleIndex: integer;
|
||||
property PageIndex: Integer read GetPageIndex write SetPageIndex;
|
||||
property TabVisible: Boolean read GetTabVisible write SetTabVisible default True;
|
||||
|
@ -218,11 +218,17 @@ end;
|
||||
function TCustomPage.IsControlVisible: Boolean;
|
||||
begin
|
||||
if Parent is TCustomNotebook then
|
||||
begin
|
||||
Result := (PageIndex = TCustomNotebook(Parent).PageIndex);
|
||||
end else begin
|
||||
Result := (PageIndex = TCustomNotebook(Parent).PageIndex)
|
||||
else
|
||||
Result := inherited IsControlVisible;
|
||||
end;
|
||||
end;
|
||||
|
||||
function TCustomPage.HandleObjectShouldBeVisible: boolean;
|
||||
begin
|
||||
if Parent is TCustomNotebook then
|
||||
Result := (PageIndex = TCustomNotebook(Parent).PageIndex)
|
||||
else
|
||||
Result := inherited HandleObjectShouldBeVisible;
|
||||
end;
|
||||
|
||||
function TCustomPage.VisibleIndex: integer;
|
||||
|
Loading…
Reference in New Issue
Block a user