In my activity I have many buttons that launch other activities. The problem is that when I press a button I don’t want to be able to press another, and so to launch 2 activities (or more). What is the best solution to block the other views (buttons) after one of them was pressed?
Share
Add one
onClickListener()for all buttons. In listener switch the actions as per id.Don’t forget to enable all buttons in
onResume()OR, Try This to enable/disable all views in a viewGroup…
Pass the
viewparameter as the parent layout containing all buttons.I haven’t used this, but this should work. Try playing around this code.