Code example for ActionMode

Methods: setTitle

0
 
	// from ActionMode.Callback 
	public boolean onCreateActionMode(ActionMode mode, Menu menu) 
	{ 
		Log.d("ScheduleFragment.onCreateActionMode", "creating an action mode");
		mode.setTitle("Make a Reservation");
		return true; 
	} 
 
	// from ActionMode.Callback 
	public void onDestroyActionMode(ActionMode mode) 
	{ 
		currentPosition = -1;
		 
		String message = reservation.report();
		if (!message.isEmpty())
		{ 
			Context context = getActivity();
			Toast toast = Toast.makeText(context, message, Toast.LENGTH_SHORT);
			toast.show();
Stop searching for code, let great code find you!  Add Codota to your java IDE