From c383d6074c144a0b8597fabe6a83ea43990c6715 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Gr=C3=A4=C3=9Flin?= Date: Tue, 17 Feb 2015 15:57:03 +0100 Subject: [PATCH] Replace QX11Info::appScreen() with KWin::Application::x11ScreenNumber() No need to go through QX11Info for information we have. --- composite.cpp | 2 +- xcbutils.h | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/composite.cpp b/composite.cpp index 1ded8e9378..8b9ad0941c 100644 --- a/composite.cpp +++ b/composite.cpp @@ -178,7 +178,7 @@ extern bool is_multihead; void Compositor::slotCompositingOptionsInitialized() { char selection_name[ 100 ]; - sprintf(selection_name, "_NET_WM_CM_S%d", QX11Info::appScreen()); + sprintf(selection_name, "_NET_WM_CM_S%d", Application::x11ScreenNumber()); if (!cm_selection) { cm_selection = new CompositorSelectionOwner(selection_name); connect(cm_selection, SIGNAL(lostOwnership()), SLOT(finish())); diff --git a/xcbutils.h b/xcbutils.h index dae3b97e46..51c8f4a1ce 100644 --- a/xcbutils.h +++ b/xcbutils.h @@ -21,6 +21,7 @@ along with this program. If not, see . #define KWIN_XCB_UTILS_H #include +#include "main.h" #include #include @@ -1713,7 +1714,7 @@ static inline int defaultDepth() if (depth != 0) { return depth; } - int screen = QX11Info::appScreen(); + int screen = Application::x11ScreenNumber(); for (xcb_screen_iterator_t it = xcb_setup_roots_iterator(xcb_get_setup(connection())); it.rem; --screen, xcb_screen_next(&it)) {