TCustomTabControl: rename a method. No functional changes.

This commit is contained in:
Bart 2024-02-25 13:29:39 +01:00
parent 5e54b2f921
commit 148735d8fb
2 changed files with 4 additions and 4 deletions

View File

@ -463,7 +463,7 @@ type
function GetPageCount : integer; virtual; function GetPageCount : integer; virtual;
procedure InsertPage(APage: TCustomPage; Index: Integer); virtual; procedure InsertPage(APage: TCustomPage; Index: Integer); virtual;
procedure RemovePage(Index: Integer); virtual; procedure RemovePage(Index: Integer); virtual;
procedure ActivateFirstControlOnPage(APage: TCustomPage) virtual; procedure MaybeSelectFirstControlOnPage(APage: TCustomPage) virtual;
//Delphi compatible properties //Delphi compatible properties
function CanChange: Boolean; virtual; function CanChange: Boolean; virtual;
property DisplayRect: TRect read GetDisplayRect; property DisplayRect: TRect read GetDisplayRect;

View File

@ -769,7 +769,7 @@ begin
{$ENDIF} {$ENDIF}
end; end;
procedure TCustomTabControl.ActivateFirstControlOnPage(APage: TCustomPage); procedure TCustomTabControl.MaybeSelectFirstControlOnPage(APage: TCustomPage);
var var
ParentForm: TCustomForm; ParentForm: TCustomForm;
C, ActiveControl: TWinControl; C, ActiveControl: TWinControl;
@ -1065,7 +1065,7 @@ begin
ParentForm := GetParentForm(Self); ParentForm := GetParentForm(Self);
if not (Assigned(ParentForm) and Assigned(APage) and APage.Visible and APage.Enabled and (APage.ControlCount > 0)) then if not (Assigned(ParentForm) and Assigned(APage) and APage.Visible and APage.Enabled and (APage.ControlCount > 0)) then
Exit; Exit;
ActivateFirstControlOnPage(APage); MaybeSelectFirstControlOnPage(APage);
DoChange; DoChange;
end; end;
@ -1104,7 +1104,7 @@ begin
FPageIndex := AValue; FPageIndex := AValue;
UpdateAllDesignerFlags; UpdateAllDesignerFlags;
DoSendPageIndex; DoSendPageIndex;
ActivateFirstControlOnPage(GetActivePageComponent); MaybeSelectFirstControlOnPage(GetActivePageComponent);
end; end;
{------------------------------------------------------------------------------ {------------------------------------------------------------------------------