mirror of
https://github.com/arabianq/pipewire-soundpad.git
synced 2026-04-28 14:31:23 +00:00
new feature: pause playback when GUI window is closed
This commit is contained in:
+7
-1
@@ -149,7 +149,13 @@ pub async fn run() -> Result<(), Box<dyn Error>> {
|
||||
Ok(Box::new(SoundpadGui::new(&cc.egui_ctx)))
|
||||
}),
|
||||
) {
|
||||
Ok(_) => Ok(()),
|
||||
Ok(_) => {
|
||||
let config = get_gui_config();
|
||||
if config.pause_on_exit {
|
||||
make_request_sync(Request::pause()).ok();
|
||||
}
|
||||
Ok(())
|
||||
}
|
||||
Err(e) => Err(e.into()),
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user