Пример #1
0
 /**
  * Show message in {@link Toast} with {@link Toast#LENGTH_SHORT} duration
  *
  * @param activity
  * @param message
  */
 public static void showShort(final Activity activity, final String message) {
   show(activity, message, LENGTH_SHORT);
 }
Пример #2
0
 /**
  * Show message in {@link Toast} with {@link Toast#LENGTH_LONG} duration
  *
  * @param activity
  * @param message
  */
 public static void showLong(final Activity activity, final String message) {
   show(activity, message, LENGTH_LONG);
 }
Пример #3
0
 /**
  * Show message in {@link Toast} with {@link Toast#LENGTH_LONG} duration
  *
  * @param activity
  * @param resId
  */
 public static void showLong(final Activity activity, int resId) {
   show(activity, resId, LENGTH_LONG);
 }
Пример #4
0
 /**
  * Show message in {@link Toast} with {@link Toast#LENGTH_SHORT} duration
  *
  * @param activity
  * @param resId
  */
 public static void showShort(final Activity activity, final int resId) {
   show(activity, resId, LENGTH_SHORT);
 }
Пример #5
0
 /**
  * Show message in {@link Toast} with {@link Toast#LENGTH_SHORT} duration
  *
  * @param activity
  * @param message
  * @param args
  */
 public static void showShort(
     final Activity activity, final String message, final Object... args) {
   String formatted = MessageFormat.format(message, args);
   show(activity, formatted, LENGTH_SHORT);
 }