oney / react-native-gcm-android

GCM for React Native Android
MIT License
172 stars 76 forks source link

Activity started twice #36

Open paulbao opened 8 years ago

paulbao commented 8 years ago

Press Home button to minimise the app and send a push notification to the app. If you click the the notification, it will launch the app again. But you have to click back button twice to go back.

oney commented 8 years ago

I believe this issue is related to react-native-system-notification that is responsible for creating notifications. Please go there to open a issue. I have tried TestGcm app. If I click the home button and click the notification, it will open the app rather than re-launching it.

jawadrehman commented 8 years ago

@paulbao i have seen it happen when the app is fully closed when multiple notifications are received.

oney commented 8 years ago

@jawadrehman the issue that you mentioned should be related to this module. Do you have more than one apps that are using this module? Including TestGcm app.

jawadrehman commented 8 years ago

@oney looking back, I think its related to the changes I made in the pull request I submitted earlier. Without that change, only one notification was created if the app was fully closed.

jawadrehman commented 8 years ago

line 242 of GCModule.java . I had to change it to use a random number to display multiple notifications, which was far more important in my app