use of com.mindorks.framework.mvvm.ui.main.QuestionCard in project android-mvvm-architecture by MindorksOpenSource.
the class BindingUtils method addQuestionItems.
@BindingAdapter({ "adapter", "action" })
public static void addQuestionItems(SwipePlaceHolderView mCardsContainerView, List<QuestionCardData> mQuestionList, int mAction) {
if (mAction == MainViewModel.ACTION_ADD_ALL) {
if (mQuestionList != null) {
mCardsContainerView.removeAllViews();
for (QuestionCardData question : mQuestionList) {
if (question != null && question.options != null && question.options.size() == 3) {
mCardsContainerView.addView(new QuestionCard(question));
}
}
ViewAnimationUtils.scaleAnimateView(mCardsContainerView);
}
}
}
Aggregations