I was working on a project and had my Activities passing each other information via Intents. However, I recently decided to swithc and go with the Singleton method and have an Application class holding all of my data.
I’m now a little confused: how do I start my Activities without Intents? This is a call I had before I switched…
public boolean onOptionsItemSelected( MenuItem item ) {
switch( item.getItemId() ) {
case R.id.connect:
startActivityForResult( new Intent( this, DeviceList.class ), REQUEST_CONNECT_DEVICE );
return true;
What would I change it to to start the DeviceList class without the use of intents?
You don’t. Use intents to start your activities. This is how Android is designed.