mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-05-25 14:23:49 +02:00

separate TCustomCheckBox/TCheckBox constructors to avoid double setting of AutoSize/TabStop in TToggleBox/TRadioButton git-svn-id: trunk@27055 -
41 lines
1.6 KiB
PHP
41 lines
1.6 KiB
PHP
{%MainUnit ../stdctrls.pp}
|
|
|
|
{
|
|
*****************************************************************************
|
|
* *
|
|
* This file is part of the Lazarus Component Library (LCL) *
|
|
* *
|
|
* See the file COPYING.modifiedLGPL.txt, included in this distribution, *
|
|
* for details about the copyright. *
|
|
* *
|
|
* This program is distributed in the hope that it will be useful, *
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. *
|
|
* *
|
|
*****************************************************************************
|
|
}
|
|
{------------------------------------------------------------------------------}
|
|
|
|
class procedure TToggleBox.WSRegisterClass;
|
|
begin
|
|
inherited WSRegisterClass;
|
|
RegisterToggleBox;
|
|
end;
|
|
|
|
procedure TToggleBox.CreateParams(var Params: TCreateParams);
|
|
begin
|
|
inherited CreateParams(Params);
|
|
Params.Style := (Params.Style and not BS_3STATE) or BS_AUTOCHECKBOX or BS_PUSHLIKE;
|
|
end;
|
|
|
|
constructor TToggleBox.Create(TheOwner : TComponent);
|
|
begin
|
|
inherited Create(TheOwner);
|
|
fCompStyle := csToggleBox;
|
|
TabStop := True;
|
|
end;
|
|
|
|
{------------------------------------------------------------------------------}
|
|
|
|
// included by stdctrls.pp
|