Eleven: bump targetsdk to 31
Change-Id: I363684688bdd97ee8d7b9dabb1d7baecac52c98a
Signed-off-by: Alexander Martinz <amartinz@shiftphones.com>
diff --git a/AndroidManifest.xml b/AndroidManifest.xml
index 4fbb91f..6573dbe 100644
--- a/AndroidManifest.xml
+++ b/AndroidManifest.xml
@@ -24,7 +24,7 @@
<uses-sdk
android:minSdkVersion="28"
- android:targetSdkVersion="30" />
+ android:targetSdkVersion="31" />
<!-- Android Studio will complain about not being able to
resove the symbol, but it compiles with no problem.
@@ -111,13 +111,15 @@
<!-- Used to set options -->
<activity
android:name="org.lineageos.eleven.ui.activities.SettingsActivity"
+ android:exported="false"
android:label="@string/menu_settings"
android:theme="@style/Eleven.Theme.ActionBar.Overlay"/>
<!-- Audio Preview -->
<activity
android:name=".ui.activities.preview.AudioPreviewActivity"
- android:launchMode="singleTask"
android:excludeFromRecents="true"
+ android:exported="true"
+ android:launchMode="singleTask"
android:taskAffinity=""
android:theme="@style/Theme.AudioPreview">
<intent-filter>
@@ -195,13 +197,17 @@
android:resource="@xml/app_widget_large_alternate" />
</receiver>
<!-- Media button receiver -->
- <receiver android:name="org.lineageos.eleven.MediaButtonIntentReceiver" >
+ <receiver
+ android:name="org.lineageos.eleven.MediaButtonIntentReceiver"
+ android:exported="false">
<intent-filter>
<action android:name="android.intent.action.MEDIA_BUTTON" />
</intent-filter>
</receiver>
<!-- Used to recalculate sorting of songs based on the user's locale -->
- <receiver android:name=".locale.LocaleChangeReceiver">
+ <receiver
+ android:name=".locale.LocaleChangeReceiver"
+ android:exported="false">
<intent-filter>
<action android:name="android.intent.action.LOCALE_CHANGED"/>
</intent-filter>
@@ -209,6 +215,7 @@
<!-- Music service -->
<service
android:name="org.lineageos.eleven.MusicPlaybackService"
+ android:exported="false"
android:label="@string/app_name"
android:process=":main" />
</application>
diff --git a/build.gradle b/build.gradle
index a819320..9ce1a97 100644
--- a/build.gradle
+++ b/build.gradle
@@ -42,7 +42,7 @@
applicationId "org.lineageos.eleven"
minSdkVersion 28
- targetSdkVersion 30
+ targetSdkVersion 31
versionCode 410
versionName '4.1.0'
diff --git a/lint-baseline.xml b/lint-baseline.xml
index fb25b81..69cf76f 100644
--- a/lint-baseline.xml
+++ b/lint-baseline.xml
@@ -79,28 +79,6 @@
</issue>
<issue
- id="OldTargetApi"
- message="Not targeting the latest versions of Android; compatibility modes apply. Consider testing and updating this version. Consult the `android.os.Build.VERSION_CODES` javadoc for details."
- errorLine1=" android:targetSdkVersion="30" />"
- errorLine2=" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~">
- <location
- file="AndroidManifest.xml"
- line="27"
- column="9"/>
- </issue>
-
- <issue
- id="OldTargetApi"
- message="Not targeting the latest versions of Android; compatibility modes apply. Consider testing and updating this version. Consult the android.os.Build.VERSION_CODES javadoc for details."
- errorLine1=" targetSdkVersion 30"
- errorLine2=" ~~~~~~~~~~~~~~~~~~~">
- <location
- file="build.gradle"
- line="45"
- column="9"/>
- </issue>
-
- <issue
id="Range"
message="Value must be ≥ 0 (was -1)"
errorLine1=" columnIndex = cursor.getColumnIndexOrThrow(MediaStore.Audio.Playlists.Members.AUDIO_ID);"
@@ -402,39 +380,6 @@
</issue>
<issue
- id="IntentFilterExportedReceiver"
- message="As of Android 12, `android:exported` must be set; use `true` to make the activity \
available to other apps, and `false` otherwise."
- errorLine1=" <activity"
- errorLine2=" ~~~~~~~~">
- <location
- file="AndroidManifest.xml"
- line="117"
- column="10"/>
- </issue>
-
- <issue
- id="IntentFilterExportedReceiver"
- message="As of Android 12, `android:exported` must be set; use `true` to make the activity \
available to other apps, and `false` otherwise."
- errorLine1=" <receiver android:name="org.lineageos.eleven.MediaButtonIntentReceiver" >"
- errorLine2=" ~~~~~~~~">
- <location
- file="AndroidManifest.xml"
- line="198"
- column="10"/>
- </issue>
-
- <issue
- id="IntentFilterExportedReceiver"
- message="As of Android 12, `android:exported` must be set; use `true` to make the activity \
available to other apps, and `false` otherwise."
- errorLine1=" <receiver android:name=".locale.LocaleChangeReceiver">"
- errorLine2=" ~~~~~~~~">
- <location
- file="AndroidManifest.xml"
- line="204"
- column="10"/>
- </issue>
-
- <issue
id="AllowBackup"
message="On SDK version 23 and up, your app data will be automatically backed up and restored on app install. Consider adding the attribute `android:fullBackupContent` to specify an `@xml` resource which configures which files to backup, or just set `android:fullBackupOnly=true`. More info: https://developer.android.com/guide/topics/data/autobackup"
errorLine1=" android:allowBackup="true""