private void selectAlbum() {
        Album.album(this)
                .multipleChoice()
                .filterMimeType(new Filter<String>() { // MimeType of File.
                    @Override
                    public boolean filter(String attributes) {
                        // MimeType: image/jpeg, image/png, video/mp4, video/3gp...
                        return attributes.contains("jpeg");
                    }
                })
                // .filterSize() // File size.
                // .filterDuration() // Video duration.
                .afterFilterVisibility(mAfterFilterVisibility)
                .columnCount(2)
                .selectCount(6)
                .camera(true)
                .checkedList(mAlbumFiles)
                .widget(
                        Widget.newDarkBuilder(this)
                                .title(mToolbar.getTitle().toString())
                                .build()
                )
                .onResult(new Action<ArrayList<AlbumFile>>() {
                    @Override
                    public void onAction(@NonNull ArrayList<AlbumFile> result) {
                        mAlbumFiles = result;
                        mAdapter.notifyDataSetChanged(mAlbumFiles);
                        mTvMessage.setVisibility(result.size() > 0 ? View.VISIBLE : View.GONE);
                    }
                })
                .onCancel(new Action<String>() {
                    @Override
                    public void onAction(@NonNull String result) {
                        Toast.makeText(AlbumFilterActivity.this, R.string.canceled, Toast.LENGTH_LONG).show();
                    }
                })
                .start();
    }
private void selectAlbum ( ) { Album . album ( this ) . multipleChoice ( ) . filterMimeType ( new Filter < String > ( ) { @ Override public boolean filter ( String attributes ) { return attributes . contains ( "jpeg" ) ; } } ) . afterFilterVisibility ( mAfterFilterVisibility ) . columnCount ( 2 ) . selectCount ( 6 ) . camera ( true ) . checkedList ( mAlbumFiles ) . widget ( Widget . newDarkBuilder ( this ) . title ( mToolbar . getTitle ( ) . toString ( ) ) . build ( ) ) . onResult ( new Action < ArrayList < AlbumFile > > ( ) { @ Override public void onAction ( @ NonNull ArrayList < AlbumFile > result ) { mAlbumFiles = result ; mAdapter . notifyDataSetChanged ( mAlbumFiles ) ; mTvMessage . setVisibility ( result . size ( ) > 0 ? View . VISIBLE : View . GONE ) ; } } ) . onCancel ( new Action < String > ( ) { @ Override public void onAction ( @ NonNull String result ) { Toast . makeText ( AlbumFilterActivity . this , R . string . canceled , Toast . LENGTH_LONG ) . show ( ) ; } } ) . start ( ) ; }
Select picture, from album.