aboutsummaryrefslogtreecommitdiff
path: root/backend/x11
diff options
context:
space:
mode:
Diffstat (limited to 'backend/x11')
-rw-r--r--backend/x11/output.c12
1 files changed, 10 insertions, 2 deletions
diff --git a/backend/x11/output.c b/backend/x11/output.c
index 440e26de..15d1d9a0 100644
--- a/backend/x11/output.c
+++ b/backend/x11/output.c
@@ -25,6 +25,11 @@
#include "util/signal.h"
#include "util/time.h"
+static const uint32_t SUPPORTED_OUTPUT_STATE =
+ WLR_OUTPUT_STATE_BACKEND_OPTIONAL |
+ WLR_OUTPUT_STATE_BUFFER |
+ WLR_OUTPUT_STATE_MODE;
+
static void parse_xcb_setup(struct wlr_output *output,
xcb_connection_t *xcb) {
const xcb_setup_t *xcb_setup = xcb_get_setup(xcb);
@@ -94,8 +99,11 @@ static void output_destroy(struct wlr_output *wlr_output) {
}
static bool output_test(struct wlr_output *wlr_output) {
- if (wlr_output->pending.committed & WLR_OUTPUT_STATE_ENABLED) {
- wlr_log(WLR_DEBUG, "Cannot disable an X11 output");
+ uint32_t unsupported =
+ wlr_output->pending.committed & ~SUPPORTED_OUTPUT_STATE;
+ if (unsupported != 0) {
+ wlr_log(WLR_DEBUG, "Unsupported output state fields: 0x%"PRIx32,
+ unsupported);
return false;
}