Source:
private void getRowViewForLeaf(ViewHolder viewHolder, final SectionRow row) { final CourseComponent unit = row.component; viewHolder.rowType.setVisibility(View.VISIBLE); viewHolder.rowSubtitleIcon.setVisibility(View.GONE); viewHolder.rowSubtitleDueDate.setVisibility(View.GONE); viewHolder.rowSubtitle.setVisibility(View.GONE); viewHolder.rowSubtitlePanel.setVisibility(View.GONE); viewHolder.bulkDownload.setVisibility(View.INVISIBLE); viewHolder.rowTitle.setText(unit.getDisplayName()); if (row.component instanceof VideoBlockModel) { final VideoBlockModel videoBlockModel = (VideoBlockModel) row.component; final DownloadEntry videoData = videoBlockModel.getDownloadEntry(storage); if (null != videoData) { updateUIForVideo(viewHolder, videoData, videoBlockModel); return; } } if (config.isDiscussionsEnabled() && row.component instanceof DiscussionBlockModel) { viewHolder.rowType.setIcon(FontAwesomeIcons.fa_comments_o); checkAccessStatus(viewHolder, unit); } else if (!unit.isMultiDevice()) { viewHolder.bulkDownload.setVisibility(View.INVISIBLE); viewHolder.rowType.setIcon(FontAwesomeIcons.fa_laptop); viewHolder.rowType.setIconColorResource(R.color.edx_brand_gray_accent); } else { viewHolder.bulkDownload.setVisibility(View.INVISIBLE); if (unit.getType() == BlockType.PROBLEM) { viewHolder.rowType.setIcon(FontAwesomeIcons.fa_list); } else { viewHolder.rowType.setIcon(FontAwesomeIcons.fa_book); } if (row.component.getAuthorizationDenialReason() == AuthorizationDenialReason.FEATURE_BASED_ENROLLMENTS) { viewHolder.rowSubtitle.setText(R.string.not_available_on_mobile); viewHolder.rowType.setIconColorResource(R.color.edx_brand_gray_accent); viewHolder.rowSubtitlePanel.setVisibility(View.VISIBLE); viewHolder.rowSubtitle.setVisibility(View.VISIBLE); } else { checkAccessStatus(viewHolder, unit); } } }

Target:
private void getRowViewForLeaf(ViewHolder viewHolder, final SectionRow row) { final CourseComponent unit = row.component; viewHolder.rowType.setVisibility(View.VISIBLE); viewHolder.rowSubtitleIcon.setVisibility(View.GONE); viewHolder.rowSubtitleDueDate.setVisibility(View.GONE); viewHolder.rowSubtitle.setVisibility(View.GONE); viewHolder.rowSubtitlePanel.setVisibility(View.GONE); viewHolder.bulkDownload.setVisibility(View.INVISIBLE); viewHolder.rowTitle.setText(unit.getDisplayName()); boolean isDenialFeatureBasedEnrolments = row.component.getAuthorizationDenialReason() == AuthorizationDenialReason.FEATURE_BASED_ENROLLMENTS; if (row.component instanceof VideoBlockModel) { final VideoBlockModel videoBlockModel = (VideoBlockModel) row.component; final DownloadEntry videoData = videoBlockModel.getDownloadEntry(storage); if (null != videoData) { updateUIForVideo(viewHolder, videoData, videoBlockModel); } } else if (config.isDiscussionsEnabled() && row.component instanceof DiscussionBlockModel) { viewHolder.rowType.setIcon(FontAwesomeIcons.fa_comments_o); checkAccessStatus(isDenialFeatureBasedEnrolments, viewHolder, unit); } else if (!unit.isMultiDevice()) { viewHolder.bulkDownload.setVisibility(View.INVISIBLE); viewHolder.rowType.setIcon(FontAwesomeIcons.fa_laptop); viewHolder.rowType.setIconColorResource(R.color.edx_brand_gray_accent); } else { viewHolder.bulkDownload.setVisibility(View.INVISIBLE); if (unit.getType() == BlockType.PROBLEM) { viewHolder.rowType.setIcon(FontAwesomeIcons.fa_list); } else { viewHolder.rowType.setIcon(FontAwesomeIcons.fa_book); } checkAccessStatus(isDenialFeatureBasedEnrolments, viewHolder, unit); } if (isDenialFeatureBasedEnrolments) { viewHolder.rowSubtitle.setText(R.string.not_available_on_mobile); viewHolder.rowType.setIconColorResource(R.color.edx_brand_gray_accent); viewHolder.rowSubtitlePanel.setVisibility(View.VISIBLE); viewHolder.rowSubtitle.setVisibility(View.VISIBLE); } }