Hi Guys,
Newbie here. Like Thanos, I’m cursed with knowledge:) Did quite a lot of basic programming back in the day (68000 - yes, I’m that old) so have some basic idea of how to do things, but not necessarily how to achieve them within Xojo.
So, I’m building a little music player based on AV Foundation. I can play a file, get its current position and I’m linking that to a slider that updates its position via a timer - then a gui refresh via a Thread.
So far, so good.
However, like in Spotify, I’d like the user to be able to move the slider to another position.
Currently, when you click it it will get interrupted by the timer and moved by itself.
So I want to interrupt the slider on a mouse down, allow the user to move it around, get the new position, and then continue playback (and the slider update) once the mouse Is up/released.
my thoughts so far:
-a Boolean for an ‘is mouse pressed’ flag, for when the user presses the mouse in the slider area
-the slider in the timer only updates itself when this boolean is false
My question: where do I do this? In the slider itself, on a mouse down event?