lcl: allow use of DropDownMenu for TToolButton.Style = tbsButton (delphi compatible)

git-svn-id: trunk@20504 -
This commit is contained in:
paul 2009-06-08 03:42:06 +00:00
parent 5a4bf4a31b
commit e55e302b7e

View File

@ -119,15 +119,11 @@ begin
begin
DropDownMenuDropped := False;
//DebugLn('TToolButton.MouseUp ',Name,':',ClassName,' ',Style=tbsCheck);
if (Style = tbsButton) then
Down := False;
if (Style = tbsDropDown) then
if (Style in [tbsButton, tbsDropDown]) then
begin
if (FToolBar <> nil) and FMouseInControl and
(X > ClientWidth - FToolBar.FDropDownWidth) then
begin
((Style = tbsButton) or (X > ClientWidth - FToolBar.FDropDownWidth)) then
DropDownMenuDropped := CheckMenuDropdown;
end;
Down := False;
end;