summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon Ser <contact@emersion.fr>2022-01-13 11:15:39 +0100
committerKirill Primak <vyivel@eclair.cafe>2022-01-13 14:01:37 +0300
commitd6f8820a8b7190a2ce76a0f140e1514e2c32dd50 (patch)
treee59e41a785297697c9e8fef7f1a8b1e90efc1699
parentdbaf2e4fdb327f05f792b69430fe6f893fc9d879 (diff)
Upgrade for wlroots surface refactoring
See [1] for details. [1]: https://gitlab.freedesktop.org/wlroots/wlroots/-/merge_requests/3412
-rw-r--r--include/sway/desktop.h2
-rw-r--r--include/sway/input/cursor.h2
-rw-r--r--include/sway/input/text_input.h2
-rw-r--r--include/sway/layers.h2
-rw-r--r--include/sway/surface.h2
-rw-r--r--include/sway/tree/container.h2
-rw-r--r--include/sway/tree/view.h2
-rw-r--r--sway/desktop/layer_shell.c1
-rw-r--r--sway/desktop/output.c2
-rw-r--r--sway/desktop/render.c2
-rw-r--r--sway/desktop/surface.c2
-rw-r--r--sway/server.c3
-rw-r--r--sway/tree/container.c1
-rw-r--r--sway/tree/view.c1
14 files changed, 16 insertions, 10 deletions
diff --git a/include/sway/desktop.h b/include/sway/desktop.h
index c969a76be..7f2f5b3eb 100644
--- a/include/sway/desktop.h
+++ b/include/sway/desktop.h
@@ -1,4 +1,4 @@
-#include <wlr/types/wlr_surface.h>
+#include <wlr/types/wlr_compositor.h>
struct sway_container;
struct sway_view;
diff --git a/include/sway/input/cursor.h b/include/sway/input/cursor.h
index 7d66e6997..853f88386 100644
--- a/include/sway/input/cursor.h
+++ b/include/sway/input/cursor.h
@@ -4,7 +4,7 @@
#include <stdint.h>
#include <wlr/types/wlr_pointer_constraints_v1.h>
#include <wlr/types/wlr_pointer_gestures_v1.h>
-#include <wlr/types/wlr_surface.h>
+#include <wlr/types/wlr_compositor.h>
#include "sway/input/seat.h"
#include "config.h"
diff --git a/include/sway/input/text_input.h b/include/sway/input/text_input.h
index 37744266d..c70fd935b 100644
--- a/include/sway/input/text_input.h
+++ b/include/sway/input/text_input.h
@@ -3,7 +3,7 @@
#include <wlr/types/wlr_text_input_v3.h>
#include <wlr/types/wlr_input_method_v2.h>
-#include <wlr/types/wlr_surface.h>
+#include <wlr/types/wlr_compositor.h>
#include "sway/input/seat.h"
/**
diff --git a/include/sway/layers.h b/include/sway/layers.h
index 148168613..f85084934 100644
--- a/include/sway/layers.h
+++ b/include/sway/layers.h
@@ -1,7 +1,7 @@
#ifndef _SWAY_LAYERS_H
#define _SWAY_LAYERS_H
#include <stdbool.h>
-#include <wlr/types/wlr_surface.h>
+#include <wlr/types/wlr_compositor.h>
#include <wlr/types/wlr_layer_shell_v1.h>
enum layer_parent {
diff --git a/include/sway/surface.h b/include/sway/surface.h
index 4da96c027..fb1cd7758 100644
--- a/include/sway/surface.h
+++ b/include/sway/surface.h
@@ -1,6 +1,6 @@
#ifndef _SWAY_SURFACE_H
#define _SWAY_SURFACE_H
-#include <wlr/types/wlr_surface.h>
+#include <wlr/types/wlr_compositor.h>
struct sway_surface {
struct wlr_surface *wlr_surface;
diff --git a/include/sway/tree/container.h b/include/sway/tree/container.h
index 057611508..a5f74de94 100644
--- a/include/sway/tree/container.h
+++ b/include/sway/tree/container.h
@@ -2,7 +2,7 @@
#define _SWAY_CONTAINER_H
#include <stdint.h>
#include <sys/types.h>
-#include <wlr/types/wlr_surface.h>
+#include <wlr/types/wlr_compositor.h>
#include "list.h"
#include "sway/tree/node.h"
diff --git a/include/sway/tree/view.h b/include/sway/tree/view.h
index 008361f7b..789a67c06 100644
--- a/include/sway/tree/view.h
+++ b/include/sway/tree/view.h
@@ -1,7 +1,7 @@
#ifndef _SWAY_VIEW_H
#define _SWAY_VIEW_H
#include <wayland-server-core.h>
-#include <wlr/types/wlr_surface.h>
+#include <wlr/types/wlr_compositor.h>
#include "config.h"
#if HAVE_XWAYLAND
#include <wlr/xwayland.h>
diff --git a/sway/desktop/layer_shell.c b/sway/desktop/layer_shell.c
index 27e457f13..1250415e5 100644
--- a/sway/desktop/layer_shell.c
+++ b/sway/desktop/layer_shell.c
@@ -5,6 +5,7 @@
#include <wlr/types/wlr_layer_shell_v1.h>
#include <wlr/types/wlr_output_damage.h>
#include <wlr/types/wlr_output.h>
+#include <wlr/types/wlr_subcompositor.h>
#include "log.h"
#include "sway/desktop/transaction.h"
#include "sway/input/cursor.h"
diff --git a/sway/desktop/output.c b/sway/desktop/output.c
index 68f095c04..852671d2e 100644
--- a/sway/desktop/output.c
+++ b/sway/desktop/output.c
@@ -14,7 +14,7 @@
#include <wlr/types/wlr_output_layout.h>
#include <wlr/types/wlr_output.h>
#include <wlr/types/wlr_presentation_time.h>
-#include <wlr/types/wlr_surface.h>
+#include <wlr/types/wlr_compositor.h>
#include <wlr/util/region.h>
#include "config.h"
#include "log.h"
diff --git a/sway/desktop/render.c b/sway/desktop/render.c
index c088c936d..02397c051 100644
--- a/sway/desktop/render.c
+++ b/sway/desktop/render.c
@@ -12,7 +12,7 @@
#include <wlr/types/wlr_output_damage.h>
#include <wlr/types/wlr_output_layout.h>
#include <wlr/types/wlr_output.h>
-#include <wlr/types/wlr_surface.h>
+#include <wlr/types/wlr_compositor.h>
#include <wlr/util/region.h>
#include "log.h"
#include "config.h"
diff --git a/sway/desktop/surface.c b/sway/desktop/surface.c
index 767b20454..1d7b536da 100644
--- a/sway/desktop/surface.c
+++ b/sway/desktop/surface.c
@@ -1,7 +1,7 @@
#define _POSIX_C_SOURCE 200112L
#include <stdlib.h>
#include <time.h>
-#include <wlr/types/wlr_surface.h>
+#include <wlr/types/wlr_compositor.h>
#include "sway/server.h"
#include "sway/surface.h"
diff --git a/sway/server.c b/sway/server.c
index f50a0987d..567e6ae48 100644
--- a/sway/server.c
+++ b/sway/server.c
@@ -24,6 +24,7 @@
#include <wlr/types/wlr_relative_pointer_v1.h>
#include <wlr/types/wlr_screencopy_v1.h>
#include <wlr/types/wlr_server_decoration.h>
+#include <wlr/types/wlr_subcompositor.h>
#include <wlr/types/wlr_tablet_v2.h>
#include <wlr/types/wlr_viewporter.h>
#include <wlr/types/wlr_xcursor_manager.h>
@@ -101,6 +102,8 @@ bool server_init(struct sway_server *server) {
wl_signal_add(&server->compositor->events.new_surface,
&server->compositor_new_surface);
+ wlr_subcompositor_create(server->wl_display);
+
server->data_device_manager =
wlr_data_device_manager_create(server->wl_display);
diff --git a/sway/tree/container.c b/sway/tree/container.c
index 79e04ec01..4756028c7 100644
--- a/sway/tree/container.c
+++ b/sway/tree/container.c
@@ -9,6 +9,7 @@
#include <wayland-server-core.h>
#include <wlr/types/wlr_linux_dmabuf_v1.h>
#include <wlr/types/wlr_output_layout.h>
+#include <wlr/types/wlr_subcompositor.h>
#include <wlr/render/drm_format_set.h>
#include "linux-dmabuf-unstable-v1-protocol.h"
#include "cairo_util.h"
diff --git a/sway/tree/view.c b/sway/tree/view.c
index 1318f5fb3..7d9e038d2 100644
--- a/sway/tree/view.c
+++ b/sway/tree/view.c
@@ -6,6 +6,7 @@
#include <wlr/types/wlr_buffer.h>
#include <wlr/types/wlr_output_layout.h>
#include <wlr/types/wlr_server_decoration.h>
+#include <wlr/types/wlr_subcompositor.h>
#include <wlr/types/wlr_xdg_decoration_v1.h>
#include "config.h"
#if HAVE_XWAYLAND