Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix for Android notification actions #10

Merged
merged 1 commit into from
Apr 29, 2020
Merged

Conversation

k00na
Copy link
Contributor

@k00na k00na commented Apr 28, 2020

Removed launch intent from decline and answer actions. Before this, clicking one of the notification actions would unnecessarily restart the app in cases when it was already running.

…gs that clear the activity stack as is the case with launch intent.
@@ -409,11 +408,20 @@ class CallKeep(private val channel: MethodChannel, private var applicationContex
launchIntent.putExtra(key, value)
}

var answerIntent = Intent(launchIntent)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

After this, is the launchIntent still needed? I don't really understand this PendingIntent below.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, launchIntent gets triggered when the user clicks on the notification itself and not on the actions. When notification is clicked it gets expanded to the full screen activity for the incoming call.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants