Commit e09ca742 authored by Vlad Zahorodnii's avatar Vlad Zahorodnii
Browse files

wayland: Make workspace responsible for creating Screens

The Screens object is created by Workspace on X11. This change makes X11
and Wayland behave more similar. As is, the Screens is a helper for
window management code, don't use it in backends. Note that the X11 backend
already uses the Screens, it needs to be addressed individually.
parent 137cd9c0
Pipeline #204653 failed with stage
in 26 minutes and 14 seconds
......@@ -153,7 +153,6 @@ void WaylandTestApplication::performStartup()
void WaylandTestApplication::continueStartupWithScreens()
{
disconnect(kwinApp()->platform(), &Platform::screensQueried, this, &WaylandTestApplication::continueStartupWithScreens);
createScreens();
WaylandCompositor::create();
connect(Compositor::self(), &Compositor::sceneCreated, this, &WaylandTestApplication::continueStartupWithScene);
}
......
......@@ -12,15 +12,14 @@
#include <config-kwin.h>
#include "atoms.h"
#include "platform.h"
#include "colormanager.h"
#include "composite.h"
#include "cursor.h"
#include "input.h"
#include "inputmethod.h"
#include "options.h"
#include "platform.h"
#include "pluginmanager.h"
#include "screens.h"
#if KWIN_BUILD_SCREENLOCKER
#include "screenlockerwatcher.h"
#endif
......@@ -280,15 +279,6 @@ void Application::createInput()
m_platform->createPlatformCursor(this);
}
void Application::createScreens()
{
if (Screens::self()) {
return;
}
Screens::create(this);
Q_EMIT screensCreated();
}
void Application::createAtoms()
{
atoms = new Atoms;
......
......@@ -138,7 +138,6 @@ public:
}
}
void updateX11Time(xcb_generic_event_t *event);
void createScreens();
static void setCrashCount(int count);
static bool wasCrash();
......@@ -238,7 +237,6 @@ Q_SIGNALS:
void x11ConnectionAboutToBeDestroyed();
void xwaylandScaleChanged();
void workspaceCreated();
void screensCreated();
void platformCreated();
void virtualTerminalCreated();
void started();
......
......@@ -149,7 +149,6 @@ void ApplicationWayland::performStartup()
TabletModeManager::create(this);
createPlugins();
createScreens();
WaylandCompositor::create();
connect(Compositor::self(), &Compositor::sceneCreated, platform(), &Platform::sceneInitialized);
......
......@@ -157,7 +157,7 @@ Workspace::Workspace()
RuleBook::create(this)->load();
kwinApp()->createScreens();
Screens::create(this);
ScreenEdges::create(this);
// VirtualDesktopManager needs to be created prior to init shortcuts
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment