mirror of
https://github.com/brl/mutter.git
synced 2024-11-29 03:20:46 -05:00
window: Move UI frame event handler to a separate function
In order to tell whether an event has been handled by the frame UI, move the UI frame handler to a specific helper function. https://gitlab.gnome.org/GNOME/mutter/issues/88
This commit is contained in:
parent
15c9458e92
commit
ad62a659eb
@ -782,6 +782,9 @@ void meta_window_handle_enter (MetaWindow *window,
|
|||||||
guint root_y);
|
guint root_y);
|
||||||
void meta_window_handle_leave (MetaWindow *window);
|
void meta_window_handle_leave (MetaWindow *window);
|
||||||
|
|
||||||
|
gboolean meta_window_handle_ui_frame_event (MetaWindow *window,
|
||||||
|
const ClutterEvent *event);
|
||||||
|
|
||||||
void meta_window_handle_ungrabbed_event (MetaWindow *window,
|
void meta_window_handle_ungrabbed_event (MetaWindow *window,
|
||||||
const ClutterEvent *event);
|
const ClutterEvent *event);
|
||||||
|
|
||||||
|
@ -8243,6 +8243,16 @@ meta_window_handle_leave (MetaWindow *window)
|
|||||||
meta_window_lower (window);
|
meta_window_lower (window);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
gboolean
|
||||||
|
meta_window_handle_ui_frame_event (MetaWindow *window,
|
||||||
|
const ClutterEvent *event)
|
||||||
|
{
|
||||||
|
if (!window->frame)
|
||||||
|
return FALSE;
|
||||||
|
|
||||||
|
return meta_ui_frame_handle_event (window->frame->ui_frame, event);
|
||||||
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
meta_window_handle_ungrabbed_event (MetaWindow *window,
|
meta_window_handle_ungrabbed_event (MetaWindow *window,
|
||||||
const ClutterEvent *event)
|
const ClutterEvent *event)
|
||||||
@ -8256,7 +8266,7 @@ meta_window_handle_ungrabbed_event (MetaWindow *window,
|
|||||||
gfloat x, y;
|
gfloat x, y;
|
||||||
guint button;
|
guint button;
|
||||||
|
|
||||||
if (window->frame && meta_ui_frame_handle_event (window->frame->ui_frame, event))
|
if (meta_window_handle_ui_frame_event (window, event))
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if (event->type != CLUTTER_BUTTON_PRESS &&
|
if (event->type != CLUTTER_BUTTON_PRESS &&
|
||||||
|
Loading…
Reference in New Issue
Block a user