]> git.sur5r.net Git - i3/i3lock/blobdiff - xcb.c
clang-format-3.5
[i3/i3lock] / xcb.c
diff --git a/xcb.c b/xcb.c
index e3a33b87600e444c27892d63e9a51b5f84f82e99..3e8cd071c455954b1189fed6e4392ce3338f7140 100644 (file)
--- a/xcb.c
+++ b/xcb.c
@@ -10,7 +10,7 @@
 #include <xcb/xcb.h>
 #include <xcb/xcb_image.h>
 #include <xcb/xcb_atom.h>
-#include <xcb/dpms.h>
+#include <xcb/xcb_aux.h>
 #include <stdio.h>
 #include <stdlib.h>
 #include <stdbool.h>
@@ -151,17 +151,10 @@ xcb_window_t open_fullscreen_window(xcb_connection_t *conn, xcb_screen_t *scr, c
     values[0] = XCB_STACK_MODE_ABOVE;
     xcb_configure_window(conn, win, XCB_CONFIG_WINDOW_STACK_MODE, values);
 
-    return win;
-}
+    /* Ensure that the window is created and set up before returning */
+    xcb_aux_sync(conn);
 
-/*
- * Set the dpms level to 'mode'.
- *
- */
-void dpms_set_mode(xcb_connection_t *conn, xcb_dpms_dpms_mode_t mode) {
-    xcb_dpms_enable(conn);
-    xcb_dpms_force_level(conn, mode);
-    xcb_flush(conn);
+    return win;
 }
 
 /*