Method

GioActionGroupget_action_state

Declaration

GVariant*
g_action_group_get_action_state (
  GActionGroup* action_group,
  const gchar* action_name
)

Description

Queries the current state of the named action within action_group.

If the action is not stateful then NULL will be returned. If the action is stateful then the type of the return value is the type given by g_action_group_get_action_state_type().

The return value (if non-NULL) should be freed with g_variant_unref() when it is no longer required.

Available since:2.28

Parameters

action_name const gchar*
 

The name of the action to query.

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

Return value

Returns: GVariant
 

The current state of the action.

 The caller of the method takes ownership of the data, and is responsible for freeing it.
 The return value can be NULL.