use only the expected_focus_window instead of both the focused_window and

2005-07-31  Elijah Newren  <newren@gmail.com>

	* src/stack.c (is_focused_foreach, get_standalone_layer): use only
	the expected_focus_window instead of both the focused_window and
	the expected_focus_window.  Removes an infinite flicker loop in
	sloppy and mouse focus, and an ugly one time flicker in click to
	focus.  Fixes #311400.
This commit is contained in:
Elijah Newren 2005-08-01 04:58:58 +00:00 committed by Elijah Newren
parent 7a9be72bdf
commit 1b2e5e56a8
2 changed files with 13 additions and 6 deletions

View File

@ -1,3 +1,11 @@
2005-07-31 Elijah Newren <newren@gmail.com>
* src/stack.c (is_focused_foreach, get_standalone_layer): use only
the expected_focus_window instead of both the focused_window and
the expected_focus_window. Removes an infinite flicker loop in
sloppy and mouse focus, and an ugly one time flicker in click to
focus. Fixes #311400.
2005-07-30 Elijah Newren <newren@gmail.com>
Patch from Jaap Haitsma to make sure that Metacity dialogs have

View File

@ -242,8 +242,7 @@ static gboolean
is_focused_foreach (MetaWindow *window,
void *data)
{
if (window->has_focus ||
(window == window->display->expected_focus_window))
if (window == window->display->expected_focus_window)
{
*((gboolean*) data) = TRUE;
return FALSE;
@ -291,12 +290,12 @@ get_standalone_layer (MetaWindow *window)
if (window->wm_state_below)
layer = META_LAYER_BOTTOM;
else if ((window->fullscreen || window_is_fullscreen_size (window)) &&
(window->has_focus || focused_transient ||
(focused_transient ||
window == window->display->expected_focus_window ||
window->display->focus_window == NULL ||
(window->display->focus_window != NULL &&
window->display->expected_focus_window == NULL ||
(window->display->expected_focus_window != NULL &&
windows_on_different_xinerama (window,
window->display->focus_window))))
window->display->expected_focus_window))))
layer = META_LAYER_FULLSCREEN;
else if (window->wm_state_above)
layer = META_LAYER_DOCK;