From 76d53a0ce737cc2123e6a6eb81e35a75dd17da02 Mon Sep 17 00:00:00 2001 From: Aleix Pol Date: Fri, 29 Oct 2021 17:22:53 +0200 Subject: [PATCH] screencast: No need to describe the cursor while it's outside the viewport --- src/plugins/screencast/pipewirestream.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/plugins/screencast/pipewirestream.cpp b/src/plugins/screencast/pipewirestream.cpp index dc73befd1a..b11df8c941 100644 --- a/src/plugins/screencast/pipewirestream.cpp +++ b/src/plugins/screencast/pipewirestream.cpp @@ -585,7 +585,7 @@ QRect PipeWireStream::cursorGeometry(Cursor *cursor) const void PipeWireStream::sendCursorData(Cursor *cursor, spa_meta_cursor *spa_meta_cursor) { - if (!cursor || !spa_meta_cursor) { + if (!cursor || !spa_meta_cursor || !m_cursor.viewport.contains(cursor->pos())) { return; }