1
mirror of https://invent.kde.org/network/falkon.git synced 2024-12-20 02:36:34 +01:00

Clear mouseover state after closing menu in bookmarks toolbar

The button was underMouse() after closing the context menu

Differential Revision: https://phabricator.kde.org/D10894
This commit is contained in:
Anmol Gautam 2018-03-03 14:30:50 +01:00 committed by David Rosca
parent 30b2ba41cd
commit e4c4fd10fc
No known key found for this signature in database
GPG Key ID: EBC3FC294452C6D8

View File

@ -316,7 +316,7 @@ void BookmarksToolbarButton::paintEvent(QPaintEvent* event)
option.features &= ~QStyleOptionButton::HasMenu;
// Draw button base (only under mouse, this is autoraise button)
if (isDown() || underMouse()) {
if (isDown() || hitButton(mapFromGlobal(QCursor::pos()))) {
option.state |= QStyle::State_AutoRaise | QStyle::State_Raised;
style()->drawPrimitive(QStyle::PE_PanelButtonTool, &option, &p, this);
}