M1: X11 active-window adapter + platform fallback
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,16 @@
|
||||
//go:build !linux
|
||||
|
||||
package evidence
|
||||
|
||||
import "context"
|
||||
|
||||
// NewSource returns a sensor that reports evidence permanently unavailable on
|
||||
// platforms without the X11 adapter.
|
||||
func NewSource() Source { return noopSource{} }
|
||||
|
||||
type noopSource struct{}
|
||||
|
||||
func (noopSource) Watch(ctx context.Context, onChange func(WindowSnapshot)) {
|
||||
onChange(WindowSnapshot{Health: EvidenceHealth{Available: false, Reason: "no active-window sensor on this platform"}})
|
||||
<-ctx.Done()
|
||||
}
|
||||
Reference in New Issue
Block a user