notifications

step by step implementation of nativescript push notification in nativescript

耗尽温柔 提交于 2020-01-17 16:57:09
问题 can anyone give step by step guidence starting from creating a helloworld app then the remaining steps to do push notifications. i have already gone through the below link and failed to achieve that https://github.com/EddyVerbruggen/nativescript-plugin-firebase i have some progress on it, refer below code. http.request({ url: 'https://fcm.googleapis.com/fcm/send', method: "POST", headers: { 'Authorization': 'key=AIzaSyBri16HAa7g2REEy******YFnTDGIlM_1k', 'Content-Type': 'application/json' },

How to do headsup notification on xamarin android?

半城伤御伤魂 提交于 2020-01-17 15:40:41
问题 How can I show the notification as heads up notification on Xamarin Android. I got the notification working, but I don't know how to set to high priority so it can show up even when using other application. I used the plugin Xam.Plugin.Notifier for the NuGet. 回答1: In Xamarin.Android, if you want to show heads-up notification, you have to set the priority to High or Max: builder.SetPriority (NotificationPriority.High); According to the source of Notifier plugin, there is no interface for the

How to know whether actual internet is available or not in Swift?

别等时光非礼了梦想. 提交于 2020-01-17 14:49:08
问题 I want to get notified when my WiFi Router color changes from Green to Red I am making an app which will tell you whether you are online or offline from menu bar in Swift which is open source & can be found at https://github.com/deadcoder0904/net-alert I want to know if its possible to get notified when WiFi color changes in Swift. I can't constantly ping my server to know that the color changed as this would be wasting internet resources. So is it possible to know this in Swift? 回答1: First

Not receiving notification click in service

痞子三分冷 提交于 2020-01-17 07:17:47
问题 I try to run a background service and display a persistent notification. When the notification is clicked, the service (providing NanoHTTPD webserver) should be stopped. The onReceive never seems to be called when tapping the notification. "Stop" is not logged. (while "Start" is. My code below is roughly based on https://stackoverflow.com/a/19476094/288568. public class Webserver extends IntentService { private final String TAG = "MyAMWebserver"; public static final int PORT = 1234; public

notification intent opens the apps main activity in background if its paused

半城伤御伤魂 提交于 2020-01-17 06:28:08
问题 I have a notification service running that will create a notification for the user and if the user clicks the notification it opens an activity to display the message, the method I am using to create the notification is : public void createNotificationMsg(String name,String doing, boolean persistent){ PendingIntent pendingIntent = PendingIntent.getActivity(getApplicationContext(), 0, new Intent(getApplicationContext(), MessageNotificationActivity.class) .setFlags(Intent.FLAG_ACTIVITY_CLEAR

Notification when view controller is presented modally/dismissed?

谁说我不能喝 提交于 2020-01-17 05:16:27
问题 Is there any way to be notified automatically if some view controller is presented modally on top of another view controller (other than viewWillDisappear , which is obviously not called for non-fullscreen modal presentation on iPad)? Background/use case: In an iPad app, whenever a modal form sheet is presented, I want to adjust the appearance of the view behind the modal. However, the presentation if the modals is not necessarily done in the same view controller that needs to adapt, but can

android displaying multiple activity in saved state when notification click

可紊 提交于 2020-01-17 04:56:29
问题 I have a notification on my app. It works in foreground well. When i`m in a other activity and press home button after that i click notification. It opens given activity, but i need to display previous activity in a saved state. Notification note = new Notification(R.drawable.service_state_0, getResources().getText(R.string.serviceStarted), System.currentTimeMillis()); Intent i = new Intent(this, StartingActivity_.class); i.setFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP | Intent.FLAG_ACTIVITY_SINGLE

how to implement Push notifications in Apache Cordova?

我的未来我决定 提交于 2020-01-17 03:49:07
问题 I am new to apache cordova apps development.I am working in an App in which i want to implement Push notifications. Which is simple way to do it. Please help me 回答1: I found an article explaining how to do push notifications here. A sample associated with that article can be found here. Perhaps a bit of a read, but I hope you find it helpful! 来源: https://stackoverflow.com/questions/31700732/how-to-implement-push-notifications-in-apache-cordova

Are Chrome rich notifications deprecated

元气小坏坏 提交于 2020-01-17 02:58:09
问题 I was previousely using webkit notifications on my website but it seems to have deprecated, I am trying the rich notifications but they seem to be not working either. I tried almost all the available demos online but none of them work. Are the Rich notifications deprecated, if so what could be the possible ways of displaying desktop notifications in chrome. I checked the chrome flags and I coudnt find the rich notifications options. This was the code I was trying for rich notifications

Android notifications and vibrate from service

南楼画角 提交于 2020-01-16 19:57:26
问题 I have service, that connect to server with AsyncTask. After parsing response, i need to make notification and vibrate, but get NullpointerException. @Override protected void onPostExecute(String[] result) { ReconnectCallback(result); super.onPostExecute(result); } public void ReconnectCallback(String[] params) { Handler mHandler = new Handler(); Notification notif = new Notification(R.drawable.ic_launcher, "Connection error", System.currentTimeMillis()); Intent x = new Intent();