diff options
author | dec05eba <dec05eba@protonmail.com> | 2025-06-28 04:25:20 +0200 |
---|---|---|
committer | dec05eba <dec05eba@protonmail.com> | 2025-06-28 04:25:26 +0200 |
commit | b9537941c9eba041b7afc8b0f4256c73e35c2387 (patch) | |
tree | 84b650502b0a54ae173acfa9b3cf45d5089beb0e /dbus/dbus_impl.h | |
parent | 2290f0641c91317c4fd05f35d2c0cfc25fba2181 (diff) |
Restart portal capture if it's paused for 3 seconds or more (can happen if returning from lock screen)
Remove dbus server, no longer needed. Just run dbus code directly.
Diffstat (limited to 'dbus/dbus_impl.h')
-rw-r--r-- | dbus/dbus_impl.h | 37 |
1 files changed, 0 insertions, 37 deletions
diff --git a/dbus/dbus_impl.h b/dbus/dbus_impl.h deleted file mode 100644 index c3f0751..0000000 --- a/dbus/dbus_impl.h +++ /dev/null @@ -1,37 +0,0 @@ -#ifndef GSR_DBUS_H -#define GSR_DBUS_H - -#include "portal.h" -#include <stdbool.h> -#include <stdint.h> -#include <dbus/dbus.h> - -#define DBUS_RANDOM_STR_SIZE 16 - -typedef struct { - DBusConnection *con; - DBusError err; - char random_str[DBUS_RANDOM_STR_SIZE + 1]; - unsigned int handle_counter; - bool desktop_portal_rule_added; - uint32_t screencast_version; - char *screencast_restore_token; -} gsr_dbus; - -/* Blocking. TODO: Make non-blocking */ -bool gsr_dbus_init(gsr_dbus *self, const char *screencast_restore_token); -void gsr_dbus_deinit(gsr_dbus *self); - -/* The follow functions should be called in order to setup ScreenCast properly */ -/* These functions that return an int return the response status code */ -int gsr_dbus_screencast_create_session(gsr_dbus *self, char **session_handle); -/* - |capture_type| is a bitmask of gsr_portal_capture_type values. gsr_portal_capture_type values that are not supported by the desktop portal will be ignored. - |gsr_portal_cursor_mode| is a bitmask of gsr_portal_cursor_mode values. gsr_portal_cursor_mode values that are not supported will be ignored. -*/ -int gsr_dbus_screencast_select_sources(gsr_dbus *self, const char *session_handle, uint32_t capture_type, uint32_t cursor_mode); -int gsr_dbus_screencast_start(gsr_dbus *self, const char *session_handle, uint32_t *pipewire_node); -bool gsr_dbus_screencast_open_pipewire_remote(gsr_dbus *self, const char *session_handle, int *pipewire_fd); -const char* gsr_dbus_screencast_get_restore_token(gsr_dbus *self); - -#endif /* GSR_DBUS_H */ |