Commit 9a4bb220 authored by Kai Uwe Broulik's avatar Kai Uwe Broulik 🍇

[KSplashQML] Register DBus before loading the splash theme

Loading the theme and setting everything up can take a while.
Ensure that we catch all setStage calls that might have been emitted before we were fully up.

CCBUG: 405444

CHANGELOG: Reduced likelihood of KSplash not being dismissed properly and only timing out after 30s

Differential Revision: https://phabricator.kde.org/D19753
parent fb868892
......@@ -65,6 +65,10 @@ SplashApp::SplashApp(int &argc, char ** argv)
m_window = parser.isSet(QStringLiteral("window"));
m_theme = parser.positionalArguments().value(0);
QDBusConnection dbus = QDBusConnection::sessionBus();
dbus.registerObject(QStringLiteral("/KSplash"), this, QDBusConnection::ExportScriptableSlots);
dbus.registerService(QStringLiteral("org.kde.KSplash"));
setupWaylandIntegration();
foreach(QScreen* screen, screens())
......@@ -86,10 +90,6 @@ SplashApp::SplashApp(int &argc, char ** argv)
connect(this, &QGuiApplication::screenAdded, this, &SplashApp::adoptScreen);
QDBusConnection dbus = QDBusConnection::sessionBus();
dbus.registerObject(QStringLiteral("/KSplash"), this, QDBusConnection::ExportScriptableSlots);
dbus.registerService(QStringLiteral("org.kde.KSplash"));
}
SplashApp::~SplashApp()
......
Markdown is supported
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