Skip to content

Commit 18ad0c4

Browse files
author
Tsung-Mao Fang
committed
Import the window extension libary in the Settings app
Test: Rebuilt apk and run apk successfully. Bug: 196939216 Change-Id: If9040ae9a1c72097e4964c8d40ea9785cf2f01dc
1 parent b7680ac commit 18ad0c4

File tree

4 files changed

+16
-0
lines changed

4 files changed

+16
-0
lines changed

Android.bp

+10
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,7 @@ android_library {
7474
"android.hardware.dumpstate-V1.1-java",
7575
"lottie",
7676
"WifiTrackerLib",
77+
"windowExtLib",
7778
],
7879

7980
libs: [
@@ -102,6 +103,10 @@ android_app {
102103
],
103104
static_libs: ["Settings-core"],
104105
uses_libs: ["org.apache.http.legacy"],
106+
optional_uses_libs: [
107+
"androidx.window.extensions",
108+
"androidx.window.sidecar",
109+
],
105110
resource_dirs: [],
106111
optimize: {
107112
proguard_flags_files: ["proguard.flags"],
@@ -113,6 +118,11 @@ android_library_import {
113118
aars: ["libs/contextualcards.aar"],
114119
}
115120

121+
android_library_import {
122+
name: "windowExtLib",
123+
aars: ["libs/window_ext_lib.aar"],
124+
}
125+
116126
filegroup {
117127
name: "Settings_proguard_flags",
118128
srcs: ["proguard.flags"],

AndroidManifest.xml

+1
Original file line numberDiff line numberDiff line change
@@ -122,6 +122,7 @@
122122
android:appComponentFactory="androidx.core.app.CoreComponentFactory">
123123

124124
<uses-library android:name="org.apache.http.legacy" />
125+
125126
<!-- Settings -->
126127

127128
<activity android:name=".homepage.SettingsHomepageActivity"

libs/window_ext_lib.aar

159 KB
Binary file not shown.

proguard.flags

+5
Original file line numberDiff line numberDiff line change
@@ -66,3 +66,8 @@
6666
-keepclasseswithmembers class * extends com.android.settings.slices.SliceBackgroundWorker {
6767
public <init>(android.content.Context, android.net.Uri);
6868
}
69+
70+
# Keep WM Jetpack classes and callbacks
71+
-keep class androidx.window.extensions.** { *; }
72+
-dontwarn androidx.window.extensions.**
73+
-keep class androidx.window.** { *; }

0 commit comments

Comments
 (0)