Created
July 9, 2019 16:53
-
-
Save saurabharora90/a5167d53385876dfcd73ce74e1904792 to your computer and use it in GitHub Desktop.
Beginning with Android Q, Background Activity Starts should be done by notification triggered activities.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
val fullScreenIntent = Intent(this, CallActivity::class.java) | |
val fullScreenPendingIntent = PendingIntent.getActivity(this, 0, | |
fullScreenIntent, PendingIntent.FLAG_UPDATE_CURRENT) | |
val notificationBuilder = NotificationCompat.Builder(this, CHANNEL_ID) | |
.... | |
.setPriority(NotificationCompat.PRIORITY_HIGH) | |
.setCategory(NotificationCompat.CATEGORY_CALL) | |
.setFullScreenIntent(fullScreenPendingIntent, true) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment