From bfacd9d420896de2c5b6945af0298878f8bf957f Mon Sep 17 00:00:00 2001 From: "Jasper St. Pierre" Date: Sat, 1 Sep 2012 17:09:39 -0300 Subject: [PATCH] keybindings: Correct annotations for meta_keybindings_set_custom_handler We need @handler to be marked as (allow-none). At the same time, give the function a more useful docstring. --- src/core/keybindings.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/src/core/keybindings.c b/src/core/keybindings.c index 0fb5f701f..48929425a 100644 --- a/src/core/keybindings.c +++ b/src/core/keybindings.c @@ -3591,6 +3591,19 @@ meta_set_keybindings_disabled (gboolean setting) "Keybindings %s\n", all_bindings_disabled ? "disabled" : "enabled"); } +/** + * meta_keybindings_set_custom_handler: + * @name: The name of the keybinding to set + * @handler: (allow-none): The new handler function + * @user_data: User data to pass to the callback + * @free_data: Will be called when this handler is overridden. + * + * Allows users to register a custom handler for a + * builtin key binding. + * + * Returns: %TRUE if the binding known as @name was found, + * %FALSE otherwise. + */ gboolean meta_keybindings_set_custom_handler (const gchar *name, MetaKeyHandlerFunc handler,