available (possibly NULL though) if it wants it.
*/
+typedef enum
+{
+ OB_CLIENT_ACTION_NO,
+ OB_CLIENT_ACTION_OPTIONAL,
+ OB_CLIENT_ACTION_ALWAYS
+} ObClientActionReq;
+
struct AnyAction {
+ ObClientActionReq client_action;
struct _ObClient *c;
ObFrameContext context;
gboolean interactive;
struct InterDirectionalAction{
struct InteractiveAction inter;
ObDirection direction;
+ gboolean dialog;
};
struct DirectionalAction{
};
struct Desktop {
- struct AnyAction any;
+ struct InteractiveAction inter;
guint desk;
};
struct InteractiveAction inter;
gboolean linear;
gboolean forward;
+ gboolean dialog;
};
union ActionData {
};
struct _ObAction {
- ObUserAction act;
+ guint ref;
+
/* The func member acts like an enum to tell which one of the structs in
the data union are valid.
*/
action_resize_relative_vert - the delta
*/
-ObAction *action_from_string(const gchar *name, ObUserAction uact);
-ObAction *action_parse(ObParseInst *i, xmlDocPtr doc, xmlNodePtr node,
+ObAction* action_from_string(const gchar *name, ObUserAction uact);
+ObAction* action_parse(ObParseInst *i, xmlDocPtr doc, xmlNodePtr node,
ObUserAction uact);
-void action_free(ObAction *a);
+void action_ref(ObAction *a);
+void action_unref(ObAction *a);
+
+ObAction* action_copy(const ObAction *a);
/*! Executes a list of actions.
@param c The client associated with the action. Can be NULL.
#define action_run(a, c, s) \
action_run_list(a, c, OB_FRAME_CONTEXT_NONE, s, 0, -1, -1, FALSE, FALSE)
+void action_run_string(const gchar *name, struct _ObClient *c);
+
/* Execute */
void action_execute(union ActionData *data);
/* ActivateAction */