From 1f1338ee5c0fe78ddaffcf580ae528e2d4d58e93 Mon Sep 17 00:00:00 2001 From: Benoit Gschwind Date: Fri, 22 Feb 2008 00:49:21 +0100 Subject: [PATCH] Ramove unneeded frame_get_window --- engines/default/plugin.c | 1 - openbox/client.c | 4 ++-- openbox/engine_interface.h | 2 -- openbox/event.c | 2 +- openbox/mouse.c | 2 +- openbox/window.c | 2 +- 6 files changed, 5 insertions(+), 8 deletions(-) diff --git a/engines/default/plugin.c b/engines/default/plugin.c index a3ffa314..fdf4ddf9 100644 --- a/engines/default/plugin.c +++ b/engines/default/plugin.c @@ -1683,7 +1683,6 @@ ObFrameEngine plugin = { frame_update_skin, /* */ frame_set_hover_flag, /* */ frame_set_press_flag, /* */ - frame_get_window,/* */ frame_get_size, /* */ frame_get_decorations, /* */ frame_is_visible, /* */ diff --git a/openbox/client.c b/openbox/client.c index 0b5f1733..e462c63d 100644 --- a/openbox/client.c +++ b/openbox/client.c @@ -600,7 +600,7 @@ void client_manage(Window window, ObPrompt *prompt) g_free(settings); ob_debug("Managed window 0x%lx plate 0x%x (%s)", - window, frame_engine->frame_get_window(self->frame), self->class); + window, self->w_frame, self->class); } @@ -670,7 +670,7 @@ void client_unmanage(ObClient *self) gulong ignore_start; ob_debug("Unmanaging window: 0x%x plate 0x%x (%s) (%s)", - self->w_client, frame_engine->frame_get_window(self->frame), + self->w_client, self->w_frame, self->class, self->title ? self->title : ""); g_assert(self != NULL); diff --git a/openbox/engine_interface.h b/openbox/engine_interface.h index ce67be62..c7bf39dc 100644 --- a/openbox/engine_interface.h +++ b/openbox/engine_interface.h @@ -172,8 +172,6 @@ struct _ObFrameEngine void (*frame_set_hover_flag)(gpointer, ObFrameButton); void (*frame_set_press_flag)(gpointer, ObFrameButton); - Window (*frame_get_window)(gpointer); - void (*frame_get_size)(gpointer, Strut *); gint (*frame_get_decorations)(gpointer); diff --git a/openbox/event.c b/openbox/event.c index 00dce00e..a9f526b2 100644 --- a/openbox/event.c +++ b/openbox/event.c @@ -1226,7 +1226,7 @@ static void event_handle_client(ObClient *client, XEvent *e) break; case ReparentNotify: /* this is when the client is first taken captive in the frame */ - if (e->xreparent.parent == frame_engine->frame_get_window(client->frame)) break; + if (e->xreparent.parent == client->w_frame) break; /* This event is quite rare and is usually handled in unmapHandler. diff --git a/openbox/mouse.c b/openbox/mouse.c index 031000a0..f2903919 100644 --- a/openbox/mouse.c +++ b/openbox/mouse.c @@ -117,7 +117,7 @@ void mouse_grab_for_client(ObClient *client, gboolean grab) guint mask; if (FRAME_CONTEXT(i, client)) { - win = frame_engine->frame_get_window(client->frame); + win = client->w_frame; mode = GrabModeAsync; mask = ButtonPressMask | ButtonMotionMask | ButtonReleaseMask; } else if (CLIENT_CONTEXT(i, client)) { diff --git a/openbox/window.c b/openbox/window.c index 136720b3..1e804fe5 100644 --- a/openbox/window.c +++ b/openbox/window.c @@ -55,7 +55,7 @@ Window window_top(ObWindow *self) case OB_WINDOW_CLASS_DOCK: return WINDOW_AS_DOCK(self)->frame; case OB_WINDOW_CLASS_CLIENT: - return frame_engine->frame_get_window(WINDOW_AS_CLIENT(self)->frame); + return WINDOW_AS_CLIENT(self)->w_frame; case OB_WINDOW_CLASS_INTERNAL: return WINDOW_AS_INTERNAL(self)->window; case OB_WINDOW_CLASS_PROMPT: -- 2.39.2