fn combine_idle(
primary: Result<u64, String>,
fallback: impl FnOnce() -> Option<u64>,
) -> Result<u64, String>Expand description
Resolve the primary reading against the platform fallback: the primary
value wins; on primary failure the injected fallback is consulted and,
if it too has nothing, the primary error is surfaced. The fallback is a
closure so this decision is pure and unit-testable on every OS without
touching a windowing system — only the two FFI sources it’s wired to in
idle_secs stay platform-bound.