From e7bede5f6ec798a24bcdd952829d52d4695b5349 Mon Sep 17 00:00:00 2001 From: subalterngames Date: Sun, 7 Jan 2024 12:36:38 -0500 Subject: [PATCH] Fixed PlayStop input bug --- Cargo.lock | 14 +++++++------- Cargo.toml | 6 +++--- audio/src/conn.rs | 2 +- changelog.md | 4 ++++ 4 files changed, 15 insertions(+), 11 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index b5884cd..f0c038b 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -105,7 +105,7 @@ dependencies = [ [[package]] name = "audio" -version = "0.2.1" +version = "0.2.2" dependencies = [ "chrono", "common", @@ -238,7 +238,7 @@ checksum = "89b2fd2a0dcf38d7971e2194b6b6eebab45ae01067456a7fd93d5547a61b70be" [[package]] name = "cacophony" -version = "0.2.1" +version = "0.2.2" dependencies = [ "audio", "clap", @@ -396,7 +396,7 @@ dependencies = [ [[package]] name = "common" -version = "0.2.1" +version = "0.2.2" dependencies = [ "clap", "directories", @@ -1008,7 +1008,7 @@ dependencies = [ [[package]] name = "input" -version = "0.2.1" +version = "0.2.2" dependencies = [ "clap", "common", @@ -1034,7 +1034,7 @@ dependencies = [ [[package]] name = "io" -version = "0.2.1" +version = "0.2.2" dependencies = [ "audio", "common", @@ -1880,7 +1880,7 @@ checksum = "e5ea92a5b6195c6ef2a0295ea818b312502c6fc94dde986c5553242e18fd4ce2" [[package]] name = "render" -version = "0.2.1" +version = "0.2.2" dependencies = [ "audio", "colorgrad", @@ -2211,7 +2211,7 @@ dependencies = [ [[package]] name = "text" -version = "0.2.1" +version = "0.2.2" dependencies = [ "common", "csv", diff --git a/Cargo.toml b/Cargo.toml index 079cc7a..394da54 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -2,7 +2,7 @@ members = ["audio", "common", "input", "io", "render", "text"] [workspace.package] -version = "0.2.1" +version = "0.2.2" authors = ["Esther Alter "] description = "A minimalist and ergonomic MIDI sequencer" documentation = "https://github.com/subalterngames/cacophony" @@ -86,7 +86,7 @@ speech_dispatcher_0_9 = ["text/speech_dispatcher_0_9"] [package] name = "cacophony" -version = "0.2.1" +version = "0.2.2" authors = ["Esther Alter "] description = "A minimalist and ergonomic MIDI sequencer" documentation = "https://github.com/subalterngames/cacophony" @@ -122,7 +122,7 @@ path = "text" name = "Cacophony" identifier = "com.subalterngames.cacophony" icon = ["icon/32.png", "icon/64.png", "icon/128.png", "icon/256.png"] -version = "0.2.1" +version = "0.2.2" resources = ["data/*"] copyright = "Copyright (c) Subaltern Games LLC 2023. All rights reserved." short_description = "A minimalist and ergonomic MIDI sequencer." diff --git a/audio/src/conn.rs b/audio/src/conn.rs index e4921c2..f460103 100644 --- a/audio/src/conn.rs +++ b/audio/src/conn.rs @@ -219,7 +219,7 @@ impl Conn { pub fn set_music(&mut self, state: &State) { let play_state = *self.play_state.lock(); match play_state { - PlayState::NotPlaying => self.start_music(state), + PlayState::NotPlaying | PlayState::Decaying => self.start_music(state), _ => self.stop_music(&state.music), } } diff --git a/changelog.md b/changelog.md index 949153c..baa09ae 100644 --- a/changelog.md +++ b/changelog.md @@ -1,5 +1,9 @@ # 0.2.x +## 0.2.2 + +- There was an input bug where the play/start key (spacebar) was sometimes unresponsive for the first few presses. This is because audio was still decaying from a previous play, meaning that technically the previous play was still ongoing. I fixed it. + ## 0.2.1 - I replaced the default qwerty bindings for note input with a more "standard" layout. This information is stored in config.ini, so if you want the update, make sure to delete Documents/cacophony/config.ini if it exists (Cacophony will use the default data/config.ini instead).