Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

怎么给联系人绑点击事件 #1

Closed
tinybright opened this issue Mar 18, 2016 · 2 comments
Closed

怎么给联系人绑点击事件 #1

tinybright opened this issue Mar 18, 2016 · 2 comments

Comments

@tinybright
Copy link

No description provided.

@jiang111
Copy link
Owner

和普通的recyclerview绑定事件写法一样的,例如在onBindViewHolder的方法里这么写:
swipeRoot.setOnClickListener(new View.OnClickListener() {
@OverRide
public void onClick(View v) {
Toast.makeText(v.getContext(), "你点击了" + position, Toast.LENGTH_SHORT).show();
}
});

@tinybright
Copy link
Author

我忘记Toast.show()了

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants