I'd like to scroll to the bottom of the RecyclerView list after loading the activity.
GENERIC_MESSAGE_LIST = (ArrayList) intent.getExtras().getParcelableArrayList(ConversationsAdapter.EXTRA_MESSAGE);
conversationView = (RecyclerView) findViewById(R.id.list_messages);
conversationView.setHasFixedSize(true);
conversationViewLayoutManager = new LinearLayoutManager(this);
conversationView.setLayoutManager(conversationViewLayoutManager);
conversationViewAdapter = new ConversationAdapter(GENERIC_MESSAGE_LIST, this);
conversationView.setAdapter(conversationViewAdapter);
conversationView.scrollTo(...)
throws an exception about being not supported in RecyclerView, and conversationView.scrollToPosition(...)
doesn't seem to do anything.
After the above block of code, I added
conversationView.scrollToPosition(GENERIC_MESSAGE_LIST.size() + 1)
which doesn't work. There are 30 elements in GENERIC_MESSAGE_LIST
.