Commit 2d829690 authored by Martin Flöser's avatar Martin Flöser
Browse files

Use platform detection in SystemSettings

Summary:
SystemSettings needs to run on Wayland in a Wayland session and on X11
in an X11 session.

Test Plan:
unset QT_QPA_PLATFORM and XDG_SESSION_TYPE -> x11 window,
reset XDG_SESSION_TYPE to wayland -> wayland window

Reviewers: #plasma

Subscribers: plasma-devel

Tags: #plasma

Differential Revision: https://phabricator.kde.org/D11445
parent 4f1f9b9f
......@@ -52,6 +52,8 @@ ecm_find_qmlmodule(org.kde.kcm 1.0)
find_package(KF5Kirigami2 2.1 REQUIRED)
find_package(LibKWorkspace ${PROJECT_VERSION} REQUIRED)
add_subdirectory(core)
add_subdirectory(app)
add_subdirectory(categories)
......
......@@ -30,6 +30,7 @@ target_link_libraries( systemsettings5 systemsettingsview
KF5::XmlGui
KF5::DBusAddons
KF5::ConfigGui
PW::KWorkspace
)
install( TARGETS systemsettings5 ${KDE_INSTALL_TARGETS_DEFAULT_ARGS} )
......
......@@ -25,6 +25,8 @@
#include <KAboutData>
#include <KCrash>
#include <kworkspace.h>
#include "SystemSettingsApp.h"
#include "SettingsBase.h"
......@@ -33,6 +35,8 @@ int main( int argc, char *argv[] )
//exec is systemsettings5, but we need the QPT to use the right config from the qApp constructor
//which is before KAboutData::setApplicationData
QCoreApplication::setApplicationName(QStringLiteral("systemsettings"));
KWorkSpace::detectPlatform(argc, argv);
SystemSettingsApp application(argc, argv);
KCrash::initialize();
......
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