summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorkotontrion <[email protected]>2024-06-15 13:17:54 +0200
committerkotontrion <[email protected]>2024-06-15 13:17:54 +0200
commit637875607f230ab7bd45d05db685323f568900f9 (patch)
tree99a35bf3ba7b89d73fbea2ef637604584a9dd2a5 /include
parent23b9314788d9f2c9f16a0daf1517bfd899243f54 (diff)
add river-control-unstable-v1 support
Diffstat (limited to 'include')
-rw-r--r--include/river.h19
1 files changed, 19 insertions, 0 deletions
diff --git a/include/river.h b/include/river.h
index 881ca75..7e2bd59 100644
--- a/include/river.h
+++ b/include/river.h
@@ -132,6 +132,25 @@ gchar* astal_river_river_get_focused_output(AstalRiverRiver *self);
gchar* astal_river_river_get_mode(AstalRiverRiver *self);
+/**
+ * AstalRiverCommandCallback:
+ * @success: a #gboolean.
+ * @msg: a string.
+ *
+ * A callback function that gets a #GObject, a #gboolean, and a string.
+ */
+typedef void (*AstalRiverCommandCallback)(gboolean success, const gchar *msg);
+
+/**
+ * astal_river_river_run_command_async:
+ * @self: the AstalRiverRiver object
+ * @length: the length of the cmd array
+ * @cmd: (array length=length): the command to execute
+ * @callback: (scope async) (nullable): the callback to invoke.
+ *
+ * Calls the given callback with the provided parameters.
+ */
+void astal_river_river_run_command_async(AstalRiverRiver *self, gint length, const gchar **cmd, AstalRiverCommandCallback callback);