List of usage examples for android.app NotificationManager cancel
public void cancel(int id)
From source file:Main.java
public static void cancelNotification(Context context, int id) { NotificationManager notificationManager = (NotificationManager) context .getSystemService(Context.NOTIFICATION_SERVICE); notificationManager.cancel(id); }
From source file:Main.java
public static void stopStatusBarNotification(Context context) { NotificationManager notificationManager = (NotificationManager) context .getSystemService(Context.NOTIFICATION_SERVICE); notificationManager.cancel(SSH_STARTED_NOTIFICATION_ID); }
From source file:Main.java
public static void clearNotifications(Context context) { NotificationManager notificationManager = (NotificationManager) context .getSystemService(Context.NOTIFICATION_SERVICE); notificationManager.cancel(NOTIFICATION_ID_ALL_PLAYERS_PERSISTENT); notificationManager.cancel(NOTIFICATION_ID_INDIVIDUAL_PLAYERS); }
From source file:Main.java
public static void dismissNotification(final Context context, int notificationId) { Log.d(TAG, "dismissNotification notificationID=" + notificationId); NotificationManager notifManager = (NotificationManager) context .getSystemService(Context.NOTIFICATION_SERVICE); notifManager.cancel(notificationId); }
From source file:com.pnsofts.itebooksinfo.Utils.NotificationHelper.java
public static void dismissMsgNotification(Context ctx) { final NotificationManager mgr; mgr = (NotificationManager) ctx.getSystemService(Context.NOTIFICATION_SERVICE); mgr.cancel(NOTIFICATION_ID); }
From source file:Main.java
public static void cancelNotification(@NonNull Context context, int id) { int finalId = id == 0 ? NOTIFICATION_ID : id; NotificationManager notificationManager = (NotificationManager) context .getSystemService(Context.NOTIFICATION_SERVICE); notificationManager.cancel(finalId); }
From source file:com.imagine.NotificationHelper.java
static void removeNotification(Context ctx) { NotificationManager notificationManager = (NotificationManager) ctx .getSystemService(Context.NOTIFICATION_SERVICE); notificationManager.cancel(1); }
From source file:enterprayz.megatools.NotificationBuilder.java
public static void killServiceNotification(Context context) { NotificationManager nm = (NotificationManager) context.getSystemService(Context.NOTIFICATION_SERVICE); nm.cancel(SERVICE_NOTIFY_ID); }
From source file:com.manning.androidhacks.hack046.helper.NotificationHelper.java
public static void dismissMsgNotification(Context ctx) { final NotificationManager mgr; mgr = (NotificationManager) ctx.getSystemService(Context.NOTIFICATION_SERVICE); mgr.cancel(R.id.activity_main_receive_msg); }
From source file:net.eledge.android.europeana.gui.notification.NewBlogNotification.java
public static void cancel(final Context context) { final NotificationManager nm = (NotificationManager) context.getSystemService(Context.NOTIFICATION_SERVICE); nm.cancel(Config.NOTIFICATION_NEWBLOG); }