Name Chrome streams after their browser tabs
A browser extension reports audible tabs to moonmix-tabs-host, which matches them to PipeWire streams by time and publishes the names for the mixer; streams of one tab share a row. Ambiguous streams keep the browser's name. Without the extension, a browser's only running stream shows its MPRIS title. The smoke test no longer claims real audio hardware. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
b61d504234
commit
e16cc1b2ad
31 files changed
+1830
-15
No files matched your search
@@ -35,6 +35,9 @@ fn print_state(state : @model.State) -> Unit {
|
||||
flags.push("-> " + r.choices[r.current_choice].label)
|
||||
}
|
||||
let vol = if r.has_volume { r.volume_text } else { "(no volume)" }
|
||||
if r.members.length() > 1 {
|
||||
flags.push("\{r.members.length()} streams")
|
||||
}
|
||||
let f = if flags.length() > 0 {
|
||||
" [" + flags.join(", ") + "]"
|
||||
} else {
|
||||
@@ -110,6 +113,8 @@ fn main {
|
||||
// default-nodes-api reports defaults shortly after Ready: settle first.
|
||||
Ready => @wp.timeout(300, 2)
|
||||
Timeout(2) => {
|
||||
let names = @model.merge_tab_files(@tabs.files())
|
||||
let _ = state.apply(TabNames(names))
|
||||
print_state(state)
|
||||
if args is ["meter", id] {
|
||||
let id = resolve(state, id)
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
// Headless probe: prints what each tab shows, can apply one action.
|
||||
import {
|
||||
"geordi/moonmix/model",
|
||||
"geordi/moonmix/tabs",
|
||||
"geordi/moonmix/wp",
|
||||
"moonbitlang/core/env",
|
||||
"moonbitlang/core/string",
|
||||
|
||||
Reference in new issue
Block a user