ajwalkiewicz / SoundPad

Simple desktop sound pad
MIT License
7 stars 0 forks source link

Feature request: Keybind for stopping all audio? #10

Closed olehj closed 11 months ago

olehj commented 1 year ago

Use maybe KP_0 for "STOP ALL"? Or press the same key to stop (will ruin the insta-spamming). But having it stopping in the background would be nice :P

ajwalkiewicz commented 1 year ago

Hi, using KP_0 to stop everything, sounds good for me. I think I was considering that option, but I don't remember why I abandoned that idea. I'll re-consider it again :D

olehj commented 1 year ago

Haha cool. Any possibilities to distinguish the numpad with the numbers above the letters? At least in linux they pad gets triggered on both for some reason.

ajwalkiewicz commented 1 year ago

@olehj, What do you think of binding KP_0 to PAUSE ALL instead of STOP ALL? I started to experiment with that, and in my opinion using pause would be much more useful as you could pause/un-pause all sounds with a single key. With stop all button, user needs to play again all sounds if he want's to return to the previous state.

Regarding your question about numpad, after initial googling I think that might required more changes, so please create another issue for that, and I'll investigate it. In a mean time, you can experiment with different key range setting: You can edit settings.json:

{
    "default_directory": "samples",
    "key_range": "system_wide",
    "font_type": "Helvetica",
    "font_size": 10,
    "show_settings": false,
    "fadeout_length": 3000,
    "on_top": true
}

And change key_range value to inside_app. This way only numpad keys will be working. Disadvantage of this is that keys will also be working only when focus is on soundpad app.

olehj commented 1 year ago

Maybe add an option if keypad 0 is to pause all or stop all? I prefer stop all by personal preferences, but having it configurable would be awesome, shouldn't be too hard to add into the settings.json?

ajwalkiewicz commented 1 year ago

Yeah, that sounds like a good feature, I'll do that :)

ajwalkiewicz commented 1 year ago

Hi @olehj , would you like to test requested change?

You would need to run:

git pull
git checkout 10-feature-request-keybind-for-stopping-all-audio

And then run app normally.

Ah, and I set default behavior to pause, but you can change it in settings.json to stop. It should work then the way you requested.

olehj commented 8 months ago

Cool! I'll check this out one time in the future, been quite busy with shit. But thanks!