From c8f0ed87a4651c293c05da79711342c4f757266b Mon Sep 17 00:00:00 2001 From: Peter Fajdiga Date: Fri, 20 Sep 2024 22:27:37 +0200 Subject: [PATCH] MockKwinClient: fix `set fullScreen` --- src/tests/utils/mocks/MockKwinClient.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/tests/utils/mocks/MockKwinClient.ts b/src/tests/utils/mocks/MockKwinClient.ts index 27c767f..58df634 100644 --- a/src/tests/utils/mocks/MockKwinClient.ts +++ b/src/tests/utils/mocks/MockKwinClient.ts @@ -100,6 +100,10 @@ class MockKwinClient { () => { if (oldFullScreen && !fullScreen) { // when switching from full-screen to windowed, Kwin sometimes first adds the frame before changing the frameGeometry to the final value + if (rectEquals(this.frameGeometry, this.windowedFrameGeometry)) { + // already has windowed frame geometry, don't undo that + return; + } runOneOf( () => { this.frameGeometry = new MockQmlRect(