on xenial help sign in
Fix power dialogs on desktop

Approved by: Michael Zanetti

commit7ebab8ce184aafc0899d422d305b9e22db54750f authorLukáš Tinkl <lukas.tinkl@canonical.com> dateWed 29 Jul 2015, 12:38 (11 years ago) parent145ea72c281665
2 files changed+12
plugins/Unity/Session/dbusunitysessionservice.cpp+5 plugins/Unity/Session/dbusunitysessionservice.h+7
plugins/Unity/Session/dbusunitysessionservice.cpp+5
@@ -197,6 +197,7 @@ void DBusUnitySessionService::Logout()
197197{
198198 // TODO ask the apps to quit and then emit the signal
199199 Q_EMIT LogoutReady();
200+ Q_EMIT logoutReady();
200201}
201202
202203void DBusUnitySessionService::EndSession()
@@ -275,6 +276,7 @@ QString DBusUnitySessionService::HostName() const
275276void DBusUnitySessionService::PromptLock()
276277{
277278 Q_EMIT LockRequested();
279+ Q_EMIT lockRequested();
278280}
279281
280282void DBusUnitySessionService::Lock()
@@ -303,6 +305,7 @@ bool DBusUnitySessionService::IsLocked() const
303305void DBusUnitySessionService::RequestLogout()
304306{
305307 Q_EMIT LogoutRequested(false);
308+ Q_EMIT logoutRequested(false);
306309}
307310
308311void DBusUnitySessionService::Reboot()
@@ -313,6 +316,7 @@ void DBusUnitySessionService::Reboot()
313316void DBusUnitySessionService::RequestReboot()
314317{
315318 Q_EMIT RebootRequested(false);
319+ Q_EMIT rebootRequested(false);
316320}
317321
318322void DBusUnitySessionService::Shutdown()
@@ -338,6 +342,7 @@ void DBusUnitySessionService::HybridSleep()
338342void DBusUnitySessionService::RequestShutdown()
339343{
340344 Q_EMIT ShutdownRequested(false);
345+ Q_EMIT shutdownRequested(false);
341346}
342347
343348enum class Action : unsigned
plugins/Unity/Session/dbusunitysessionservice.h+7
@@ -46,6 +46,8 @@ public:
4646 Q_INVOKABLE void shutdown() { Shutdown(); }
4747 Q_INVOKABLE void endSession() { EndSession(); }
4848
49+ // TODO: remove duplicate signals and split D-Bus and QML API's
50+ // Apparently QML needs the signals in lowercase, while DBUS spec needs the uppercase version
4951Q_SIGNALS:
5052 /**
5153 * LogoutRequested signal
@@ -56,6 +58,7 @@ Q_SIGNALS:
5658 * which inhibit the logout.
5759 */
5860 Q_SCRIPTABLE void LogoutRequested(bool have_inhibitors);
61+ void logoutRequested(bool have_inhibitors);
5962
6063 /**
6164 * RebootRequested signal
@@ -66,6 +69,7 @@ Q_SIGNALS:
6669 * which inhibit the reboot.
6770 */
6871 Q_SCRIPTABLE void RebootRequested(bool have_inhibitors);
72+ void rebootRequested(bool have_inhibitors);
6973
7074 /**
7175 * ShutdownRequested signal
@@ -76,6 +80,7 @@ Q_SIGNALS:
7680 * which inhibit the shutdown.
7781 */
7882 Q_SCRIPTABLE void ShutdownRequested(bool have_inhibitors);
83+ void shutdownRequested(bool have_inhibitors);
7984
8085 /**
8186 * LogoutReady signal
@@ -84,11 +89,13 @@ Q_SIGNALS:
8489 * is safe to logout.
8590 */
8691 Q_SCRIPTABLE void LogoutReady();
92+ void logoutReady();
8793
8894 /**
8995 * Emitted as a result of calling PromptLock()
9096 */
9197 Q_SCRIPTABLE void LockRequested();
98+ void lockRequested();
9299
93100 /**
94101 * Emitted after the session has been locked.