Commit graph

11 commits

Author SHA1 Message Date
Stephan Buys
ce0868582b tests: fix env guard and pipe read for tab dnd 2025-11-20 22:33:13 +01:00
Michael Aaron Murphy
8cf372c9b9
perf: inline public getters/setters, and use non-generic inner functions
To reduce compile-times and avoid some overhead to binary size, this will modify some of our
generic functions to use non-generic inner functions where possible. The inner functions are
marked carefully with `#[inline(never)]` to prevent being inlined by LLVM at their callsites

While looking for generic functions to optimize, I have also taken the opportunity to annotate
public non-generic getters and setters with `#[inline]` to ensure that LLVM will inline them
across crate boundaries. By default, only generic functions are automatically inlined, and
only when enabling fat LTO are constant functions reliably inlined across crate boundaries.
2025-03-21 13:31:34 +01:00
Jeremy Soller
e29ce0d4c1
Fix compilation with process feature on other Unixes 2025-03-19 12:27:21 -06:00
Ashley Wulber
337b80d4ca
feat: Tooltips and Better Surface Management 2025-03-14 16:56:21 +01:00
Ashley Wulber
c7edd37b03 cargo fmt 2025-03-12 23:40:31 +01:00
Vadim Khitrin
64ddcb3bf2 fix: Support Spawning Processes on macOS
Allow using pipe on macOS when attempting to spawn a process.
2025-03-10 16:22:23 +01:00
Ashley Wulber
57256e53e5 fix(process): wait on child to prevent zombie 2024-08-22 16:41:14 +02:00
Ian Douglas Scott
732c7aef5c Add smol implementation for spawn
Although this is used in apps that use `tokio`, if we're going to
support `smol`, this seems suboptimal to require.

This assumes the function will be called by a tokio executor if the
`tokio` feature is used. Otherwise it can be spawned from any executor.
That should be consistent with everything else.

This fails to compile without either the `tokio` or `smol` feature. This
seems reasonable, since `zbus` also fails to compile in that case.
2024-07-26 12:01:40 -07:00
Ian Douglas Scott
82fb781746 Use tokio to asynchronously read from pipe
Avoids either `spawn_blocking`, or potentially blocking call in an async
function (though it shouldn't block for long).
2024-07-26 12:01:40 -07:00
Ian Douglas Scott
fe035e37b0 Use rustix/libc instead of nix; use pipe to capture double-fork pid
`rustix` and `libc` are already in the dependency tree, and `rustix`
follows IO safety rules, so use those.

We can use a pipe to get the PID of the double-forked process.
2024-07-26 12:01:40 -07:00
Ashley Wulber
ef5b6fb44a feat: add helpers for getting and using activation tokens in applets
refactor(applet): connect to privileged socket if available

cleanup
2023-11-17 19:29:11 -05:00