localnotificationsplugin icon indicating copy to clipboard operation
localnotificationsplugin copied to clipboard

Play sound when notification is received in iOS

Open bokmadsen opened this issue 7 years ago • 8 comments

Feature Request

There doesn't seem to be any option to play a sound when notification is received

Feature description:
Allow to specify that a sound should be played when notified, maybe even what sound to play

bokmadsen avatar Apr 28 '17 05:04 bokmadsen

1+ for this. But to play sound for Android and iOS. Possible enable/disable argument.

Android: When building the NotificationCompat.Builder add: builder.SetSound(RingtoneManager.GetDefaultUri(RingtoneType.Notification));

iOS For building UILocalNotification add: SoundName = UILocalNotification.DefaultSoundName Or building UNMutableNotificationContent add: Sound = UNNotificationSound.Default

justintemplar avatar Jul 17 '17 23:07 justintemplar

+1 for sounds & vibration.

rbrian avatar Sep 24 '18 23:09 rbrian

@justintemplar you said: Android: When building the NotificationCompat.Builder add: builder.SetSound(RingtoneManager.GetDefaultUri(RingtoneType.Notification));

but where in this project NotificationCompat.Builder is builded? I can't see anywhere

raul9410 avatar Dec 12 '18 11:12 raul9410

@raul9410 here you have it

DoktorAerzt avatar Dec 12 '18 12:12 DoktorAerzt

Here is a pull request that was submitted before the repository was moved to a separate repository: https://github.com/edsnider/xamarin.plugins/pull/33

Maybe someone can submit a new PR with the old PR as inspiration?

karlingen avatar Jan 18 '19 21:01 karlingen

@edsnider @jamesmontemagno could you add sound?

skycloudnest avatar Jan 28 '21 18:01 skycloudnest

@JensSchadron

skycloudnest avatar Jan 28 '21 18:01 skycloudnest

@JensSchadron @edsnider

skycloudnest avatar Jan 29 '21 09:01 skycloudnest