You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jun 9, 2020. It is now read-only.
I set a textview in section , then set a clicklistener of it so it can change its background when I click it. But after I scroll the list, I found that the section can't reserve its status. After the section get to the top of the list, or scroll down when section was on the top of the list, it turned to be the orign background color, pls help check this issue
The text was updated successfully, but these errors were encountered:
You can mark the textview state when onClick. Refresh the state in adapter getView()
For example:
public View getView(int position, View convertView, ViewGroup parent) {
switch(viewType) {
case HEADER_VIEW:
//init view
//refresh state
refreshState(state);
//set click event
textView.setOnClickListener(v -> {
//mark the state
int state = 1;
});
}
}
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
I set a textview in section , then set a clicklistener of it so it can change its background when I click it. But after I scroll the list, I found that the section can't reserve its status. After the section get to the top of the list, or scroll down when section was on the top of the list, it turned to be the orign background color, pls help check this issue
The text was updated successfully, but these errors were encountered: