Merge "When click conditional's title, expand/collapse content." into nyc-mr1-dev

This commit is contained in:
TreeHugger Robot
2016-08-22 20:01:16 +00:00
committed by Android (Google) Code Review
2 changed files with 8 additions and 9 deletions

View File

@@ -68,12 +68,13 @@ public class ConditionAdapterUtils {
card.setOnClickListener(onClickListener);
view.icon.setImageIcon(condition.getIcon());
view.title.setText(condition.getTitle());
ImageView expand = (ImageView) view.itemView.findViewById(R.id.expand_indicator);
expand.setTag(condition);
final View collapsedGroup = view.itemView.findViewById(R.id.collapsed_group);
collapsedGroup.setTag(condition);
final ImageView expand = (ImageView) view.itemView.findViewById(R.id.expand_indicator);
expand.setImageResource(isExpanded ? R.drawable.ic_expand_less : R.drawable.ic_expand_more);
expand.setContentDescription(expand.getContext().getString(isExpanded
? R.string.condition_expand_hide : R.string.condition_expand_show));
expand.setOnClickListener(onExpandListener);
collapsedGroup.setOnClickListener(onExpandListener);
View detailGroup = view.itemView.findViewById(R.id.detail_group);
CharSequence[] actions = condition.getActions();