send QEvent::Leave for view when dragging started

--this way the applets in the view will be informed for
mouse exited the view window
pull/8/head
Michail Vourlakos 6 years ago
parent bc94001cc8
commit 057edb87f1

@ -1292,6 +1292,9 @@ void View::restoreGrabItemBehavior()
if (mouseGrabberItem()) {
mouseGrabberItem()->ungrabMouse();
}
setMouseGrabEnabled(true);
setMouseGrabEnabled(false);
}
bool View::isHighestPriorityView() {

@ -528,8 +528,9 @@ void VisibilityManager::applyActivitiesToHiddenWindows(const QStringList &activi
void VisibilityManager::activeWindowDraggingStarted()
{
setContainsMouse(false);
updateHiddenState();
//! Send a fake QEvent::LEAVE to inform applets for mouse leaving the view
QHoverEvent e(QEvent::Leave, QPoint(-5,-5), m_latteView->geometry().center());
QCoreApplication::instance()->sendEvent(m_latteView, &e);
}
void VisibilityManager::dodgeActive()

Loading…
Cancel
Save