mirror of
https://github.com/brl/mutter.git
synced 2024-11-21 23:50:41 -05:00
If no valid window is found in the MRU list, then set focus to the desktop
2006-01-15 Kyle Ambroff <kambroff@csus.edu> * src/workspace.c (focus_ancestor_or_mru_window): If no valid window is found in the MRU list, then set focus to the desktop window. (#317405)
This commit is contained in:
parent
d552ca35f6
commit
fac7010411
@ -1,3 +1,9 @@
|
||||
2006-01-15 Kyle Ambroff <kambroff@csus.edu>
|
||||
|
||||
* src/workspace.c (focus_ancestor_or_mru_window):
|
||||
If no valid window is found in the MRU list, then set focus to the
|
||||
desktop window. (#317405)
|
||||
|
||||
2006-01-15 Elijah Newren <newren@gmail.com>
|
||||
|
||||
Fix accidental overzealous focus holding by the terminal
|
||||
|
@ -950,6 +950,7 @@ focus_ancestor_or_mru_window (MetaWorkspace *workspace,
|
||||
Time timestamp)
|
||||
{
|
||||
MetaWindow *window = NULL;
|
||||
MetaWindow *desktop_window = NULL;
|
||||
GList *tmp;
|
||||
|
||||
if (not_this_one)
|
||||
@ -996,10 +997,22 @@ focus_ancestor_or_mru_window (MetaWorkspace *workspace,
|
||||
window = tmp->data;
|
||||
break;
|
||||
}
|
||||
else if (tmp_window != not_this_one &&
|
||||
desktop_window == NULL &&
|
||||
meta_window_showing_on_its_workspace (tmp_window) &&
|
||||
tmp_window->type == META_WINDOW_DESKTOP)
|
||||
{
|
||||
/* Found the most recently used desktop window */
|
||||
desktop_window = tmp_window;
|
||||
}
|
||||
|
||||
tmp = tmp->next;
|
||||
}
|
||||
|
||||
/* If no window was found, default to the MRU desktop-window */
|
||||
if (window == NULL)
|
||||
window = desktop_window;
|
||||
|
||||
if (window)
|
||||
{
|
||||
meta_topic (META_DEBUG_FOCUS,
|
||||
|
Loading…
Reference in New Issue
Block a user