[nautilus] extension: Allow @tip to be NULL in nautilus_menu_item_new()
- From: António Fernandes <antoniof src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [nautilus] extension: Allow @tip to be NULL in nautilus_menu_item_new()
- Date: Sun, 5 Dec 2021 08:50:10 +0000 (UTC)
commit a43fb2deab7c7379f9e341c500ecde4d4462f35d
Author: Aaron Jacobs <atheriel gmail com>
Date: Sat Dec 4 20:23:28 2021 -0500
extension: Allow @tip to be NULL in nautilus_menu_item_new()
Tooltips are currently unused, so it makes sense to allow NULL here, as
with the @icon parameter.
libnautilus-extension/nautilus-menu-item.c | 1 -
libnautilus-extension/nautilus-menu.h | 2 +-
2 files changed, 1 insertion(+), 2 deletions(-)
---
diff --git a/libnautilus-extension/nautilus-menu-item.c b/libnautilus-extension/nautilus-menu-item.c
index ead7ee8ca..50cf7fdc5 100644
--- a/libnautilus-extension/nautilus-menu-item.c
+++ b/libnautilus-extension/nautilus-menu-item.c
@@ -69,7 +69,6 @@ nautilus_menu_item_new (const char *name,
g_return_val_if_fail (name != NULL, NULL);
g_return_val_if_fail (label != NULL, NULL);
- g_return_val_if_fail (tip != NULL, NULL);
item = g_object_new (NAUTILUS_TYPE_MENU_ITEM,
"name", name,
diff --git a/libnautilus-extension/nautilus-menu.h b/libnautilus-extension/nautilus-menu.h
index c9f05338c..1bcc8b7f5 100644
--- a/libnautilus-extension/nautilus-menu.h
+++ b/libnautilus-extension/nautilus-menu.h
@@ -102,7 +102,7 @@ void nautilus_menu_item_list_free (GList *item_list);
* nautilus_menu_item_new:
* @name: the identifier for the menu item
* @label: the user-visible label of the menu item
- * @tip: the tooltip of the menu item
+ * @tip: (nullable): the tooltip of the menu item
* @icon: (nullable): the name of the icon to display in the menu item
*
* Creates a new menu item that can be added to the toolbar or to a contextual menu.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]