diff --git a/CMakeLists.txt b/CMakeLists.txt index 57cdee72e2..1846cbe97c 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -290,12 +290,6 @@ find_package(XCB 1.10 REQUIRED COMPONENTS ) set_package_properties(XCB PROPERTIES TYPE REQUIRED) -# and the optional XCB dependencies -if (XCB_ICCCM_VERSION VERSION_LESS "0.4") - set(XCB_ICCCM_FOUND FALSE) -endif() -add_feature_info("XCB-ICCCM" XCB_ICCCM_FOUND "Required for building test applications for KWin") - find_package(X11_XCB) set_package_properties(X11_XCB PROPERTIES PURPOSE "Required for building X11 windowed backend of kwin_wayland" diff --git a/autotests/CMakeLists.txt b/autotests/CMakeLists.txt index 772ab4e20f..940efc7fc4 100644 --- a/autotests/CMakeLists.txt +++ b/autotests/CMakeLists.txt @@ -87,23 +87,21 @@ target_link_libraries(testXcbWrapper add_test(NAME kwin-testXcbWrapper COMMAND testXcbWrapper) ecm_mark_as_test(testXcbWrapper) -if (XCB_ICCCM_FOUND) - add_executable(testXcbSizeHints test_xcb_size_hints.cpp xcb_scaling_mock.cpp) - set_target_properties(testXcbSizeHints PROPERTIES COMPILE_DEFINITIONS "NO_NONE_WINDOW") - target_link_libraries(testXcbSizeHints - Qt::GuiPrivate - Qt::Test - Qt::Widgets - - KF6::ConfigCore - KF6::WindowSystem - - XCB::ICCCM - XCB::XCB - ) - add_test(NAME kwin-testXcbSizeHints COMMAND testXcbSizeHints) - ecm_mark_as_test(testXcbSizeHints) -endif() +add_executable(testXcbSizeHints test_xcb_size_hints.cpp xcb_scaling_mock.cpp) +set_target_properties(testXcbSizeHints PROPERTIES COMPILE_DEFINITIONS "NO_NONE_WINDOW") +target_link_libraries(testXcbSizeHints + Qt::GuiPrivate + Qt::Test + Qt::Widgets + + KF6::ConfigCore + KF6::WindowSystem + + XCB::ICCCM + XCB::XCB +) +add_test(NAME kwin-testXcbSizeHints COMMAND testXcbSizeHints) +ecm_mark_as_test(testXcbSizeHints) ######################################################## # Test XcbWindow diff --git a/autotests/integration/CMakeLists.txt b/autotests/integration/CMakeLists.txt index 2ba2904d2c..5798b38007 100644 --- a/autotests/integration/CMakeLists.txt +++ b/autotests/integration/CMakeLists.txt @@ -103,34 +103,32 @@ integrationTest(NAME testScreenEdges SRCS screenedges_test.cpp) integrationTest(NAME testOutputChanges SRCS outputchanges_test.cpp) integrationTest(NAME testTiles SRCS tiles_test.cpp) integrationTest(NAME testFractionalScaling SRCS fractional_scaling_test.cpp) -if (TARGET K::KPipeWire) - integrationTest(NAME testScreencasting SRCS screencasting_test.cpp LIBS K::KPipeWire) -endif() +integrationTest(NAME testMoveResize SRCS move_resize_window_test.cpp LIBS XCB::ICCCM) +integrationTest(NAME testStruts SRCS struts_test.cpp LIBS XCB::ICCCM) +integrationTest(NAME testShade SRCS shade_test.cpp LIBS XCB::ICCCM) +integrationTest(NAME testDontCrashAuroraeDestroyDeco SRCS dont_crash_aurorae_destroy_deco.cpp LIBS XCB::ICCCM) +integrationTest(NAME testPlasmaWindow SRCS plasmawindow_test.cpp LIBS XCB::ICCCM) +integrationTest(NAME testScreenEdgeClientShow SRCS screenedge_client_show_test.cpp LIBS XCB::ICCCM) +integrationTest(NAME testX11DesktopWindow SRCS desktop_window_x11_test.cpp LIBS XCB::ICCCM) +integrationTest(NAME testXwaylandInput SRCS xwayland_input_test.cpp LIBS XCB::ICCCM) +integrationTest(NAME testWindowRules SRCS window_rules_test.cpp LIBS XCB::ICCCM) +integrationTest(NAME testX11Window SRCS x11_window_test.cpp LIBS XCB::ICCCM) +integrationTest(NAME testQuickTiling SRCS quick_tiling_test.cpp LIBS XCB::ICCCM) +integrationTest(NAME testGlobalShortcuts SRCS globalshortcuts_test.cpp LIBS XCB::ICCCM) +integrationTest(NAME testStackingOrder SRCS stacking_order_test.cpp LIBS XCB::ICCCM) +integrationTest(NAME testDbusInterface SRCS dbus_interface_test.cpp LIBS XCB::ICCCM) +integrationTest(NAME testXwaylandServerCrash SRCS xwaylandserver_crash_test.cpp LIBS XCB::ICCCM) +integrationTest(NAME testXwaylandServerRestart SRCS xwaylandserver_restart_test.cpp LIBS XCB::ICCCM) qt_add_dbus_interfaces(DBUS_SRCS ${CMAKE_BINARY_DIR}/src/org.kde.kwin.VirtualKeyboard.xml) integrationTest(NAME testVirtualKeyboardDBus SRCS test_virtualkeyboard_dbus.cpp ${DBUS_SRCS}) -if (XCB_ICCCM_FOUND) - integrationTest(NAME testMoveResize SRCS move_resize_window_test.cpp LIBS XCB::ICCCM) - integrationTest(NAME testStruts SRCS struts_test.cpp LIBS XCB::ICCCM) - integrationTest(NAME testShade SRCS shade_test.cpp LIBS XCB::ICCCM) - integrationTest(NAME testDontCrashAuroraeDestroyDeco SRCS dont_crash_aurorae_destroy_deco.cpp LIBS XCB::ICCCM) - integrationTest(NAME testPlasmaWindow SRCS plasmawindow_test.cpp LIBS XCB::ICCCM) - integrationTest(NAME testScreenEdgeClientShow SRCS screenedge_client_show_test.cpp LIBS XCB::ICCCM) - integrationTest(NAME testX11DesktopWindow SRCS desktop_window_x11_test.cpp LIBS XCB::ICCCM) - integrationTest(NAME testXwaylandInput SRCS xwayland_input_test.cpp LIBS XCB::ICCCM) - integrationTest(NAME testWindowRules SRCS window_rules_test.cpp LIBS XCB::ICCCM) - integrationTest(NAME testX11Window SRCS x11_window_test.cpp LIBS XCB::ICCCM) - integrationTest(NAME testQuickTiling SRCS quick_tiling_test.cpp LIBS XCB::ICCCM) - integrationTest(NAME testGlobalShortcuts SRCS globalshortcuts_test.cpp LIBS XCB::ICCCM) - integrationTest(NAME testStackingOrder SRCS stacking_order_test.cpp LIBS XCB::ICCCM) - integrationTest(NAME testDbusInterface SRCS dbus_interface_test.cpp LIBS XCB::ICCCM) - integrationTest(NAME testXwaylandServerCrash SRCS xwaylandserver_crash_test.cpp LIBS XCB::ICCCM) - integrationTest(NAME testXwaylandServerRestart SRCS xwaylandserver_restart_test.cpp LIBS XCB::ICCCM) +if (TARGET K::KPipeWire) + integrationTest(NAME testScreencasting SRCS screencasting_test.cpp LIBS K::KPipeWire) +endif() - if (KWIN_BUILD_ACTIVITIES) - integrationTest(NAME testActivities SRCS activities_test.cpp LIBS XCB::ICCCM) - endif() +if (KWIN_BUILD_ACTIVITIES) + integrationTest(NAME testActivities SRCS activities_test.cpp LIBS XCB::ICCCM) endif() add_subdirectory(scripting) diff --git a/autotests/integration/effects/CMakeLists.txt b/autotests/integration/effects/CMakeLists.txt index 33557d59fc..b9560ea102 100644 --- a/autotests/integration/effects/CMakeLists.txt +++ b/autotests/integration/effects/CMakeLists.txt @@ -1,8 +1,6 @@ -if (XCB_ICCCM_FOUND) - integrationTest(NAME testTranslucency SRCS translucency_test.cpp LIBS XCB::ICCCM) - integrationTest(NAME testSlidingPopups SRCS slidingpopups_test.cpp LIBS XCB::ICCCM) - integrationTest(NAME testShadeWobblyWindows SRCS wobbly_shade_test.cpp LIBS XCB::ICCCM) -endif() +integrationTest(NAME testTranslucency SRCS translucency_test.cpp LIBS XCB::ICCCM) +integrationTest(NAME testSlidingPopups SRCS slidingpopups_test.cpp LIBS XCB::ICCCM) +integrationTest(NAME testShadeWobblyWindows SRCS wobbly_shade_test.cpp LIBS XCB::ICCCM) integrationTest(NAME testScriptedEffects SRCS scripted_effects_test.cpp) integrationTest(WAYLAND_ONLY NAME testToplevelOpenCloseAnimation SRCS toplevel_open_close_animation_test.cpp) integrationTest(WAYLAND_ONLY NAME testPopupOpenCloseAnimation SRCS popup_open_close_animation_test.cpp) diff --git a/src/config-kwin.h.cmake b/src/config-kwin.h.cmake index 83e06a639f..54b6d34193 100644 --- a/src/config-kwin.h.cmake +++ b/src/config-kwin.h.cmake @@ -23,13 +23,6 @@ #define BREEZE_KDECORATION_PLUGIN_ID "${BREEZE_KDECORATION_PLUGIN_ID}" #endif -#cmakedefine01 XCB_ICCCM_FOUND -#if !XCB_ICCCM_FOUND -#define XCB_ICCCM_WM_STATE_WITHDRAWN 0 -#define XCB_ICCCM_WM_STATE_NORMAL 1 -#define XCB_ICCCM_WM_STATE_ICONIC 3 -#endif - #cmakedefine01 PipeWire_FOUND #cmakedefine01 HAVE_XWAYLAND_LISTENFD diff --git a/src/events.cpp b/src/events.cpp index c71ad3a950..3b94c75503 100644 --- a/src/events.cpp +++ b/src/events.cpp @@ -47,9 +47,7 @@ #include #include -#if XCB_ICCCM_FOUND #include -#endif #include "composite.h" #include "x11eventfilter.h" diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt index dc6a0ba8fe..832012551f 100644 --- a/tests/CMakeLists.txt +++ b/tests/CMakeLists.txt @@ -1,8 +1,6 @@ -if (XCB_ICCCM_FOUND) - set(normalhintsbasesizetest_SRCS normalhintsbasesizetest.cpp) - add_executable(normalhintsbasesizetest ${normalhintsbasesizetest_SRCS}) - target_link_libraries(normalhintsbasesizetest XCB::XCB XCB::ICCCM KF6::WindowSystem) -endif() +set(normalhintsbasesizetest_SRCS normalhintsbasesizetest.cpp) +add_executable(normalhintsbasesizetest ${normalhintsbasesizetest_SRCS}) +target_link_libraries(normalhintsbasesizetest XCB::XCB XCB::ICCCM KF6::WindowSystem) # next target set(screenedgeshowtest_SRCS screenedgeshowtest.cpp)