mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-17 15:59:13 +02:00
LCL: listbox: fix default value for Options
git-svn-id: trunk@55126 -
This commit is contained in:
parent
9311861669
commit
48dbf5c56d
@ -128,11 +128,6 @@ begin
|
|||||||
UnlockSelectionChange;
|
UnlockSelectionChange;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function TCustomListBox.IsOptionsStored: Boolean;
|
|
||||||
begin
|
|
||||||
Result := (FOptions = [lboDrawFocusRect]);
|
|
||||||
end;
|
|
||||||
|
|
||||||
{------------------------------------------------------------------------------
|
{------------------------------------------------------------------------------
|
||||||
procedure TCustomListBox.FinalizeWnd
|
procedure TCustomListBox.FinalizeWnd
|
||||||
------------------------------------------------------------------------------}
|
------------------------------------------------------------------------------}
|
||||||
@ -562,7 +557,7 @@ begin
|
|||||||
FItemIndex:=-1;
|
FItemIndex:=-1;
|
||||||
FExtendedSelect := true;
|
FExtendedSelect := true;
|
||||||
//FScrollWidth := 0;
|
//FScrollWidth := 0;
|
||||||
FOptions := [lboDrawFocusRect];
|
FOptions := DefOptions;
|
||||||
FCanvas := TControlCanvas.Create;
|
FCanvas := TControlCanvas.Create;
|
||||||
TControlCanvas(FCanvas).Control := Self;
|
TControlCanvas(FCanvas).Control := Self;
|
||||||
ParentColor := false;
|
ParentColor := false;
|
||||||
|
@ -495,6 +495,8 @@ type
|
|||||||
{ TCustomListBox }
|
{ TCustomListBox }
|
||||||
|
|
||||||
TCustomListBox = class(TWinControl)
|
TCustomListBox = class(TWinControl)
|
||||||
|
private const
|
||||||
|
DefOptions = [lboDrawFocusRect];
|
||||||
private
|
private
|
||||||
FCacheValid: Boolean;
|
FCacheValid: Boolean;
|
||||||
FCanvas: TCanvas;
|
FCanvas: TCanvas;
|
||||||
@ -519,7 +521,6 @@ type
|
|||||||
function GetCount: Integer;
|
function GetCount: Integer;
|
||||||
function GetScrollWidth: Integer;
|
function GetScrollWidth: Integer;
|
||||||
function GetTopIndex: Integer;
|
function GetTopIndex: Integer;
|
||||||
function IsOptionsStored: Boolean;
|
|
||||||
procedure RaiseIndexOutOfBounds(AIndex: integer);
|
procedure RaiseIndexOutOfBounds(AIndex: integer);
|
||||||
procedure SetColumns(const AValue: Integer);
|
procedure SetColumns(const AValue: Integer);
|
||||||
procedure SetScrollWidth(const AValue: Integer);
|
procedure SetScrollWidth(const AValue: Integer);
|
||||||
@ -622,7 +623,7 @@ type
|
|||||||
property OnSelectionChange: TSelectionChangeEvent read FOnSelectionChange
|
property OnSelectionChange: TSelectionChangeEvent read FOnSelectionChange
|
||||||
write FOnSelectionChange;
|
write FOnSelectionChange;
|
||||||
property OnUTF8KeyPress;
|
property OnUTF8KeyPress;
|
||||||
property Options: TListBoxOptions read FOptions write FOptions stored IsOptionsStored;
|
property Options: TListBoxOptions read FOptions write FOptions default DefOptions;
|
||||||
property ParentColor default False;
|
property ParentColor default False;
|
||||||
property ParentFont;
|
property ParentFont;
|
||||||
property ParentShowHint;
|
property ParentShowHint;
|
||||||
|
Loading…
Reference in New Issue
Block a user