Android - прокрутка / прокрутка NumberPicker быстрее

Как я могу ускорить прокрутку/перелистывание средства выбора номера? В настоящее время требуется так много усилий, чтобы перейти от 00 минут к 59 минутам. Я пробовал пример из Замедление скорости контроллера Viewpager в андроиде и применено напротив него к выбору чисел, но я не вижу никакой разницы.

введите здесь описание изображения

try {
        Field mScroller;
        mScroller = NumberPicker.class.getDeclaredField("mFlingScroller");
        mScroller.setAccessible(true);
        FixedSpeedScroller scroller = new FixedSpeedScroller(getContext(),null,true);

        // scroller.setFixedDuration(5000);
        // scrollBy(0,1500);

        Log.v("Scroller",""+mScroller); //getting the mFlingScroller field
        mScroller.set(this, scroller);

    } catch (NoSuchFieldException | IllegalArgumentException | IllegalAccessException e) {
        e.printStackTrace();
    }

public class FixedSpeedScroller extends Scroller {

    private int mDuration = 10;

    public FixedSpeedScroller(Context context) {
        super(context);
    }

    public FixedSpeedScroller(Context context, Interpolator interpolator) {
        super(context, interpolator);
    }

    public FixedSpeedScroller(Context context, Interpolator interpolator, boolean flywheel) {
        super(context, interpolator, flywheel);
    }


    @Override
    public void startScroll(int startX, int startY, int dx, int dy, int duration) {
        // Ignore received duration, use fixed one instead
        super.startScroll(startX, startY, dx, dy, mDuration);
    }

    @Override
    public void startScroll(int startX, int startY, int dx, int dy) {
        // Ignore received duration, use fixed one instead
        super.startScroll(startX, startY, dx, dy, mDuration);
    }
}

Я уменьшил mDuration до значения ниже примера (5000). Но все равно без надежды. Некоторая помощь будет принята с благодарностью. Заранее спасибо!!! :)


person Alex    schedule 01.08.2016    source источник
comment
Кстати, в итоге я использовал эту библиотеку github.com/Carbs0126/NumberPickerView.   -  person Alex    schedule 31.12.2016
comment
в этой библиотеке текст редактирования недоступен   -  person Rajesh Nasit    schedule 12.10.2017
comment
@RajeshNasit - ну, все дело в том, что вы выбираете здесь число / строку.   -  person Alex    schedule 12.10.2017
comment
Вы правы, но я тоже хочу нажать, чтобы отредактировать   -  person Rajesh Nasit    schedule 12.10.2017