car/src/main/java/androidx/car/app/CarListDialog.java
private void initializeScrollbar() {
        mScrollBarView = getWindow().findViewById(R.id.scrollbar);
        mScrollBarView.setDayNightStyle(DayNightStyle.ALWAYS_LIGHT);

        mScrollBarView.setPaginationListener(new PagedScrollBarView.PaginationListener() {
            @Override
            public void onPaginate(int direction) {
                switch (direction) {
                    case PagedScrollBarView.PaginationListener.PAGE_UP:
                        mList.pageUp();
                        break;
                    case PagedScrollBarView.PaginationListener.PAGE_DOWN:
                        mList.pageDown();
                        break;
                    default:
                        Log.e(TAG, "Unknown pagination direction (" + direction + ")");
                }
            }

            @Override
            public void onAlphaJump() {
            }
        });
    }
/**
     * Initializes the scrollbar that appears off the dialog. This scrollbar is not the one that
     * usually appears with the PagedListView, but mimics it in functionality.
     */
Initializes the scrollbar that appears off the dialog. This scrollbar is not the one that
usually appears with the PagedListView, but mimics it in functionality.
Initializes the scrollbar that appears off the dialog . This scrollbar is not the one that usually appears with the PagedListView but mimics it in functionality .
private void initializeScrollbar() {
        mScrollBarView = getWindow().findViewById(R.id.scrollbar);
        mScrollBarView.setDayNightStyle(DayNightStyle.ALWAYS_LIGHT);
        mScrollBarView.setPaginationListener(new PagedScrollBarView.PaginationListener() {
            @Override
            public void onPaginate(int direction) {
                switch (direction) {
                    case PagedScrollBarView.PaginationListener.PAGE_UP:
                        mList.pageUp();
                        break;
                    case PagedScrollBarView.PaginationListener.PAGE_DOWN:
                        mList.pageDown();
                        break;
                    default:
                        Log.e(TAG, "Unknown pagination direction (" + direction + ")");
                }
            }
            @Override
            public void onAlphaJump() {
            }
        });
    }
private void initializeScrollbar ( ) { mScrollBarView = getWindow ( ) . findViewById ( R . id . scrollbar ) ; mScrollBarView . setDayNightStyle ( DayNightStyle . ALWAYS_LIGHT ) ; mScrollBarView . setPaginationListener ( new PagedScrollBarView . PaginationListener ( ) { @ Override public void onPaginate ( int direction ) { switch ( direction ) { case PagedScrollBarView . PaginationListener . PAGE_UP : mList . pageUp ( ) ; break ; case PagedScrollBarView . PaginationListener . PAGE_DOWN : mList . pageDown ( ) ; break ; default : Log . e ( TAG , "Unknown pagination direction (" + direction + ")" ) ; } } @ Override public void onAlphaJump ( ) { } } ) ; }
Initializes the scrollbar that appears off the dialog.
Initializes the scrollbar that appears off the dialog .