diff options
Diffstat (limited to 'vcl/unx/generic/window/screensaverinhibitor.cxx')
-rw-r--r-- | vcl/unx/generic/window/screensaverinhibitor.cxx | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/vcl/unx/generic/window/screensaverinhibitor.cxx b/vcl/unx/generic/window/screensaverinhibitor.cxx index ca4cecc160b6..3c2032334872 100644 --- a/vcl/unx/generic/window/screensaverinhibitor.cxx +++ b/vcl/unx/generic/window/screensaverinhibitor.cxx @@ -15,7 +15,9 @@ #include <X11/Xlib.h> #include <postx.h> -#ifdef ENABLE_DBUS +#include <config_dbus.h> + +#if ENABLE_DBUS #include <dbus/dbus-glib.h> #define FDO_DBUS_SERVICE "org.freedesktop.ScreenSaver" @@ -64,7 +66,7 @@ void ScreenSaverInhibitor::inhibit( bool bInhibit, const OUString& sReason, } } -#ifdef ENABLE_DBUS +#if ENABLE_DBUS void dbusInhibit( bool bInhibit, const gchar* service, const gchar* path, const gchar* interface, std::function<bool( DBusGProxy*, guint&, GError*& )> fInhibit, @@ -135,7 +137,7 @@ void dbusInhibit( bool bInhibit, void ScreenSaverInhibitor::inhibitFDO( bool bInhibit, const char* appname, const char* reason ) { -#ifdef ENABLE_DBUS +#if ENABLE_DBUS dbusInhibit( bInhibit, FDO_DBUS_SERVICE, FDO_DBUS_PATH, FDO_DBUS_INTERFACE, [appname, reason] ( DBusGProxy *proxy, guint& nCookie, GError*& error ) -> bool { @@ -165,7 +167,7 @@ void ScreenSaverInhibitor::inhibitFDO( bool bInhibit, const char* appname, const void ScreenSaverInhibitor::inhibitFDOPM( bool bInhibit, const char* appname, const char* reason ) { -#ifdef ENABLE_DBUS +#if ENABLE_DBUS dbusInhibit( bInhibit, FDOPM_DBUS_SERVICE, FDOPM_DBUS_PATH, FDOPM_DBUS_INTERFACE, [appname, reason] ( DBusGProxy *proxy, guint& nCookie, GError*& error ) -> bool { @@ -195,7 +197,7 @@ void ScreenSaverInhibitor::inhibitFDOPM( bool bInhibit, const char* appname, con void ScreenSaverInhibitor::inhibitGSM( bool bInhibit, const char* appname, const char* reason, const unsigned int xid ) { -#ifdef ENABLE_DBUS +#if ENABLE_DBUS dbusInhibit( bInhibit, GSM_DBUS_SERVICE, GSM_DBUS_PATH, GSM_DBUS_INTERFACE, [appname, reason, xid] ( DBusGProxy *proxy, guint& nCookie, GError*& error ) -> bool { @@ -228,7 +230,7 @@ void ScreenSaverInhibitor::inhibitGSM( bool bInhibit, const char* appname, const void ScreenSaverInhibitor::inhibitMSM( bool bInhibit, const char* appname, const char* reason, const unsigned int xid ) { -#ifdef ENABLE_DBUS +#if ENABLE_DBUS dbusInhibit( bInhibit, MSM_DBUS_SERVICE, MSM_DBUS_PATH, MSM_DBUS_INTERFACE, [appname, reason, xid] ( DBusGProxy *proxy, guint& nCookie, GError*& error ) -> bool { |