-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathservices.h
More file actions
40 lines (31 loc) · 1.24 KB
/
Copy pathservices.h
File metadata and controls
40 lines (31 loc) · 1.24 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
#ifndef TINYWL_SERVICES_H
#define TINYWL_SERVICES_H
#include <sys/types.h>
#include <stdbool.h>
struct tinywl_server;
struct wlr_backend;
struct wlr_xwayland;
struct tinywl_services;
struct tinywl_services *tinywl_services_init(struct tinywl_server *server);
void tinywl_services_destroy(struct tinywl_services *svc);
/*
* Reap only child PIDs we recorded ourselves; other subsystems
* (e.g. wlroots' Xwayland) reap their own, and a blanket wait would steal that from them.
*/
void tinywl_services_try_reap(struct tinywl_services *svc);
/*
* Register an ad-hoc forked child (menu launches, screenshot helper)
* so tinywl_services_try_reap() reaps it too, instead of leaving a zombie.
*/
void tinywl_services_track_pid(struct tinywl_services *svc, pid_t pid, const char *name);
/*
* True if `backend` is (or, wrapped in a multi-backend, contains)
* a nested X11/Wayland backend rather than real DRM/KMS.
*/
bool tinywl_backend_is_nested(struct wlr_backend *backend);
/* Returns the wlr_xwayland instance owned by these services (or NULL if
* XWayland isn't running), so the caller can hook its own listeners
* (e.g. events.new_surface) onto it.
*/
struct wlr_xwayland *tinywl_services_get_xwayland(struct tinywl_services *svc);
#endif