Code example for ListFragment

Methods: getActivity, getText

0
	protected void toastLong(String message) {
		Toast.makeText(getActivity(), message, Toast.LENGTH_LONG).show();
	} 
 
	protected void toastLong(int message) {
		Toast.makeText(getActivity(), getText(message), Toast.LENGTH_LONG)
				.show();
	} 
 
	protected void toastShort(int message) {
		Toast.makeText(getActivity(), getText(message), Toast.LENGTH_SHORT)
				.show();
	} 
 
	protected void toastShort(CharSequence message) {
		Toast.makeText(getActivity(), message.toString(), Toast.LENGTH_SHORT)
				.show();
	} 
 
}