Code example for FragmentActivity

Methods: onOptionsItemSelected

0
		if (item.getItemId() == android.R.id.home) {
			NavUtils.navigateUpTo(this, new Intent(this, ListActivity.class));
			return true; 
		} 
 
		return super.onOptionsItemSelected(item);
	} 
 
	@Override 
	public Loader<Cursor> onCreateLoader(int id, Bundle bundle) {
		long listId = getIntent().getLongExtra(TasksListFragment.LIST_ID, -1);
		if(listId != -1) {
			return new CursorLoader(this, 
					CheddarContentProvider.Lists.CONTENT_URI,  
					new String[]{CheddarContentProvider.Lists.LIST_TITLE}, 
					CheddarContentProvider.Lists.LIST_ID + "=?",  
					new String[]{String.valueOf(listId)}, 
					null); 
		} 
		return null; 
	}