Commit 9a4a5ac0 authored by Juha Manninen's avatar Juha Manninen
Browse files

LCL: Prevent an exception in TPageControl with a disabled tab. Issue #36282, patch from errno.

git-svn-id: trunk@62235 -
parent 4880ec89
......@@ -1135,7 +1135,7 @@ begin
if (FPageIndexOnLastChange >= 0) and (FPageIndexOnLastChange < PageCount) and
(FPageIndexOnLastChange <> FPageIndex) then
begin
if Assigned(CurPage) and HasFocusedControl(Page[FPageIndexOnLastChange]) then
if Assigned(CurPage) and CurPage.enabled and HasFocusedControl(Page[FPageIndexOnLastChange]) then
CurPage.SetFocus;
Page[FPageIndexOnLastChange].Visible := False;
end;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment