Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- final RadioButton[] buttons = {radio_books,radio_games,radio_dvds,radio_electronics};
- for (RadioButton this_button : buttons) {
- this_button.setOnClickListener(new OnClickListener() {
- @Override
- public void onClick(View v) {
- for (RadioButton button : buttons) {
- if ((RadioButton)v != button) {
- button.setChecked(false);
- }
- }
- }
- });
- }
Add Comment
Please, Sign In to add comment