chiark / gitweb /
Prep v239: Add support for the new 'suspend-then-hibernate' method.
[elogind.git] / src / login / logind-dbus.c
index 31acd57dc62641ae8ec123c3cd2c3ef1cc8f9d6d..2f7782a13e85f00accc2b88655c183d57102c724 100644 (file)
@@ -1979,6 +1979,9 @@ static int method_hybrid_sleep(sd_bus_message *message, void *userdata, sd_bus_e
                         m, message,
 #if 0 /// elogind uses HandleAction instead of const char* unti names
                         SPECIAL_HYBRID_SLEEP_TARGET,
+#else
+                        HANDLE_HYBRID_SLEEP,
+#endif // 0
                         INHIBIT_SLEEP,
                         "org.freedesktop.login1.hibernate",
                         "org.freedesktop.login1.hibernate-multiple-sessions",
@@ -1992,9 +1995,10 @@ static int method_suspend_then_hibernate(sd_bus_message *message, void *userdata
 
         return method_do_shutdown_or_sleep(
                         m, message,
+#if 0 /// elogind uses HandleAction instead of const char* unti names
                         SPECIAL_SUSPEND_THEN_HIBERNATE_TARGET,
 #else
-                        HANDLE_HYBRID_SLEEP,
+                        HANDLE_SUSPEND_THEN_HIBERNATE,
 #endif // 0
                         INHIBIT_SLEEP,
                         "org.freedesktop.login1.hibernate",