Open nabati opened 8 years ago
It works fine to me. What's the Android and React Native version are you using?
@Neson the same with me, I'm using Android 6.0 and React Native 0.16
I see, but I can't accurately identify the problem yet. Providing a sample project that reproducing the problem will be a big help to solve this issue!
To move a few steps ahead: 1. Are you using local notifications or GCM push notificaions? 2. Are you sure the android.permission.VIBRATE
permission is added to AndroidManifest.xml
?
Thank you for the feedback!
I'm using GCM and in my AndroidManifest has:
<uses-permission android:name="android.permission.VIBRATE" />
I put this in Notification.java:
Uri soundUri = RingtoneManager.getDefaultUri(RingtoneManager.TYPE_NOTIFICATION);
notificationBuilder.setSound(soundUri);
notificationBuilder.setVibrate(new long[] { 1000, 1000, 1000, 1000, 1000 });
notificationBuilder.setLights(Color.RED, 3000, 3000);
and works. I don't know the lights, this not works on my phone.
Neither sound nor vibration seems to be working at the moment.
Is the documentation not up to date?