From 3d0bdc56a48fe0d5cc0889ab098f6c6c922d20c7 Mon Sep 17 00:00:00 2001 From: Vlad Zahorodnii Date: Mon, 29 Nov 2021 19:06:00 +0200 Subject: [PATCH] Remove mysterious s_cursorUpdateBlocking boolean flag in pointer_input.cpp From what I can tell, it's not really needed. --- src/pointer_input.cpp | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/src/pointer_input.cpp b/src/pointer_input.cpp index b7fbe4f350..1f75e4833d 100644 --- a/src/pointer_input.cpp +++ b/src/pointer_input.cpp @@ -563,8 +563,6 @@ void PointerInputRedirection::cleanupDecoration(Decoration::DecoratedClientImpl m_decorationDestroyedConnection = connect(now, &QObject::destroyed, this, &PointerInputRedirection::update, Qt::QueuedConnection); } -static bool s_cursorUpdateBlocking = false; - void PointerInputRedirection::focusUpdate(Toplevel *focusOld, Toplevel *focusNow) { if (AbstractClient *ac = qobject_cast(focusOld)) { @@ -598,11 +596,6 @@ void PointerInputRedirection::focusUpdate(Toplevel *focusOld, Toplevel *focusNow // TODO: add convenient API to update global pos together with updating focused surface warpXcbOnSurfaceLeft(focusNow->surface()); - // TODO: why? in order to reset the cursor icon? - s_cursorUpdateBlocking = true; - seat->setFocusedPointerSurface(nullptr); - s_cursorUpdateBlocking = false; - seat->notifyPointerMotion(m_pos.toPoint()); seat->setFocusedPointerSurface(focusNow->surface(), focusNow->inputTransformation()); @@ -1080,10 +1073,6 @@ void CursorImage::handlePointerChanged() void CursorImage::handleFocusedSurfaceChanged() { - if (s_cursorUpdateBlocking) { - return; - } - KWaylandServer::PointerInterface *pointer = waylandServer()->seat()->pointer(); disconnect(m_serverCursor.connection);