nvdweem/PCPanel

[Toggle Device] Can't drag a sound device

Closed this issue · 5 comments

Hi!

I'm unable to drag and drop or double clic a sound device in the "Toggle Device" section.
image

My use of this feature is to switch between Speakers and Headset on a single Knob press.

Thanks for your hard work!

This should now be fixed. The 1.4-SNAPSHOT installer should be updated already.

Drag and drop is now working 👍🏻, but the actual action of switching between devices doesn't work on knob clic.

Here is the message I get in the log file :
2022-06-18 21:49:41.099 ERROR 3236 --- [Command Handler Thread] c.g.c.c.CommandVolumeDefaultDeviceToggle : TODO

I guess it has to do with this :

I probably should have actually tested. The functionality instead of just the drag and drop :)
I'll look into fixing the Todo tomorrow. Might be a good moment to check if I put more todos in the code ;)

The todo should now be implemented. I've tried to make it a bit smarter than just having a fixed order. If you manually change the output device (or do so through another button action) the order will continue from the current default device.

I also changed the UI a bit. I don't think it makes sense to combine input and output devices in the list so the list disables the output devices if you select an input device and the other way around. If this assumption is wrong please let me know because it will also mean that following the current default device can't be done because there would be multiple default devices :).

It works perfectly well, thanks a lot! 🥇