diff --git a/src/core/display.c b/src/core/display.c index 526674c3b..9a7d9a12e 100644 --- a/src/core/display.c +++ b/src/core/display.c @@ -2065,18 +2065,17 @@ meta_display_end_grab_op (MetaDisplay *display, } /** - * meta_display_get_grab_op: + * meta_display_is_grabbed: * @display: The #MetaDisplay that the window is on - * Gets the current grab operation, if any. + * Returns %TRUE if there is an ongoing grab operation. * - * Return value: the current grab operation, or %META_GRAB_OP_NONE if - * Mutter doesn't currently have a grab. + * Return value: Whether there is an active display grab operation. */ -MetaGrabOp -meta_display_get_grab_op (MetaDisplay *display) +gboolean +meta_display_is_grabbed (MetaDisplay *display) { - return display->grab_op; + return display->grab_op != META_GRAB_OP_NONE; } void diff --git a/src/meta/display.h b/src/meta/display.h index 206e08c0c..f53346c24 100644 --- a/src/meta/display.h +++ b/src/meta/display.h @@ -148,7 +148,7 @@ void meta_display_end_grab_op (MetaDisplay *display, guint32 timestamp); META_EXPORT -MetaGrabOp meta_display_get_grab_op (MetaDisplay *display); +gboolean meta_display_is_grabbed (MetaDisplay *display); META_EXPORT guint meta_display_add_keybinding (MetaDisplay *display,