Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion android/hello_sdl_android/build.gradle
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
apply plugin: 'com.android.application'

android {
compileSdkVersion 30
compileSdkVersion 31
defaultConfig {
applicationId "com.sdl.hellosdlandroid"
minSdkVersion 16
Expand Down
2 changes: 1 addition & 1 deletion android/sdl_android/build.gradle
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
apply plugin: 'com.android.library'

android {
compileSdkVersion 30
compileSdkVersion 31
defaultConfig {
minSdkVersion 16
targetSdkVersion 30
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1521,7 +1521,8 @@ private void enterForeground(String content, long chronometerLength, boolean ong

// Create an intent that will be fired when the user clicks the notification.
Intent intent = new Intent(Intent.ACTION_VIEW, Uri.parse(SDL_NOTIFICATION_FAQS_PAGE));
PendingIntent pendingIntent = PendingIntent.getActivity(this, 0, intent, 0);
int flag = (Build.VERSION.SDK_INT >= Build.VERSION_CODES.S)? PendingIntent.FLAG_IMMUTABLE : 0;
PendingIntent pendingIntent = PendingIntent.getActivity(this, 0, intent, flag);
builder.setContentIntent(pendingIntent);

if (chronometerLength > (FOREGROUND_TIMEOUT / 1000) && android.os.Build.VERSION.SDK_INT >= Build.VERSION_CODES.N) {
Expand Down