SpkToolbar: cosmetic

git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@7970 8e941d3f-bd1b-0410-a28a-d453659cc2b4
This commit is contained in:
wp_xxyyzz
2021-02-15 15:36:59 +00:00
parent 4e0089b2f2
commit 3f28cb5ded

View File

@ -2570,21 +2570,21 @@ procedure TSpkToolbar.MenuButtonMouseUp(Button: TMouseButton; Shift: TShiftState
var
aPopupPoint: TPoint;
begin
//During rebuilding procees the mouse is ignored
//During rebuilding procees the mouse is ignored
if FInternalUpdating or FUpdating then
exit;
// Change Menu Button state and repaint
FMenuButtonState := mbtHottrack;
SetMetricsInvalid;
Repaint;
// Change Menu Button state and repaint
FMenuButtonState := mbtHottrack;
SetMetricsInvalid;
Repaint;
// Dropdown the Menu button dropdown menu or fire the event for click
if Assigned(FMenuButtonDropdownMenu) and (FShowMenuButton) then
begin
aPopupPoint := ClientToScreen(GetMenuButtonDropdownPoint);
TPopupMenu(FMenuButtonDropdownMenu).PopUp(aPopupPoint.X, aPopupPoint.Y);
end else
begin
aPopupPoint := ClientToScreen(GetMenuButtonDropdownPoint);
TPopupMenu(FMenuButtonDropdownMenu).PopUp(aPopupPoint.X, aPopupPoint.Y);
end else
DoMenuButtonClick;
end;