[mutter] keybindings: Add is_builtin() method
- From: Florian MÃllner <fmuellner src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [mutter] keybindings: Add is_builtin() method
- Date: Sat, 17 Nov 2012 00:58:43 +0000 (UTC)
commit 6004197064cea2d979747b03c79616d52c27d2ed
Author: Florian MÃllner <fmuellner gnome org>
Date: Sat Nov 17 00:32:04 2012 +0100
keybindings: Add is_builtin() method
https://bugzilla.gnome.org/show_bug.cgi?id=688202
src/core/keybindings.c | 6 ++++++
src/meta/keybindings.h | 1 +
2 files changed, 7 insertions(+), 0 deletions(-)
---
diff --git a/src/core/keybindings.c b/src/core/keybindings.c
index f750b2f..63b0e13 100644
--- a/src/core/keybindings.c
+++ b/src/core/keybindings.c
@@ -95,6 +95,12 @@ meta_key_binding_get_mask (MetaKeyBinding *binding)
return binding->mask;
}
+gboolean
+meta_key_binding_is_builtin (MetaKeyBinding *binding)
+{
+ return binding->handler->flags & META_KEY_BINDING_BUILTIN;
+}
+
/* These can't be bound to anything, but they are used to handle
* various other events. TODO: Possibly we should include them as event
* handler functions and have some kind of flag to say they're unbindable.
diff --git a/src/meta/keybindings.h b/src/meta/keybindings.h
index 862e1b2..2cd2a37 100644
--- a/src/meta/keybindings.h
+++ b/src/meta/keybindings.h
@@ -28,6 +28,7 @@
const char *meta_key_binding_get_name (MetaKeyBinding *binding);
MetaVirtualModifier meta_key_binding_get_modifiers (MetaKeyBinding *binding);
guint meta_key_binding_get_mask (MetaKeyBinding *binding);
+gboolean meta_key_binding_is_builtin (MetaKeyBinding *binding);
gboolean meta_keybindings_set_custom_handler (const gchar *name,
MetaKeyHandlerFunc handler,
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]