Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public void getTutorialByID(View v)
- {
- Button cbPressed = (Button)v;
- open(GetTutorialActivity.class, cbPressed.getText().toString());
- }
- private <T extends Activity> void open(Class<T> activity, String cbPressedText)
- {
- Intent intentActivity = new Intent(this, activity);
- intentActivity.setAction(cbPressedText);
- startActivity(intentActivity);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement