| | |
| | | import android.widget.CheckBox;
|
| | | import android.widget.CompoundButton;
|
| | | import android.widget.RadioButton;
|
| | | import android.widget.RelativeLayout;
|
| | | import android.widget.TextView;
|
| | |
|
| | | import com.bsk.zhangbo.demoforbsk.R;
|
| | |
| | | fragment_visit_left_person_row_check_box.setOnCheckedChangeListener(new CompoundButton.OnCheckedChangeListener() {
|
| | | @Override
|
| | | public void onCheckedChanged(CompoundButton buttonView, boolean isChecked) {
|
| | | // if (lastRadioButton != null && lastRadioButton != fragment_visit_left_person_row_check_box) {
|
| | | // lastRadioButton.setChecked(false);
|
| | | // }
|
| | | // lastRadioButton = fragment_visit_left_person_row_check_box;
|
| | | // if (isChecked) {
|
| | | // cn.com.basic.face.fragment.VisitFragment.getInstance().setVisitInfo(item);
|
| | | // lastIndex = position;
|
| | | // }
|
| | | }
|
| | | });
|
| | | RelativeLayout fragment_visit_left_relative_layout = viewHolder.findViewById(R.id.fragment_visit_left_relative_layout);
|
| | | fragment_visit_left_relative_layout.setOnClickListener(new View.OnClickListener() {
|
| | | @Override
|
| | | public void onClick(View v) {
|
| | | if (lastRadioButton != null && lastRadioButton != fragment_visit_left_person_row_check_box) {
|
| | | lastRadioButton.setChecked(false);
|
| | | }
|
| | | lastRadioButton = fragment_visit_left_person_row_check_box;
|
| | | if (isChecked) {
|
| | | cn.com.basic.face.fragment.VisitFragment.getInstance().setVisitInfo(item);
|
| | | lastIndex = position;
|
| | | }
|
| | | cn.com.basic.face.fragment.VisitFragment.getInstance().setVisitInfo(item);
|
| | | lastIndex = position;
|
| | | fragment_visit_left_person_row_check_box.setChecked(true);
|
| | | }
|
| | | });
|
| | |
|
| | |
|
| | | fragment_visit_left_person_row_check_box.setChecked(false);
|
| | |
|
| | | if (lastIndex == position) {
|