From 0de811bc2505e4ca067dcb502830ec02fa07b218 Mon Sep 17 00:00:00 2001 From: Hugo Pereira Da Costa Date: Mon, 7 Oct 2019 14:29:30 -0600 Subject: [PATCH] Fix color of dropdown arrow for focused toolbuttons with long-press menus. --- kstyle/breezestyle.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/kstyle/breezestyle.cpp b/kstyle/breezestyle.cpp index 0fe65215..d4bf897f 100644 --- a/kstyle/breezestyle.cpp +++ b/kstyle/breezestyle.cpp @@ -3425,9 +3425,12 @@ namespace Breeze // cast option const QStyleOptionToolButton* toolButtonOption( static_cast( option ) ); - const bool hasPopupMenu( toolButtonOption->subControls & SC_ToolButtonMenu ); + const bool hasMenu( + ( toolButtonOption->subControls & SC_ToolButtonMenu ) || + ( toolButtonOption->features&QStyleOptionToolButton::HasMenu + && toolButtonOption->features&QStyleOptionToolButton::PopupDelay ) ); const bool sunken( state & (State_On | State_Sunken) ); - if( flat && hasPopupMenu ) + if( flat && hasMenu ) { if( sunken && !mouseOver ) color = palette.color( QPalette::HighlightedText );