From c16f838abfbe0808b1b05d6df9abab8a34538c6f Mon Sep 17 00:00:00 2001 From: markt Date: Sun, 3 Jun 2007 20:37:32 +0000 Subject: deiconify windows when auto-grouped with new window, when using focusnew --- ChangeLog | 3 +++ src/Window.cc | 10 ++++++---- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/ChangeLog b/ChangeLog index 6f8287d..df0da3b 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,6 +1,9 @@ (Format: Year/Month/Day) Changes for 1.0.0: *07/06/03: + * Deiconify when automatically tabbing to a minimized window with focus new + windows on, bug #1716899 (Mark) + Window.cc FbWinFrame.cc * Submenus of slit menu were misbehaving with xinerama (Mark) Slit.cc * Also send transient windows when sending a window to another workspace, bug diff --git a/src/Window.cc b/src/Window.cc index 413ffcc..46530b7 100644 --- a/src/Window.cc +++ b/src/Window.cc @@ -668,9 +668,11 @@ void FluxboxWindow::attachClient(WinClient &client, int x, int y) { // and we don't seem to get a FocusIn event from setInputFocus setCurrentClient(client); FocusControl::setFocusedWindow(&client); - } else if (focused_win) + } else if (focused_win) { setCurrentClient(*focused_win, false); - else + if (isIconic() && screen().focusControl().focusNew() && !Fluxbox::instance()->isStartup()) + deiconify(); + } else // reparenting puts the new client on top, but the old client is keeping // the focus, so we raise it m_client->raise(); @@ -1501,7 +1503,7 @@ void FluxboxWindow::deiconify(bool reassoc, bool do_raise) { (*client_it)->setEventMask(PropertyChangeMask | StructureNotifyMask | FocusChangeMask); } - if (reassoc && !m_client->transients.empty()) { + if (reassoc) { // deiconify all transients client_it = clientList().begin(); for (; client_it != client_it_end; ++client_it) { @@ -2337,7 +2339,7 @@ void FluxboxWindow::mapRequestEvent(XMapRequestEvent &re) { void FluxboxWindow::mapNotifyEvent(XMapEvent &ne) { WinClient *client = findClient(ne.window); - if (client == 0) + if (client == 0 || client != m_client) return; #ifdef DEBUG cerr<<"FluxboxWindow::mapNotifyEvent: " -- cgit v0.11.2