Open maberer opened 8 years ago
you could do this
Set this on the view you want to be clickable
android:onClick="firstNameClickHandler"
android:tag="@{user}" // the viewmodel variable
and then in your activity
public void firstNameClickHandler(View v) {
UserViewModel userViewModel = (UserViewModel)v.getTag();
}
How can we detect, if a "firstName" or "lastName" is clicked? So generally: How can we detect which item has been clicked within a row item? This should consider CompositeItemBinder with different item types...
I am thinking about having
"firstNameClickHandler()" "lastNameClickHandler()"
in the activity?