Method

GioActionGroupget_action_state_type

since: 2.28

Declaration [src]

const GVariantType*
g_action_group_get_action_state_type (
  GActionGroup* action_group,
  const gchar* action_name
)

Description [src]

Queries the type of the state of the named action within action_group.

If the action is stateful then this function returns the GVariantType of the state. All calls to g_action_group_change_action_state() must give a GVariant of this type and g_action_group_get_action_state() will return a GVariant of the same type.

If the action is not stateful then this function will return NULL. In that case, g_action_group_get_action_state() will return NULL and you must not call g_action_group_change_action_state().

The state type of a particular action will never change but it is possible for an action to be removed and for a new action to be added with the same name but a different state type.

Available since: 2.28

Parameters

action_name

Type: const gchar*

The name of the action to query.

The data is owned by the caller of the method.
The value is a NUL terminated UTF-8 string.

Return value

Type: GVariantType

The state type, if the action is stateful.

The returned data is owned by the instance.
The return value can be NULL.