private void appendComment(BotAdapter.Type type, String comment) { botAdapter.addItem(type, comment); botAdapter.setAnimationsLocked(false); botAdapter.setDelayEnterAnimation(false); if (rvComments.getChildCount() > 0) { rvComments.smoothScrollBy( 0, rvComments.getChildAt(0).getHeight() * botAdapter.getItemCount()); } }
private void animateContent() { botAdapter.updateItems(); llAddComment .animate() .translationY(0) .setInterpolator(new DecelerateInterpolator()) .setDuration(200) .start(); }