Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
R
react-native-notifications
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Jira
Jira
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
冷佳娟
react-native-notifications
Commits
0c653b0a
Commit
0c653b0a
authored
Jan 11, 2018
by
Amit Davidi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix nondistinct pending intent bug
parent
aaf458f3
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
2 deletions
+1
-2
android/src/main/java/com/wix/reactnativenotifications/core/NotificationIntentAdapter.java
...ctnativenotifications/core/NotificationIntentAdapter.java
+1
-2
No files found.
android/src/main/java/com/wix/reactnativenotifications/core/NotificationIntentAdapter.java
View file @
0c653b0a
...
...
@@ -8,12 +8,11 @@ import android.os.Bundle;
import
com.wix.reactnativenotifications.core.notification.PushNotificationProps
;
public
class
NotificationIntentAdapter
{
private
static
final
int
PENDING_INTENT_CODE
=
0
;
private
static
final
String
PUSH_NOTIFICATION_EXTRA_NAME
=
"pushNotification"
;
public
static
PendingIntent
createPendingNotificationIntent
(
Context
appContext
,
Intent
intent
,
PushNotificationProps
notification
)
{
intent
.
putExtra
(
PUSH_NOTIFICATION_EXTRA_NAME
,
notification
.
asBundle
());
return
PendingIntent
.
getService
(
appContext
,
PENDING_INTENT_CODE
,
intent
,
PendingIntent
.
FLAG_ONE_SHOT
);
return
PendingIntent
.
getService
(
appContext
,
(
int
)
System
.
currentTimeMillis
()
,
intent
,
PendingIntent
.
FLAG_ONE_SHOT
);
}
public
static
Bundle
extractPendingNotificationDataFromIntent
(
Intent
intent
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment