From 15a05467bded6850aedba693e9a8ea8432a85c93 Mon Sep 17 00:00:00 2001 From: Havoc Pennington Date: Thu, 24 Oct 2002 05:15:28 +0000 Subject: [PATCH] put minimized windows at the end of Alt+Tab, #89416 2002-10-24 Havoc Pennington * src/display.c (meta_display_get_tab_list): put minimized windows at the end of Alt+Tab, #89416 --- ChangeLog | 5 +++++ rationales.txt | 2 ++ src/display.c | 29 ++++++++++++++++++++++++++--- 3 files changed, 33 insertions(+), 3 deletions(-) diff --git a/ChangeLog b/ChangeLog index 53eccb176..c8ab4b344 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2002-10-24 Havoc Pennington + + * src/display.c (meta_display_get_tab_list): put minimized windows + at the end of Alt+Tab, #89416 + 2002-10-23 Havoc Pennington * src/theme.c (meta_frame_layout_calc_geometry): initialize the diff --git a/rationales.txt b/rationales.txt index 7fad7855c..e024fc2bc 100644 --- a/rationales.txt +++ b/rationales.txt @@ -4,3 +4,5 @@ Keep panel always on top: http://bugzilla.gnome.org/show_bug.cgi?id=81551 Edge flipping: http://bugzilla.gnome.org/show_bug.cgi?id=82917 Opaque resize: http://bugzilla.gnome.org/show_bug.cgi?id=92618 Super+click to resize: http://bugzilla.gnome.org/show_bug.cgi?id=79315 +minimized windows in Alt+tab: http://bugzilla.gnome.org/show_bug.cgi?id=89416 + diff --git a/src/display.c b/src/display.c index efe292987..6be190300 100644 --- a/src/display.c +++ b/src/display.c @@ -3009,7 +3009,9 @@ meta_display_get_tab_list (MetaDisplay *display, /* workspace can be NULL for all workspaces */ - /* Windows sellout mode - MRU order */ + /* Windows sellout mode - MRU order. Collect unminimized windows + * then minimized so minimized windows aren't in the way so much. + */ { GList *tmp; @@ -3019,7 +3021,8 @@ meta_display_get_tab_list (MetaDisplay *display, { MetaWindow *window = tmp->data; - if (window->screen == screen && + if (!window->minimized && + window->screen == screen && IN_TAB_CHAIN (window, type) && (workspace == NULL || meta_window_visible_on_workspace (window, workspace))) @@ -3027,9 +3030,29 @@ meta_display_get_tab_list (MetaDisplay *display, tmp = tmp->next; } - tab_list = g_slist_reverse (tab_list); } + { + GList *tmp; + + tmp = screen->display->mru_list; + while (tmp != NULL) + { + MetaWindow *window = tmp->data; + + if (window->minimized && + window->screen == screen && + IN_TAB_CHAIN (window, type) && + (workspace == NULL || + meta_window_visible_on_workspace (window, workspace))) + tab_list = g_slist_prepend (tab_list, window); + + tmp = tmp->next; + } + } + + tab_list = g_slist_reverse (tab_list); + return tab_list; }