There are times you might want to call a function when a slider changes in SwiftUI. I did this recently to send out the slider's value to another d...
For further actions, you may consider blocking this person and/or reporting abuse
Hello, I have a question:
How can I detect, when the user moves the slider if the value is incrementing or decrementing?
If the user moves up the slider I need to call a method (for instance: volume up)
If the user moves down the slider I need to call a method (for instance: volume down)
thanks!
Here the answer
forums.swift.org/t/how-can-i-detec...
Helped me a lot, but in "set:" it should be called either newVal or newValue.
Thanks for catching that! I'll update the post :)