草庐IT

uiaccessibility-notification

全部标签

android - 如何使用 Notification.deleteIntent

我正在尝试检测我的通知何时被清除。我的问题直接引用这个answer这概述了我应该做的事情。这就是我执行这些操作的方式://usualNotificationinitializationherenotification.deleteIntent=PendingIntent.getService(context,0,newIntent(context,CleanUpIntent.class),0);notificationManager.notify(123,notification)这是CleanUpIntent类:classCleanUpIntentextendsIntentServi

安卓 N : How to launch activity in current active window instead of second window when click on notification in split-screen?

在AndroidN中使用分屏时我想在用户点击通知时在当前Activity窗口中启动activity,但AndroidN总是如果通过单击通知启动,则在第二个窗口中启动activity。NotificationCompat.BuildermBuilder=newNotificationCompat.Builder(this).setSmallIcon(R.drawable.notification).setAutoCancel(false).setContentTitle("DemoTitle").setContentText("Demo");Intentintent=newIntent(

安卓 N : How to launch activity in current active window instead of second window when click on notification in split-screen?

在AndroidN中使用分屏时我想在用户点击通知时在当前Activity窗口中启动activity,但AndroidN总是如果通过单击通知启动,则在第二个窗口中启动activity。NotificationCompat.BuildermBuilder=newNotificationCompat.Builder(this).setSmallIcon(R.drawable.notification).setAutoCancel(false).setContentTitle("DemoTitle").setContentText("Demo");Intentintent=newIntent(

Android - java.lang.IllegalArgumentException : contentIntent required error caused by notification?

我有一个正在运行的服务,当它收到一条消息说它必须更改时,它会更新通知栏中的通知。但有时在更新通知时会出现以下错误java.lang.IllegalArgumentException:contentIntentrequired这是我的代码:变量设置inticon=R.drawable.notification;CharSequencetickerText="Test";longwhen=System.currentTimeMillis();PendingIntentcontentIntent;Notificationnotification=newNotification(icon,ti

Android - java.lang.IllegalArgumentException : contentIntent required error caused by notification?

我有一个正在运行的服务,当它收到一条消息说它必须更改时,它会更新通知栏中的通知。但有时在更新通知时会出现以下错误java.lang.IllegalArgumentException:contentIntentrequired这是我的代码:变量设置inticon=R.drawable.notification;CharSequencetickerText="Test";longwhen=System.currentTimeMillis();PendingIntentcontentIntent;Notificationnotification=newNotification(icon,ti

【什么是苹果IM推?什么是苹果推?】iMessage推送操纵Apple Push Notification service (APNs)

以帮忙你明白实现iMessage推送的基本原理和步调:开辟者账户:确保你具有苹果开发者账户,以便访谒苹果开发者中间和相干东西。APNs认证:iMessage推送操纵ApplePushNotificationservice(APNs)来发送关照。在苹果开发者中心,你需要建立一个推送证书,并将其与你的应用程序联系关系起来。这将容许你的应用程序发送推送通知到用户装备。推荐内容IMESSGAE相关作者✈️@IMEAE推荐内容 iMessage苹果推软件***点击即可查看作者要求内容信息作者✈️@IMEAE推荐内容 1.家庭推内容***点击即可查看作者要求内容信息作者✈️@IMEAE推荐内容 2.相册推

Android GCM(推送通知): device doesn't receive notification if application is stopped

我在我的Android项目中使用推送通知(GCM)。根据GCM教程,我实现了广播接收器并将其注册在AndroidManifest.xml中。即使我的应用程序关闭,这种广播接收器也应该接收消息(不仅当我的应用程序在后台,而且即使它被强制停止)。但它并没有像我预期的那样工作。如果应用程序关闭,则不会调用onReceive()方法。看来我对广播接收器的理解是正确的,问题出在我对GCM的期望中。其中一个可能的原因是,如果应用程序关闭,谷歌服务器甚至不会向设备发送通知。那么,仅当我的应用程序正在运行或在后台(但未关闭)时,我的应用程序才能接收消息(并且onReceive()方法将在广播接收器中调

Android GCM(推送通知): device doesn't receive notification if application is stopped

我在我的Android项目中使用推送通知(GCM)。根据GCM教程,我实现了广播接收器并将其注册在AndroidManifest.xml中。即使我的应用程序关闭,这种广播接收器也应该接收消息(不仅当我的应用程序在后台,而且即使它被强制停止)。但它并没有像我预期的那样工作。如果应用程序关闭,则不会调用onReceive()方法。看来我对广播接收器的理解是正确的,问题出在我对GCM的期望中。其中一个可能的原因是,如果应用程序关闭,谷歌服务器甚至不会向设备发送通知。那么,仅当我的应用程序正在运行或在后台(但未关闭)时,我的应用程序才能接收消息(并且onReceive()方法将在广播接收器中调

android - Notification.Builder(context) 已弃用 Android O

这个问题在这里已经有了答案:NotificationCompat.BuilderdeprecatedinAndroidO(10个回答)关闭5年前.Notification.Builder(context)最近在AndroidO中的NotificationChannels位置已被弃用。问题:在使用Notification.Builder(context,StringID)而不是Notification.Builder(context)后,我确实收到了我的AndroidO设备的通知。但是,在Android23(M)上尝试之后,我没有收到通知。我调试了我的代码,一旦调试器在Android23

android - Notification.Builder(context) 已弃用 Android O

这个问题在这里已经有了答案:NotificationCompat.BuilderdeprecatedinAndroidO(10个回答)关闭5年前.Notification.Builder(context)最近在AndroidO中的NotificationChannels位置已被弃用。问题:在使用Notification.Builder(context,StringID)而不是Notification.Builder(context)后,我确实收到了我的AndroidO设备的通知。但是,在Android23(M)上尝试之后,我没有收到通知。我调试了我的代码,一旦调试器在Android23