mirror of
https://github.com/brl/mutter.git
synced 2024-11-22 08:00:42 -05:00
handle CWStackMode in configure requests (meta_window_new): if a window is
2002-05-28 Havoc Pennington <hp@pobox.com> * src/window.c (meta_window_configure_request): handle CWStackMode in configure requests (meta_window_new): if a window is opened at 0,0 and screen size, put it in the fullscreen state. (meta_window_new): remove old code that set the window position to 0,0 if PPosition/USPosition unset, that will be handled by whether we place the window or not.
This commit is contained in:
parent
0cf10075e1
commit
4b5eda0b0a
10
ChangeLog
10
ChangeLog
@ -1,3 +1,13 @@
|
|||||||
|
2002-05-28 Havoc Pennington <hp@pobox.com>
|
||||||
|
|
||||||
|
* src/window.c (meta_window_configure_request): handle CWStackMode
|
||||||
|
in configure requests
|
||||||
|
(meta_window_new): if a window is opened at 0,0 and screen size,
|
||||||
|
put it in the fullscreen state.
|
||||||
|
(meta_window_new): remove old code that set the window position to
|
||||||
|
0,0 if PPosition/USPosition unset, that will be handled by whether
|
||||||
|
we place the window or not.
|
||||||
|
|
||||||
2002-05-28 Abel Cheung <maddog@linux.org.hk>
|
2002-05-28 Abel Cheung <maddog@linux.org.hk>
|
||||||
|
|
||||||
* configure.in: Added "zh_TW" to ALL_LINGUAS.
|
* configure.in: Added "zh_TW" to ALL_LINGUAS.
|
||||||
|
49
src/window.c
49
src/window.c
@ -443,14 +443,11 @@ meta_window_new (MetaDisplay *display, Window xwindow,
|
|||||||
update_struts (window);
|
update_struts (window);
|
||||||
|
|
||||||
update_net_wm_state (window);
|
update_net_wm_state (window);
|
||||||
/* Initially maximize if window is fullscreen; FIXME
|
|
||||||
* assume fullscreen state instead once we have that state...
|
if (attrs.x == 0 && attrs.y == 0 &&
|
||||||
*/
|
|
||||||
if (!window->maximized &&
|
|
||||||
attrs.x == 0 && attrs.y == 0 &&
|
|
||||||
attrs.width == window->screen->width &&
|
attrs.width == window->screen->width &&
|
||||||
attrs.height == window->screen->height)
|
attrs.height == window->screen->height)
|
||||||
window->maximized = TRUE;
|
window->fullscreen = TRUE;
|
||||||
|
|
||||||
update_mwm_hints (window);
|
update_mwm_hints (window);
|
||||||
update_wm_class (window);
|
update_wm_class (window);
|
||||||
@ -462,15 +459,6 @@ meta_window_new (MetaDisplay *display, Window xwindow,
|
|||||||
update_icon_name (window);
|
update_icon_name (window);
|
||||||
update_icon (window);
|
update_icon (window);
|
||||||
|
|
||||||
if (!window->mapped &&
|
|
||||||
(window->size_hints.flags & PPosition) == 0 &&
|
|
||||||
(window->size_hints.flags & USPosition) == 0)
|
|
||||||
{
|
|
||||||
/* ignore current window position */
|
|
||||||
window->size_hints.x = 0;
|
|
||||||
window->size_hints.y = 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (window->initially_iconic)
|
if (window->initially_iconic)
|
||||||
{
|
{
|
||||||
/* WM_HINTS said minimized */
|
/* WM_HINTS said minimized */
|
||||||
@ -2992,6 +2980,37 @@ meta_window_configure_request (MetaWindow *window,
|
|||||||
window->size_hints.width,
|
window->size_hints.width,
|
||||||
window->size_hints.height);
|
window->size_hints.height);
|
||||||
|
|
||||||
|
/* Handle stacking. We only handle raises/lowers, mostly because
|
||||||
|
* stack.c really can't deal with anything else. I guess we'll fix
|
||||||
|
* that if a client turns up that really requires it. Only a very
|
||||||
|
* few clients even require the raise/lower (and in fact all client
|
||||||
|
* attempts to deal with stacking order are essentially broken,
|
||||||
|
* since they have no idea what other clients are involved or how
|
||||||
|
* the stack looks).
|
||||||
|
*
|
||||||
|
* I'm pretty sure no interesting client uses TopIf, BottomIf, or
|
||||||
|
* Opposite anyway, so the only possible missing thing is
|
||||||
|
* Above/Below with a sibling set. For now we just pretend there's
|
||||||
|
* never a sibling set and always do the full raise/lower instead of
|
||||||
|
* the raise-just-above/below-sibling.
|
||||||
|
*/
|
||||||
|
if (event->xconfigurerequest.value_mask & CWStackMode)
|
||||||
|
{
|
||||||
|
switch (event->xconfigurerequest.detail)
|
||||||
|
{
|
||||||
|
case Above:
|
||||||
|
meta_window_raise (window);
|
||||||
|
break;
|
||||||
|
case Below:
|
||||||
|
meta_window_lower (window);
|
||||||
|
break;
|
||||||
|
case TopIf:
|
||||||
|
case BottomIf:
|
||||||
|
case Opposite:
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user