Inside, the setValue method is called. You can try to catch an event when the user moves the handle of the slider by implementing ChangeListener to capture this event. Also, remember that moving the handle causes a lot of event changes, so if you are interested in the final value of the slider, use getValueIsAdjusting when it evaluates to false .
If the problem is related to ChangeListener , try extending the JSlider component and add a new method that gets a new AND value that returns it (for example, using int code or an enumeration), getting the value set up after you create your own logic for the real method setValue.
In your case, you want to prevent invokation setValue if some component calls it, if I'm not mistaken.
source share