File tree Expand file tree Collapse file tree
app/src/main/java/org/schabi/newpipe/player/helper Expand file tree Collapse file tree Original file line number Diff line number Diff line change 2727import org .schabi .newpipe .R ;
2828import org .schabi .newpipe .databinding .DialogPlaybackParameterBinding ;
2929import org .schabi .newpipe .player .Player ;
30+ import org .schabi .newpipe .util .SimpleOnSeekBarChangeListener ;
3031import org .schabi .newpipe .util .SliderStrategy ;
3132
3233import java .util .HashMap ;
3738import java .util .function .DoubleFunction ;
3839import java .util .function .DoubleSupplier ;
3940
41+ import javax .annotation .Nonnull ;
42+
4043import icepick .Icepick ;
4144import icepick .State ;
4245
@@ -493,25 +496,16 @@ private SeekBar.OnSeekBarChangeListener getTempoOrPitchSeekbarChangeListener(
493496 final SliderStrategy sliderStrategy ,
494497 final DoubleConsumer newValueConsumer
495498 ) {
496- return new SeekBar . OnSeekBarChangeListener () {
499+ return new SimpleOnSeekBarChangeListener () {
497500 @ Override
498- public void onProgressChanged (final SeekBar seekBar , final int progress ,
501+ public void onProgressChanged (@ Nonnull final SeekBar seekBar ,
502+ final int progress ,
499503 final boolean fromUser ) {
500504 if (fromUser ) { // ensure that the user triggered the change
501505 newValueConsumer .accept (sliderStrategy .valueOf (progress ));
502506 updateCallback ();
503507 }
504508 }
505-
506- @ Override
507- public void onStartTrackingTouch (final SeekBar seekBar ) {
508- // Do nothing
509- }
510-
511- @ Override
512- public void onStopTrackingTouch (final SeekBar seekBar ) {
513- // Do nothing
514- }
515509 };
516510 }
517511
You can’t perform that action at this time.
0 commit comments