aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon Ser <contact@emersion.fr>2023-01-31 15:57:36 +0100
committerSimon Ser <contact@emersion.fr>2023-01-31 16:20:33 +0100
commitdf0c926a7a5838bb1daab4ac884d7243b2ecb8ae (patch)
tree52c09d6ad7808e27eab8423799c3988a828a8bb0
parente1a1dc4be5eba4faa7c81ef9039278a4ae5ba6a9 (diff)
xdg-shell: rename wlr_xdg_toplevel.added to sent_initial_configure
This is more descriptive, and avoids the confusion with wlr_xdg_surface.added.
-rw-r--r--include/wlr/types/wlr_xdg_shell.h2
-rw-r--r--types/xdg_shell/wlr_xdg_toplevel.c6
2 files changed, 4 insertions, 4 deletions
diff --git a/include/wlr/types/wlr_xdg_shell.h b/include/wlr/types/wlr_xdg_shell.h
index f2aae252..03d7c92b 100644
--- a/include/wlr/types/wlr_xdg_shell.h
+++ b/include/wlr/types/wlr_xdg_shell.h
@@ -172,7 +172,7 @@ struct wlr_xdg_toplevel_requested {
struct wlr_xdg_toplevel {
struct wl_resource *resource;
struct wlr_xdg_surface *base;
- bool added;
+ bool sent_initial_configure;
struct wlr_xdg_toplevel *parent;
struct wl_listener parent_unmap;
diff --git a/types/xdg_shell/wlr_xdg_toplevel.c b/types/xdg_shell/wlr_xdg_toplevel.c
index 26bf15bc..a0405d4d 100644
--- a/types/xdg_shell/wlr_xdg_toplevel.c
+++ b/types/xdg_shell/wlr_xdg_toplevel.c
@@ -132,11 +132,11 @@ void handle_xdg_toplevel_committed(struct wlr_xdg_toplevel *toplevel) {
toplevel->current = toplevel->pending;
- if (!toplevel->added) {
+ if (!toplevel->sent_initial_configure) {
// on the first commit, send a configure request to tell the client it
// is added
wlr_xdg_surface_schedule_configure(toplevel->base);
- toplevel->added = true;
+ toplevel->sent_initial_configure = true;
if (toplevel->base->client->shell->version >=
XDG_TOPLEVEL_WM_CAPABILITIES_SINCE_VERSION) {
@@ -535,7 +535,7 @@ void unmap_xdg_toplevel(struct wlr_xdg_toplevel *toplevel) {
toplevel->requested.maximized = false;
toplevel->requested.minimized = false;
- toplevel->added = false;
+ toplevel->sent_initial_configure = false;
}
void destroy_xdg_toplevel(struct wlr_xdg_toplevel *toplevel) {