private void setProfileImage(final ActivityViewHolder holder, final ParcelableUser user) { if (mDisplayProfileImage) { mProfileImageLoader.displayProfileImage(holder.profile_image, user.profile_image_url); } else { holder.profile_image.setImageDrawable(null); } }
private void setUserProfileImages(final ActivityViewHolder holder, final ParcelableUser[] users) { final int length = users != null ? Math.min(holder.activity_profile_images.length, users.length) : 0; final boolean should_display_images = mDisplayProfileImage && length > 0; holder.activity_profile_image_container.setVisibility( should_display_images ? View.VISIBLE : View.GONE); if (!should_display_images) return; for (int i = 0; i < length; i++) { final ImageView activity_profile_image = holder.activity_profile_images[i]; final String profile_image_url = users[i].profile_image_url; mProfileImageLoader.displayProfileImage(activity_profile_image, profile_image_url); } }