| Nautilus-Actions™ Reference Manual | ||||
|---|---|---|---|---|
| Top | Description | Object Hierarchy | Implemented Interfaces | ||||
#include <nautilus-actions/na-object-item.h> #define NA_OBJECT_ITEM_TYPE #define NA_OBJECT_ITEM (object) #define NA_IS_OBJECT_ITEM (object) NAObjectItem; enum NAItemTarget; gboolean na_object_item_are_equal (const NAObjectItem *a,const NAObjectItem *b); NAObjectId * na_object_item_get_item (const NAObjectItem *item,const gchar *id); gint na_object_item_get_position (const NAObjectItem *item,const NAObjectId *child); void na_object_item_append_item (NAObjectItem *item,const NAObjectId *child); void na_object_item_insert_at (NAObjectItem *item,const NAObjectId *child,gint pos); void na_object_item_insert_item (NAObjectItem *item,const NAObjectId *child,const NAObjectId *before); void na_object_item_remove_item (NAObjectItem *item,const NAObjectId *child); guint na_object_item_get_items_count (const NAObjectItem *item); void na_object_item_count_items (GList *items,gint *menus,gint *actions,gint *profiles,gboolean recurse); void na_object_item_unref_items (GList *items); void na_object_item_unref_items_rec (GList *items); void na_object_item_rebuild_children_slist (NAObjectItem *item); void na_object_item_deals_with_version (NAObjectItem *item);
GObject +----NAObject +----NAObjectId +----NAObjectItem +----NAObjectAction +----NAObjectMenu
This is a pure virtual class, i.e. not an instantiatable one, but serves as the base class for NAObjectAction and NAObjectMenu.
#define NA_OBJECT_ITEM( object ) ( G_TYPE_CHECK_INSTANCE_CAST( object, NA_OBJECT_ITEM_TYPE, NAObjectItem ))
#define NA_IS_OBJECT_ITEM( object ) ( G_TYPE_CHECK_INSTANCE_TYPE( object, NA_OBJECT_ITEM_TYPE ))
typedef enum {
ITEM_TARGET_SELECTION = 1,
ITEM_TARGET_LOCATION,
ITEM_TARGET_TOOLBAR,
ITEM_TARGET_ANY
} NAItemTarget;
The NAItemTarget mode is Nautilus-driven. It determines in which part of the Nautilus UI our actions will be displayed.
| when targeting the selection context menu. | |
| when targeting the background context menu. | |
| when targeting the toolbar. | |
| a wilcard target defined in order to be able to activate an action from a keyboard shortcut, while keeping this same action hidden from the UI. |
gboolean na_object_item_are_equal (const NAObjectItem *a,const NAObjectItem *b);
NAObjectId * na_object_item_get_item (const NAObjectItem *item,const gchar *id);
gint na_object_item_get_position (const NAObjectItem *item,const NAObjectId *child);
void na_object_item_append_item (NAObjectItem *item,const NAObjectId *child);
void na_object_item_insert_at (NAObjectItem *item,const NAObjectId *child,gint pos);
void na_object_item_insert_item (NAObjectItem *item,const NAObjectId *child,const NAObjectId *before);
void na_object_item_remove_item (NAObjectItem *item,const NAObjectId *child);
void na_object_item_count_items (GList *items,gint *menus,gint *actions,gint *profiles,gboolean recurse);
void na_object_item_rebuild_children_slist
(NAObjectItem *item);