mirror of
https://github.com/brl/mutter.git
synced 2024-11-22 08:00:42 -05:00
...
This commit is contained in:
parent
99f53856f6
commit
073a5d4ea9
@ -562,6 +562,11 @@ event_queue_callback (MetaEventQueue *queue,
|
|||||||
case MapRequest:
|
case MapRequest:
|
||||||
if (window == NULL)
|
if (window == NULL)
|
||||||
window = meta_window_new (display, event->xmaprequest.window, FALSE);
|
window = meta_window_new (display, event->xmaprequest.window, FALSE);
|
||||||
|
else if (window)
|
||||||
|
{
|
||||||
|
if (window->minimized)
|
||||||
|
meta_window_unminimize (window);
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
case ReparentNotify:
|
case ReparentNotify:
|
||||||
break;
|
break;
|
||||||
|
15
src/frame.c
15
src/frame.c
@ -38,7 +38,8 @@ struct _MetaFrameActionGrab
|
|||||||
/* This lacks ButtonReleaseMask to avoid the auto-grab
|
/* This lacks ButtonReleaseMask to avoid the auto-grab
|
||||||
* since it breaks our popup menu
|
* since it breaks our popup menu
|
||||||
*/
|
*/
|
||||||
#define EVENT_MASK (StructureNotifyMask | SubstructureNotifyMask | \
|
#define EVENT_MASK (SubstructureRedirectMask | \
|
||||||
|
StructureNotifyMask | SubstructureNotifyMask | \
|
||||||
ExposureMask | \
|
ExposureMask | \
|
||||||
ButtonPressMask | ButtonReleaseMask | \
|
ButtonPressMask | ButtonReleaseMask | \
|
||||||
PointerMotionMask | PointerMotionHintMask | \
|
PointerMotionMask | PointerMotionHintMask | \
|
||||||
@ -51,12 +52,20 @@ meta_frame_init_info (MetaFrame *frame,
|
|||||||
MetaFrameInfo *info)
|
MetaFrameInfo *info)
|
||||||
{
|
{
|
||||||
info->flags =
|
info->flags =
|
||||||
META_FRAME_ALLOWS_MENU | META_FRAME_ALLOWS_DELETE |
|
META_FRAME_ALLOWS_MENU | META_FRAME_ALLOWS_RESIZE;
|
||||||
META_FRAME_ALLOWS_RESIZE;
|
|
||||||
|
if (frame->window->has_close_func)
|
||||||
|
info->flags |= META_FRAME_ALLOWS_DELETE;
|
||||||
|
|
||||||
if (frame->window->type == META_WINDOW_NORMAL)
|
if (frame->window->type == META_WINDOW_NORMAL)
|
||||||
info->flags |= (META_FRAME_ALLOWS_ICONIFY | META_FRAME_ALLOWS_MAXIMIZE);
|
info->flags |= (META_FRAME_ALLOWS_ICONIFY | META_FRAME_ALLOWS_MAXIMIZE);
|
||||||
|
|
||||||
|
if (!frame->window->has_maximize_func)
|
||||||
|
info->flags &= ~META_FRAME_ALLOWS_MAXIMIZE;
|
||||||
|
|
||||||
|
if (!frame->window->has_minimize_func)
|
||||||
|
info->flags &= ~META_FRAME_ALLOWS_ICONIFY;
|
||||||
|
|
||||||
if (frame->window->has_focus)
|
if (frame->window->has_focus)
|
||||||
info->flags |= META_FRAME_HAS_FOCUS;
|
info->flags |= META_FRAME_HAS_FOCUS;
|
||||||
|
|
||||||
|
@ -23,9 +23,11 @@ if test -z "$ONLY_WM"; then
|
|||||||
done
|
done
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
usleep 5000
|
||||||
|
|
||||||
DISPLAY=:1 xsetroot -solid royalblue3
|
DISPLAY=:1 xsetroot -solid royalblue3
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if test -z "$ONLY_SETUP"; then
|
if test -z "$ONLY_SETUP"; then
|
||||||
METACITY_UISLAVE_DIR=./uislave DISPLAY=:1 unst libtool --mode=execute $DEBUG ./metacity
|
METACITY_UISLAVE_DIR=./uislave DISPLAY=:1 exec unst libtool --mode=execute $DEBUG ./metacity
|
||||||
fi
|
fi
|
||||||
|
17
src/window.c
17
src/window.c
@ -1966,8 +1966,13 @@ update_mwm_hints (MetaWindow *window)
|
|||||||
|
|
||||||
/* We support MWM hints deemed non-stupid */
|
/* We support MWM hints deemed non-stupid */
|
||||||
|
|
||||||
|
meta_verbose ("Window %s has MWM hints\n",
|
||||||
|
window->desc);
|
||||||
|
|
||||||
if (hints->flags & MWM_HINTS_DECORATIONS)
|
if (hints->flags & MWM_HINTS_DECORATIONS)
|
||||||
{
|
{
|
||||||
|
meta_verbose ("Window %s sets MWM decorations to 0x%lx\n",
|
||||||
|
window->desc, hints->decorations);
|
||||||
if (hints->decorations == 0)
|
if (hints->decorations == 0)
|
||||||
window->decorated = FALSE;
|
window->decorated = FALSE;
|
||||||
}
|
}
|
||||||
@ -1975,12 +1980,24 @@ update_mwm_hints (MetaWindow *window)
|
|||||||
if (hints->flags & MWM_HINTS_FUNCTIONS)
|
if (hints->flags & MWM_HINTS_FUNCTIONS)
|
||||||
{
|
{
|
||||||
if ((hints->functions & MWM_FUNC_CLOSE) == 0)
|
if ((hints->functions & MWM_FUNC_CLOSE) == 0)
|
||||||
|
{
|
||||||
|
meta_verbose ("Window %s disables close via MWM hints\n",
|
||||||
|
window->desc);
|
||||||
window->has_close_func = FALSE;
|
window->has_close_func = FALSE;
|
||||||
|
}
|
||||||
if ((hints->functions & MWM_FUNC_MINIMIZE) == 0)
|
if ((hints->functions & MWM_FUNC_MINIMIZE) == 0)
|
||||||
|
{
|
||||||
|
meta_verbose ("Window %s disables minimize via MWM hints\n",
|
||||||
|
window->desc);
|
||||||
window->has_minimize_func = FALSE;
|
window->has_minimize_func = FALSE;
|
||||||
|
}
|
||||||
if ((hints->functions & MWM_FUNC_MAXIMIZE) == 0)
|
if ((hints->functions & MWM_FUNC_MAXIMIZE) == 0)
|
||||||
|
{
|
||||||
|
meta_verbose ("Window %s disables maximize via MWM hints\n",
|
||||||
|
window->desc);
|
||||||
window->has_maximize_func = FALSE;
|
window->has_maximize_func = FALSE;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
XFree (hints);
|
XFree (hints);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user