commit fffe652646df30e6cf8b7053de4a95e60344b22f
parent a950bc6999605bb21402778507cb8da6bc43c7ad
Author: Michael Forney <mforney@mforney.org>
Date: Wed, 12 Feb 2014 18:34:48 -0800
window: Rename WITHDRAWN -> NONE, TOPLEVEL -> NORMAL
Diffstat:
5 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/example/wm.c b/example/wm.c
@@ -189,9 +189,9 @@ static void window_event(struct wl_listener * listener, void * data)
free(window);
break;
case SWC_WINDOW_STATE_CHANGED:
- /* When the window changes state to TOPLEVEL, we can add it to the
+ /* When the window changes state to NORMAL, we can add it to the
* current screen and then rearrange the windows on that screen. */
- if (window->swc->state == SWC_WINDOW_STATE_TOPLEVEL)
+ if (window->swc->state == SWC_WINDOW_STATE_NORMAL)
{
screen_add_window(active_screen, window);
focus(window);
diff --git a/libswc/shell_surface.c b/libswc/shell_surface.c
@@ -75,7 +75,7 @@ static void set_toplevel(struct wl_client * client,
return;
shell_surface->type = SHELL_SURFACE_TYPE_TOPLEVEL;
- window_set_state(&shell_surface->window, SWC_WINDOW_STATE_TOPLEVEL);
+ window_set_state(&shell_surface->window, SWC_WINDOW_STATE_NORMAL);
}
static void set_transient(struct wl_client * client,
diff --git a/libswc/swc.h b/libswc/swc.h
@@ -95,8 +95,8 @@ struct swc_window
enum
{
- SWC_WINDOW_STATE_WITHDRAWN,
- SWC_WINDOW_STATE_TOPLEVEL
+ SWC_WINDOW_STATE_NONE,
+ SWC_WINDOW_STATE_NORMAL
} state;
struct swc_window * parent;
diff --git a/libswc/window.c b/libswc/window.c
@@ -119,7 +119,7 @@ bool window_initialize(struct window * window, const struct window_impl * impl,
window->base.title = NULL;
window->base.class = NULL;
- window->base.state = SWC_WINDOW_STATE_WITHDRAWN;
+ window->base.state = SWC_WINDOW_STATE_NONE;
window->base.parent = NULL;
wl_signal_init(&window->base.event_signal);
window->surface = surface;
diff --git a/libswc/xwm.c b/libswc/xwm.c
@@ -362,7 +362,7 @@ void swc_xwm_manage_window(xcb_window_t id, struct swc_surface * surface)
xcb_configure_window(xwm.connection, id, mask, values);
update_name(xwl_window);
- window_set_state(&xwl_window->window, SWC_WINDOW_STATE_TOPLEVEL);
+ window_set_state(&xwl_window->window, SWC_WINDOW_STATE_NORMAL);
}
}