From db167ebe80d3a85fed16f5bacc2ce4225074e45c Mon Sep 17 00:00:00 2001 From: Uli Schlachter Date: Sun, 6 Oct 2013 10:22:49 +0200 Subject: [PATCH] Revert "client: Don't move clients around across restarts (FS#1159)" This reverts commit c3bca6ac344577781858e06c83e310b69ac9a4e0. This caused problems where clients would always spawn on the top-left screen and couldn't be moved around. This was because lua placed them on the other screen, but when the titlebar got added, their top-left corner was moved over again. --- awesome.c | 6 ------ objects/client.c | 11 ++--------- 2 files changed, 2 insertions(+), 15 deletions(-) diff --git a/awesome.c b/awesome.c index 743010b7..05bd4b2e 100644 --- a/awesome.c +++ b/awesome.c @@ -65,12 +65,6 @@ awesome_atexit(bool restart) lua_pushboolean(globalconf.L, restart); signal_object_emit(globalconf.L, &global_signals, "exit", 1); - /* TODO: Reparent windows back to root window, placing them according to - * their window gravity. Right now we pretend to use static gravity and that - * works automatically thanks to xcb_change_save_set(). See - * titlebar_resize(). - */ - a_dbus_cleanup(); systray_cleanup(); diff --git a/objects/client.c b/objects/client.c index 4dd318c1..bdbcaaeb 100644 --- a/objects/client.c +++ b/objects/client.c @@ -1558,23 +1558,16 @@ titlebar_resize(client_t *c, client_titlebar_t bar, int size) return; /* Now resize the client (and titlebars!) suitably (the client without - * titlebars should keep its current size!) - * TODO: I guess that this should honor the client's window gravity, right - * now we pretend to have static gravity. See awesome_atexit(). - */ + * titlebars should keep its current size!) */ area_t geometry = c->geometry; int change = size - c->titlebar[bar].size; switch (bar) { case CLIENT_TITLEBAR_TOP: - geometry.y -= change; - /* fall through */; case CLIENT_TITLEBAR_BOTTOM: geometry.height += change; break; - case CLIENT_TITLEBAR_LEFT: - geometry.x -= change; - /* fall through */; case CLIENT_TITLEBAR_RIGHT: + case CLIENT_TITLEBAR_LEFT: geometry.width += change; break; default: