unity-gtk-action-group

unity-gtk-action-group — Action group collector

Synopsis

#include <unity-gtk-parser.h>

struct              UnityGtkActionGroup;
typedef             UnityGtkActionGroupClass;
UnityGtkActionGroup * unity_gtk_action_group_new        (GActionGroup *old_group);
void                unity_gtk_action_group_connect_shell
                                                        (UnityGtkActionGroup *group,
                                                         UnityGtkMenuShell *shell);
void                unity_gtk_action_group_disconnect_shell
                                                        (UnityGtkActionGroup *group,
                                                         UnityGtkMenuShell *shell);
void                unity_gtk_action_group_set_debug    (gboolean debug);

Object Hierarchy

  GObject
   +----UnityGtkActionGroup

Implemented Interfaces

UnityGtkActionGroup implements GActionGroup.

Description

A UnityGtkActionGroup is a GActionGroup that accumulates the actions of multiple UnityGtkMenuShells into a single object. This can be used for purposes such as exporting actions over DBus with g_dbus_connection_export_action_group().

Details

struct UnityGtkActionGroup

struct UnityGtkActionGroup;

Opaque action group collector for UnityGtkMenuShell.


UnityGtkActionGroupClass

typedef GObjectClass                UnityGtkActionGroupClass;

unity_gtk_action_group_new ()

UnityGtkActionGroup * unity_gtk_action_group_new        (GActionGroup *old_group);

Creates a new UnityGtkMenuShell based on the contents of the given menu_shell. Any subsequent changes to menu_shell are reflected in the returned UnityGtkMenuShell.

Actions not found in an attached UnityGtkMenuShell are queried in old_group before failing.

old_group :

a fallback GActionGroup.

Returns :

a new UnityGtkActionGroup.

unity_gtk_action_group_connect_shell ()

void                unity_gtk_action_group_connect_shell
                                                        (UnityGtkActionGroup *group,
                                                         UnityGtkMenuShell *shell);

Creates actions for all menu items in shell and adds them to group. Subsequent changes to shell also affect group.

group :

a UnityGtkActionGroup.

shell :

a UnityGtkMenuShell.

unity_gtk_action_group_disconnect_shell ()

void                unity_gtk_action_group_disconnect_shell
                                                        (UnityGtkActionGroup *group,
                                                         UnityGtkMenuShell *shell);

Removes the actions for shell from group.

group :

a UnityGtkActionGroup.

shell :

a UnityGtkMenuShell.

unity_gtk_action_group_set_debug ()

void                unity_gtk_action_group_set_debug    (gboolean debug);

Sets if action group changes should be logged using g_print().

debug :

TRUE to enable debugging output