mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-09 12:35:55 +02:00
merge r51094 #9effa4e621: lcl: win32: ComboBox ItemWidth support. Issue #29149, patch by Simon Ameis/Janusz Tomczak
git-svn-id: branches/fixes_1_6@51095 -
This commit is contained in:
parent
51ce3a5ea1
commit
21578de506
@ -250,7 +250,7 @@ procedure TCustomComboBox.AdjustDropDown;
|
||||
var
|
||||
Count, MinItemsWidth, MinItemsHeight: Integer;
|
||||
begin
|
||||
if (not HandleAllocated) or (not DroppedDown) then exit;
|
||||
if (not HandleAllocated) then exit;
|
||||
Count := Items.Count;
|
||||
if Count > DropDownCount then Count := DropDownCount;
|
||||
if Count < 1 then Count := 1;
|
||||
|
@ -3056,6 +3056,7 @@ function TWin32WidgetSet.SetComboMinDropDownSize(Handle: HWND; MinItemsWidth,
|
||||
begin
|
||||
Result:= ThemeServices.ThemesEnabled and
|
||||
boolean(Windows.SendMessage(Handle, CB_SETMINVISIBLE, MinItemCount, 0));
|
||||
Result := Result and boolean(Windows.SendMessage(Handle, CB_SETDROPPEDWIDTH, MinItemsWidth, 0));
|
||||
end;
|
||||
|
||||
{------------------------------------------------------------------------------
|
||||
|
Loading…
Reference in New Issue
Block a user