From 3f28cb5ded19312b6b9f81f2adeb765c52e64dff Mon Sep 17 00:00:00 2001 From: wp_xxyyzz Date: Mon, 15 Feb 2021 15:36:59 +0000 Subject: [PATCH] SpkToolbar: cosmetic git-svn-id: https://svn.code.sf.net/p/lazarus-ccr/svn@7970 8e941d3f-bd1b-0410-a28a-d453659cc2b4 --- .../spktoolbar/SpkToolbar/SpkToolbar.pas | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/components/spktoolbar/SpkToolbar/SpkToolbar.pas b/components/spktoolbar/SpkToolbar/SpkToolbar.pas index bfb1e1881..bfab4eaef 100644 --- a/components/spktoolbar/SpkToolbar/SpkToolbar.pas +++ b/components/spktoolbar/SpkToolbar/SpkToolbar.pas @@ -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;