1
0
Fork 0

Stick and unstick transients with their parent automatically. Fixes

2005-01-26  Elijah Newren  <newren@gmail.com>

	Stick and unstick transients with their parent automatically.
	Fixes #152283.

	* src/window.c: (window_stick_impl, window_unstick_impl): rename
	from meta_window_stick and meta_window_unstick respectively,
	(stick_foreach_func): a function to assist calling
	window_(un)stick_impl on each transient, (meta_window_stick,
	meta_window_unstick): new functions that call window_stick_impl or
	window_unstick_impl for the window and each of its transients.
This commit is contained in:
Elijah Newren 2005-01-26 23:25:05 +00:00 committed by Elijah Newren
parent fa5bc6ff51
commit 5fe06b5fff
2 changed files with 50 additions and 4 deletions

View file

@ -1,3 +1,15 @@
2005-01-26 Elijah Newren <newren@gmail.com>
Stick and unstick transients with their parent automatically.
Fixes #152283.
* src/window.c: (window_stick_impl, window_unstick_impl): rename
from meta_window_stick and meta_window_unstick respectively,
(stick_foreach_func): a function to assist calling
window_(un)stick_impl on each transient, (meta_window_stick,
meta_window_unstick): new functions that call window_stick_impl or
window_unstick_impl for the window and each of its transients.
2005-01-26 Elijah Newren <newren@gmail.com>
Patch from John Paul Wallington to keep tooltip on screen

View file

@ -3421,8 +3421,8 @@ meta_window_change_workspace (MetaWindow *window,
workspace);
}
void
meta_window_stick (MetaWindow *window)
static void
window_stick_impl (MetaWindow *window)
{
GList *tmp;
MetaWorkspace *workspace;
@ -3456,8 +3456,8 @@ meta_window_stick (MetaWindow *window)
meta_window_queue_calc_showing (window);
}
void
meta_window_unstick (MetaWindow *window)
static void
window_unstick_impl (MetaWindow *window)
{
GList *tmp;
MetaWorkspace *workspace;
@ -3492,6 +3492,40 @@ meta_window_unstick (MetaWindow *window)
meta_window_queue_calc_showing (window);
}
static gboolean
stick_foreach_func (MetaWindow *window,
void *data)
{
gboolean stick;
stick = *(gboolean*)data;
if (stick)
window_stick_impl (window);
else
window_unstick_impl (window);
return TRUE;
}
void
meta_window_stick (MetaWindow *window)
{
gboolean stick = TRUE;
window_stick_impl (window);
meta_window_foreach_transient (window,
stick_foreach_func,
&stick);
}
void
meta_window_unstick (MetaWindow *window)
{
gboolean stick = FALSE;
window_unstick_impl (window);
meta_window_foreach_transient (window,
stick_foreach_func,
&stick);
}
unsigned long
meta_window_get_net_wm_desktop (MetaWindow *window)
{