notifications

Notification with multiple buttons

[亡魂溺海] 提交于 2020-08-09 05:39:13
问题 I need to display notification with two buttons. Different operation need to perform for each button.so for that I have written following code but when I'm getting multiple notification delete action is not performing. Random NOTIFICATION_ID = new Random(); int CANCELNOTIFICATIONID = NOTIFICATION_ID.nextInt(); // define sound URI, the sound to be played when there's a notification Uri soundUri = RingtoneManager.getDefaultUri(RingtoneManager.TYPE_NOTIFICATION); Log.i("******* Service6", "" +

Notification with multiple buttons

岁酱吖の 提交于 2020-08-09 05:38:03
问题 I need to display notification with two buttons. Different operation need to perform for each button.so for that I have written following code but when I'm getting multiple notification delete action is not performing. Random NOTIFICATION_ID = new Random(); int CANCELNOTIFICATIONID = NOTIFICATION_ID.nextInt(); // define sound URI, the sound to be played when there's a notification Uri soundUri = RingtoneManager.getDefaultUri(RingtoneManager.TYPE_NOTIFICATION); Log.i("******* Service6", "" +

How to flash/blink taskbar icon in vb.net?

[亡魂溺海] 提交于 2020-08-04 23:20:13
问题 I need to make my vb.net application be able to flash/blink to attract a user's attention when a notification is received within the application. Like the DW icon does in this image: I've been Googling this for a while and have tried various code examples, all with no success. Here's what I've got so far: Public Class FlashWindow Private Declare Function FlashWindow Lib "user32" (ByVal hwnd As Long, ByVal bInvert As Long) As Long Shared Sub main() FlashWindow(Me.Handle, 1) End Sub End Class

How to write a notification that does absolutly nothing when clicked?

老子叫甜甜 提交于 2020-07-29 11:15:10
问题 Ive seen many examples of how to make something happen when the user clicks on a notification but I actually don't want anything to happen. If the user clicks on the notification I want the notification to simply dissapear and the user NOT taken anywhere. In my code below, while FLAG_AUTO_CANCEL clears the notification from the status bar, when the user clicks on a my notification they are taken to "MyActivity". How can I create a notification that does nothing? Notification notification =

Android 8 (Oreo) notification not showing up

别等时光非礼了梦想. 提交于 2020-07-22 07:04:08
问题 Intent intent = new Intent(this, SplashActivity.class); Bundle bundle = new Bundle(); bundle.putString("splash", psd); bundle.putString("targetId", targetId); intent.putExtras(bundle); intent.setAction(psd); intent.setAction(targetId); intent.setFlags(Intent.FLAG_ACTIVITY_CLEAR_TASK | Intent.FLAG_ACTIVITY_NEW_TASK); PendingIntent pendingIntent = PendingIntent.getActivity(getApplicationContext(), id, intent, 0); Uri defaultSoundUri = RingtoneManager.getDefaultUri(RingtoneManager.TYPE

The tap gesture isn't detected on the status bar area?

空扰寡人 提交于 2020-07-19 06:19:10
问题 The title explains it all. Is there any way to detect a tap gesture on the status bar in iOS 11? I've already googled for this, and tried as suggested, but they all seem to be outdated answers somehow. I wonder if there's anyone who has already figured out how to solve this. 回答1: I use this code in the AppDelegate.swift override func touchesBegan(_ touches: Set<UITouch>, with event: UIEvent?) { super.touchesBegan(touches, with: event) let statusBarRect = UIApplication.shared.statusBarFrame

The tap gesture isn't detected on the status bar area?

倖福魔咒の 提交于 2020-07-19 06:18:11
问题 The title explains it all. Is there any way to detect a tap gesture on the status bar in iOS 11? I've already googled for this, and tried as suggested, but they all seem to be outdated answers somehow. I wonder if there's anyone who has already figured out how to solve this. 回答1: I use this code in the AppDelegate.swift override func touchesBegan(_ touches: Set<UITouch>, with event: UIEvent?) { super.touchesBegan(touches, with: event) let statusBarRect = UIApplication.shared.statusBarFrame

The tap gesture isn't detected on the status bar area?

China☆狼群 提交于 2020-07-19 06:17:56
问题 The title explains it all. Is there any way to detect a tap gesture on the status bar in iOS 11? I've already googled for this, and tried as suggested, but they all seem to be outdated answers somehow. I wonder if there's anyone who has already figured out how to solve this. 回答1: I use this code in the AppDelegate.swift override func touchesBegan(_ touches: Set<UITouch>, with event: UIEvent?) { super.touchesBegan(touches, with: event) let statusBarRect = UIApplication.shared.statusBarFrame

Notifications on Windows 10 using desktop app

旧巷老猫 提交于 2020-07-17 06:59:25
问题 I got a Windows Forms project in C# with a NotifyIcon. I'm using the following code to display a balloon notification: notifyIcon.ShowBalloonTip(1000, "title", "text", ToolTipIcon.Info); This was working fine until Windows 8.1. Now I've installed the Windows 10 Preview and the balloon notification doesn't show up anymore. I guess that all notifications are moved to the Windows 8 style toast notifications and the balloon notifications are completely removed (because I haven't seen a single

Send notification from device to another with firebase in Android [duplicate]

别等时光非礼了梦想. 提交于 2020-07-16 10:33:30
问题 This question already has answers here : How to send one to one message using Firebase Messaging (5 answers) How to send Device to device notification by using FCM without using XMPP or any other script.? (3 answers) Closed yesterday . I build an application that book lessons, in the application there are student account and teacher account. So I need when the student book the lesson then the teacher receive a notification with the details of the lesson. I use Firebase Realtime database to