Merge "Import translations. DO NOT MERGE ANYWHERE"
diff --git a/Android.bp b/Android.bp
index 73bc382..6b39b51 100644
--- a/Android.bp
+++ b/Android.bp
@@ -620,7 +620,6 @@
"av-types-aidl-java",
"mediatranscoding_aidl_interface-java",
"soundtrigger_middleware-aidl-java",
- "modules-utils-os",
],
}
@@ -1260,6 +1259,7 @@
filegroup {
name: "framework-telephony-common-shared-srcs",
srcs: [
+ "core/java/android/os/BasicShellCommandHandler.java",
"core/java/android/os/RegistrantList.java",
"core/java/android/os/Registrant.java",
"core/java/android/util/IndentingPrintWriter.java",
@@ -1342,6 +1342,7 @@
name: "framework-wifi-service-shared-srcs",
srcs: [
"core/java/android/net/InterfaceConfiguration.java",
+ "core/java/android/os/BasicShellCommandHandler.java",
"core/java/android/util/BackupUtils.java",
"core/java/android/util/Rational.java",
"core/java/com/android/internal/util/FastXmlSerializer.java",
diff --git a/apct-tests/perftests/inputmethod/Android.bp b/apct-tests/perftests/inputmethod/Android.bp
new file mode 100644
index 0000000..463ac9b
--- /dev/null
+++ b/apct-tests/perftests/inputmethod/Android.bp
@@ -0,0 +1,30 @@
+// Copyright (C) 2020 The Android Open Source Project
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+android_test {
+ name: "ImePerfTests",
+ srcs: ["src/**/*.java"],
+ static_libs: [
+ "androidx.test.rules",
+ "androidx.annotation_annotation",
+ "apct-perftests-utils",
+ "collector-device-lib",
+ "compatibility-device-util-axt",
+ "platform-test-annotations",
+ ],
+ test_suites: ["device-tests"],
+ data: [":perfetto_artifacts"],
+ platform_apis: true,
+ certificate: "platform",
+}
diff --git a/apct-tests/perftests/inputmethod/AndroidManifest.xml b/apct-tests/perftests/inputmethod/AndroidManifest.xml
new file mode 100644
index 0000000..1fb0b88
--- /dev/null
+++ b/apct-tests/perftests/inputmethod/AndroidManifest.xml
@@ -0,0 +1,44 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+<manifest xmlns:android="http://schemas.android.com/apk/res/android"
+ package="com.android.perftests.inputmethod">
+
+ <application>
+ <uses-library android:name="android.test.runner" />
+ <activity android:name="android.perftests.utils.PerfTestActivity"
+ android:exported="true">
+ <intent-filter>
+ <action android:name="com.android.perftests.core.PERFTEST" />
+ </intent-filter>
+ </activity>
+ <service android:name="android.inputmethod.ImePerfTest$BaselineIme"
+ android:process=":BaselineIME"
+ android:label="Baseline IME"
+ android:permission="android.permission.BIND_INPUT_METHOD"
+ android:exported="true">
+ <intent-filter>
+ <action android:name="android.view.InputMethod"/>
+ </intent-filter>
+ <meta-data android:name="android.view.im"
+ android:resource="@xml/simple_method"/>
+ </service>
+ </application>
+
+ <instrumentation android:name="androidx.test.runner.AndroidJUnitRunner"
+ android:targetPackage="com.android.perftests.inputmethod">
+ <meta-data android:name="listener" android:value="android.inputmethod.ImePerfRunPrecondition" />
+ </instrumentation>
+</manifest>
diff --git a/apct-tests/perftests/inputmethod/AndroidTest.xml b/apct-tests/perftests/inputmethod/AndroidTest.xml
new file mode 100644
index 0000000..1ec0cba
--- /dev/null
+++ b/apct-tests/perftests/inputmethod/AndroidTest.xml
@@ -0,0 +1,73 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+<configuration description="Runs ImePerfTests metric instrumentation.">
+ <option name="test-suite-tag" value="apct" />
+ <option name="test-suite-tag" value="apct-metric-instrumentation" />
+ <target_preparer class="com.android.tradefed.targetprep.suite.SuiteApkInstaller">
+ <option name="cleanup-apks" value="true" />
+ <option name="test-file-name" value="ImePerfTests.apk" />
+ </target_preparer>
+
+ <target_preparer class="com.android.tradefed.targetprep.DeviceSetup">
+ <option name="force-skip-system-props" value="true" />
+ <option name="run-command" value="input keyevent KEYCODE_WAKEUP" />
+ <option name="run-command" value="cmd window dismiss-keyguard" />
+ <option name="run-command" value="cmd package compile -m speed com.android.perftests.inputmethod" />
+ </target_preparer>
+
+ <!-- Needed for pushing the trace config file -->
+ <target_preparer class="com.android.tradefed.targetprep.RootTargetPreparer"/>
+ <target_preparer class="com.android.tradefed.targetprep.PushFilePreparer">
+ <option name="push-file" key="trace_config_detailed.textproto" value="/data/misc/perfetto-traces/trace_config.textproto" />
+ <!--Install the content provider automatically when we push some file in sdcard folder.-->
+ <!--Needed to avoid the installation during the test suite.-->
+ <option name="push-file" key="trace_config_detailed.textproto" value="/sdcard/sample.textproto" />
+ </target_preparer>
+
+ <!-- Needed for storing the perfetto trace files in the sdcard/test_results-->
+ <option name="isolated-storage" value="false" />
+
+ <test class="com.android.tradefed.testtype.AndroidJUnitTest" >
+ <option name="package" value="com.android.perftests.inputmethod" />
+ <option name="hidden-api-checks" value="false"/>
+
+ <!-- Listener related args for collecting the traces and waiting for the device to stabilize. -->
+ <option name="device-listeners" value="android.device.collectors.ProcLoadListener,android.device.collectors.PerfettoListener" />
+
+ <!-- Guarantee that user defined RunListeners will be running before any of the default listeners defined in this runner. -->
+ <option name="instrumentation-arg" key="newRunListenerMode" value="true" />
+
+ <!-- Kill background operations -->
+ <option name="instrumentation-arg" key="kill-bg" value="true" />
+
+ <!-- ProcLoadListener related arguments -->
+ <!-- Wait for device last minute threshold to reach 3 with 2 minute timeout before starting the test run -->
+ <option name="instrumentation-arg" key="procload-collector:per_run" value="true" />
+ <option name="instrumentation-arg" key="proc-loadavg-threshold" value="3" />
+ <option name="instrumentation-arg" key="proc-loadavg-timeout" value="120000" />
+ <option name="instrumentation-arg" key="proc-loadavg-interval" value="10000" />
+
+ <!-- PerfettoListener related arguments -->
+ <option name="instrumentation-arg" key="perfetto_config_text_proto" value="true" />
+ <option name="instrumentation-arg" key="perfetto_config_file" value="trace_config.textproto" />
+ </test>
+
+ <metrics_collector class="com.android.tradefed.device.metric.FilePullerLogCollector">
+ <option name="directory-keys" value="/data/local/tmp/ImePerfTests" />
+ <!-- Needed for pulling the collected trace config on to the host -->
+ <option name="pull-pattern-keys" value="perfetto_file_path" />
+ </metrics_collector>
+</configuration>
diff --git a/apct-tests/perftests/inputmethod/README.md b/apct-tests/perftests/inputmethod/README.md
new file mode 100644
index 0000000..8ba2087
--- /dev/null
+++ b/apct-tests/perftests/inputmethod/README.md
@@ -0,0 +1,40 @@
+## IMF performance tests
+
+These tests are adaptation of Window Manager perf tests (apct-tests/perftests/windowmanager).
+
+### Precondition
+To reduce the variance of the test, if `perf-setup` (platform_testing/scripts/perf-setup)
+is available, it is better to use the following instructions to lock CPU and GPU frequencies.
+```
+m perf-setup
+PERF_SETUP_PATH=/data/local/tmp/perf-setup.sh
+adb push $OUT/$PERF_SETUP_PATH $PERF_SETUP_PATH
+adb shell chmod +x $PERF_SETUP_PATH
+adb shell $PERF_SETUP_PATH
+```
+
+### Example to run
+Use `atest`
+```
+atest ImePerfTests:ImePerfTest -- \
+ --module-arg ImePerfTests:instrumentation-arg:profiling-iterations:=20
+
+```
+Note: `instrumentation-arg:kill-bg:=true` is already defined in the AndroidText.xml
+
+Use `am instrument`
+```
+adb shell am instrument -w -r -e class android.inputmethod.ImePerfTest \
+ -e listener android.inputmethod.ImePerfRunPrecondition \
+ -e kill-bg true \
+ com.android.perftests.inputmethod/androidx.test.runner.AndroidJUnitRunner
+```
+* `kill-bg` is optional.
+
+Test arguments
+ - kill-bg
+ * boolean: Kill background process before running test.
+ - profiling-iterations
+ * int: Run the extra iterations with enabling method profiling.
+ - profiling-sampling
+ * int: The interval (0=trace each method, default is 10) of sample profiling in microseconds.
diff --git a/apct-tests/perftests/inputmethod/res/xml/simple_method.xml b/apct-tests/perftests/inputmethod/res/xml/simple_method.xml
new file mode 100644
index 0000000..87cb1ad
--- /dev/null
+++ b/apct-tests/perftests/inputmethod/res/xml/simple_method.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Copyright (C) 2020 The Android Open Source Project
+ ~
+ ~ Licensed under the Apache License, Version 2.0 (the "License");
+ ~ you may not use this file except in compliance with the License.
+ ~ You may obtain a copy of the License at
+ ~
+ ~ http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing, software
+ ~ distributed under the License is distributed on an "AS IS" BASIS,
+ ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ ~ See the License for the specific language governing permissions and
+ ~ limitations under the License.
+ -->
+
+<!-- Configuration info for an input method -->
+<input-method xmlns:android="http://schemas.android.com/apk/res/android" />
diff --git a/apct-tests/perftests/inputmethod/src/android/inputmethod/ImePerfRunPrecondition.java b/apct-tests/perftests/inputmethod/src/android/inputmethod/ImePerfRunPrecondition.java
new file mode 100644
index 0000000..fc48fd5
--- /dev/null
+++ b/apct-tests/perftests/inputmethod/src/android/inputmethod/ImePerfRunPrecondition.java
@@ -0,0 +1,149 @@
+/*
+ * Copyright (C) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package android.inputmethod;
+
+import static android.app.WindowConfiguration.ACTIVITY_TYPE_ASSISTANT;
+import static android.app.WindowConfiguration.ACTIVITY_TYPE_RECENTS;
+import static android.app.WindowConfiguration.ACTIVITY_TYPE_STANDARD;
+import static android.app.WindowConfiguration.ACTIVITY_TYPE_UNDEFINED;
+import static android.inputmethod.ImePerfTestBase.executeShellCommand;
+import static android.inputmethod.ImePerfTestBase.runWithShellPermissionIdentity;
+
+import android.app.ActivityManager;
+import android.app.ActivityManager.RunningAppProcessInfo;
+import android.app.ActivityTaskManager;
+import android.content.Context;
+import android.inputmethod.ImePerfTestBase.SettingsSession;
+import android.os.BatteryManager;
+import android.os.Bundle;
+import android.os.SystemClock;
+import android.provider.Settings;
+import android.util.Log;
+import android.view.WindowManagerPolicyConstants;
+
+import androidx.test.platform.app.InstrumentationRegistry;
+
+import com.android.internal.policy.PhoneWindow;
+
+import org.junit.runner.Description;
+import org.junit.runner.Result;
+import org.junit.runner.notification.RunListener;
+
+import java.util.List;
+
+/** Prepare the preconditions before running performance test. */
+public class ImePerfRunPrecondition extends RunListener {
+ private static final String TAG = ImePerfRunPrecondition.class.getSimpleName();
+
+ private static final String ARGUMENT_LOG_ONLY = "log";
+ private static final String ARGUMENT_KILL_BACKGROUND = "kill-bg";
+ private static final String ARGUMENT_PROFILING_ITERATIONS = "profiling-iterations";
+ private static final String ARGUMENT_PROFILING_SAMPLING = "profiling-sampling";
+ private static final String DEFAULT_PROFILING_ITERATIONS = "10";
+ private static final String DEFAULT_PROFILING_SAMPLING_US = "10";
+ private static final long KILL_BACKGROUND_WAIT_MS = 3000;
+
+ /** The requested iterations to run with method profiling. */
+ static int sProfilingIterations;
+
+ /** The interval of sample profiling in microseconds. */
+ static int sSamplingIntervalUs;
+
+ private final Context mContext = InstrumentationRegistry.getInstrumentation().getContext();
+ private long mWaitPreconditionDoneMs = 500;
+
+ private final SettingsSession<Integer> mStayOnWhilePluggedInSetting = new SettingsSession<>(
+ Settings.Global.getInt(mContext.getContentResolver(),
+ Settings.Global.STAY_ON_WHILE_PLUGGED_IN, 0),
+ value -> executeShellCommand(String.format("settings put global %s %d",
+ Settings.Global.STAY_ON_WHILE_PLUGGED_IN, value)));
+
+ private final SettingsSession<Integer> mNavigationModeSetting = new SettingsSession<>(
+ mContext.getResources().getInteger(
+ com.android.internal.R.integer.config_navBarInteractionMode),
+ value -> {
+ final String navOverlay;
+ switch (value) {
+ case WindowManagerPolicyConstants.NAV_BAR_MODE_GESTURAL:
+ default:
+ navOverlay = WindowManagerPolicyConstants.NAV_BAR_MODE_GESTURAL_OVERLAY;
+ break;
+ }
+ executeShellCommand("cmd overlay enable-exclusive " + navOverlay);
+ });
+
+ /** It only executes once before all tests. */
+ @Override
+ public void testRunStarted(Description description) {
+ final Bundle arguments = InstrumentationRegistry.getArguments();
+ // If true, it only logs the method names without running.
+ final boolean skip = Boolean.parseBoolean(arguments.getString(ARGUMENT_LOG_ONLY, "false"));
+ Log.i(TAG, "arguments=" + arguments);
+ if (skip) {
+ return;
+ }
+ sProfilingIterations = Integer.parseInt(
+ arguments.getString(ARGUMENT_PROFILING_ITERATIONS, DEFAULT_PROFILING_ITERATIONS));
+ sSamplingIntervalUs = Integer.parseInt(
+ arguments.getString(ARGUMENT_PROFILING_SAMPLING, DEFAULT_PROFILING_SAMPLING_US));
+
+ // Use same navigation mode (gesture navigation) across all devices and tests
+ // for consistency.
+ mNavigationModeSetting.set(WindowManagerPolicyConstants.NAV_BAR_MODE_GESTURAL);
+ // Keep the device awake during testing.
+ mStayOnWhilePluggedInSetting.set(BatteryManager.BATTERY_PLUGGED_ANY);
+
+ runWithShellPermissionIdentity(() -> {
+ final ActivityTaskManager atm = mContext.getSystemService(ActivityTaskManager.class);
+ atm.removeAllVisibleRecentTasks();
+ atm.removeRootTasksWithActivityTypes(new int[] { ACTIVITY_TYPE_STANDARD,
+ ACTIVITY_TYPE_ASSISTANT, ACTIVITY_TYPE_RECENTS, ACTIVITY_TYPE_UNDEFINED });
+ });
+ PhoneWindow.sendCloseSystemWindows(mContext, "ImePerfTests");
+
+ if (Boolean.parseBoolean(arguments.getString(ARGUMENT_KILL_BACKGROUND))) {
+ runWithShellPermissionIdentity(this::killBackgroundProcesses);
+ mWaitPreconditionDoneMs = KILL_BACKGROUND_WAIT_MS;
+ }
+ // Wait a while for the precondition setup to complete.
+ SystemClock.sleep(mWaitPreconditionDoneMs);
+ }
+
+ private void killBackgroundProcesses() {
+ Log.i(TAG, "Killing background processes...");
+ final ActivityManager am = mContext.getSystemService(ActivityManager.class);
+ final List<RunningAppProcessInfo> processes = am.getRunningAppProcesses();
+ if (processes == null) {
+ return;
+ }
+ for (RunningAppProcessInfo processInfo : processes) {
+ if (processInfo.importanceReasonCode == RunningAppProcessInfo.REASON_UNKNOWN
+ && processInfo.importance > RunningAppProcessInfo.IMPORTANCE_SERVICE) {
+ for (String pkg : processInfo.pkgList) {
+ am.forceStopPackage(pkg);
+ }
+ }
+ }
+ }
+
+ /** It only executes once after all tests. */
+ @Override
+ public void testRunFinished(Result result) {
+ mNavigationModeSetting.close();
+ mStayOnWhilePluggedInSetting.close();
+ }
+}
diff --git a/apct-tests/perftests/inputmethod/src/android/inputmethod/ImePerfTest.java b/apct-tests/perftests/inputmethod/src/android/inputmethod/ImePerfTest.java
new file mode 100644
index 0000000..303c667
--- /dev/null
+++ b/apct-tests/perftests/inputmethod/src/android/inputmethod/ImePerfTest.java
@@ -0,0 +1,380 @@
+/*
+ * Copyright (C) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package android.inputmethod;
+
+import static android.perftests.utils.ManualBenchmarkState.StatsReport;
+import static android.perftests.utils.PerfTestActivity.ID_EDITOR;
+import static android.view.ViewGroup.LayoutParams.MATCH_PARENT;
+import static android.view.WindowInsetsAnimation.Callback.DISPATCH_MODE_STOP;
+
+import static androidx.test.platform.app.InstrumentationRegistry.getInstrumentation;
+
+import android.app.Activity;
+import android.content.ComponentName;
+import android.content.Context;
+import android.inputmethodservice.InputMethodService;
+import android.os.ParcelFileDescriptor;
+import android.os.SystemClock;
+import android.perftests.utils.ManualBenchmarkState;
+import android.perftests.utils.ManualBenchmarkState.ManualBenchmarkTest;
+import android.perftests.utils.PerfManualStatusReporter;
+import android.perftests.utils.TraceMarkParser;
+import android.perftests.utils.TraceMarkParser.TraceMarkSlice;
+import android.provider.Settings;
+import android.util.Log;
+import android.view.View;
+import android.view.ViewGroup;
+import android.view.WindowInsets;
+import android.view.WindowInsetsAnimation;
+import android.view.WindowInsetsController;
+import android.view.inputmethod.InputMethodManager;
+import android.widget.FrameLayout;
+
+import androidx.annotation.NonNull;
+import androidx.annotation.Nullable;
+import androidx.test.filters.LargeTest;
+
+import com.android.compatibility.common.util.PollingCheck;
+
+import junit.framework.Assert;
+
+import org.junit.Rule;
+import org.junit.Test;
+
+import java.io.BufferedReader;
+import java.io.IOException;
+import java.io.InputStream;
+import java.io.InputStreamReader;
+import java.util.List;
+import java.util.concurrent.CountDownLatch;
+import java.util.concurrent.TimeUnit;
+import java.util.concurrent.atomic.AtomicLong;
+import java.util.concurrent.atomic.AtomicReference;
+
+/** Measure the performance of internal methods in Input Method framework by trace tag. */
+@LargeTest
+public class ImePerfTest extends ImePerfTestBase
+ implements ManualBenchmarkState.CustomizedIterationListener {
+ private static final String TAG = ImePerfTest.class.getSimpleName();
+
+ @Rule
+ public final PerfManualStatusReporter mPerfStatusReporter = new PerfManualStatusReporter();
+
+ @Rule
+ public final PerfTestActivityRule mActivityRule = new PerfTestActivityRule();
+
+ /**
+ * IMF common methods to log for show/hide in trace.
+ */
+ private String[] mCommonMethods = {
+ "IC.pendingAnim",
+ "IMMS.applyImeVisibility",
+ "applyPostLayoutPolicy",
+ "applyWindowSurfaceChanges",
+ "ISC.onPostLayout"
+ };
+
+ /** IMF show methods to log in trace. */
+ private String[] mShowMethods = {
+ "IC.showRequestFromIme",
+ "IC.showRequestFromApi",
+ "IC.showRequestFromApiToImeReady",
+ "IC.pendingAnim",
+ "IMMS.applyImeVisibility",
+ "IMMS.showMySoftInput",
+ "IMMS.showSoftInput",
+ "IMS.showSoftInput",
+ "IMS.startInput",
+ "WMS.showImePostLayout"
+ };
+
+ /** IMF hide lifecycle methods to log in trace. */
+ private String[] mHideMethods = {
+ "IC.hideRequestFromIme",
+ "IC.hideRequestFromApi",
+ "IMMS.hideMySoftInput",
+ "IMMS.hideSoftInput",
+ "IMS.hideSoftInput",
+ "WMS.hideIme"
+ };
+
+ /**
+ * IMF methods to log in trace.
+ */
+ private TraceMarkParser mTraceMethods;
+
+ private boolean mIsTraceStarted;
+
+ /**
+ * Ime Session for {@link BaselineIme}.
+ */
+ private static class ImeSession implements AutoCloseable {
+
+ private static final long TIMEOUT = 2000;
+ private final ComponentName mImeName;
+ private Context mContext = getInstrumentation().getContext();
+
+ ImeSession(ComponentName ime) throws Exception {
+ mImeName = ime;
+ // using adb, enable and set Baseline IME.
+ executeShellCommand("ime reset");
+ executeShellCommand("ime enable " + ime.flattenToShortString());
+ executeShellCommand("ime set " + ime.flattenToShortString());
+ PollingCheck.check("Make sure that BaselineIme becomes available "
+ + getCurrentInputMethodId(), TIMEOUT,
+ () -> ime.equals(getCurrentInputMethodId()));
+ }
+
+ @Override
+ public void close() throws Exception {
+ executeShellCommand("ime reset");
+ PollingCheck.check("Make sure that Baseline IME becomes unavailable", TIMEOUT, () ->
+ mContext.getSystemService(InputMethodManager.class)
+ .getEnabledInputMethodList()
+ .stream()
+ .noneMatch(info -> mImeName.equals(info.getComponent())));
+ }
+
+ @Nullable
+ private ComponentName getCurrentInputMethodId() {
+ return ComponentName.unflattenFromString(
+ Settings.Secure.getString(mContext.getContentResolver(),
+ Settings.Secure.DEFAULT_INPUT_METHOD));
+ }
+ }
+
+ /**
+ * A minimal baseline IME (that has a single static view) used to measure IMF latency.
+ */
+ public static class BaselineIme extends InputMethodService {
+
+ public static final int HEIGHT_DP = 100;
+
+ @Override
+ public View onCreateInputView() {
+ final ViewGroup view = new FrameLayout(this);
+ final View inner = new View(this);
+ final float density = getResources().getDisplayMetrics().density;
+ final int height = (int) (HEIGHT_DP * density);
+ view.setPadding(0, 0, 0, 0);
+ view.addView(inner, new FrameLayout.LayoutParams(MATCH_PARENT, height));
+ inner.setBackgroundColor(0xff01fe10); // green
+ return view;
+ }
+
+ static ComponentName getName(Context context) {
+ return new ComponentName(context, BaselineIme.class);
+ }
+ }
+
+ @Test
+ @ManualBenchmarkTest(
+ targetTestDurationNs = 10 * TIME_1_S_IN_NS,
+ statsReport = @StatsReport(
+ flags = StatsReport.FLAG_ITERATION | StatsReport.FLAG_MEAN
+ | StatsReport.FLAG_MIN | StatsReport.FLAG_MAX
+ | StatsReport.FLAG_COEFFICIENT_VAR))
+ public void testShowIme() throws Throwable {
+ testShowOrHideIme(true /* show */);
+ }
+
+ @Test
+ @ManualBenchmarkTest(
+ targetTestDurationNs = 10 * TIME_1_S_IN_NS,
+ statsReport = @StatsReport(
+ flags = StatsReport.FLAG_ITERATION | StatsReport.FLAG_MEAN
+ | StatsReport.FLAG_MIN | StatsReport.FLAG_MAX
+ | StatsReport.FLAG_COEFFICIENT_VAR))
+ public void testHideIme() throws Throwable {
+ testShowOrHideIme(false /* show */);
+ }
+
+ private void testShowOrHideIme(final boolean show) throws Throwable {
+ mTraceMethods = new TraceMarkParser(buildArray(
+ mCommonMethods, show ? mShowMethods : mHideMethods));
+ final ManualBenchmarkState state = mPerfStatusReporter.getBenchmarkState();
+ state.setCustomizedIterations(getProfilingIterations(), this);
+ long measuredTimeNs = 0;
+ try (ImeSession imeSession = new ImeSession(BaselineIme.getName(
+ getInstrumentation().getContext()))) {
+ final AtomicReference<CountDownLatch> latchStart = new AtomicReference<>();
+ final AtomicReference<CountDownLatch> latchEnd = new AtomicReference<>();
+ final Activity activity = getActivityWithFocus();
+
+ // call IME show/hide
+ final WindowInsetsController controller =
+ activity.getWindow().getDecorView().getWindowInsetsController();
+
+ while (state.keepRunning(measuredTimeNs)) {
+ setImeListener(activity, latchStart, latchEnd);
+ latchStart.set(new CountDownLatch(show ? 1 : 2));
+ latchEnd.set(new CountDownLatch(2));
+ // For measuring hide, lets show IME first.
+ if (!show) {
+ activity.runOnUiThread(() -> {
+ controller.show(WindowInsets.Type.ime());
+ });
+ PollingCheck.check("IME show animation should finish ", TIMEOUT_1_S_IN_MS,
+ () -> latchStart.get().getCount() == 1
+ && latchEnd.get().getCount() == 1);
+ }
+ if (!mIsTraceStarted && !state.isWarmingUp()) {
+ startAsyncAtrace();
+ mIsTraceStarted = true;
+ }
+
+ AtomicLong startTime = new AtomicLong();
+ activity.runOnUiThread(() -> {
+ startTime.set(SystemClock.elapsedRealtimeNanos());
+ if (show) {
+ controller.show(WindowInsets.Type.ime());
+ } else {
+ controller.hide(WindowInsets.Type.ime());
+ }
+ });
+
+ measuredTimeNs = waitForAnimationStart(latchStart, startTime);
+
+ // hide IME before next iteration.
+ if (show) {
+ activity.runOnUiThread(() -> controller.hide(WindowInsets.Type.ime()));
+ try {
+ latchEnd.get().await(TIMEOUT_1_S_IN_MS * 5, TimeUnit.MILLISECONDS);
+ if (latchEnd.get().getCount() != 0) {
+ Assert.fail("IME hide animation should finish.");
+ }
+ } catch (InterruptedException e) {
+ }
+ }
+ }
+ } finally {
+ if (mIsTraceStarted) {
+ stopAsyncAtrace();
+ }
+ }
+ mActivityRule.finishActivity();
+
+ addResultToState(state);
+ }
+
+ private long waitForAnimationStart(
+ AtomicReference<CountDownLatch> latchStart, AtomicLong startTime) {
+ try {
+ latchStart.get().await(TIMEOUT_1_S_IN_MS * 5, TimeUnit.MILLISECONDS);
+ if (latchStart.get().getCount() != 0) {
+ Assert.fail("IME animation should start " + latchStart.get().getCount());
+ }
+ } catch (InterruptedException e) { }
+
+ return SystemClock.elapsedRealtimeNanos() - startTime.get();
+ }
+
+ private void addResultToState(ManualBenchmarkState state) {
+ mTraceMethods.forAllSlices((key, slices) -> {
+ for (TraceMarkSlice slice : slices) {
+ state.addExtraResult(key, (long) (slice.getDurationInSeconds() * NANOS_PER_S));
+ }
+ });
+ Log.i(TAG, String.valueOf(mTraceMethods));
+ }
+
+ private Activity getActivityWithFocus() throws Exception {
+ final Activity activity = mActivityRule.launchActivity();
+ PollingCheck.check("Activity onResume()", TIMEOUT_1_S_IN_MS,
+ () -> activity.isResumed());
+
+ View editor = activity.findViewById(ID_EDITOR);
+ editor.requestFocus();
+
+ // wait till editor is focused so we don't count activity/view latency.
+ PollingCheck.check("Editor is focused", TIMEOUT_1_S_IN_MS,
+ () -> editor.isFocused());
+ getInstrumentation().waitForIdleSync();
+
+ return activity;
+ }
+
+ private void setImeListener(Activity activity,
+ @NonNull AtomicReference<CountDownLatch> latchStart,
+ @Nullable AtomicReference<CountDownLatch> latchEnd) {
+ // set IME animation listener
+ activity.getWindow().getDecorView().setWindowInsetsAnimationCallback(
+ new WindowInsetsAnimation.Callback(DISPATCH_MODE_STOP) {
+ @NonNull
+ @Override
+ public WindowInsetsAnimation.Bounds onStart(
+ @NonNull WindowInsetsAnimation animation,
+ @NonNull WindowInsetsAnimation.Bounds bounds) {
+ latchStart.get().countDown();
+ return super.onStart(animation, bounds);
+ }
+
+ @NonNull
+ @Override
+ public WindowInsets onProgress(@NonNull WindowInsets insets,
+ @NonNull List<WindowInsetsAnimation> runningAnimations) {
+ return insets;
+ }
+
+ @Override
+ public void onEnd(@NonNull WindowInsetsAnimation animation) {
+ super.onEnd(animation);
+ if (latchEnd != null) {
+ latchEnd.get().countDown();
+ }
+ }
+ });
+ }
+
+ private void startAsyncAtrace() throws IOException {
+ mIsTraceStarted = true;
+ // IMF uses 'wm' component for trace in InputMethodService, InputMethodManagerService,
+ // WindowManagerService and 'view' for client window (InsetsController).
+ // TODO(b/167947940): Consider a separate input_method atrace
+ UI_AUTOMATION.executeShellCommand("atrace -b 32768 --async_start wm view");
+ // Avoid atrace isn't ready immediately.
+ SystemClock.sleep(TimeUnit.NANOSECONDS.toMillis(TIME_1_S_IN_NS));
+ }
+
+ private void stopAsyncAtrace() {
+ if (!mIsTraceStarted) {
+ return;
+ }
+ final ParcelFileDescriptor pfd = UI_AUTOMATION.executeShellCommand("atrace --async_stop");
+ mIsTraceStarted = false;
+ final InputStream inputStream = new ParcelFileDescriptor.AutoCloseInputStream(pfd);
+ try (BufferedReader reader = new BufferedReader(new InputStreamReader(inputStream))) {
+ String line;
+ while ((line = reader.readLine()) != null) {
+ mTraceMethods.visit(line);
+ }
+ } catch (IOException e) {
+ Log.w(TAG, "Failed to read the result of stopped atrace", e);
+ }
+ }
+
+ @Override
+ public void onStart(int iteration) {
+ // Do not capture trace when profiling because the result will be much slower.
+ stopAsyncAtrace();
+ }
+
+ @Override
+ public void onFinished(int iteration) {
+ // do nothing.
+ }
+}
diff --git a/apct-tests/perftests/inputmethod/src/android/inputmethod/ImePerfTestBase.java b/apct-tests/perftests/inputmethod/src/android/inputmethod/ImePerfTestBase.java
new file mode 100644
index 0000000..1a861d7
--- /dev/null
+++ b/apct-tests/perftests/inputmethod/src/android/inputmethod/ImePerfTestBase.java
@@ -0,0 +1,165 @@
+/*
+ * Copyright (C) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package android.inputmethod;
+
+import static android.perftests.utils.PerfTestActivity.INTENT_EXTRA_ADD_EDIT_TEXT;
+
+import static androidx.test.platform.app.InstrumentationRegistry.getInstrumentation;
+
+import android.app.KeyguardManager;
+import android.app.UiAutomation;
+import android.content.Context;
+import android.content.Intent;
+import android.os.ParcelFileDescriptor;
+import android.os.PowerManager;
+import android.perftests.utils.PerfTestActivity;
+
+
+import androidx.test.rule.ActivityTestRule;
+
+import org.junit.BeforeClass;
+
+import java.io.ByteArrayOutputStream;
+import java.io.FileInputStream;
+import java.io.IOException;
+import java.util.Objects;
+import java.util.function.Consumer;
+
+public class ImePerfTestBase {
+ static final UiAutomation UI_AUTOMATION = getInstrumentation().getUiAutomation();
+ static final long NANOS_PER_S = 1000L * 1000 * 1000;
+ static final long TIME_1_S_IN_NS = 1 * NANOS_PER_S;
+ static final long TIMEOUT_1_S_IN_MS = 1 * 1000L;
+
+ @BeforeClass
+ public static void setUpOnce() {
+ final Context context = getInstrumentation().getContext();
+
+ if (!context.getSystemService(PowerManager.class).isInteractive()
+ || context.getSystemService(KeyguardManager.class).isKeyguardLocked()) {
+ executeShellCommand("input keyevent KEYCODE_WAKEUP");
+ executeShellCommand("wm dismiss-keyguard");
+ }
+ context.startActivity(new Intent(Intent.ACTION_MAIN)
+ .addCategory(Intent.CATEGORY_HOME).setFlags(Intent.FLAG_ACTIVITY_NEW_TASK));
+ }
+
+ /**
+ * Executes shell command with reading the output. It may also used to block until the current
+ * command is completed.
+ */
+ static ByteArrayOutputStream executeShellCommand(String command) {
+ final ParcelFileDescriptor pfd = UI_AUTOMATION.executeShellCommand(command);
+ final byte[] buf = new byte[512];
+ final ByteArrayOutputStream bytes = new ByteArrayOutputStream();
+ int bytesRead;
+ try (FileInputStream fis = new ParcelFileDescriptor.AutoCloseInputStream(pfd)) {
+ while ((bytesRead = fis.read(buf)) != -1) {
+ bytes.write(buf, 0, bytesRead);
+ }
+ } catch (IOException e) {
+ throw new RuntimeException(e);
+ }
+ return bytes;
+ }
+
+ /** Returns how many iterations should run with method tracing. */
+ static int getProfilingIterations() {
+ return ImePerfRunPrecondition.sProfilingIterations;
+ }
+
+ static void runWithShellPermissionIdentity(Runnable runnable) {
+ UI_AUTOMATION.adoptShellPermissionIdentity();
+ try {
+ runnable.run();
+ } finally {
+ UI_AUTOMATION.dropShellPermissionIdentity();
+ }
+ }
+
+ static class SettingsSession<T> implements AutoCloseable {
+ private final Consumer<T> mSetter;
+ private final T mOriginalValue;
+ private boolean mChanged;
+
+ SettingsSession(T originalValue, Consumer<T> setter) {
+ mOriginalValue = originalValue;
+ mSetter = setter;
+ }
+
+ void set(T value) {
+ if (Objects.equals(value, mOriginalValue)) {
+ mChanged = false;
+ return;
+ }
+ mSetter.accept(value);
+ mChanged = true;
+ }
+
+ @Override
+ public void close() {
+ if (mChanged) {
+ mSetter.accept(mOriginalValue);
+ }
+ }
+ }
+
+ /**
+ * Provides an activity that keeps screen on and is able to wait for a stable lifecycle stage.
+ */
+ static class PerfTestActivityRule extends ActivityTestRule<PerfTestActivity> {
+ private final Intent mStartIntent =
+ new Intent(getInstrumentation().getTargetContext(), PerfTestActivity.class);
+
+ PerfTestActivityRule() {
+ this(false /* launchActivity */);
+ }
+
+ PerfTestActivityRule(boolean launchActivity) {
+ super(PerfTestActivity.class, false /* initialTouchMode */, launchActivity);
+ }
+
+ @Override
+ protected Intent getActivityIntent() {
+ return mStartIntent;
+ }
+
+ @Override
+ public PerfTestActivity launchActivity(Intent intent) {
+ intent.putExtra(INTENT_EXTRA_ADD_EDIT_TEXT, true);
+ return super.launchActivity(intent);
+ }
+
+ PerfTestActivity launchActivity() {
+ return launchActivity(mStartIntent);
+ }
+ }
+
+ static String[] buildArray(String[]... arrays) {
+ int length = 0;
+ for (String[] array : arrays) {
+ length += array.length;
+ }
+ String[] newArray = new String[length];
+ int offset = 0;
+ for (String[] array : arrays) {
+ System.arraycopy(array, 0, newArray, offset, array.length);
+ offset += array.length;
+ }
+ return newArray;
+ }
+}
diff --git a/apct-tests/perftests/utils/src/android/perftests/utils/PerfTestActivity.java b/apct-tests/perftests/utils/src/android/perftests/utils/PerfTestActivity.java
index e934feb..f3bea17 100644
--- a/apct-tests/perftests/utils/src/android/perftests/utils/PerfTestActivity.java
+++ b/apct-tests/perftests/utils/src/android/perftests/utils/PerfTestActivity.java
@@ -21,6 +21,8 @@
import android.content.Intent;
import android.os.Bundle;
import android.view.WindowManager;
+import android.widget.EditText;
+import android.widget.LinearLayout;
/**
* A simple activity used for testing, e.g. performance of activity switching, or as a base
@@ -28,6 +30,8 @@
*/
public class PerfTestActivity extends Activity {
public static final String INTENT_EXTRA_KEEP_SCREEN_ON = "keep_screen_on";
+ public static final String INTENT_EXTRA_ADD_EDIT_TEXT = "add_edit_text";
+ public static final int ID_EDITOR = 3252356;
@Override
protected void onCreate(Bundle savedInstanceState) {
@@ -35,6 +39,15 @@
if (getIntent().getBooleanExtra(INTENT_EXTRA_KEEP_SCREEN_ON, false)) {
getWindow().addFlags(WindowManager.LayoutParams.FLAG_KEEP_SCREEN_ON);
}
+ if (getIntent().getBooleanExtra(INTENT_EXTRA_ADD_EDIT_TEXT, false)) {
+ final LinearLayout layout = new LinearLayout(this);
+ layout.setOrientation(LinearLayout.VERTICAL);
+
+ final EditText editText = new EditText(this);
+ editText.setId(ID_EDITOR);
+ layout.addView(editText);
+ setContentView(layout);
+ }
}
public static Intent createLaunchIntent(Context context) {
diff --git a/apex/jobscheduler/framework/java/android/app/job/JobParameters.java b/apex/jobscheduler/framework/java/android/app/job/JobParameters.java
index 62c90dfa..e251ff0 100644
--- a/apex/jobscheduler/framework/java/android/app/job/JobParameters.java
+++ b/apex/jobscheduler/framework/java/android/app/job/JobParameters.java
@@ -21,6 +21,7 @@
import android.compat.annotation.UnsupportedAppUsage;
import android.content.ClipData;
import android.net.Network;
+import android.net.NetworkRequest;
import android.net.Uri;
import android.os.Bundle;
import android.os.IBinder;
@@ -242,8 +243,9 @@
*
* @return the network that should be used to perform any network requests
* for this job, or {@code null} if this job didn't set any required
- * network type.
+ * network type or if the job executed when there was no available network to use.
* @see JobInfo.Builder#setRequiredNetworkType(int)
+ * @see JobInfo.Builder#setRequiredNetwork(NetworkRequest)
*/
public @Nullable Network getNetwork() {
return network;
diff --git a/apex/jobscheduler/framework/java/android/app/job/JobScheduler.java b/apex/jobscheduler/framework/java/android/app/job/JobScheduler.java
index bf5781b..361325d 100644
--- a/apex/jobscheduler/framework/java/android/app/job/JobScheduler.java
+++ b/apex/jobscheduler/framework/java/android/app/job/JobScheduler.java
@@ -169,6 +169,7 @@
* @param tag Debugging tag for dumps associated with this job (instead of the service class)
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
@RequiresPermission(android.Manifest.permission.UPDATE_DEVICE_STATS)
public abstract @Result int scheduleAsPackage(@NonNull JobInfo job, @NonNull String packageName,
@@ -211,6 +212,7 @@
* Returns a list of all currently-executing jobs.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
public abstract List<JobInfo> getStartedJobs();
/**
@@ -220,5 +222,6 @@
* <p class="note">This is a slow operation, so it should be called sparingly.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
public abstract List<JobSnapshot> getAllJobSnapshots();
}
\ No newline at end of file
diff --git a/apex/jobscheduler/service/java/com/android/server/alarm/AlarmManagerService.java b/apex/jobscheduler/service/java/com/android/server/alarm/AlarmManagerService.java
index ba2a8a3..d4ea7af 100644
--- a/apex/jobscheduler/service/java/com/android/server/alarm/AlarmManagerService.java
+++ b/apex/jobscheduler/service/java/com/android/server/alarm/AlarmManagerService.java
@@ -439,7 +439,7 @@
private static final int DEFAULT_APP_STANDBY_RESTRICTED_QUOTA = 1;
private static final long DEFAULT_APP_STANDBY_RESTRICTED_WINDOW = MILLIS_IN_DAY;
- private static final boolean DEFAULT_LAZY_BATCHING = false;
+ private static final boolean DEFAULT_LAZY_BATCHING = true;
// Minimum futurity of a new alarm
public long MIN_FUTURITY = DEFAULT_MIN_FUTURITY;
diff --git a/apex/jobscheduler/service/java/com/android/server/job/JobSchedulerShellCommand.java b/apex/jobscheduler/service/java/com/android/server/job/JobSchedulerShellCommand.java
index cc20213..1e72062 100644
--- a/apex/jobscheduler/service/java/com/android/server/job/JobSchedulerShellCommand.java
+++ b/apex/jobscheduler/service/java/com/android/server/job/JobSchedulerShellCommand.java
@@ -20,11 +20,10 @@
import android.app.AppGlobals;
import android.content.pm.IPackageManager;
import android.content.pm.PackageManager;
+import android.os.BasicShellCommandHandler;
import android.os.Binder;
import android.os.UserHandle;
-import com.android.modules.utils.BasicShellCommandHandler;
-
import java.io.PrintWriter;
public final class JobSchedulerShellCommand extends BasicShellCommandHandler {
diff --git a/apex/permission/Android.bp b/apex/permission/Android.bp
index 71a52bb..e30df05 100644
--- a/apex/permission/Android.bp
+++ b/apex/permission/Android.bp
@@ -21,7 +21,7 @@
apex_defaults {
name: "com.android.permission-defaults",
updatable: true,
- min_sdk_version: "R",
+ min_sdk_version: "30",
key: "com.android.permission.key",
certificate: ":com.android.permission.certificate",
java_libs: [
diff --git a/apex/statsd/Android.bp b/apex/statsd/Android.bp
index ede8852..f13861e 100644
--- a/apex/statsd/Android.bp
+++ b/apex/statsd/Android.bp
@@ -35,7 +35,7 @@
prebuilts: ["com.android.os.statsd.init.rc"],
name: "com.android.os.statsd-defaults",
updatable: true,
- min_sdk_version: "R",
+ min_sdk_version: "30",
key: "com.android.os.statsd.key",
certificate: ":com.android.os.statsd.certificate",
}
diff --git a/api/current.txt b/api/current.txt
index 2ebb75d..8c23fb7 100644
--- a/api/current.txt
+++ b/api/current.txt
@@ -6950,6 +6950,7 @@
method @Nullable public java.util.List<java.lang.String> getPermittedCrossProfileNotificationListeners(@NonNull android.content.ComponentName);
method @Nullable public java.util.List<java.lang.String> getPermittedInputMethods(@NonNull android.content.ComponentName);
method public int getPersonalAppsSuspendedReasons(@NonNull android.content.ComponentName);
+ method public int getRequiredPasswordComplexity();
method public long getRequiredStrongAuthTimeout(@Nullable android.content.ComponentName);
method public boolean getScreenCaptureDisabled(@Nullable android.content.ComponentName);
method public java.util.List<android.os.UserHandle> getSecondaryUsers(@NonNull android.content.ComponentName);
@@ -7081,6 +7082,7 @@
method public void setProfileEnabled(@NonNull android.content.ComponentName);
method public void setProfileName(@NonNull android.content.ComponentName, String);
method public void setRecommendedGlobalProxy(@NonNull android.content.ComponentName, @Nullable android.net.ProxyInfo);
+ method public void setRequiredPasswordComplexity(int);
method public void setRequiredStrongAuthTimeout(@NonNull android.content.ComponentName, long);
method public boolean setResetPasswordToken(android.content.ComponentName, byte[]);
method public void setRestrictionsProvider(@NonNull android.content.ComponentName, @Nullable android.content.ComponentName);
@@ -24388,6 +24390,8 @@
field public static final int ENCODING_MP3 = 9; // 0x9
field public static final int ENCODING_OPUS = 20; // 0x14
field public static final int ENCODING_PCM_16BIT = 2; // 0x2
+ field public static final int ENCODING_PCM_24BIT_PACKED = 21; // 0x15
+ field public static final int ENCODING_PCM_32BIT = 22; // 0x16
field public static final int ENCODING_PCM_8BIT = 3; // 0x3
field public static final int ENCODING_PCM_FLOAT = 4; // 0x4
field public static final int SAMPLE_RATE_UNSPECIFIED = 0; // 0x0
@@ -46138,6 +46142,8 @@
field public static final String EXTRA_ANSWERING_DROPS_FG_CALL = "android.telecom.extra.ANSWERING_DROPS_FG_CALL";
field public static final String EXTRA_ANSWERING_DROPS_FG_CALL_APP_NAME = "android.telecom.extra.ANSWERING_DROPS_FG_CALL_APP_NAME";
field public static final String EXTRA_AUDIO_CODEC = "android.telecom.extra.AUDIO_CODEC";
+ field public static final String EXTRA_AUDIO_CODEC_BANDWIDTH_KHZ = "android.telecom.extra.AUDIO_CODEC_BANDWIDTH_KHZ";
+ field public static final String EXTRA_AUDIO_CODEC_BITRATE_KBPS = "android.telecom.extra.AUDIO_CODEC_BITRATE_KBPS";
field public static final String EXTRA_CALL_SUBJECT = "android.telecom.extra.CALL_SUBJECT";
field public static final String EXTRA_CHILD_ADDRESS = "android.telecom.extra.CHILD_ADDRESS";
field public static final String EXTRA_IS_RTT_AUDIO_PRESENT = "android.telecom.extra.IS_RTT_AUDIO_PRESENT";
@@ -53854,16 +53860,17 @@
field public int toolType;
}
- public interface OnReceiveContentCallback<T extends android.view.View> {
- method public boolean onReceiveContent(@NonNull T, @NonNull android.view.OnReceiveContentCallback.Payload);
+ public interface OnReceiveContentListener {
+ method @Nullable public android.view.OnReceiveContentListener.Payload onReceiveContent(@NonNull android.view.View, @NonNull android.view.OnReceiveContentListener.Payload);
}
- public static final class OnReceiveContentCallback.Payload {
+ public static final class OnReceiveContentListener.Payload {
method @NonNull public android.content.ClipData getClip();
method @Nullable public android.os.Bundle getExtras();
method public int getFlags();
method @Nullable public android.net.Uri getLinkUri();
method public int getSource();
+ method @NonNull public java.util.Map<java.lang.Boolean,android.view.OnReceiveContentListener.Payload> partition(@NonNull java.util.function.Predicate<android.content.ClipData.Item>);
field public static final int FLAG_CONVERT_TO_PLAIN_TEXT = 1; // 0x1
field public static final int SOURCE_APP = 0; // 0x0
field public static final int SOURCE_AUTOFILL = 4; // 0x4
@@ -53873,12 +53880,15 @@
field public static final int SOURCE_PROCESS_TEXT = 5; // 0x5
}
- public static final class OnReceiveContentCallback.Payload.Builder {
- ctor public OnReceiveContentCallback.Payload.Builder(@NonNull android.content.ClipData, int);
- method @NonNull public android.view.OnReceiveContentCallback.Payload build();
- method @NonNull public android.view.OnReceiveContentCallback.Payload.Builder setExtras(@Nullable android.os.Bundle);
- method @NonNull public android.view.OnReceiveContentCallback.Payload.Builder setFlags(int);
- method @NonNull public android.view.OnReceiveContentCallback.Payload.Builder setLinkUri(@Nullable android.net.Uri);
+ public static final class OnReceiveContentListener.Payload.Builder {
+ ctor public OnReceiveContentListener.Payload.Builder(@NonNull android.view.OnReceiveContentListener.Payload);
+ ctor public OnReceiveContentListener.Payload.Builder(@NonNull android.content.ClipData, int);
+ method @NonNull public android.view.OnReceiveContentListener.Payload build();
+ method @NonNull public android.view.OnReceiveContentListener.Payload.Builder setClip(@NonNull android.content.ClipData);
+ method @NonNull public android.view.OnReceiveContentListener.Payload.Builder setExtras(@Nullable android.os.Bundle);
+ method @NonNull public android.view.OnReceiveContentListener.Payload.Builder setFlags(int);
+ method @NonNull public android.view.OnReceiveContentListener.Payload.Builder setLinkUri(@Nullable android.net.Uri);
+ method @NonNull public android.view.OnReceiveContentListener.Payload.Builder setSource(int);
}
public abstract class OrientationEventListener {
@@ -54627,7 +54637,7 @@
method public void onProvideContentCaptureStructure(@NonNull android.view.ViewStructure, int);
method public void onProvideStructure(android.view.ViewStructure);
method public void onProvideVirtualStructure(android.view.ViewStructure);
- method public boolean onReceiveContent(@NonNull android.view.OnReceiveContentCallback.Payload);
+ method @Nullable public android.view.OnReceiveContentListener.Payload onReceiveContent(@NonNull android.view.OnReceiveContentListener.Payload);
method public android.view.PointerIcon onResolvePointerIcon(android.view.MotionEvent, int);
method @CallSuper protected void onRestoreInstanceState(android.os.Parcelable);
method public void onRtlPropertiesChanged(int);
@@ -54785,7 +54795,7 @@
method public void setOnHoverListener(android.view.View.OnHoverListener);
method public void setOnKeyListener(android.view.View.OnKeyListener);
method public void setOnLongClickListener(@Nullable android.view.View.OnLongClickListener);
- method public void setOnReceiveContentCallback(@Nullable String[], @Nullable android.view.OnReceiveContentCallback);
+ method public void setOnReceiveContentListener(@Nullable String[], @Nullable android.view.OnReceiveContentListener);
method public void setOnScrollChangeListener(android.view.View.OnScrollChangeListener);
method @Deprecated public void setOnSystemUiVisibilityChangeListener(android.view.View.OnSystemUiVisibilityChangeListener);
method public void setOnTouchListener(android.view.View.OnTouchListener);
@@ -61802,11 +61812,6 @@
field @NonNull public static final android.os.Parcelable.Creator<android.widget.TextView.SavedState> CREATOR;
}
- public class TextViewOnReceiveContentCallback implements android.view.OnReceiveContentCallback<android.widget.TextView> {
- ctor public TextViewOnReceiveContentCallback();
- method public boolean onReceiveContent(@NonNull android.widget.TextView, @NonNull android.view.OnReceiveContentCallback.Payload);
- }
-
public interface ThemedSpinnerAdapter extends android.widget.SpinnerAdapter {
method @Nullable public android.content.res.Resources.Theme getDropDownViewTheme();
method public void setDropDownViewTheme(@Nullable android.content.res.Resources.Theme);
diff --git a/api/system-current.txt b/api/system-current.txt
deleted file mode 100644
index 73602ae..0000000
--- a/api/system-current.txt
+++ /dev/null
@@ -1,13917 +0,0 @@
-// Signature format: 2.0
-package android {
-
- public static final class Manifest.permission {
- field public static final String ACCESS_AMBIENT_LIGHT_STATS = "android.permission.ACCESS_AMBIENT_LIGHT_STATS";
- field public static final String ACCESS_BROADCAST_RADIO = "android.permission.ACCESS_BROADCAST_RADIO";
- field public static final String ACCESS_CACHE_FILESYSTEM = "android.permission.ACCESS_CACHE_FILESYSTEM";
- field public static final String ACCESS_CONTEXT_HUB = "android.permission.ACCESS_CONTEXT_HUB";
- field public static final String ACCESS_DRM_CERTIFICATES = "android.permission.ACCESS_DRM_CERTIFICATES";
- field @Deprecated public static final String ACCESS_FM_RADIO = "android.permission.ACCESS_FM_RADIO";
- field public static final String ACCESS_INSTANT_APPS = "android.permission.ACCESS_INSTANT_APPS";
- field public static final String ACCESS_LOCUS_ID_USAGE_STATS = "android.permission.ACCESS_LOCUS_ID_USAGE_STATS";
- field public static final String ACCESS_MOCK_LOCATION = "android.permission.ACCESS_MOCK_LOCATION";
- field public static final String ACCESS_MTP = "android.permission.ACCESS_MTP";
- field public static final String ACCESS_NETWORK_CONDITIONS = "android.permission.ACCESS_NETWORK_CONDITIONS";
- field public static final String ACCESS_NOTIFICATIONS = "android.permission.ACCESS_NOTIFICATIONS";
- field public static final String ACCESS_SHARED_LIBRARIES = "android.permission.ACCESS_SHARED_LIBRARIES";
- field public static final String ACCESS_SHORTCUTS = "android.permission.ACCESS_SHORTCUTS";
- field public static final String ACCESS_SURFACE_FLINGER = "android.permission.ACCESS_SURFACE_FLINGER";
- field public static final String ACCESS_TV_DESCRAMBLER = "android.permission.ACCESS_TV_DESCRAMBLER";
- field public static final String ACCESS_TV_TUNER = "android.permission.ACCESS_TV_TUNER";
- field public static final String ACCESS_VIBRATOR_STATE = "android.permission.ACCESS_VIBRATOR_STATE";
- field public static final String ACTIVITY_EMBEDDING = "android.permission.ACTIVITY_EMBEDDING";
- field public static final String ADJUST_RUNTIME_PERMISSIONS_POLICY = "android.permission.ADJUST_RUNTIME_PERMISSIONS_POLICY";
- field public static final String ALLOCATE_AGGRESSIVE = "android.permission.ALLOCATE_AGGRESSIVE";
- field public static final String ALLOW_ANY_CODEC_FOR_PLAYBACK = "android.permission.ALLOW_ANY_CODEC_FOR_PLAYBACK";
- field public static final String AMBIENT_WALLPAPER = "android.permission.AMBIENT_WALLPAPER";
- field public static final String APPROVE_INCIDENT_REPORTS = "android.permission.APPROVE_INCIDENT_REPORTS";
- field public static final String BACKUP = "android.permission.BACKUP";
- field public static final String BIND_ATTENTION_SERVICE = "android.permission.BIND_ATTENTION_SERVICE";
- field public static final String BIND_AUGMENTED_AUTOFILL_SERVICE = "android.permission.BIND_AUGMENTED_AUTOFILL_SERVICE";
- field public static final String BIND_CELL_BROADCAST_SERVICE = "android.permission.BIND_CELL_BROADCAST_SERVICE";
- field @Deprecated public static final String BIND_CONNECTION_SERVICE = "android.permission.BIND_CONNECTION_SERVICE";
- field public static final String BIND_CONTENT_CAPTURE_SERVICE = "android.permission.BIND_CONTENT_CAPTURE_SERVICE";
- field public static final String BIND_CONTENT_SUGGESTIONS_SERVICE = "android.permission.BIND_CONTENT_SUGGESTIONS_SERVICE";
- field public static final String BIND_DIRECTORY_SEARCH = "android.permission.BIND_DIRECTORY_SEARCH";
- field public static final String BIND_EUICC_SERVICE = "android.permission.BIND_EUICC_SERVICE";
- field public static final String BIND_EXTERNAL_STORAGE_SERVICE = "android.permission.BIND_EXTERNAL_STORAGE_SERVICE";
- field public static final String BIND_IMS_SERVICE = "android.permission.BIND_IMS_SERVICE";
- field public static final String BIND_KEYGUARD_APPWIDGET = "android.permission.BIND_KEYGUARD_APPWIDGET";
- field public static final String BIND_MUSIC_RECOGNITION_SERVICE = "android.permission.BIND_MUSIC_RECOGNITION_SERVICE";
- field public static final String BIND_NETWORK_RECOMMENDATION_SERVICE = "android.permission.BIND_NETWORK_RECOMMENDATION_SERVICE";
- field public static final String BIND_NOTIFICATION_ASSISTANT_SERVICE = "android.permission.BIND_NOTIFICATION_ASSISTANT_SERVICE";
- field public static final String BIND_PHONE_ACCOUNT_SUGGESTION_SERVICE = "android.permission.BIND_PHONE_ACCOUNT_SUGGESTION_SERVICE";
- field public static final String BIND_PRINT_RECOMMENDATION_SERVICE = "android.permission.BIND_PRINT_RECOMMENDATION_SERVICE";
- field public static final String BIND_RESOLVER_RANKER_SERVICE = "android.permission.BIND_RESOLVER_RANKER_SERVICE";
- field public static final String BIND_RUNTIME_PERMISSION_PRESENTER_SERVICE = "android.permission.BIND_RUNTIME_PERMISSION_PRESENTER_SERVICE";
- field public static final String BIND_SETTINGS_SUGGESTIONS_SERVICE = "android.permission.BIND_SETTINGS_SUGGESTIONS_SERVICE";
- field public static final String BIND_SOUND_TRIGGER_DETECTION_SERVICE = "android.permission.BIND_SOUND_TRIGGER_DETECTION_SERVICE";
- field public static final String BIND_TELEPHONY_DATA_SERVICE = "android.permission.BIND_TELEPHONY_DATA_SERVICE";
- field public static final String BIND_TELEPHONY_NETWORK_SERVICE = "android.permission.BIND_TELEPHONY_NETWORK_SERVICE";
- field public static final String BIND_TEXTCLASSIFIER_SERVICE = "android.permission.BIND_TEXTCLASSIFIER_SERVICE";
- field public static final String BIND_TRUST_AGENT = "android.permission.BIND_TRUST_AGENT";
- field public static final String BIND_TV_REMOTE_SERVICE = "android.permission.BIND_TV_REMOTE_SERVICE";
- field public static final String BRICK = "android.permission.BRICK";
- field public static final String BRIGHTNESS_SLIDER_USAGE = "android.permission.BRIGHTNESS_SLIDER_USAGE";
- field @Deprecated public static final String BROADCAST_NETWORK_PRIVILEGED = "android.permission.BROADCAST_NETWORK_PRIVILEGED";
- field public static final String CAMERA_DISABLE_TRANSMIT_LED = "android.permission.CAMERA_DISABLE_TRANSMIT_LED";
- field public static final String CAPTURE_AUDIO_HOTWORD = "android.permission.CAPTURE_AUDIO_HOTWORD";
- field public static final String CAPTURE_MEDIA_OUTPUT = "android.permission.CAPTURE_MEDIA_OUTPUT";
- field public static final String CAPTURE_TV_INPUT = "android.permission.CAPTURE_TV_INPUT";
- field public static final String CAPTURE_VOICE_COMMUNICATION_OUTPUT = "android.permission.CAPTURE_VOICE_COMMUNICATION_OUTPUT";
- field public static final String CHANGE_APP_IDLE_STATE = "android.permission.CHANGE_APP_IDLE_STATE";
- field public static final String CHANGE_DEVICE_IDLE_TEMP_WHITELIST = "android.permission.CHANGE_DEVICE_IDLE_TEMP_WHITELIST";
- field public static final String CLEAR_APP_USER_DATA = "android.permission.CLEAR_APP_USER_DATA";
- field public static final String COMPANION_APPROVE_WIFI_CONNECTIONS = "android.permission.COMPANION_APPROVE_WIFI_CONNECTIONS";
- field public static final String CONFIGURE_DISPLAY_BRIGHTNESS = "android.permission.CONFIGURE_DISPLAY_BRIGHTNESS";
- field public static final String CONFIGURE_WIFI_DISPLAY = "android.permission.CONFIGURE_WIFI_DISPLAY";
- field @Deprecated public static final String CONNECTIVITY_INTERNAL = "android.permission.CONNECTIVITY_INTERNAL";
- field public static final String CONNECTIVITY_USE_RESTRICTED_NETWORKS = "android.permission.CONNECTIVITY_USE_RESTRICTED_NETWORKS";
- field public static final String CONTROL_DEVICE_LIGHTS = "android.permission.CONTROL_DEVICE_LIGHTS";
- field public static final String CONTROL_DISPLAY_COLOR_TRANSFORMS = "android.permission.CONTROL_DISPLAY_COLOR_TRANSFORMS";
- field public static final String CONTROL_DISPLAY_SATURATION = "android.permission.CONTROL_DISPLAY_SATURATION";
- field public static final String CONTROL_INCALL_EXPERIENCE = "android.permission.CONTROL_INCALL_EXPERIENCE";
- field public static final String CONTROL_KEYGUARD_SECURE_NOTIFICATIONS = "android.permission.CONTROL_KEYGUARD_SECURE_NOTIFICATIONS";
- field public static final String CONTROL_VPN = "android.permission.CONTROL_VPN";
- field public static final String CREATE_USERS = "android.permission.CREATE_USERS";
- field public static final String CRYPT_KEEPER = "android.permission.CRYPT_KEEPER";
- field public static final String DEVICE_POWER = "android.permission.DEVICE_POWER";
- field public static final String DISPATCH_PROVISIONING_MESSAGE = "android.permission.DISPATCH_PROVISIONING_MESSAGE";
- field public static final String ENTER_CAR_MODE_PRIORITIZED = "android.permission.ENTER_CAR_MODE_PRIORITIZED";
- field public static final String EXEMPT_FROM_AUDIO_RECORD_RESTRICTIONS = "android.permission.EXEMPT_FROM_AUDIO_RECORD_RESTRICTIONS";
- field public static final String FORCE_BACK = "android.permission.FORCE_BACK";
- field public static final String FORCE_STOP_PACKAGES = "android.permission.FORCE_STOP_PACKAGES";
- field public static final String GET_APP_OPS_STATS = "android.permission.GET_APP_OPS_STATS";
- field public static final String GET_PROCESS_STATE_AND_OOM_SCORE = "android.permission.GET_PROCESS_STATE_AND_OOM_SCORE";
- field public static final String GET_RUNTIME_PERMISSIONS = "android.permission.GET_RUNTIME_PERMISSIONS";
- field public static final String GET_TOP_ACTIVITY_INFO = "android.permission.GET_TOP_ACTIVITY_INFO";
- field @Deprecated public static final String GRANT_PROFILE_OWNER_DEVICE_IDS_ACCESS = "android.permission.GRANT_PROFILE_OWNER_DEVICE_IDS_ACCESS";
- field public static final String GRANT_RUNTIME_PERMISSIONS = "android.permission.GRANT_RUNTIME_PERMISSIONS";
- field public static final String GRANT_RUNTIME_PERMISSIONS_TO_TELEPHONY_DEFAULTS = "android.permission.GRANT_RUNTIME_PERMISSIONS_TO_TELEPHONY_DEFAULTS";
- field public static final String HANDLE_CAR_MODE_CHANGES = "android.permission.HANDLE_CAR_MODE_CHANGES";
- field public static final String HARDWARE_TEST = "android.permission.HARDWARE_TEST";
- field public static final String HDMI_CEC = "android.permission.HDMI_CEC";
- field public static final String HIDE_NON_SYSTEM_OVERLAY_WINDOWS = "android.permission.HIDE_NON_SYSTEM_OVERLAY_WINDOWS";
- field public static final String INJECT_EVENTS = "android.permission.INJECT_EVENTS";
- field public static final String INSTALL_DYNAMIC_SYSTEM = "android.permission.INSTALL_DYNAMIC_SYSTEM";
- field public static final String INSTALL_GRANT_RUNTIME_PERMISSIONS = "android.permission.INSTALL_GRANT_RUNTIME_PERMISSIONS";
- field public static final String INSTALL_LOCATION_TIME_ZONE_PROVIDER = "android.permission.INSTALL_LOCATION_TIME_ZONE_PROVIDER";
- field public static final String INSTALL_PACKAGE_UPDATES = "android.permission.INSTALL_PACKAGE_UPDATES";
- field public static final String INSTALL_SELF_UPDATES = "android.permission.INSTALL_SELF_UPDATES";
- field public static final String INTENT_FILTER_VERIFICATION_AGENT = "android.permission.INTENT_FILTER_VERIFICATION_AGENT";
- field public static final String INTERACT_ACROSS_USERS = "android.permission.INTERACT_ACROSS_USERS";
- field public static final String INTERACT_ACROSS_USERS_FULL = "android.permission.INTERACT_ACROSS_USERS_FULL";
- field public static final String INTERNAL_SYSTEM_WINDOW = "android.permission.INTERNAL_SYSTEM_WINDOW";
- field public static final String INVOKE_CARRIER_SETUP = "android.permission.INVOKE_CARRIER_SETUP";
- field public static final String KILL_UID = "android.permission.KILL_UID";
- field public static final String LOCAL_MAC_ADDRESS = "android.permission.LOCAL_MAC_ADDRESS";
- field public static final String LOCK_DEVICE = "android.permission.LOCK_DEVICE";
- field public static final String LOOP_RADIO = "android.permission.LOOP_RADIO";
- field public static final String MANAGE_ACCESSIBILITY = "android.permission.MANAGE_ACCESSIBILITY";
- field @Deprecated public static final String MANAGE_ACTIVITY_STACKS = "android.permission.MANAGE_ACTIVITY_STACKS";
- field public static final String MANAGE_ACTIVITY_TASKS = "android.permission.MANAGE_ACTIVITY_TASKS";
- field public static final String MANAGE_APP_OPS_RESTRICTIONS = "android.permission.MANAGE_APP_OPS_RESTRICTIONS";
- field public static final String MANAGE_APP_PREDICTIONS = "android.permission.MANAGE_APP_PREDICTIONS";
- field public static final String MANAGE_APP_TOKENS = "android.permission.MANAGE_APP_TOKENS";
- field public static final String MANAGE_AUTO_FILL = "android.permission.MANAGE_AUTO_FILL";
- field public static final String MANAGE_CARRIER_OEM_UNLOCK_STATE = "android.permission.MANAGE_CARRIER_OEM_UNLOCK_STATE";
- field public static final String MANAGE_CA_CERTIFICATES = "android.permission.MANAGE_CA_CERTIFICATES";
- field public static final String MANAGE_CONTENT_CAPTURE = "android.permission.MANAGE_CONTENT_CAPTURE";
- field public static final String MANAGE_CONTENT_SUGGESTIONS = "android.permission.MANAGE_CONTENT_SUGGESTIONS";
- field public static final String MANAGE_DEBUGGING = "android.permission.MANAGE_DEBUGGING";
- field public static final String MANAGE_FACTORY_RESET_PROTECTION = "android.permission.MANAGE_FACTORY_RESET_PROTECTION";
- field public static final String MANAGE_IPSEC_TUNNELS = "android.permission.MANAGE_IPSEC_TUNNELS";
- field public static final String MANAGE_MUSIC_RECOGNITION = "android.permission.MANAGE_MUSIC_RECOGNITION";
- field public static final String MANAGE_NOTIFICATION_LISTENERS = "android.permission.MANAGE_NOTIFICATION_LISTENERS";
- field public static final String MANAGE_ONE_TIME_PERMISSION_SESSIONS = "android.permission.MANAGE_ONE_TIME_PERMISSION_SESSIONS";
- field public static final String MANAGE_ROLE_HOLDERS = "android.permission.MANAGE_ROLE_HOLDERS";
- field public static final String MANAGE_ROLLBACKS = "android.permission.MANAGE_ROLLBACKS";
- field public static final String MANAGE_SENSOR_PRIVACY = "android.permission.MANAGE_SENSOR_PRIVACY";
- field public static final String MANAGE_SOUND_TRIGGER = "android.permission.MANAGE_SOUND_TRIGGER";
- field public static final String MANAGE_SUBSCRIPTION_PLANS = "android.permission.MANAGE_SUBSCRIPTION_PLANS";
- field public static final String MANAGE_TIME_AND_ZONE_DETECTION = "android.permission.MANAGE_TIME_AND_ZONE_DETECTION";
- field public static final String MANAGE_USB = "android.permission.MANAGE_USB";
- field public static final String MANAGE_USERS = "android.permission.MANAGE_USERS";
- field public static final String MANAGE_USER_OEM_UNLOCK_STATE = "android.permission.MANAGE_USER_OEM_UNLOCK_STATE";
- field public static final String MODIFY_APPWIDGET_BIND_PERMISSIONS = "android.permission.MODIFY_APPWIDGET_BIND_PERMISSIONS";
- field public static final String MODIFY_AUDIO_ROUTING = "android.permission.MODIFY_AUDIO_ROUTING";
- field public static final String MODIFY_CELL_BROADCASTS = "android.permission.MODIFY_CELL_BROADCASTS";
- field public static final String MODIFY_DAY_NIGHT_MODE = "android.permission.MODIFY_DAY_NIGHT_MODE";
- field @Deprecated public static final String MODIFY_NETWORK_ACCOUNTING = "android.permission.MODIFY_NETWORK_ACCOUNTING";
- field public static final String MODIFY_PARENTAL_CONTROLS = "android.permission.MODIFY_PARENTAL_CONTROLS";
- field public static final String MODIFY_QUIET_MODE = "android.permission.MODIFY_QUIET_MODE";
- field public static final String MODIFY_SETTINGS_OVERRIDEABLE_BY_RESTORE = "android.permission.MODIFY_SETTINGS_OVERRIDEABLE_BY_RESTORE";
- field public static final String MOVE_PACKAGE = "android.permission.MOVE_PACKAGE";
- field public static final String NETWORK_AIRPLANE_MODE = "android.permission.NETWORK_AIRPLANE_MODE";
- field public static final String NETWORK_CARRIER_PROVISIONING = "android.permission.NETWORK_CARRIER_PROVISIONING";
- field public static final String NETWORK_FACTORY = "android.permission.NETWORK_FACTORY";
- field public static final String NETWORK_MANAGED_PROVISIONING = "android.permission.NETWORK_MANAGED_PROVISIONING";
- field public static final String NETWORK_SCAN = "android.permission.NETWORK_SCAN";
- field public static final String NETWORK_SETTINGS = "android.permission.NETWORK_SETTINGS";
- field public static final String NETWORK_SETUP_WIZARD = "android.permission.NETWORK_SETUP_WIZARD";
- field public static final String NETWORK_SIGNAL_STRENGTH_WAKEUP = "android.permission.NETWORK_SIGNAL_STRENGTH_WAKEUP";
- field public static final String NETWORK_STACK = "android.permission.NETWORK_STACK";
- field public static final String NETWORK_STATS_PROVIDER = "android.permission.NETWORK_STATS_PROVIDER";
- field public static final String NOTIFICATION_DURING_SETUP = "android.permission.NOTIFICATION_DURING_SETUP";
- field public static final String NOTIFY_TV_INPUTS = "android.permission.NOTIFY_TV_INPUTS";
- field public static final String OBSERVE_APP_USAGE = "android.permission.OBSERVE_APP_USAGE";
- field public static final String OBSERVE_NETWORK_POLICY = "android.permission.OBSERVE_NETWORK_POLICY";
- field public static final String OBSERVE_ROLE_HOLDERS = "android.permission.OBSERVE_ROLE_HOLDERS";
- field public static final String OPEN_ACCESSIBILITY_DETAILS_SETTINGS = "android.permission.OPEN_ACCESSIBILITY_DETAILS_SETTINGS";
- field public static final String OVERRIDE_WIFI_CONFIG = "android.permission.OVERRIDE_WIFI_CONFIG";
- field public static final String PACKAGE_VERIFICATION_AGENT = "android.permission.PACKAGE_VERIFICATION_AGENT";
- field public static final String PACKET_KEEPALIVE_OFFLOAD = "android.permission.PACKET_KEEPALIVE_OFFLOAD";
- field public static final String PEERS_MAC_ADDRESS = "android.permission.PEERS_MAC_ADDRESS";
- field public static final String PERFORM_CDMA_PROVISIONING = "android.permission.PERFORM_CDMA_PROVISIONING";
- field public static final String PERFORM_SIM_ACTIVATION = "android.permission.PERFORM_SIM_ACTIVATION";
- field public static final String POWER_SAVER = "android.permission.POWER_SAVER";
- field public static final String PROVIDE_RESOLVER_RANKER_SERVICE = "android.permission.PROVIDE_RESOLVER_RANKER_SERVICE";
- field public static final String PROVIDE_TRUST_AGENT = "android.permission.PROVIDE_TRUST_AGENT";
- field public static final String QUERY_TIME_ZONE_RULES = "android.permission.QUERY_TIME_ZONE_RULES";
- field public static final String RADIO_SCAN_WITHOUT_LOCATION = "android.permission.RADIO_SCAN_WITHOUT_LOCATION";
- field public static final String READ_ACTIVE_EMERGENCY_SESSION = "android.permission.READ_ACTIVE_EMERGENCY_SESSION";
- field public static final String READ_CARRIER_APP_INFO = "android.permission.READ_CARRIER_APP_INFO";
- field public static final String READ_CELL_BROADCASTS = "android.permission.READ_CELL_BROADCASTS";
- field public static final String READ_CONTENT_RATING_SYSTEMS = "android.permission.READ_CONTENT_RATING_SYSTEMS";
- field public static final String READ_DEVICE_CONFIG = "android.permission.READ_DEVICE_CONFIG";
- field public static final String READ_DREAM_STATE = "android.permission.READ_DREAM_STATE";
- field public static final String READ_INSTALL_SESSIONS = "android.permission.READ_INSTALL_SESSIONS";
- field public static final String READ_NETWORK_USAGE_HISTORY = "android.permission.READ_NETWORK_USAGE_HISTORY";
- field public static final String READ_OEM_UNLOCK_STATE = "android.permission.READ_OEM_UNLOCK_STATE";
- field public static final String READ_PRINT_SERVICES = "android.permission.READ_PRINT_SERVICES";
- field public static final String READ_PRINT_SERVICE_RECOMMENDATIONS = "android.permission.READ_PRINT_SERVICE_RECOMMENDATIONS";
- field public static final String READ_PRIVILEGED_PHONE_STATE = "android.permission.READ_PRIVILEGED_PHONE_STATE";
- field public static final String READ_PROJECTION_STATE = "android.permission.READ_PROJECTION_STATE";
- field public static final String READ_RUNTIME_PROFILES = "android.permission.READ_RUNTIME_PROFILES";
- field public static final String READ_SEARCH_INDEXABLES = "android.permission.READ_SEARCH_INDEXABLES";
- field public static final String READ_SYSTEM_UPDATE_INFO = "android.permission.READ_SYSTEM_UPDATE_INFO";
- field public static final String READ_WALLPAPER_INTERNAL = "android.permission.READ_WALLPAPER_INTERNAL";
- field public static final String READ_WIFI_CREDENTIAL = "android.permission.READ_WIFI_CREDENTIAL";
- field public static final String REAL_GET_TASKS = "android.permission.REAL_GET_TASKS";
- field public static final String RECEIVE_DATA_ACTIVITY_CHANGE = "android.permission.RECEIVE_DATA_ACTIVITY_CHANGE";
- field public static final String RECEIVE_DEVICE_CUSTOMIZATION_READY = "android.permission.RECEIVE_DEVICE_CUSTOMIZATION_READY";
- field public static final String RECEIVE_EMERGENCY_BROADCAST = "android.permission.RECEIVE_EMERGENCY_BROADCAST";
- field public static final String RECEIVE_WIFI_CREDENTIAL_CHANGE = "android.permission.RECEIVE_WIFI_CREDENTIAL_CHANGE";
- field public static final String RECOVERY = "android.permission.RECOVERY";
- field public static final String RECOVER_KEYSTORE = "android.permission.RECOVER_KEYSTORE";
- field public static final String REGISTER_CALL_PROVIDER = "android.permission.REGISTER_CALL_PROVIDER";
- field public static final String REGISTER_CONNECTION_MANAGER = "android.permission.REGISTER_CONNECTION_MANAGER";
- field public static final String REGISTER_SIM_SUBSCRIPTION = "android.permission.REGISTER_SIM_SUBSCRIPTION";
- field public static final String REGISTER_STATS_PULL_ATOM = "android.permission.REGISTER_STATS_PULL_ATOM";
- field public static final String REMOTE_DISPLAY_PROVIDER = "android.permission.REMOTE_DISPLAY_PROVIDER";
- field public static final String REMOVE_DRM_CERTIFICATES = "android.permission.REMOVE_DRM_CERTIFICATES";
- field public static final String REMOVE_TASKS = "android.permission.REMOVE_TASKS";
- field public static final String REQUEST_NETWORK_SCORES = "android.permission.REQUEST_NETWORK_SCORES";
- field public static final String REQUEST_NOTIFICATION_ASSISTANT_SERVICE = "android.permission.REQUEST_NOTIFICATION_ASSISTANT_SERVICE";
- field public static final String RESET_PASSWORD = "android.permission.RESET_PASSWORD";
- field public static final String RESTORE_RUNTIME_PERMISSIONS = "android.permission.RESTORE_RUNTIME_PERMISSIONS";
- field public static final String RESTRICTED_VR_ACCESS = "android.permission.RESTRICTED_VR_ACCESS";
- field public static final String RETRIEVE_WINDOW_CONTENT = "android.permission.RETRIEVE_WINDOW_CONTENT";
- field public static final String REVIEW_ACCESSIBILITY_SERVICES = "android.permission.REVIEW_ACCESSIBILITY_SERVICES";
- field public static final String REVOKE_RUNTIME_PERMISSIONS = "android.permission.REVOKE_RUNTIME_PERMISSIONS";
- field public static final String SCORE_NETWORKS = "android.permission.SCORE_NETWORKS";
- field public static final String SECURE_ELEMENT_PRIVILEGED_OPERATION = "android.permission.SECURE_ELEMENT_PRIVILEGED_OPERATION";
- field public static final String SEND_CATEGORY_CAR_NOTIFICATIONS = "android.permission.SEND_CATEGORY_CAR_NOTIFICATIONS";
- field public static final String SEND_DEVICE_CUSTOMIZATION_READY = "android.permission.SEND_DEVICE_CUSTOMIZATION_READY";
- field public static final String SEND_SHOW_SUSPENDED_APP_DETAILS = "android.permission.SEND_SHOW_SUSPENDED_APP_DETAILS";
- field public static final String SEND_SMS_NO_CONFIRMATION = "android.permission.SEND_SMS_NO_CONFIRMATION";
- field public static final String SERIAL_PORT = "android.permission.SERIAL_PORT";
- field public static final String SET_ACTIVITY_WATCHER = "android.permission.SET_ACTIVITY_WATCHER";
- field public static final String SET_HARMFUL_APP_WARNINGS = "android.permission.SET_HARMFUL_APP_WARNINGS";
- field public static final String SET_MEDIA_KEY_LISTENER = "android.permission.SET_MEDIA_KEY_LISTENER";
- field public static final String SET_ORIENTATION = "android.permission.SET_ORIENTATION";
- field public static final String SET_POINTER_SPEED = "android.permission.SET_POINTER_SPEED";
- field public static final String SET_SCREEN_COMPATIBILITY = "android.permission.SET_SCREEN_COMPATIBILITY";
- field public static final String SET_VOLUME_KEY_LONG_PRESS_LISTENER = "android.permission.SET_VOLUME_KEY_LONG_PRESS_LISTENER";
- field public static final String SET_WALLPAPER_COMPONENT = "android.permission.SET_WALLPAPER_COMPONENT";
- field public static final String SHOW_KEYGUARD_MESSAGE = "android.permission.SHOW_KEYGUARD_MESSAGE";
- field public static final String SHUTDOWN = "android.permission.SHUTDOWN";
- field public static final String START_ACTIVITIES_FROM_BACKGROUND = "android.permission.START_ACTIVITIES_FROM_BACKGROUND";
- field public static final String STATUS_BAR_SERVICE = "android.permission.STATUS_BAR_SERVICE";
- field public static final String STOP_APP_SWITCHES = "android.permission.STOP_APP_SWITCHES";
- field public static final String SUBSTITUTE_NOTIFICATION_APP_NAME = "android.permission.SUBSTITUTE_NOTIFICATION_APP_NAME";
- field public static final String SUBSTITUTE_SHARE_TARGET_APP_NAME_AND_ICON = "android.permission.SUBSTITUTE_SHARE_TARGET_APP_NAME_AND_ICON";
- field public static final String SUSPEND_APPS = "android.permission.SUSPEND_APPS";
- field public static final String SYSTEM_CAMERA = "android.permission.SYSTEM_CAMERA";
- field public static final String TETHER_PRIVILEGED = "android.permission.TETHER_PRIVILEGED";
- field public static final String TOGGLE_AUTOMOTIVE_PROJECTION = "android.permission.TOGGLE_AUTOMOTIVE_PROJECTION";
- field public static final String TV_INPUT_HARDWARE = "android.permission.TV_INPUT_HARDWARE";
- field public static final String TV_VIRTUAL_REMOTE_CONTROLLER = "android.permission.TV_VIRTUAL_REMOTE_CONTROLLER";
- field public static final String UNLIMITED_SHORTCUTS_API_CALLS = "android.permission.UNLIMITED_SHORTCUTS_API_CALLS";
- field public static final String UPDATE_APP_OPS_STATS = "android.permission.UPDATE_APP_OPS_STATS";
- field public static final String UPDATE_LOCK = "android.permission.UPDATE_LOCK";
- field public static final String UPDATE_TIME_ZONE_RULES = "android.permission.UPDATE_TIME_ZONE_RULES";
- field public static final String UPGRADE_RUNTIME_PERMISSIONS = "android.permission.UPGRADE_RUNTIME_PERMISSIONS";
- field public static final String USER_ACTIVITY = "android.permission.USER_ACTIVITY";
- field public static final String USE_RESERVED_DISK = "android.permission.USE_RESERVED_DISK";
- field public static final String WHITELIST_AUTO_REVOKE_PERMISSIONS = "android.permission.WHITELIST_AUTO_REVOKE_PERMISSIONS";
- field public static final String WHITELIST_RESTRICTED_PERMISSIONS = "android.permission.WHITELIST_RESTRICTED_PERMISSIONS";
- field public static final String WIFI_SET_DEVICE_MOBILITY_STATE = "android.permission.WIFI_SET_DEVICE_MOBILITY_STATE";
- field public static final String WIFI_UPDATE_USABILITY_STATS_SCORE = "android.permission.WIFI_UPDATE_USABILITY_STATS_SCORE";
- field public static final String WRITE_DEVICE_CONFIG = "android.permission.WRITE_DEVICE_CONFIG";
- field public static final String WRITE_DREAM_STATE = "android.permission.WRITE_DREAM_STATE";
- field public static final String WRITE_EMBEDDED_SUBSCRIPTIONS = "android.permission.WRITE_EMBEDDED_SUBSCRIPTIONS";
- field @Deprecated public static final String WRITE_MEDIA_STORAGE = "android.permission.WRITE_MEDIA_STORAGE";
- field public static final String WRITE_OBB = "android.permission.WRITE_OBB";
- }
-
- public static final class Manifest.permission_group {
- field public static final String UNDEFINED = "android.permission-group.UNDEFINED";
- }
-
- public static final class R.array {
- field public static final int config_keySystemUuidMapping = 17235973; // 0x1070005
- }
-
- public static final class R.attr {
- field public static final int allowClearUserDataOnFailedRestore = 16844288; // 0x1010600
- field public static final int isVrOnly = 16844152; // 0x1010578
- field public static final int minExtensionVersion = 16844305; // 0x1010611
- field public static final int requiredSystemPropertyName = 16844133; // 0x1010565
- field public static final int requiredSystemPropertyValue = 16844134; // 0x1010566
- field public static final int sdkVersion = 16844304; // 0x1010610
- field public static final int supportsAmbientMode = 16844173; // 0x101058d
- field public static final int userRestriction = 16844164; // 0x1010584
- }
-
- public static final class R.bool {
- field public static final int config_sendPackageName = 17891328; // 0x1110000
- field public static final int config_showDefaultAssistant = 17891329; // 0x1110001
- field public static final int config_showDefaultEmergency = 17891330; // 0x1110002
- field public static final int config_showDefaultHome = 17891331; // 0x1110003
- }
-
- public static final class R.color {
- field public static final int system_notification_accent_color = 17170460; // 0x106001c
- }
-
- public static final class R.dimen {
- field public static final int config_restrictedIconSize = 17104903; // 0x1050007
- }
-
- public static final class R.drawable {
- field public static final int ic_info = 17301684; // 0x10800b4
- }
-
- public static final class R.raw {
- field public static final int loaderror = 17825792; // 0x1100000
- field public static final int nodomain = 17825793; // 0x1100001
- }
-
- public static final class R.string {
- field public static final int config_defaultAssistant = 17039393; // 0x1040021
- field public static final int config_defaultBrowser = 17039394; // 0x1040022
- field public static final int config_defaultCallRedirection = 17039397; // 0x1040025
- field public static final int config_defaultCallScreening = 17039398; // 0x1040026
- field public static final int config_defaultDialer = 17039395; // 0x1040023
- field public static final int config_defaultSms = 17039396; // 0x1040024
- field public static final int config_feedbackIntentExtraKey = 17039391; // 0x104001f
- field public static final int config_feedbackIntentNameKey = 17039392; // 0x1040020
- field public static final int config_helpIntentExtraKey = 17039389; // 0x104001d
- field public static final int config_helpIntentNameKey = 17039390; // 0x104001e
- field public static final int config_helpPackageNameKey = 17039387; // 0x104001b
- field public static final int config_helpPackageNameValue = 17039388; // 0x104001c
- field public static final int config_systemAutomotiveCluster = 17039400; // 0x1040028
- field public static final int config_systemAutomotiveProjection = 17039402; // 0x104002a
- field public static final int config_systemGallery = 17039399; // 0x1040027
- field public static final int config_systemVideoCall = 17039401; // 0x1040029
- }
-
- public static final class R.style {
- field public static final int Theme_DeviceDefault_DocumentsUI = 16974562; // 0x10302e2
- field public static final int Theme_Leanback_FormWizard = 16974544; // 0x10302d0
- }
-
-}
-
-package android.accounts {
-
- public class AccountManager {
- method @RequiresPermission(android.Manifest.permission.INTERACT_ACROSS_USERS_FULL) public android.accounts.AccountManagerFuture<android.os.Bundle> finishSessionAsUser(android.os.Bundle, android.app.Activity, android.os.UserHandle, android.accounts.AccountManagerCallback<android.os.Bundle>, android.os.Handler);
- }
-
-}
-
-package android.app {
-
- public class Activity extends android.view.ContextThemeWrapper implements android.content.ComponentCallbacks2 android.view.KeyEvent.Callback android.view.LayoutInflater.Factory2 android.view.View.OnCreateContextMenuListener android.view.Window.Callback {
- method public void convertFromTranslucent();
- method public boolean convertToTranslucent(android.app.Activity.TranslucentConversionListener, android.app.ActivityOptions);
- method @Deprecated public boolean isBackgroundVisibleBehind();
- method @Deprecated public void onBackgroundVisibleBehindChanged(boolean);
- }
-
- public static interface Activity.TranslucentConversionListener {
- method public void onTranslucentConversionComplete(boolean);
- }
-
- public class ActivityManager {
- method @RequiresPermission(android.Manifest.permission.PACKAGE_USAGE_STATS) public void addOnUidImportanceListener(android.app.ActivityManager.OnUidImportanceListener, int);
- method @RequiresPermission(android.Manifest.permission.FORCE_STOP_PACKAGES) public void forceStopPackage(String);
- method @RequiresPermission(anyOf={"android.permission.INTERACT_ACROSS_USERS", "android.permission.INTERACT_ACROSS_USERS_FULL"}) public static int getCurrentUser();
- method @RequiresPermission(android.Manifest.permission.PACKAGE_USAGE_STATS) public int getPackageImportance(String);
- method @NonNull public java.util.Collection<java.util.Locale> getSupportedLocales();
- method @RequiresPermission(android.Manifest.permission.PACKAGE_USAGE_STATS) public int getUidImportance(int);
- method @RequiresPermission(android.Manifest.permission.FORCE_STOP_PACKAGES) public void killProcessesWhenImperceptible(@NonNull int[], @NonNull String);
- method @RequiresPermission(android.Manifest.permission.KILL_UID) public void killUid(int, String);
- method @RequiresPermission(android.Manifest.permission.PACKAGE_USAGE_STATS) public void removeOnUidImportanceListener(android.app.ActivityManager.OnUidImportanceListener);
- method public void setDeviceLocales(@NonNull android.os.LocaleList);
- method @RequiresPermission(android.Manifest.permission.RESTRICTED_VR_ACCESS) public static void setPersistentVrThread(int);
- method @RequiresPermission(android.Manifest.permission.MANAGE_USERS) public boolean switchUser(@NonNull android.os.UserHandle);
- }
-
- public static interface ActivityManager.OnUidImportanceListener {
- method public void onUidImportance(int, int);
- }
-
- public class AlarmManager {
- method @RequiresPermission(android.Manifest.permission.UPDATE_DEVICE_STATS) public void set(int, long, long, long, android.app.PendingIntent, android.os.WorkSource);
- method @RequiresPermission(android.Manifest.permission.UPDATE_DEVICE_STATS) public void set(int, long, long, long, android.app.AlarmManager.OnAlarmListener, android.os.Handler, android.os.WorkSource);
- }
-
- public class AppOpsManager {
- method @Nullable @RequiresPermission(android.Manifest.permission.GET_APP_OPS_STATS) public android.app.RuntimeAppOpAccessMessage collectRuntimeAppOpAccessMessage();
- method @RequiresPermission(android.Manifest.permission.GET_APP_OPS_STATS) public void getHistoricalOps(@NonNull android.app.AppOpsManager.HistoricalOpsRequest, @NonNull java.util.concurrent.Executor, @NonNull java.util.function.Consumer<android.app.AppOpsManager.HistoricalOps>);
- method public static String[] getOpStrs();
- method @NonNull @RequiresPermission(android.Manifest.permission.GET_APP_OPS_STATS) public java.util.List<android.app.AppOpsManager.PackageOps> getOpsForPackage(int, @NonNull String, @Nullable java.lang.String...);
- method @NonNull @RequiresPermission(android.Manifest.permission.GET_APP_OPS_STATS) public java.util.List<android.app.AppOpsManager.PackageOps> getPackagesForOps(@Nullable String[]);
- method public static int opToDefaultMode(@NonNull String);
- method @Nullable public static String opToPermission(@NonNull String);
- method @RequiresPermission("android.permission.MANAGE_APP_OPS_MODES") public void setMode(@NonNull String, int, @Nullable String, int);
- method @RequiresPermission("android.permission.MANAGE_APP_OPS_MODES") public void setUidMode(@NonNull String, int, int);
- field public static final String OPSTR_ACCEPT_HANDOVER = "android:accept_handover";
- field public static final String OPSTR_ACCESS_ACCESSIBILITY = "android:access_accessibility";
- field public static final String OPSTR_ACCESS_NOTIFICATIONS = "android:access_notifications";
- field public static final String OPSTR_ACTIVATE_PLATFORM_VPN = "android:activate_platform_vpn";
- field public static final String OPSTR_ACTIVATE_VPN = "android:activate_vpn";
- field public static final String OPSTR_ASSIST_SCREENSHOT = "android:assist_screenshot";
- field public static final String OPSTR_ASSIST_STRUCTURE = "android:assist_structure";
- field public static final String OPSTR_AUDIO_ACCESSIBILITY_VOLUME = "android:audio_accessibility_volume";
- field public static final String OPSTR_AUDIO_ALARM_VOLUME = "android:audio_alarm_volume";
- field public static final String OPSTR_AUDIO_BLUETOOTH_VOLUME = "android:audio_bluetooth_volume";
- field public static final String OPSTR_AUDIO_MASTER_VOLUME = "android:audio_master_volume";
- field public static final String OPSTR_AUDIO_MEDIA_VOLUME = "android:audio_media_volume";
- field public static final String OPSTR_AUDIO_NOTIFICATION_VOLUME = "android:audio_notification_volume";
- field public static final String OPSTR_AUDIO_RING_VOLUME = "android:audio_ring_volume";
- field public static final String OPSTR_AUDIO_VOICE_VOLUME = "android:audio_voice_volume";
- field public static final String OPSTR_AUTO_REVOKE_MANAGED_BY_INSTALLER = "android:auto_revoke_managed_by_installer";
- field public static final String OPSTR_AUTO_REVOKE_PERMISSIONS_IF_UNUSED = "android:auto_revoke_permissions_if_unused";
- field public static final String OPSTR_BIND_ACCESSIBILITY_SERVICE = "android:bind_accessibility_service";
- field public static final String OPSTR_CHANGE_WIFI_STATE = "android:change_wifi_state";
- field public static final String OPSTR_GET_ACCOUNTS = "android:get_accounts";
- field public static final String OPSTR_GPS = "android:gps";
- field public static final String OPSTR_INSTANT_APP_START_FOREGROUND = "android:instant_app_start_foreground";
- field public static final String OPSTR_INTERACT_ACROSS_PROFILES = "android:interact_across_profiles";
- field public static final String OPSTR_LEGACY_STORAGE = "android:legacy_storage";
- field public static final String OPSTR_LOADER_USAGE_STATS = "android:loader_usage_stats";
- field public static final String OPSTR_MANAGE_EXTERNAL_STORAGE = "android:manage_external_storage";
- field public static final String OPSTR_MANAGE_IPSEC_TUNNELS = "android:manage_ipsec_tunnels";
- field public static final String OPSTR_MANAGE_ONGOING_CALLS = "android:manage_ongoing_calls";
- field public static final String OPSTR_MUTE_MICROPHONE = "android:mute_microphone";
- field public static final String OPSTR_NEIGHBORING_CELLS = "android:neighboring_cells";
- field public static final String OPSTR_PLAY_AUDIO = "android:play_audio";
- field public static final String OPSTR_POST_NOTIFICATION = "android:post_notification";
- field public static final String OPSTR_PROJECT_MEDIA = "android:project_media";
- field public static final String OPSTR_READ_CLIPBOARD = "android:read_clipboard";
- field public static final String OPSTR_READ_ICC_SMS = "android:read_icc_sms";
- field public static final String OPSTR_READ_MEDIA_AUDIO = "android:read_media_audio";
- field public static final String OPSTR_READ_MEDIA_IMAGES = "android:read_media_images";
- field public static final String OPSTR_READ_MEDIA_VIDEO = "android:read_media_video";
- field public static final String OPSTR_RECEIVE_EMERGENCY_BROADCAST = "android:receive_emergency_broadcast";
- field public static final String OPSTR_REQUEST_DELETE_PACKAGES = "android:request_delete_packages";
- field public static final String OPSTR_REQUEST_INSTALL_PACKAGES = "android:request_install_packages";
- field public static final String OPSTR_RUN_ANY_IN_BACKGROUND = "android:run_any_in_background";
- field public static final String OPSTR_RUN_IN_BACKGROUND = "android:run_in_background";
- field public static final String OPSTR_START_FOREGROUND = "android:start_foreground";
- field public static final String OPSTR_TAKE_AUDIO_FOCUS = "android:take_audio_focus";
- field public static final String OPSTR_TAKE_MEDIA_BUTTONS = "android:take_media_buttons";
- field public static final String OPSTR_TOAST_WINDOW = "android:toast_window";
- field public static final String OPSTR_TURN_SCREEN_ON = "android:turn_screen_on";
- field public static final String OPSTR_VIBRATE = "android:vibrate";
- field public static final String OPSTR_WAKE_LOCK = "android:wake_lock";
- field public static final String OPSTR_WIFI_SCAN = "android:wifi_scan";
- field public static final String OPSTR_WRITE_CLIPBOARD = "android:write_clipboard";
- field public static final String OPSTR_WRITE_ICC_SMS = "android:write_icc_sms";
- field public static final String OPSTR_WRITE_MEDIA_AUDIO = "android:write_media_audio";
- field public static final String OPSTR_WRITE_MEDIA_IMAGES = "android:write_media_images";
- field public static final String OPSTR_WRITE_MEDIA_VIDEO = "android:write_media_video";
- field public static final String OPSTR_WRITE_SMS = "android:write_sms";
- field public static final String OPSTR_WRITE_WALLPAPER = "android:write_wallpaper";
- field public static final int OP_FLAGS_ALL = 31; // 0x1f
- field public static final int OP_FLAGS_ALL_TRUSTED = 13; // 0xd
- field public static final int OP_FLAG_SELF = 1; // 0x1
- field public static final int OP_FLAG_TRUSTED_PROXIED = 8; // 0x8
- field public static final int OP_FLAG_TRUSTED_PROXY = 2; // 0x2
- field public static final int OP_FLAG_UNTRUSTED_PROXIED = 16; // 0x10
- field public static final int OP_FLAG_UNTRUSTED_PROXY = 4; // 0x4
- field public static final int UID_STATE_BACKGROUND = 600; // 0x258
- field public static final int UID_STATE_CACHED = 700; // 0x2bc
- field public static final int UID_STATE_FOREGROUND = 500; // 0x1f4
- field public static final int UID_STATE_FOREGROUND_SERVICE = 400; // 0x190
- field @Deprecated public static final int UID_STATE_FOREGROUND_SERVICE_LOCATION = 300; // 0x12c
- field public static final int UID_STATE_PERSISTENT = 100; // 0x64
- field public static final int UID_STATE_TOP = 200; // 0xc8
- }
-
- public static final class AppOpsManager.AttributedHistoricalOps implements android.os.Parcelable {
- method public int describeContents();
- method @Nullable public android.app.AppOpsManager.HistoricalOp getOp(@NonNull String);
- method @NonNull public android.app.AppOpsManager.HistoricalOp getOpAt(@IntRange(from=0) int);
- method @IntRange(from=0) public int getOpCount();
- method @Nullable public String getTag();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.app.AppOpsManager.AttributedHistoricalOps> CREATOR;
- }
-
- public static final class AppOpsManager.AttributedOpEntry implements android.os.Parcelable {
- method public int describeContents();
- method public long getLastAccessBackgroundTime(int);
- method public long getLastAccessForegroundTime(int);
- method public long getLastAccessTime(int);
- method public long getLastAccessTime(int, int, int);
- method public long getLastBackgroundDuration(int);
- method @Nullable public android.app.AppOpsManager.OpEventProxyInfo getLastBackgroundProxyInfo(int);
- method public long getLastDuration(int);
- method public long getLastDuration(int, int, int);
- method public long getLastForegroundDuration(int);
- method @Nullable public android.app.AppOpsManager.OpEventProxyInfo getLastForegroundProxyInfo(int);
- method @Nullable public android.app.AppOpsManager.OpEventProxyInfo getLastProxyInfo(int);
- method @Nullable public android.app.AppOpsManager.OpEventProxyInfo getLastProxyInfo(int, int, int);
- method public long getLastRejectBackgroundTime(int);
- method public long getLastRejectForegroundTime(int);
- method public long getLastRejectTime(int);
- method public long getLastRejectTime(int, int, int);
- method public boolean isRunning();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.app.AppOpsManager.AttributedOpEntry> CREATOR;
- }
-
- public static final class AppOpsManager.HistoricalOp implements android.os.Parcelable {
- method public int describeContents();
- method public long getAccessCount(int, int, int);
- method public long getAccessDuration(int, int, int);
- method public long getBackgroundAccessCount(int);
- method public long getBackgroundAccessDuration(int);
- method public long getBackgroundRejectCount(int);
- method public long getForegroundAccessCount(int);
- method public long getForegroundAccessDuration(int);
- method public long getForegroundRejectCount(int);
- method @NonNull public String getOpName();
- method public long getRejectCount(int, int, int);
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.app.AppOpsManager.HistoricalOp> CREATOR;
- }
-
- public static final class AppOpsManager.HistoricalOps implements android.os.Parcelable {
- method public int describeContents();
- method public long getBeginTimeMillis();
- method public long getEndTimeMillis();
- method @IntRange(from=0) public int getUidCount();
- method @Nullable public android.app.AppOpsManager.HistoricalUidOps getUidOps(int);
- method @NonNull public android.app.AppOpsManager.HistoricalUidOps getUidOpsAt(@IntRange(from=0) int);
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.app.AppOpsManager.HistoricalOps> CREATOR;
- }
-
- public static final class AppOpsManager.HistoricalOpsRequest {
- }
-
- public static final class AppOpsManager.HistoricalOpsRequest.Builder {
- ctor public AppOpsManager.HistoricalOpsRequest.Builder(long, long);
- method @NonNull public android.app.AppOpsManager.HistoricalOpsRequest build();
- method @NonNull public android.app.AppOpsManager.HistoricalOpsRequest.Builder setAttributionTag(@Nullable String);
- method @NonNull public android.app.AppOpsManager.HistoricalOpsRequest.Builder setFlags(int);
- method @NonNull public android.app.AppOpsManager.HistoricalOpsRequest.Builder setOpNames(@Nullable java.util.List<java.lang.String>);
- method @NonNull public android.app.AppOpsManager.HistoricalOpsRequest.Builder setPackageName(@Nullable String);
- method @NonNull public android.app.AppOpsManager.HistoricalOpsRequest.Builder setUid(int);
- }
-
- public static final class AppOpsManager.HistoricalPackageOps implements android.os.Parcelable {
- method public int describeContents();
- method @Nullable public android.app.AppOpsManager.AttributedHistoricalOps getAttributedOps(@NonNull String);
- method @NonNull public android.app.AppOpsManager.AttributedHistoricalOps getAttributedOpsAt(@IntRange(from=0) int);
- method @IntRange(from=0) public int getAttributedOpsCount();
- method @Nullable public android.app.AppOpsManager.HistoricalOp getOp(@NonNull String);
- method @NonNull public android.app.AppOpsManager.HistoricalOp getOpAt(@IntRange(from=0) int);
- method @IntRange(from=0) public int getOpCount();
- method @NonNull public String getPackageName();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.app.AppOpsManager.HistoricalPackageOps> CREATOR;
- }
-
- public static final class AppOpsManager.HistoricalUidOps implements android.os.Parcelable {
- method public int describeContents();
- method @IntRange(from=0) public int getPackageCount();
- method @Nullable public android.app.AppOpsManager.HistoricalPackageOps getPackageOps(@NonNull String);
- method @NonNull public android.app.AppOpsManager.HistoricalPackageOps getPackageOpsAt(@IntRange(from=0) int);
- method public int getUid();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.app.AppOpsManager.HistoricalUidOps> CREATOR;
- }
-
- public static final class AppOpsManager.OpEntry implements android.os.Parcelable {
- method public int describeContents();
- method @NonNull public java.util.Map<java.lang.String,android.app.AppOpsManager.AttributedOpEntry> getAttributedOpEntries();
- method @Deprecated public long getDuration();
- method public long getLastAccessBackgroundTime(int);
- method public long getLastAccessForegroundTime(int);
- method public long getLastAccessTime(int);
- method public long getLastAccessTime(int, int, int);
- method public long getLastBackgroundDuration(int);
- method @Nullable public android.app.AppOpsManager.OpEventProxyInfo getLastBackgroundProxyInfo(int);
- method public long getLastDuration(int);
- method public long getLastDuration(int, int, int);
- method public long getLastForegroundDuration(int);
- method @Nullable public android.app.AppOpsManager.OpEventProxyInfo getLastForegroundProxyInfo(int);
- method @Nullable public android.app.AppOpsManager.OpEventProxyInfo getLastProxyInfo(int);
- method @Nullable public android.app.AppOpsManager.OpEventProxyInfo getLastProxyInfo(int, int, int);
- method public long getLastRejectBackgroundTime(int);
- method public long getLastRejectForegroundTime(int);
- method public long getLastRejectTime(int);
- method public long getLastRejectTime(int, int, int);
- method public int getMode();
- method @NonNull public String getOpStr();
- method @Deprecated @Nullable public String getProxyPackageName();
- method @Deprecated @Nullable public String getProxyPackageName(int, int);
- method @Deprecated public int getProxyUid();
- method @Deprecated public int getProxyUid(int, int);
- method public boolean isRunning();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.app.AppOpsManager.OpEntry> CREATOR;
- }
-
- public static final class AppOpsManager.OpEventProxyInfo implements android.os.Parcelable {
- method public int describeContents();
- method @Nullable public String getAttributionTag();
- method @Nullable public String getPackageName();
- method @IntRange(from=0) public int getUid();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.app.AppOpsManager.OpEventProxyInfo> CREATOR;
- }
-
- public static final class AppOpsManager.PackageOps implements android.os.Parcelable {
- method public int describeContents();
- method @NonNull public java.util.List<android.app.AppOpsManager.OpEntry> getOps();
- method @NonNull public String getPackageName();
- method public int getUid();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.app.AppOpsManager.PackageOps> CREATOR;
- }
-
- public class BroadcastOptions {
- method public static android.app.BroadcastOptions makeBasic();
- method @RequiresPermission(android.Manifest.permission.START_ACTIVITIES_FROM_BACKGROUND) public void setBackgroundActivityStartsAllowed(boolean);
- method public void setDontSendToRestrictedApps(boolean);
- method @RequiresPermission(android.Manifest.permission.CHANGE_DEVICE_IDLE_TEMP_WHITELIST) public void setTemporaryAppWhitelistDuration(long);
- method public android.os.Bundle toBundle();
- }
-
- public class DownloadManager {
- method @RequiresPermission(android.Manifest.permission.WRITE_MEDIA_STORAGE) public void onMediaStoreDownloadsDeleted(@NonNull android.util.LongSparseArray<java.lang.String>);
- field public static final String ACTION_DOWNLOAD_COMPLETED = "android.intent.action.DOWNLOAD_COMPLETED";
- }
-
- public abstract class InstantAppResolverService extends android.app.Service {
- ctor public InstantAppResolverService();
- method public final void attachBaseContext(android.content.Context);
- method public final android.os.IBinder onBind(android.content.Intent);
- method @Deprecated public void onGetInstantAppIntentFilter(@Nullable int[], @NonNull String, @NonNull android.app.InstantAppResolverService.InstantAppResolutionCallback);
- method @Deprecated public void onGetInstantAppIntentFilter(@NonNull android.content.Intent, @Nullable int[], @NonNull String, @NonNull android.app.InstantAppResolverService.InstantAppResolutionCallback);
- method @Deprecated public void onGetInstantAppIntentFilter(@NonNull android.content.Intent, @Nullable int[], @NonNull android.os.UserHandle, @NonNull String, @NonNull android.app.InstantAppResolverService.InstantAppResolutionCallback);
- method @MainThread public void onGetInstantAppIntentFilter(@NonNull android.content.pm.InstantAppRequestInfo, @NonNull android.app.InstantAppResolverService.InstantAppResolutionCallback);
- method @Deprecated public void onGetInstantAppResolveInfo(@Nullable int[], @NonNull String, @NonNull android.app.InstantAppResolverService.InstantAppResolutionCallback);
- method @Deprecated public void onGetInstantAppResolveInfo(@NonNull android.content.Intent, @Nullable int[], @NonNull String, @NonNull android.app.InstantAppResolverService.InstantAppResolutionCallback);
- method @Deprecated public void onGetInstantAppResolveInfo(@NonNull android.content.Intent, @Nullable int[], @NonNull android.os.UserHandle, @NonNull String, @NonNull android.app.InstantAppResolverService.InstantAppResolutionCallback);
- method @MainThread public void onGetInstantAppResolveInfo(@NonNull android.content.pm.InstantAppRequestInfo, @NonNull android.app.InstantAppResolverService.InstantAppResolutionCallback);
- }
-
- public static final class InstantAppResolverService.InstantAppResolutionCallback {
- method public void onInstantAppResolveInfo(java.util.List<android.content.pm.InstantAppResolveInfo>);
- }
-
- public class KeyguardManager {
- method public android.content.Intent createConfirmFactoryResetCredentialIntent(CharSequence, CharSequence, CharSequence);
- method @RequiresPermission("android.permission.SET_INITIAL_LOCK") public int getMinLockLength(boolean, int);
- method @RequiresPermission(android.Manifest.permission.CONTROL_KEYGUARD_SECURE_NOTIFICATIONS) public boolean getPrivateNotificationsAllowed();
- method @RequiresPermission("android.permission.SET_INITIAL_LOCK") public boolean isValidLockPasswordComplexity(int, @NonNull byte[], int);
- method @RequiresPermission(android.Manifest.permission.SHOW_KEYGUARD_MESSAGE) public void requestDismissKeyguard(@NonNull android.app.Activity, @Nullable CharSequence, @Nullable android.app.KeyguardManager.KeyguardDismissCallback);
- method @RequiresPermission("android.permission.SET_INITIAL_LOCK") public boolean setLock(int, @NonNull byte[], int);
- method @RequiresPermission(android.Manifest.permission.CONTROL_KEYGUARD_SECURE_NOTIFICATIONS) public void setPrivateNotificationsAllowed(boolean);
- }
-
- public class Notification implements android.os.Parcelable {
- field public static final String CATEGORY_CAR_EMERGENCY = "car_emergency";
- field public static final String CATEGORY_CAR_INFORMATION = "car_information";
- field public static final String CATEGORY_CAR_WARNING = "car_warning";
- field @RequiresPermission(android.Manifest.permission.NOTIFICATION_DURING_SETUP) public static final String EXTRA_ALLOW_DURING_SETUP = "android.allowDuringSetup";
- field @RequiresPermission(android.Manifest.permission.SUBSTITUTE_NOTIFICATION_APP_NAME) public static final String EXTRA_SUBSTITUTE_APP_NAME = "android.substName";
- field public static final int FLAG_AUTOGROUP_SUMMARY = 1024; // 0x400
- }
-
- public static final class Notification.TvExtender implements android.app.Notification.Extender {
- ctor public Notification.TvExtender();
- ctor public Notification.TvExtender(android.app.Notification);
- method public android.app.Notification.Builder extend(android.app.Notification.Builder);
- method public String getChannelId();
- method public android.app.PendingIntent getContentIntent();
- method public android.app.PendingIntent getDeleteIntent();
- method public boolean getSuppressShowOverApps();
- method public boolean isAvailableOnTv();
- method public android.app.Notification.TvExtender setChannel(String);
- method public android.app.Notification.TvExtender setChannelId(String);
- method public android.app.Notification.TvExtender setContentIntent(android.app.PendingIntent);
- method public android.app.Notification.TvExtender setDeleteIntent(android.app.PendingIntent);
- method public android.app.Notification.TvExtender setSuppressShowOverApps(boolean);
- }
-
- public final class NotificationChannel implements android.os.Parcelable {
- method public int getUserLockedFields();
- method public boolean isDeleted();
- method public void populateFromXml(org.xmlpull.v1.XmlPullParser);
- method public void setBlockable(boolean);
- method public org.json.JSONObject toJson() throws org.json.JSONException;
- method public void writeXml(org.xmlpull.v1.XmlSerializer) throws java.io.IOException;
- field public static final int USER_LOCKED_SOUND = 32; // 0x20
- }
-
- public final class NotificationChannelGroup implements android.os.Parcelable {
- method public org.json.JSONObject toJson() throws org.json.JSONException;
- }
-
- public class NotificationManager {
- method @NonNull public java.util.List<java.lang.String> getAllowedAssistantAdjustments();
- method @Nullable public android.content.ComponentName getAllowedNotificationAssistant();
- method @NonNull @RequiresPermission(android.Manifest.permission.MANAGE_NOTIFICATION_LISTENERS) public java.util.List<android.content.ComponentName> getEnabledNotificationListeners();
- method public boolean isNotificationAssistantAccessGranted(@NonNull android.content.ComponentName);
- method public void setNotificationAssistantAccessGranted(@Nullable android.content.ComponentName, boolean);
- method @RequiresPermission(android.Manifest.permission.MANAGE_NOTIFICATION_LISTENERS) public void setNotificationListenerAccessGranted(@NonNull android.content.ComponentName, boolean, boolean);
- field @RequiresPermission(android.Manifest.permission.STATUS_BAR_SERVICE) public static final String ACTION_CLOSE_NOTIFICATION_HANDLER_PANEL = "android.app.action.CLOSE_NOTIFICATION_HANDLER_PANEL";
- field @RequiresPermission(android.Manifest.permission.STATUS_BAR_SERVICE) public static final String ACTION_OPEN_NOTIFICATION_HANDLER_PANEL = "android.app.action.OPEN_NOTIFICATION_HANDLER_PANEL";
- field @RequiresPermission(android.Manifest.permission.STATUS_BAR_SERVICE) public static final String ACTION_TOGGLE_NOTIFICATION_HANDLER_PANEL = "android.app.action.TOGGLE_NOTIFICATION_HANDLER_PANEL";
- }
-
- public final class RuntimeAppOpAccessMessage implements android.os.Parcelable {
- ctor public RuntimeAppOpAccessMessage(@IntRange(from=0L) int, @IntRange(from=0L) int, @NonNull String, @Nullable String, @NonNull String, int);
- method public int describeContents();
- method @Nullable public String getAttributionTag();
- method @NonNull public String getMessage();
- method @NonNull public String getOp();
- method @NonNull public String getPackageName();
- method public int getSamplingStrategy();
- method @IntRange(from=0L) public int getUid();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.app.RuntimeAppOpAccessMessage> CREATOR;
- }
-
- public class SearchManager implements android.content.DialogInterface.OnCancelListener android.content.DialogInterface.OnDismissListener {
- method public void launchAssist(@Nullable android.os.Bundle);
- }
-
- public final class StatsManager {
- method @RequiresPermission(allOf={android.Manifest.permission.DUMP, android.Manifest.permission.PACKAGE_USAGE_STATS}) public void addConfig(long, byte[]) throws android.app.StatsManager.StatsUnavailableException;
- method @Deprecated @RequiresPermission(allOf={android.Manifest.permission.DUMP, android.Manifest.permission.PACKAGE_USAGE_STATS}) public boolean addConfiguration(long, byte[]);
- method @RequiresPermission(android.Manifest.permission.REGISTER_STATS_PULL_ATOM) public void clearPullAtomCallback(int);
- method @Deprecated @Nullable @RequiresPermission(allOf={android.Manifest.permission.DUMP, android.Manifest.permission.PACKAGE_USAGE_STATS}) public byte[] getData(long);
- method @Deprecated @Nullable @RequiresPermission(allOf={android.Manifest.permission.DUMP, android.Manifest.permission.PACKAGE_USAGE_STATS}) public byte[] getMetadata();
- method @RequiresPermission(allOf={android.Manifest.permission.DUMP, android.Manifest.permission.PACKAGE_USAGE_STATS}) public long[] getRegisteredExperimentIds() throws android.app.StatsManager.StatsUnavailableException;
- method @RequiresPermission(allOf={android.Manifest.permission.DUMP, android.Manifest.permission.PACKAGE_USAGE_STATS}) public byte[] getReports(long) throws android.app.StatsManager.StatsUnavailableException;
- method @RequiresPermission(allOf={android.Manifest.permission.DUMP, android.Manifest.permission.PACKAGE_USAGE_STATS}) public byte[] getStatsMetadata() throws android.app.StatsManager.StatsUnavailableException;
- method @RequiresPermission(allOf={android.Manifest.permission.DUMP, android.Manifest.permission.PACKAGE_USAGE_STATS}) public void removeConfig(long) throws android.app.StatsManager.StatsUnavailableException;
- method @Deprecated @RequiresPermission(allOf={android.Manifest.permission.DUMP, android.Manifest.permission.PACKAGE_USAGE_STATS}) public boolean removeConfiguration(long);
- method @NonNull @RequiresPermission(allOf={android.Manifest.permission.DUMP, android.Manifest.permission.PACKAGE_USAGE_STATS}) public long[] setActiveConfigsChangedOperation(@Nullable android.app.PendingIntent) throws android.app.StatsManager.StatsUnavailableException;
- method @RequiresPermission(allOf={android.Manifest.permission.DUMP, android.Manifest.permission.PACKAGE_USAGE_STATS}) public void setBroadcastSubscriber(android.app.PendingIntent, long, long) throws android.app.StatsManager.StatsUnavailableException;
- method @Deprecated @RequiresPermission(allOf={android.Manifest.permission.DUMP, android.Manifest.permission.PACKAGE_USAGE_STATS}) public boolean setBroadcastSubscriber(long, long, android.app.PendingIntent);
- method @Deprecated @RequiresPermission(allOf={android.Manifest.permission.DUMP, android.Manifest.permission.PACKAGE_USAGE_STATS}) public boolean setDataFetchOperation(long, android.app.PendingIntent);
- method @RequiresPermission(allOf={android.Manifest.permission.DUMP, android.Manifest.permission.PACKAGE_USAGE_STATS}) public void setFetchReportsOperation(android.app.PendingIntent, long) throws android.app.StatsManager.StatsUnavailableException;
- method @RequiresPermission(android.Manifest.permission.REGISTER_STATS_PULL_ATOM) public void setPullAtomCallback(int, @Nullable android.app.StatsManager.PullAtomMetadata, @NonNull java.util.concurrent.Executor, @NonNull android.app.StatsManager.StatsPullAtomCallback);
- field public static final String ACTION_STATSD_STARTED = "android.app.action.STATSD_STARTED";
- field public static final String EXTRA_STATS_ACTIVE_CONFIG_KEYS = "android.app.extra.STATS_ACTIVE_CONFIG_KEYS";
- field public static final String EXTRA_STATS_BROADCAST_SUBSCRIBER_COOKIES = "android.app.extra.STATS_BROADCAST_SUBSCRIBER_COOKIES";
- field public static final String EXTRA_STATS_CONFIG_KEY = "android.app.extra.STATS_CONFIG_KEY";
- field public static final String EXTRA_STATS_CONFIG_UID = "android.app.extra.STATS_CONFIG_UID";
- field public static final String EXTRA_STATS_DIMENSIONS_VALUE = "android.app.extra.STATS_DIMENSIONS_VALUE";
- field public static final String EXTRA_STATS_SUBSCRIPTION_ID = "android.app.extra.STATS_SUBSCRIPTION_ID";
- field public static final String EXTRA_STATS_SUBSCRIPTION_RULE_ID = "android.app.extra.STATS_SUBSCRIPTION_RULE_ID";
- field public static final int PULL_SKIP = 1; // 0x1
- field public static final int PULL_SUCCESS = 0; // 0x0
- }
-
- public static class StatsManager.PullAtomMetadata {
- method @Nullable public int[] getAdditiveFields();
- method public long getCoolDownMillis();
- method public long getTimeoutMillis();
- }
-
- public static class StatsManager.PullAtomMetadata.Builder {
- ctor public StatsManager.PullAtomMetadata.Builder();
- method @NonNull public android.app.StatsManager.PullAtomMetadata build();
- method @NonNull public android.app.StatsManager.PullAtomMetadata.Builder setAdditiveFields(@NonNull int[]);
- method @NonNull public android.app.StatsManager.PullAtomMetadata.Builder setCoolDownMillis(long);
- method @NonNull public android.app.StatsManager.PullAtomMetadata.Builder setTimeoutMillis(long);
- }
-
- public static interface StatsManager.StatsPullAtomCallback {
- method public int onPullAtom(int, @NonNull java.util.List<android.util.StatsEvent>);
- }
-
- public static class StatsManager.StatsUnavailableException extends android.util.AndroidException {
- ctor public StatsManager.StatsUnavailableException(String);
- ctor public StatsManager.StatsUnavailableException(String, Throwable);
- }
-
- public class StatusBarManager {
- method @NonNull @RequiresPermission(android.Manifest.permission.STATUS_BAR) public android.app.StatusBarManager.DisableInfo getDisableInfo();
- method @RequiresPermission(android.Manifest.permission.STATUS_BAR) public void setDisabledForSetup(boolean);
- }
-
- public static final class StatusBarManager.DisableInfo {
- method public boolean areAllComponentsEnabled();
- method public boolean isNavigateToHomeDisabled();
- method public boolean isNotificationPeekingDisabled();
- method public boolean isRecentsDisabled();
- method public boolean isSearchDisabled();
- method public boolean isStatusBarExpansionDisabled();
- }
-
- public final class SystemServiceRegistry {
- method public static <TServiceClass> void registerContextAwareService(@NonNull String, @NonNull Class<TServiceClass>, @NonNull android.app.SystemServiceRegistry.ContextAwareServiceProducerWithBinder<TServiceClass>);
- method public static <TServiceClass> void registerContextAwareService(@NonNull String, @NonNull Class<TServiceClass>, @NonNull android.app.SystemServiceRegistry.ContextAwareServiceProducerWithoutBinder<TServiceClass>);
- method public static <TServiceClass> void registerStaticService(@NonNull String, @NonNull Class<TServiceClass>, @NonNull android.app.SystemServiceRegistry.StaticServiceProducerWithBinder<TServiceClass>);
- method public static <TServiceClass> void registerStaticService(@NonNull String, @NonNull Class<TServiceClass>, @NonNull android.app.SystemServiceRegistry.StaticServiceProducerWithoutBinder<TServiceClass>);
- }
-
- public static interface SystemServiceRegistry.ContextAwareServiceProducerWithBinder<TServiceClass> {
- method @NonNull public TServiceClass createService(@NonNull android.content.Context, @NonNull android.os.IBinder);
- }
-
- public static interface SystemServiceRegistry.ContextAwareServiceProducerWithoutBinder<TServiceClass> {
- method @NonNull public TServiceClass createService(@NonNull android.content.Context);
- }
-
- public static interface SystemServiceRegistry.StaticServiceProducerWithBinder<TServiceClass> {
- method @NonNull public TServiceClass createService(@NonNull android.os.IBinder);
- }
-
- public static interface SystemServiceRegistry.StaticServiceProducerWithoutBinder<TServiceClass> {
- method @NonNull public TServiceClass createService();
- }
-
- public class UiModeManager {
- method @RequiresPermission(android.Manifest.permission.READ_PROJECTION_STATE) public void addOnProjectionStateChangeListener(int, @NonNull java.util.concurrent.Executor, @NonNull android.app.UiModeManager.OnProjectionStateChangeListener);
- method @RequiresPermission(android.Manifest.permission.ENTER_CAR_MODE_PRIORITIZED) public void enableCarMode(@IntRange(from=0) int, int);
- method @RequiresPermission(android.Manifest.permission.READ_PROJECTION_STATE) public int getActiveProjectionTypes();
- method @NonNull @RequiresPermission(android.Manifest.permission.READ_PROJECTION_STATE) public java.util.Set<java.lang.String> getProjectingPackages(int);
- method @RequiresPermission(value=android.Manifest.permission.TOGGLE_AUTOMOTIVE_PROJECTION, conditional=true) public boolean releaseProjection(int);
- method @RequiresPermission(android.Manifest.permission.READ_PROJECTION_STATE) public void removeOnProjectionStateChangeListener(@NonNull android.app.UiModeManager.OnProjectionStateChangeListener);
- method @RequiresPermission(value=android.Manifest.permission.TOGGLE_AUTOMOTIVE_PROJECTION, conditional=true) public boolean requestProjection(int);
- field public static final String ACTION_ENTER_CAR_MODE_PRIORITIZED = "android.app.action.ENTER_CAR_MODE_PRIORITIZED";
- field public static final String ACTION_EXIT_CAR_MODE_PRIORITIZED = "android.app.action.EXIT_CAR_MODE_PRIORITIZED";
- field public static final int DEFAULT_PRIORITY = 0; // 0x0
- field public static final String EXTRA_CALLING_PACKAGE = "android.app.extra.CALLING_PACKAGE";
- field public static final String EXTRA_PRIORITY = "android.app.extra.PRIORITY";
- field public static final int PROJECTION_TYPE_ALL = 65535; // 0xffff
- field public static final int PROJECTION_TYPE_AUTOMOTIVE = 1; // 0x1
- field public static final int PROJECTION_TYPE_NONE = 0; // 0x0
- }
-
- public static interface UiModeManager.OnProjectionStateChangeListener {
- method public void onProjectionStateChanged(int, @NonNull java.util.Set<java.lang.String>);
- }
-
- public final class Vr2dDisplayProperties implements android.os.Parcelable {
- ctor public Vr2dDisplayProperties(int, int, int);
- method public int describeContents();
- method public void dump(@NonNull java.io.PrintWriter, @NonNull String);
- method public int getAddedFlags();
- method public int getDpi();
- method public int getHeight();
- method public int getRemovedFlags();
- method public int getWidth();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.app.Vr2dDisplayProperties> CREATOR;
- field public static final int FLAG_VIRTUAL_DISPLAY_ENABLED = 1; // 0x1
- }
-
- public static final class Vr2dDisplayProperties.Builder {
- ctor public Vr2dDisplayProperties.Builder();
- method @NonNull public android.app.Vr2dDisplayProperties.Builder addFlags(int);
- method @NonNull public android.app.Vr2dDisplayProperties build();
- method @NonNull public android.app.Vr2dDisplayProperties.Builder removeFlags(int);
- method @NonNull public android.app.Vr2dDisplayProperties.Builder setDimensions(int, int, int);
- method @NonNull public android.app.Vr2dDisplayProperties.Builder setEnabled(boolean);
- }
-
- public class VrManager {
- method @RequiresPermission(android.Manifest.permission.RESTRICTED_VR_ACCESS) public int getVr2dDisplayId();
- method @RequiresPermission(anyOf={android.Manifest.permission.RESTRICTED_VR_ACCESS, "android.permission.ACCESS_VR_STATE"}) public boolean isPersistentVrModeEnabled();
- method @RequiresPermission(anyOf={android.Manifest.permission.RESTRICTED_VR_ACCESS, "android.permission.ACCESS_VR_STATE"}) public boolean isVrModeEnabled();
- method @RequiresPermission(anyOf={android.Manifest.permission.RESTRICTED_VR_ACCESS, "android.permission.ACCESS_VR_STATE"}) public void registerVrStateCallback(@NonNull java.util.concurrent.Executor, @NonNull android.app.VrStateCallback);
- method @RequiresPermission(android.Manifest.permission.RESTRICTED_VR_ACCESS) public void setAndBindVrCompositor(android.content.ComponentName);
- method @RequiresPermission(android.Manifest.permission.RESTRICTED_VR_ACCESS) public void setPersistentVrModeEnabled(boolean);
- method @RequiresPermission("android.permission.ACCESS_VR_MANAGER") public void setStandbyEnabled(boolean);
- method @RequiresPermission(android.Manifest.permission.RESTRICTED_VR_ACCESS) public void setVr2dDisplayProperties(@NonNull android.app.Vr2dDisplayProperties);
- method @RequiresPermission(android.Manifest.permission.RESTRICTED_VR_ACCESS) public void setVrInputMethod(@Nullable android.content.ComponentName);
- method @RequiresPermission(anyOf={android.Manifest.permission.RESTRICTED_VR_ACCESS, "android.permission.ACCESS_VR_STATE"}) public void unregisterVrStateCallback(@NonNull android.app.VrStateCallback);
- }
-
- public abstract class VrStateCallback {
- ctor public VrStateCallback();
- method public void onPersistentVrStateChanged(boolean);
- method public void onVrStateChanged(boolean);
- }
-
- public final class WallpaperColors implements android.os.Parcelable {
- ctor public WallpaperColors(@NonNull android.graphics.Color, @Nullable android.graphics.Color, @Nullable android.graphics.Color, int);
- method public int getColorHints();
- field public static final int HINT_SUPPORTS_DARK_TEXT = 1; // 0x1
- field public static final int HINT_SUPPORTS_DARK_THEME = 2; // 0x2
- }
-
- public final class WallpaperInfo implements android.os.Parcelable {
- method public boolean supportsAmbientMode();
- }
-
- public class WallpaperManager {
- method @RequiresPermission(android.Manifest.permission.INTERACT_ACROSS_USERS_FULL) public void clearWallpaper(int, int);
- method public void setDisplayOffset(android.os.IBinder, int, int);
- method @RequiresPermission(android.Manifest.permission.SET_WALLPAPER_COMPONENT) public boolean setWallpaperComponent(android.content.ComponentName);
- }
-
-}
-
-package android.app.admin {
-
- public class DevicePolicyKeyguardService extends android.app.Service {
- ctor public DevicePolicyKeyguardService();
- method @Nullable public void dismiss();
- method @Nullable public final android.os.IBinder onBind(@Nullable android.content.Intent);
- method @Nullable public android.view.SurfaceControlViewHost.SurfacePackage onCreateKeyguardSurface(@NonNull android.os.IBinder);
- }
-
- public class DevicePolicyManager {
- method @RequiresPermission(android.Manifest.permission.INTERACT_ACROSS_USERS) public boolean getBluetoothContactSharingDisabled(@NonNull android.os.UserHandle);
- method @Nullable @RequiresPermission(android.Manifest.permission.MANAGE_USERS) public String getDeviceOwner();
- method @RequiresPermission(android.Manifest.permission.MANAGE_USERS) public android.content.ComponentName getDeviceOwnerComponentOnAnyUser();
- method @RequiresPermission(android.Manifest.permission.MANAGE_USERS) public String getDeviceOwnerNameOnAnyUser();
- method @Nullable public CharSequence getDeviceOwnerOrganizationName();
- method @Nullable @RequiresPermission(android.Manifest.permission.MANAGE_USERS) public android.os.UserHandle getDeviceOwnerUser();
- method @Nullable @RequiresPermission(android.Manifest.permission.MANAGE_USERS) public java.util.List<java.lang.String> getPermittedAccessibilityServices(int);
- method @Nullable @RequiresPermission(android.Manifest.permission.MANAGE_USERS) public java.util.List<java.lang.String> getPermittedInputMethodsForCurrentUser();
- method @Nullable public android.content.ComponentName getProfileOwner() throws java.lang.IllegalArgumentException;
- method @Nullable @RequiresPermission(android.Manifest.permission.MANAGE_USERS) public String getProfileOwnerNameAsUser(int) throws java.lang.IllegalArgumentException;
- method @RequiresPermission(android.Manifest.permission.MANAGE_USERS) public int getUserProvisioningState();
- method public boolean isDeviceManaged();
- method @RequiresPermission(android.Manifest.permission.MANAGE_USERS) public boolean isDeviceProvisioned();
- method @RequiresPermission(android.Manifest.permission.MANAGE_USERS) public boolean isDeviceProvisioningConfigApplied();
- method @RequiresPermission(android.Manifest.permission.MANAGE_USERS) public boolean isManagedKiosk();
- method public boolean isSecondaryLockscreenEnabled(@NonNull android.os.UserHandle);
- method @RequiresPermission(android.Manifest.permission.MANAGE_USERS) public boolean isUnattendedManagedKiosk();
- method @RequiresPermission("android.permission.NOTIFY_PENDING_SYSTEM_UPDATE") public void notifyPendingSystemUpdate(long);
- method @RequiresPermission("android.permission.NOTIFY_PENDING_SYSTEM_UPDATE") public void notifyPendingSystemUpdate(long, boolean);
- method @RequiresPermission(android.Manifest.permission.INTERACT_ACROSS_USERS_FULL) public boolean packageHasActiveAdmins(String);
- method @Deprecated @RequiresPermission("android.permission.MANAGE_DEVICE_ADMINS") public boolean setActiveProfileOwner(@NonNull android.content.ComponentName, String) throws java.lang.IllegalArgumentException;
- method @RequiresPermission(android.Manifest.permission.MANAGE_USERS) public void setDeviceProvisioningConfigApplied();
- method @Deprecated @RequiresPermission(value=android.Manifest.permission.GRANT_PROFILE_OWNER_DEVICE_IDS_ACCESS, conditional=true) public void setProfileOwnerCanAccessDeviceIds(@NonNull android.content.ComponentName);
- method public void setSecondaryLockscreenEnabled(@NonNull android.content.ComponentName, boolean);
- field public static final String ACCOUNT_FEATURE_DEVICE_OR_PROFILE_OWNER_ALLOWED = "android.account.DEVICE_OR_PROFILE_OWNER_ALLOWED";
- field public static final String ACCOUNT_FEATURE_DEVICE_OR_PROFILE_OWNER_DISALLOWED = "android.account.DEVICE_OR_PROFILE_OWNER_DISALLOWED";
- field public static final String ACTION_BIND_SECONDARY_LOCKSCREEN_SERVICE = "android.app.action.BIND_SECONDARY_LOCKSCREEN_SERVICE";
- field public static final String ACTION_PROVISION_FINALIZATION = "android.app.action.PROVISION_FINALIZATION";
- field public static final String ACTION_PROVISION_FINANCED_DEVICE = "android.app.action.PROVISION_FINANCED_DEVICE";
- field public static final String ACTION_PROVISION_MANAGED_DEVICE_FROM_TRUSTED_SOURCE = "android.app.action.PROVISION_MANAGED_DEVICE_FROM_TRUSTED_SOURCE";
- field @RequiresPermission(android.Manifest.permission.MANAGE_FACTORY_RESET_PROTECTION) public static final String ACTION_RESET_PROTECTION_POLICY_CHANGED = "android.app.action.RESET_PROTECTION_POLICY_CHANGED";
- field public static final String ACTION_SET_PROFILE_OWNER = "android.app.action.SET_PROFILE_OWNER";
- field public static final String ACTION_STATE_USER_SETUP_COMPLETE = "android.app.action.STATE_USER_SETUP_COMPLETE";
- field public static final String EXTRA_PROFILE_OWNER_NAME = "android.app.extra.PROFILE_OWNER_NAME";
- field public static final String EXTRA_PROVISIONING_DEVICE_ADMIN_PACKAGE_ICON_URI = "android.app.extra.PROVISIONING_DEVICE_ADMIN_PACKAGE_ICON_URI";
- field public static final String EXTRA_PROVISIONING_DEVICE_ADMIN_PACKAGE_LABEL = "android.app.extra.PROVISIONING_DEVICE_ADMIN_PACKAGE_LABEL";
- field public static final String EXTRA_PROVISIONING_ORGANIZATION_NAME = "android.app.extra.PROVISIONING_ORGANIZATION_NAME";
- field public static final String EXTRA_PROVISIONING_SUPPORT_URL = "android.app.extra.PROVISIONING_SUPPORT_URL";
- field public static final String EXTRA_PROVISIONING_TRIGGER = "android.app.extra.PROVISIONING_TRIGGER";
- field public static final String EXTRA_RESTRICTION = "android.app.extra.RESTRICTION";
- field public static final int PROVISIONING_TRIGGER_CLOUD_ENROLLMENT = 1; // 0x1
- field public static final int PROVISIONING_TRIGGER_PERSISTENT_DEVICE_OWNER = 3; // 0x3
- field public static final int PROVISIONING_TRIGGER_QR_CODE = 2; // 0x2
- field public static final int PROVISIONING_TRIGGER_UNSPECIFIED = 0; // 0x0
- field public static final int STATE_USER_PROFILE_COMPLETE = 4; // 0x4
- field public static final int STATE_USER_PROFILE_FINALIZED = 5; // 0x5
- field public static final int STATE_USER_SETUP_COMPLETE = 2; // 0x2
- field public static final int STATE_USER_SETUP_FINALIZED = 3; // 0x3
- field public static final int STATE_USER_SETUP_INCOMPLETE = 1; // 0x1
- field public static final int STATE_USER_UNMANAGED = 0; // 0x0
- }
-
- public final class SystemUpdatePolicy implements android.os.Parcelable {
- method public android.app.admin.SystemUpdatePolicy.InstallationOption getInstallationOptionAt(long);
- field public static final int TYPE_PAUSE = 4; // 0x4
- }
-
- public static class SystemUpdatePolicy.InstallationOption {
- method public long getEffectiveTime();
- method public int getType();
- }
-
-}
-
-package android.app.appsearch {
-
- public class AppSearchManagerFrameworkInitializer {
- method public static void initialize();
- }
-
-}
-
-package android.app.assist {
-
- public static class AssistStructure.ViewNode {
- ctor public AssistStructure.ViewNode();
- }
-
-}
-
-package android.app.backup {
-
- public class BackupDataInput {
- ctor public BackupDataInput(java.io.FileDescriptor);
- }
-
- public class BackupDataOutput {
- ctor public BackupDataOutput(java.io.FileDescriptor);
- ctor public BackupDataOutput(java.io.FileDescriptor, long);
- }
-
- public class BackupManager {
- method @RequiresPermission(android.Manifest.permission.BACKUP) public void backupNow();
- method @RequiresPermission(android.Manifest.permission.BACKUP) public android.app.backup.RestoreSession beginRestoreSession();
- method @RequiresPermission(android.Manifest.permission.BACKUP) public void cancelBackups();
- method @RequiresPermission(android.Manifest.permission.BACKUP) public void excludeKeysFromRestore(@NonNull String, @NonNull java.util.List<java.lang.String>);
- method @RequiresPermission(android.Manifest.permission.BACKUP) public long getAvailableRestoreToken(String);
- method @RequiresPermission(android.Manifest.permission.BACKUP) public android.content.Intent getConfigurationIntent(String);
- method @RequiresPermission(android.Manifest.permission.BACKUP) public String getCurrentTransport();
- method @Nullable @RequiresPermission(android.Manifest.permission.BACKUP) public android.content.ComponentName getCurrentTransportComponent();
- method @RequiresPermission(android.Manifest.permission.BACKUP) public android.content.Intent getDataManagementIntent(String);
- method @Nullable @RequiresPermission(android.Manifest.permission.BACKUP) public CharSequence getDataManagementIntentLabel(@NonNull String);
- method @Deprecated @Nullable @RequiresPermission(android.Manifest.permission.BACKUP) public String getDataManagementLabel(@NonNull String);
- method @RequiresPermission(android.Manifest.permission.BACKUP) public String getDestinationString(String);
- method @RequiresPermission(android.Manifest.permission.BACKUP) public boolean isAppEligibleForBackup(String);
- method @RequiresPermission(android.Manifest.permission.BACKUP) public boolean isBackupEnabled();
- method @RequiresPermission(android.Manifest.permission.BACKUP) public boolean isBackupServiceActive(android.os.UserHandle);
- method @RequiresPermission(android.Manifest.permission.BACKUP) public String[] listAllTransports();
- method @RequiresPermission(android.Manifest.permission.BACKUP) public int requestBackup(String[], android.app.backup.BackupObserver);
- method @RequiresPermission(android.Manifest.permission.BACKUP) public int requestBackup(String[], android.app.backup.BackupObserver, android.app.backup.BackupManagerMonitor, int);
- method @Deprecated public int requestRestore(android.app.backup.RestoreObserver, android.app.backup.BackupManagerMonitor);
- method @Deprecated @RequiresPermission(android.Manifest.permission.BACKUP) public String selectBackupTransport(String);
- method @RequiresPermission(android.Manifest.permission.BACKUP) public void selectBackupTransport(android.content.ComponentName, android.app.backup.SelectBackupTransportCallback);
- method @RequiresPermission(android.Manifest.permission.BACKUP) public void setAncestralSerialNumber(long);
- method @RequiresPermission(android.Manifest.permission.BACKUP) public void setAutoRestore(boolean);
- method @RequiresPermission(android.Manifest.permission.BACKUP) public void setBackupEnabled(boolean);
- method @Deprecated @RequiresPermission(android.Manifest.permission.BACKUP) public void updateTransportAttributes(@NonNull android.content.ComponentName, @NonNull String, @Nullable android.content.Intent, @NonNull String, @Nullable android.content.Intent, @Nullable String);
- method @RequiresPermission(android.Manifest.permission.BACKUP) public void updateTransportAttributes(@NonNull android.content.ComponentName, @NonNull String, @Nullable android.content.Intent, @NonNull String, @Nullable android.content.Intent, @Nullable CharSequence);
- field public static final int ERROR_AGENT_FAILURE = -1003; // 0xfffffc15
- field public static final int ERROR_BACKUP_CANCELLED = -2003; // 0xfffff82d
- field public static final int ERROR_BACKUP_NOT_ALLOWED = -2001; // 0xfffff82f
- field public static final int ERROR_PACKAGE_NOT_FOUND = -2002; // 0xfffff82e
- field public static final int ERROR_TRANSPORT_ABORTED = -1000; // 0xfffffc18
- field public static final int ERROR_TRANSPORT_INVALID = -2; // 0xfffffffe
- field public static final int ERROR_TRANSPORT_PACKAGE_REJECTED = -1002; // 0xfffffc16
- field public static final int ERROR_TRANSPORT_QUOTA_EXCEEDED = -1005; // 0xfffffc13
- field public static final int ERROR_TRANSPORT_UNAVAILABLE = -1; // 0xffffffff
- field public static final int FLAG_NON_INCREMENTAL_BACKUP = 1; // 0x1
- field public static final String PACKAGE_MANAGER_SENTINEL = "@pm@";
- field public static final int SUCCESS = 0; // 0x0
- }
-
- public class BackupManagerMonitor {
- ctor public BackupManagerMonitor();
- method public void onEvent(android.os.Bundle);
- field public static final String EXTRA_LOG_CANCEL_ALL = "android.app.backup.extra.LOG_CANCEL_ALL";
- field public static final String EXTRA_LOG_EVENT_CATEGORY = "android.app.backup.extra.LOG_EVENT_CATEGORY";
- field public static final String EXTRA_LOG_EVENT_ID = "android.app.backup.extra.LOG_EVENT_ID";
- field public static final String EXTRA_LOG_EVENT_PACKAGE_LONG_VERSION = "android.app.backup.extra.LOG_EVENT_PACKAGE_FULL_VERSION";
- field public static final String EXTRA_LOG_EVENT_PACKAGE_NAME = "android.app.backup.extra.LOG_EVENT_PACKAGE_NAME";
- field @Deprecated public static final String EXTRA_LOG_EVENT_PACKAGE_VERSION = "android.app.backup.extra.LOG_EVENT_PACKAGE_VERSION";
- field public static final String EXTRA_LOG_EXCEPTION_FULL_BACKUP = "android.app.backup.extra.LOG_EXCEPTION_FULL_BACKUP";
- field public static final String EXTRA_LOG_ILLEGAL_KEY = "android.app.backup.extra.LOG_ILLEGAL_KEY";
- field public static final String EXTRA_LOG_MANIFEST_PACKAGE_NAME = "android.app.backup.extra.LOG_MANIFEST_PACKAGE_NAME";
- field public static final String EXTRA_LOG_OLD_VERSION = "android.app.backup.extra.LOG_OLD_VERSION";
- field public static final String EXTRA_LOG_POLICY_ALLOW_APKS = "android.app.backup.extra.LOG_POLICY_ALLOW_APKS";
- field public static final String EXTRA_LOG_PREFLIGHT_ERROR = "android.app.backup.extra.LOG_PREFLIGHT_ERROR";
- field public static final String EXTRA_LOG_RESTORE_ANYWAY = "android.app.backup.extra.LOG_RESTORE_ANYWAY";
- field public static final String EXTRA_LOG_RESTORE_VERSION = "android.app.backup.extra.LOG_RESTORE_VERSION";
- field public static final String EXTRA_LOG_WIDGET_PACKAGE_NAME = "android.app.backup.extra.LOG_WIDGET_PACKAGE_NAME";
- field public static final int LOG_EVENT_CATEGORY_AGENT = 2; // 0x2
- field public static final int LOG_EVENT_CATEGORY_BACKUP_MANAGER_POLICY = 3; // 0x3
- field public static final int LOG_EVENT_CATEGORY_TRANSPORT = 1; // 0x1
- field public static final int LOG_EVENT_ID_APK_NOT_INSTALLED = 40; // 0x28
- field public static final int LOG_EVENT_ID_APP_HAS_NO_AGENT = 28; // 0x1c
- field public static final int LOG_EVENT_ID_BACKUP_DISABLED = 13; // 0xd
- field public static final int LOG_EVENT_ID_CANNOT_RESTORE_WITHOUT_APK = 41; // 0x29
- field public static final int LOG_EVENT_ID_CANT_FIND_AGENT = 30; // 0x1e
- field public static final int LOG_EVENT_ID_CORRUPT_MANIFEST = 46; // 0x2e
- field public static final int LOG_EVENT_ID_DEVICE_NOT_PROVISIONED = 14; // 0xe
- field public static final int LOG_EVENT_ID_ERROR_PREFLIGHT = 16; // 0x10
- field public static final int LOG_EVENT_ID_EXCEPTION_FULL_BACKUP = 19; // 0x13
- field public static final int LOG_EVENT_ID_EXPECTED_DIFFERENT_PACKAGE = 43; // 0x2b
- field public static final int LOG_EVENT_ID_FULL_BACKUP_CANCEL = 4; // 0x4
- field public static final int LOG_EVENT_ID_FULL_RESTORE_ALLOW_BACKUP_FALSE = 39; // 0x27
- field public static final int LOG_EVENT_ID_FULL_RESTORE_SIGNATURE_MISMATCH = 37; // 0x25
- field public static final int LOG_EVENT_ID_FULL_RESTORE_TIMEOUT = 45; // 0x2d
- field public static final int LOG_EVENT_ID_ILLEGAL_KEY = 5; // 0x5
- field public static final int LOG_EVENT_ID_KEY_VALUE_BACKUP_CANCEL = 21; // 0x15
- field public static final int LOG_EVENT_ID_KEY_VALUE_RESTORE_TIMEOUT = 31; // 0x1f
- field public static final int LOG_EVENT_ID_LOST_TRANSPORT = 25; // 0x19
- field public static final int LOG_EVENT_ID_MISSING_SIGNATURE = 42; // 0x2a
- field public static final int LOG_EVENT_ID_NO_DATA_TO_SEND = 7; // 0x7
- field public static final int LOG_EVENT_ID_NO_PACKAGES = 49; // 0x31
- field public static final int LOG_EVENT_ID_NO_PM_METADATA_RECEIVED = 23; // 0x17
- field public static final int LOG_EVENT_ID_NO_RESTORE_METADATA_AVAILABLE = 22; // 0x16
- field public static final int LOG_EVENT_ID_PACKAGE_INELIGIBLE = 9; // 0x9
- field public static final int LOG_EVENT_ID_PACKAGE_KEY_VALUE_PARTICIPANT = 10; // 0xa
- field public static final int LOG_EVENT_ID_PACKAGE_NOT_FOUND = 12; // 0xc
- field public static final int LOG_EVENT_ID_PACKAGE_NOT_PRESENT = 26; // 0x1a
- field public static final int LOG_EVENT_ID_PACKAGE_STOPPED = 11; // 0xb
- field public static final int LOG_EVENT_ID_PACKAGE_TRANSPORT_NOT_PRESENT = 15; // 0xf
- field public static final int LOG_EVENT_ID_PM_AGENT_HAS_NO_METADATA = 24; // 0x18
- field public static final int LOG_EVENT_ID_QUOTA_HIT_PREFLIGHT = 18; // 0x12
- field public static final int LOG_EVENT_ID_RESTORE_ANY_VERSION = 34; // 0x22
- field public static final int LOG_EVENT_ID_RESTORE_VERSION_HIGHER = 27; // 0x1b
- field public static final int LOG_EVENT_ID_SIGNATURE_MISMATCH = 29; // 0x1d
- field public static final int LOG_EVENT_ID_SYSTEM_APP_NO_AGENT = 38; // 0x26
- field public static final int LOG_EVENT_ID_TRANSPORT_IS_NULL = 50; // 0x32
- field public static final int LOG_EVENT_ID_TRANSPORT_NON_INCREMENTAL_BACKUP_REQUIRED = 51; // 0x33
- field public static final int LOG_EVENT_ID_UNKNOWN_VERSION = 44; // 0x2c
- field public static final int LOG_EVENT_ID_VERSIONS_MATCH = 35; // 0x23
- field public static final int LOG_EVENT_ID_VERSION_OF_BACKUP_OLDER = 36; // 0x24
- field public static final int LOG_EVENT_ID_WIDGET_METADATA_MISMATCH = 47; // 0x2f
- field public static final int LOG_EVENT_ID_WIDGET_UNKNOWN_VERSION = 48; // 0x30
- }
-
- public abstract class BackupObserver {
- ctor public BackupObserver();
- method public void backupFinished(int);
- method public void onResult(String, int);
- method public void onUpdate(String, android.app.backup.BackupProgress);
- }
-
- public class BackupProgress implements android.os.Parcelable {
- ctor public BackupProgress(long, long);
- method public int describeContents();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.app.backup.BackupProgress> CREATOR;
- field public final long bytesExpected;
- field public final long bytesTransferred;
- }
-
- public class BackupTransport {
- ctor public BackupTransport();
- method public int abortFullRestore();
- method public void cancelFullBackup();
- method public int checkFullBackupSize(long);
- method public int clearBackupData(android.content.pm.PackageInfo);
- method public android.content.Intent configurationIntent();
- method public String currentDestinationString();
- method public android.content.Intent dataManagementIntent();
- method @Nullable public CharSequence dataManagementIntentLabel();
- method @Deprecated @Nullable public String dataManagementLabel();
- method public int finishBackup();
- method public void finishRestore();
- method public android.app.backup.RestoreSet[] getAvailableRestoreSets();
- method public long getBackupQuota(String, boolean);
- method public android.os.IBinder getBinder();
- method public long getCurrentRestoreSet();
- method public int getNextFullRestoreDataChunk(android.os.ParcelFileDescriptor);
- method public int getRestoreData(android.os.ParcelFileDescriptor);
- method public int getTransportFlags();
- method public int initializeDevice();
- method public boolean isAppEligibleForBackup(android.content.pm.PackageInfo, boolean);
- method public String name();
- method public android.app.backup.RestoreDescription nextRestorePackage();
- method public int performBackup(android.content.pm.PackageInfo, android.os.ParcelFileDescriptor, int);
- method public int performBackup(android.content.pm.PackageInfo, android.os.ParcelFileDescriptor);
- method public int performFullBackup(android.content.pm.PackageInfo, android.os.ParcelFileDescriptor, int);
- method public int performFullBackup(android.content.pm.PackageInfo, android.os.ParcelFileDescriptor);
- method public long requestBackupTime();
- method public long requestFullBackupTime();
- method public int sendBackupData(int);
- method public int startRestore(long, android.content.pm.PackageInfo[]);
- method public String transportDirName();
- field public static final int AGENT_ERROR = -1003; // 0xfffffc15
- field public static final int AGENT_UNKNOWN = -1004; // 0xfffffc14
- field public static final String EXTRA_TRANSPORT_REGISTRATION = "android.app.backup.extra.TRANSPORT_REGISTRATION";
- field public static final int FLAG_DATA_NOT_CHANGED = 8; // 0x8
- field public static final int FLAG_INCREMENTAL = 2; // 0x2
- field public static final int FLAG_NON_INCREMENTAL = 4; // 0x4
- field public static final int FLAG_USER_INITIATED = 1; // 0x1
- field public static final int NO_MORE_DATA = -1; // 0xffffffff
- field public static final int TRANSPORT_ERROR = -1000; // 0xfffffc18
- field public static final int TRANSPORT_NON_INCREMENTAL_BACKUP_REQUIRED = -1006; // 0xfffffc12
- field public static final int TRANSPORT_NOT_INITIALIZED = -1001; // 0xfffffc17
- field public static final int TRANSPORT_OK = 0; // 0x0
- field public static final int TRANSPORT_PACKAGE_REJECTED = -1002; // 0xfffffc16
- field public static final int TRANSPORT_QUOTA_EXCEEDED = -1005; // 0xfffffc13
- }
-
- public class RestoreDescription implements android.os.Parcelable {
- ctor public RestoreDescription(String, int);
- method public int describeContents();
- method public int getDataType();
- method public String getPackageName();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.app.backup.RestoreDescription> CREATOR;
- field public static final android.app.backup.RestoreDescription NO_MORE_PACKAGES;
- field public static final int TYPE_FULL_STREAM = 2; // 0x2
- field public static final int TYPE_KEY_VALUE = 1; // 0x1
- }
-
- public abstract class RestoreObserver {
- method public void restoreSetsAvailable(android.app.backup.RestoreSet[]);
- }
-
- public class RestoreSession {
- method public void endRestoreSession();
- method public int getAvailableRestoreSets(android.app.backup.RestoreObserver, android.app.backup.BackupManagerMonitor);
- method public int getAvailableRestoreSets(android.app.backup.RestoreObserver);
- method public int restoreAll(long, android.app.backup.RestoreObserver, android.app.backup.BackupManagerMonitor);
- method public int restoreAll(long, android.app.backup.RestoreObserver);
- method public int restorePackage(String, android.app.backup.RestoreObserver, android.app.backup.BackupManagerMonitor);
- method public int restorePackage(String, android.app.backup.RestoreObserver);
- method public int restorePackages(long, @Nullable android.app.backup.RestoreObserver, @NonNull java.util.Set<java.lang.String>, @Nullable android.app.backup.BackupManagerMonitor);
- method public int restorePackages(long, @Nullable android.app.backup.RestoreObserver, @NonNull java.util.Set<java.lang.String>);
- }
-
- public class RestoreSet implements android.os.Parcelable {
- ctor public RestoreSet();
- ctor public RestoreSet(String, String, long);
- method public int describeContents();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.app.backup.RestoreSet> CREATOR;
- field public String device;
- field public String name;
- field public long token;
- }
-
- public abstract class SelectBackupTransportCallback {
- ctor public SelectBackupTransportCallback();
- method public void onFailure(int);
- method public void onSuccess(String);
- }
-
-}
-
-package android.app.compat {
-
- public final class CompatChanges {
- method public static boolean isChangeEnabled(long);
- method @RequiresPermission(allOf={"android.permission.READ_COMPAT_CHANGE_CONFIG", "android.permission.LOG_COMPAT_CHANGE"}) public static boolean isChangeEnabled(long, @NonNull String, @NonNull android.os.UserHandle);
- method @RequiresPermission(allOf={"android.permission.READ_COMPAT_CHANGE_CONFIG", "android.permission.LOG_COMPAT_CHANGE"}) public static boolean isChangeEnabled(long, int);
- }
-
-}
-
-package android.app.contentsuggestions {
-
- public final class ClassificationsRequest implements android.os.Parcelable {
- method public int describeContents();
- method @NonNull public android.os.Bundle getExtras();
- method @NonNull public java.util.List<android.app.contentsuggestions.ContentSelection> getSelections();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.app.contentsuggestions.ClassificationsRequest> CREATOR;
- }
-
- public static final class ClassificationsRequest.Builder {
- ctor public ClassificationsRequest.Builder(@NonNull java.util.List<android.app.contentsuggestions.ContentSelection>);
- method @NonNull public android.app.contentsuggestions.ClassificationsRequest build();
- method @NonNull public android.app.contentsuggestions.ClassificationsRequest.Builder setExtras(@NonNull android.os.Bundle);
- }
-
- public final class ContentClassification implements android.os.Parcelable {
- ctor public ContentClassification(@NonNull String, @NonNull android.os.Bundle);
- method public int describeContents();
- method @NonNull public android.os.Bundle getExtras();
- method @NonNull public String getId();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.app.contentsuggestions.ContentClassification> CREATOR;
- }
-
- public final class ContentSelection implements android.os.Parcelable {
- ctor public ContentSelection(@NonNull String, @NonNull android.os.Bundle);
- method public int describeContents();
- method @NonNull public android.os.Bundle getExtras();
- method @NonNull public String getId();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.app.contentsuggestions.ContentSelection> CREATOR;
- }
-
- public final class ContentSuggestionsManager {
- method public void classifyContentSelections(@NonNull android.app.contentsuggestions.ClassificationsRequest, @NonNull java.util.concurrent.Executor, @NonNull android.app.contentsuggestions.ContentSuggestionsManager.ClassificationsCallback);
- method public boolean isEnabled();
- method public void notifyInteraction(@NonNull String, @NonNull android.os.Bundle);
- method public void provideContextImage(@NonNull android.graphics.Bitmap, @NonNull android.os.Bundle);
- method public void provideContextImage(int, @NonNull android.os.Bundle);
- method public void suggestContentSelections(@NonNull android.app.contentsuggestions.SelectionsRequest, @NonNull java.util.concurrent.Executor, @NonNull android.app.contentsuggestions.ContentSuggestionsManager.SelectionsCallback);
- }
-
- public static interface ContentSuggestionsManager.ClassificationsCallback {
- method public void onContentClassificationsAvailable(int, @NonNull java.util.List<android.app.contentsuggestions.ContentClassification>);
- }
-
- public static interface ContentSuggestionsManager.SelectionsCallback {
- method public void onContentSelectionsAvailable(int, @NonNull java.util.List<android.app.contentsuggestions.ContentSelection>);
- }
-
- public final class SelectionsRequest implements android.os.Parcelable {
- method public int describeContents();
- method @NonNull public android.os.Bundle getExtras();
- method @Nullable public android.graphics.Point getInterestPoint();
- method public int getTaskId();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.app.contentsuggestions.SelectionsRequest> CREATOR;
- }
-
- public static final class SelectionsRequest.Builder {
- ctor public SelectionsRequest.Builder(int);
- method @NonNull public android.app.contentsuggestions.SelectionsRequest build();
- method @NonNull public android.app.contentsuggestions.SelectionsRequest.Builder setExtras(@NonNull android.os.Bundle);
- method @NonNull public android.app.contentsuggestions.SelectionsRequest.Builder setInterestPoint(@NonNull android.graphics.Point);
- }
-
-}
-
-package android.app.job {
-
- public abstract class JobScheduler {
- method @RequiresPermission(android.Manifest.permission.UPDATE_DEVICE_STATS) public abstract int scheduleAsPackage(@NonNull android.app.job.JobInfo, @NonNull String, int, String);
- }
-
- public class JobSchedulerFrameworkInitializer {
- method public static void registerServiceWrappers();
- }
-
-}
-
-package android.app.prediction {
-
- public final class AppPredictionContext implements android.os.Parcelable {
- method public int describeContents();
- method @Nullable public android.os.Bundle getExtras();
- method @NonNull public String getPackageName();
- method @IntRange(from=0) public int getPredictedTargetCount();
- method @NonNull public String getUiSurface();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.app.prediction.AppPredictionContext> CREATOR;
- }
-
- public static final class AppPredictionContext.Builder {
- ctor public AppPredictionContext.Builder(@NonNull android.content.Context);
- method @NonNull public android.app.prediction.AppPredictionContext build();
- method @NonNull public android.app.prediction.AppPredictionContext.Builder setExtras(@Nullable android.os.Bundle);
- method @NonNull public android.app.prediction.AppPredictionContext.Builder setPredictedTargetCount(@IntRange(from=0) int);
- method @NonNull public android.app.prediction.AppPredictionContext.Builder setUiSurface(@NonNull String);
- }
-
- public final class AppPredictionManager {
- method @NonNull public android.app.prediction.AppPredictor createAppPredictionSession(@NonNull android.app.prediction.AppPredictionContext);
- }
-
- public final class AppPredictionSessionId implements android.os.Parcelable {
- method public int describeContents();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.app.prediction.AppPredictionSessionId> CREATOR;
- }
-
- public final class AppPredictor {
- method public void destroy();
- method public void notifyAppTargetEvent(@NonNull android.app.prediction.AppTargetEvent);
- method public void notifyLaunchLocationShown(@NonNull String, @NonNull java.util.List<android.app.prediction.AppTargetId>);
- method public void registerPredictionUpdates(@NonNull java.util.concurrent.Executor, @NonNull android.app.prediction.AppPredictor.Callback);
- method public void requestPredictionUpdate();
- method @Nullable public void sortTargets(@NonNull java.util.List<android.app.prediction.AppTarget>, @NonNull java.util.concurrent.Executor, @NonNull java.util.function.Consumer<java.util.List<android.app.prediction.AppTarget>>);
- method public void unregisterPredictionUpdates(@NonNull android.app.prediction.AppPredictor.Callback);
- }
-
- public static interface AppPredictor.Callback {
- method public void onTargetsAvailable(@NonNull java.util.List<android.app.prediction.AppTarget>);
- }
-
- public final class AppTarget implements android.os.Parcelable {
- method public int describeContents();
- method @Nullable public String getClassName();
- method @NonNull public android.app.prediction.AppTargetId getId();
- method @NonNull public String getPackageName();
- method @IntRange(from=0) public int getRank();
- method @Nullable public android.content.pm.ShortcutInfo getShortcutInfo();
- method @NonNull public android.os.UserHandle getUser();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.app.prediction.AppTarget> CREATOR;
- }
-
- public static final class AppTarget.Builder {
- ctor public AppTarget.Builder(@NonNull android.app.prediction.AppTargetId, @NonNull String, @NonNull android.os.UserHandle);
- ctor public AppTarget.Builder(@NonNull android.app.prediction.AppTargetId, @NonNull android.content.pm.ShortcutInfo);
- method @NonNull public android.app.prediction.AppTarget build();
- method @NonNull public android.app.prediction.AppTarget.Builder setClassName(@NonNull String);
- method @NonNull public android.app.prediction.AppTarget.Builder setRank(@IntRange(from=0) int);
- }
-
- public final class AppTargetEvent implements android.os.Parcelable {
- method public int describeContents();
- method public int getAction();
- method @Nullable public String getLaunchLocation();
- method @Nullable public android.app.prediction.AppTarget getTarget();
- method public void writeToParcel(android.os.Parcel, int);
- field public static final int ACTION_DISMISS = 2; // 0x2
- field public static final int ACTION_LAUNCH = 1; // 0x1
- field public static final int ACTION_PIN = 3; // 0x3
- field public static final int ACTION_UNPIN = 4; // 0x4
- field @NonNull public static final android.os.Parcelable.Creator<android.app.prediction.AppTargetEvent> CREATOR;
- }
-
- public static final class AppTargetEvent.Builder {
- ctor public AppTargetEvent.Builder(@Nullable android.app.prediction.AppTarget, int);
- method @NonNull public android.app.prediction.AppTargetEvent build();
- method @NonNull public android.app.prediction.AppTargetEvent.Builder setLaunchLocation(@Nullable String);
- }
-
- public final class AppTargetId implements android.os.Parcelable {
- ctor public AppTargetId(@NonNull String);
- method public int describeContents();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.app.prediction.AppTargetId> CREATOR;
- }
-
-}
-
-package android.app.role {
-
- public interface OnRoleHoldersChangedListener {
- method public void onRoleHoldersChanged(@NonNull String, @NonNull android.os.UserHandle);
- }
-
- public abstract class RoleControllerService extends android.app.Service {
- ctor public RoleControllerService();
- method @WorkerThread public abstract boolean onAddRoleHolder(@NonNull String, @NonNull String, int);
- method @Nullable public final android.os.IBinder onBind(@Nullable android.content.Intent);
- method @WorkerThread public abstract boolean onClearRoleHolders(@NonNull String, int);
- method @WorkerThread public abstract boolean onGrantDefaultRoles();
- method @Deprecated public abstract boolean onIsApplicationQualifiedForRole(@NonNull String, @NonNull String);
- method public boolean onIsApplicationVisibleForRole(@NonNull String, @NonNull String);
- method public abstract boolean onIsRoleVisible(@NonNull String);
- method @WorkerThread public abstract boolean onRemoveRoleHolder(@NonNull String, @NonNull String, int);
- field public static final String SERVICE_INTERFACE = "android.app.role.RoleControllerService";
- }
-
- public final class RoleManager {
- method @RequiresPermission(android.Manifest.permission.OBSERVE_ROLE_HOLDERS) public void addOnRoleHoldersChangedListenerAsUser(@NonNull java.util.concurrent.Executor, @NonNull android.app.role.OnRoleHoldersChangedListener, @NonNull android.os.UserHandle);
- method @RequiresPermission(android.Manifest.permission.MANAGE_ROLE_HOLDERS) public void addRoleHolderAsUser(@NonNull String, @NonNull String, int, @NonNull android.os.UserHandle, @NonNull java.util.concurrent.Executor, @NonNull java.util.function.Consumer<java.lang.Boolean>);
- method @RequiresPermission("com.android.permissioncontroller.permission.MANAGE_ROLES_FROM_CONTROLLER") public boolean addRoleHolderFromController(@NonNull String, @NonNull String);
- method @RequiresPermission(android.Manifest.permission.MANAGE_ROLE_HOLDERS) public void clearRoleHoldersAsUser(@NonNull String, int, @NonNull android.os.UserHandle, @NonNull java.util.concurrent.Executor, @NonNull java.util.function.Consumer<java.lang.Boolean>);
- method @NonNull @RequiresPermission("com.android.permissioncontroller.permission.MANAGE_ROLES_FROM_CONTROLLER") public java.util.List<java.lang.String> getHeldRolesFromController(@NonNull String);
- method @NonNull @RequiresPermission(android.Manifest.permission.MANAGE_ROLE_HOLDERS) public java.util.List<java.lang.String> getRoleHolders(@NonNull String);
- method @NonNull @RequiresPermission(android.Manifest.permission.MANAGE_ROLE_HOLDERS) public java.util.List<java.lang.String> getRoleHoldersAsUser(@NonNull String, @NonNull android.os.UserHandle);
- method @RequiresPermission(android.Manifest.permission.OBSERVE_ROLE_HOLDERS) public void removeOnRoleHoldersChangedListenerAsUser(@NonNull android.app.role.OnRoleHoldersChangedListener, @NonNull android.os.UserHandle);
- method @RequiresPermission(android.Manifest.permission.MANAGE_ROLE_HOLDERS) public void removeRoleHolderAsUser(@NonNull String, @NonNull String, int, @NonNull android.os.UserHandle, @NonNull java.util.concurrent.Executor, @NonNull java.util.function.Consumer<java.lang.Boolean>);
- method @RequiresPermission("com.android.permissioncontroller.permission.MANAGE_ROLES_FROM_CONTROLLER") public boolean removeRoleHolderFromController(@NonNull String, @NonNull String);
- method @RequiresPermission("com.android.permissioncontroller.permission.MANAGE_ROLES_FROM_CONTROLLER") public void setRoleNamesFromController(@NonNull java.util.List<java.lang.String>);
- field public static final int MANAGE_HOLDERS_FLAG_DONT_KILL_APP = 1; // 0x1
- }
-
-}
-
-package android.app.time {
-
- public final class TimeManager {
- method @RequiresPermission(android.Manifest.permission.MANAGE_TIME_AND_ZONE_DETECTION) public void addTimeZoneDetectorListener(@NonNull java.util.concurrent.Executor, @NonNull android.app.time.TimeManager.TimeZoneDetectorListener);
- method @NonNull @RequiresPermission(android.Manifest.permission.MANAGE_TIME_AND_ZONE_DETECTION) public android.app.time.TimeZoneCapabilitiesAndConfig getTimeZoneCapabilitiesAndConfig();
- method @RequiresPermission(android.Manifest.permission.MANAGE_TIME_AND_ZONE_DETECTION) public void removeTimeZoneDetectorListener(@NonNull android.app.time.TimeManager.TimeZoneDetectorListener);
- method @RequiresPermission(android.Manifest.permission.MANAGE_TIME_AND_ZONE_DETECTION) public boolean updateTimeZoneConfiguration(@NonNull android.app.time.TimeZoneConfiguration);
- }
-
- @java.lang.FunctionalInterface public static interface TimeManager.TimeZoneDetectorListener {
- method public void onChange();
- }
-
- public final class TimeZoneCapabilities implements android.os.Parcelable {
- method public int describeContents();
- method public int getConfigureAutoDetectionEnabledCapability();
- method public int getConfigureGeoDetectionEnabledCapability();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field public static final int CAPABILITY_NOT_ALLOWED = 20; // 0x14
- field public static final int CAPABILITY_NOT_APPLICABLE = 30; // 0x1e
- field public static final int CAPABILITY_NOT_SUPPORTED = 10; // 0xa
- field public static final int CAPABILITY_POSSESSED = 40; // 0x28
- field @NonNull public static final android.os.Parcelable.Creator<android.app.time.TimeZoneCapabilities> CREATOR;
- }
-
- public final class TimeZoneCapabilitiesAndConfig implements android.os.Parcelable {
- method public int describeContents();
- method @NonNull public android.app.time.TimeZoneCapabilities getCapabilities();
- method @NonNull public android.app.time.TimeZoneConfiguration getConfiguration();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.app.time.TimeZoneCapabilitiesAndConfig> CREATOR;
- }
-
- public final class TimeZoneConfiguration implements android.os.Parcelable {
- method public int describeContents();
- method public boolean isAutoDetectionEnabled();
- method public boolean isGeoDetectionEnabled();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.app.time.TimeZoneConfiguration> CREATOR;
- }
-
- public static final class TimeZoneConfiguration.Builder {
- ctor public TimeZoneConfiguration.Builder();
- ctor public TimeZoneConfiguration.Builder(@NonNull android.app.time.TimeZoneConfiguration);
- method @NonNull public android.app.time.TimeZoneConfiguration build();
- method @NonNull public android.app.time.TimeZoneConfiguration.Builder setAutoDetectionEnabled(boolean);
- method @NonNull public android.app.time.TimeZoneConfiguration.Builder setGeoDetectionEnabled(boolean);
- }
-
-}
-
-package android.app.usage {
-
- public final class CacheQuotaHint implements android.os.Parcelable {
- ctor public CacheQuotaHint(@NonNull android.app.usage.CacheQuotaHint.Builder);
- method public int describeContents();
- method public long getQuota();
- method public int getUid();
- method @Nullable public android.app.usage.UsageStats getUsageStats();
- method @Nullable public String getVolumeUuid();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.app.usage.CacheQuotaHint> CREATOR;
- field public static final long QUOTA_NOT_SET = -1L; // 0xffffffffffffffffL
- }
-
- public static final class CacheQuotaHint.Builder {
- ctor public CacheQuotaHint.Builder();
- ctor public CacheQuotaHint.Builder(@NonNull android.app.usage.CacheQuotaHint);
- method @NonNull public android.app.usage.CacheQuotaHint build();
- method @NonNull public android.app.usage.CacheQuotaHint.Builder setQuota(long);
- method @NonNull public android.app.usage.CacheQuotaHint.Builder setUid(int);
- method @NonNull public android.app.usage.CacheQuotaHint.Builder setUsageStats(@Nullable android.app.usage.UsageStats);
- method @NonNull public android.app.usage.CacheQuotaHint.Builder setVolumeUuid(@Nullable String);
- }
-
- public abstract class CacheQuotaService extends android.app.Service {
- ctor public CacheQuotaService();
- method public android.os.IBinder onBind(android.content.Intent);
- method public abstract java.util.List<android.app.usage.CacheQuotaHint> onComputeCacheQuotaHints(java.util.List<android.app.usage.CacheQuotaHint>);
- field public static final String SERVICE_INTERFACE = "android.app.usage.CacheQuotaService";
- }
-
- public class NetworkStatsManager {
- method @NonNull @RequiresPermission(anyOf={android.Manifest.permission.NETWORK_STATS_PROVIDER, android.net.NetworkStack.PERMISSION_MAINLINE_NETWORK_STACK}) public void registerNetworkStatsProvider(@NonNull String, @NonNull android.net.netstats.provider.NetworkStatsProvider);
- method @NonNull @RequiresPermission(anyOf={android.Manifest.permission.NETWORK_STATS_PROVIDER, android.net.NetworkStack.PERMISSION_MAINLINE_NETWORK_STACK}) public void unregisterNetworkStatsProvider(@NonNull android.net.netstats.provider.NetworkStatsProvider);
- }
-
- public static final class UsageEvents.Event {
- method public int getInstanceId();
- method @Nullable public String getNotificationChannelId();
- method @Nullable public String getTaskRootClassName();
- method @Nullable public String getTaskRootPackageName();
- method public boolean isInstantApp();
- field public static final int NOTIFICATION_INTERRUPTION = 12; // 0xc
- field public static final int NOTIFICATION_SEEN = 10; // 0xa
- field public static final int SLICE_PINNED = 14; // 0xe
- field public static final int SLICE_PINNED_PRIV = 13; // 0xd
- field public static final int SYSTEM_INTERACTION = 6; // 0x6
- }
-
- public final class UsageStats implements android.os.Parcelable {
- method public int getAppLaunchCount();
- }
-
- public final class UsageStatsManager {
- method @RequiresPermission(android.Manifest.permission.PACKAGE_USAGE_STATS) public int getAppStandbyBucket(String);
- method @RequiresPermission(android.Manifest.permission.PACKAGE_USAGE_STATS) public java.util.Map<java.lang.String,java.lang.Integer> getAppStandbyBuckets();
- method public int getUsageSource();
- method @RequiresPermission(android.Manifest.permission.BIND_CARRIER_SERVICES) public void onCarrierPrivilegedAppsChanged();
- method @RequiresPermission(allOf={android.Manifest.permission.SUSPEND_APPS, android.Manifest.permission.OBSERVE_APP_USAGE}) public void registerAppUsageLimitObserver(int, @NonNull String[], @NonNull java.time.Duration, @NonNull java.time.Duration, @Nullable android.app.PendingIntent);
- method @RequiresPermission(android.Manifest.permission.OBSERVE_APP_USAGE) public void registerAppUsageObserver(int, @NonNull String[], long, @NonNull java.util.concurrent.TimeUnit, @NonNull android.app.PendingIntent);
- method @RequiresPermission(android.Manifest.permission.OBSERVE_APP_USAGE) public void registerUsageSessionObserver(int, @NonNull String[], @NonNull java.time.Duration, @NonNull java.time.Duration, @NonNull android.app.PendingIntent, @Nullable android.app.PendingIntent);
- method public void reportUsageStart(@NonNull android.app.Activity, @NonNull String);
- method public void reportUsageStart(@NonNull android.app.Activity, @NonNull String, long);
- method public void reportUsageStop(@NonNull android.app.Activity, @NonNull String);
- method @RequiresPermission(android.Manifest.permission.CHANGE_APP_IDLE_STATE) public void setAppStandbyBucket(String, int);
- method @RequiresPermission(android.Manifest.permission.CHANGE_APP_IDLE_STATE) public void setAppStandbyBuckets(java.util.Map<java.lang.String,java.lang.Integer>);
- method @RequiresPermission(allOf={android.Manifest.permission.SUSPEND_APPS, android.Manifest.permission.OBSERVE_APP_USAGE}) public void unregisterAppUsageLimitObserver(int);
- method @RequiresPermission(android.Manifest.permission.OBSERVE_APP_USAGE) public void unregisterAppUsageObserver(int);
- method @RequiresPermission(android.Manifest.permission.OBSERVE_APP_USAGE) public void unregisterUsageSessionObserver(int);
- method @Deprecated @RequiresPermission(android.Manifest.permission.CHANGE_DEVICE_IDLE_TEMP_WHITELIST) public void whitelistAppTemporarily(String, long, android.os.UserHandle);
- field public static final String EXTRA_OBSERVER_ID = "android.app.usage.extra.OBSERVER_ID";
- field public static final String EXTRA_TIME_LIMIT = "android.app.usage.extra.TIME_LIMIT";
- field public static final String EXTRA_TIME_USED = "android.app.usage.extra.TIME_USED";
- field public static final int STANDBY_BUCKET_EXEMPTED = 5; // 0x5
- field public static final int STANDBY_BUCKET_NEVER = 50; // 0x32
- field public static final int USAGE_SOURCE_CURRENT_ACTIVITY = 2; // 0x2
- field public static final int USAGE_SOURCE_TASK_ROOT_ACTIVITY = 1; // 0x1
- }
-
-}
-
-package android.bluetooth {
-
- public final class BluetoothA2dp implements android.bluetooth.BluetoothProfile {
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public int getConnectionPolicy(@NonNull android.bluetooth.BluetoothDevice);
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public boolean setConnectionPolicy(@NonNull android.bluetooth.BluetoothDevice, int);
- field public static final int OPTIONAL_CODECS_NOT_SUPPORTED = 0; // 0x0
- field public static final int OPTIONAL_CODECS_PREF_DISABLED = 0; // 0x0
- field public static final int OPTIONAL_CODECS_PREF_ENABLED = 1; // 0x1
- field public static final int OPTIONAL_CODECS_PREF_UNKNOWN = -1; // 0xffffffff
- field public static final int OPTIONAL_CODECS_SUPPORTED = 1; // 0x1
- field public static final int OPTIONAL_CODECS_SUPPORT_UNKNOWN = -1; // 0xffffffff
- }
-
- public final class BluetoothA2dpSink implements android.bluetooth.BluetoothProfile {
- method public void finalize();
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public int getConnectionPolicy(@NonNull android.bluetooth.BluetoothDevice);
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public boolean isAudioPlaying(@NonNull android.bluetooth.BluetoothDevice);
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public boolean setConnectionPolicy(@NonNull android.bluetooth.BluetoothDevice, int);
- field @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public static final String ACTION_CONNECTION_STATE_CHANGED = "android.bluetooth.a2dp-sink.profile.action.CONNECTION_STATE_CHANGED";
- }
-
- public final class BluetoothAdapter {
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public boolean addOnMetadataChangedListener(@NonNull android.bluetooth.BluetoothDevice, @NonNull java.util.concurrent.Executor, @NonNull android.bluetooth.BluetoothAdapter.OnMetadataChangedListener);
- method public boolean disableBLE();
- method public boolean enableBLE();
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_ADMIN) public boolean enableNoAutoConnect();
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public long getDiscoveryEndMillis();
- method public boolean isBleScanAlwaysAvailable();
- method public boolean isLeEnabled();
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public boolean removeActiveDevice(int);
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public boolean removeOnMetadataChangedListener(@NonNull android.bluetooth.BluetoothDevice, @NonNull android.bluetooth.BluetoothAdapter.OnMetadataChangedListener);
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public boolean setActiveDevice(@NonNull android.bluetooth.BluetoothDevice, int);
- field public static final String ACTION_BLE_STATE_CHANGED = "android.bluetooth.adapter.action.BLE_STATE_CHANGED";
- field public static final String ACTION_REQUEST_BLE_SCAN_ALWAYS_AVAILABLE = "android.bluetooth.adapter.action.REQUEST_BLE_SCAN_ALWAYS_AVAILABLE";
- field public static final int ACTIVE_DEVICE_ALL = 2; // 0x2
- field public static final int ACTIVE_DEVICE_AUDIO = 0; // 0x0
- field public static final int ACTIVE_DEVICE_PHONE_CALL = 1; // 0x1
- }
-
- public static interface BluetoothAdapter.OnMetadataChangedListener {
- method public void onMetadataChanged(@NonNull android.bluetooth.BluetoothDevice, int, @Nullable byte[]);
- }
-
- public final class BluetoothDevice implements android.os.Parcelable {
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public boolean cancelBondProcess();
- method @Nullable @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public byte[] getMetadata(int);
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH) public int getSimAccessPermission();
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH) public boolean isConnected();
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH) public boolean isEncrypted();
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public boolean isInSilenceMode();
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public boolean removeBond();
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public boolean setMessageAccessPermission(int);
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public boolean setMetadata(int, @NonNull byte[]);
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public boolean setPhonebookAccessPermission(int);
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public boolean setSilenceMode(boolean);
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public boolean setSimAccessPermission(int);
- field public static final int ACCESS_ALLOWED = 1; // 0x1
- field public static final int ACCESS_REJECTED = 2; // 0x2
- field public static final int ACCESS_UNKNOWN = 0; // 0x0
- field public static final String ACTION_SILENCE_MODE_CHANGED = "android.bluetooth.device.action.SILENCE_MODE_CHANGED";
- field public static final int METADATA_COMPANION_APP = 4; // 0x4
- field public static final int METADATA_ENHANCED_SETTINGS_UI_URI = 16; // 0x10
- field public static final int METADATA_HARDWARE_VERSION = 3; // 0x3
- field public static final int METADATA_IS_UNTETHERED_HEADSET = 6; // 0x6
- field public static final int METADATA_MAIN_ICON = 5; // 0x5
- field public static final int METADATA_MANUFACTURER_NAME = 0; // 0x0
- field public static final int METADATA_MAX_LENGTH = 2048; // 0x800
- field public static final int METADATA_MODEL_NAME = 1; // 0x1
- field public static final int METADATA_SOFTWARE_VERSION = 2; // 0x2
- field public static final int METADATA_UNTETHERED_CASE_BATTERY = 12; // 0xc
- field public static final int METADATA_UNTETHERED_CASE_CHARGING = 15; // 0xf
- field public static final int METADATA_UNTETHERED_CASE_ICON = 9; // 0x9
- field public static final int METADATA_UNTETHERED_LEFT_BATTERY = 10; // 0xa
- field public static final int METADATA_UNTETHERED_LEFT_CHARGING = 13; // 0xd
- field public static final int METADATA_UNTETHERED_LEFT_ICON = 7; // 0x7
- field public static final int METADATA_UNTETHERED_RIGHT_BATTERY = 11; // 0xb
- field public static final int METADATA_UNTETHERED_RIGHT_CHARGING = 14; // 0xe
- field public static final int METADATA_UNTETHERED_RIGHT_ICON = 8; // 0x8
- }
-
- public final class BluetoothHeadset implements android.bluetooth.BluetoothProfile {
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_ADMIN) public boolean connect(android.bluetooth.BluetoothDevice);
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_ADMIN) public boolean disconnect(android.bluetooth.BluetoothDevice);
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public int getConnectionPolicy(@NonNull android.bluetooth.BluetoothDevice);
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public boolean setConnectionPolicy(@NonNull android.bluetooth.BluetoothDevice, int);
- method @Deprecated @RequiresPermission(android.Manifest.permission.BLUETOOTH_ADMIN) public boolean setPriority(android.bluetooth.BluetoothDevice, int);
- }
-
- public final class BluetoothHearingAid implements android.bluetooth.BluetoothProfile {
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public int getConnectionPolicy(@NonNull android.bluetooth.BluetoothDevice);
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public long getHiSyncId(@NonNull android.bluetooth.BluetoothDevice);
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public boolean setConnectionPolicy(@NonNull android.bluetooth.BluetoothDevice, int);
- }
-
- public final class BluetoothHidDevice implements android.bluetooth.BluetoothProfile {
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public boolean setConnectionPolicy(@NonNull android.bluetooth.BluetoothDevice, int);
- }
-
- public final class BluetoothHidHost implements android.bluetooth.BluetoothProfile {
- method @NonNull @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public java.util.List<android.bluetooth.BluetoothDevice> getConnectedDevices();
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public int getConnectionPolicy(@NonNull android.bluetooth.BluetoothDevice);
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public int getConnectionState(@NonNull android.bluetooth.BluetoothDevice);
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public boolean setConnectionPolicy(@NonNull android.bluetooth.BluetoothDevice, int);
- field public static final String ACTION_CONNECTION_STATE_CHANGED = "android.bluetooth.input.profile.action.CONNECTION_STATE_CHANGED";
- }
-
- public final class BluetoothMap implements java.lang.AutoCloseable android.bluetooth.BluetoothProfile {
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public void close();
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) protected void finalize();
- method @NonNull @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public java.util.List<android.bluetooth.BluetoothDevice> getConnectedDevices();
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public int getConnectionPolicy(@NonNull android.bluetooth.BluetoothDevice);
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public boolean setConnectionPolicy(@NonNull android.bluetooth.BluetoothDevice, int);
- field public static final String ACTION_CONNECTION_STATE_CHANGED = "android.bluetooth.map.profile.action.CONNECTION_STATE_CHANGED";
- }
-
- public final class BluetoothPan implements android.bluetooth.BluetoothProfile {
- method @NonNull @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public java.util.List<android.bluetooth.BluetoothDevice> getConnectedDevices();
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public int getConnectionState(@NonNull android.bluetooth.BluetoothDevice);
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public boolean isTetheringOn();
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public void setBluetoothTethering(boolean);
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public boolean setConnectionPolicy(@NonNull android.bluetooth.BluetoothDevice, int);
- field public static final String ACTION_CONNECTION_STATE_CHANGED = "android.bluetooth.pan.profile.action.CONNECTION_STATE_CHANGED";
- field public static final String ACTION_TETHERING_STATE_CHANGED = "android.bluetooth.action.TETHERING_STATE_CHANGED";
- field public static final String EXTRA_LOCAL_ROLE = "android.bluetooth.pan.extra.LOCAL_ROLE";
- field public static final String EXTRA_TETHERING_STATE = "android.bluetooth.extra.TETHERING_STATE";
- field public static final int LOCAL_NAP_ROLE = 1; // 0x1
- field public static final int LOCAL_PANU_ROLE = 2; // 0x2
- field public static final int PAN_ROLE_NONE = 0; // 0x0
- field public static final int REMOTE_NAP_ROLE = 1; // 0x1
- field public static final int REMOTE_PANU_ROLE = 2; // 0x2
- field public static final int TETHERING_STATE_OFF = 1; // 0x1
- field public static final int TETHERING_STATE_ON = 2; // 0x2
- }
-
- public class BluetoothPbap implements android.bluetooth.BluetoothProfile {
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public int getConnectionState(@NonNull android.bluetooth.BluetoothDevice);
- method @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public boolean setConnectionPolicy(@NonNull android.bluetooth.BluetoothDevice, int);
- field @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public static final String ACTION_CONNECTION_STATE_CHANGED = "android.bluetooth.pbap.profile.action.CONNECTION_STATE_CHANGED";
- }
-
- public interface BluetoothProfile {
- field public static final int A2DP_SINK = 11; // 0xb
- field public static final int AVRCP_CONTROLLER = 12; // 0xc
- field public static final int CONNECTION_POLICY_ALLOWED = 100; // 0x64
- field public static final int CONNECTION_POLICY_FORBIDDEN = 0; // 0x0
- field public static final int CONNECTION_POLICY_UNKNOWN = -1; // 0xffffffff
- field public static final int HEADSET_CLIENT = 16; // 0x10
- field public static final int PAN = 5; // 0x5
- field public static final int PBAP_CLIENT = 17; // 0x11
- field @Deprecated public static final int PRIORITY_OFF = 0; // 0x0
- field @Deprecated public static final int PRIORITY_ON = 100; // 0x64
- }
-
- public final class BluetoothUuid {
- method public static boolean containsAnyUuid(@Nullable android.os.ParcelUuid[], @Nullable android.os.ParcelUuid[]);
- method @NonNull public static android.os.ParcelUuid parseUuidFrom(@Nullable byte[]);
- field @NonNull public static final android.os.ParcelUuid A2DP_SINK;
- field @NonNull public static final android.os.ParcelUuid A2DP_SOURCE;
- field @NonNull public static final android.os.ParcelUuid ADV_AUDIO_DIST;
- field @NonNull public static final android.os.ParcelUuid AVRCP_CONTROLLER;
- field @NonNull public static final android.os.ParcelUuid AVRCP_TARGET;
- field @NonNull public static final android.os.ParcelUuid BASE_UUID;
- field @NonNull public static final android.os.ParcelUuid BNEP;
- field @NonNull public static final android.os.ParcelUuid HEARING_AID;
- field @NonNull public static final android.os.ParcelUuid HFP;
- field @NonNull public static final android.os.ParcelUuid HFP_AG;
- field @NonNull public static final android.os.ParcelUuid HID;
- field @NonNull public static final android.os.ParcelUuid HOGP;
- field @NonNull public static final android.os.ParcelUuid HSP;
- field @NonNull public static final android.os.ParcelUuid HSP_AG;
- field @NonNull public static final android.os.ParcelUuid MAP;
- field @NonNull public static final android.os.ParcelUuid MAS;
- field @NonNull public static final android.os.ParcelUuid MNS;
- field @NonNull public static final android.os.ParcelUuid NAP;
- field @NonNull public static final android.os.ParcelUuid OBEX_OBJECT_PUSH;
- field @NonNull public static final android.os.ParcelUuid PANU;
- field @NonNull public static final android.os.ParcelUuid PBAP_PCE;
- field @NonNull public static final android.os.ParcelUuid PBAP_PSE;
- field @NonNull public static final android.os.ParcelUuid SAP;
- field public static final int UUID_BYTES_128_BIT = 16; // 0x10
- field public static final int UUID_BYTES_16_BIT = 2; // 0x2
- field public static final int UUID_BYTES_32_BIT = 4; // 0x4
- }
-
-}
-
-package android.bluetooth.le {
-
- public final class BluetoothLeScanner {
- method @RequiresPermission(allOf={android.Manifest.permission.BLUETOOTH_ADMIN, android.Manifest.permission.UPDATE_DEVICE_STATS}) public void startScanFromSource(android.os.WorkSource, android.bluetooth.le.ScanCallback);
- method @RequiresPermission(allOf={android.Manifest.permission.BLUETOOTH_ADMIN, android.Manifest.permission.UPDATE_DEVICE_STATS}) public void startScanFromSource(java.util.List<android.bluetooth.le.ScanFilter>, android.bluetooth.le.ScanSettings, android.os.WorkSource, android.bluetooth.le.ScanCallback);
- method public void startTruncatedScan(java.util.List<android.bluetooth.le.TruncatedFilter>, android.bluetooth.le.ScanSettings, android.bluetooth.le.ScanCallback);
- }
-
- public final class ResultStorageDescriptor implements android.os.Parcelable {
- ctor public ResultStorageDescriptor(int, int, int);
- method public int describeContents();
- method public int getLength();
- method public int getOffset();
- method public int getType();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.bluetooth.le.ResultStorageDescriptor> CREATOR;
- }
-
- public final class ScanSettings implements android.os.Parcelable {
- field public static final int SCAN_RESULT_TYPE_ABBREVIATED = 1; // 0x1
- field public static final int SCAN_RESULT_TYPE_FULL = 0; // 0x0
- }
-
- public static final class ScanSettings.Builder {
- method public android.bluetooth.le.ScanSettings.Builder setScanResultType(int);
- }
-
- public final class TruncatedFilter {
- ctor public TruncatedFilter(android.bluetooth.le.ScanFilter, java.util.List<android.bluetooth.le.ResultStorageDescriptor>);
- method public android.bluetooth.le.ScanFilter getFilter();
- method public java.util.List<android.bluetooth.le.ResultStorageDescriptor> getStorageDescriptors();
- }
-
-}
-
-package android.companion {
-
- public final class CompanionDeviceManager {
- method @RequiresPermission("android.permission.MANAGE_COMPANION_DEVICES") public boolean isDeviceAssociatedForWifiConnection(@NonNull String, @NonNull android.net.MacAddress, @NonNull android.os.UserHandle);
- }
-
-}
-
-package android.content {
-
- public class ApexEnvironment {
- method @NonNull public static android.content.ApexEnvironment getApexEnvironment(@NonNull String);
- method @NonNull public java.io.File getCredentialProtectedDataDirForUser(@NonNull android.os.UserHandle);
- method @NonNull public java.io.File getDeviceProtectedDataDir();
- method @NonNull public java.io.File getDeviceProtectedDataDirForUser(@NonNull android.os.UserHandle);
- }
-
- public abstract class BroadcastReceiver {
- method @NonNull public final android.os.UserHandle getSendingUser();
- }
-
- public abstract class ContentProvider implements android.content.ComponentCallbacks2 {
- method public int checkUriPermission(@NonNull android.net.Uri, int, int);
- }
-
- public class ContentProviderClient implements java.lang.AutoCloseable {
- method @RequiresPermission(android.Manifest.permission.REMOVE_TASKS) public void setDetectNotResponding(long);
- }
-
- public abstract class ContentResolver {
- method public int checkUriPermission(@NonNull android.net.Uri, int, int);
- method @NonNull public static android.net.Uri decodeFromFile(@NonNull java.io.File);
- method @NonNull public static java.io.File encodeToFile(@NonNull android.net.Uri);
- method @Nullable @RequiresPermission("android.permission.CACHE_CONTENT") public android.os.Bundle getCache(@NonNull android.net.Uri);
- method @RequiresPermission("android.permission.CACHE_CONTENT") public void putCache(@NonNull android.net.Uri, @Nullable android.os.Bundle);
- }
-
- public abstract class Context {
- method @NonNull public android.content.Context createContextAsUser(@NonNull android.os.UserHandle, int);
- method public abstract android.content.Context createCredentialProtectedStorageContext();
- method @NonNull public android.content.Context createPackageContextAsUser(@NonNull String, int, @NonNull android.os.UserHandle) throws android.content.pm.PackageManager.NameNotFoundException;
- method @Nullable public abstract java.io.File getPreloadsFileCache();
- method public abstract boolean isCredentialProtectedStorage();
- method @Nullable @RequiresPermission(android.Manifest.permission.INTERACT_ACROSS_USERS_FULL) public android.content.Intent registerReceiverForAllUsers(@Nullable android.content.BroadcastReceiver, @NonNull android.content.IntentFilter, @Nullable String, @Nullable android.os.Handler);
- method public abstract void sendBroadcast(android.content.Intent, @Nullable String, @Nullable android.os.Bundle);
- method @RequiresPermission(android.Manifest.permission.INTERACT_ACROSS_USERS) public abstract void sendBroadcastAsUser(@RequiresPermission android.content.Intent, android.os.UserHandle, @Nullable String, @Nullable android.os.Bundle);
- method public abstract void sendOrderedBroadcast(@NonNull android.content.Intent, @Nullable String, @Nullable android.os.Bundle, @Nullable android.content.BroadcastReceiver, @Nullable android.os.Handler, int, @Nullable String, @Nullable android.os.Bundle);
- method @RequiresPermission(android.Manifest.permission.INTERACT_ACROSS_USERS) public void startActivityAsUser(@NonNull @RequiresPermission android.content.Intent, @NonNull android.os.UserHandle);
- field public static final String APP_INTEGRITY_SERVICE = "app_integrity";
- field public static final String APP_PREDICTION_SERVICE = "app_prediction";
- field public static final String BACKUP_SERVICE = "backup";
- field public static final String BATTERY_STATS_SERVICE = "batterystats";
- field public static final int BIND_ALLOW_BACKGROUND_ACTIVITY_STARTS = 1048576; // 0x100000
- field public static final String BUGREPORT_SERVICE = "bugreport";
- field public static final String CONTENT_SUGGESTIONS_SERVICE = "content_suggestions";
- field public static final String CONTEXTHUB_SERVICE = "contexthub";
- field public static final String ETHERNET_SERVICE = "ethernet";
- field public static final String EUICC_CARD_SERVICE = "euicc_card";
- field public static final String HDMI_CONTROL_SERVICE = "hdmi_control";
- field public static final String MEDIA_TRANSCODING_SERVICE = "media_transcoding";
- field public static final String NETD_SERVICE = "netd";
- field public static final String NETWORK_SCORE_SERVICE = "network_score";
- field public static final String OEM_LOCK_SERVICE = "oem_lock";
- field public static final String PERMISSION_SERVICE = "permission";
- field public static final String PERSISTENT_DATA_BLOCK_SERVICE = "persistent_data_block";
- field public static final String ROLLBACK_SERVICE = "rollback";
- field public static final String SECURE_ELEMENT_SERVICE = "secure_element";
- field public static final String STATS_MANAGER = "stats";
- field public static final String STATUS_BAR_SERVICE = "statusbar";
- field public static final String SYSTEM_CONFIG_SERVICE = "system_config";
- field public static final String SYSTEM_UPDATE_SERVICE = "system_update";
- field public static final String TETHERING_SERVICE = "tethering";
- field public static final String VR_SERVICE = "vrmanager";
- field public static final String WIFI_NL80211_SERVICE = "wifinl80211";
- field @Deprecated public static final String WIFI_RTT_SERVICE = "rttmanager";
- field public static final String WIFI_SCANNING_SERVICE = "wifiscanner";
- }
-
- public class ContextWrapper extends android.content.Context {
- method public android.content.Context createCredentialProtectedStorageContext();
- method public java.io.File getPreloadsFileCache();
- method public boolean isCredentialProtectedStorage();
- method public void sendBroadcast(android.content.Intent, String, android.os.Bundle);
- method public void sendBroadcastAsUser(android.content.Intent, android.os.UserHandle, String, android.os.Bundle);
- method public void sendOrderedBroadcast(android.content.Intent, String, android.os.Bundle, android.content.BroadcastReceiver, android.os.Handler, int, String, android.os.Bundle);
- }
-
- public class Intent implements java.lang.Cloneable android.os.Parcelable {
- field public static final String ACTION_BATTERY_LEVEL_CHANGED = "android.intent.action.BATTERY_LEVEL_CHANGED";
- field public static final String ACTION_CALL_EMERGENCY = "android.intent.action.CALL_EMERGENCY";
- field public static final String ACTION_CALL_PRIVILEGED = "android.intent.action.CALL_PRIVILEGED";
- field public static final String ACTION_DEVICE_CUSTOMIZATION_READY = "android.intent.action.DEVICE_CUSTOMIZATION_READY";
- field public static final String ACTION_DIAL_EMERGENCY = "android.intent.action.DIAL_EMERGENCY";
- field public static final String ACTION_FACTORY_RESET = "android.intent.action.FACTORY_RESET";
- field public static final String ACTION_GLOBAL_BUTTON = "android.intent.action.GLOBAL_BUTTON";
- field public static final String ACTION_INCIDENT_REPORT_READY = "android.intent.action.INCIDENT_REPORT_READY";
- field public static final String ACTION_INSTALL_INSTANT_APP_PACKAGE = "android.intent.action.INSTALL_INSTANT_APP_PACKAGE";
- field public static final String ACTION_INSTANT_APP_RESOLVER_SETTINGS = "android.intent.action.INSTANT_APP_RESOLVER_SETTINGS";
- field public static final String ACTION_INTENT_FILTER_NEEDS_VERIFICATION = "android.intent.action.INTENT_FILTER_NEEDS_VERIFICATION";
- field public static final String ACTION_LOAD_DATA = "android.intent.action.LOAD_DATA";
- field @RequiresPermission(android.Manifest.permission.GRANT_RUNTIME_PERMISSIONS) public static final String ACTION_MANAGE_APP_PERMISSION = "android.intent.action.MANAGE_APP_PERMISSION";
- field public static final String ACTION_MANAGE_APP_PERMISSIONS = "android.intent.action.MANAGE_APP_PERMISSIONS";
- field @RequiresPermission(android.Manifest.permission.MANAGE_ROLE_HOLDERS) public static final String ACTION_MANAGE_DEFAULT_APP = "android.intent.action.MANAGE_DEFAULT_APP";
- field public static final String ACTION_MANAGE_PERMISSIONS = "android.intent.action.MANAGE_PERMISSIONS";
- field public static final String ACTION_MANAGE_PERMISSION_APPS = "android.intent.action.MANAGE_PERMISSION_APPS";
- field @RequiresPermission(android.Manifest.permission.MANAGE_ROLE_HOLDERS) public static final String ACTION_MANAGE_SPECIAL_APP_ACCESSES = "android.intent.action.MANAGE_SPECIAL_APP_ACCESSES";
- field public static final String ACTION_MASTER_CLEAR_NOTIFICATION = "android.intent.action.MASTER_CLEAR_NOTIFICATION";
- field public static final String ACTION_PACKAGE_NEEDS_INTEGRITY_VERIFICATION = "android.intent.action.PACKAGE_NEEDS_INTEGRITY_VERIFICATION";
- field public static final String ACTION_PACKAGE_UNSUSPENDED_MANUALLY = "android.intent.action.PACKAGE_UNSUSPENDED_MANUALLY";
- field public static final String ACTION_PENDING_INCIDENT_REPORTS_CHANGED = "android.intent.action.PENDING_INCIDENT_REPORTS_CHANGED";
- field public static final String ACTION_PRE_BOOT_COMPLETED = "android.intent.action.PRE_BOOT_COMPLETED";
- field public static final String ACTION_QUERY_PACKAGE_RESTART = "android.intent.action.QUERY_PACKAGE_RESTART";
- field public static final String ACTION_RESOLVE_INSTANT_APP_PACKAGE = "android.intent.action.RESOLVE_INSTANT_APP_PACKAGE";
- field @RequiresPermission(android.Manifest.permission.REVIEW_ACCESSIBILITY_SERVICES) public static final String ACTION_REVIEW_ACCESSIBILITY_SERVICES = "android.intent.action.REVIEW_ACCESSIBILITY_SERVICES";
- field @RequiresPermission(android.Manifest.permission.GRANT_RUNTIME_PERMISSIONS) public static final String ACTION_REVIEW_ONGOING_PERMISSION_USAGE = "android.intent.action.REVIEW_ONGOING_PERMISSION_USAGE";
- field public static final String ACTION_REVIEW_PERMISSIONS = "android.intent.action.REVIEW_PERMISSIONS";
- field @RequiresPermission(android.Manifest.permission.GRANT_RUNTIME_PERMISSIONS) public static final String ACTION_REVIEW_PERMISSION_USAGE = "android.intent.action.REVIEW_PERMISSION_USAGE";
- field public static final String ACTION_ROLLBACK_COMMITTED = "android.intent.action.ROLLBACK_COMMITTED";
- field public static final String ACTION_SHOW_SUSPENDED_APP_DETAILS = "android.intent.action.SHOW_SUSPENDED_APP_DETAILS";
- field @Deprecated public static final String ACTION_SIM_STATE_CHANGED = "android.intent.action.SIM_STATE_CHANGED";
- field public static final String ACTION_SPLIT_CONFIGURATION_CHANGED = "android.intent.action.SPLIT_CONFIGURATION_CHANGED";
- field public static final String ACTION_UPGRADE_SETUP = "android.intent.action.UPGRADE_SETUP";
- field public static final String ACTION_USER_ADDED = "android.intent.action.USER_ADDED";
- field public static final String ACTION_USER_REMOVED = "android.intent.action.USER_REMOVED";
- field public static final String ACTION_VOICE_ASSIST = "android.intent.action.VOICE_ASSIST";
- field public static final String CATEGORY_LEANBACK_SETTINGS = "android.intent.category.LEANBACK_SETTINGS";
- field public static final String EXTRA_CALLING_PACKAGE = "android.intent.extra.CALLING_PACKAGE";
- field public static final String EXTRA_FORCE_FACTORY_RESET = "android.intent.extra.FORCE_FACTORY_RESET";
- field public static final String EXTRA_INSTANT_APP_ACTION = "android.intent.extra.INSTANT_APP_ACTION";
- field public static final String EXTRA_INSTANT_APP_BUNDLES = "android.intent.extra.INSTANT_APP_BUNDLES";
- field public static final String EXTRA_INSTANT_APP_EXTRAS = "android.intent.extra.INSTANT_APP_EXTRAS";
- field public static final String EXTRA_INSTANT_APP_FAILURE = "android.intent.extra.INSTANT_APP_FAILURE";
- field public static final String EXTRA_INSTANT_APP_HOSTNAME = "android.intent.extra.INSTANT_APP_HOSTNAME";
- field public static final String EXTRA_INSTANT_APP_SUCCESS = "android.intent.extra.INSTANT_APP_SUCCESS";
- field public static final String EXTRA_INSTANT_APP_TOKEN = "android.intent.extra.INSTANT_APP_TOKEN";
- field public static final String EXTRA_LONG_VERSION_CODE = "android.intent.extra.LONG_VERSION_CODE";
- field public static final String EXTRA_ORIGINATING_UID = "android.intent.extra.ORIGINATING_UID";
- field public static final String EXTRA_PACKAGES = "android.intent.extra.PACKAGES";
- field public static final String EXTRA_PERMISSION_GROUP_NAME = "android.intent.extra.PERMISSION_GROUP_NAME";
- field public static final String EXTRA_PERMISSION_NAME = "android.intent.extra.PERMISSION_NAME";
- field public static final String EXTRA_REASON = "android.intent.extra.REASON";
- field public static final String EXTRA_REMOTE_CALLBACK = "android.intent.extra.REMOTE_CALLBACK";
- field public static final String EXTRA_RESULT_NEEDED = "android.intent.extra.RESULT_NEEDED";
- field public static final String EXTRA_ROLE_NAME = "android.intent.extra.ROLE_NAME";
- field public static final String EXTRA_UNKNOWN_INSTANT_APP = "android.intent.extra.UNKNOWN_INSTANT_APP";
- field public static final String EXTRA_VERIFICATION_BUNDLE = "android.intent.extra.VERIFICATION_BUNDLE";
- field public static final int FLAG_RECEIVER_REGISTERED_ONLY_BEFORE_BOOT = 67108864; // 0x4000000
- field public static final String METADATA_SETUP_VERSION = "android.SETUP_VERSION";
- }
-
- public class IntentFilter implements android.os.Parcelable {
- method public final int getOrder();
- method public final void setOrder(int);
- }
-
-}
-
-package android.content.integrity {
-
- public class AppIntegrityManager {
- method @NonNull public String getCurrentRuleSetProvider();
- method @NonNull public String getCurrentRuleSetVersion();
- method public void updateRuleSet(@NonNull android.content.integrity.RuleSet, @NonNull android.content.IntentSender);
- field public static final String EXTRA_STATUS = "android.content.integrity.extra.STATUS";
- field public static final int STATUS_FAILURE = 1; // 0x1
- field public static final int STATUS_SUCCESS = 0; // 0x0
- }
-
- public abstract class IntegrityFormula {
- method @NonNull public static android.content.integrity.IntegrityFormula all(@NonNull android.content.integrity.IntegrityFormula...);
- method @NonNull public static android.content.integrity.IntegrityFormula any(@NonNull android.content.integrity.IntegrityFormula...);
- method @NonNull public static android.content.integrity.IntegrityFormula not(@NonNull android.content.integrity.IntegrityFormula);
- }
-
- public static final class IntegrityFormula.Application {
- method @NonNull public static android.content.integrity.IntegrityFormula certificatesContain(@NonNull String);
- method @NonNull public static android.content.integrity.IntegrityFormula isPreInstalled();
- method @NonNull public static android.content.integrity.IntegrityFormula packageNameEquals(@NonNull String);
- method @NonNull public static android.content.integrity.IntegrityFormula versionCodeEquals(@NonNull long);
- method @NonNull public static android.content.integrity.IntegrityFormula versionCodeGreaterThan(@NonNull long);
- method @NonNull public static android.content.integrity.IntegrityFormula versionCodeGreaterThanOrEqualTo(@NonNull long);
- }
-
- public static final class IntegrityFormula.Installer {
- method @NonNull public static android.content.integrity.IntegrityFormula certificatesContain(@NonNull String);
- method @NonNull public static android.content.integrity.IntegrityFormula notAllowedByManifest();
- method @NonNull public static android.content.integrity.IntegrityFormula packageNameEquals(@NonNull String);
- }
-
- public static final class IntegrityFormula.SourceStamp {
- method @NonNull public static android.content.integrity.IntegrityFormula notTrusted();
- method @NonNull public static android.content.integrity.IntegrityFormula stampCertificateHashEquals(@NonNull String);
- }
-
- public final class Rule implements android.os.Parcelable {
- ctor public Rule(@NonNull android.content.integrity.IntegrityFormula, int);
- method public int describeContents();
- method public int getEffect();
- method @NonNull public android.content.integrity.IntegrityFormula getFormula();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.content.integrity.Rule> CREATOR;
- field public static final int DENY = 0; // 0x0
- field public static final int FORCE_ALLOW = 1; // 0x1
- }
-
- public class RuleSet {
- method @NonNull public java.util.List<android.content.integrity.Rule> getRules();
- method @NonNull public String getVersion();
- }
-
- public static class RuleSet.Builder {
- ctor public RuleSet.Builder();
- method @NonNull public android.content.integrity.RuleSet.Builder addRules(@NonNull java.util.List<android.content.integrity.Rule>);
- method @NonNull public android.content.integrity.RuleSet build();
- method @NonNull public android.content.integrity.RuleSet.Builder setVersion(@NonNull String);
- }
-
-}
-
-package android.content.om {
-
- public final class OverlayInfo implements android.os.Parcelable {
- method public int describeContents();
- method @Nullable public String getCategory();
- method @NonNull public String getPackageName();
- method @Nullable public String getTargetOverlayableName();
- method @NonNull public String getTargetPackageName();
- method public int getUserId();
- method public boolean isEnabled();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.content.om.OverlayInfo> CREATOR;
- }
-
- public class OverlayManager {
- method @Nullable public android.content.om.OverlayInfo getOverlayInfo(@NonNull String, @NonNull android.os.UserHandle);
- method @NonNull @RequiresPermission(anyOf={"android.permission.INTERACT_ACROSS_USERS", "android.permission.INTERACT_ACROSS_USERS_FULL"}) public java.util.List<android.content.om.OverlayInfo> getOverlayInfosForTarget(@NonNull String, @NonNull android.os.UserHandle);
- method @RequiresPermission(anyOf={"android.permission.INTERACT_ACROSS_USERS", "android.permission.INTERACT_ACROSS_USERS_FULL"}) public void setEnabled(@NonNull String, boolean, @NonNull android.os.UserHandle) throws java.lang.IllegalStateException, java.lang.SecurityException;
- method @RequiresPermission(anyOf={"android.permission.INTERACT_ACROSS_USERS", "android.permission.INTERACT_ACROSS_USERS_FULL"}) public void setEnabledExclusiveInCategory(@NonNull String, @NonNull android.os.UserHandle) throws java.lang.IllegalStateException, java.lang.SecurityException;
- }
-
-}
-
-package android.content.pm {
-
- public class ApplicationInfo extends android.content.pm.PackageItemInfo implements android.os.Parcelable {
- method public boolean isEncryptionAware();
- method public boolean isInstantApp();
- field public String credentialProtectedDataDir;
- field public int targetSandboxVersion;
- }
-
- public class CrossProfileApps {
- method @RequiresPermission(android.Manifest.permission.INTERACT_ACROSS_PROFILES) public void startActivity(@NonNull android.content.ComponentName, @NonNull android.os.UserHandle);
- }
-
- public class DataLoaderParams {
- method @NonNull public static final android.content.pm.DataLoaderParams forIncremental(@NonNull android.content.ComponentName, @NonNull String);
- method @NonNull public static final android.content.pm.DataLoaderParams forStreaming(@NonNull android.content.ComponentName, @NonNull String);
- method @NonNull public final String getArguments();
- method @NonNull public final android.content.ComponentName getComponentName();
- method @NonNull public final int getType();
- }
-
- public final class InstallationFile {
- method public long getLengthBytes();
- method public int getLocation();
- method @Nullable public byte[] getMetadata();
- method @NonNull public String getName();
- method @Nullable public byte[] getSignature();
- }
-
- public final class InstantAppInfo implements android.os.Parcelable {
- ctor public InstantAppInfo(android.content.pm.ApplicationInfo, String[], String[]);
- ctor public InstantAppInfo(String, CharSequence, String[], String[]);
- method public int describeContents();
- method @Nullable public android.content.pm.ApplicationInfo getApplicationInfo();
- method @Nullable public String[] getGrantedPermissions();
- method @NonNull public String getPackageName();
- method @Nullable public String[] getRequestedPermissions();
- method @NonNull public android.graphics.drawable.Drawable loadIcon(@NonNull android.content.pm.PackageManager);
- method @NonNull public CharSequence loadLabel(@NonNull android.content.pm.PackageManager);
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.content.pm.InstantAppInfo> CREATOR;
- }
-
- public final class InstantAppIntentFilter implements android.os.Parcelable {
- ctor public InstantAppIntentFilter(@Nullable String, @NonNull java.util.List<android.content.IntentFilter>);
- method public int describeContents();
- method public java.util.List<android.content.IntentFilter> getFilters();
- method public String getSplitName();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.content.pm.InstantAppIntentFilter> CREATOR;
- }
-
- public final class InstantAppRequestInfo implements android.os.Parcelable {
- ctor public InstantAppRequestInfo(@NonNull android.content.Intent, @Nullable int[], @NonNull android.os.UserHandle, boolean, @NonNull String);
- method public int describeContents();
- method @Nullable public int[] getHostDigestPrefix();
- method @NonNull public android.content.Intent getIntent();
- method @NonNull public String getToken();
- method @NonNull public android.os.UserHandle getUserHandle();
- method public boolean isRequesterInstantApp();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.content.pm.InstantAppRequestInfo> CREATOR;
- }
-
- public final class InstantAppResolveInfo implements android.os.Parcelable {
- ctor public InstantAppResolveInfo(@NonNull android.content.pm.InstantAppResolveInfo.InstantAppDigest, @Nullable String, @Nullable java.util.List<android.content.pm.InstantAppIntentFilter>, int);
- ctor public InstantAppResolveInfo(@NonNull android.content.pm.InstantAppResolveInfo.InstantAppDigest, @Nullable String, @Nullable java.util.List<android.content.pm.InstantAppIntentFilter>, long, @Nullable android.os.Bundle);
- ctor public InstantAppResolveInfo(@NonNull String, @Nullable String, @Nullable java.util.List<android.content.pm.InstantAppIntentFilter>);
- ctor public InstantAppResolveInfo(@Nullable android.os.Bundle);
- method public int describeContents();
- method public byte[] getDigestBytes();
- method public int getDigestPrefix();
- method @Nullable public android.os.Bundle getExtras();
- method public java.util.List<android.content.pm.InstantAppIntentFilter> getIntentFilters();
- method public long getLongVersionCode();
- method public String getPackageName();
- method @Deprecated public int getVersionCode();
- method public boolean shouldLetInstallerDecide();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.content.pm.InstantAppResolveInfo> CREATOR;
- }
-
- public static final class InstantAppResolveInfo.InstantAppDigest implements android.os.Parcelable {
- ctor public InstantAppResolveInfo.InstantAppDigest(@NonNull String);
- method public int describeContents();
- method public byte[][] getDigestBytes();
- method public int[] getDigestPrefix();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.content.pm.InstantAppResolveInfo.InstantAppDigest> CREATOR;
- field public static final android.content.pm.InstantAppResolveInfo.InstantAppDigest UNDEFINED;
- }
-
- public final class IntentFilterVerificationInfo implements android.os.Parcelable {
- method public int describeContents();
- method public java.util.Set<java.lang.String> getDomains();
- method public String getPackageName();
- method public int getStatus();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.content.pm.IntentFilterVerificationInfo> CREATOR;
- }
-
- public class LauncherApps {
- method @Nullable public android.content.pm.LauncherApps.AppUsageLimit getAppUsageLimit(@NonNull String, @NonNull android.os.UserHandle);
- }
-
- public static final class LauncherApps.AppUsageLimit implements android.os.Parcelable {
- method public int describeContents();
- method public long getTotalUsageLimit();
- method public long getUsageRemaining();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.content.pm.LauncherApps.AppUsageLimit> CREATOR;
- }
-
- public class PackageInstaller {
- method @RequiresPermission(android.Manifest.permission.INSTALL_PACKAGES) public void setPermissionsResult(int, boolean);
- field public static final int DATA_LOADER_TYPE_INCREMENTAL = 2; // 0x2
- field public static final int DATA_LOADER_TYPE_NONE = 0; // 0x0
- field public static final int DATA_LOADER_TYPE_STREAMING = 1; // 0x1
- field public static final String EXTRA_DATA_LOADER_TYPE = "android.content.pm.extra.DATA_LOADER_TYPE";
- field public static final int LOCATION_DATA_APP = 0; // 0x0
- field public static final int LOCATION_MEDIA_DATA = 2; // 0x2
- field public static final int LOCATION_MEDIA_OBB = 1; // 0x1
- }
-
- public static class PackageInstaller.Session implements java.io.Closeable {
- method @RequiresPermission("com.android.permission.USE_INSTALLER_V2") public void addFile(int, @NonNull String, long, @NonNull byte[], @Nullable byte[]);
- method @RequiresPermission(android.Manifest.permission.INSTALL_PACKAGES) public void commitTransferred(@NonNull android.content.IntentSender);
- method @Nullable @RequiresPermission("com.android.permission.USE_INSTALLER_V2") public android.content.pm.DataLoaderParams getDataLoaderParams();
- method @RequiresPermission("com.android.permission.USE_INSTALLER_V2") public void removeFile(int, @NonNull String);
- }
-
- public static class PackageInstaller.SessionInfo implements android.os.Parcelable {
- method public boolean getAllocateAggressive();
- method @Deprecated public boolean getAllowDowngrade();
- method public int getAutoRevokePermissionsMode();
- method public boolean getDontKillApp();
- method public boolean getEnableRollback();
- method @Nullable public String[] getGrantedRuntimePermissions();
- method public boolean getInstallAsFullApp(boolean);
- method public boolean getInstallAsInstantApp(boolean);
- method public boolean getInstallAsVirtualPreload();
- method public boolean getRequestDowngrade();
- method public int getRollbackDataPolicy();
- method @NonNull public java.util.Set<java.lang.String> getWhitelistedRestrictedPermissions();
- }
-
- public static class PackageInstaller.SessionParams implements android.os.Parcelable {
- method @RequiresPermission(android.Manifest.permission.ALLOCATE_AGGRESSIVE) public void setAllocateAggressive(boolean);
- method @Deprecated public void setAllowDowngrade(boolean);
- method @RequiresPermission(allOf={android.Manifest.permission.INSTALL_PACKAGES, "com.android.permission.USE_INSTALLER_V2"}) public void setDataLoaderParams(@NonNull android.content.pm.DataLoaderParams);
- method public void setDontKillApp(boolean);
- method public void setEnableRollback(boolean);
- method public void setEnableRollback(boolean, int);
- method @RequiresPermission(android.Manifest.permission.INSTALL_GRANT_RUNTIME_PERMISSIONS) public void setGrantedRuntimePermissions(String[]);
- method @RequiresPermission(android.Manifest.permission.INSTALL_PACKAGES) public void setInstallAsApex();
- method public void setInstallAsInstantApp(boolean);
- method public void setInstallAsVirtualPreload();
- method public void setRequestDowngrade(boolean);
- method @RequiresPermission(android.Manifest.permission.INSTALL_PACKAGES) public void setStaged();
- }
-
- public class PackageItemInfo {
- method public static void forceSafeLabels();
- method @Deprecated @NonNull public CharSequence loadSafeLabel(@NonNull android.content.pm.PackageManager);
- method @NonNull public CharSequence loadSafeLabel(@NonNull android.content.pm.PackageManager, @FloatRange(from=0) float, int);
- }
-
- public abstract class PackageManager {
- method @RequiresPermission("android.permission.OBSERVE_GRANT_REVOKE_PERMISSIONS") public abstract void addOnPermissionsChangeListener(@NonNull android.content.pm.PackageManager.OnPermissionsChangedListener);
- method public abstract boolean arePermissionsIndividuallyControlled();
- method @NonNull public abstract java.util.List<android.content.IntentFilter> getAllIntentFilters(@NonNull String);
- method @NonNull @RequiresPermission(android.Manifest.permission.INTERACT_ACROSS_USERS) public android.content.pm.ApplicationInfo getApplicationInfoAsUser(@NonNull String, int, @NonNull android.os.UserHandle) throws android.content.pm.PackageManager.NameNotFoundException;
- method @NonNull public android.content.pm.dex.ArtManager getArtManager();
- method @NonNull @RequiresPermission(android.Manifest.permission.ACCESS_SHARED_LIBRARIES) public java.util.List<android.content.pm.SharedLibraryInfo> getDeclaredSharedLibraries(@NonNull String, int);
- method @Nullable @RequiresPermission(android.Manifest.permission.INTERACT_ACROSS_USERS_FULL) public abstract String getDefaultBrowserPackageNameAsUser(int);
- method @Nullable @RequiresPermission(android.Manifest.permission.SET_HARMFUL_APP_WARNINGS) public CharSequence getHarmfulAppWarning(@NonNull String);
- method @Nullable public String getIncidentReportApproverPackageName();
- method @NonNull @RequiresPermission(android.Manifest.permission.INTERACT_ACROSS_USERS_FULL) public abstract java.util.List<android.content.pm.PackageInfo> getInstalledPackagesAsUser(int, int);
- method @Nullable @RequiresPermission(android.Manifest.permission.ACCESS_INSTANT_APPS) public abstract android.graphics.drawable.Drawable getInstantAppIcon(String);
- method @Nullable public abstract android.content.ComponentName getInstantAppInstallerComponent();
- method @Nullable public abstract android.content.ComponentName getInstantAppResolverSettingsComponent();
- method @NonNull @RequiresPermission(android.Manifest.permission.ACCESS_INSTANT_APPS) public abstract java.util.List<android.content.pm.InstantAppInfo> getInstantApps();
- method @NonNull public abstract java.util.List<android.content.pm.IntentFilterVerificationInfo> getIntentFilterVerifications(@NonNull String);
- method @RequiresPermission(android.Manifest.permission.INTERACT_ACROSS_USERS_FULL) public abstract int getIntentVerificationStatusAsUser(@NonNull String, int);
- method @android.content.pm.PackageManager.PermissionFlags @RequiresPermission(anyOf={android.Manifest.permission.GRANT_RUNTIME_PERMISSIONS, android.Manifest.permission.REVOKE_RUNTIME_PERMISSIONS, android.Manifest.permission.GET_RUNTIME_PERMISSIONS}) public abstract int getPermissionFlags(@NonNull String, @NonNull String, @NonNull android.os.UserHandle);
- method @NonNull @RequiresPermission(android.Manifest.permission.SUSPEND_APPS) public String[] getUnsuspendablePackages(@NonNull String[]);
- method @RequiresPermission(android.Manifest.permission.GRANT_RUNTIME_PERMISSIONS) public abstract void grantRuntimePermission(@NonNull String, @NonNull String, @NonNull android.os.UserHandle);
- method @Deprecated public abstract int installExistingPackage(@NonNull String) throws android.content.pm.PackageManager.NameNotFoundException;
- method @Deprecated public abstract int installExistingPackage(@NonNull String, int) throws android.content.pm.PackageManager.NameNotFoundException;
- method @NonNull @RequiresPermission(android.Manifest.permission.INTERACT_ACROSS_USERS) public java.util.List<android.content.pm.ResolveInfo> queryBroadcastReceiversAsUser(@NonNull android.content.Intent, int, android.os.UserHandle);
- method @NonNull @RequiresPermission(android.Manifest.permission.INTERACT_ACROSS_USERS) public java.util.List<android.content.pm.ResolveInfo> queryIntentActivitiesAsUser(@NonNull android.content.Intent, int, @NonNull android.os.UserHandle);
- method @NonNull @RequiresPermission(android.Manifest.permission.INTERACT_ACROSS_USERS) public java.util.List<android.content.pm.ResolveInfo> queryIntentContentProvidersAsUser(@NonNull android.content.Intent, int, @NonNull android.os.UserHandle);
- method @NonNull @RequiresPermission(android.Manifest.permission.INTERACT_ACROSS_USERS) public java.util.List<android.content.pm.ResolveInfo> queryIntentServicesAsUser(@NonNull android.content.Intent, int, @NonNull android.os.UserHandle);
- method public abstract void registerDexModule(@NonNull String, @Nullable android.content.pm.PackageManager.DexModuleRegisterCallback);
- method @RequiresPermission("android.permission.OBSERVE_GRANT_REVOKE_PERMISSIONS") public abstract void removeOnPermissionsChangeListener(@NonNull android.content.pm.PackageManager.OnPermissionsChangedListener);
- method public void replacePreferredActivity(@NonNull android.content.IntentFilter, int, @NonNull java.util.List<android.content.ComponentName>, @NonNull android.content.ComponentName);
- method @RequiresPermission(android.Manifest.permission.REVOKE_RUNTIME_PERMISSIONS) public abstract void revokeRuntimePermission(@NonNull String, @NonNull String, @NonNull android.os.UserHandle);
- method @RequiresPermission(android.Manifest.permission.REVOKE_RUNTIME_PERMISSIONS) public void revokeRuntimePermission(@NonNull String, @NonNull String, @NonNull android.os.UserHandle, @NonNull String);
- method public void sendDeviceCustomizationReadyBroadcast();
- method @RequiresPermission(allOf={android.Manifest.permission.SET_PREFERRED_APPLICATIONS, android.Manifest.permission.INTERACT_ACROSS_USERS_FULL}) public abstract boolean setDefaultBrowserPackageNameAsUser(@Nullable String, int);
- method @NonNull @RequiresPermission(android.Manifest.permission.SUSPEND_APPS) public String[] setDistractingPackageRestrictions(@NonNull String[], int);
- method @RequiresPermission(android.Manifest.permission.SET_HARMFUL_APP_WARNINGS) public void setHarmfulAppWarning(@NonNull String, @Nullable CharSequence);
- method @Deprecated @Nullable @RequiresPermission(android.Manifest.permission.SUSPEND_APPS) public String[] setPackagesSuspended(@Nullable String[], boolean, @Nullable android.os.PersistableBundle, @Nullable android.os.PersistableBundle, @Nullable String);
- method @Nullable @RequiresPermission(android.Manifest.permission.SUSPEND_APPS) public String[] setPackagesSuspended(@Nullable String[], boolean, @Nullable android.os.PersistableBundle, @Nullable android.os.PersistableBundle, @Nullable android.content.pm.SuspendDialogInfo);
- method @RequiresPermission(value=android.Manifest.permission.CHANGE_COMPONENT_ENABLED_STATE, conditional=true) public void setSyntheticAppDetailsActivityEnabled(@NonNull String, boolean);
- method public void setSystemAppState(@NonNull String, int);
- method @RequiresPermission(android.Manifest.permission.INSTALL_PACKAGES) public abstract void setUpdateAvailable(@NonNull String, boolean);
- method @RequiresPermission(android.Manifest.permission.SET_PREFERRED_APPLICATIONS) public abstract boolean updateIntentVerificationStatusAsUser(@NonNull String, int, int);
- method @RequiresPermission(anyOf={android.Manifest.permission.GRANT_RUNTIME_PERMISSIONS, android.Manifest.permission.REVOKE_RUNTIME_PERMISSIONS}) public abstract void updatePermissionFlags(@NonNull String, @NonNull String, @android.content.pm.PackageManager.PermissionFlags int, @android.content.pm.PackageManager.PermissionFlags int, @NonNull android.os.UserHandle);
- method @RequiresPermission(android.Manifest.permission.INTENT_FILTER_VERIFICATION_AGENT) public abstract void verifyIntentFilter(int, int, @NonNull java.util.List<java.lang.String>);
- field public static final String ACTION_REQUEST_PERMISSIONS = "android.content.pm.action.REQUEST_PERMISSIONS";
- field public static final String EXTRA_REQUEST_PERMISSIONS_NAMES = "android.content.pm.extra.REQUEST_PERMISSIONS_NAMES";
- field public static final String EXTRA_REQUEST_PERMISSIONS_RESULTS = "android.content.pm.extra.REQUEST_PERMISSIONS_RESULTS";
- field public static final String FEATURE_BROADCAST_RADIO = "android.hardware.broadcastradio";
- field public static final String FEATURE_CONTEXT_HUB = "android.hardware.context_hub";
- field public static final String FEATURE_INCREMENTAL_DELIVERY = "android.software.incremental_delivery";
- field public static final String FEATURE_REBOOT_ESCROW = "android.hardware.reboot_escrow";
- field public static final String FEATURE_TELEPHONY_CARRIERLOCK = "android.hardware.telephony.carrierlock";
- field public static final int FLAGS_PERMISSION_RESERVED_PERMISSION_CONTROLLER = -268435456; // 0xf0000000
- field public static final int FLAG_PERMISSION_APPLY_RESTRICTION = 16384; // 0x4000
- field public static final int FLAG_PERMISSION_AUTO_REVOKED = 131072; // 0x20000
- field public static final int FLAG_PERMISSION_GRANTED_BY_DEFAULT = 32; // 0x20
- field public static final int FLAG_PERMISSION_GRANTED_BY_ROLE = 32768; // 0x8000
- field public static final int FLAG_PERMISSION_ONE_TIME = 65536; // 0x10000
- field public static final int FLAG_PERMISSION_POLICY_FIXED = 4; // 0x4
- field public static final int FLAG_PERMISSION_RESTRICTION_INSTALLER_EXEMPT = 2048; // 0x800
- field public static final int FLAG_PERMISSION_RESTRICTION_ROLE_EXEMPT = 262144; // 0x40000
- field public static final int FLAG_PERMISSION_RESTRICTION_SYSTEM_EXEMPT = 4096; // 0x1000
- field public static final int FLAG_PERMISSION_RESTRICTION_UPGRADE_EXEMPT = 8192; // 0x2000
- field public static final int FLAG_PERMISSION_REVIEW_REQUIRED = 64; // 0x40
- field public static final int FLAG_PERMISSION_REVOKED_COMPAT = 8; // 0x8
- field @Deprecated public static final int FLAG_PERMISSION_REVOKE_ON_UPGRADE = 8; // 0x8
- field public static final int FLAG_PERMISSION_SYSTEM_FIXED = 16; // 0x10
- field public static final int FLAG_PERMISSION_USER_FIXED = 2; // 0x2
- field public static final int FLAG_PERMISSION_USER_SENSITIVE_WHEN_DENIED = 512; // 0x200
- field public static final int FLAG_PERMISSION_USER_SENSITIVE_WHEN_GRANTED = 256; // 0x100
- field public static final int FLAG_PERMISSION_USER_SET = 1; // 0x1
- field public static final int INSTALL_FAILED_ALREADY_EXISTS = -1; // 0xffffffff
- field public static final int INSTALL_FAILED_CONFLICTING_PROVIDER = -13; // 0xfffffff3
- field public static final int INSTALL_FAILED_CONTAINER_ERROR = -18; // 0xffffffee
- field public static final int INSTALL_FAILED_CPU_ABI_INCOMPATIBLE = -16; // 0xfffffff0
- field public static final int INSTALL_FAILED_DEXOPT = -11; // 0xfffffff5
- field public static final int INSTALL_FAILED_DUPLICATE_PACKAGE = -5; // 0xfffffffb
- field public static final int INSTALL_FAILED_INSUFFICIENT_STORAGE = -4; // 0xfffffffc
- field public static final int INSTALL_FAILED_INTERNAL_ERROR = -110; // 0xffffff92
- field public static final int INSTALL_FAILED_INVALID_APK = -2; // 0xfffffffe
- field public static final int INSTALL_FAILED_INVALID_INSTALL_LOCATION = -19; // 0xffffffed
- field public static final int INSTALL_FAILED_INVALID_URI = -3; // 0xfffffffd
- field public static final int INSTALL_FAILED_MEDIA_UNAVAILABLE = -20; // 0xffffffec
- field public static final int INSTALL_FAILED_MISSING_FEATURE = -17; // 0xffffffef
- field public static final int INSTALL_FAILED_MISSING_SHARED_LIBRARY = -9; // 0xfffffff7
- field public static final int INSTALL_FAILED_NEWER_SDK = -14; // 0xfffffff2
- field public static final int INSTALL_FAILED_NO_SHARED_USER = -6; // 0xfffffffa
- field public static final int INSTALL_FAILED_OLDER_SDK = -12; // 0xfffffff4
- field public static final int INSTALL_FAILED_PACKAGE_CHANGED = -23; // 0xffffffe9
- field public static final int INSTALL_FAILED_PERMISSION_MODEL_DOWNGRADE = -26; // 0xffffffe6
- field public static final int INSTALL_FAILED_REPLACE_COULDNT_DELETE = -10; // 0xfffffff6
- field public static final int INSTALL_FAILED_SANDBOX_VERSION_DOWNGRADE = -27; // 0xffffffe5
- field public static final int INSTALL_FAILED_SHARED_USER_INCOMPATIBLE = -8; // 0xfffffff8
- field public static final int INSTALL_FAILED_TEST_ONLY = -15; // 0xfffffff1
- field public static final int INSTALL_FAILED_UPDATE_INCOMPATIBLE = -7; // 0xfffffff9
- field public static final int INSTALL_FAILED_VERIFICATION_FAILURE = -22; // 0xffffffea
- field public static final int INSTALL_FAILED_VERIFICATION_TIMEOUT = -21; // 0xffffffeb
- field public static final int INSTALL_PARSE_FAILED_BAD_MANIFEST = -101; // 0xffffff9b
- field public static final int INSTALL_PARSE_FAILED_BAD_PACKAGE_NAME = -106; // 0xffffff96
- field public static final int INSTALL_PARSE_FAILED_BAD_SHARED_USER_ID = -107; // 0xffffff95
- field public static final int INSTALL_PARSE_FAILED_CERTIFICATE_ENCODING = -105; // 0xffffff97
- field public static final int INSTALL_PARSE_FAILED_INCONSISTENT_CERTIFICATES = -104; // 0xffffff98
- field public static final int INSTALL_PARSE_FAILED_MANIFEST_EMPTY = -109; // 0xffffff93
- field public static final int INSTALL_PARSE_FAILED_MANIFEST_MALFORMED = -108; // 0xffffff94
- field public static final int INSTALL_PARSE_FAILED_NOT_APK = -100; // 0xffffff9c
- field public static final int INSTALL_PARSE_FAILED_NO_CERTIFICATES = -103; // 0xffffff99
- field public static final int INSTALL_PARSE_FAILED_UNEXPECTED_EXCEPTION = -102; // 0xffffff9a
- field public static final int INSTALL_SUCCEEDED = 1; // 0x1
- field public static final int INTENT_FILTER_DOMAIN_VERIFICATION_STATUS_ALWAYS = 2; // 0x2
- field public static final int INTENT_FILTER_DOMAIN_VERIFICATION_STATUS_ALWAYS_ASK = 4; // 0x4
- field public static final int INTENT_FILTER_DOMAIN_VERIFICATION_STATUS_ASK = 1; // 0x1
- field public static final int INTENT_FILTER_DOMAIN_VERIFICATION_STATUS_NEVER = 3; // 0x3
- field public static final int INTENT_FILTER_DOMAIN_VERIFICATION_STATUS_UNDEFINED = 0; // 0x0
- field public static final int INTENT_FILTER_VERIFICATION_FAILURE = -1; // 0xffffffff
- field public static final int INTENT_FILTER_VERIFICATION_SUCCESS = 1; // 0x1
- field @Deprecated public static final int MASK_PERMISSION_FLAGS = 255; // 0xff
- field public static final int MATCH_ANY_USER = 4194304; // 0x400000
- field public static final int MATCH_FACTORY_ONLY = 2097152; // 0x200000
- field public static final int MATCH_HIDDEN_UNTIL_INSTALLED_COMPONENTS = 536870912; // 0x20000000
- field public static final int MATCH_INSTANT = 8388608; // 0x800000
- field public static final int MODULE_APEX_NAME = 1; // 0x1
- field public static final int RESTRICTION_HIDE_FROM_SUGGESTIONS = 1; // 0x1
- field public static final int RESTRICTION_HIDE_NOTIFICATIONS = 2; // 0x2
- field public static final int RESTRICTION_NONE = 0; // 0x0
- field public static final int SYSTEM_APP_STATE_HIDDEN_UNTIL_INSTALLED_HIDDEN = 0; // 0x0
- field public static final int SYSTEM_APP_STATE_HIDDEN_UNTIL_INSTALLED_VISIBLE = 1; // 0x1
- field public static final int SYSTEM_APP_STATE_INSTALLED = 2; // 0x2
- field public static final int SYSTEM_APP_STATE_UNINSTALLED = 3; // 0x3
- }
-
- public abstract static class PackageManager.DexModuleRegisterCallback {
- ctor public PackageManager.DexModuleRegisterCallback();
- method public abstract void onDexModuleRegistered(String, boolean, String);
- }
-
- public static interface PackageManager.OnPermissionsChangedListener {
- method public void onPermissionsChanged(int);
- }
-
- @IntDef(prefix={"FLAG_PERMISSION_"}, value={android.content.pm.PackageManager.FLAG_PERMISSION_USER_SET, android.content.pm.PackageManager.FLAG_PERMISSION_USER_FIXED, android.content.pm.PackageManager.FLAG_PERMISSION_POLICY_FIXED, android.content.pm.PackageManager.FLAG_PERMISSION_REVOKE_ON_UPGRADE, android.content.pm.PackageManager.FLAG_PERMISSION_SYSTEM_FIXED, android.content.pm.PackageManager.FLAG_PERMISSION_GRANTED_BY_DEFAULT, android.content.pm.PackageManager.FLAG_PERMISSION_USER_SENSITIVE_WHEN_GRANTED, android.content.pm.PackageManager.FLAG_PERMISSION_USER_SENSITIVE_WHEN_DENIED, android.content.pm.PackageManager.FLAG_PERMISSION_RESTRICTION_UPGRADE_EXEMPT, android.content.pm.PackageManager.FLAG_PERMISSION_RESTRICTION_SYSTEM_EXEMPT, android.content.pm.PackageManager.FLAG_PERMISSION_RESTRICTION_INSTALLER_EXEMPT, android.content.pm.PackageManager.FLAG_PERMISSION_APPLY_RESTRICTION, android.content.pm.PackageManager.FLAG_PERMISSION_GRANTED_BY_ROLE, android.content.pm.PackageManager.FLAG_PERMISSION_REVOKED_COMPAT, android.content.pm.PackageManager.FLAG_PERMISSION_ONE_TIME, android.content.pm.PackageManager.FLAG_PERMISSION_AUTO_REVOKED}) @java.lang.annotation.Retention(java.lang.annotation.RetentionPolicy.SOURCE) public static @interface PackageManager.PermissionFlags {
- }
-
- public class PermissionGroupInfo extends android.content.pm.PackageItemInfo implements android.os.Parcelable {
- field @StringRes public final int backgroundRequestDetailResourceId;
- field @StringRes public final int backgroundRequestResourceId;
- field @StringRes public final int requestDetailResourceId;
- field @StringRes public int requestRes;
- }
-
- public class PermissionInfo extends android.content.pm.PackageItemInfo implements android.os.Parcelable {
- field public static final int FLAG_REMOVED = 2; // 0x2
- field public static final int PROTECTION_FLAG_APP_PREDICTOR = 2097152; // 0x200000
- field public static final int PROTECTION_FLAG_COMPANION = 8388608; // 0x800000
- field public static final int PROTECTION_FLAG_CONFIGURATOR = 524288; // 0x80000
- field public static final int PROTECTION_FLAG_DOCUMENTER = 262144; // 0x40000
- field public static final int PROTECTION_FLAG_INCIDENT_REPORT_APPROVER = 1048576; // 0x100000
- field public static final int PROTECTION_FLAG_OEM = 16384; // 0x4000
- field public static final int PROTECTION_FLAG_RETAIL_DEMO = 16777216; // 0x1000000
- field public static final int PROTECTION_FLAG_SYSTEM_TEXT_CLASSIFIER = 65536; // 0x10000
- field public static final int PROTECTION_FLAG_WELLBEING = 131072; // 0x20000
- field @Nullable public final String backgroundPermission;
- field @StringRes public int requestRes;
- }
-
- public class ResolveInfo implements android.os.Parcelable {
- field public boolean handleAllWebDataURI;
- }
-
- public final class ShortcutInfo implements android.os.Parcelable {
- method @Nullable public android.app.Person[] getPersons();
- }
-
- public class ShortcutManager {
- method @NonNull @RequiresPermission(android.Manifest.permission.MANAGE_APP_PREDICTIONS) public java.util.List<android.content.pm.ShortcutManager.ShareShortcutInfo> getShareTargets(@NonNull android.content.IntentFilter);
- method public boolean hasShareTargets(@NonNull String);
- }
-
- public static final class ShortcutManager.ShareShortcutInfo implements android.os.Parcelable {
- method public int describeContents();
- method @NonNull public android.content.pm.ShortcutInfo getShortcutInfo();
- method @NonNull public android.content.ComponentName getTargetComponent();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.content.pm.ShortcutManager.ShareShortcutInfo> CREATOR;
- }
-
- public final class SuspendDialogInfo implements android.os.Parcelable {
- method public int describeContents();
- method public void writeToParcel(android.os.Parcel, int);
- field public static final int BUTTON_ACTION_MORE_DETAILS = 0; // 0x0
- field public static final int BUTTON_ACTION_UNSUSPEND = 1; // 0x1
- field @NonNull public static final android.os.Parcelable.Creator<android.content.pm.SuspendDialogInfo> CREATOR;
- }
-
- public static final class SuspendDialogInfo.Builder {
- ctor public SuspendDialogInfo.Builder();
- method @NonNull public android.content.pm.SuspendDialogInfo build();
- method @NonNull public android.content.pm.SuspendDialogInfo.Builder setIcon(@DrawableRes int);
- method @NonNull public android.content.pm.SuspendDialogInfo.Builder setMessage(@NonNull String);
- method @NonNull public android.content.pm.SuspendDialogInfo.Builder setMessage(@StringRes int);
- method @NonNull public android.content.pm.SuspendDialogInfo.Builder setNeutralButtonAction(int);
- method @NonNull public android.content.pm.SuspendDialogInfo.Builder setNeutralButtonText(@StringRes int);
- method @NonNull public android.content.pm.SuspendDialogInfo.Builder setTitle(@StringRes int);
- }
-
-}
-
-package android.content.pm.dex {
-
- public class ArtManager {
- method @RequiresPermission(allOf={android.Manifest.permission.READ_RUNTIME_PROFILES, android.Manifest.permission.PACKAGE_USAGE_STATS}) public boolean isRuntimeProfilingEnabled(int);
- method @RequiresPermission(allOf={android.Manifest.permission.READ_RUNTIME_PROFILES, android.Manifest.permission.PACKAGE_USAGE_STATS}) public void snapshotRuntimeProfile(int, @Nullable String, @Nullable String, @NonNull java.util.concurrent.Executor, @NonNull android.content.pm.dex.ArtManager.SnapshotRuntimeProfileCallback);
- field public static final int PROFILE_APPS = 0; // 0x0
- field public static final int PROFILE_BOOT_IMAGE = 1; // 0x1
- field public static final int SNAPSHOT_FAILED_CODE_PATH_NOT_FOUND = 1; // 0x1
- field public static final int SNAPSHOT_FAILED_INTERNAL_ERROR = 2; // 0x2
- field public static final int SNAPSHOT_FAILED_PACKAGE_NOT_FOUND = 0; // 0x0
- }
-
- public abstract static class ArtManager.SnapshotRuntimeProfileCallback {
- ctor public ArtManager.SnapshotRuntimeProfileCallback();
- method public abstract void onError(int);
- method public abstract void onSuccess(android.os.ParcelFileDescriptor);
- }
-
-}
-
-package android.content.pm.permission {
-
- @Deprecated public final class RuntimePermissionPresentationInfo implements android.os.Parcelable {
- ctor @Deprecated public RuntimePermissionPresentationInfo(CharSequence, boolean, boolean);
- method @Deprecated public int describeContents();
- method @Deprecated @NonNull public CharSequence getLabel();
- method @Deprecated public boolean isGranted();
- method @Deprecated public boolean isStandard();
- method @Deprecated public void writeToParcel(android.os.Parcel, int);
- field @Deprecated @NonNull public static final android.os.Parcelable.Creator<android.content.pm.permission.RuntimePermissionPresentationInfo> CREATOR;
- }
-
-}
-
-package android.content.rollback {
-
- public final class PackageRollbackInfo implements android.os.Parcelable {
- method public int describeContents();
- method @NonNull public String getPackageName();
- method @NonNull public android.content.pm.VersionedPackage getVersionRolledBackFrom();
- method @NonNull public android.content.pm.VersionedPackage getVersionRolledBackTo();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.content.rollback.PackageRollbackInfo> CREATOR;
- }
-
- public final class RollbackInfo implements android.os.Parcelable {
- method public int describeContents();
- method @NonNull public java.util.List<android.content.pm.VersionedPackage> getCausePackages();
- method public int getCommittedSessionId();
- method @NonNull public java.util.List<android.content.rollback.PackageRollbackInfo> getPackages();
- method public int getRollbackId();
- method public boolean isStaged();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.content.rollback.RollbackInfo> CREATOR;
- }
-
- public final class RollbackManager {
- method @RequiresPermission(anyOf={android.Manifest.permission.MANAGE_ROLLBACKS, "android.permission.TEST_MANAGE_ROLLBACKS"}) public void commitRollback(int, @NonNull java.util.List<android.content.pm.VersionedPackage>, @NonNull android.content.IntentSender);
- method @NonNull @RequiresPermission(anyOf={android.Manifest.permission.MANAGE_ROLLBACKS, "android.permission.TEST_MANAGE_ROLLBACKS"}) public java.util.List<android.content.rollback.RollbackInfo> getAvailableRollbacks();
- method @NonNull @RequiresPermission(anyOf={android.Manifest.permission.MANAGE_ROLLBACKS, "android.permission.TEST_MANAGE_ROLLBACKS"}) public java.util.List<android.content.rollback.RollbackInfo> getRecentlyCommittedRollbacks();
- field public static final String EXTRA_STATUS = "android.content.rollback.extra.STATUS";
- field public static final String EXTRA_STATUS_MESSAGE = "android.content.rollback.extra.STATUS_MESSAGE";
- field public static final int STATUS_FAILURE = 1; // 0x1
- field public static final int STATUS_FAILURE_INSTALL = 3; // 0x3
- field public static final int STATUS_FAILURE_ROLLBACK_UNAVAILABLE = 2; // 0x2
- field public static final int STATUS_SUCCESS = 0; // 0x0
- }
-
-}
-
-package android.debug {
-
- public class AdbManager {
- method @RequiresPermission(android.Manifest.permission.MANAGE_DEBUGGING) public boolean isAdbWifiQrSupported();
- method @RequiresPermission(android.Manifest.permission.MANAGE_DEBUGGING) public boolean isAdbWifiSupported();
- }
-
-}
-
-package android.hardware {
-
- public final class Sensor {
- method public java.util.UUID getUuid();
- method public boolean isDataInjectionSupported();
- field public static final String STRING_TYPE_DYNAMIC_SENSOR_META = "android.sensor.dynamic_sensor_meta";
- field public static final String STRING_TYPE_WRIST_TILT_GESTURE = "android.sensor.wrist_tilt_gesture";
- field public static final int TYPE_DYNAMIC_SENSOR_META = 32; // 0x20
- field public static final int TYPE_WRIST_TILT_GESTURE = 26; // 0x1a
- }
-
- public abstract class SensorManager {
- method public boolean initDataInjection(boolean);
- method public boolean injectSensorData(android.hardware.Sensor, float[], int, long);
- }
-
-}
-
-package android.hardware.biometrics {
-
- public static interface BiometricManager.Authenticators {
- field @RequiresPermission(android.Manifest.permission.WRITE_DEVICE_CONFIG) public static final int BIOMETRIC_CONVENIENCE = 4095; // 0xfff
- field @RequiresPermission(android.Manifest.permission.WRITE_DEVICE_CONFIG) public static final int EMPTY_SET = 0; // 0x0
- }
-
-}
-
-package android.hardware.camera2 {
-
- public abstract class CameraDevice implements java.lang.AutoCloseable {
- method @Deprecated public abstract void createCustomCaptureSession(android.hardware.camera2.params.InputConfiguration, @NonNull java.util.List<android.hardware.camera2.params.OutputConfiguration>, int, @NonNull android.hardware.camera2.CameraCaptureSession.StateCallback, @Nullable android.os.Handler) throws android.hardware.camera2.CameraAccessException;
- field public static final int SESSION_OPERATION_MODE_CONSTRAINED_HIGH_SPEED = 1; // 0x1
- field public static final int SESSION_OPERATION_MODE_NORMAL = 0; // 0x0
- field public static final int SESSION_OPERATION_MODE_VENDOR_START = 32768; // 0x8000
- }
-
-}
-
-package android.hardware.camera2.params {
-
- public final class OutputConfiguration implements android.os.Parcelable {
- ctor public OutputConfiguration(@NonNull android.view.Surface, int);
- ctor public OutputConfiguration(int, @NonNull android.view.Surface, int);
- method public int getRotation();
- field public static final int ROTATION_0 = 0; // 0x0
- field public static final int ROTATION_180 = 2; // 0x2
- field public static final int ROTATION_270 = 3; // 0x3
- field public static final int ROTATION_90 = 1; // 0x1
- }
-
-}
-
-package android.hardware.display {
-
- public final class AmbientBrightnessDayStats implements android.os.Parcelable {
- method public int describeContents();
- method public float[] getBucketBoundaries();
- method public java.time.LocalDate getLocalDate();
- method public float[] getStats();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.hardware.display.AmbientBrightnessDayStats> CREATOR;
- }
-
- public final class BrightnessChangeEvent implements android.os.Parcelable {
- method public int describeContents();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.hardware.display.BrightnessChangeEvent> CREATOR;
- field public final float batteryLevel;
- field public final float brightness;
- field public final long colorSampleDuration;
- field public final int colorTemperature;
- field @Nullable public final long[] colorValueBuckets;
- field public final boolean isDefaultBrightnessConfig;
- field public final boolean isUserSetBrightness;
- field public final float lastBrightness;
- field public final long[] luxTimestamps;
- field public final float[] luxValues;
- field public final boolean nightMode;
- field public final String packageName;
- field public final float powerBrightnessFactor;
- field public final long timeStamp;
- }
-
- public final class BrightnessConfiguration implements android.os.Parcelable {
- method public int describeContents();
- method @Nullable public android.hardware.display.BrightnessCorrection getCorrectionByCategory(int);
- method @Nullable public android.hardware.display.BrightnessCorrection getCorrectionByPackageName(@NonNull String);
- method public android.util.Pair<float[],float[]> getCurve();
- method public float getShortTermModelLowerLuxMultiplier();
- method public long getShortTermModelTimeoutMillis();
- method public float getShortTermModelUpperLuxMultiplier();
- method public boolean shouldCollectColorSamples();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.hardware.display.BrightnessConfiguration> CREATOR;
- field public static final long SHORT_TERM_TIMEOUT_UNSET = -1L; // 0xffffffffffffffffL
- }
-
- public static class BrightnessConfiguration.Builder {
- ctor public BrightnessConfiguration.Builder(float[], float[]);
- method @NonNull public android.hardware.display.BrightnessConfiguration.Builder addCorrectionByCategory(int, @NonNull android.hardware.display.BrightnessCorrection);
- method @NonNull public android.hardware.display.BrightnessConfiguration.Builder addCorrectionByPackageName(@NonNull String, @NonNull android.hardware.display.BrightnessCorrection);
- method @NonNull public android.hardware.display.BrightnessConfiguration build();
- method public int getMaxCorrectionsByCategory();
- method public int getMaxCorrectionsByPackageName();
- method @NonNull public android.hardware.display.BrightnessConfiguration.Builder setDescription(@Nullable String);
- method @NonNull public android.hardware.display.BrightnessConfiguration.Builder setShortTermModelLowerLuxMultiplier(@FloatRange(from=0.0f) float);
- method @NonNull public android.hardware.display.BrightnessConfiguration.Builder setShortTermModelTimeoutMillis(long);
- method @NonNull public android.hardware.display.BrightnessConfiguration.Builder setShortTermModelUpperLuxMultiplier(@FloatRange(from=0.0f) float);
- method @NonNull public android.hardware.display.BrightnessConfiguration.Builder setShouldCollectColorSamples(boolean);
- }
-
- public final class BrightnessCorrection implements android.os.Parcelable {
- method @FloatRange(from=0.0) public float apply(@FloatRange(from=0.0) float);
- method @NonNull public static android.hardware.display.BrightnessCorrection createScaleAndTranslateLog(float, float);
- method public int describeContents();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.hardware.display.BrightnessCorrection> CREATOR;
- }
-
- public final class ColorDisplayManager {
- method @RequiresPermission(android.Manifest.permission.CONTROL_DISPLAY_COLOR_TRANSFORMS) public int getNightDisplayAutoMode();
- method @RequiresPermission(android.Manifest.permission.CONTROL_DISPLAY_COLOR_TRANSFORMS) public int getTransformCapabilities();
- method @RequiresPermission(android.Manifest.permission.CONTROL_DISPLAY_COLOR_TRANSFORMS) public boolean setAppSaturationLevel(@NonNull String, @IntRange(from=0, to=100) int);
- method @RequiresPermission(android.Manifest.permission.CONTROL_DISPLAY_COLOR_TRANSFORMS) public boolean setNightDisplayAutoMode(int);
- method @RequiresPermission(android.Manifest.permission.CONTROL_DISPLAY_COLOR_TRANSFORMS) public boolean setNightDisplayCustomEndTime(@NonNull java.time.LocalTime);
- method @RequiresPermission(android.Manifest.permission.CONTROL_DISPLAY_COLOR_TRANSFORMS) public boolean setNightDisplayCustomStartTime(@NonNull java.time.LocalTime);
- method @RequiresPermission(android.Manifest.permission.CONTROL_DISPLAY_COLOR_TRANSFORMS) public boolean setSaturationLevel(@IntRange(from=0, to=100) int);
- field public static final int AUTO_MODE_CUSTOM_TIME = 1; // 0x1
- field public static final int AUTO_MODE_DISABLED = 0; // 0x0
- field public static final int AUTO_MODE_TWILIGHT = 2; // 0x2
- field public static final int CAPABILITY_HARDWARE_ACCELERATION_GLOBAL = 2; // 0x2
- field public static final int CAPABILITY_HARDWARE_ACCELERATION_PER_APP = 4; // 0x4
- field public static final int CAPABILITY_NONE = 0; // 0x0
- field public static final int CAPABILITY_PROTECTED_CONTENT = 1; // 0x1
- }
-
- public final class DisplayManager {
- method @RequiresPermission(android.Manifest.permission.ACCESS_AMBIENT_LIGHT_STATS) public java.util.List<android.hardware.display.AmbientBrightnessDayStats> getAmbientBrightnessStats();
- method @RequiresPermission(android.Manifest.permission.CONFIGURE_DISPLAY_BRIGHTNESS) public android.hardware.display.BrightnessConfiguration getBrightnessConfiguration();
- method @RequiresPermission(android.Manifest.permission.BRIGHTNESS_SLIDER_USAGE) public java.util.List<android.hardware.display.BrightnessChangeEvent> getBrightnessEvents();
- method @Nullable @RequiresPermission(android.Manifest.permission.CONFIGURE_DISPLAY_BRIGHTNESS) public android.hardware.display.BrightnessConfiguration getDefaultBrightnessConfiguration();
- method public android.util.Pair<float[],float[]> getMinimumBrightnessCurve();
- method public android.graphics.Point getStableDisplaySize();
- method @RequiresPermission(android.Manifest.permission.CONFIGURE_DISPLAY_BRIGHTNESS) public void setBrightnessConfiguration(android.hardware.display.BrightnessConfiguration);
- method @Deprecated @RequiresPermission(android.Manifest.permission.CONTROL_DISPLAY_SATURATION) public void setSaturationLevel(float);
- }
-
-}
-
-package android.hardware.hdmi {
-
- public abstract class HdmiClient {
- method public android.hardware.hdmi.HdmiDeviceInfo getActiveSource();
- method public void sendKeyEvent(int, boolean);
- method public void sendVendorCommand(int, byte[], boolean);
- method public void setVendorCommandListener(@NonNull android.hardware.hdmi.HdmiControlManager.VendorCommandListener);
- }
-
- public final class HdmiControlManager {
- method @RequiresPermission(android.Manifest.permission.HDMI_CEC) public void addHotplugEventListener(android.hardware.hdmi.HdmiControlManager.HotplugEventListener);
- method @RequiresPermission(android.Manifest.permission.HDMI_CEC) public void addHotplugEventListener(@NonNull java.util.concurrent.Executor, @NonNull android.hardware.hdmi.HdmiControlManager.HotplugEventListener);
- method @Nullable public android.hardware.hdmi.HdmiClient getClient(int);
- method @NonNull public java.util.List<android.hardware.hdmi.HdmiDeviceInfo> getConnectedDevices();
- method public int getPhysicalAddress();
- method @Nullable public android.hardware.hdmi.HdmiPlaybackClient getPlaybackClient();
- method @Nullable public android.hardware.hdmi.HdmiSwitchClient getSwitchClient();
- method @Nullable public android.hardware.hdmi.HdmiTvClient getTvClient();
- method public boolean isDeviceConnected(@NonNull android.hardware.hdmi.HdmiDeviceInfo);
- method public void powerOffDevice(@NonNull android.hardware.hdmi.HdmiDeviceInfo);
- method @RequiresPermission(android.Manifest.permission.HDMI_CEC) public void removeHotplugEventListener(android.hardware.hdmi.HdmiControlManager.HotplugEventListener);
- method public void setActiveSource(@NonNull android.hardware.hdmi.HdmiDeviceInfo);
- method @RequiresPermission(android.Manifest.permission.HDMI_CEC) public void setStandbyMode(boolean);
- field public static final String ACTION_OSD_MESSAGE = "android.hardware.hdmi.action.OSD_MESSAGE";
- field public static final int AVR_VOLUME_MUTED = 101; // 0x65
- field public static final int CLEAR_TIMER_STATUS_CEC_DISABLE = 162; // 0xa2
- field public static final int CLEAR_TIMER_STATUS_CHECK_RECORDER_CONNECTION = 160; // 0xa0
- field public static final int CLEAR_TIMER_STATUS_FAIL_TO_CLEAR_SELECTED_SOURCE = 161; // 0xa1
- field public static final int CLEAR_TIMER_STATUS_TIMER_CLEARED = 128; // 0x80
- field public static final int CLEAR_TIMER_STATUS_TIMER_NOT_CLEARED_NO_INFO_AVAILABLE = 2; // 0x2
- field public static final int CLEAR_TIMER_STATUS_TIMER_NOT_CLEARED_NO_MATCHING = 1; // 0x1
- field public static final int CLEAR_TIMER_STATUS_TIMER_NOT_CLEARED_RECORDING = 0; // 0x0
- field public static final int CONTROL_STATE_CHANGED_REASON_SETTING = 1; // 0x1
- field public static final int CONTROL_STATE_CHANGED_REASON_STANDBY = 3; // 0x3
- field public static final int CONTROL_STATE_CHANGED_REASON_START = 0; // 0x0
- field public static final int CONTROL_STATE_CHANGED_REASON_WAKEUP = 2; // 0x2
- field public static final int DEVICE_EVENT_ADD_DEVICE = 1; // 0x1
- field public static final int DEVICE_EVENT_REMOVE_DEVICE = 2; // 0x2
- field public static final int DEVICE_EVENT_UPDATE_DEVICE = 3; // 0x3
- field public static final String EXTRA_MESSAGE_EXTRA_PARAM1 = "android.hardware.hdmi.extra.MESSAGE_EXTRA_PARAM1";
- field public static final String EXTRA_MESSAGE_ID = "android.hardware.hdmi.extra.MESSAGE_ID";
- field public static final int ONE_TOUCH_RECORD_ALREADY_RECORDING = 18; // 0x12
- field public static final int ONE_TOUCH_RECORD_CEC_DISABLED = 51; // 0x33
- field public static final int ONE_TOUCH_RECORD_CHECK_RECORDER_CONNECTION = 49; // 0x31
- field public static final int ONE_TOUCH_RECORD_DISALLOW_TO_COPY = 13; // 0xd
- field public static final int ONE_TOUCH_RECORD_DISALLOW_TO_FUTHER_COPIES = 14; // 0xe
- field public static final int ONE_TOUCH_RECORD_FAIL_TO_RECORD_DISPLAYED_SCREEN = 50; // 0x32
- field public static final int ONE_TOUCH_RECORD_INVALID_EXTERNAL_PHYSICAL_ADDRESS = 10; // 0xa
- field public static final int ONE_TOUCH_RECORD_INVALID_EXTERNAL_PLUG_NUMBER = 9; // 0x9
- field public static final int ONE_TOUCH_RECORD_MEDIA_PROBLEM = 21; // 0x15
- field public static final int ONE_TOUCH_RECORD_MEDIA_PROTECTED = 19; // 0x13
- field public static final int ONE_TOUCH_RECORD_NOT_ENOUGH_SPACE = 22; // 0x16
- field public static final int ONE_TOUCH_RECORD_NO_MEDIA = 16; // 0x10
- field public static final int ONE_TOUCH_RECORD_NO_OR_INSUFFICIENT_CA_ENTITLEMENTS = 12; // 0xc
- field public static final int ONE_TOUCH_RECORD_NO_SOURCE_SIGNAL = 20; // 0x14
- field public static final int ONE_TOUCH_RECORD_OTHER_REASON = 31; // 0x1f
- field public static final int ONE_TOUCH_RECORD_PARENT_LOCK_ON = 23; // 0x17
- field public static final int ONE_TOUCH_RECORD_PLAYING = 17; // 0x11
- field public static final int ONE_TOUCH_RECORD_PREVIOUS_RECORDING_IN_PROGRESS = 48; // 0x30
- field public static final int ONE_TOUCH_RECORD_RECORDING_ALREADY_TERMINATED = 27; // 0x1b
- field public static final int ONE_TOUCH_RECORD_RECORDING_ANALOGUE_SERVICE = 3; // 0x3
- field public static final int ONE_TOUCH_RECORD_RECORDING_CURRENTLY_SELECTED_SOURCE = 1; // 0x1
- field public static final int ONE_TOUCH_RECORD_RECORDING_DIGITAL_SERVICE = 2; // 0x2
- field public static final int ONE_TOUCH_RECORD_RECORDING_EXTERNAL_INPUT = 4; // 0x4
- field public static final int ONE_TOUCH_RECORD_RECORDING_TERMINATED_NORMALLY = 26; // 0x1a
- field public static final int ONE_TOUCH_RECORD_UNABLE_ANALOGUE_SERVICE = 6; // 0x6
- field public static final int ONE_TOUCH_RECORD_UNABLE_DIGITAL_SERVICE = 5; // 0x5
- field public static final int ONE_TOUCH_RECORD_UNABLE_SELECTED_SERVICE = 7; // 0x7
- field public static final int ONE_TOUCH_RECORD_UNSUPPORTED_CA = 11; // 0xb
- field public static final int OSD_MESSAGE_ARC_CONNECTED_INVALID_PORT = 1; // 0x1
- field public static final int OSD_MESSAGE_AVR_VOLUME_CHANGED = 2; // 0x2
- field public static final int POWER_STATUS_ON = 0; // 0x0
- field public static final int POWER_STATUS_STANDBY = 1; // 0x1
- field public static final int POWER_STATUS_TRANSIENT_TO_ON = 2; // 0x2
- field public static final int POWER_STATUS_TRANSIENT_TO_STANDBY = 3; // 0x3
- field public static final int POWER_STATUS_UNKNOWN = -1; // 0xffffffff
- field @Deprecated public static final int RESULT_ALREADY_IN_PROGRESS = 4; // 0x4
- field public static final int RESULT_COMMUNICATION_FAILED = 7; // 0x7
- field public static final int RESULT_EXCEPTION = 5; // 0x5
- field public static final int RESULT_INCORRECT_MODE = 6; // 0x6
- field public static final int RESULT_SOURCE_NOT_AVAILABLE = 2; // 0x2
- field public static final int RESULT_SUCCESS = 0; // 0x0
- field public static final int RESULT_TARGET_NOT_AVAILABLE = 3; // 0x3
- field public static final int RESULT_TIMEOUT = 1; // 0x1
- field public static final int TIMER_RECORDING_RESULT_EXTRA_CEC_DISABLED = 3; // 0x3
- field public static final int TIMER_RECORDING_RESULT_EXTRA_CHECK_RECORDER_CONNECTION = 1; // 0x1
- field public static final int TIMER_RECORDING_RESULT_EXTRA_FAIL_TO_RECORD_SELECTED_SOURCE = 2; // 0x2
- field public static final int TIMER_RECORDING_RESULT_EXTRA_NO_ERROR = 0; // 0x0
- field public static final int TIMER_RECORDING_TYPE_ANALOGUE = 2; // 0x2
- field public static final int TIMER_RECORDING_TYPE_DIGITAL = 1; // 0x1
- field public static final int TIMER_RECORDING_TYPE_EXTERNAL = 3; // 0x3
- field public static final int TIMER_STATUS_MEDIA_INFO_NOT_PRESENT = 2; // 0x2
- field public static final int TIMER_STATUS_MEDIA_INFO_PRESENT_NOT_PROTECTED = 0; // 0x0
- field public static final int TIMER_STATUS_MEDIA_INFO_PRESENT_PROTECTED = 1; // 0x1
- field public static final int TIMER_STATUS_NOT_PROGRAMMED_CA_NOT_SUPPORTED = 6; // 0x6
- field public static final int TIMER_STATUS_NOT_PROGRAMMED_CLOCK_FAILURE = 10; // 0xa
- field public static final int TIMER_STATUS_NOT_PROGRAMMED_DATE_OUT_OF_RANGE = 2; // 0x2
- field public static final int TIMER_STATUS_NOT_PROGRAMMED_DUPLICATED = 14; // 0xe
- field public static final int TIMER_STATUS_NOT_PROGRAMMED_INVALID_EXTERNAL_PHYSICAL_NUMBER = 5; // 0x5
- field public static final int TIMER_STATUS_NOT_PROGRAMMED_INVALID_EXTERNAL_PLUG_NUMBER = 4; // 0x4
- field public static final int TIMER_STATUS_NOT_PROGRAMMED_INVALID_SEQUENCE = 3; // 0x3
- field public static final int TIMER_STATUS_NOT_PROGRAMMED_NO_CA_ENTITLEMENTS = 7; // 0x7
- field public static final int TIMER_STATUS_NOT_PROGRAMMED_NO_FREE_TIME = 1; // 0x1
- field public static final int TIMER_STATUS_NOT_PROGRAMMED_PARENTAL_LOCK_ON = 9; // 0x9
- field public static final int TIMER_STATUS_NOT_PROGRAMMED_UNSUPPORTED_RESOLUTION = 8; // 0x8
- field public static final int TIMER_STATUS_PROGRAMMED_INFO_ENOUGH_SPACE = 8; // 0x8
- field public static final int TIMER_STATUS_PROGRAMMED_INFO_MIGHT_NOT_ENOUGH_SPACE = 11; // 0xb
- field public static final int TIMER_STATUS_PROGRAMMED_INFO_NOT_ENOUGH_SPACE = 9; // 0x9
- field public static final int TIMER_STATUS_PROGRAMMED_INFO_NO_MEDIA_INFO = 10; // 0xa
- }
-
- @IntDef({android.hardware.hdmi.HdmiControlManager.RESULT_SUCCESS, android.hardware.hdmi.HdmiControlManager.RESULT_TIMEOUT, android.hardware.hdmi.HdmiControlManager.RESULT_SOURCE_NOT_AVAILABLE, android.hardware.hdmi.HdmiControlManager.RESULT_TARGET_NOT_AVAILABLE, android.hardware.hdmi.HdmiControlManager.RESULT_ALREADY_IN_PROGRESS, android.hardware.hdmi.HdmiControlManager.RESULT_EXCEPTION, android.hardware.hdmi.HdmiControlManager.RESULT_INCORRECT_MODE, android.hardware.hdmi.HdmiControlManager.RESULT_COMMUNICATION_FAILED}) @java.lang.annotation.Retention(java.lang.annotation.RetentionPolicy.CLASS) public static @interface HdmiControlManager.ControlCallbackResult {
- }
-
- public static interface HdmiControlManager.HotplugEventListener {
- method public void onReceived(android.hardware.hdmi.HdmiHotplugEvent);
- }
-
- public static interface HdmiControlManager.VendorCommandListener {
- method public void onControlStateChanged(boolean, int);
- method public void onReceived(int, int, byte[], boolean);
- }
-
- public class HdmiDeviceInfo implements android.os.Parcelable {
- ctor public HdmiDeviceInfo();
- method public int describeContents();
- method public int getAdopterId();
- method public int getDeviceId();
- method public int getDevicePowerStatus();
- method public int getDeviceType();
- method public String getDisplayName();
- method public int getId();
- method public int getLogicalAddress();
- method public int getPhysicalAddress();
- method public int getPortId();
- method public int getVendorId();
- method public static int idForCecDevice(int);
- method public static int idForHardware(int);
- method public static int idForMhlDevice(int);
- method public boolean isCecDevice();
- method public boolean isInactivated();
- method public boolean isMhlDevice();
- method public boolean isSourceType();
- method public void writeToParcel(android.os.Parcel, int);
- field public static final int ADDR_INTERNAL = 0; // 0x0
- field @NonNull public static final android.os.Parcelable.Creator<android.hardware.hdmi.HdmiDeviceInfo> CREATOR;
- field public static final int DEVICE_AUDIO_SYSTEM = 5; // 0x5
- field public static final int DEVICE_INACTIVE = -1; // 0xffffffff
- field public static final int DEVICE_PLAYBACK = 4; // 0x4
- field public static final int DEVICE_RECORDER = 1; // 0x1
- field public static final int DEVICE_RESERVED = 2; // 0x2
- field public static final int DEVICE_TUNER = 3; // 0x3
- field public static final int DEVICE_TV = 0; // 0x0
- field public static final int ID_INVALID = 65535; // 0xffff
- field public static final android.hardware.hdmi.HdmiDeviceInfo INACTIVE_DEVICE;
- field public static final int PATH_INTERNAL = 0; // 0x0
- field public static final int PATH_INVALID = 65535; // 0xffff
- field public static final int PORT_INVALID = -1; // 0xffffffff
- }
-
- public final class HdmiHotplugEvent implements android.os.Parcelable {
- method public int describeContents();
- method public int getPort();
- method public boolean isConnected();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.hardware.hdmi.HdmiHotplugEvent> CREATOR;
- }
-
- public final class HdmiPlaybackClient extends android.hardware.hdmi.HdmiClient {
- method public int getDeviceType();
- method public void oneTouchPlay(android.hardware.hdmi.HdmiPlaybackClient.OneTouchPlayCallback);
- method public void queryDisplayStatus(android.hardware.hdmi.HdmiPlaybackClient.DisplayStatusCallback);
- method public void sendStandby();
- }
-
- public static interface HdmiPlaybackClient.DisplayStatusCallback {
- method public void onComplete(int);
- }
-
- public static interface HdmiPlaybackClient.OneTouchPlayCallback {
- method public void onComplete(int);
- }
-
- public final class HdmiPortInfo implements android.os.Parcelable {
- ctor public HdmiPortInfo(int, int, int, boolean, boolean, boolean);
- method public int describeContents();
- method public int getAddress();
- method public int getId();
- method public int getType();
- method public boolean isArcSupported();
- method public boolean isCecSupported();
- method public boolean isMhlSupported();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.hardware.hdmi.HdmiPortInfo> CREATOR;
- field public static final int PORT_INPUT = 0; // 0x0
- field public static final int PORT_OUTPUT = 1; // 0x1
- }
-
- public abstract class HdmiRecordListener {
- ctor public HdmiRecordListener();
- method public void onClearTimerRecordingResult(int, int);
- method public void onOneTouchRecordResult(int, int);
- method public abstract android.hardware.hdmi.HdmiRecordSources.RecordSource onOneTouchRecordSourceRequested(int);
- method public void onTimerRecordingResult(int, android.hardware.hdmi.HdmiRecordListener.TimerStatusData);
- }
-
- public static class HdmiRecordListener.TimerStatusData {
- method public int getDurationHour();
- method public int getDurationMinute();
- method public int getExtraError();
- method public int getMediaInfo();
- method public int getNotProgammedError();
- method public int getProgrammedInfo();
- method public boolean isOverlapped();
- method public boolean isProgrammed();
- }
-
- public final class HdmiRecordSources {
- method public static boolean checkRecordSource(byte[]);
- method public static android.hardware.hdmi.HdmiRecordSources.OwnSource ofOwnSource();
- }
-
- public static final class HdmiRecordSources.AnalogueServiceSource extends android.hardware.hdmi.HdmiRecordSources.RecordSource {
- }
-
- public static final class HdmiRecordSources.DigitalServiceSource extends android.hardware.hdmi.HdmiRecordSources.RecordSource {
- }
-
- public static final class HdmiRecordSources.ExternalPhysicalAddress extends android.hardware.hdmi.HdmiRecordSources.RecordSource {
- }
-
- public static final class HdmiRecordSources.ExternalPlugData extends android.hardware.hdmi.HdmiRecordSources.RecordSource {
- }
-
- public static final class HdmiRecordSources.OwnSource extends android.hardware.hdmi.HdmiRecordSources.RecordSource {
- }
-
- public abstract static class HdmiRecordSources.RecordSource {
- }
-
- public class HdmiSwitchClient extends android.hardware.hdmi.HdmiClient {
- method public int getDeviceType();
- method @NonNull public java.util.List<android.hardware.hdmi.HdmiPortInfo> getPortInfo();
- method public void selectPort(int, @NonNull android.hardware.hdmi.HdmiSwitchClient.OnSelectListener);
- method public void selectPort(int, @NonNull java.util.concurrent.Executor, @NonNull android.hardware.hdmi.HdmiSwitchClient.OnSelectListener);
- }
-
- public static interface HdmiSwitchClient.OnSelectListener {
- method public void onSelect(@android.hardware.hdmi.HdmiControlManager.ControlCallbackResult int);
- }
-
- public class HdmiTimerRecordSources {
- method public static boolean checkTimerRecordSource(int, byte[]);
- method public static android.hardware.hdmi.HdmiTimerRecordSources.Duration durationOf(int, int);
- method public static android.hardware.hdmi.HdmiTimerRecordSources.TimerRecordSource ofAnalogueSource(android.hardware.hdmi.HdmiTimerRecordSources.TimerInfo, android.hardware.hdmi.HdmiRecordSources.AnalogueServiceSource);
- method public static android.hardware.hdmi.HdmiTimerRecordSources.TimerRecordSource ofDigitalSource(android.hardware.hdmi.HdmiTimerRecordSources.TimerInfo, android.hardware.hdmi.HdmiRecordSources.DigitalServiceSource);
- method public static android.hardware.hdmi.HdmiTimerRecordSources.TimerRecordSource ofExternalPhysicalAddress(android.hardware.hdmi.HdmiTimerRecordSources.TimerInfo, android.hardware.hdmi.HdmiRecordSources.ExternalPhysicalAddress);
- method public static android.hardware.hdmi.HdmiTimerRecordSources.TimerRecordSource ofExternalPlug(android.hardware.hdmi.HdmiTimerRecordSources.TimerInfo, android.hardware.hdmi.HdmiRecordSources.ExternalPlugData);
- method public static android.hardware.hdmi.HdmiTimerRecordSources.Time timeOf(int, int);
- method public static android.hardware.hdmi.HdmiTimerRecordSources.TimerInfo timerInfoOf(int, int, android.hardware.hdmi.HdmiTimerRecordSources.Time, android.hardware.hdmi.HdmiTimerRecordSources.Duration, int);
- field public static final int RECORDING_SEQUENCE_REPEAT_FRIDAY = 32; // 0x20
- field public static final int RECORDING_SEQUENCE_REPEAT_MONDAY = 2; // 0x2
- field public static final int RECORDING_SEQUENCE_REPEAT_ONCE_ONLY = 0; // 0x0
- field public static final int RECORDING_SEQUENCE_REPEAT_SATUREDAY = 64; // 0x40
- field public static final int RECORDING_SEQUENCE_REPEAT_SUNDAY = 1; // 0x1
- field public static final int RECORDING_SEQUENCE_REPEAT_THURSDAY = 16; // 0x10
- field public static final int RECORDING_SEQUENCE_REPEAT_TUESDAY = 4; // 0x4
- field public static final int RECORDING_SEQUENCE_REPEAT_WEDNESDAY = 8; // 0x8
- }
-
- public static final class HdmiTimerRecordSources.Duration {
- }
-
- public static final class HdmiTimerRecordSources.Time {
- }
-
- public static final class HdmiTimerRecordSources.TimerInfo {
- }
-
- public static final class HdmiTimerRecordSources.TimerRecordSource {
- }
-
- public final class HdmiTvClient extends android.hardware.hdmi.HdmiClient {
- method public void clearTimerRecording(int, int, android.hardware.hdmi.HdmiTimerRecordSources.TimerRecordSource);
- method public void deviceSelect(int, @NonNull android.hardware.hdmi.HdmiTvClient.SelectCallback);
- method public java.util.List<android.hardware.hdmi.HdmiDeviceInfo> getDeviceList();
- method public int getDeviceType();
- method public void portSelect(int, @NonNull android.hardware.hdmi.HdmiTvClient.SelectCallback);
- method public void sendMhlVendorCommand(int, int, int, byte[]);
- method public void sendStandby(int);
- method public void setHdmiMhlVendorCommandListener(android.hardware.hdmi.HdmiTvClient.HdmiMhlVendorCommandListener);
- method public void setInputChangeListener(android.hardware.hdmi.HdmiTvClient.InputChangeListener);
- method public void setRecordListener(@NonNull android.hardware.hdmi.HdmiRecordListener);
- method public void setSystemAudioMode(boolean, android.hardware.hdmi.HdmiTvClient.SelectCallback);
- method public void setSystemAudioMute(boolean);
- method public void setSystemAudioVolume(int, int, int);
- method public void startOneTouchRecord(int, @NonNull android.hardware.hdmi.HdmiRecordSources.RecordSource);
- method public void startTimerRecording(int, int, android.hardware.hdmi.HdmiTimerRecordSources.TimerRecordSource);
- method public void stopOneTouchRecord(int);
- field public static final int VENDOR_DATA_SIZE = 16; // 0x10
- }
-
- public static interface HdmiTvClient.HdmiMhlVendorCommandListener {
- method public void onReceived(int, int, int, byte[]);
- }
-
- public static interface HdmiTvClient.InputChangeListener {
- method public void onChanged(android.hardware.hdmi.HdmiDeviceInfo);
- }
-
- public static interface HdmiTvClient.SelectCallback {
- method public void onComplete(int);
- }
-
-}
-
-package android.hardware.lights {
-
- public final class Light implements android.os.Parcelable {
- method public int describeContents();
- method public int getId();
- method public int getOrdinal();
- method public int getType();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.hardware.lights.Light> CREATOR;
- }
-
- public final class LightState implements android.os.Parcelable {
- ctor public LightState(@ColorInt int);
- method public int describeContents();
- method @ColorInt public int getColor();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.hardware.lights.LightState> CREATOR;
- }
-
- public final class LightsManager {
- method @NonNull @RequiresPermission(android.Manifest.permission.CONTROL_DEVICE_LIGHTS) public java.util.List<android.hardware.lights.Light> getLights();
- method @NonNull @RequiresPermission(android.Manifest.permission.CONTROL_DEVICE_LIGHTS) public android.hardware.lights.LightsManager.LightsSession openSession();
- field public static final int LIGHT_TYPE_MICROPHONE = 8; // 0x8
- }
-
- public final class LightsManager.LightsSession implements java.lang.AutoCloseable {
- method @RequiresPermission(android.Manifest.permission.CONTROL_DEVICE_LIGHTS) public void close();
- method @RequiresPermission(android.Manifest.permission.CONTROL_DEVICE_LIGHTS) public void requestLights(@NonNull android.hardware.lights.LightsRequest);
- }
-
- public final class LightsRequest {
- }
-
- public static final class LightsRequest.Builder {
- ctor public LightsRequest.Builder();
- method @NonNull public android.hardware.lights.LightsRequest build();
- method @NonNull public android.hardware.lights.LightsRequest.Builder clearLight(@NonNull android.hardware.lights.Light);
- method @NonNull public android.hardware.lights.LightsRequest.Builder setLight(@NonNull android.hardware.lights.Light, @NonNull android.hardware.lights.LightState);
- }
-
-}
-
-package android.hardware.location {
-
- public class ContextHubClient implements java.io.Closeable {
- method public void close();
- method @NonNull public android.hardware.location.ContextHubInfo getAttachedHub();
- method @RequiresPermission(anyOf={android.Manifest.permission.LOCATION_HARDWARE, android.Manifest.permission.ACCESS_CONTEXT_HUB}) public int sendMessageToNanoApp(@NonNull android.hardware.location.NanoAppMessage);
- }
-
- public class ContextHubClientCallback {
- ctor public ContextHubClientCallback();
- method public void onHubReset(android.hardware.location.ContextHubClient);
- method public void onMessageFromNanoApp(android.hardware.location.ContextHubClient, android.hardware.location.NanoAppMessage);
- method public void onNanoAppAborted(android.hardware.location.ContextHubClient, long, int);
- method public void onNanoAppDisabled(android.hardware.location.ContextHubClient, long);
- method public void onNanoAppEnabled(android.hardware.location.ContextHubClient, long);
- method public void onNanoAppLoaded(android.hardware.location.ContextHubClient, long);
- method public void onNanoAppUnloaded(android.hardware.location.ContextHubClient, long);
- }
-
- public class ContextHubInfo implements android.os.Parcelable {
- ctor public ContextHubInfo();
- method public int describeContents();
- method public byte getChreApiMajorVersion();
- method public byte getChreApiMinorVersion();
- method public short getChrePatchVersion();
- method public long getChrePlatformId();
- method public int getId();
- method public int getMaxPacketLengthBytes();
- method public android.hardware.location.MemoryRegion[] getMemoryRegions();
- method public String getName();
- method public float getPeakMips();
- method public float getPeakPowerDrawMw();
- method public int getPlatformVersion();
- method public float getSleepPowerDrawMw();
- method public int getStaticSwVersion();
- method public float getStoppedPowerDrawMw();
- method public int[] getSupportedSensors();
- method public String getToolchain();
- method public int getToolchainVersion();
- method public String getVendor();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.hardware.location.ContextHubInfo> CREATOR;
- }
-
- public class ContextHubIntentEvent {
- method @NonNull public static android.hardware.location.ContextHubIntentEvent fromIntent(@NonNull android.content.Intent);
- method @NonNull public android.hardware.location.ContextHubInfo getContextHubInfo();
- method public int getEventType();
- method public int getNanoAppAbortCode();
- method public long getNanoAppId();
- method @NonNull public android.hardware.location.NanoAppMessage getNanoAppMessage();
- }
-
- public final class ContextHubManager {
- method @NonNull @RequiresPermission(anyOf={android.Manifest.permission.LOCATION_HARDWARE, android.Manifest.permission.ACCESS_CONTEXT_HUB}) public android.hardware.location.ContextHubClient createClient(@NonNull android.hardware.location.ContextHubInfo, @NonNull android.hardware.location.ContextHubClientCallback, @NonNull java.util.concurrent.Executor);
- method @NonNull @RequiresPermission(anyOf={android.Manifest.permission.LOCATION_HARDWARE, android.Manifest.permission.ACCESS_CONTEXT_HUB}) public android.hardware.location.ContextHubClient createClient(@NonNull android.hardware.location.ContextHubInfo, @NonNull android.hardware.location.ContextHubClientCallback);
- method @NonNull @RequiresPermission(anyOf={android.Manifest.permission.LOCATION_HARDWARE, android.Manifest.permission.ACCESS_CONTEXT_HUB}) public android.hardware.location.ContextHubClient createClient(@NonNull android.hardware.location.ContextHubInfo, @NonNull android.app.PendingIntent, long);
- method @NonNull @RequiresPermission(anyOf={android.Manifest.permission.LOCATION_HARDWARE, android.Manifest.permission.ACCESS_CONTEXT_HUB}) public android.hardware.location.ContextHubTransaction<java.lang.Void> disableNanoApp(@NonNull android.hardware.location.ContextHubInfo, long);
- method @NonNull @RequiresPermission(anyOf={android.Manifest.permission.LOCATION_HARDWARE, android.Manifest.permission.ACCESS_CONTEXT_HUB}) public android.hardware.location.ContextHubTransaction<java.lang.Void> enableNanoApp(@NonNull android.hardware.location.ContextHubInfo, long);
- method @Deprecated @NonNull @RequiresPermission(anyOf={android.Manifest.permission.LOCATION_HARDWARE, android.Manifest.permission.ACCESS_CONTEXT_HUB}) public int[] findNanoAppOnHub(int, @NonNull android.hardware.location.NanoAppFilter);
- method @Deprecated @RequiresPermission(anyOf={android.Manifest.permission.LOCATION_HARDWARE, android.Manifest.permission.ACCESS_CONTEXT_HUB}) public int[] getContextHubHandles();
- method @Deprecated @RequiresPermission(anyOf={android.Manifest.permission.LOCATION_HARDWARE, android.Manifest.permission.ACCESS_CONTEXT_HUB}) public android.hardware.location.ContextHubInfo getContextHubInfo(int);
- method @NonNull @RequiresPermission(anyOf={android.Manifest.permission.LOCATION_HARDWARE, android.Manifest.permission.ACCESS_CONTEXT_HUB}) public java.util.List<android.hardware.location.ContextHubInfo> getContextHubs();
- method @Deprecated @Nullable @RequiresPermission(anyOf={android.Manifest.permission.LOCATION_HARDWARE, android.Manifest.permission.ACCESS_CONTEXT_HUB}) public android.hardware.location.NanoAppInstanceInfo getNanoAppInstanceInfo(int);
- method @Deprecated @RequiresPermission(anyOf={android.Manifest.permission.LOCATION_HARDWARE, android.Manifest.permission.ACCESS_CONTEXT_HUB}) public int loadNanoApp(int, @NonNull android.hardware.location.NanoApp);
- method @NonNull @RequiresPermission(anyOf={android.Manifest.permission.LOCATION_HARDWARE, android.Manifest.permission.ACCESS_CONTEXT_HUB}) public android.hardware.location.ContextHubTransaction<java.lang.Void> loadNanoApp(@NonNull android.hardware.location.ContextHubInfo, @NonNull android.hardware.location.NanoAppBinary);
- method @NonNull @RequiresPermission(anyOf={android.Manifest.permission.LOCATION_HARDWARE, android.Manifest.permission.ACCESS_CONTEXT_HUB}) public android.hardware.location.ContextHubTransaction<java.util.List<android.hardware.location.NanoAppState>> queryNanoApps(@NonNull android.hardware.location.ContextHubInfo);
- method @Deprecated public int registerCallback(@NonNull android.hardware.location.ContextHubManager.Callback);
- method @Deprecated public int registerCallback(android.hardware.location.ContextHubManager.Callback, android.os.Handler);
- method @Deprecated @RequiresPermission(anyOf={android.Manifest.permission.LOCATION_HARDWARE, android.Manifest.permission.ACCESS_CONTEXT_HUB}) public int sendMessage(int, int, @NonNull android.hardware.location.ContextHubMessage);
- method @Deprecated @RequiresPermission(anyOf={android.Manifest.permission.LOCATION_HARDWARE, android.Manifest.permission.ACCESS_CONTEXT_HUB}) public int unloadNanoApp(int);
- method @NonNull @RequiresPermission(anyOf={android.Manifest.permission.LOCATION_HARDWARE, android.Manifest.permission.ACCESS_CONTEXT_HUB}) public android.hardware.location.ContextHubTransaction<java.lang.Void> unloadNanoApp(@NonNull android.hardware.location.ContextHubInfo, long);
- method @Deprecated public int unregisterCallback(@NonNull android.hardware.location.ContextHubManager.Callback);
- field public static final int EVENT_HUB_RESET = 6; // 0x6
- field public static final int EVENT_NANOAPP_ABORTED = 4; // 0x4
- field public static final int EVENT_NANOAPP_DISABLED = 3; // 0x3
- field public static final int EVENT_NANOAPP_ENABLED = 2; // 0x2
- field public static final int EVENT_NANOAPP_LOADED = 0; // 0x0
- field public static final int EVENT_NANOAPP_MESSAGE = 5; // 0x5
- field public static final int EVENT_NANOAPP_UNLOADED = 1; // 0x1
- field public static final String EXTRA_CONTEXT_HUB_INFO = "android.hardware.location.extra.CONTEXT_HUB_INFO";
- field public static final String EXTRA_EVENT_TYPE = "android.hardware.location.extra.EVENT_TYPE";
- field public static final String EXTRA_MESSAGE = "android.hardware.location.extra.MESSAGE";
- field public static final String EXTRA_NANOAPP_ABORT_CODE = "android.hardware.location.extra.NANOAPP_ABORT_CODE";
- field public static final String EXTRA_NANOAPP_ID = "android.hardware.location.extra.NANOAPP_ID";
- }
-
- @Deprecated public abstract static class ContextHubManager.Callback {
- ctor @Deprecated protected ContextHubManager.Callback();
- method @Deprecated public abstract void onMessageReceipt(int, int, @NonNull android.hardware.location.ContextHubMessage);
- }
-
- @Deprecated public class ContextHubMessage implements android.os.Parcelable {
- ctor @Deprecated public ContextHubMessage(int, int, byte[]);
- method @Deprecated public int describeContents();
- method @Deprecated public byte[] getData();
- method @Deprecated public int getMsgType();
- method @Deprecated public int getVersion();
- method @Deprecated public void setMsgData(byte[]);
- method @Deprecated public void setMsgType(int);
- method @Deprecated public void setVersion(int);
- method @Deprecated public void writeToParcel(android.os.Parcel, int);
- field @Deprecated @NonNull public static final android.os.Parcelable.Creator<android.hardware.location.ContextHubMessage> CREATOR;
- }
-
- public class ContextHubTransaction<T> {
- method public int getType();
- method public void setOnCompleteListener(@NonNull android.hardware.location.ContextHubTransaction.OnCompleteListener<T>, @NonNull java.util.concurrent.Executor);
- method public void setOnCompleteListener(@NonNull android.hardware.location.ContextHubTransaction.OnCompleteListener<T>);
- method public static String typeToString(int, boolean);
- method public android.hardware.location.ContextHubTransaction.Response<T> waitForResponse(long, java.util.concurrent.TimeUnit) throws java.lang.InterruptedException, java.util.concurrent.TimeoutException;
- field public static final int RESULT_FAILED_AT_HUB = 5; // 0x5
- field public static final int RESULT_FAILED_BAD_PARAMS = 2; // 0x2
- field public static final int RESULT_FAILED_BUSY = 4; // 0x4
- field public static final int RESULT_FAILED_HAL_UNAVAILABLE = 8; // 0x8
- field public static final int RESULT_FAILED_SERVICE_INTERNAL_FAILURE = 7; // 0x7
- field public static final int RESULT_FAILED_TIMEOUT = 6; // 0x6
- field public static final int RESULT_FAILED_UNINITIALIZED = 3; // 0x3
- field public static final int RESULT_FAILED_UNKNOWN = 1; // 0x1
- field public static final int RESULT_SUCCESS = 0; // 0x0
- field public static final int TYPE_DISABLE_NANOAPP = 3; // 0x3
- field public static final int TYPE_ENABLE_NANOAPP = 2; // 0x2
- field public static final int TYPE_LOAD_NANOAPP = 0; // 0x0
- field public static final int TYPE_QUERY_NANOAPPS = 4; // 0x4
- field public static final int TYPE_UNLOAD_NANOAPP = 1; // 0x1
- }
-
- @java.lang.FunctionalInterface public static interface ContextHubTransaction.OnCompleteListener<L> {
- method public void onComplete(android.hardware.location.ContextHubTransaction<L>, android.hardware.location.ContextHubTransaction.Response<L>);
- }
-
- public static class ContextHubTransaction.Response<R> {
- method public R getContents();
- method public int getResult();
- }
-
- public final class GeofenceHardware {
- method public boolean addGeofence(int, int, android.hardware.location.GeofenceHardwareRequest, android.hardware.location.GeofenceHardwareCallback);
- method public int[] getMonitoringTypes();
- method public int getStatusOfMonitoringType(int);
- method public boolean pauseGeofence(int, int);
- method public boolean registerForMonitorStateChangeCallback(int, android.hardware.location.GeofenceHardwareMonitorCallback);
- method public boolean removeGeofence(int, int);
- method public boolean resumeGeofence(int, int, int);
- method public boolean unregisterForMonitorStateChangeCallback(int, android.hardware.location.GeofenceHardwareMonitorCallback);
- field public static final int GEOFENCE_ENTERED = 1; // 0x1
- field public static final int GEOFENCE_ERROR_ID_EXISTS = 2; // 0x2
- field public static final int GEOFENCE_ERROR_ID_UNKNOWN = 3; // 0x3
- field public static final int GEOFENCE_ERROR_INSUFFICIENT_MEMORY = 6; // 0x6
- field public static final int GEOFENCE_ERROR_INVALID_TRANSITION = 4; // 0x4
- field public static final int GEOFENCE_ERROR_TOO_MANY_GEOFENCES = 1; // 0x1
- field public static final int GEOFENCE_EXITED = 2; // 0x2
- field public static final int GEOFENCE_FAILURE = 5; // 0x5
- field public static final int GEOFENCE_SUCCESS = 0; // 0x0
- field public static final int GEOFENCE_UNCERTAIN = 4; // 0x4
- field public static final int MONITORING_TYPE_FUSED_HARDWARE = 1; // 0x1
- field public static final int MONITORING_TYPE_GPS_HARDWARE = 0; // 0x0
- field public static final int MONITOR_CURRENTLY_AVAILABLE = 0; // 0x0
- field public static final int MONITOR_CURRENTLY_UNAVAILABLE = 1; // 0x1
- field public static final int MONITOR_UNSUPPORTED = 2; // 0x2
- field public static final int SOURCE_TECHNOLOGY_BLUETOOTH = 16; // 0x10
- field public static final int SOURCE_TECHNOLOGY_CELL = 8; // 0x8
- field public static final int SOURCE_TECHNOLOGY_GNSS = 1; // 0x1
- field public static final int SOURCE_TECHNOLOGY_SENSORS = 4; // 0x4
- field public static final int SOURCE_TECHNOLOGY_WIFI = 2; // 0x2
- }
-
- public abstract class GeofenceHardwareCallback {
- ctor public GeofenceHardwareCallback();
- method public void onGeofenceAdd(int, int);
- method public void onGeofencePause(int, int);
- method public void onGeofenceRemove(int, int);
- method public void onGeofenceResume(int, int);
- method public void onGeofenceTransition(int, int, android.location.Location, long, int);
- }
-
- public abstract class GeofenceHardwareMonitorCallback {
- ctor public GeofenceHardwareMonitorCallback();
- method @Deprecated public void onMonitoringSystemChange(int, boolean, android.location.Location);
- method public void onMonitoringSystemChange(android.hardware.location.GeofenceHardwareMonitorEvent);
- }
-
- public class GeofenceHardwareMonitorEvent implements android.os.Parcelable {
- ctor public GeofenceHardwareMonitorEvent(int, int, int, android.location.Location);
- method public int describeContents();
- method public android.location.Location getLocation();
- method public int getMonitoringStatus();
- method public int getMonitoringType();
- method public int getSourceTechnologies();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.hardware.location.GeofenceHardwareMonitorEvent> CREATOR;
- }
-
- public final class GeofenceHardwareRequest {
- ctor public GeofenceHardwareRequest();
- method public static android.hardware.location.GeofenceHardwareRequest createCircularGeofence(double, double, double);
- method public int getLastTransition();
- method public double getLatitude();
- method public double getLongitude();
- method public int getMonitorTransitions();
- method public int getNotificationResponsiveness();
- method public double getRadius();
- method public int getSourceTechnologies();
- method public int getUnknownTimer();
- method public void setLastTransition(int);
- method public void setMonitorTransitions(int);
- method public void setNotificationResponsiveness(int);
- method public void setSourceTechnologies(int);
- method public void setUnknownTimer(int);
- }
-
- public class MemoryRegion implements android.os.Parcelable {
- ctor public MemoryRegion(android.os.Parcel);
- method public int describeContents();
- method public int getCapacityBytes();
- method public int getFreeCapacityBytes();
- method public boolean isExecutable();
- method public boolean isReadable();
- method public boolean isWritable();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.hardware.location.MemoryRegion> CREATOR;
- }
-
- @Deprecated public class NanoApp implements android.os.Parcelable {
- ctor @Deprecated public NanoApp();
- ctor @Deprecated public NanoApp(int, byte[]);
- ctor @Deprecated public NanoApp(long, byte[]);
- method @Deprecated public int describeContents();
- method @Deprecated public byte[] getAppBinary();
- method @Deprecated public long getAppId();
- method @Deprecated public int getAppVersion();
- method @Deprecated public String getName();
- method @Deprecated public int getNeededExecMemBytes();
- method @Deprecated public int getNeededReadMemBytes();
- method @Deprecated public int[] getNeededSensors();
- method @Deprecated public int getNeededWriteMemBytes();
- method @Deprecated public int[] getOutputEvents();
- method @Deprecated public String getPublisher();
- method @Deprecated public void setAppBinary(byte[]);
- method @Deprecated public void setAppId(long);
- method @Deprecated public void setAppVersion(int);
- method @Deprecated public void setName(String);
- method @Deprecated public void setNeededExecMemBytes(int);
- method @Deprecated public void setNeededReadMemBytes(int);
- method @Deprecated public void setNeededSensors(int[]);
- method @Deprecated public void setNeededWriteMemBytes(int);
- method @Deprecated public void setOutputEvents(int[]);
- method @Deprecated public void setPublisher(String);
- method @Deprecated public void writeToParcel(android.os.Parcel, int);
- field @Deprecated @NonNull public static final android.os.Parcelable.Creator<android.hardware.location.NanoApp> CREATOR;
- }
-
- public final class NanoAppBinary implements android.os.Parcelable {
- ctor public NanoAppBinary(byte[]);
- method public int describeContents();
- method public byte[] getBinary();
- method public byte[] getBinaryNoHeader();
- method public int getFlags();
- method public int getHeaderVersion();
- method public long getHwHubType();
- method public long getNanoAppId();
- method public int getNanoAppVersion();
- method public byte getTargetChreApiMajorVersion();
- method public byte getTargetChreApiMinorVersion();
- method public boolean hasValidHeader();
- method public boolean isEncrypted();
- method public boolean isSigned();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.hardware.location.NanoAppBinary> CREATOR;
- }
-
- @Deprecated public class NanoAppFilter implements android.os.Parcelable {
- ctor @Deprecated public NanoAppFilter(long, int, int, long);
- method @Deprecated public int describeContents();
- method @Deprecated public boolean testMatch(android.hardware.location.NanoAppInstanceInfo);
- method @Deprecated public void writeToParcel(android.os.Parcel, int);
- field @Deprecated public static final int APP_ANY = -1; // 0xffffffff
- field @Deprecated @NonNull public static final android.os.Parcelable.Creator<android.hardware.location.NanoAppFilter> CREATOR;
- field @Deprecated public static final int FLAGS_VERSION_ANY = -1; // 0xffffffff
- field @Deprecated public static final int FLAGS_VERSION_GREAT_THAN = 2; // 0x2
- field @Deprecated public static final int FLAGS_VERSION_LESS_THAN = 4; // 0x4
- field @Deprecated public static final int FLAGS_VERSION_STRICTLY_EQUAL = 8; // 0x8
- field @Deprecated public static final int HUB_ANY = -1; // 0xffffffff
- field @Deprecated public static final int VENDOR_ANY = -1; // 0xffffffff
- }
-
- @Deprecated public class NanoAppInstanceInfo implements android.os.Parcelable {
- ctor @Deprecated public NanoAppInstanceInfo();
- method @Deprecated public int describeContents();
- method @Deprecated public long getAppId();
- method @Deprecated public int getAppVersion();
- method @Deprecated public int getContexthubId();
- method @Deprecated public int getHandle();
- method @Deprecated public String getName();
- method @Deprecated public int getNeededExecMemBytes();
- method @Deprecated public int getNeededReadMemBytes();
- method @Deprecated @NonNull public int[] getNeededSensors();
- method @Deprecated public int getNeededWriteMemBytes();
- method @Deprecated @NonNull public int[] getOutputEvents();
- method @Deprecated public String getPublisher();
- method @Deprecated public void writeToParcel(android.os.Parcel, int);
- field @Deprecated @NonNull public static final android.os.Parcelable.Creator<android.hardware.location.NanoAppInstanceInfo> CREATOR;
- }
-
- public final class NanoAppMessage implements android.os.Parcelable {
- method public static android.hardware.location.NanoAppMessage createMessageFromNanoApp(long, int, byte[], boolean);
- method public static android.hardware.location.NanoAppMessage createMessageToNanoApp(long, int, byte[]);
- method public int describeContents();
- method public byte[] getMessageBody();
- method public int getMessageType();
- method public long getNanoAppId();
- method public boolean isBroadcastMessage();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.hardware.location.NanoAppMessage> CREATOR;
- }
-
- public final class NanoAppState implements android.os.Parcelable {
- ctor public NanoAppState(long, int, boolean);
- method public int describeContents();
- method public long getNanoAppId();
- method public long getNanoAppVersion();
- method public boolean isEnabled();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.hardware.location.NanoAppState> CREATOR;
- }
-
-}
-
-package android.hardware.radio {
-
- public final class Announcement implements android.os.Parcelable {
- method public int describeContents();
- method @NonNull public android.hardware.radio.ProgramSelector getSelector();
- method public int getType();
- method @NonNull public java.util.Map<java.lang.String,java.lang.String> getVendorInfo();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.hardware.radio.Announcement> CREATOR;
- field public static final int TYPE_EMERGENCY = 1; // 0x1
- field public static final int TYPE_EVENT = 6; // 0x6
- field public static final int TYPE_MISC = 8; // 0x8
- field public static final int TYPE_NEWS = 5; // 0x5
- field public static final int TYPE_SPORT = 7; // 0x7
- field public static final int TYPE_TRAFFIC = 3; // 0x3
- field public static final int TYPE_WARNING = 2; // 0x2
- field public static final int TYPE_WEATHER = 4; // 0x4
- }
-
- public static interface Announcement.OnListUpdatedListener {
- method public void onListUpdated(java.util.Collection<android.hardware.radio.Announcement>);
- }
-
- public final class ProgramList implements java.lang.AutoCloseable {
- method public void addOnCompleteListener(@NonNull java.util.concurrent.Executor, @NonNull android.hardware.radio.ProgramList.OnCompleteListener);
- method public void addOnCompleteListener(@NonNull android.hardware.radio.ProgramList.OnCompleteListener);
- method public void close();
- method @Nullable public android.hardware.radio.RadioManager.ProgramInfo get(@NonNull android.hardware.radio.ProgramSelector.Identifier);
- method public void registerListCallback(@NonNull java.util.concurrent.Executor, @NonNull android.hardware.radio.ProgramList.ListCallback);
- method public void registerListCallback(@NonNull android.hardware.radio.ProgramList.ListCallback);
- method public void removeOnCompleteListener(@NonNull android.hardware.radio.ProgramList.OnCompleteListener);
- method @NonNull public java.util.List<android.hardware.radio.RadioManager.ProgramInfo> toList();
- method public void unregisterListCallback(@NonNull android.hardware.radio.ProgramList.ListCallback);
- }
-
- public static final class ProgramList.Filter implements android.os.Parcelable {
- ctor public ProgramList.Filter(@NonNull java.util.Set<java.lang.Integer>, @NonNull java.util.Set<android.hardware.radio.ProgramSelector.Identifier>, boolean, boolean);
- method public boolean areCategoriesIncluded();
- method public boolean areModificationsExcluded();
- method public int describeContents();
- method @NonNull public java.util.Set<java.lang.Integer> getIdentifierTypes();
- method @NonNull public java.util.Set<android.hardware.radio.ProgramSelector.Identifier> getIdentifiers();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.hardware.radio.ProgramList.Filter> CREATOR;
- }
-
- public abstract static class ProgramList.ListCallback {
- ctor public ProgramList.ListCallback();
- method public void onItemChanged(@NonNull android.hardware.radio.ProgramSelector.Identifier);
- method public void onItemRemoved(@NonNull android.hardware.radio.ProgramSelector.Identifier);
- }
-
- public static interface ProgramList.OnCompleteListener {
- method public void onComplete();
- }
-
- public final class ProgramSelector implements android.os.Parcelable {
- ctor public ProgramSelector(@android.hardware.radio.ProgramSelector.ProgramType int, @NonNull android.hardware.radio.ProgramSelector.Identifier, @Nullable android.hardware.radio.ProgramSelector.Identifier[], @Nullable long[]);
- method @NonNull public static android.hardware.radio.ProgramSelector createAmFmSelector(@android.hardware.radio.RadioManager.Band int, int);
- method @NonNull public static android.hardware.radio.ProgramSelector createAmFmSelector(@android.hardware.radio.RadioManager.Band int, int, int);
- method public int describeContents();
- method @NonNull public android.hardware.radio.ProgramSelector.Identifier[] getAllIds(@android.hardware.radio.ProgramSelector.IdentifierType int);
- method public long getFirstId(@android.hardware.radio.ProgramSelector.IdentifierType int);
- method @NonNull public android.hardware.radio.ProgramSelector.Identifier getPrimaryId();
- method @Deprecated @android.hardware.radio.ProgramSelector.ProgramType public int getProgramType();
- method @NonNull public android.hardware.radio.ProgramSelector.Identifier[] getSecondaryIds();
- method @Deprecated @NonNull public long[] getVendorIds();
- method @NonNull public android.hardware.radio.ProgramSelector withSecondaryPreferred(@NonNull android.hardware.radio.ProgramSelector.Identifier);
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.hardware.radio.ProgramSelector> CREATOR;
- field public static final int IDENTIFIER_TYPE_AMFM_FREQUENCY = 1; // 0x1
- field public static final int IDENTIFIER_TYPE_DAB_ENSEMBLE = 6; // 0x6
- field public static final int IDENTIFIER_TYPE_DAB_FREQUENCY = 8; // 0x8
- field public static final int IDENTIFIER_TYPE_DAB_SCID = 7; // 0x7
- field public static final int IDENTIFIER_TYPE_DAB_SIDECC = 5; // 0x5
- field public static final int IDENTIFIER_TYPE_DAB_SID_EXT = 5; // 0x5
- field public static final int IDENTIFIER_TYPE_DRMO_FREQUENCY = 10; // 0xa
- field @Deprecated public static final int IDENTIFIER_TYPE_DRMO_MODULATION = 11; // 0xb
- field public static final int IDENTIFIER_TYPE_DRMO_SERVICE_ID = 9; // 0x9
- field public static final int IDENTIFIER_TYPE_HD_STATION_ID_EXT = 3; // 0x3
- field public static final int IDENTIFIER_TYPE_HD_STATION_NAME = 10004; // 0x2714
- field @Deprecated public static final int IDENTIFIER_TYPE_HD_SUBCHANNEL = 4; // 0x4
- field public static final int IDENTIFIER_TYPE_INVALID = 0; // 0x0
- field public static final int IDENTIFIER_TYPE_RDS_PI = 2; // 0x2
- field public static final int IDENTIFIER_TYPE_SXM_CHANNEL = 13; // 0xd
- field public static final int IDENTIFIER_TYPE_SXM_SERVICE_ID = 12; // 0xc
- field public static final int IDENTIFIER_TYPE_VENDOR_END = 1999; // 0x7cf
- field @Deprecated public static final int IDENTIFIER_TYPE_VENDOR_PRIMARY_END = 1999; // 0x7cf
- field @Deprecated public static final int IDENTIFIER_TYPE_VENDOR_PRIMARY_START = 1000; // 0x3e8
- field public static final int IDENTIFIER_TYPE_VENDOR_START = 1000; // 0x3e8
- field @Deprecated public static final int PROGRAM_TYPE_AM = 1; // 0x1
- field @Deprecated public static final int PROGRAM_TYPE_AM_HD = 3; // 0x3
- field @Deprecated public static final int PROGRAM_TYPE_DAB = 5; // 0x5
- field @Deprecated public static final int PROGRAM_TYPE_DRMO = 6; // 0x6
- field @Deprecated public static final int PROGRAM_TYPE_FM = 2; // 0x2
- field @Deprecated public static final int PROGRAM_TYPE_FM_HD = 4; // 0x4
- field @Deprecated public static final int PROGRAM_TYPE_INVALID = 0; // 0x0
- field @Deprecated public static final int PROGRAM_TYPE_SXM = 7; // 0x7
- field @Deprecated public static final int PROGRAM_TYPE_VENDOR_END = 1999; // 0x7cf
- field @Deprecated public static final int PROGRAM_TYPE_VENDOR_START = 1000; // 0x3e8
- }
-
- public static final class ProgramSelector.Identifier implements android.os.Parcelable {
- ctor public ProgramSelector.Identifier(@android.hardware.radio.ProgramSelector.IdentifierType int, long);
- method public int describeContents();
- method @android.hardware.radio.ProgramSelector.IdentifierType public int getType();
- method public long getValue();
- method public boolean isCategoryType();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.hardware.radio.ProgramSelector.Identifier> CREATOR;
- }
-
- @IntDef(prefix={"IDENTIFIER_TYPE_"}, value={android.hardware.radio.ProgramSelector.IDENTIFIER_TYPE_INVALID, android.hardware.radio.ProgramSelector.IDENTIFIER_TYPE_AMFM_FREQUENCY, android.hardware.radio.ProgramSelector.IDENTIFIER_TYPE_RDS_PI, android.hardware.radio.ProgramSelector.IDENTIFIER_TYPE_HD_STATION_ID_EXT, android.hardware.radio.ProgramSelector.IDENTIFIER_TYPE_HD_SUBCHANNEL, android.hardware.radio.ProgramSelector.IDENTIFIER_TYPE_HD_STATION_NAME, android.hardware.radio.ProgramSelector.IDENTIFIER_TYPE_DAB_SID_EXT, android.hardware.radio.ProgramSelector.IDENTIFIER_TYPE_DAB_SIDECC, android.hardware.radio.ProgramSelector.IDENTIFIER_TYPE_DAB_ENSEMBLE, android.hardware.radio.ProgramSelector.IDENTIFIER_TYPE_DAB_SCID, android.hardware.radio.ProgramSelector.IDENTIFIER_TYPE_DAB_FREQUENCY, android.hardware.radio.ProgramSelector.IDENTIFIER_TYPE_DRMO_SERVICE_ID, android.hardware.radio.ProgramSelector.IDENTIFIER_TYPE_DRMO_FREQUENCY, android.hardware.radio.ProgramSelector.IDENTIFIER_TYPE_DRMO_MODULATION, android.hardware.radio.ProgramSelector.IDENTIFIER_TYPE_SXM_SERVICE_ID, android.hardware.radio.ProgramSelector.IDENTIFIER_TYPE_SXM_CHANNEL}) @IntRange(from=android.hardware.radio.ProgramSelector.IDENTIFIER_TYPE_VENDOR_START, to=android.hardware.radio.ProgramSelector.IDENTIFIER_TYPE_VENDOR_END) @java.lang.annotation.Retention(java.lang.annotation.RetentionPolicy.SOURCE) public static @interface ProgramSelector.IdentifierType {
- }
-
- @Deprecated @IntDef(prefix={"PROGRAM_TYPE_"}, value={android.hardware.radio.ProgramSelector.PROGRAM_TYPE_INVALID, android.hardware.radio.ProgramSelector.PROGRAM_TYPE_AM, android.hardware.radio.ProgramSelector.PROGRAM_TYPE_FM, android.hardware.radio.ProgramSelector.PROGRAM_TYPE_AM_HD, android.hardware.radio.ProgramSelector.PROGRAM_TYPE_FM_HD, android.hardware.radio.ProgramSelector.PROGRAM_TYPE_DAB, android.hardware.radio.ProgramSelector.PROGRAM_TYPE_DRMO, android.hardware.radio.ProgramSelector.PROGRAM_TYPE_SXM}) @IntRange(from=android.hardware.radio.ProgramSelector.PROGRAM_TYPE_VENDOR_START, to=android.hardware.radio.ProgramSelector.PROGRAM_TYPE_VENDOR_END) @java.lang.annotation.Retention(java.lang.annotation.RetentionPolicy.SOURCE) public static @interface ProgramSelector.ProgramType {
- }
-
- public class RadioManager {
- method @RequiresPermission(android.Manifest.permission.ACCESS_BROADCAST_RADIO) public void addAnnouncementListener(@NonNull java.util.Set<java.lang.Integer>, @NonNull android.hardware.radio.Announcement.OnListUpdatedListener);
- method @RequiresPermission(android.Manifest.permission.ACCESS_BROADCAST_RADIO) public void addAnnouncementListener(@NonNull java.util.concurrent.Executor, @NonNull java.util.Set<java.lang.Integer>, @NonNull android.hardware.radio.Announcement.OnListUpdatedListener);
- method @RequiresPermission(android.Manifest.permission.ACCESS_BROADCAST_RADIO) public int listModules(java.util.List<android.hardware.radio.RadioManager.ModuleProperties>);
- method @RequiresPermission(android.Manifest.permission.ACCESS_BROADCAST_RADIO) public android.hardware.radio.RadioTuner openTuner(int, android.hardware.radio.RadioManager.BandConfig, boolean, android.hardware.radio.RadioTuner.Callback, android.os.Handler);
- method @RequiresPermission(android.Manifest.permission.ACCESS_BROADCAST_RADIO) public void removeAnnouncementListener(@NonNull android.hardware.radio.Announcement.OnListUpdatedListener);
- field public static final int BAND_AM = 0; // 0x0
- field public static final int BAND_AM_HD = 3; // 0x3
- field public static final int BAND_FM = 1; // 0x1
- field public static final int BAND_FM_HD = 2; // 0x2
- field public static final int BAND_INVALID = -1; // 0xffffffff
- field public static final int CLASS_AM_FM = 0; // 0x0
- field public static final int CLASS_DT = 2; // 0x2
- field public static final int CLASS_SAT = 1; // 0x1
- field public static final int CONFIG_DAB_DAB_LINKING = 6; // 0x6
- field public static final int CONFIG_DAB_DAB_SOFT_LINKING = 8; // 0x8
- field public static final int CONFIG_DAB_FM_LINKING = 7; // 0x7
- field public static final int CONFIG_DAB_FM_SOFT_LINKING = 9; // 0x9
- field public static final int CONFIG_FORCE_ANALOG = 2; // 0x2
- field public static final int CONFIG_FORCE_DIGITAL = 3; // 0x3
- field public static final int CONFIG_FORCE_MONO = 1; // 0x1
- field public static final int CONFIG_RDS_AF = 4; // 0x4
- field public static final int CONFIG_RDS_REG = 5; // 0x5
- field public static final int REGION_ITU_1 = 0; // 0x0
- field public static final int REGION_ITU_2 = 1; // 0x1
- field public static final int REGION_JAPAN = 3; // 0x3
- field public static final int REGION_KOREA = 4; // 0x4
- field public static final int REGION_OIRT = 2; // 0x2
- field public static final int STATUS_BAD_VALUE = -22; // 0xffffffea
- field public static final int STATUS_DEAD_OBJECT = -32; // 0xffffffe0
- field public static final int STATUS_ERROR = -2147483648; // 0x80000000
- field public static final int STATUS_INVALID_OPERATION = -38; // 0xffffffda
- field public static final int STATUS_NO_INIT = -19; // 0xffffffed
- field public static final int STATUS_OK = 0; // 0x0
- field public static final int STATUS_PERMISSION_DENIED = -1; // 0xffffffff
- field public static final int STATUS_TIMED_OUT = -110; // 0xffffff92
- }
-
- public static class RadioManager.AmBandConfig extends android.hardware.radio.RadioManager.BandConfig {
- method public boolean getStereo();
- field @NonNull public static final android.os.Parcelable.Creator<android.hardware.radio.RadioManager.AmBandConfig> CREATOR;
- }
-
- public static class RadioManager.AmBandConfig.Builder {
- ctor public RadioManager.AmBandConfig.Builder(android.hardware.radio.RadioManager.AmBandDescriptor);
- ctor public RadioManager.AmBandConfig.Builder(android.hardware.radio.RadioManager.AmBandConfig);
- method public android.hardware.radio.RadioManager.AmBandConfig build();
- method public android.hardware.radio.RadioManager.AmBandConfig.Builder setStereo(boolean);
- }
-
- public static class RadioManager.AmBandDescriptor extends android.hardware.radio.RadioManager.BandDescriptor {
- method public boolean isStereoSupported();
- field @NonNull public static final android.os.Parcelable.Creator<android.hardware.radio.RadioManager.AmBandDescriptor> CREATOR;
- }
-
- @IntDef(prefix={"BAND_"}, value={android.hardware.radio.RadioManager.BAND_INVALID, android.hardware.radio.RadioManager.BAND_AM, android.hardware.radio.RadioManager.BAND_FM, android.hardware.radio.RadioManager.BAND_AM_HD, android.hardware.radio.RadioManager.BAND_FM_HD}) @java.lang.annotation.Retention(java.lang.annotation.RetentionPolicy.SOURCE) public static @interface RadioManager.Band {
- }
-
- public static class RadioManager.BandConfig implements android.os.Parcelable {
- method public int describeContents();
- method public int getLowerLimit();
- method public int getRegion();
- method public int getSpacing();
- method public int getType();
- method public int getUpperLimit();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.hardware.radio.RadioManager.BandConfig> CREATOR;
- }
-
- public static class RadioManager.BandDescriptor implements android.os.Parcelable {
- method public int describeContents();
- method public int getLowerLimit();
- method public int getRegion();
- method public int getSpacing();
- method public int getType();
- method public int getUpperLimit();
- method public boolean isAmBand();
- method public boolean isFmBand();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.hardware.radio.RadioManager.BandDescriptor> CREATOR;
- }
-
- public static class RadioManager.FmBandConfig extends android.hardware.radio.RadioManager.BandConfig {
- method public boolean getAf();
- method public boolean getEa();
- method public boolean getRds();
- method public boolean getStereo();
- method public boolean getTa();
- field @NonNull public static final android.os.Parcelable.Creator<android.hardware.radio.RadioManager.FmBandConfig> CREATOR;
- }
-
- public static class RadioManager.FmBandConfig.Builder {
- ctor public RadioManager.FmBandConfig.Builder(android.hardware.radio.RadioManager.FmBandDescriptor);
- ctor public RadioManager.FmBandConfig.Builder(android.hardware.radio.RadioManager.FmBandConfig);
- method public android.hardware.radio.RadioManager.FmBandConfig build();
- method public android.hardware.radio.RadioManager.FmBandConfig.Builder setAf(boolean);
- method public android.hardware.radio.RadioManager.FmBandConfig.Builder setEa(boolean);
- method public android.hardware.radio.RadioManager.FmBandConfig.Builder setRds(boolean);
- method public android.hardware.radio.RadioManager.FmBandConfig.Builder setStereo(boolean);
- method public android.hardware.radio.RadioManager.FmBandConfig.Builder setTa(boolean);
- }
-
- public static class RadioManager.FmBandDescriptor extends android.hardware.radio.RadioManager.BandDescriptor {
- method public boolean isAfSupported();
- method public boolean isEaSupported();
- method public boolean isRdsSupported();
- method public boolean isStereoSupported();
- method public boolean isTaSupported();
- field @NonNull public static final android.os.Parcelable.Creator<android.hardware.radio.RadioManager.FmBandDescriptor> CREATOR;
- }
-
- public static class RadioManager.ModuleProperties implements android.os.Parcelable {
- method public int describeContents();
- method public android.hardware.radio.RadioManager.BandDescriptor[] getBands();
- method public int getClassId();
- method @Nullable public java.util.Map<java.lang.String,java.lang.Integer> getDabFrequencyTable();
- method public int getId();
- method public String getImplementor();
- method public int getNumAudioSources();
- method public int getNumTuners();
- method public String getProduct();
- method public String getSerial();
- method @NonNull public String getServiceName();
- method @NonNull public java.util.Map<java.lang.String,java.lang.String> getVendorInfo();
- method public String getVersion();
- method public boolean isBackgroundScanningSupported();
- method public boolean isCaptureSupported();
- method public boolean isInitializationRequired();
- method public boolean isProgramIdentifierSupported(@android.hardware.radio.ProgramSelector.IdentifierType int);
- method public boolean isProgramTypeSupported(@android.hardware.radio.ProgramSelector.ProgramType int);
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.hardware.radio.RadioManager.ModuleProperties> CREATOR;
- }
-
- public static class RadioManager.ProgramInfo implements android.os.Parcelable {
- method public int describeContents();
- method @Deprecated public int getChannel();
- method @Nullable public android.hardware.radio.ProgramSelector.Identifier getLogicallyTunedTo();
- method public android.hardware.radio.RadioMetadata getMetadata();
- method @Nullable public android.hardware.radio.ProgramSelector.Identifier getPhysicallyTunedTo();
- method @Nullable public java.util.Collection<android.hardware.radio.ProgramSelector.Identifier> getRelatedContent();
- method @NonNull public android.hardware.radio.ProgramSelector getSelector();
- method public int getSignalStrength();
- method @Deprecated public int getSubChannel();
- method @NonNull public java.util.Map<java.lang.String,java.lang.String> getVendorInfo();
- method @Deprecated public boolean isDigital();
- method public boolean isLive();
- method public boolean isMuted();
- method public boolean isStereo();
- method public boolean isTrafficAnnouncementActive();
- method public boolean isTrafficProgram();
- method public boolean isTuned();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.hardware.radio.RadioManager.ProgramInfo> CREATOR;
- }
-
- public final class RadioMetadata implements android.os.Parcelable {
- method public boolean containsKey(String);
- method public int describeContents();
- method @Deprecated public android.graphics.Bitmap getBitmap(String);
- method public android.hardware.radio.RadioMetadata.Clock getClock(String);
- method public int getInt(String);
- method public String getString(String);
- method public java.util.Set<java.lang.String> keySet();
- method public int size();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.hardware.radio.RadioMetadata> CREATOR;
- field public static final String METADATA_KEY_ALBUM = "android.hardware.radio.metadata.ALBUM";
- field public static final String METADATA_KEY_ART = "android.hardware.radio.metadata.ART";
- field public static final String METADATA_KEY_ARTIST = "android.hardware.radio.metadata.ARTIST";
- field public static final String METADATA_KEY_CLOCK = "android.hardware.radio.metadata.CLOCK";
- field public static final String METADATA_KEY_DAB_COMPONENT_NAME = "android.hardware.radio.metadata.DAB_COMPONENT_NAME";
- field public static final String METADATA_KEY_DAB_COMPONENT_NAME_SHORT = "android.hardware.radio.metadata.DAB_COMPONENT_NAME_SHORT";
- field public static final String METADATA_KEY_DAB_ENSEMBLE_NAME = "android.hardware.radio.metadata.DAB_ENSEMBLE_NAME";
- field public static final String METADATA_KEY_DAB_ENSEMBLE_NAME_SHORT = "android.hardware.radio.metadata.DAB_ENSEMBLE_NAME_SHORT";
- field public static final String METADATA_KEY_DAB_SERVICE_NAME = "android.hardware.radio.metadata.DAB_SERVICE_NAME";
- field public static final String METADATA_KEY_DAB_SERVICE_NAME_SHORT = "android.hardware.radio.metadata.DAB_SERVICE_NAME_SHORT";
- field public static final String METADATA_KEY_GENRE = "android.hardware.radio.metadata.GENRE";
- field public static final String METADATA_KEY_ICON = "android.hardware.radio.metadata.ICON";
- field public static final String METADATA_KEY_PROGRAM_NAME = "android.hardware.radio.metadata.PROGRAM_NAME";
- field public static final String METADATA_KEY_RBDS_PTY = "android.hardware.radio.metadata.RBDS_PTY";
- field public static final String METADATA_KEY_RDS_PI = "android.hardware.radio.metadata.RDS_PI";
- field public static final String METADATA_KEY_RDS_PS = "android.hardware.radio.metadata.RDS_PS";
- field public static final String METADATA_KEY_RDS_PTY = "android.hardware.radio.metadata.RDS_PTY";
- field public static final String METADATA_KEY_RDS_RT = "android.hardware.radio.metadata.RDS_RT";
- field public static final String METADATA_KEY_TITLE = "android.hardware.radio.metadata.TITLE";
- }
-
- public static final class RadioMetadata.Builder {
- ctor public RadioMetadata.Builder();
- ctor public RadioMetadata.Builder(android.hardware.radio.RadioMetadata);
- method public android.hardware.radio.RadioMetadata build();
- method public android.hardware.radio.RadioMetadata.Builder putBitmap(String, android.graphics.Bitmap);
- method public android.hardware.radio.RadioMetadata.Builder putClock(String, long, int);
- method public android.hardware.radio.RadioMetadata.Builder putInt(String, int);
- method public android.hardware.radio.RadioMetadata.Builder putString(String, String);
- }
-
- public static final class RadioMetadata.Clock implements android.os.Parcelable {
- ctor public RadioMetadata.Clock(long, int);
- method public int describeContents();
- method public int getTimezoneOffsetMinutes();
- method public long getUtcEpochSeconds();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.hardware.radio.RadioMetadata.Clock> CREATOR;
- }
-
- public abstract class RadioTuner {
- ctor public RadioTuner();
- method public abstract int cancel();
- method public abstract void cancelAnnouncement();
- method public abstract void close();
- method @Deprecated public abstract int getConfiguration(android.hardware.radio.RadioManager.BandConfig[]);
- method @Nullable public android.hardware.radio.ProgramList getDynamicProgramList(@Nullable android.hardware.radio.ProgramList.Filter);
- method public abstract boolean getMute();
- method @NonNull public java.util.Map<java.lang.String,java.lang.String> getParameters(@NonNull java.util.List<java.lang.String>);
- method @Deprecated public abstract int getProgramInformation(android.hardware.radio.RadioManager.ProgramInfo[]);
- method @Deprecated @NonNull public abstract java.util.List<android.hardware.radio.RadioManager.ProgramInfo> getProgramList(@Nullable java.util.Map<java.lang.String,java.lang.String>);
- method public abstract boolean hasControl();
- method @Deprecated public abstract boolean isAnalogForced();
- method @Deprecated public abstract boolean isAntennaConnected();
- method public boolean isConfigFlagSet(int);
- method public boolean isConfigFlagSupported(int);
- method public abstract int scan(int, boolean);
- method @Deprecated public abstract void setAnalogForced(boolean);
- method public void setConfigFlag(int, boolean);
- method @Deprecated public abstract int setConfiguration(android.hardware.radio.RadioManager.BandConfig);
- method public abstract int setMute(boolean);
- method @NonNull public java.util.Map<java.lang.String,java.lang.String> setParameters(@NonNull java.util.Map<java.lang.String,java.lang.String>);
- method public abstract boolean startBackgroundScan();
- method public abstract int step(int, boolean);
- method @Deprecated public abstract int tune(int, int);
- method public abstract void tune(@NonNull android.hardware.radio.ProgramSelector);
- field public static final int DIRECTION_DOWN = 1; // 0x1
- field public static final int DIRECTION_UP = 0; // 0x0
- field @Deprecated public static final int ERROR_BACKGROUND_SCAN_FAILED = 6; // 0x6
- field @Deprecated public static final int ERROR_BACKGROUND_SCAN_UNAVAILABLE = 5; // 0x5
- field @Deprecated public static final int ERROR_CANCELLED = 2; // 0x2
- field @Deprecated public static final int ERROR_CONFIG = 4; // 0x4
- field @Deprecated public static final int ERROR_HARDWARE_FAILURE = 0; // 0x0
- field @Deprecated public static final int ERROR_SCAN_TIMEOUT = 3; // 0x3
- field @Deprecated public static final int ERROR_SERVER_DIED = 1; // 0x1
- }
-
- public abstract static class RadioTuner.Callback {
- ctor public RadioTuner.Callback();
- method public void onAntennaState(boolean);
- method public void onBackgroundScanAvailabilityChange(boolean);
- method public void onBackgroundScanComplete();
- method @Deprecated public void onConfigurationChanged(android.hardware.radio.RadioManager.BandConfig);
- method public void onControlChanged(boolean);
- method public void onEmergencyAnnouncement(boolean);
- method @Deprecated public void onError(int);
- method @Deprecated public void onMetadataChanged(android.hardware.radio.RadioMetadata);
- method public void onParametersUpdated(@NonNull java.util.Map<java.lang.String,java.lang.String>);
- method public void onProgramInfoChanged(android.hardware.radio.RadioManager.ProgramInfo);
- method public void onProgramListChanged();
- method public void onTrafficAnnouncement(boolean);
- method public void onTuneFailed(int, @Nullable android.hardware.radio.ProgramSelector);
- }
-
-}
-
-package android.hardware.soundtrigger {
-
- public class SoundTrigger {
- field public static final int RECOGNITION_MODE_GENERIC = 8; // 0x8
- field public static final int RECOGNITION_MODE_USER_AUTHENTICATION = 4; // 0x4
- field public static final int RECOGNITION_MODE_USER_IDENTIFICATION = 2; // 0x2
- field public static final int RECOGNITION_MODE_VOICE_TRIGGER = 1; // 0x1
- field public static final int STATUS_OK = 0; // 0x0
- }
-
- public static final class SoundTrigger.Keyphrase implements android.os.Parcelable {
- ctor public SoundTrigger.Keyphrase(int, int, @NonNull java.util.Locale, @NonNull String, @Nullable int[]);
- method public int getId();
- method @NonNull public java.util.Locale getLocale();
- method public int getRecognitionModes();
- method @NonNull public String getText();
- method @NonNull public int[] getUsers();
- method @NonNull public static android.hardware.soundtrigger.SoundTrigger.Keyphrase readFromParcel(@NonNull android.os.Parcel);
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.hardware.soundtrigger.SoundTrigger.Keyphrase> CREATOR;
- }
-
- public static final class SoundTrigger.KeyphraseSoundModel extends android.hardware.soundtrigger.SoundTrigger.SoundModel implements android.os.Parcelable {
- ctor public SoundTrigger.KeyphraseSoundModel(@NonNull java.util.UUID, @NonNull java.util.UUID, @Nullable byte[], @Nullable android.hardware.soundtrigger.SoundTrigger.Keyphrase[], int);
- ctor public SoundTrigger.KeyphraseSoundModel(@NonNull java.util.UUID, @NonNull java.util.UUID, @Nullable byte[], @Nullable android.hardware.soundtrigger.SoundTrigger.Keyphrase[]);
- method @NonNull public android.hardware.soundtrigger.SoundTrigger.Keyphrase[] getKeyphrases();
- method @NonNull public static android.hardware.soundtrigger.SoundTrigger.KeyphraseSoundModel readFromParcel(@NonNull android.os.Parcel);
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.hardware.soundtrigger.SoundTrigger.KeyphraseSoundModel> CREATOR;
- }
-
- public static final class SoundTrigger.ModelParamRange implements android.os.Parcelable {
- method public int getEnd();
- method public int getStart();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.hardware.soundtrigger.SoundTrigger.ModelParamRange> CREATOR;
- }
-
- public static final class SoundTrigger.ModuleProperties implements android.os.Parcelable {
- method public int describeContents();
- method public int getAudioCapabilities();
- method @NonNull public String getDescription();
- method public int getId();
- method @NonNull public String getImplementor();
- method public int getMaxBufferMillis();
- method public int getMaxKeyphrases();
- method public int getMaxSoundModels();
- method public int getMaxUsers();
- method public int getPowerConsumptionMw();
- method public int getRecognitionModes();
- method @NonNull public String getSupportedModelArch();
- method @NonNull public java.util.UUID getUuid();
- method public int getVersion();
- method public boolean isCaptureTransitionSupported();
- method public boolean isConcurrentCaptureSupported();
- method public boolean isTriggerReturnedInEvent();
- method public void writeToParcel(android.os.Parcel, int);
- field public static final int AUDIO_CAPABILITY_ECHO_CANCELLATION = 1; // 0x1
- field public static final int AUDIO_CAPABILITY_NOISE_SUPPRESSION = 2; // 0x2
- field @NonNull public static final android.os.Parcelable.Creator<android.hardware.soundtrigger.SoundTrigger.ModuleProperties> CREATOR;
- }
-
- public static class SoundTrigger.RecognitionEvent {
- method @Nullable public android.media.AudioFormat getCaptureFormat();
- method public int getCaptureSession();
- method public byte[] getData();
- method public boolean isCaptureAvailable();
- }
-
- public static class SoundTrigger.SoundModel {
- method @NonNull public byte[] getData();
- method public int getType();
- method @NonNull public java.util.UUID getUuid();
- method @NonNull public java.util.UUID getVendorUuid();
- method public int getVersion();
- field public static final int TYPE_GENERIC_SOUND = 1; // 0x1
- field public static final int TYPE_KEYPHRASE = 0; // 0x0
- }
-
-}
-
-package android.hardware.usb {
-
- public class UsbDeviceConnection {
- method public boolean resetDevice();
- }
-
- public class UsbManager {
- method @RequiresPermission(android.Manifest.permission.MANAGE_USB) public long getCurrentFunctions();
- method @NonNull @RequiresPermission(android.Manifest.permission.MANAGE_USB) public java.util.List<android.hardware.usb.UsbPort> getPorts();
- method @RequiresPermission(android.Manifest.permission.MANAGE_USB) public void grantPermission(android.hardware.usb.UsbDevice, String);
- method @RequiresPermission(android.Manifest.permission.MANAGE_USB) public void resetUsbGadget();
- method @RequiresPermission(android.Manifest.permission.MANAGE_USB) public void setCurrentFunctions(long);
- field @RequiresPermission(android.Manifest.permission.MANAGE_USB) public static final String ACTION_USB_ACCESSORY_HANDSHAKE = "android.hardware.usb.action.USB_ACCESSORY_HANDSHAKE";
- field @RequiresPermission(android.Manifest.permission.MANAGE_USB) public static final String ACTION_USB_PORT_CHANGED = "android.hardware.usb.action.USB_PORT_CHANGED";
- field public static final String ACTION_USB_STATE = "android.hardware.usb.action.USB_STATE";
- field public static final String EXTRA_ACCESSORY_HANDSHAKE_END = "android.hardware.usb.extra.ACCESSORY_HANDSHAKE_END";
- field public static final String EXTRA_ACCESSORY_START = "android.hardware.usb.extra.ACCESSORY_START";
- field public static final String EXTRA_ACCESSORY_STRING_COUNT = "android.hardware.usb.extra.ACCESSORY_STRING_COUNT";
- field public static final String EXTRA_ACCESSORY_UEVENT_TIME = "android.hardware.usb.extra.ACCESSORY_UEVENT_TIME";
- field public static final long FUNCTION_ACCESSORY = 2L; // 0x2L
- field public static final long FUNCTION_ADB = 1L; // 0x1L
- field public static final long FUNCTION_AUDIO_SOURCE = 64L; // 0x40L
- field public static final long FUNCTION_MIDI = 8L; // 0x8L
- field public static final long FUNCTION_MTP = 4L; // 0x4L
- field public static final long FUNCTION_NCM = 1024L; // 0x400L
- field public static final long FUNCTION_NONE = 0L; // 0x0L
- field public static final long FUNCTION_PTP = 16L; // 0x10L
- field public static final long FUNCTION_RNDIS = 32L; // 0x20L
- field public static final String USB_CONFIGURED = "configured";
- field public static final String USB_CONNECTED = "connected";
- field public static final String USB_FUNCTION_NCM = "ncm";
- field public static final String USB_FUNCTION_RNDIS = "rndis";
- }
-
- public final class UsbPort {
- method @Nullable @RequiresPermission(android.Manifest.permission.MANAGE_USB) public android.hardware.usb.UsbPortStatus getStatus();
- method @RequiresPermission(android.Manifest.permission.MANAGE_USB) public void setRoles(int, int);
- }
-
- public final class UsbPortStatus implements android.os.Parcelable {
- method public int describeContents();
- method public int getCurrentDataRole();
- method public int getCurrentMode();
- method public int getCurrentPowerRole();
- method public int getSupportedRoleCombinations();
- method public boolean isConnected();
- method public boolean isRoleCombinationSupported(int, int);
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.hardware.usb.UsbPortStatus> CREATOR;
- field public static final int DATA_ROLE_DEVICE = 2; // 0x2
- field public static final int DATA_ROLE_HOST = 1; // 0x1
- field public static final int DATA_ROLE_NONE = 0; // 0x0
- field public static final int MODE_AUDIO_ACCESSORY = 4; // 0x4
- field public static final int MODE_DEBUG_ACCESSORY = 8; // 0x8
- field public static final int MODE_DFP = 2; // 0x2
- field public static final int MODE_NONE = 0; // 0x0
- field public static final int MODE_UFP = 1; // 0x1
- field public static final int POWER_ROLE_NONE = 0; // 0x0
- field public static final int POWER_ROLE_SINK = 2; // 0x2
- field public static final int POWER_ROLE_SOURCE = 1; // 0x1
- }
-
-}
-
-package android.location {
-
- public abstract class BatchedLocationCallback {
- ctor public BatchedLocationCallback();
- method public void onLocationBatch(java.util.List<android.location.Location>);
- }
-
- public final class GnssCapabilities {
- method public boolean hasGeofencing();
- method public boolean hasLowPowerMode();
- method public boolean hasMeasurementCorrections();
- method public boolean hasMeasurementCorrectionsExcessPathLength();
- method public boolean hasMeasurementCorrectionsLosSats();
- method public boolean hasMeasurementCorrectionsReflectingPane();
- method public boolean hasMeasurements();
- method public boolean hasNavMessages();
- method @Deprecated public boolean hasSatelliteBlacklist();
- method public boolean hasSatelliteBlocklist();
- }
-
- public final class GnssMeasurementCorrections implements android.os.Parcelable {
- method public int describeContents();
- method @FloatRange(from=-1000.0F, to=10000.0f) public double getAltitudeMeters();
- method @FloatRange(from=0.0f, to=360.0f) public float getEnvironmentBearingDegrees();
- method @FloatRange(from=0.0f, to=180.0f) public float getEnvironmentBearingUncertaintyDegrees();
- method @FloatRange(from=0.0f) public double getHorizontalPositionUncertaintyMeters();
- method @FloatRange(from=-90.0F, to=90.0f) public double getLatitudeDegrees();
- method @FloatRange(from=-180.0F, to=180.0f) public double getLongitudeDegrees();
- method @NonNull public java.util.List<android.location.GnssSingleSatCorrection> getSingleSatelliteCorrectionList();
- method @IntRange(from=0) public long getToaGpsNanosecondsOfWeek();
- method @FloatRange(from=0.0f) public double getVerticalPositionUncertaintyMeters();
- method public boolean hasEnvironmentBearing();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field public static final android.os.Parcelable.Creator<android.location.GnssMeasurementCorrections> CREATOR;
- }
-
- public static final class GnssMeasurementCorrections.Builder {
- ctor public GnssMeasurementCorrections.Builder();
- method @NonNull public android.location.GnssMeasurementCorrections build();
- method @NonNull public android.location.GnssMeasurementCorrections.Builder setAltitudeMeters(@FloatRange(from=-1000.0F, to=10000.0f) double);
- method @NonNull public android.location.GnssMeasurementCorrections.Builder setEnvironmentBearingDegrees(@FloatRange(from=0.0f, to=360.0f) float);
- method @NonNull public android.location.GnssMeasurementCorrections.Builder setEnvironmentBearingUncertaintyDegrees(@FloatRange(from=0.0f, to=180.0f) float);
- method @NonNull public android.location.GnssMeasurementCorrections.Builder setHorizontalPositionUncertaintyMeters(@FloatRange(from=0.0f) double);
- method @NonNull public android.location.GnssMeasurementCorrections.Builder setLatitudeDegrees(@FloatRange(from=-90.0F, to=90.0f) double);
- method @NonNull public android.location.GnssMeasurementCorrections.Builder setLongitudeDegrees(@FloatRange(from=-180.0F, to=180.0f) double);
- method @NonNull public android.location.GnssMeasurementCorrections.Builder setSingleSatelliteCorrectionList(@NonNull java.util.List<android.location.GnssSingleSatCorrection>);
- method @NonNull public android.location.GnssMeasurementCorrections.Builder setToaGpsNanosecondsOfWeek(@IntRange(from=0) long);
- method @NonNull public android.location.GnssMeasurementCorrections.Builder setVerticalPositionUncertaintyMeters(@FloatRange(from=0.0f) double);
- }
-
- public final class GnssReflectingPlane implements android.os.Parcelable {
- method public int describeContents();
- method @FloatRange(from=-1000.0F, to=10000.0f) public double getAltitudeMeters();
- method @FloatRange(from=0.0f, to=360.0f) public double getAzimuthDegrees();
- method @FloatRange(from=-90.0F, to=90.0f) public double getLatitudeDegrees();
- method @FloatRange(from=-180.0F, to=180.0f) public double getLongitudeDegrees();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field public static final android.os.Parcelable.Creator<android.location.GnssReflectingPlane> CREATOR;
- }
-
- public static final class GnssReflectingPlane.Builder {
- ctor public GnssReflectingPlane.Builder();
- method @NonNull public android.location.GnssReflectingPlane build();
- method @NonNull public android.location.GnssReflectingPlane.Builder setAltitudeMeters(@FloatRange(from=-1000.0F, to=10000.0f) double);
- method @NonNull public android.location.GnssReflectingPlane.Builder setAzimuthDegrees(@FloatRange(from=0.0f, to=360.0f) double);
- method @NonNull public android.location.GnssReflectingPlane.Builder setLatitudeDegrees(@FloatRange(from=-90.0F, to=90.0f) double);
- method @NonNull public android.location.GnssReflectingPlane.Builder setLongitudeDegrees(@FloatRange(from=-180.0F, to=180.0f) double);
- }
-
- public final class GnssRequest implements android.os.Parcelable {
- method public int describeContents();
- method public boolean isFullTracking();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.location.GnssRequest> CREATOR;
- }
-
- public static final class GnssRequest.Builder {
- ctor public GnssRequest.Builder();
- ctor public GnssRequest.Builder(@NonNull android.location.GnssRequest);
- method @NonNull public android.location.GnssRequest build();
- method @NonNull public android.location.GnssRequest.Builder setFullTracking(boolean);
- }
-
- public final class GnssSingleSatCorrection implements android.os.Parcelable {
- method public int describeContents();
- method @FloatRange(from=0.0f, fromInclusive=false) public float getCarrierFrequencyHz();
- method public int getConstellationType();
- method @FloatRange(from=0.0f) public float getExcessPathLengthMeters();
- method @FloatRange(from=0.0f) public float getExcessPathLengthUncertaintyMeters();
- method @FloatRange(from=0.0f, to=1.0f) public float getProbabilityLineOfSight();
- method @Nullable public android.location.GnssReflectingPlane getReflectingPlane();
- method @IntRange(from=0) public int getSatelliteId();
- method public boolean hasExcessPathLength();
- method public boolean hasExcessPathLengthUncertainty();
- method public boolean hasReflectingPlane();
- method public boolean hasValidSatelliteLineOfSight();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field public static final android.os.Parcelable.Creator<android.location.GnssSingleSatCorrection> CREATOR;
- }
-
- public static final class GnssSingleSatCorrection.Builder {
- ctor public GnssSingleSatCorrection.Builder();
- method @NonNull public android.location.GnssSingleSatCorrection build();
- method @NonNull public android.location.GnssSingleSatCorrection.Builder setCarrierFrequencyHz(@FloatRange(from=0.0f, fromInclusive=false) float);
- method @NonNull public android.location.GnssSingleSatCorrection.Builder setConstellationType(int);
- method @NonNull public android.location.GnssSingleSatCorrection.Builder setExcessPathLengthMeters(@FloatRange(from=0.0f) float);
- method @NonNull public android.location.GnssSingleSatCorrection.Builder setExcessPathLengthUncertaintyMeters(@FloatRange(from=0.0f) float);
- method @NonNull public android.location.GnssSingleSatCorrection.Builder setProbabilityLineOfSight(@FloatRange(from=0.0f, to=1.0f) float);
- method @NonNull public android.location.GnssSingleSatCorrection.Builder setReflectingPlane(@Nullable android.location.GnssReflectingPlane);
- method @NonNull public android.location.GnssSingleSatCorrection.Builder setSatelliteId(@IntRange(from=0) int);
- }
-
- @Deprecated public class GpsClock implements android.os.Parcelable {
- method @Deprecated public int describeContents();
- method @Deprecated public double getBiasInNs();
- method @Deprecated public double getBiasUncertaintyInNs();
- method @Deprecated public double getDriftInNsPerSec();
- method @Deprecated public double getDriftUncertaintyInNsPerSec();
- method @Deprecated public long getFullBiasInNs();
- method @Deprecated public short getLeapSecond();
- method @Deprecated public long getTimeInNs();
- method @Deprecated public double getTimeUncertaintyInNs();
- method @Deprecated public byte getType();
- method @Deprecated public boolean hasBiasInNs();
- method @Deprecated public boolean hasBiasUncertaintyInNs();
- method @Deprecated public boolean hasDriftInNsPerSec();
- method @Deprecated public boolean hasDriftUncertaintyInNsPerSec();
- method @Deprecated public boolean hasFullBiasInNs();
- method @Deprecated public boolean hasLeapSecond();
- method @Deprecated public boolean hasTimeUncertaintyInNs();
- method @Deprecated public void reset();
- method @Deprecated public void resetBiasInNs();
- method @Deprecated public void resetBiasUncertaintyInNs();
- method @Deprecated public void resetDriftInNsPerSec();
- method @Deprecated public void resetDriftUncertaintyInNsPerSec();
- method @Deprecated public void resetFullBiasInNs();
- method @Deprecated public void resetLeapSecond();
- method @Deprecated public void resetTimeUncertaintyInNs();
- method @Deprecated public void set(android.location.GpsClock);
- method @Deprecated public void setBiasInNs(double);
- method @Deprecated public void setBiasUncertaintyInNs(double);
- method @Deprecated public void setDriftInNsPerSec(double);
- method @Deprecated public void setDriftUncertaintyInNsPerSec(double);
- method @Deprecated public void setFullBiasInNs(long);
- method @Deprecated public void setLeapSecond(short);
- method @Deprecated public void setTimeInNs(long);
- method @Deprecated public void setTimeUncertaintyInNs(double);
- method @Deprecated public void setType(byte);
- method @Deprecated public void writeToParcel(android.os.Parcel, int);
- field @Deprecated @NonNull public static final android.os.Parcelable.Creator<android.location.GpsClock> CREATOR;
- field @Deprecated public static final byte TYPE_GPS_TIME = 2; // 0x2
- field @Deprecated public static final byte TYPE_LOCAL_HW_TIME = 1; // 0x1
- field @Deprecated public static final byte TYPE_UNKNOWN = 0; // 0x0
- }
-
- @Deprecated public class GpsMeasurement implements android.os.Parcelable {
- method @Deprecated public int describeContents();
- method @Deprecated public double getAccumulatedDeltaRangeInMeters();
- method @Deprecated public short getAccumulatedDeltaRangeState();
- method @Deprecated public double getAccumulatedDeltaRangeUncertaintyInMeters();
- method @Deprecated public double getAzimuthInDeg();
- method @Deprecated public double getAzimuthUncertaintyInDeg();
- method @Deprecated public int getBitNumber();
- method @Deprecated public long getCarrierCycles();
- method @Deprecated public float getCarrierFrequencyInHz();
- method @Deprecated public double getCarrierPhase();
- method @Deprecated public double getCarrierPhaseUncertainty();
- method @Deprecated public double getCn0InDbHz();
- method @Deprecated public double getCodePhaseInChips();
- method @Deprecated public double getCodePhaseUncertaintyInChips();
- method @Deprecated public double getDopplerShiftInHz();
- method @Deprecated public double getDopplerShiftUncertaintyInHz();
- method @Deprecated public double getElevationInDeg();
- method @Deprecated public double getElevationUncertaintyInDeg();
- method @Deprecated public byte getLossOfLock();
- method @Deprecated public byte getMultipathIndicator();
- method @Deprecated public byte getPrn();
- method @Deprecated public double getPseudorangeInMeters();
- method @Deprecated public double getPseudorangeRateInMetersPerSec();
- method @Deprecated public double getPseudorangeRateUncertaintyInMetersPerSec();
- method @Deprecated public double getPseudorangeUncertaintyInMeters();
- method @Deprecated public long getReceivedGpsTowInNs();
- method @Deprecated public long getReceivedGpsTowUncertaintyInNs();
- method @Deprecated public double getSnrInDb();
- method @Deprecated public short getState();
- method @Deprecated public short getTimeFromLastBitInMs();
- method @Deprecated public double getTimeOffsetInNs();
- method @Deprecated public boolean hasAzimuthInDeg();
- method @Deprecated public boolean hasAzimuthUncertaintyInDeg();
- method @Deprecated public boolean hasBitNumber();
- method @Deprecated public boolean hasCarrierCycles();
- method @Deprecated public boolean hasCarrierFrequencyInHz();
- method @Deprecated public boolean hasCarrierPhase();
- method @Deprecated public boolean hasCarrierPhaseUncertainty();
- method @Deprecated public boolean hasCodePhaseInChips();
- method @Deprecated public boolean hasCodePhaseUncertaintyInChips();
- method @Deprecated public boolean hasDopplerShiftInHz();
- method @Deprecated public boolean hasDopplerShiftUncertaintyInHz();
- method @Deprecated public boolean hasElevationInDeg();
- method @Deprecated public boolean hasElevationUncertaintyInDeg();
- method @Deprecated public boolean hasPseudorangeInMeters();
- method @Deprecated public boolean hasPseudorangeUncertaintyInMeters();
- method @Deprecated public boolean hasSnrInDb();
- method @Deprecated public boolean hasTimeFromLastBitInMs();
- method @Deprecated public boolean isPseudorangeRateCorrected();
- method @Deprecated public boolean isUsedInFix();
- method @Deprecated public void reset();
- method @Deprecated public void resetAzimuthInDeg();
- method @Deprecated public void resetAzimuthUncertaintyInDeg();
- method @Deprecated public void resetBitNumber();
- method @Deprecated public void resetCarrierCycles();
- method @Deprecated public void resetCarrierFrequencyInHz();
- method @Deprecated public void resetCarrierPhase();
- method @Deprecated public void resetCarrierPhaseUncertainty();
- method @Deprecated public void resetCodePhaseInChips();
- method @Deprecated public void resetCodePhaseUncertaintyInChips();
- method @Deprecated public void resetDopplerShiftInHz();
- method @Deprecated public void resetDopplerShiftUncertaintyInHz();
- method @Deprecated public void resetElevationInDeg();
- method @Deprecated public void resetElevationUncertaintyInDeg();
- method @Deprecated public void resetPseudorangeInMeters();
- method @Deprecated public void resetPseudorangeUncertaintyInMeters();
- method @Deprecated public void resetSnrInDb();
- method @Deprecated public void resetTimeFromLastBitInMs();
- method @Deprecated public void set(android.location.GpsMeasurement);
- method @Deprecated public void setAccumulatedDeltaRangeInMeters(double);
- method @Deprecated public void setAccumulatedDeltaRangeState(short);
- method @Deprecated public void setAccumulatedDeltaRangeUncertaintyInMeters(double);
- method @Deprecated public void setAzimuthInDeg(double);
- method @Deprecated public void setAzimuthUncertaintyInDeg(double);
- method @Deprecated public void setBitNumber(int);
- method @Deprecated public void setCarrierCycles(long);
- method @Deprecated public void setCarrierFrequencyInHz(float);
- method @Deprecated public void setCarrierPhase(double);
- method @Deprecated public void setCarrierPhaseUncertainty(double);
- method @Deprecated public void setCn0InDbHz(double);
- method @Deprecated public void setCodePhaseInChips(double);
- method @Deprecated public void setCodePhaseUncertaintyInChips(double);
- method @Deprecated public void setDopplerShiftInHz(double);
- method @Deprecated public void setDopplerShiftUncertaintyInHz(double);
- method @Deprecated public void setElevationInDeg(double);
- method @Deprecated public void setElevationUncertaintyInDeg(double);
- method @Deprecated public void setLossOfLock(byte);
- method @Deprecated public void setMultipathIndicator(byte);
- method @Deprecated public void setPrn(byte);
- method @Deprecated public void setPseudorangeInMeters(double);
- method @Deprecated public void setPseudorangeRateInMetersPerSec(double);
- method @Deprecated public void setPseudorangeRateUncertaintyInMetersPerSec(double);
- method @Deprecated public void setPseudorangeUncertaintyInMeters(double);
- method @Deprecated public void setReceivedGpsTowInNs(long);
- method @Deprecated public void setReceivedGpsTowUncertaintyInNs(long);
- method @Deprecated public void setSnrInDb(double);
- method @Deprecated public void setState(short);
- method @Deprecated public void setTimeFromLastBitInMs(short);
- method @Deprecated public void setTimeOffsetInNs(double);
- method @Deprecated public void setUsedInFix(boolean);
- method @Deprecated public void writeToParcel(android.os.Parcel, int);
- field @Deprecated public static final short ADR_STATE_CYCLE_SLIP = 4; // 0x4
- field @Deprecated public static final short ADR_STATE_RESET = 2; // 0x2
- field @Deprecated public static final short ADR_STATE_UNKNOWN = 0; // 0x0
- field @Deprecated public static final short ADR_STATE_VALID = 1; // 0x1
- field @Deprecated @NonNull public static final android.os.Parcelable.Creator<android.location.GpsMeasurement> CREATOR;
- field @Deprecated public static final byte LOSS_OF_LOCK_CYCLE_SLIP = 2; // 0x2
- field @Deprecated public static final byte LOSS_OF_LOCK_OK = 1; // 0x1
- field @Deprecated public static final byte LOSS_OF_LOCK_UNKNOWN = 0; // 0x0
- field @Deprecated public static final byte MULTIPATH_INDICATOR_DETECTED = 1; // 0x1
- field @Deprecated public static final byte MULTIPATH_INDICATOR_NOT_USED = 2; // 0x2
- field @Deprecated public static final byte MULTIPATH_INDICATOR_UNKNOWN = 0; // 0x0
- field @Deprecated public static final short STATE_BIT_SYNC = 2; // 0x2
- field @Deprecated public static final short STATE_CODE_LOCK = 1; // 0x1
- field @Deprecated public static final short STATE_MSEC_AMBIGUOUS = 16; // 0x10
- field @Deprecated public static final short STATE_SUBFRAME_SYNC = 4; // 0x4
- field @Deprecated public static final short STATE_TOW_DECODED = 8; // 0x8
- field @Deprecated public static final short STATE_UNKNOWN = 0; // 0x0
- }
-
- @Deprecated public class GpsMeasurementsEvent implements android.os.Parcelable {
- ctor @Deprecated public GpsMeasurementsEvent(android.location.GpsClock, android.location.GpsMeasurement[]);
- method @Deprecated public int describeContents();
- method @Deprecated @NonNull public android.location.GpsClock getClock();
- method @Deprecated @NonNull public java.util.Collection<android.location.GpsMeasurement> getMeasurements();
- method @Deprecated public void writeToParcel(android.os.Parcel, int);
- field @Deprecated @NonNull public static final android.os.Parcelable.Creator<android.location.GpsMeasurementsEvent> CREATOR;
- field @Deprecated public static final int STATUS_GPS_LOCATION_DISABLED = 2; // 0x2
- field @Deprecated public static final int STATUS_NOT_SUPPORTED = 0; // 0x0
- field @Deprecated public static final int STATUS_READY = 1; // 0x1
- }
-
- @Deprecated public static interface GpsMeasurementsEvent.Listener {
- method @Deprecated public void onGpsMeasurementsReceived(android.location.GpsMeasurementsEvent);
- method @Deprecated public void onStatusChanged(int);
- }
-
- @Deprecated public class GpsNavigationMessage implements android.os.Parcelable {
- method @Deprecated public int describeContents();
- method @Deprecated @NonNull public byte[] getData();
- method @Deprecated public short getMessageId();
- method @Deprecated public byte getPrn();
- method @Deprecated public short getStatus();
- method @Deprecated public short getSubmessageId();
- method @Deprecated public byte getType();
- method @Deprecated public void reset();
- method @Deprecated public void set(android.location.GpsNavigationMessage);
- method @Deprecated public void setData(byte[]);
- method @Deprecated public void setMessageId(short);
- method @Deprecated public void setPrn(byte);
- method @Deprecated public void setStatus(short);
- method @Deprecated public void setSubmessageId(short);
- method @Deprecated public void setType(byte);
- method @Deprecated public void writeToParcel(android.os.Parcel, int);
- field @Deprecated @NonNull public static final android.os.Parcelable.Creator<android.location.GpsNavigationMessage> CREATOR;
- field @Deprecated public static final short STATUS_PARITY_PASSED = 1; // 0x1
- field @Deprecated public static final short STATUS_PARITY_REBUILT = 2; // 0x2
- field @Deprecated public static final short STATUS_UNKNOWN = 0; // 0x0
- field @Deprecated public static final byte TYPE_CNAV2 = 4; // 0x4
- field @Deprecated public static final byte TYPE_L1CA = 1; // 0x1
- field @Deprecated public static final byte TYPE_L2CNAV = 2; // 0x2
- field @Deprecated public static final byte TYPE_L5CNAV = 3; // 0x3
- field @Deprecated public static final byte TYPE_UNKNOWN = 0; // 0x0
- }
-
- @Deprecated public class GpsNavigationMessageEvent implements android.os.Parcelable {
- ctor @Deprecated public GpsNavigationMessageEvent(android.location.GpsNavigationMessage);
- method @Deprecated public int describeContents();
- method @Deprecated @NonNull public android.location.GpsNavigationMessage getNavigationMessage();
- method @Deprecated public void writeToParcel(android.os.Parcel, int);
- field @Deprecated @NonNull public static final android.os.Parcelable.Creator<android.location.GpsNavigationMessageEvent> CREATOR;
- field @Deprecated public static int STATUS_GPS_LOCATION_DISABLED;
- field @Deprecated public static int STATUS_NOT_SUPPORTED;
- field @Deprecated public static int STATUS_READY;
- }
-
- @Deprecated public static interface GpsNavigationMessageEvent.Listener {
- method @Deprecated public void onGpsNavigationMessageReceived(android.location.GpsNavigationMessageEvent);
- method @Deprecated public void onStatusChanged(int);
- }
-
- public class Location implements android.os.Parcelable {
- method public boolean isComplete();
- method public void makeComplete();
- method public void setIsFromMockProvider(boolean);
- field @Deprecated public static final String EXTRA_NO_GPS_LOCATION = "noGPSLocation";
- }
-
- public class LocationManager {
- method @Deprecated @RequiresPermission(android.Manifest.permission.LOCATION_HARDWARE) public void flushGnssBatch();
- method @Deprecated @RequiresPermission(anyOf={android.Manifest.permission.ACCESS_COARSE_LOCATION, android.Manifest.permission.ACCESS_FINE_LOCATION}) public void getCurrentLocation(@NonNull android.location.LocationRequest, @Nullable android.os.CancellationSignal, @NonNull java.util.concurrent.Executor, @NonNull java.util.function.Consumer<android.location.Location>);
- method @Nullable public String getExtraLocationControllerPackage();
- method @Deprecated public int getGnssBatchSize();
- method @RequiresPermission(android.Manifest.permission.ACCESS_FINE_LOCATION) public void injectGnssMeasurementCorrections(@NonNull android.location.GnssMeasurementCorrections);
- method public boolean isExtraLocationControllerPackageEnabled();
- method public boolean isLocationEnabledForUser(@NonNull android.os.UserHandle);
- method public boolean isProviderEnabledForUser(@NonNull String, @NonNull android.os.UserHandle);
- method @Deprecated @RequiresPermission(android.Manifest.permission.READ_DEVICE_CONFIG) public boolean isProviderPackage(@NonNull String);
- method @RequiresPermission(android.Manifest.permission.READ_DEVICE_CONFIG) public boolean isProviderPackage(@Nullable String, @NonNull String);
- method @Deprecated @RequiresPermission(allOf={android.Manifest.permission.LOCATION_HARDWARE, android.Manifest.permission.UPDATE_APP_OPS_STATS}) public boolean registerGnssBatchedLocationCallback(long, boolean, @NonNull android.location.BatchedLocationCallback, @Nullable android.os.Handler);
- method @RequiresPermission(allOf={android.Manifest.permission.ACCESS_FINE_LOCATION, android.Manifest.permission.LOCATION_HARDWARE}) public boolean registerGnssMeasurementsCallback(@NonNull android.location.GnssRequest, @NonNull java.util.concurrent.Executor, @NonNull android.location.GnssMeasurementsEvent.Callback);
- method @Deprecated @RequiresPermission(anyOf={android.Manifest.permission.ACCESS_COARSE_LOCATION, android.Manifest.permission.ACCESS_FINE_LOCATION}) public void requestLocationUpdates(@Nullable android.location.LocationRequest, @NonNull android.location.LocationListener, @Nullable android.os.Looper);
- method @Deprecated @RequiresPermission(anyOf={android.Manifest.permission.ACCESS_COARSE_LOCATION, android.Manifest.permission.ACCESS_FINE_LOCATION}) public void requestLocationUpdates(@Nullable android.location.LocationRequest, @NonNull java.util.concurrent.Executor, @NonNull android.location.LocationListener);
- method @Deprecated @RequiresPermission(anyOf={android.Manifest.permission.ACCESS_COARSE_LOCATION, android.Manifest.permission.ACCESS_FINE_LOCATION}) public void requestLocationUpdates(@Nullable android.location.LocationRequest, @NonNull android.app.PendingIntent);
- method @RequiresPermission(android.Manifest.permission.LOCATION_HARDWARE) public void setExtraLocationControllerPackage(@Nullable String);
- method @RequiresPermission(android.Manifest.permission.LOCATION_HARDWARE) public void setExtraLocationControllerPackageEnabled(boolean);
- method @RequiresPermission(android.Manifest.permission.WRITE_SECURE_SETTINGS) public void setLocationEnabledForUser(boolean, @NonNull android.os.UserHandle);
- method @Deprecated @RequiresPermission(android.Manifest.permission.WRITE_SECURE_SETTINGS) public boolean setProviderEnabledForUser(@NonNull String, boolean, @NonNull android.os.UserHandle);
- method @Deprecated @RequiresPermission(android.Manifest.permission.LOCATION_HARDWARE) public boolean unregisterGnssBatchedLocationCallback(@NonNull android.location.BatchedLocationCallback);
- field public static final String FUSED_PROVIDER = "fused";
- }
-
- public final class LocationRequest implements android.os.Parcelable {
- method @Deprecated @NonNull public static android.location.LocationRequest create();
- method @Deprecated @NonNull public static android.location.LocationRequest createFromDeprecatedCriteria(@NonNull android.location.Criteria, long, float, boolean);
- method @Deprecated @NonNull public static android.location.LocationRequest createFromDeprecatedProvider(@NonNull String, long, float, boolean);
- method @Deprecated public long getExpireAt();
- method @Deprecated public long getExpireIn();
- method @Deprecated public long getFastestInterval();
- method @Deprecated public boolean getHideFromAppOps();
- method @Deprecated public long getInterval();
- method @Deprecated public int getNumUpdates();
- method @Deprecated @NonNull public String getProvider();
- method @Deprecated public float getSmallestDisplacement();
- method @NonNull public android.os.WorkSource getWorkSource();
- method public boolean isHiddenFromAppOps();
- method public boolean isLocationSettingsIgnored();
- method public boolean isLowPower();
- method @Deprecated public boolean isLowPowerMode();
- method @Deprecated @NonNull public android.location.LocationRequest setExpireAt(long);
- method @Deprecated @NonNull public android.location.LocationRequest setExpireIn(long);
- method @Deprecated @NonNull public android.location.LocationRequest setFastestInterval(long);
- method @Deprecated public void setHideFromAppOps(boolean);
- method @Deprecated @NonNull public android.location.LocationRequest setInterval(long);
- method @Deprecated @NonNull @RequiresPermission(android.Manifest.permission.WRITE_SECURE_SETTINGS) public android.location.LocationRequest setLocationSettingsIgnored(boolean);
- method @Deprecated @NonNull public android.location.LocationRequest setLowPowerMode(boolean);
- method @Deprecated @NonNull public android.location.LocationRequest setNumUpdates(int);
- method @Deprecated @NonNull public android.location.LocationRequest setProvider(@NonNull String);
- method @Deprecated @NonNull public android.location.LocationRequest setQuality(int);
- method @Deprecated @NonNull public android.location.LocationRequest setSmallestDisplacement(float);
- method @Deprecated public void setWorkSource(@Nullable android.os.WorkSource);
- field @Deprecated public static final int ACCURACY_BLOCK = 102; // 0x66
- field @Deprecated public static final int ACCURACY_CITY = 104; // 0x68
- field @Deprecated public static final int ACCURACY_FINE = 100; // 0x64
- field @Deprecated public static final int POWER_HIGH = 203; // 0xcb
- field @Deprecated public static final int POWER_LOW = 201; // 0xc9
- field @Deprecated public static final int POWER_NONE = 200; // 0xc8
- }
-
- public static final class LocationRequest.Builder {
- method @NonNull @RequiresPermission(android.Manifest.permission.UPDATE_APP_OPS_STATS) public android.location.LocationRequest.Builder setHiddenFromAppOps(boolean);
- method @NonNull @RequiresPermission(android.Manifest.permission.WRITE_SECURE_SETTINGS) public android.location.LocationRequest.Builder setLocationSettingsIgnored(boolean);
- method @NonNull @RequiresPermission(android.Manifest.permission.LOCATION_HARDWARE) public android.location.LocationRequest.Builder setLowPower(boolean);
- method @NonNull @RequiresPermission(android.Manifest.permission.UPDATE_DEVICE_STATS) public android.location.LocationRequest.Builder setWorkSource(@Nullable android.os.WorkSource);
- }
-
- public final class LocationResult implements android.os.Parcelable {
- method @NonNull public static android.location.LocationResult wrap(@NonNull android.location.Location);
- }
-
-}
-
-package android.media {
-
- public final class AudioAttributes implements android.os.Parcelable {
- method public int getAllFlags();
- method public android.os.Bundle getBundle();
- method public int getCapturePreset();
- method public int getSystemUsage();
- method public static boolean isSystemUsage(int);
- field public static final int FLAG_BEACON = 8; // 0x8
- field public static final int FLAG_BYPASS_INTERRUPTION_POLICY = 64; // 0x40
- field public static final int FLAG_BYPASS_MUTE = 128; // 0x80
- field public static final int FLAG_HW_HOTWORD = 32; // 0x20
- field @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public static final int USAGE_ANNOUNCEMENT = 1003; // 0x3eb
- field @RequiresPermission(allOf={android.Manifest.permission.MODIFY_PHONE_STATE, android.Manifest.permission.MODIFY_AUDIO_ROUTING}) public static final int USAGE_CALL_ASSISTANT = 17; // 0x11
- field @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public static final int USAGE_EMERGENCY = 1000; // 0x3e8
- field @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public static final int USAGE_SAFETY = 1001; // 0x3e9
- field @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public static final int USAGE_VEHICLE_STATUS = 1002; // 0x3ea
- }
-
- public static class AudioAttributes.Builder {
- method public android.media.AudioAttributes.Builder addBundle(@NonNull android.os.Bundle);
- method public android.media.AudioAttributes.Builder setCapturePreset(int);
- method public android.media.AudioAttributes.Builder setInternalCapturePreset(int);
- method @NonNull @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public android.media.AudioAttributes.Builder setSystemUsage(int);
- }
-
- public final class AudioDeviceAttributes implements android.os.Parcelable {
- ctor public AudioDeviceAttributes(@NonNull android.media.AudioDeviceInfo);
- ctor public AudioDeviceAttributes(int, int, @NonNull String);
- method public int describeContents();
- method @NonNull public String getAddress();
- method public int getRole();
- method public int getType();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.media.AudioDeviceAttributes> CREATOR;
- field public static final int ROLE_INPUT = 1; // 0x1
- field public static final int ROLE_OUTPUT = 2; // 0x2
- }
-
- public final class AudioFocusInfo implements android.os.Parcelable {
- method public int describeContents();
- method @NonNull public android.media.AudioAttributes getAttributes();
- method @NonNull public String getClientId();
- method public int getClientUid();
- method public int getFlags();
- method public int getGainRequest();
- method public int getLossReceived();
- method @NonNull public String getPackageName();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.media.AudioFocusInfo> CREATOR;
- }
-
- public final class AudioFocusRequest {
- method public boolean locksFocus();
- }
-
- public static final class AudioFocusRequest.Builder {
- method @NonNull public android.media.AudioFocusRequest.Builder setLocksFocus(boolean);
- }
-
- public class AudioManager {
- method @Deprecated public int abandonAudioFocus(android.media.AudioManager.OnAudioFocusChangeListener, android.media.AudioAttributes);
- method @Deprecated @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public void addOnPreferredDeviceForStrategyChangedListener(@NonNull java.util.concurrent.Executor, @NonNull android.media.AudioManager.OnPreferredDeviceForStrategyChangedListener) throws java.lang.SecurityException;
- method @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public void addOnPreferredDevicesForCapturePresetChangedListener(@NonNull java.util.concurrent.Executor, @NonNull android.media.AudioManager.OnPreferredDevicesForCapturePresetChangedListener) throws java.lang.SecurityException;
- method @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public void addOnPreferredDevicesForStrategyChangedListener(@NonNull java.util.concurrent.Executor, @NonNull android.media.AudioManager.OnPreferredDevicesForStrategyChangedListener) throws java.lang.SecurityException;
- method public void clearAudioServerStateCallback();
- method @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public boolean clearPreferredDevicesForCapturePreset(int);
- method @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public int dispatchAudioFocusChange(@NonNull android.media.AudioFocusInfo, int, @NonNull android.media.audiopolicy.AudioPolicy);
- method @IntRange(from=0) public long getAdditionalOutputDeviceDelay(@NonNull android.media.AudioDeviceInfo);
- method @NonNull @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public static java.util.List<android.media.audiopolicy.AudioProductStrategy> getAudioProductStrategies();
- method @NonNull @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public static java.util.List<android.media.audiopolicy.AudioVolumeGroup> getAudioVolumeGroups();
- method @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public int getDeviceVolumeBehavior(@NonNull android.media.AudioDeviceAttributes);
- method @NonNull @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public java.util.List<android.media.AudioDeviceAttributes> getDevicesForAttributes(@NonNull android.media.AudioAttributes);
- method @IntRange(from=0) public long getMaxAdditionalOutputDeviceDelay(@NonNull android.media.AudioDeviceInfo);
- method @IntRange(from=0) @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public int getMaxVolumeIndexForAttributes(@NonNull android.media.AudioAttributes);
- method @IntRange(from=0) @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public int getMinVolumeIndexForAttributes(@NonNull android.media.AudioAttributes);
- method @Nullable @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public android.media.AudioDeviceAttributes getPreferredDeviceForStrategy(@NonNull android.media.audiopolicy.AudioProductStrategy);
- method @NonNull @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public java.util.List<android.media.AudioDeviceAttributes> getPreferredDevicesForCapturePreset(int);
- method @NonNull @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public java.util.List<android.media.AudioDeviceAttributes> getPreferredDevicesForStrategy(@NonNull android.media.audiopolicy.AudioProductStrategy);
- method @NonNull @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public int[] getSupportedSystemUsages();
- method @IntRange(from=0) @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public int getVolumeIndexForAttributes(@NonNull android.media.AudioAttributes);
- method public boolean isAudioServerRunning();
- method public boolean isHdmiSystemAudioSupported();
- method @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public int registerAudioPolicy(@NonNull android.media.audiopolicy.AudioPolicy);
- method public void registerVolumeGroupCallback(@NonNull java.util.concurrent.Executor, @NonNull android.media.AudioManager.VolumeGroupCallback);
- method @Deprecated @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public void removeOnPreferredDeviceForStrategyChangedListener(@NonNull android.media.AudioManager.OnPreferredDeviceForStrategyChangedListener);
- method @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public void removeOnPreferredDevicesForCapturePresetChangedListener(@NonNull android.media.AudioManager.OnPreferredDevicesForCapturePresetChangedListener);
- method @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public void removeOnPreferredDevicesForStrategyChangedListener(@NonNull android.media.AudioManager.OnPreferredDevicesForStrategyChangedListener);
- method @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public boolean removePreferredDeviceForStrategy(@NonNull android.media.audiopolicy.AudioProductStrategy);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public int requestAudioFocus(android.media.AudioManager.OnAudioFocusChangeListener, @NonNull android.media.AudioAttributes, int, int) throws java.lang.IllegalArgumentException;
- method @Deprecated @RequiresPermission(anyOf={android.Manifest.permission.MODIFY_PHONE_STATE, android.Manifest.permission.MODIFY_AUDIO_ROUTING}) public int requestAudioFocus(android.media.AudioManager.OnAudioFocusChangeListener, @NonNull android.media.AudioAttributes, int, int, android.media.audiopolicy.AudioPolicy) throws java.lang.IllegalArgumentException;
- method @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public int requestAudioFocus(@NonNull android.media.AudioFocusRequest, @Nullable android.media.audiopolicy.AudioPolicy);
- method @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public boolean setAdditionalOutputDeviceDelay(@NonNull android.media.AudioDeviceInfo, @IntRange(from=0) long);
- method public void setAudioServerStateCallback(@NonNull java.util.concurrent.Executor, @NonNull android.media.AudioManager.AudioServerStateCallback);
- method @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public void setDeviceVolumeBehavior(@NonNull android.media.AudioDeviceAttributes, int);
- method @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public void setFocusRequestResult(@NonNull android.media.AudioFocusInfo, int, @NonNull android.media.audiopolicy.AudioPolicy);
- method @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public boolean setPreferredDeviceForCapturePreset(int, @NonNull android.media.AudioDeviceAttributes);
- method @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public boolean setPreferredDeviceForStrategy(@NonNull android.media.audiopolicy.AudioProductStrategy, @NonNull android.media.AudioDeviceAttributes);
- method @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public boolean setPreferredDevicesForStrategy(@NonNull android.media.audiopolicy.AudioProductStrategy, @NonNull java.util.List<android.media.AudioDeviceAttributes>);
- method @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public void setSupportedSystemUsages(@NonNull int[]);
- method @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public void setVolumeIndexForAttributes(@NonNull android.media.AudioAttributes, int, int);
- method @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public void unregisterAudioPolicy(@NonNull android.media.audiopolicy.AudioPolicy);
- method @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public void unregisterAudioPolicyAsync(@NonNull android.media.audiopolicy.AudioPolicy);
- method public void unregisterVolumeGroupCallback(@NonNull android.media.AudioManager.VolumeGroupCallback);
- field public static final int AUDIOFOCUS_FLAG_DELAY_OK = 1; // 0x1
- field public static final int AUDIOFOCUS_FLAG_LOCK = 4; // 0x4
- field public static final int AUDIOFOCUS_FLAG_PAUSES_ON_DUCKABLE_LOSS = 2; // 0x2
- field public static final int DEVICE_VOLUME_BEHAVIOR_ABSOLUTE = 3; // 0x3
- field public static final int DEVICE_VOLUME_BEHAVIOR_ABSOLUTE_MULTI_MODE = 4; // 0x4
- field public static final int DEVICE_VOLUME_BEHAVIOR_FIXED = 2; // 0x2
- field public static final int DEVICE_VOLUME_BEHAVIOR_FULL = 1; // 0x1
- field public static final int DEVICE_VOLUME_BEHAVIOR_VARIABLE = 0; // 0x0
- field @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public static final int STREAM_ASSISTANT = 11; // 0xb
- field public static final int SUCCESS = 0; // 0x0
- }
-
- public abstract static class AudioManager.AudioServerStateCallback {
- ctor public AudioManager.AudioServerStateCallback();
- method public void onAudioServerDown();
- method public void onAudioServerUp();
- }
-
- @Deprecated public static interface AudioManager.OnPreferredDeviceForStrategyChangedListener {
- method @Deprecated public void onPreferredDeviceForStrategyChanged(@NonNull android.media.audiopolicy.AudioProductStrategy, @Nullable android.media.AudioDeviceAttributes);
- }
-
- public static interface AudioManager.OnPreferredDevicesForCapturePresetChangedListener {
- method public void onPreferredDevicesForCapturePresetChanged(int, @NonNull java.util.List<android.media.AudioDeviceAttributes>);
- }
-
- public static interface AudioManager.OnPreferredDevicesForStrategyChangedListener {
- method public void onPreferredDevicesForStrategyChanged(@NonNull android.media.audiopolicy.AudioProductStrategy, @NonNull java.util.List<android.media.AudioDeviceAttributes>);
- }
-
- public abstract static class AudioManager.VolumeGroupCallback {
- ctor public AudioManager.VolumeGroupCallback();
- method public void onAudioVolumeGroupChanged(int, int);
- }
-
- public final class AudioPlaybackConfiguration implements android.os.Parcelable {
- method public int getClientPid();
- method public int getClientUid();
- method public int getPlayerInterfaceId();
- method public android.media.PlayerProxy getPlayerProxy();
- method public int getPlayerState();
- method public int getPlayerType();
- method public boolean isActive();
- field public static final int PLAYER_STATE_IDLE = 1; // 0x1
- field public static final int PLAYER_STATE_PAUSED = 3; // 0x3
- field public static final int PLAYER_STATE_RELEASED = 0; // 0x0
- field public static final int PLAYER_STATE_STARTED = 2; // 0x2
- field public static final int PLAYER_STATE_STOPPED = 4; // 0x4
- field public static final int PLAYER_STATE_UNKNOWN = -1; // 0xffffffff
- field public static final int PLAYER_TYPE_JAM_AUDIOTRACK = 1; // 0x1
- field public static final int PLAYER_TYPE_JAM_MEDIAPLAYER = 2; // 0x2
- field public static final int PLAYER_TYPE_JAM_SOUNDPOOL = 3; // 0x3
- field public static final int PLAYER_TYPE_SLES_AUDIOPLAYER_BUFFERQUEUE = 11; // 0xb
- field public static final int PLAYER_TYPE_SLES_AUDIOPLAYER_URI_FD = 12; // 0xc
- field public static final int PLAYER_TYPE_UNKNOWN = -1; // 0xffffffff
- }
-
- public class AudioRecord implements android.media.AudioRecordingMonitor android.media.AudioRouting android.media.MicrophoneDirection {
- ctor public AudioRecord(android.media.AudioAttributes, android.media.AudioFormat, int, int) throws java.lang.IllegalArgumentException;
- }
-
- public static class AudioRecord.Builder {
- method public android.media.AudioRecord.Builder setAudioAttributes(@NonNull android.media.AudioAttributes) throws java.lang.IllegalArgumentException;
- method public android.media.AudioRecord.Builder setSessionId(int) throws java.lang.IllegalArgumentException;
- }
-
- public final class AudioRecordingConfiguration implements android.os.Parcelable {
- method @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public int getClientUid();
- }
-
- public class AudioTrack implements android.media.AudioRouting android.media.VolumeAutomation {
- field @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public static final int ENCAPSULATION_MODE_HANDLE = 2; // 0x2
- }
-
- public static class AudioTrack.Builder {
- method @NonNull @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public android.media.AudioTrack.Builder setTunerConfiguration(@NonNull android.media.AudioTrack.TunerConfiguration);
- }
-
- public static class AudioTrack.TunerConfiguration {
- ctor @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public AudioTrack.TunerConfiguration(@IntRange(from=1) int, @IntRange(from=1) int);
- method @IntRange(from=1) @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public int getContentId();
- method @IntRange(from=1) @RequiresPermission(android.Manifest.permission.MODIFY_AUDIO_ROUTING) public int getSyncId();
- }
-
- public class HwAudioSource {
- method public boolean isPlaying();
- method public void start();
- method public void stop();
- }
-
- public static final class HwAudioSource.Builder {
- ctor public HwAudioSource.Builder();
- method @NonNull public android.media.HwAudioSource build();
- method @NonNull public android.media.HwAudioSource.Builder setAudioAttributes(@NonNull android.media.AudioAttributes);
- method @NonNull public android.media.HwAudioSource.Builder setAudioDeviceInfo(@NonNull android.media.AudioDeviceInfo);
- }
-
- public class MediaPlayer implements android.media.AudioRouting android.media.VolumeAutomation {
- method @RequiresPermission("android.permission.BIND_IMS_SERVICE") public void setOnRtpRxNoticeListener(@NonNull android.content.Context, @NonNull android.media.MediaPlayer.OnRtpRxNoticeListener, @Nullable android.os.Handler);
- }
-
- public static interface MediaPlayer.OnRtpRxNoticeListener {
- method public void onRtpRxNotice(@NonNull android.media.MediaPlayer, int, @NonNull int[]);
- }
-
- public final class MediaRecorder.AudioSource {
- field @RequiresPermission(android.Manifest.permission.CAPTURE_AUDIO_OUTPUT) public static final int ECHO_REFERENCE = 1997; // 0x7cd
- field @RequiresPermission(android.Manifest.permission.CAPTURE_AUDIO_HOTWORD) public static final int HOTWORD = 1999; // 0x7cf
- field @RequiresPermission(android.Manifest.permission.CAPTURE_AUDIO_OUTPUT) public static final int RADIO_TUNER = 1998; // 0x7ce
- }
-
- public final class MediaTranscodeManager {
- method @NonNull public android.media.MediaTranscodeManager.TranscodingSession enqueueRequest(@NonNull android.media.MediaTranscodeManager.TranscodingRequest, @NonNull java.util.concurrent.Executor, @NonNull android.media.MediaTranscodeManager.OnTranscodingFinishedListener) throws java.io.FileNotFoundException, android.media.MediaTranscodingException.ServiceNotAvailableException;
- field public static final int PRIORITY_REALTIME = 1; // 0x1
- field public static final int TRANSCODING_TYPE_VIDEO = 1; // 0x1
- }
-
- @java.lang.FunctionalInterface public static interface MediaTranscodeManager.OnTranscodingFinishedListener {
- method public void onTranscodingFinished(@NonNull android.media.MediaTranscodeManager.TranscodingSession);
- }
-
- public static final class MediaTranscodeManager.TranscodingRequest {
- method public int getClientPid();
- method public int getClientUid();
- method @NonNull public android.net.Uri getDestinationUri();
- method public int getPriority();
- method @NonNull public android.net.Uri getSourceUri();
- method public int getType();
- method @Nullable public android.media.MediaFormat getVideoTrackFormat();
- }
-
- public static final class MediaTranscodeManager.TranscodingRequest.Builder {
- ctor public MediaTranscodeManager.TranscodingRequest.Builder();
- method @NonNull public android.media.MediaTranscodeManager.TranscodingRequest build();
- method @NonNull public android.media.MediaTranscodeManager.TranscodingRequest.Builder setClientPid(int);
- method @NonNull public android.media.MediaTranscodeManager.TranscodingRequest.Builder setClientUid(int);
- method @NonNull public android.media.MediaTranscodeManager.TranscodingRequest.Builder setDestinationUri(@NonNull android.net.Uri);
- method @NonNull public android.media.MediaTranscodeManager.TranscodingRequest.Builder setPriority(int);
- method @NonNull public android.media.MediaTranscodeManager.TranscodingRequest.Builder setSourceUri(@NonNull android.net.Uri);
- method @NonNull public android.media.MediaTranscodeManager.TranscodingRequest.Builder setType(int);
- method @NonNull public android.media.MediaTranscodeManager.TranscodingRequest.Builder setVideoTrackFormat(@NonNull android.media.MediaFormat);
- }
-
- public static class MediaTranscodeManager.TranscodingRequest.MediaFormatResolver {
- ctor public MediaTranscodeManager.TranscodingRequest.MediaFormatResolver();
- method @Nullable public android.media.MediaFormat resolveVideoFormat();
- method @NonNull public android.media.MediaTranscodeManager.TranscodingRequest.MediaFormatResolver setSourceVideoFormatHint(@NonNull android.media.MediaFormat);
- method public boolean shouldTranscode();
- field public static final String CAPS_SUPPORTS_HEVC = "support-hevc";
- }
-
- public static final class MediaTranscodeManager.TranscodingSession {
- method public void cancel();
- method @IntRange(from=0, to=100) public int getProgress();
- method public int getResult();
- method public int getSessionId();
- method public int getStatus();
- method public void setOnProgressUpdateListener(@NonNull java.util.concurrent.Executor, @Nullable android.media.MediaTranscodeManager.TranscodingSession.OnProgressUpdateListener);
- method public void setOnProgressUpdateListener(int, @NonNull java.util.concurrent.Executor, @Nullable android.media.MediaTranscodeManager.TranscodingSession.OnProgressUpdateListener);
- field public static final int RESULT_CANCELED = 4; // 0x4
- field public static final int RESULT_ERROR = 3; // 0x3
- field public static final int RESULT_NONE = 1; // 0x1
- field public static final int RESULT_SUCCESS = 2; // 0x2
- field public static final int STATUS_FINISHED = 3; // 0x3
- field public static final int STATUS_PAUSED = 4; // 0x4
- field public static final int STATUS_PENDING = 1; // 0x1
- field public static final int STATUS_RUNNING = 2; // 0x2
- }
-
- @java.lang.FunctionalInterface public static interface MediaTranscodeManager.TranscodingSession.OnProgressUpdateListener {
- method public void onProgressUpdate(@NonNull android.media.MediaTranscodeManager.TranscodingSession, @IntRange(from=0, to=100) int);
- }
-
- public class PlayerProxy {
- method public void pause();
- method public void setPan(float);
- method public void setStartDelayMs(int);
- method public void setVolume(float);
- method public void start();
- method public void stop();
- }
-
- public class RingtoneManager {
- method @RequiresPermission(android.Manifest.permission.WRITE_SETTINGS) public static void ensureDefaultRingtones(@NonNull android.content.Context);
- }
-
-}
-
-package android.media.audiofx {
-
- public class AudioEffect {
- ctor @RequiresPermission("android.permission.MODIFY_DEFAULT_AUDIO_EFFECTS") public AudioEffect(@NonNull java.util.UUID, @NonNull android.media.AudioDeviceAttributes);
- method @RequiresPermission("android.permission.MODIFY_DEFAULT_AUDIO_EFFECTS") public static boolean isEffectSupportedForDevice(@NonNull java.util.UUID, @NonNull android.media.AudioDeviceAttributes);
- }
-
-}
-
-package android.media.audiopolicy {
-
- public class AudioMix {
- method public int getMixState();
- field public static final int MIX_STATE_DISABLED = -1; // 0xffffffff
- field public static final int MIX_STATE_IDLE = 0; // 0x0
- field public static final int MIX_STATE_MIXING = 1; // 0x1
- field public static final int ROUTE_FLAG_LOOP_BACK = 2; // 0x2
- field public static final int ROUTE_FLAG_RENDER = 1; // 0x1
- }
-
- public static class AudioMix.Builder {
- ctor public AudioMix.Builder(android.media.audiopolicy.AudioMixingRule) throws java.lang.IllegalArgumentException;
- method public android.media.audiopolicy.AudioMix build() throws java.lang.IllegalArgumentException;
- method public android.media.audiopolicy.AudioMix.Builder setDevice(@NonNull android.media.AudioDeviceInfo) throws java.lang.IllegalArgumentException;
- method public android.media.audiopolicy.AudioMix.Builder setFormat(android.media.AudioFormat) throws java.lang.IllegalArgumentException;
- method public android.media.audiopolicy.AudioMix.Builder setRouteFlags(int) throws java.lang.IllegalArgumentException;
- }
-
- public class AudioMixingRule {
- field public static final int RULE_MATCH_ATTRIBUTE_CAPTURE_PRESET = 2; // 0x2
- field public static final int RULE_MATCH_ATTRIBUTE_USAGE = 1; // 0x1
- field public static final int RULE_MATCH_UID = 4; // 0x4
- field public static final int RULE_MATCH_USERID = 8; // 0x8
- }
-
- public static class AudioMixingRule.Builder {
- ctor public AudioMixingRule.Builder();
- method public android.media.audiopolicy.AudioMixingRule.Builder addMixRule(int, Object) throws java.lang.IllegalArgumentException;
- method public android.media.audiopolicy.AudioMixingRule.Builder addRule(android.media.AudioAttributes, int) throws java.lang.IllegalArgumentException;
- method @NonNull public android.media.audiopolicy.AudioMixingRule.Builder allowPrivilegedPlaybackCapture(boolean);
- method public android.media.audiopolicy.AudioMixingRule build();
- method public android.media.audiopolicy.AudioMixingRule.Builder excludeMixRule(int, Object) throws java.lang.IllegalArgumentException;
- method public android.media.audiopolicy.AudioMixingRule.Builder excludeRule(android.media.AudioAttributes, int) throws java.lang.IllegalArgumentException;
- }
-
- public class AudioPolicy {
- method public int attachMixes(@NonNull java.util.List<android.media.audiopolicy.AudioMix>);
- method public android.media.AudioRecord createAudioRecordSink(android.media.audiopolicy.AudioMix) throws java.lang.IllegalArgumentException;
- method public android.media.AudioTrack createAudioTrackSource(android.media.audiopolicy.AudioMix) throws java.lang.IllegalArgumentException;
- method public int detachMixes(@NonNull java.util.List<android.media.audiopolicy.AudioMix>);
- method public int getFocusDuckingBehavior();
- method public int getStatus();
- method public boolean removeUidDeviceAffinity(int);
- method public boolean removeUserIdDeviceAffinity(int);
- method public int setFocusDuckingBehavior(int) throws java.lang.IllegalArgumentException, java.lang.IllegalStateException;
- method public void setRegistration(String);
- method public boolean setUidDeviceAffinity(int, @NonNull java.util.List<android.media.AudioDeviceInfo>);
- method public boolean setUserIdDeviceAffinity(int, @NonNull java.util.List<android.media.AudioDeviceInfo>);
- method public String toLogFriendlyString();
- field public static final int FOCUS_POLICY_DUCKING_DEFAULT = 0; // 0x0
- field public static final int FOCUS_POLICY_DUCKING_IN_APP = 0; // 0x0
- field public static final int FOCUS_POLICY_DUCKING_IN_POLICY = 1; // 0x1
- field public static final int POLICY_STATUS_REGISTERED = 2; // 0x2
- field public static final int POLICY_STATUS_UNREGISTERED = 1; // 0x1
- }
-
- public abstract static class AudioPolicy.AudioPolicyFocusListener {
- ctor public AudioPolicy.AudioPolicyFocusListener();
- method public void onAudioFocusAbandon(android.media.AudioFocusInfo);
- method public void onAudioFocusGrant(android.media.AudioFocusInfo, int);
- method public void onAudioFocusLoss(android.media.AudioFocusInfo, boolean);
- method public void onAudioFocusRequest(android.media.AudioFocusInfo, int);
- }
-
- public abstract static class AudioPolicy.AudioPolicyStatusListener {
- ctor public AudioPolicy.AudioPolicyStatusListener();
- method public void onMixStateUpdate(android.media.audiopolicy.AudioMix);
- method public void onStatusChange();
- }
-
- public abstract static class AudioPolicy.AudioPolicyVolumeCallback {
- ctor public AudioPolicy.AudioPolicyVolumeCallback();
- method public void onVolumeAdjustment(int);
- }
-
- public static class AudioPolicy.Builder {
- ctor public AudioPolicy.Builder(android.content.Context);
- method @NonNull public android.media.audiopolicy.AudioPolicy.Builder addMix(@NonNull android.media.audiopolicy.AudioMix) throws java.lang.IllegalArgumentException;
- method @NonNull public android.media.audiopolicy.AudioPolicy build();
- method public void setAudioPolicyFocusListener(android.media.audiopolicy.AudioPolicy.AudioPolicyFocusListener);
- method public void setAudioPolicyStatusListener(android.media.audiopolicy.AudioPolicy.AudioPolicyStatusListener);
- method @NonNull public android.media.audiopolicy.AudioPolicy.Builder setAudioPolicyVolumeCallback(@NonNull android.media.audiopolicy.AudioPolicy.AudioPolicyVolumeCallback);
- method @NonNull public android.media.audiopolicy.AudioPolicy.Builder setIsAudioFocusPolicy(boolean);
- method @NonNull public android.media.audiopolicy.AudioPolicy.Builder setLooper(@NonNull android.os.Looper) throws java.lang.IllegalArgumentException;
- }
-
- public final class AudioProductStrategy implements android.os.Parcelable {
- method @NonNull public static android.media.audiopolicy.AudioProductStrategy createInvalidAudioProductStrategy(int);
- method public int describeContents();
- method @NonNull public android.media.AudioAttributes getAudioAttributes();
- method public int getId();
- method public boolean supportsAudioAttributes(@NonNull android.media.AudioAttributes);
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.media.audiopolicy.AudioProductStrategy> CREATOR;
- }
-
- public final class AudioVolumeGroup implements android.os.Parcelable {
- method public int describeContents();
- method @NonNull public java.util.List<android.media.AudioAttributes> getAudioAttributes();
- method public int getId();
- method @NonNull public int[] getLegacyStreamTypes();
- method @NonNull public String name();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field public static final android.os.Parcelable.Creator<android.media.audiopolicy.AudioVolumeGroup> CREATOR;
- field public static final int DEFAULT_VOLUME_GROUP = -1; // 0xffffffff
- }
-
-}
-
-package android.media.musicrecognition {
-
- public class MusicRecognitionManager {
- method @RequiresPermission(android.Manifest.permission.MANAGE_MUSIC_RECOGNITION) public void beginStreamingSearch(@NonNull android.media.musicrecognition.RecognitionRequest, @NonNull java.util.concurrent.Executor, @NonNull android.media.musicrecognition.MusicRecognitionManager.RecognitionCallback);
- field public static final int RECOGNITION_FAILED_AUDIO_UNAVAILABLE = 7; // 0x7
- field public static final int RECOGNITION_FAILED_NOT_FOUND = 1; // 0x1
- field public static final int RECOGNITION_FAILED_NO_CONNECTIVITY = 2; // 0x2
- field public static final int RECOGNITION_FAILED_SERVICE_KILLED = 5; // 0x5
- field public static final int RECOGNITION_FAILED_SERVICE_UNAVAILABLE = 3; // 0x3
- field public static final int RECOGNITION_FAILED_TIMEOUT = 6; // 0x6
- field public static final int RECOGNITION_FAILED_UNKNOWN = -1; // 0xffffffff
- }
-
- public static interface MusicRecognitionManager.RecognitionCallback {
- method public void onAudioStreamClosed();
- method public void onRecognitionFailed(@NonNull android.media.musicrecognition.RecognitionRequest, int);
- method public void onRecognitionSucceeded(@NonNull android.media.musicrecognition.RecognitionRequest, @NonNull android.media.MediaMetadata, @Nullable android.os.Bundle);
- }
-
- public abstract class MusicRecognitionService extends android.app.Service {
- ctor public MusicRecognitionService();
- method public abstract void onRecognize(@NonNull android.os.ParcelFileDescriptor, @NonNull android.media.AudioFormat, @NonNull android.media.musicrecognition.MusicRecognitionService.Callback);
- }
-
- public static interface MusicRecognitionService.Callback {
- method public void onRecognitionFailed(int);
- method public void onRecognitionSucceeded(@NonNull android.media.MediaMetadata, @Nullable android.os.Bundle);
- }
-
- public final class RecognitionRequest implements android.os.Parcelable {
- method public int describeContents();
- method @NonNull public android.media.AudioAttributes getAudioAttributes();
- method @NonNull public android.media.AudioFormat getAudioFormat();
- method public int getCaptureSession();
- method public int getIgnoreBeginningFrames();
- method public int getMaxAudioLengthSeconds();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.media.musicrecognition.RecognitionRequest> CREATOR;
- }
-
- public static final class RecognitionRequest.Builder {
- ctor public RecognitionRequest.Builder();
- method @NonNull public android.media.musicrecognition.RecognitionRequest build();
- method @NonNull public android.media.musicrecognition.RecognitionRequest.Builder setAudioAttributes(@NonNull android.media.AudioAttributes);
- method @NonNull public android.media.musicrecognition.RecognitionRequest.Builder setAudioFormat(@NonNull android.media.AudioFormat);
- method @NonNull public android.media.musicrecognition.RecognitionRequest.Builder setCaptureSession(int);
- method @NonNull public android.media.musicrecognition.RecognitionRequest.Builder setIgnoreBeginningFrames(int);
- method @NonNull public android.media.musicrecognition.RecognitionRequest.Builder setMaxAudioLengthSeconds(int);
- }
-
-}
-
-package android.media.session {
-
- public final class MediaSessionManager {
- method @RequiresPermission(android.Manifest.permission.MEDIA_CONTENT_CONTROL) public void addOnMediaKeyEventDispatchedListener(@NonNull java.util.concurrent.Executor, @NonNull android.media.session.MediaSessionManager.OnMediaKeyEventDispatchedListener);
- method @RequiresPermission(android.Manifest.permission.MEDIA_CONTENT_CONTROL) public void addOnMediaKeyEventSessionChangedListener(@NonNull java.util.concurrent.Executor, @NonNull android.media.session.MediaSessionManager.OnMediaKeyEventSessionChangedListener);
- method @RequiresPermission(android.Manifest.permission.MEDIA_CONTENT_CONTROL) public void removeOnMediaKeyEventDispatchedListener(@NonNull android.media.session.MediaSessionManager.OnMediaKeyEventDispatchedListener);
- method @RequiresPermission(android.Manifest.permission.MEDIA_CONTENT_CONTROL) public void removeOnMediaKeyEventSessionChangedListener(@NonNull android.media.session.MediaSessionManager.OnMediaKeyEventSessionChangedListener);
- method @RequiresPermission(android.Manifest.permission.SET_MEDIA_KEY_LISTENER) public void setOnMediaKeyListener(android.media.session.MediaSessionManager.OnMediaKeyListener, @Nullable android.os.Handler);
- method @RequiresPermission(android.Manifest.permission.SET_VOLUME_KEY_LONG_PRESS_LISTENER) public void setOnVolumeKeyLongPressListener(android.media.session.MediaSessionManager.OnVolumeKeyLongPressListener, @Nullable android.os.Handler);
- }
-
- public static interface MediaSessionManager.OnMediaKeyEventDispatchedListener {
- method public void onMediaKeyEventDispatched(@NonNull android.view.KeyEvent, @NonNull String, @Nullable android.media.session.MediaSession.Token);
- }
-
- public static interface MediaSessionManager.OnMediaKeyEventSessionChangedListener {
- method public void onMediaKeyEventSessionChanged(@NonNull String, @Nullable android.media.session.MediaSession.Token);
- }
-
- public static interface MediaSessionManager.OnMediaKeyListener {
- method public boolean onMediaKey(android.view.KeyEvent);
- }
-
- public static interface MediaSessionManager.OnVolumeKeyLongPressListener {
- method public void onVolumeKeyLongPress(android.view.KeyEvent);
- }
-
-}
-
-package android.media.soundtrigger {
-
- public abstract class SoundTriggerDetectionService extends android.app.Service {
- ctor public SoundTriggerDetectionService();
- method @MainThread public void onConnected(@NonNull java.util.UUID, @Nullable android.os.Bundle);
- method @MainThread public void onDisconnected(@NonNull java.util.UUID, @Nullable android.os.Bundle);
- method @MainThread public void onError(@NonNull java.util.UUID, @Nullable android.os.Bundle, int, int);
- method @MainThread public void onGenericRecognitionEvent(@NonNull java.util.UUID, @Nullable android.os.Bundle, int, @NonNull android.hardware.soundtrigger.SoundTrigger.RecognitionEvent);
- method @MainThread public abstract void onStopOperation(@NonNull java.util.UUID, @Nullable android.os.Bundle, int);
- method public final void operationFinished(@Nullable java.util.UUID, int);
- }
-
- public final class SoundTriggerDetector {
- method @RequiresPermission(android.Manifest.permission.MANAGE_SOUND_TRIGGER) public boolean startRecognition(int);
- method @RequiresPermission(android.Manifest.permission.MANAGE_SOUND_TRIGGER) public boolean stopRecognition();
- field public static final int RECOGNITION_FLAG_ALLOW_MULTIPLE_TRIGGERS = 2; // 0x2
- field public static final int RECOGNITION_FLAG_CAPTURE_TRIGGER_AUDIO = 1; // 0x1
- field public static final int RECOGNITION_FLAG_ENABLE_AUDIO_ECHO_CANCELLATION = 4; // 0x4
- field public static final int RECOGNITION_FLAG_ENABLE_AUDIO_NOISE_SUPPRESSION = 8; // 0x8
- }
-
- public abstract static class SoundTriggerDetector.Callback {
- ctor public SoundTriggerDetector.Callback();
- method public abstract void onAvailabilityChanged(int);
- method public abstract void onDetected(@NonNull android.media.soundtrigger.SoundTriggerDetector.EventPayload);
- method public abstract void onError();
- method public abstract void onRecognitionPaused();
- method public abstract void onRecognitionResumed();
- }
-
- public static class SoundTriggerDetector.EventPayload {
- method @Nullable public android.media.AudioFormat getCaptureAudioFormat();
- method @Nullable public byte[] getTriggerAudio();
- }
-
- public final class SoundTriggerManager {
- method @Nullable @RequiresPermission(android.Manifest.permission.MANAGE_SOUND_TRIGGER) public android.media.soundtrigger.SoundTriggerDetector createSoundTriggerDetector(java.util.UUID, @NonNull android.media.soundtrigger.SoundTriggerDetector.Callback, @Nullable android.os.Handler);
- method @RequiresPermission(android.Manifest.permission.MANAGE_SOUND_TRIGGER) public void deleteModel(java.util.UUID);
- method public int getDetectionServiceOperationsTimeout();
- method @Nullable @RequiresPermission(android.Manifest.permission.MANAGE_SOUND_TRIGGER) public android.media.soundtrigger.SoundTriggerManager.Model getModel(java.util.UUID);
- method @Nullable @RequiresPermission(android.Manifest.permission.MANAGE_SOUND_TRIGGER) public android.hardware.soundtrigger.SoundTrigger.ModuleProperties getModuleProperties();
- method @RequiresPermission(android.Manifest.permission.MANAGE_SOUND_TRIGGER) public int getParameter(@NonNull java.util.UUID, int);
- method @Nullable @RequiresPermission(android.Manifest.permission.MANAGE_SOUND_TRIGGER) public android.hardware.soundtrigger.SoundTrigger.ModelParamRange queryParameter(@Nullable java.util.UUID, int);
- method @RequiresPermission(android.Manifest.permission.MANAGE_SOUND_TRIGGER) public int setParameter(@Nullable java.util.UUID, int, int);
- method @RequiresPermission(android.Manifest.permission.MANAGE_SOUND_TRIGGER) public void updateModel(android.media.soundtrigger.SoundTriggerManager.Model);
- }
-
- public static class SoundTriggerManager.Model {
- method @NonNull public static android.media.soundtrigger.SoundTriggerManager.Model create(@NonNull java.util.UUID, @NonNull java.util.UUID, @Nullable byte[], int);
- method @NonNull public static android.media.soundtrigger.SoundTriggerManager.Model create(@NonNull java.util.UUID, @NonNull java.util.UUID, @Nullable byte[]);
- method @Nullable public byte[] getModelData();
- method @NonNull public java.util.UUID getModelUuid();
- method @NonNull public java.util.UUID getVendorUuid();
- method public int getVersion();
- }
-
-}
-
-package android.media.tv {
-
- public final class DvbDeviceInfo implements android.os.Parcelable {
- ctor public DvbDeviceInfo(int, int);
- method public int describeContents();
- method @IntRange(from=0) public int getAdapterId();
- method @IntRange(from=0) public int getDeviceId();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.media.tv.DvbDeviceInfo> CREATOR;
- }
-
- public final class TunedInfo implements android.os.Parcelable {
- method public int describeContents();
- method public int getAppTag();
- method public int getAppType();
- method @Nullable public android.net.Uri getChannelUri();
- method @NonNull public String getInputId();
- method public boolean isForeground();
- method public boolean isRecordingSession();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field public static final int APP_TAG_SELF = 0; // 0x0
- field public static final int APP_TYPE_NON_SYSTEM = 3; // 0x3
- field public static final int APP_TYPE_SELF = 1; // 0x1
- field public static final int APP_TYPE_SYSTEM = 2; // 0x2
- field @NonNull public static final android.os.Parcelable.Creator<android.media.tv.TunedInfo> CREATOR;
- }
-
- public final class TvContentRatingSystemInfo implements android.os.Parcelable {
- method public static android.media.tv.TvContentRatingSystemInfo createTvContentRatingSystemInfo(int, android.content.pm.ApplicationInfo);
- method public int describeContents();
- method public android.net.Uri getXmlUri();
- method public boolean isSystemDefined();
- method public void writeToParcel(android.os.Parcel, int);
- }
-
- public final class TvContract {
- method public static android.net.Uri buildChannelsUriForInput(@Nullable String, boolean);
- method public static android.net.Uri buildChannelsUriForInput(@Nullable String, @Nullable String, boolean);
- field public static final String ACTION_CHANNEL_BROWSABLE_REQUESTED = "android.media.tv.action.CHANNEL_BROWSABLE_REQUESTED";
- field public static final String EXTRA_BLOCKED_PACKAGES = "android.media.tv.extra.BLOCKED_PACKAGES";
- field public static final String EXTRA_COLUMN_NAME = "android.media.tv.extra.COLUMN_NAME";
- field public static final String EXTRA_DATA_TYPE = "android.media.tv.extra.DATA_TYPE";
- field public static final String EXTRA_DEFAULT_VALUE = "android.media.tv.extra.DEFAULT_VALUE";
- field public static final String EXTRA_EXISTING_COLUMN_NAMES = "android.media.tv.extra.EXISTING_COLUMN_NAMES";
- field public static final String EXTRA_PACKAGE_NAME = "android.media.tv.extra.PACKAGE_NAME";
- field public static final String EXTRA_RESULT_CODE = "android.media.tv.extra.RESULT_CODE";
- field public static final String METHOD_ADD_COLUMN = "add_column";
- field public static final String METHOD_BLOCK_PACKAGE = "block_package";
- field public static final String METHOD_GET_BLOCKED_PACKAGES = "get_blocked_packages";
- field public static final String METHOD_GET_COLUMNS = "get_columns";
- field public static final String METHOD_UNBLOCK_PACKAGE = "unblock_package";
- field public static final int RESULT_ERROR_INVALID_ARGUMENT = 2; // 0x2
- field public static final int RESULT_ERROR_IO = 1; // 0x1
- field public static final int RESULT_OK = 0; // 0x0
- }
-
- public static final class TvContract.WatchedPrograms implements android.media.tv.TvContract.BaseTvColumns {
- field public static final String COLUMN_CHANNEL_ID = "channel_id";
- field public static final String COLUMN_DESCRIPTION = "description";
- field public static final String COLUMN_END_TIME_UTC_MILLIS = "end_time_utc_millis";
- field public static final String COLUMN_INTERNAL_SESSION_TOKEN = "session_token";
- field public static final String COLUMN_INTERNAL_TUNE_PARAMS = "tune_params";
- field public static final String COLUMN_START_TIME_UTC_MILLIS = "start_time_utc_millis";
- field public static final String COLUMN_TITLE = "title";
- field public static final String COLUMN_WATCH_END_TIME_UTC_MILLIS = "watch_end_time_utc_millis";
- field public static final String COLUMN_WATCH_START_TIME_UTC_MILLIS = "watch_start_time_utc_millis";
- field public static final String CONTENT_ITEM_TYPE = "vnd.android.cursor.item/watched_program";
- field public static final String CONTENT_TYPE = "vnd.android.cursor.dir/watched_program";
- field public static final android.net.Uri CONTENT_URI;
- }
-
- public final class TvInputHardwareInfo implements android.os.Parcelable {
- method public int describeContents();
- method public String getAudioAddress();
- method public int getAudioType();
- method public int getCableConnectionStatus();
- method public int getDeviceId();
- method public int getHdmiPortId();
- method public int getType();
- method public void readFromParcel(android.os.Parcel);
- method public void writeToParcel(android.os.Parcel, int);
- field public static final int CABLE_CONNECTION_STATUS_CONNECTED = 1; // 0x1
- field public static final int CABLE_CONNECTION_STATUS_DISCONNECTED = 2; // 0x2
- field public static final int CABLE_CONNECTION_STATUS_UNKNOWN = 0; // 0x0
- field @NonNull public static final android.os.Parcelable.Creator<android.media.tv.TvInputHardwareInfo> CREATOR;
- field public static final int TV_INPUT_TYPE_COMPONENT = 6; // 0x6
- field public static final int TV_INPUT_TYPE_COMPOSITE = 3; // 0x3
- field public static final int TV_INPUT_TYPE_DISPLAY_PORT = 10; // 0xa
- field public static final int TV_INPUT_TYPE_DVI = 8; // 0x8
- field public static final int TV_INPUT_TYPE_HDMI = 9; // 0x9
- field public static final int TV_INPUT_TYPE_OTHER_HARDWARE = 1; // 0x1
- field public static final int TV_INPUT_TYPE_SCART = 5; // 0x5
- field public static final int TV_INPUT_TYPE_SVIDEO = 4; // 0x4
- field public static final int TV_INPUT_TYPE_TUNER = 2; // 0x2
- field public static final int TV_INPUT_TYPE_VGA = 7; // 0x7
- }
-
- public static final class TvInputHardwareInfo.Builder {
- ctor public TvInputHardwareInfo.Builder();
- method public android.media.tv.TvInputHardwareInfo.Builder audioAddress(String);
- method public android.media.tv.TvInputHardwareInfo.Builder audioType(int);
- method public android.media.tv.TvInputHardwareInfo build();
- method public android.media.tv.TvInputHardwareInfo.Builder cableConnectionStatus(int);
- method public android.media.tv.TvInputHardwareInfo.Builder deviceId(int);
- method public android.media.tv.TvInputHardwareInfo.Builder hdmiPortId(int);
- method public android.media.tv.TvInputHardwareInfo.Builder type(int);
- }
-
- public final class TvInputInfo implements android.os.Parcelable {
- method @Deprecated public static android.media.tv.TvInputInfo createTvInputInfo(android.content.Context, android.content.pm.ResolveInfo, android.hardware.hdmi.HdmiDeviceInfo, String, String, android.net.Uri) throws java.io.IOException, org.xmlpull.v1.XmlPullParserException;
- method @Deprecated public static android.media.tv.TvInputInfo createTvInputInfo(android.content.Context, android.content.pm.ResolveInfo, android.hardware.hdmi.HdmiDeviceInfo, String, int, android.graphics.drawable.Icon) throws java.io.IOException, org.xmlpull.v1.XmlPullParserException;
- method @Deprecated public static android.media.tv.TvInputInfo createTvInputInfo(android.content.Context, android.content.pm.ResolveInfo, android.media.tv.TvInputHardwareInfo, String, android.net.Uri) throws java.io.IOException, org.xmlpull.v1.XmlPullParserException;
- method @Deprecated public static android.media.tv.TvInputInfo createTvInputInfo(android.content.Context, android.content.pm.ResolveInfo, android.media.tv.TvInputHardwareInfo, int, android.graphics.drawable.Icon) throws java.io.IOException, org.xmlpull.v1.XmlPullParserException;
- method public android.hardware.hdmi.HdmiDeviceInfo getHdmiDeviceInfo();
- method public boolean isConnectedToHdmiSwitch();
- method public boolean isHardwareInput();
- method public android.graphics.drawable.Drawable loadIcon(@NonNull android.content.Context, int);
- }
-
- public static final class TvInputInfo.Builder {
- method public android.media.tv.TvInputInfo.Builder setHdmiDeviceInfo(android.hardware.hdmi.HdmiDeviceInfo);
- method public android.media.tv.TvInputInfo.Builder setIcon(android.graphics.drawable.Icon);
- method public android.media.tv.TvInputInfo.Builder setIcon(android.graphics.drawable.Icon, int);
- method public android.media.tv.TvInputInfo.Builder setLabel(CharSequence);
- method public android.media.tv.TvInputInfo.Builder setLabel(@StringRes int);
- method public android.media.tv.TvInputInfo.Builder setParentId(String);
- method public android.media.tv.TvInputInfo.Builder setTvInputHardwareInfo(android.media.tv.TvInputHardwareInfo);
- }
-
- public static final class TvInputInfo.TvInputSettings {
- method public static java.util.Map<java.lang.String,java.lang.String> getCustomLabels(android.content.Context, int);
- method public static java.util.Set<java.lang.String> getHiddenTvInputIds(android.content.Context, int);
- method public static void putCustomLabels(android.content.Context, java.util.Map<java.lang.String,java.lang.String>, int);
- method public static void putHiddenTvInputs(android.content.Context, java.util.Set<java.lang.String>, int);
- }
-
- public final class TvInputManager {
- method @RequiresPermission(android.Manifest.permission.TV_INPUT_HARDWARE) public android.media.tv.TvInputManager.Hardware acquireTvInputHardware(int, @NonNull android.media.tv.TvInputInfo, @NonNull android.media.tv.TvInputManager.HardwareCallback);
- method @Nullable @RequiresPermission(android.Manifest.permission.TV_INPUT_HARDWARE) public android.media.tv.TvInputManager.Hardware acquireTvInputHardware(int, @NonNull android.media.tv.TvInputInfo, @Nullable String, int, @NonNull java.util.concurrent.Executor, @NonNull android.media.tv.TvInputManager.HardwareCallback);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PARENTAL_CONTROLS) public void addBlockedRating(@NonNull android.media.tv.TvContentRating);
- method @RequiresPermission(android.Manifest.permission.CAPTURE_TV_INPUT) public boolean captureFrame(String, android.view.Surface, android.media.tv.TvStreamConfig);
- method @RequiresPermission(android.Manifest.permission.CAPTURE_TV_INPUT) public java.util.List<android.media.tv.TvStreamConfig> getAvailableTvStreamConfigList(String);
- method @NonNull @RequiresPermission("com.android.providers.tv.permission.ACCESS_WATCHED_PROGRAMS") public java.util.List<android.media.tv.TunedInfo> getCurrentTunedInfos();
- method @NonNull @RequiresPermission("android.permission.DVB_DEVICE") public java.util.List<android.media.tv.DvbDeviceInfo> getDvbDeviceList();
- method @RequiresPermission(android.Manifest.permission.TV_INPUT_HARDWARE) public java.util.List<android.media.tv.TvInputHardwareInfo> getHardwareList();
- method @RequiresPermission(android.Manifest.permission.READ_CONTENT_RATING_SYSTEMS) public java.util.List<android.media.tv.TvContentRatingSystemInfo> getTvContentRatingSystemList();
- method @RequiresPermission(android.Manifest.permission.CAPTURE_TV_INPUT) public boolean isSingleSessionActive();
- method @RequiresPermission(android.Manifest.permission.NOTIFY_TV_INPUTS) public void notifyPreviewProgramAddedToWatchNext(String, long, long);
- method @RequiresPermission(android.Manifest.permission.NOTIFY_TV_INPUTS) public void notifyPreviewProgramBrowsableDisabled(String, long);
- method @RequiresPermission(android.Manifest.permission.NOTIFY_TV_INPUTS) public void notifyWatchNextProgramBrowsableDisabled(String, long);
- method @Nullable @RequiresPermission("android.permission.DVB_DEVICE") public android.os.ParcelFileDescriptor openDvbDevice(@NonNull android.media.tv.DvbDeviceInfo, int);
- method @RequiresPermission(android.Manifest.permission.TV_INPUT_HARDWARE) public void releaseTvInputHardware(int, android.media.tv.TvInputManager.Hardware);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PARENTAL_CONTROLS) public void removeBlockedRating(@NonNull android.media.tv.TvContentRating);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PARENTAL_CONTROLS) public void setParentalControlsEnabled(boolean);
- }
-
- public static final class TvInputManager.Hardware {
- method public void overrideAudioSink(int, String, int, int, int);
- method public void setStreamVolume(float);
- method public boolean setSurface(android.view.Surface, android.media.tv.TvStreamConfig);
- }
-
- public abstract static class TvInputManager.HardwareCallback {
- ctor public TvInputManager.HardwareCallback();
- method public abstract void onReleased();
- method public abstract void onStreamConfigChanged(android.media.tv.TvStreamConfig[]);
- }
-
- public abstract static class TvInputManager.TvInputCallback {
- method public void onCurrentTunedInfosUpdated(@NonNull java.util.List<android.media.tv.TunedInfo>);
- }
-
- public abstract class TvInputService extends android.app.Service {
- method @Nullable public android.os.IBinder createExtension();
- method @Nullable public android.media.tv.TvInputInfo onHardwareAdded(android.media.tv.TvInputHardwareInfo);
- method @Nullable public String onHardwareRemoved(android.media.tv.TvInputHardwareInfo);
- method @Nullable public android.media.tv.TvInputInfo onHdmiDeviceAdded(android.hardware.hdmi.HdmiDeviceInfo);
- method @Nullable public String onHdmiDeviceRemoved(android.hardware.hdmi.HdmiDeviceInfo);
- method public void onHdmiDeviceUpdated(@NonNull android.hardware.hdmi.HdmiDeviceInfo);
- }
-
- public abstract static class TvInputService.RecordingSession {
- method public void notifySessionEvent(@NonNull String, android.os.Bundle);
- }
-
- public abstract static class TvInputService.Session implements android.view.KeyEvent.Callback {
- method public void notifySessionEvent(@NonNull String, android.os.Bundle);
- method public void onSetMain(boolean);
- }
-
- public abstract static class TvRecordingClient.RecordingCallback {
- method public void onEvent(String, String, android.os.Bundle);
- }
-
- public class TvStreamConfig implements android.os.Parcelable {
- method public int describeContents();
- method public int getGeneration();
- method public int getMaxHeight();
- method public int getMaxWidth();
- method public int getStreamId();
- method public int getType();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.media.tv.TvStreamConfig> CREATOR;
- field public static final int STREAM_TYPE_BUFFER_PRODUCER = 2; // 0x2
- field public static final int STREAM_TYPE_INDEPENDENT_VIDEO_SOURCE = 1; // 0x1
- }
-
- public static final class TvStreamConfig.Builder {
- ctor public TvStreamConfig.Builder();
- method public android.media.tv.TvStreamConfig build();
- method public android.media.tv.TvStreamConfig.Builder generation(int);
- method public android.media.tv.TvStreamConfig.Builder maxHeight(int);
- method public android.media.tv.TvStreamConfig.Builder maxWidth(int);
- method public android.media.tv.TvStreamConfig.Builder streamId(int);
- method public android.media.tv.TvStreamConfig.Builder type(int);
- }
-
- public class TvView extends android.view.ViewGroup {
- method @RequiresPermission("android.permission.CHANGE_HDMI_CEC_ACTIVE_SOURCE") public void setMain();
- method @RequiresPermission(android.Manifest.permission.MODIFY_PARENTAL_CONTROLS) public void unblockContent(android.media.tv.TvContentRating);
- }
-
- public abstract static class TvView.TvInputCallback {
- method public void onEvent(String, String, android.os.Bundle);
- }
-
-}
-
-package android.media.tv.tuner {
-
- public class DemuxCapabilities {
- method public int getAudioFilterCount();
- method public int getDemuxCount();
- method public int getFilterCapabilities();
- method @NonNull @Size(5) public int[] getLinkCapabilities();
- method public int getPcrFilterCount();
- method public int getPesFilterCount();
- method public int getPlaybackCount();
- method public int getRecordCount();
- method public int getSectionFilterCount();
- method public long getSectionFilterLength();
- method public int getTsFilterCount();
- method public int getVideoFilterCount();
- method public boolean isTimeFilterSupported();
- }
-
- public class Descrambler implements java.lang.AutoCloseable {
- method public int addPid(int, int, @Nullable android.media.tv.tuner.filter.Filter);
- method public void close();
- method public int removePid(int, int, @Nullable android.media.tv.tuner.filter.Filter);
- method public int setKeyToken(@NonNull byte[]);
- field public static final int PID_TYPE_MMTP = 2; // 0x2
- field public static final int PID_TYPE_T = 1; // 0x1
- }
-
- public class Lnb implements java.lang.AutoCloseable {
- method public void close();
- method public int sendDiseqcMessage(@NonNull byte[]);
- method public int setSatellitePosition(int);
- method public int setTone(int);
- method public int setVoltage(int);
- field public static final int EVENT_TYPE_DISEQC_RX_OVERFLOW = 0; // 0x0
- field public static final int EVENT_TYPE_DISEQC_RX_PARITY_ERROR = 2; // 0x2
- field public static final int EVENT_TYPE_DISEQC_RX_TIMEOUT = 1; // 0x1
- field public static final int EVENT_TYPE_LNB_OVERLOAD = 3; // 0x3
- field public static final int POSITION_A = 1; // 0x1
- field public static final int POSITION_B = 2; // 0x2
- field public static final int POSITION_UNDEFINED = 0; // 0x0
- field public static final int TONE_CONTINUOUS = 1; // 0x1
- field public static final int TONE_NONE = 0; // 0x0
- field public static final int VOLTAGE_11V = 2; // 0x2
- field public static final int VOLTAGE_12V = 3; // 0x3
- field public static final int VOLTAGE_13V = 4; // 0x4
- field public static final int VOLTAGE_14V = 5; // 0x5
- field public static final int VOLTAGE_15V = 6; // 0x6
- field public static final int VOLTAGE_18V = 7; // 0x7
- field public static final int VOLTAGE_19V = 8; // 0x8
- field public static final int VOLTAGE_5V = 1; // 0x1
- field public static final int VOLTAGE_NONE = 0; // 0x0
- }
-
- public interface LnbCallback {
- method public void onDiseqcMessage(@NonNull byte[]);
- method public void onEvent(int);
- }
-
- public class Tuner implements java.lang.AutoCloseable {
- ctor @RequiresPermission(android.Manifest.permission.ACCESS_TV_TUNER) public Tuner(@NonNull android.content.Context, @Nullable String, int);
- method public int cancelScanning();
- method public int cancelTuning();
- method public void clearOnTuneEventListener();
- method public void clearResourceLostListener();
- method public void close();
- method public int connectCiCam(int);
- method public int disconnectCiCam();
- method public int getAvSyncHwId(@NonNull android.media.tv.tuner.filter.Filter);
- method public long getAvSyncTime(int);
- method @Nullable public android.media.tv.tuner.DemuxCapabilities getDemuxCapabilities();
- method @Nullable public android.media.tv.tuner.frontend.FrontendInfo getFrontendInfo();
- method @Nullable public java.util.List<android.media.tv.tuner.frontend.FrontendInfo> getFrontendInfoList();
- method @Nullable public android.media.tv.tuner.frontend.FrontendStatus getFrontendStatus(@NonNull int[]);
- method public int linkFrontendToCiCam(int);
- method @Nullable @RequiresPermission(android.Manifest.permission.ACCESS_TV_DESCRAMBLER) public android.media.tv.tuner.Descrambler openDescrambler();
- method @Nullable public android.media.tv.tuner.dvr.DvrPlayback openDvrPlayback(long, @NonNull java.util.concurrent.Executor, @NonNull android.media.tv.tuner.dvr.OnPlaybackStatusChangedListener);
- method @Nullable public android.media.tv.tuner.dvr.DvrRecorder openDvrRecorder(long, @NonNull java.util.concurrent.Executor, @NonNull android.media.tv.tuner.dvr.OnRecordStatusChangedListener);
- method @Nullable public android.media.tv.tuner.filter.Filter openFilter(int, int, long, @Nullable java.util.concurrent.Executor, @Nullable android.media.tv.tuner.filter.FilterCallback);
- method @Nullable public android.media.tv.tuner.Lnb openLnb(@NonNull java.util.concurrent.Executor, @NonNull android.media.tv.tuner.LnbCallback);
- method @Nullable public android.media.tv.tuner.Lnb openLnbByName(@NonNull String, @NonNull java.util.concurrent.Executor, @NonNull android.media.tv.tuner.LnbCallback);
- method @Nullable public android.media.tv.tuner.filter.TimeFilter openTimeFilter();
- method public int scan(@NonNull android.media.tv.tuner.frontend.FrontendSettings, int, @NonNull java.util.concurrent.Executor, @NonNull android.media.tv.tuner.frontend.ScanCallback);
- method public int setLnaEnabled(boolean);
- method public void setOnTuneEventListener(@NonNull java.util.concurrent.Executor, @NonNull android.media.tv.tuner.frontend.OnTuneEventListener);
- method public void setResourceLostListener(@NonNull java.util.concurrent.Executor, @NonNull android.media.tv.tuner.Tuner.OnResourceLostListener);
- method public void shareFrontendFromTuner(@NonNull android.media.tv.tuner.Tuner);
- method public int tune(@NonNull android.media.tv.tuner.frontend.FrontendSettings);
- method public int unlinkFrontendToCiCam(int);
- method public void updateResourcePriority(int, int);
- field public static final int INVALID_AV_SYNC_ID = -1; // 0xffffffff
- field public static final int INVALID_FILTER_ID = -1; // 0xffffffff
- field public static final long INVALID_FILTER_ID_64BIT = -1L; // 0xffffffffffffffffL
- field public static final int INVALID_FIRST_MACROBLOCK_IN_SLICE = -1; // 0xffffffff
- field public static final int INVALID_FRONTEND_ID = -1; // 0xffffffff
- field public static final int INVALID_FRONTEND_SETTING_FREQUENCY = -1; // 0xffffffff
- field @NonNull public static final byte[] INVALID_KEYTOKEN;
- field public static final int INVALID_LTS_ID = -1; // 0xffffffff
- field public static final int INVALID_MMTP_RECORD_EVENT_MPT_SEQUENCE_NUM = -1; // 0xffffffff
- field public static final int INVALID_STREAM_ID = 65535; // 0xffff
- field public static final long INVALID_TIMESTAMP = -1L; // 0xffffffffffffffffL
- field public static final int INVALID_TS_PID = 65535; // 0xffff
- field public static final int RESULT_INVALID_ARGUMENT = 4; // 0x4
- field public static final int RESULT_INVALID_STATE = 3; // 0x3
- field public static final int RESULT_NOT_INITIALIZED = 2; // 0x2
- field public static final int RESULT_OUT_OF_MEMORY = 5; // 0x5
- field public static final int RESULT_SUCCESS = 0; // 0x0
- field public static final int RESULT_UNAVAILABLE = 1; // 0x1
- field public static final int RESULT_UNKNOWN_ERROR = 6; // 0x6
- field public static final int SCAN_TYPE_AUTO = 1; // 0x1
- field public static final int SCAN_TYPE_BLIND = 2; // 0x2
- field public static final int SCAN_TYPE_UNDEFINED = 0; // 0x0
- }
-
- public static interface Tuner.OnResourceLostListener {
- method public void onResourceLost(@NonNull android.media.tv.tuner.Tuner);
- }
-
- public final class TunerVersionChecker {
- method public static int getTunerVersion();
- field public static final int TUNER_VERSION_1_0 = 65536; // 0x10000
- field public static final int TUNER_VERSION_1_1 = 65537; // 0x10001
- field public static final int TUNER_VERSION_UNKNOWN = 0; // 0x0
- }
-
-}
-
-package android.media.tv.tuner.dvr {
-
- public class DvrPlayback implements java.lang.AutoCloseable {
- method @Deprecated public int attachFilter(@NonNull android.media.tv.tuner.filter.Filter);
- method public void close();
- method public int configure(@NonNull android.media.tv.tuner.dvr.DvrSettings);
- method @Deprecated public int detachFilter(@NonNull android.media.tv.tuner.filter.Filter);
- method public int flush();
- method public long read(long);
- method public long read(@NonNull byte[], long, long);
- method public void setFileDescriptor(@NonNull android.os.ParcelFileDescriptor);
- method public int start();
- method public int stop();
- field public static final int PLAYBACK_STATUS_ALMOST_EMPTY = 2; // 0x2
- field public static final int PLAYBACK_STATUS_ALMOST_FULL = 4; // 0x4
- field public static final int PLAYBACK_STATUS_EMPTY = 1; // 0x1
- field public static final int PLAYBACK_STATUS_FULL = 8; // 0x8
- }
-
- public class DvrRecorder implements java.lang.AutoCloseable {
- method public int attachFilter(@NonNull android.media.tv.tuner.filter.Filter);
- method public void close();
- method public int configure(@NonNull android.media.tv.tuner.dvr.DvrSettings);
- method public int detachFilter(@NonNull android.media.tv.tuner.filter.Filter);
- method public int flush();
- method public void setFileDescriptor(@NonNull android.os.ParcelFileDescriptor);
- method public int start();
- method public int stop();
- method public long write(long);
- method public long write(@NonNull byte[], long, long);
- }
-
- public class DvrSettings {
- method @NonNull public static android.media.tv.tuner.dvr.DvrSettings.Builder builder();
- method public int getDataFormat();
- method public long getHighThreshold();
- method public long getLowThreshold();
- method public long getPacketSize();
- method public int getStatusMask();
- field public static final int DATA_FORMAT_ES = 2; // 0x2
- field public static final int DATA_FORMAT_PES = 1; // 0x1
- field public static final int DATA_FORMAT_SHV_TLV = 3; // 0x3
- field public static final int DATA_FORMAT_TS = 0; // 0x0
- }
-
- public static final class DvrSettings.Builder {
- ctor public DvrSettings.Builder();
- method @NonNull public android.media.tv.tuner.dvr.DvrSettings build();
- method @NonNull public android.media.tv.tuner.dvr.DvrSettings.Builder setDataFormat(int);
- method @NonNull public android.media.tv.tuner.dvr.DvrSettings.Builder setHighThreshold(long);
- method @NonNull public android.media.tv.tuner.dvr.DvrSettings.Builder setLowThreshold(long);
- method @NonNull public android.media.tv.tuner.dvr.DvrSettings.Builder setPacketSize(long);
- method @NonNull public android.media.tv.tuner.dvr.DvrSettings.Builder setStatusMask(int);
- }
-
- public interface OnPlaybackStatusChangedListener {
- method public void onPlaybackStatusChanged(int);
- }
-
- public interface OnRecordStatusChangedListener {
- method public void onRecordStatusChanged(int);
- }
-
-}
-
-package android.media.tv.tuner.filter {
-
- public final class AlpFilterConfiguration extends android.media.tv.tuner.filter.FilterConfiguration {
- method @NonNull public static android.media.tv.tuner.filter.AlpFilterConfiguration.Builder builder();
- method public int getLengthType();
- method public int getPacketType();
- method public int getType();
- field public static final int LENGTH_TYPE_UNDEFINED = 0; // 0x0
- field public static final int LENGTH_TYPE_WITHOUT_ADDITIONAL_HEADER = 1; // 0x1
- field public static final int LENGTH_TYPE_WITH_ADDITIONAL_HEADER = 2; // 0x2
- field public static final int PACKET_TYPE_COMPRESSED = 2; // 0x2
- field public static final int PACKET_TYPE_EXTENSION = 6; // 0x6
- field public static final int PACKET_TYPE_IPV4 = 0; // 0x0
- field public static final int PACKET_TYPE_MPEG2_TS = 7; // 0x7
- field public static final int PACKET_TYPE_SIGNALING = 4; // 0x4
- }
-
- public static final class AlpFilterConfiguration.Builder {
- method @NonNull public android.media.tv.tuner.filter.AlpFilterConfiguration build();
- method @NonNull public android.media.tv.tuner.filter.AlpFilterConfiguration.Builder setLengthType(int);
- method @NonNull public android.media.tv.tuner.filter.AlpFilterConfiguration.Builder setPacketType(int);
- method @NonNull public android.media.tv.tuner.filter.AlpFilterConfiguration.Builder setSettings(@Nullable android.media.tv.tuner.filter.Settings);
- }
-
- public class AudioDescriptor {
- method public byte getAdFade();
- method public byte getAdGainCenter();
- method public byte getAdGainFront();
- method public byte getAdGainSurround();
- method public byte getAdPan();
- method public char getAdVersionTextTag();
- }
-
- public class AvSettings extends android.media.tv.tuner.filter.Settings {
- method @NonNull public static android.media.tv.tuner.filter.AvSettings.Builder builder(int, boolean);
- method public int getAudioStreamType();
- method public int getVideoStreamType();
- method public boolean isPassthrough();
- field public static final int AUDIO_STREAM_TYPE_AAC = 6; // 0x6
- field public static final int AUDIO_STREAM_TYPE_AC3 = 7; // 0x7
- field public static final int AUDIO_STREAM_TYPE_AC4 = 9; // 0x9
- field public static final int AUDIO_STREAM_TYPE_DRA = 15; // 0xf
- field public static final int AUDIO_STREAM_TYPE_DTS = 10; // 0xa
- field public static final int AUDIO_STREAM_TYPE_DTS_HD = 11; // 0xb
- field public static final int AUDIO_STREAM_TYPE_EAC3 = 8; // 0x8
- field public static final int AUDIO_STREAM_TYPE_MP3 = 2; // 0x2
- field public static final int AUDIO_STREAM_TYPE_MPEG1 = 3; // 0x3
- field public static final int AUDIO_STREAM_TYPE_MPEG2 = 4; // 0x4
- field public static final int AUDIO_STREAM_TYPE_MPEGH = 5; // 0x5
- field public static final int AUDIO_STREAM_TYPE_OPUS = 13; // 0xd
- field public static final int AUDIO_STREAM_TYPE_PCM = 1; // 0x1
- field public static final int AUDIO_STREAM_TYPE_UNDEFINED = 0; // 0x0
- field public static final int AUDIO_STREAM_TYPE_VORBIS = 14; // 0xe
- field public static final int AUDIO_STREAM_TYPE_WMA = 12; // 0xc
- field public static final int VIDEO_STREAM_TYPE_AV1 = 10; // 0xa
- field public static final int VIDEO_STREAM_TYPE_AVC = 5; // 0x5
- field public static final int VIDEO_STREAM_TYPE_AVS = 11; // 0xb
- field public static final int VIDEO_STREAM_TYPE_AVS2 = 12; // 0xc
- field public static final int VIDEO_STREAM_TYPE_HEVC = 6; // 0x6
- field public static final int VIDEO_STREAM_TYPE_MPEG1 = 2; // 0x2
- field public static final int VIDEO_STREAM_TYPE_MPEG2 = 3; // 0x3
- field public static final int VIDEO_STREAM_TYPE_MPEG4P2 = 4; // 0x4
- field public static final int VIDEO_STREAM_TYPE_RESERVED = 1; // 0x1
- field public static final int VIDEO_STREAM_TYPE_UNDEFINED = 0; // 0x0
- field public static final int VIDEO_STREAM_TYPE_VC1 = 7; // 0x7
- field public static final int VIDEO_STREAM_TYPE_VP8 = 8; // 0x8
- field public static final int VIDEO_STREAM_TYPE_VP9 = 9; // 0x9
- }
-
- public static class AvSettings.Builder {
- method @NonNull public android.media.tv.tuner.filter.AvSettings build();
- method @NonNull public android.media.tv.tuner.filter.AvSettings.Builder setAudioStreamType(int);
- method @NonNull public android.media.tv.tuner.filter.AvSettings.Builder setPassthrough(boolean);
- method @NonNull public android.media.tv.tuner.filter.AvSettings.Builder setVideoStreamType(int);
- }
-
- public class DownloadEvent extends android.media.tv.tuner.filter.FilterEvent {
- method public int getDataLength();
- method public int getItemFragmentIndex();
- method public int getItemId();
- method public int getLastItemFragmentIndex();
- method public int getMpuSequenceNumber();
- }
-
- public class DownloadSettings extends android.media.tv.tuner.filter.Settings {
- method @NonNull public static android.media.tv.tuner.filter.DownloadSettings.Builder builder(int);
- method public int getDownloadId();
- }
-
- public static class DownloadSettings.Builder {
- method @NonNull public android.media.tv.tuner.filter.DownloadSettings build();
- method @NonNull public android.media.tv.tuner.filter.DownloadSettings.Builder setDownloadId(int);
- }
-
- public class Filter implements java.lang.AutoCloseable {
- method public void close();
- method public int configure(@NonNull android.media.tv.tuner.filter.FilterConfiguration);
- method public int configureScramblingStatusEvent(int);
- method public int flush();
- method public int getId();
- method public long getId64Bit();
- method public int read(@NonNull byte[], long, long);
- method public int setDataSource(@Nullable android.media.tv.tuner.filter.Filter);
- method public int start();
- method public int stop();
- field public static final int SCRAMBLING_STATUS_NOT_SCRAMBLED = 2; // 0x2
- field public static final int SCRAMBLING_STATUS_SCRAMBLED = 4; // 0x4
- field public static final int SCRAMBLING_STATUS_UNKNOWN = 1; // 0x1
- field public static final int STATUS_DATA_READY = 1; // 0x1
- field public static final int STATUS_HIGH_WATER = 4; // 0x4
- field public static final int STATUS_LOW_WATER = 2; // 0x2
- field public static final int STATUS_OVERFLOW = 8; // 0x8
- field public static final int SUBTYPE_AUDIO = 3; // 0x3
- field public static final int SUBTYPE_DOWNLOAD = 5; // 0x5
- field public static final int SUBTYPE_IP = 13; // 0xd
- field public static final int SUBTYPE_IP_PAYLOAD = 12; // 0xc
- field public static final int SUBTYPE_MMTP = 10; // 0xa
- field public static final int SUBTYPE_NTP = 11; // 0xb
- field public static final int SUBTYPE_PAYLOAD_THROUGH = 14; // 0xe
- field public static final int SUBTYPE_PCR = 8; // 0x8
- field public static final int SUBTYPE_PES = 2; // 0x2
- field public static final int SUBTYPE_PTP = 16; // 0x10
- field public static final int SUBTYPE_RECORD = 6; // 0x6
- field public static final int SUBTYPE_SECTION = 1; // 0x1
- field public static final int SUBTYPE_TEMI = 9; // 0x9
- field public static final int SUBTYPE_TLV = 15; // 0xf
- field public static final int SUBTYPE_TS = 7; // 0x7
- field public static final int SUBTYPE_UNDEFINED = 0; // 0x0
- field public static final int SUBTYPE_VIDEO = 4; // 0x4
- field public static final int TYPE_ALP = 16; // 0x10
- field public static final int TYPE_IP = 4; // 0x4
- field public static final int TYPE_MMTP = 2; // 0x2
- field public static final int TYPE_TLV = 8; // 0x8
- field public static final int TYPE_TS = 1; // 0x1
- field public static final int TYPE_UNDEFINED = 0; // 0x0
- }
-
- public interface FilterCallback {
- method public void onFilterEvent(@NonNull android.media.tv.tuner.filter.Filter, @NonNull android.media.tv.tuner.filter.FilterEvent[]);
- method public void onFilterStatusChanged(@NonNull android.media.tv.tuner.filter.Filter, int);
- }
-
- public abstract class FilterConfiguration {
- method @Nullable public android.media.tv.tuner.filter.Settings getSettings();
- method public abstract int getType();
- }
-
- public abstract class FilterEvent {
- ctor public FilterEvent();
- }
-
- public final class IpFilterConfiguration extends android.media.tv.tuner.filter.FilterConfiguration {
- method @NonNull public static android.media.tv.tuner.filter.IpFilterConfiguration.Builder builder();
- method @NonNull @Size(min=4, max=16) public byte[] getDstIpAddress();
- method public int getDstPort();
- method @IntRange(from=0, to=61439) public int getIpFilterContextId();
- method @NonNull @Size(min=4, max=16) public byte[] getSrcIpAddress();
- method public int getSrcPort();
- method public int getType();
- method public boolean isPassthrough();
- field public static final int INVALID_IP_FILTER_CONTEXT_ID = -1; // 0xffffffff
- }
-
- public static final class IpFilterConfiguration.Builder {
- method @NonNull public android.media.tv.tuner.filter.IpFilterConfiguration build();
- method @NonNull public android.media.tv.tuner.filter.IpFilterConfiguration.Builder setDstIpAddress(@NonNull byte[]);
- method @NonNull public android.media.tv.tuner.filter.IpFilterConfiguration.Builder setDstPort(int);
- method @NonNull public android.media.tv.tuner.filter.IpFilterConfiguration.Builder setIpFilterContextId(int);
- method @NonNull public android.media.tv.tuner.filter.IpFilterConfiguration.Builder setPassthrough(boolean);
- method @NonNull public android.media.tv.tuner.filter.IpFilterConfiguration.Builder setSettings(@Nullable android.media.tv.tuner.filter.Settings);
- method @NonNull public android.media.tv.tuner.filter.IpFilterConfiguration.Builder setSrcIpAddress(@NonNull byte[]);
- method @NonNull public android.media.tv.tuner.filter.IpFilterConfiguration.Builder setSrcPort(int);
- }
-
- public class IpPayloadEvent extends android.media.tv.tuner.filter.FilterEvent {
- method public int getDataLength();
- }
-
- public class MediaEvent extends android.media.tv.tuner.filter.FilterEvent {
- method public long getAudioHandle();
- method public long getAvDataId();
- method public long getDataLength();
- method @Nullable public android.media.tv.tuner.filter.AudioDescriptor getExtraMetaData();
- method @Nullable public android.media.MediaCodec.LinearBlock getLinearBlock();
- method public int getMpuSequenceNumber();
- method public long getOffset();
- method public long getPts();
- method public int getStreamId();
- method public boolean isPrivateData();
- method public boolean isPtsPresent();
- method public boolean isSecureMemory();
- method public void release();
- }
-
- public final class MmtpFilterConfiguration extends android.media.tv.tuner.filter.FilterConfiguration {
- method @NonNull public static android.media.tv.tuner.filter.MmtpFilterConfiguration.Builder builder();
- method public int getMmtpPacketId();
- method public int getType();
- }
-
- public static final class MmtpFilterConfiguration.Builder {
- method @NonNull public android.media.tv.tuner.filter.MmtpFilterConfiguration build();
- method @NonNull public android.media.tv.tuner.filter.MmtpFilterConfiguration.Builder setMmtpPacketId(int);
- method @NonNull public android.media.tv.tuner.filter.MmtpFilterConfiguration.Builder setSettings(@Nullable android.media.tv.tuner.filter.Settings);
- }
-
- public class MmtpRecordEvent extends android.media.tv.tuner.filter.FilterEvent {
- method public long getDataLength();
- method public int getFirstMacroblockInSlice();
- method public int getMpuSequenceNumber();
- method public long getPts();
- method public int getScHevcIndexMask();
- method public int getTsIndexMask();
- }
-
- public class PesEvent extends android.media.tv.tuner.filter.FilterEvent {
- method public int getDataLength();
- method public int getMpuSequenceNumber();
- method public int getStreamId();
- }
-
- public class PesSettings extends android.media.tv.tuner.filter.Settings {
- method @NonNull public static android.media.tv.tuner.filter.PesSettings.Builder builder(int);
- method public int getStreamId();
- method public boolean isRaw();
- }
-
- public static class PesSettings.Builder {
- method @NonNull public android.media.tv.tuner.filter.PesSettings build();
- method @NonNull public android.media.tv.tuner.filter.PesSettings.Builder setRaw(boolean);
- method @NonNull public android.media.tv.tuner.filter.PesSettings.Builder setStreamId(int);
- }
-
- public class RecordSettings extends android.media.tv.tuner.filter.Settings {
- method @NonNull public static android.media.tv.tuner.filter.RecordSettings.Builder builder(int);
- method public int getScIndexMask();
- method public int getScIndexType();
- method public int getTsIndexMask();
- field public static final int INDEX_TYPE_NONE = 0; // 0x0
- field public static final int INDEX_TYPE_SC = 1; // 0x1
- field public static final int INDEX_TYPE_SC_HEVC = 2; // 0x2
- field public static final int MPT_INDEX_AUDIO = 262144; // 0x40000
- field public static final int MPT_INDEX_MPT = 65536; // 0x10000
- field public static final int MPT_INDEX_TIMESTAMP_TARGET_AUDIO = 1048576; // 0x100000
- field public static final int MPT_INDEX_TIMESTAMP_TARGET_VIDEO = 524288; // 0x80000
- field public static final int MPT_INDEX_VIDEO = 131072; // 0x20000
- field public static final int SC_HEVC_INDEX_AUD = 2; // 0x2
- field public static final int SC_HEVC_INDEX_SLICE_BLA_N_LP = 16; // 0x10
- field public static final int SC_HEVC_INDEX_SLICE_BLA_W_RADL = 8; // 0x8
- field public static final int SC_HEVC_INDEX_SLICE_CE_BLA_W_LP = 4; // 0x4
- field public static final int SC_HEVC_INDEX_SLICE_IDR_N_LP = 64; // 0x40
- field public static final int SC_HEVC_INDEX_SLICE_IDR_W_RADL = 32; // 0x20
- field public static final int SC_HEVC_INDEX_SLICE_TRAIL_CRA = 128; // 0x80
- field public static final int SC_HEVC_INDEX_SPS = 1; // 0x1
- field public static final int SC_INDEX_B_FRAME = 4; // 0x4
- field public static final int SC_INDEX_B_SLICE = 64; // 0x40
- field public static final int SC_INDEX_I_FRAME = 1; // 0x1
- field public static final int SC_INDEX_I_SLICE = 16; // 0x10
- field public static final int SC_INDEX_P_FRAME = 2; // 0x2
- field public static final int SC_INDEX_P_SLICE = 32; // 0x20
- field public static final int SC_INDEX_SEQUENCE = 8; // 0x8
- field public static final int SC_INDEX_SI_SLICE = 128; // 0x80
- field public static final int SC_INDEX_SP_SLICE = 256; // 0x100
- field public static final int TS_INDEX_ADAPTATION_EXTENSION_FLAG = 4096; // 0x1000
- field public static final int TS_INDEX_CHANGE_TO_EVEN_SCRAMBLED = 8; // 0x8
- field public static final int TS_INDEX_CHANGE_TO_NOT_SCRAMBLED = 4; // 0x4
- field public static final int TS_INDEX_CHANGE_TO_ODD_SCRAMBLED = 16; // 0x10
- field public static final int TS_INDEX_DISCONTINUITY_INDICATOR = 32; // 0x20
- field public static final int TS_INDEX_FIRST_PACKET = 1; // 0x1
- field public static final int TS_INDEX_INVALID = 0; // 0x0
- field public static final int TS_INDEX_OPCR_FLAG = 512; // 0x200
- field public static final int TS_INDEX_PAYLOAD_UNIT_START_INDICATOR = 2; // 0x2
- field public static final int TS_INDEX_PCR_FLAG = 256; // 0x100
- field public static final int TS_INDEX_PRIORITY_INDICATOR = 128; // 0x80
- field public static final int TS_INDEX_PRIVATE_DATA = 2048; // 0x800
- field public static final int TS_INDEX_RANDOM_ACCESS_INDICATOR = 64; // 0x40
- field public static final int TS_INDEX_SPLICING_POINT_FLAG = 1024; // 0x400
- }
-
- public static class RecordSettings.Builder {
- method @NonNull public android.media.tv.tuner.filter.RecordSettings build();
- method @NonNull public android.media.tv.tuner.filter.RecordSettings.Builder setScIndexMask(int);
- method @NonNull public android.media.tv.tuner.filter.RecordSettings.Builder setScIndexType(int);
- method @NonNull public android.media.tv.tuner.filter.RecordSettings.Builder setTsIndexMask(int);
- }
-
- public final class ScramblingStatusEvent extends android.media.tv.tuner.filter.FilterEvent {
- method public int getScramblingStatus();
- }
-
- public class SectionEvent extends android.media.tv.tuner.filter.FilterEvent {
- method public int getDataLength();
- method public int getSectionNumber();
- method public int getTableId();
- method public int getVersion();
- }
-
- public abstract class SectionSettings extends android.media.tv.tuner.filter.Settings {
- method public boolean isCrcEnabled();
- method public boolean isRaw();
- method public boolean isRepeat();
- }
-
- public abstract static class SectionSettings.Builder<T extends android.media.tv.tuner.filter.SectionSettings.Builder<T>> {
- method @NonNull public T setCrcEnabled(boolean);
- method @NonNull public T setRaw(boolean);
- method @NonNull public T setRepeat(boolean);
- }
-
- public class SectionSettingsWithSectionBits extends android.media.tv.tuner.filter.SectionSettings {
- method @NonNull public static android.media.tv.tuner.filter.SectionSettingsWithSectionBits.Builder builder(int);
- method @NonNull public byte[] getFilterBytes();
- method @NonNull public byte[] getMask();
- method @NonNull public byte[] getMode();
- }
-
- public static class SectionSettingsWithSectionBits.Builder extends android.media.tv.tuner.filter.SectionSettings.Builder<android.media.tv.tuner.filter.SectionSettingsWithSectionBits.Builder> {
- method @NonNull public android.media.tv.tuner.filter.SectionSettingsWithSectionBits build();
- method @NonNull public android.media.tv.tuner.filter.SectionSettingsWithSectionBits.Builder setFilter(@NonNull byte[]);
- method @NonNull public android.media.tv.tuner.filter.SectionSettingsWithSectionBits.Builder setMask(@NonNull byte[]);
- method @NonNull public android.media.tv.tuner.filter.SectionSettingsWithSectionBits.Builder setMode(@NonNull byte[]);
- }
-
- public class SectionSettingsWithTableInfo extends android.media.tv.tuner.filter.SectionSettings {
- method @NonNull public static android.media.tv.tuner.filter.SectionSettingsWithTableInfo.Builder builder(int);
- method public int getTableId();
- method public int getVersion();
- }
-
- public static class SectionSettingsWithTableInfo.Builder extends android.media.tv.tuner.filter.SectionSettings.Builder<android.media.tv.tuner.filter.SectionSettingsWithTableInfo.Builder> {
- method @NonNull public android.media.tv.tuner.filter.SectionSettingsWithTableInfo build();
- method @NonNull public android.media.tv.tuner.filter.SectionSettingsWithTableInfo.Builder setTableId(int);
- method @NonNull public android.media.tv.tuner.filter.SectionSettingsWithTableInfo.Builder setVersion(int);
- }
-
- public abstract class Settings {
- method public int getType();
- }
-
- public class TemiEvent extends android.media.tv.tuner.filter.FilterEvent {
- method @NonNull public byte[] getDescriptorData();
- method public byte getDescriptorTag();
- method public long getPts();
- }
-
- public class TimeFilter implements java.lang.AutoCloseable {
- method public int clearTimestamp();
- method public void close();
- method public long getSourceTime();
- method public long getTimeStamp();
- method public int setCurrentTimestamp(long);
- }
-
- public final class TlvFilterConfiguration extends android.media.tv.tuner.filter.FilterConfiguration {
- method @NonNull public static android.media.tv.tuner.filter.TlvFilterConfiguration.Builder builder();
- method public int getPacketType();
- method public int getType();
- method public boolean isCompressedIpPacket();
- method public boolean isPassthrough();
- field public static final int PACKET_TYPE_COMPRESSED = 3; // 0x3
- field public static final int PACKET_TYPE_IPV4 = 1; // 0x1
- field public static final int PACKET_TYPE_IPV6 = 2; // 0x2
- field public static final int PACKET_TYPE_NULL = 255; // 0xff
- field public static final int PACKET_TYPE_SIGNALING = 254; // 0xfe
- }
-
- public static final class TlvFilterConfiguration.Builder {
- method @NonNull public android.media.tv.tuner.filter.TlvFilterConfiguration build();
- method @NonNull public android.media.tv.tuner.filter.TlvFilterConfiguration.Builder setCompressedIpPacket(boolean);
- method @NonNull public android.media.tv.tuner.filter.TlvFilterConfiguration.Builder setPacketType(int);
- method @NonNull public android.media.tv.tuner.filter.TlvFilterConfiguration.Builder setPassthrough(boolean);
- method @NonNull public android.media.tv.tuner.filter.TlvFilterConfiguration.Builder setSettings(@Nullable android.media.tv.tuner.filter.Settings);
- }
-
- public final class TsFilterConfiguration extends android.media.tv.tuner.filter.FilterConfiguration {
- method @NonNull public static android.media.tv.tuner.filter.TsFilterConfiguration.Builder builder();
- method public int getTpid();
- method public int getType();
- }
-
- public static final class TsFilterConfiguration.Builder {
- method @NonNull public android.media.tv.tuner.filter.TsFilterConfiguration build();
- method @NonNull public android.media.tv.tuner.filter.TsFilterConfiguration.Builder setSettings(@Nullable android.media.tv.tuner.filter.Settings);
- method @NonNull public android.media.tv.tuner.filter.TsFilterConfiguration.Builder setTpid(int);
- }
-
- public class TsRecordEvent extends android.media.tv.tuner.filter.FilterEvent {
- method public long getDataLength();
- method public int getFirstMacroblockInSlice();
- method public int getPacketId();
- method public long getPts();
- method public int getScIndexMask();
- method public int getTsIndexMask();
- }
-
-}
-
-package android.media.tv.tuner.frontend {
-
- public class AnalogFrontendCapabilities extends android.media.tv.tuner.frontend.FrontendCapabilities {
- method public int getSifStandardCapability();
- method public int getSignalTypeCapability();
- }
-
- public class AnalogFrontendSettings extends android.media.tv.tuner.frontend.FrontendSettings {
- method @NonNull public static android.media.tv.tuner.frontend.AnalogFrontendSettings.Builder builder();
- method public int getAftFlag();
- method public int getSifStandard();
- method public int getSignalType();
- method public int getType();
- field public static final int AFT_FLAG_FALSE = 2; // 0x2
- field public static final int AFT_FLAG_TRUE = 1; // 0x1
- field public static final int AFT_FLAG_UNDEFINED = 0; // 0x0
- field public static final int SIF_AUTO = 1; // 0x1
- field public static final int SIF_BG = 2; // 0x2
- field public static final int SIF_BG_A2 = 4; // 0x4
- field public static final int SIF_BG_NICAM = 8; // 0x8
- field public static final int SIF_DK = 32; // 0x20
- field public static final int SIF_DK1_A2 = 64; // 0x40
- field public static final int SIF_DK2_A2 = 128; // 0x80
- field public static final int SIF_DK3_A2 = 256; // 0x100
- field public static final int SIF_DK_NICAM = 512; // 0x200
- field public static final int SIF_I = 16; // 0x10
- field public static final int SIF_I_NICAM = 32768; // 0x8000
- field public static final int SIF_L = 1024; // 0x400
- field public static final int SIF_L_NICAM = 65536; // 0x10000
- field public static final int SIF_L_PRIME = 131072; // 0x20000
- field public static final int SIF_M = 2048; // 0x800
- field public static final int SIF_M_A2 = 8192; // 0x2000
- field public static final int SIF_M_BTSC = 4096; // 0x1000
- field public static final int SIF_M_EIAJ = 16384; // 0x4000
- field public static final int SIF_UNDEFINED = 0; // 0x0
- field public static final int SIGNAL_TYPE_AUTO = 1; // 0x1
- field public static final int SIGNAL_TYPE_NTSC = 32; // 0x20
- field public static final int SIGNAL_TYPE_NTSC_443 = 64; // 0x40
- field public static final int SIGNAL_TYPE_PAL = 2; // 0x2
- field public static final int SIGNAL_TYPE_PAL_60 = 16; // 0x10
- field public static final int SIGNAL_TYPE_PAL_M = 4; // 0x4
- field public static final int SIGNAL_TYPE_PAL_N = 8; // 0x8
- field public static final int SIGNAL_TYPE_SECAM = 128; // 0x80
- field public static final int SIGNAL_TYPE_UNDEFINED = 0; // 0x0
- }
-
- public static class AnalogFrontendSettings.Builder {
- method @NonNull public android.media.tv.tuner.frontend.AnalogFrontendSettings build();
- method @NonNull public android.media.tv.tuner.frontend.AnalogFrontendSettings.Builder setAftFlag(int);
- method @IntRange(from=1) @NonNull public android.media.tv.tuner.frontend.AnalogFrontendSettings.Builder setFrequency(int);
- method @NonNull public android.media.tv.tuner.frontend.AnalogFrontendSettings.Builder setSifStandard(int);
- method @NonNull public android.media.tv.tuner.frontend.AnalogFrontendSettings.Builder setSignalType(int);
- }
-
- public class Atsc3FrontendCapabilities extends android.media.tv.tuner.frontend.FrontendCapabilities {
- method public int getBandwidthCapability();
- method public int getDemodOutputFormatCapability();
- method public int getFecCapability();
- method public int getModulationCapability();
- method public int getPlpCodeRateCapability();
- method public int getTimeInterleaveModeCapability();
- }
-
- public class Atsc3FrontendSettings extends android.media.tv.tuner.frontend.FrontendSettings {
- method @NonNull public static android.media.tv.tuner.frontend.Atsc3FrontendSettings.Builder builder();
- method public int getBandwidth();
- method public int getDemodOutputFormat();
- method @NonNull public android.media.tv.tuner.frontend.Atsc3PlpSettings[] getPlpSettings();
- method public int getType();
- field public static final int BANDWIDTH_AUTO = 1; // 0x1
- field public static final int BANDWIDTH_BANDWIDTH_6MHZ = 2; // 0x2
- field public static final int BANDWIDTH_BANDWIDTH_7MHZ = 4; // 0x4
- field public static final int BANDWIDTH_BANDWIDTH_8MHZ = 8; // 0x8
- field public static final int BANDWIDTH_UNDEFINED = 0; // 0x0
- field public static final int CODERATE_10_15 = 512; // 0x200
- field public static final int CODERATE_11_15 = 1024; // 0x400
- field public static final int CODERATE_12_15 = 2048; // 0x800
- field public static final int CODERATE_13_15 = 4096; // 0x1000
- field public static final int CODERATE_2_15 = 2; // 0x2
- field public static final int CODERATE_3_15 = 4; // 0x4
- field public static final int CODERATE_4_15 = 8; // 0x8
- field public static final int CODERATE_5_15 = 16; // 0x10
- field public static final int CODERATE_6_15 = 32; // 0x20
- field public static final int CODERATE_7_15 = 64; // 0x40
- field public static final int CODERATE_8_15 = 128; // 0x80
- field public static final int CODERATE_9_15 = 256; // 0x100
- field public static final int CODERATE_AUTO = 1; // 0x1
- field public static final int CODERATE_UNDEFINED = 0; // 0x0
- field public static final int DEMOD_OUTPUT_FORMAT_ATSC3_LINKLAYER_PACKET = 1; // 0x1
- field public static final int DEMOD_OUTPUT_FORMAT_BASEBAND_PACKET = 2; // 0x2
- field public static final int DEMOD_OUTPUT_FORMAT_UNDEFINED = 0; // 0x0
- field public static final int FEC_AUTO = 1; // 0x1
- field public static final int FEC_BCH_LDPC_16K = 2; // 0x2
- field public static final int FEC_BCH_LDPC_64K = 4; // 0x4
- field public static final int FEC_CRC_LDPC_16K = 8; // 0x8
- field public static final int FEC_CRC_LDPC_64K = 16; // 0x10
- field public static final int FEC_LDPC_16K = 32; // 0x20
- field public static final int FEC_LDPC_64K = 64; // 0x40
- field public static final int FEC_UNDEFINED = 0; // 0x0
- field public static final int MODULATION_AUTO = 1; // 0x1
- field public static final int MODULATION_MOD_1024QAM = 32; // 0x20
- field public static final int MODULATION_MOD_16QAM = 4; // 0x4
- field public static final int MODULATION_MOD_256QAM = 16; // 0x10
- field public static final int MODULATION_MOD_4096QAM = 64; // 0x40
- field public static final int MODULATION_MOD_64QAM = 8; // 0x8
- field public static final int MODULATION_MOD_QPSK = 2; // 0x2
- field public static final int MODULATION_UNDEFINED = 0; // 0x0
- field public static final int TIME_INTERLEAVE_MODE_AUTO = 1; // 0x1
- field public static final int TIME_INTERLEAVE_MODE_CTI = 2; // 0x2
- field public static final int TIME_INTERLEAVE_MODE_HTI = 4; // 0x4
- field public static final int TIME_INTERLEAVE_MODE_UNDEFINED = 0; // 0x0
- }
-
- public static class Atsc3FrontendSettings.Builder {
- method @NonNull public android.media.tv.tuner.frontend.Atsc3FrontendSettings build();
- method @NonNull public android.media.tv.tuner.frontend.Atsc3FrontendSettings.Builder setBandwidth(int);
- method @NonNull public android.media.tv.tuner.frontend.Atsc3FrontendSettings.Builder setDemodOutputFormat(int);
- method @IntRange(from=1) @NonNull public android.media.tv.tuner.frontend.Atsc3FrontendSettings.Builder setFrequency(int);
- method @NonNull public android.media.tv.tuner.frontend.Atsc3FrontendSettings.Builder setPlpSettings(@NonNull android.media.tv.tuner.frontend.Atsc3PlpSettings[]);
- }
-
- public class Atsc3PlpInfo {
- method public boolean getLlsFlag();
- method public int getPlpId();
- }
-
- public class Atsc3PlpSettings {
- method @NonNull public static android.media.tv.tuner.frontend.Atsc3PlpSettings.Builder builder();
- method public int getCodeRate();
- method public int getFec();
- method public int getInterleaveMode();
- method public int getModulation();
- method public int getPlpId();
- }
-
- public static class Atsc3PlpSettings.Builder {
- method @NonNull public android.media.tv.tuner.frontend.Atsc3PlpSettings build();
- method @NonNull public android.media.tv.tuner.frontend.Atsc3PlpSettings.Builder setCodeRate(int);
- method @NonNull public android.media.tv.tuner.frontend.Atsc3PlpSettings.Builder setFec(int);
- method @NonNull public android.media.tv.tuner.frontend.Atsc3PlpSettings.Builder setInterleaveMode(int);
- method @NonNull public android.media.tv.tuner.frontend.Atsc3PlpSettings.Builder setModulation(int);
- method @NonNull public android.media.tv.tuner.frontend.Atsc3PlpSettings.Builder setPlpId(int);
- }
-
- public class AtscFrontendCapabilities extends android.media.tv.tuner.frontend.FrontendCapabilities {
- method public int getModulationCapability();
- }
-
- public class AtscFrontendSettings extends android.media.tv.tuner.frontend.FrontendSettings {
- method @NonNull public static android.media.tv.tuner.frontend.AtscFrontendSettings.Builder builder();
- method public int getModulation();
- method public int getType();
- field public static final int MODULATION_AUTO = 1; // 0x1
- field public static final int MODULATION_MOD_16VSB = 8; // 0x8
- field public static final int MODULATION_MOD_8VSB = 4; // 0x4
- field public static final int MODULATION_UNDEFINED = 0; // 0x0
- }
-
- public static class AtscFrontendSettings.Builder {
- method @NonNull public android.media.tv.tuner.frontend.AtscFrontendSettings build();
- method @IntRange(from=1) @NonNull public android.media.tv.tuner.frontend.AtscFrontendSettings.Builder setFrequency(int);
- method @NonNull public android.media.tv.tuner.frontend.AtscFrontendSettings.Builder setModulation(int);
- }
-
- public final class DtmbFrontendCapabilities extends android.media.tv.tuner.frontend.FrontendCapabilities {
- method public int getBandwidthCapability();
- method public int getCodeRateCapability();
- method public int getGuardIntervalCapability();
- method public int getModulationCapability();
- method public int getTimeInterleaveModeCapability();
- method public int getTransmissionModeCapability();
- }
-
- public final class DtmbFrontendSettings extends android.media.tv.tuner.frontend.FrontendSettings {
- method @NonNull public static android.media.tv.tuner.frontend.DtmbFrontendSettings.Builder builder();
- method public int getBandwidth();
- method public int getCodeRate();
- method public int getGuardInterval();
- method public int getModulation();
- method public int getTimeInterleaveMode();
- method public int getTransmissionMode();
- method public int getType();
- field public static final int BANDWIDTH_6MHZ = 4; // 0x4
- field public static final int BANDWIDTH_8MHZ = 2; // 0x2
- field public static final int BANDWIDTH_AUTO = 1; // 0x1
- field public static final int BANDWIDTH_UNDEFINED = 0; // 0x0
- field public static final int CODERATE_2_5 = 2; // 0x2
- field public static final int CODERATE_3_5 = 4; // 0x4
- field public static final int CODERATE_4_5 = 8; // 0x8
- field public static final int CODERATE_AUTO = 1; // 0x1
- field public static final int CODERATE_UNDEFINED = 0; // 0x0
- field public static final int GUARD_INTERVAL_AUTO = 1; // 0x1
- field public static final int GUARD_INTERVAL_PN_420_CONST = 16; // 0x10
- field public static final int GUARD_INTERVAL_PN_420_VARIOUS = 2; // 0x2
- field public static final int GUARD_INTERVAL_PN_595_CONST = 4; // 0x4
- field public static final int GUARD_INTERVAL_PN_945_CONST = 32; // 0x20
- field public static final int GUARD_INTERVAL_PN_945_VARIOUS = 8; // 0x8
- field public static final int GUARD_INTERVAL_PN_RESERVED = 64; // 0x40
- field public static final int GUARD_INTERVAL_UNDEFINED = 0; // 0x0
- field public static final int MODULATION_CONSTELLATION_16QAM = 8; // 0x8
- field public static final int MODULATION_CONSTELLATION_32QAM = 16; // 0x10
- field public static final int MODULATION_CONSTELLATION_4QAM = 2; // 0x2
- field public static final int MODULATION_CONSTELLATION_4QAM_NR = 4; // 0x4
- field public static final int MODULATION_CONSTELLATION_64QAM = 32; // 0x20
- field public static final int MODULATION_CONSTELLATION_AUTO = 1; // 0x1
- field public static final int MODULATION_CONSTELLATION_UNDEFINED = 0; // 0x0
- field public static final int TIME_INTERLEAVE_MODE_AUTO = 1; // 0x1
- field public static final int TIME_INTERLEAVE_MODE_TIMER_INT_240 = 2; // 0x2
- field public static final int TIME_INTERLEAVE_MODE_TIMER_INT_720 = 4; // 0x4
- field public static final int TIME_INTERLEAVE_MODE_UNDEFINED = 0; // 0x0
- field public static final int TRANSMISSION_MODE_AUTO = 1; // 0x1
- field public static final int TRANSMISSION_MODE_C1 = 2; // 0x2
- field public static final int TRANSMISSION_MODE_C3780 = 4; // 0x4
- field public static final int TRANSMISSION_MODE_UNDEFINED = 0; // 0x0
- }
-
- public static final class DtmbFrontendSettings.Builder {
- method @NonNull public android.media.tv.tuner.frontend.DtmbFrontendSettings build();
- method @NonNull public android.media.tv.tuner.frontend.DtmbFrontendSettings.Builder setBandwidth(int);
- method @NonNull public android.media.tv.tuner.frontend.DtmbFrontendSettings.Builder setCodeRate(int);
- method @IntRange(from=1) @NonNull public android.media.tv.tuner.frontend.DtmbFrontendSettings.Builder setFrequency(int);
- method @NonNull public android.media.tv.tuner.frontend.DtmbFrontendSettings.Builder setGuardInterval(int);
- method @NonNull public android.media.tv.tuner.frontend.DtmbFrontendSettings.Builder setModulation(int);
- method @NonNull public android.media.tv.tuner.frontend.DtmbFrontendSettings.Builder setTimeInterleaveMode(int);
- method @NonNull public android.media.tv.tuner.frontend.DtmbFrontendSettings.Builder setTransmissionMode(int);
- }
-
- public class DvbcFrontendCapabilities extends android.media.tv.tuner.frontend.FrontendCapabilities {
- method public int getAnnexCapability();
- method public long getCodeRateCapability();
- method @Deprecated public int getFecCapability();
- method public int getModulationCapability();
- }
-
- public class DvbcFrontendSettings extends android.media.tv.tuner.frontend.FrontendSettings {
- method @NonNull public static android.media.tv.tuner.frontend.DvbcFrontendSettings.Builder builder();
- method public int getAnnex();
- method public int getBandwidth();
- method public long getInnerFec();
- method public int getModulation();
- method public int getOuterFec();
- method public int getSpectralInversion();
- method public int getSymbolRate();
- method public int getTimeInterleaveMode();
- method public int getType();
- field public static final int ANNEX_A = 1; // 0x1
- field public static final int ANNEX_B = 2; // 0x2
- field public static final int ANNEX_C = 4; // 0x4
- field public static final int ANNEX_UNDEFINED = 0; // 0x0
- field public static final int BANDWIDTH_5MHZ = 1; // 0x1
- field public static final int BANDWIDTH_6MHZ = 2; // 0x2
- field public static final int BANDWIDTH_7MHZ = 4; // 0x4
- field public static final int BANDWIDTH_8MHZ = 8; // 0x8
- field public static final int BANDWIDTH_UNDEFINED = 0; // 0x0
- field public static final int MODULATION_AUTO = 1; // 0x1
- field public static final int MODULATION_MOD_128QAM = 16; // 0x10
- field public static final int MODULATION_MOD_16QAM = 2; // 0x2
- field public static final int MODULATION_MOD_256QAM = 32; // 0x20
- field public static final int MODULATION_MOD_32QAM = 4; // 0x4
- field public static final int MODULATION_MOD_64QAM = 8; // 0x8
- field public static final int MODULATION_UNDEFINED = 0; // 0x0
- field public static final int OUTER_FEC_OUTER_FEC_NONE = 1; // 0x1
- field public static final int OUTER_FEC_OUTER_FEC_RS = 2; // 0x2
- field public static final int OUTER_FEC_UNDEFINED = 0; // 0x0
- field @Deprecated public static final int SPECTRAL_INVERSION_INVERTED = 2; // 0x2
- field @Deprecated public static final int SPECTRAL_INVERSION_NORMAL = 1; // 0x1
- field @Deprecated public static final int SPECTRAL_INVERSION_UNDEFINED = 0; // 0x0
- field public static final int TIME_INTERLEAVE_MODE_128_1_0 = 2; // 0x2
- field public static final int TIME_INTERLEAVE_MODE_128_1_1 = 4; // 0x4
- field public static final int TIME_INTERLEAVE_MODE_128_2 = 128; // 0x80
- field public static final int TIME_INTERLEAVE_MODE_128_3 = 256; // 0x100
- field public static final int TIME_INTERLEAVE_MODE_128_4 = 512; // 0x200
- field public static final int TIME_INTERLEAVE_MODE_16_8 = 32; // 0x20
- field public static final int TIME_INTERLEAVE_MODE_32_4 = 16; // 0x10
- field public static final int TIME_INTERLEAVE_MODE_64_2 = 8; // 0x8
- field public static final int TIME_INTERLEAVE_MODE_8_16 = 64; // 0x40
- field public static final int TIME_INTERLEAVE_MODE_AUTO = 1; // 0x1
- field public static final int TIME_INTERLEAVE_MODE_UNDEFINED = 0; // 0x0
- }
-
- public static class DvbcFrontendSettings.Builder {
- method @NonNull public android.media.tv.tuner.frontend.DvbcFrontendSettings build();
- method @NonNull public android.media.tv.tuner.frontend.DvbcFrontendSettings.Builder setAnnex(int);
- method @NonNull public android.media.tv.tuner.frontend.DvbcFrontendSettings.Builder setBandwidth(int);
- method @IntRange(from=1) @NonNull public android.media.tv.tuner.frontend.DvbcFrontendSettings.Builder setFrequency(int);
- method @NonNull public android.media.tv.tuner.frontend.DvbcFrontendSettings.Builder setInnerFec(long);
- method @NonNull public android.media.tv.tuner.frontend.DvbcFrontendSettings.Builder setModulation(int);
- method @NonNull public android.media.tv.tuner.frontend.DvbcFrontendSettings.Builder setOuterFec(int);
- method @NonNull public android.media.tv.tuner.frontend.DvbcFrontendSettings.Builder setSpectralInversion(int);
- method @NonNull public android.media.tv.tuner.frontend.DvbcFrontendSettings.Builder setSymbolRate(int);
- method @NonNull public android.media.tv.tuner.frontend.DvbcFrontendSettings.Builder setTimeInterleaveMode(int);
- }
-
- public class DvbsCodeRate {
- method @NonNull public static android.media.tv.tuner.frontend.DvbsCodeRate.Builder builder();
- method public int getBitsPer1000Symbol();
- method public long getInnerFec();
- method public boolean isLinear();
- method public boolean isShortFrameEnabled();
- }
-
- public static class DvbsCodeRate.Builder {
- method @NonNull public android.media.tv.tuner.frontend.DvbsCodeRate build();
- method @NonNull public android.media.tv.tuner.frontend.DvbsCodeRate.Builder setBitsPer1000Symbol(int);
- method @NonNull public android.media.tv.tuner.frontend.DvbsCodeRate.Builder setInnerFec(long);
- method @NonNull public android.media.tv.tuner.frontend.DvbsCodeRate.Builder setLinear(boolean);
- method @NonNull public android.media.tv.tuner.frontend.DvbsCodeRate.Builder setShortFrameEnabled(boolean);
- }
-
- public class DvbsFrontendCapabilities extends android.media.tv.tuner.frontend.FrontendCapabilities {
- method public long getInnerFecCapability();
- method public int getModulationCapability();
- method public int getStandardCapability();
- }
-
- public class DvbsFrontendSettings extends android.media.tv.tuner.frontend.FrontendSettings {
- method @NonNull public static android.media.tv.tuner.frontend.DvbsFrontendSettings.Builder builder();
- method @Nullable public android.media.tv.tuner.frontend.DvbsCodeRate getCodeRate();
- method public boolean getCouldHandleDiseqcRxMessage();
- method public int getInputStreamId();
- method public int getModulation();
- method public int getPilot();
- method public int getRolloff();
- method public int getScanType();
- method public int getStandard();
- method public int getSymbolRate();
- method public int getType();
- method public int getVcmMode();
- field public static final int MODULATION_AUTO = 1; // 0x1
- field public static final int MODULATION_MOD_128APSK = 2048; // 0x800
- field public static final int MODULATION_MOD_16APSK = 256; // 0x100
- field public static final int MODULATION_MOD_16PSK = 16; // 0x10
- field public static final int MODULATION_MOD_16QAM = 8; // 0x8
- field public static final int MODULATION_MOD_256APSK = 4096; // 0x1000
- field public static final int MODULATION_MOD_32APSK = 512; // 0x200
- field public static final int MODULATION_MOD_32PSK = 32; // 0x20
- field public static final int MODULATION_MOD_64APSK = 1024; // 0x400
- field public static final int MODULATION_MOD_8APSK = 128; // 0x80
- field public static final int MODULATION_MOD_8PSK = 4; // 0x4
- field public static final int MODULATION_MOD_ACM = 64; // 0x40
- field public static final int MODULATION_MOD_QPSK = 2; // 0x2
- field public static final int MODULATION_MOD_RESERVED = 8192; // 0x2000
- field public static final int MODULATION_UNDEFINED = 0; // 0x0
- field public static final int PILOT_AUTO = 3; // 0x3
- field public static final int PILOT_OFF = 2; // 0x2
- field public static final int PILOT_ON = 1; // 0x1
- field public static final int PILOT_UNDEFINED = 0; // 0x0
- field public static final int ROLLOFF_0_10 = 5; // 0x5
- field public static final int ROLLOFF_0_15 = 4; // 0x4
- field public static final int ROLLOFF_0_20 = 3; // 0x3
- field public static final int ROLLOFF_0_25 = 2; // 0x2
- field public static final int ROLLOFF_0_35 = 1; // 0x1
- field public static final int ROLLOFF_0_5 = 6; // 0x6
- field public static final int ROLLOFF_UNDEFINED = 0; // 0x0
- field public static final int SCAN_TYPE_DIRECT = 1; // 0x1
- field public static final int SCAN_TYPE_DISEQC = 2; // 0x2
- field public static final int SCAN_TYPE_JESS = 4; // 0x4
- field public static final int SCAN_TYPE_UNDEFINED = 0; // 0x0
- field public static final int SCAN_TYPE_UNICABLE = 3; // 0x3
- field public static final int STANDARD_AUTO = 1; // 0x1
- field public static final int STANDARD_S = 2; // 0x2
- field public static final int STANDARD_S2 = 4; // 0x4
- field public static final int STANDARD_S2X = 8; // 0x8
- field public static final int VCM_MODE_AUTO = 1; // 0x1
- field public static final int VCM_MODE_MANUAL = 2; // 0x2
- field public static final int VCM_MODE_UNDEFINED = 0; // 0x0
- }
-
- public static class DvbsFrontendSettings.Builder {
- method @NonNull public android.media.tv.tuner.frontend.DvbsFrontendSettings build();
- method @NonNull public android.media.tv.tuner.frontend.DvbsFrontendSettings.Builder setCodeRate(@Nullable android.media.tv.tuner.frontend.DvbsCodeRate);
- method @NonNull public android.media.tv.tuner.frontend.DvbsFrontendSettings.Builder setCouldHandleDiseqcRxMessage(boolean);
- method @IntRange(from=1) @NonNull public android.media.tv.tuner.frontend.DvbsFrontendSettings.Builder setFrequency(int);
- method @NonNull public android.media.tv.tuner.frontend.DvbsFrontendSettings.Builder setInputStreamId(int);
- method @NonNull public android.media.tv.tuner.frontend.DvbsFrontendSettings.Builder setModulation(int);
- method @NonNull public android.media.tv.tuner.frontend.DvbsFrontendSettings.Builder setPilot(int);
- method @NonNull public android.media.tv.tuner.frontend.DvbsFrontendSettings.Builder setRolloff(int);
- method @NonNull public android.media.tv.tuner.frontend.DvbsFrontendSettings.Builder setScanType(int);
- method @NonNull public android.media.tv.tuner.frontend.DvbsFrontendSettings.Builder setStandard(int);
- method @NonNull public android.media.tv.tuner.frontend.DvbsFrontendSettings.Builder setSymbolRate(int);
- method @NonNull public android.media.tv.tuner.frontend.DvbsFrontendSettings.Builder setVcmMode(int);
- }
-
- public class DvbtFrontendCapabilities extends android.media.tv.tuner.frontend.FrontendCapabilities {
- method public int getBandwidthCapability();
- method public int getCodeRateCapability();
- method public int getConstellationCapability();
- method public int getGuardIntervalCapability();
- method public int getHierarchyCapability();
- method public int getTransmissionModeCapability();
- method public boolean isMisoSupported();
- method public boolean isT2Supported();
- }
-
- public class DvbtFrontendSettings extends android.media.tv.tuner.frontend.FrontendSettings {
- method @NonNull public static android.media.tv.tuner.frontend.DvbtFrontendSettings.Builder builder();
- method public int getBandwidth();
- method public int getConstellation();
- method public int getGuardInterval();
- method public int getHierarchy();
- method public int getHighPriorityCodeRate();
- method public int getLowPriorityCodeRate();
- method public int getPlpGroupId();
- method public int getPlpId();
- method public int getPlpMode();
- method public int getStandard();
- method public int getTransmissionMode();
- method public int getType();
- method public boolean isHighPriority();
- method public boolean isMiso();
- field public static final int BANDWIDTH_10MHZ = 64; // 0x40
- field public static final int BANDWIDTH_1_7MHZ = 32; // 0x20
- field public static final int BANDWIDTH_5MHZ = 16; // 0x10
- field public static final int BANDWIDTH_6MHZ = 8; // 0x8
- field public static final int BANDWIDTH_7MHZ = 4; // 0x4
- field public static final int BANDWIDTH_8MHZ = 2; // 0x2
- field public static final int BANDWIDTH_AUTO = 1; // 0x1
- field public static final int BANDWIDTH_UNDEFINED = 0; // 0x0
- field public static final int CODERATE_1_2 = 2; // 0x2
- field public static final int CODERATE_2_3 = 4; // 0x4
- field public static final int CODERATE_3_4 = 8; // 0x8
- field public static final int CODERATE_3_5 = 64; // 0x40
- field public static final int CODERATE_4_5 = 128; // 0x80
- field public static final int CODERATE_5_6 = 16; // 0x10
- field public static final int CODERATE_6_7 = 256; // 0x100
- field public static final int CODERATE_7_8 = 32; // 0x20
- field public static final int CODERATE_8_9 = 512; // 0x200
- field public static final int CODERATE_AUTO = 1; // 0x1
- field public static final int CODERATE_UNDEFINED = 0; // 0x0
- field public static final int CONSTELLATION_16QAM = 4; // 0x4
- field public static final int CONSTELLATION_16QAM_R = 64; // 0x40
- field public static final int CONSTELLATION_256QAM = 16; // 0x10
- field public static final int CONSTELLATION_256QAM_R = 256; // 0x100
- field public static final int CONSTELLATION_64QAM = 8; // 0x8
- field public static final int CONSTELLATION_64QAM_R = 128; // 0x80
- field public static final int CONSTELLATION_AUTO = 1; // 0x1
- field public static final int CONSTELLATION_QPSK = 2; // 0x2
- field public static final int CONSTELLATION_QPSK_R = 32; // 0x20
- field public static final int CONSTELLATION_UNDEFINED = 0; // 0x0
- field public static final int GUARD_INTERVAL_19_128 = 64; // 0x40
- field public static final int GUARD_INTERVAL_19_256 = 128; // 0x80
- field public static final int GUARD_INTERVAL_1_128 = 32; // 0x20
- field public static final int GUARD_INTERVAL_1_16 = 4; // 0x4
- field public static final int GUARD_INTERVAL_1_32 = 2; // 0x2
- field public static final int GUARD_INTERVAL_1_4 = 16; // 0x10
- field public static final int GUARD_INTERVAL_1_8 = 8; // 0x8
- field public static final int GUARD_INTERVAL_AUTO = 1; // 0x1
- field public static final int GUARD_INTERVAL_UNDEFINED = 0; // 0x0
- field public static final int HIERARCHY_1_INDEPTH = 64; // 0x40
- field public static final int HIERARCHY_1_NATIVE = 4; // 0x4
- field public static final int HIERARCHY_2_INDEPTH = 128; // 0x80
- field public static final int HIERARCHY_2_NATIVE = 8; // 0x8
- field public static final int HIERARCHY_4_INDEPTH = 256; // 0x100
- field public static final int HIERARCHY_4_NATIVE = 16; // 0x10
- field public static final int HIERARCHY_AUTO = 1; // 0x1
- field public static final int HIERARCHY_NON_INDEPTH = 32; // 0x20
- field public static final int HIERARCHY_NON_NATIVE = 2; // 0x2
- field public static final int HIERARCHY_UNDEFINED = 0; // 0x0
- field public static final int PLP_MODE_AUTO = 1; // 0x1
- field public static final int PLP_MODE_MANUAL = 2; // 0x2
- field public static final int PLP_MODE_UNDEFINED = 0; // 0x0
- field public static final int STANDARD_AUTO = 1; // 0x1
- field public static final int STANDARD_T = 2; // 0x2
- field public static final int STANDARD_T2 = 4; // 0x4
- field public static final int TRANSMISSION_MODE_16K = 32; // 0x20
- field public static final int TRANSMISSION_MODE_1K = 16; // 0x10
- field public static final int TRANSMISSION_MODE_2K = 2; // 0x2
- field public static final int TRANSMISSION_MODE_32K = 64; // 0x40
- field public static final int TRANSMISSION_MODE_4K = 8; // 0x8
- field public static final int TRANSMISSION_MODE_8K = 4; // 0x4
- field public static final int TRANSMISSION_MODE_AUTO = 1; // 0x1
- field public static final int TRANSMISSION_MODE_EXTENDED_16K = 256; // 0x100
- field public static final int TRANSMISSION_MODE_EXTENDED_32K = 512; // 0x200
- field public static final int TRANSMISSION_MODE_EXTENDED_8K = 128; // 0x80
- field public static final int TRANSMISSION_MODE_UNDEFINED = 0; // 0x0
- }
-
- public static class DvbtFrontendSettings.Builder {
- method @NonNull public android.media.tv.tuner.frontend.DvbtFrontendSettings build();
- method @NonNull public android.media.tv.tuner.frontend.DvbtFrontendSettings.Builder setBandwidth(int);
- method @NonNull public android.media.tv.tuner.frontend.DvbtFrontendSettings.Builder setConstellation(int);
- method @IntRange(from=1) @NonNull public android.media.tv.tuner.frontend.DvbtFrontendSettings.Builder setFrequency(int);
- method @NonNull public android.media.tv.tuner.frontend.DvbtFrontendSettings.Builder setGuardInterval(int);
- method @NonNull public android.media.tv.tuner.frontend.DvbtFrontendSettings.Builder setHierarchy(int);
- method @NonNull public android.media.tv.tuner.frontend.DvbtFrontendSettings.Builder setHighPriority(boolean);
- method @NonNull public android.media.tv.tuner.frontend.DvbtFrontendSettings.Builder setHighPriorityCodeRate(int);
- method @NonNull public android.media.tv.tuner.frontend.DvbtFrontendSettings.Builder setLowPriorityCodeRate(int);
- method @NonNull public android.media.tv.tuner.frontend.DvbtFrontendSettings.Builder setMiso(boolean);
- method @NonNull public android.media.tv.tuner.frontend.DvbtFrontendSettings.Builder setPlpGroupId(int);
- method @NonNull public android.media.tv.tuner.frontend.DvbtFrontendSettings.Builder setPlpId(int);
- method @NonNull public android.media.tv.tuner.frontend.DvbtFrontendSettings.Builder setPlpMode(int);
- method @NonNull public android.media.tv.tuner.frontend.DvbtFrontendSettings.Builder setStandard(int);
- method @NonNull public android.media.tv.tuner.frontend.DvbtFrontendSettings.Builder setTransmissionMode(int);
- }
-
- public abstract class FrontendCapabilities {
- ctor public FrontendCapabilities();
- }
-
- public class FrontendInfo {
- method public int getAcquireRange();
- method public int getExclusiveGroupId();
- method @NonNull public android.util.Range<java.lang.Integer> getFrequencyRange();
- method @NonNull public android.media.tv.tuner.frontend.FrontendCapabilities getFrontendCapabilities();
- method public int getId();
- method @NonNull public int[] getStatusCapabilities();
- method @NonNull public android.util.Range<java.lang.Integer> getSymbolRateRange();
- method public int getType();
- }
-
- public abstract class FrontendSettings {
- method @IntRange(from=1) public int getEndFrequency();
- method public int getFrequency();
- method public int getFrontendSpectralInversion();
- method public abstract int getType();
- method @IntRange(from=1) public void setEndFrequency(int);
- method public void setSpectralInversion(int);
- field public static final long FEC_11_15 = 4194304L; // 0x400000L
- field public static final long FEC_11_20 = 8388608L; // 0x800000L
- field public static final long FEC_11_45 = 16777216L; // 0x1000000L
- field public static final long FEC_13_18 = 33554432L; // 0x2000000L
- field public static final long FEC_13_45 = 67108864L; // 0x4000000L
- field public static final long FEC_14_45 = 134217728L; // 0x8000000L
- field public static final long FEC_1_2 = 2L; // 0x2L
- field public static final long FEC_1_3 = 4L; // 0x4L
- field public static final long FEC_1_4 = 8L; // 0x8L
- field public static final long FEC_1_5 = 16L; // 0x10L
- field public static final long FEC_23_36 = 268435456L; // 0x10000000L
- field public static final long FEC_25_36 = 536870912L; // 0x20000000L
- field public static final long FEC_26_45 = 1073741824L; // 0x40000000L
- field public static final long FEC_28_45 = -2147483648L; // 0xffffffff80000000L
- field public static final long FEC_29_45 = 1L; // 0x1L
- field public static final long FEC_2_3 = 32L; // 0x20L
- field public static final long FEC_2_5 = 64L; // 0x40L
- field public static final long FEC_2_9 = 128L; // 0x80L
- field public static final long FEC_31_45 = 2L; // 0x2L
- field public static final long FEC_32_45 = 4L; // 0x4L
- field public static final long FEC_3_4 = 256L; // 0x100L
- field public static final long FEC_3_5 = 512L; // 0x200L
- field public static final long FEC_4_15 = 2048L; // 0x800L
- field public static final long FEC_4_5 = 1024L; // 0x400L
- field public static final long FEC_5_6 = 4096L; // 0x1000L
- field public static final long FEC_5_9 = 8192L; // 0x2000L
- field public static final long FEC_6_7 = 16384L; // 0x4000L
- field public static final long FEC_77_90 = 8L; // 0x8L
- field public static final long FEC_7_15 = 131072L; // 0x20000L
- field public static final long FEC_7_8 = 32768L; // 0x8000L
- field public static final long FEC_7_9 = 65536L; // 0x10000L
- field public static final long FEC_8_15 = 524288L; // 0x80000L
- field public static final long FEC_8_9 = 262144L; // 0x40000L
- field public static final long FEC_9_10 = 1048576L; // 0x100000L
- field public static final long FEC_9_20 = 2097152L; // 0x200000L
- field public static final long FEC_AUTO = 1L; // 0x1L
- field public static final long FEC_UNDEFINED = 0L; // 0x0L
- field public static final int FRONTEND_SPECTRAL_INVERSION_INVERTED = 2; // 0x2
- field public static final int FRONTEND_SPECTRAL_INVERSION_NORMAL = 1; // 0x1
- field public static final int FRONTEND_SPECTRAL_INVERSION_UNDEFINED = 0; // 0x0
- field public static final int TYPE_ANALOG = 1; // 0x1
- field public static final int TYPE_ATSC = 2; // 0x2
- field public static final int TYPE_ATSC3 = 3; // 0x3
- field public static final int TYPE_DTMB = 10; // 0xa
- field public static final int TYPE_DVBC = 4; // 0x4
- field public static final int TYPE_DVBS = 5; // 0x5
- field public static final int TYPE_DVBT = 6; // 0x6
- field public static final int TYPE_ISDBS = 7; // 0x7
- field public static final int TYPE_ISDBS3 = 8; // 0x8
- field public static final int TYPE_ISDBT = 9; // 0x9
- field public static final int TYPE_UNDEFINED = 0; // 0x0
- }
-
- public class FrontendStatus {
- method public int getAgc();
- method @NonNull public android.media.tv.tuner.frontend.FrontendStatus.Atsc3PlpTuningInfo[] getAtsc3PlpTuningInfo();
- method public int getBandwidth();
- method public int getBer();
- method @NonNull public int[] getBers();
- method @NonNull public int[] getCodeRates();
- method @NonNull public int[] getExtendedModulations();
- method public int getFreqOffset();
- method public int getGuardInterval();
- method public int getHierarchy();
- method public long getInnerFec();
- method @NonNull public int[] getInterleaving();
- method @IntRange(from=0, to=255) @NonNull public int[] getIsdbtSegment();
- method @NonNull public boolean[] getLayerErrors();
- method public int getLnbVoltage();
- method public int getMer();
- method public int getModulation();
- method public int getPer();
- method public int getPerBer();
- method public int getPlpId();
- method public int getRollOff();
- method public int getSignalQuality();
- method public int getSignalStrength();
- method public int getSnr();
- method public int getSpectralInversion();
- method public int getSymbolRate();
- method @IntRange(from=0, to=65535) public int getSystemId();
- method public int getTransmissionMode();
- method @NonNull public int[] getTsDataRate();
- method public int getUec();
- method public boolean isDemodLocked();
- method public boolean isEwbs();
- method public boolean isLinear();
- method public boolean isLnaOn();
- method public boolean isMisoEnabled();
- method public boolean isRfLocked();
- method public boolean isShortFramesEnabled();
- field public static final int FRONTEND_STATUS_TYPE_AGC = 14; // 0xe
- field public static final int FRONTEND_STATUS_TYPE_ATSC3_PLP_INFO = 21; // 0x15
- field public static final int FRONTEND_STATUS_TYPE_BANDWIDTH = 25; // 0x19
- field public static final int FRONTEND_STATUS_TYPE_BER = 2; // 0x2
- field public static final int FRONTEND_STATUS_TYPE_BERS = 23; // 0x17
- field public static final int FRONTEND_STATUS_TYPE_CODERATES = 24; // 0x18
- field public static final int FRONTEND_STATUS_TYPE_DEMOD_LOCK = 0; // 0x0
- field public static final int FRONTEND_STATUS_TYPE_EWBS = 13; // 0xd
- field public static final int FRONTEND_STATUS_TYPE_FEC = 8; // 0x8
- field public static final int FRONTEND_STATUS_TYPE_FREQ_OFFSET = 18; // 0x12
- field public static final int FRONTEND_STATUS_TYPE_GUARD_INTERVAL = 26; // 0x1a
- field public static final int FRONTEND_STATUS_TYPE_HIERARCHY = 19; // 0x13
- field public static final int FRONTEND_STATUS_TYPE_INTERLEAVINGS = 30; // 0x1e
- field public static final int FRONTEND_STATUS_TYPE_ISDBT_SEGMENTS = 31; // 0x1f
- field public static final int FRONTEND_STATUS_TYPE_IS_LINEAR = 35; // 0x23
- field public static final int FRONTEND_STATUS_TYPE_IS_MISO = 34; // 0x22
- field public static final int FRONTEND_STATUS_TYPE_IS_SHORT_FRAMES = 36; // 0x24
- field public static final int FRONTEND_STATUS_TYPE_LAYER_ERROR = 16; // 0x10
- field public static final int FRONTEND_STATUS_TYPE_LNA = 15; // 0xf
- field public static final int FRONTEND_STATUS_TYPE_LNB_VOLTAGE = 11; // 0xb
- field public static final int FRONTEND_STATUS_TYPE_MER = 17; // 0x11
- field public static final int FRONTEND_STATUS_TYPE_MODULATION = 9; // 0x9
- field public static final int FRONTEND_STATUS_TYPE_MODULATIONS_EXT = 22; // 0x16
- field public static final int FRONTEND_STATUS_TYPE_PER = 3; // 0x3
- field public static final int FRONTEND_STATUS_TYPE_PLP_ID = 12; // 0xc
- field public static final int FRONTEND_STATUS_TYPE_PRE_BER = 4; // 0x4
- field public static final int FRONTEND_STATUS_TYPE_RF_LOCK = 20; // 0x14
- field public static final int FRONTEND_STATUS_TYPE_ROLL_OFF = 33; // 0x21
- field public static final int FRONTEND_STATUS_TYPE_SIGNAL_QUALITY = 5; // 0x5
- field public static final int FRONTEND_STATUS_TYPE_SIGNAL_STRENGTH = 6; // 0x6
- field public static final int FRONTEND_STATUS_TYPE_SNR = 1; // 0x1
- field public static final int FRONTEND_STATUS_TYPE_SPECTRAL = 10; // 0xa
- field public static final int FRONTEND_STATUS_TYPE_SYMBOL_RATE = 7; // 0x7
- field public static final int FRONTEND_STATUS_TYPE_T2_SYSTEM_ID = 29; // 0x1d
- field public static final int FRONTEND_STATUS_TYPE_TRANSMISSION_MODE = 27; // 0x1b
- field public static final int FRONTEND_STATUS_TYPE_TS_DATA_RATES = 32; // 0x20
- field public static final int FRONTEND_STATUS_TYPE_UEC = 28; // 0x1c
- }
-
- public static class FrontendStatus.Atsc3PlpTuningInfo {
- method public int getPlpId();
- method public int getUec();
- method public boolean isLocked();
- }
-
- public class Isdbs3FrontendCapabilities extends android.media.tv.tuner.frontend.FrontendCapabilities {
- method public int getCodeRateCapability();
- method public int getModulationCapability();
- }
-
- public class Isdbs3FrontendSettings extends android.media.tv.tuner.frontend.FrontendSettings {
- method @NonNull public static android.media.tv.tuner.frontend.Isdbs3FrontendSettings.Builder builder();
- method public int getCodeRate();
- method public int getModulation();
- method public int getRolloff();
- method public int getStreamId();
- method public int getStreamIdType();
- method public int getSymbolRate();
- method public int getType();
- field public static final int CODERATE_1_2 = 8; // 0x8
- field public static final int CODERATE_1_3 = 2; // 0x2
- field public static final int CODERATE_2_3 = 32; // 0x20
- field public static final int CODERATE_2_5 = 4; // 0x4
- field public static final int CODERATE_3_4 = 64; // 0x40
- field public static final int CODERATE_3_5 = 16; // 0x10
- field public static final int CODERATE_4_5 = 256; // 0x100
- field public static final int CODERATE_5_6 = 512; // 0x200
- field public static final int CODERATE_7_8 = 1024; // 0x400
- field public static final int CODERATE_7_9 = 128; // 0x80
- field public static final int CODERATE_9_10 = 2048; // 0x800
- field public static final int CODERATE_AUTO = 1; // 0x1
- field public static final int CODERATE_UNDEFINED = 0; // 0x0
- field public static final int MODULATION_AUTO = 1; // 0x1
- field public static final int MODULATION_MOD_16APSK = 16; // 0x10
- field public static final int MODULATION_MOD_32APSK = 32; // 0x20
- field public static final int MODULATION_MOD_8PSK = 8; // 0x8
- field public static final int MODULATION_MOD_BPSK = 2; // 0x2
- field public static final int MODULATION_MOD_QPSK = 4; // 0x4
- field public static final int MODULATION_UNDEFINED = 0; // 0x0
- field public static final int ROLLOFF_0_03 = 1; // 0x1
- field public static final int ROLLOFF_UNDEFINED = 0; // 0x0
- }
-
- public static class Isdbs3FrontendSettings.Builder {
- method @NonNull public android.media.tv.tuner.frontend.Isdbs3FrontendSettings build();
- method @NonNull public android.media.tv.tuner.frontend.Isdbs3FrontendSettings.Builder setCodeRate(int);
- method @IntRange(from=1) @NonNull public android.media.tv.tuner.frontend.Isdbs3FrontendSettings.Builder setFrequency(int);
- method @NonNull public android.media.tv.tuner.frontend.Isdbs3FrontendSettings.Builder setModulation(int);
- method @NonNull public android.media.tv.tuner.frontend.Isdbs3FrontendSettings.Builder setRolloff(int);
- method @NonNull public android.media.tv.tuner.frontend.Isdbs3FrontendSettings.Builder setStreamId(int);
- method @NonNull public android.media.tv.tuner.frontend.Isdbs3FrontendSettings.Builder setStreamIdType(int);
- method @NonNull public android.media.tv.tuner.frontend.Isdbs3FrontendSettings.Builder setSymbolRate(int);
- }
-
- public class IsdbsFrontendCapabilities extends android.media.tv.tuner.frontend.FrontendCapabilities {
- method public int getCodeRateCapability();
- method public int getModulationCapability();
- }
-
- public class IsdbsFrontendSettings extends android.media.tv.tuner.frontend.FrontendSettings {
- method @NonNull public static android.media.tv.tuner.frontend.IsdbsFrontendSettings.Builder builder();
- method public int getCodeRate();
- method public int getModulation();
- method public int getRolloff();
- method public int getStreamId();
- method public int getStreamIdType();
- method public int getSymbolRate();
- method public int getType();
- field public static final int CODERATE_1_2 = 2; // 0x2
- field public static final int CODERATE_2_3 = 4; // 0x4
- field public static final int CODERATE_3_4 = 8; // 0x8
- field public static final int CODERATE_5_6 = 16; // 0x10
- field public static final int CODERATE_7_8 = 32; // 0x20
- field public static final int CODERATE_AUTO = 1; // 0x1
- field public static final int CODERATE_UNDEFINED = 0; // 0x0
- field public static final int MODULATION_AUTO = 1; // 0x1
- field public static final int MODULATION_MOD_BPSK = 2; // 0x2
- field public static final int MODULATION_MOD_QPSK = 4; // 0x4
- field public static final int MODULATION_MOD_TC8PSK = 8; // 0x8
- field public static final int MODULATION_UNDEFINED = 0; // 0x0
- field public static final int ROLLOFF_0_35 = 1; // 0x1
- field public static final int ROLLOFF_UNDEFINED = 0; // 0x0
- field public static final int STREAM_ID_TYPE_ID = 0; // 0x0
- field public static final int STREAM_ID_TYPE_RELATIVE_NUMBER = 1; // 0x1
- }
-
- public static class IsdbsFrontendSettings.Builder {
- method @NonNull public android.media.tv.tuner.frontend.IsdbsFrontendSettings build();
- method @NonNull public android.media.tv.tuner.frontend.IsdbsFrontendSettings.Builder setCodeRate(int);
- method @IntRange(from=1) @NonNull public android.media.tv.tuner.frontend.IsdbsFrontendSettings.Builder setFrequency(int);
- method @NonNull public android.media.tv.tuner.frontend.IsdbsFrontendSettings.Builder setModulation(int);
- method @NonNull public android.media.tv.tuner.frontend.IsdbsFrontendSettings.Builder setRolloff(int);
- method @NonNull public android.media.tv.tuner.frontend.IsdbsFrontendSettings.Builder setStreamId(int);
- method @NonNull public android.media.tv.tuner.frontend.IsdbsFrontendSettings.Builder setStreamIdType(int);
- method @NonNull public android.media.tv.tuner.frontend.IsdbsFrontendSettings.Builder setSymbolRate(int);
- }
-
- public class IsdbtFrontendCapabilities extends android.media.tv.tuner.frontend.FrontendCapabilities {
- method public int getBandwidthCapability();
- method public int getCodeRateCapability();
- method public int getGuardIntervalCapability();
- method public int getModeCapability();
- method public int getModulationCapability();
- }
-
- public class IsdbtFrontendSettings extends android.media.tv.tuner.frontend.FrontendSettings {
- method @NonNull public static android.media.tv.tuner.frontend.IsdbtFrontendSettings.Builder builder();
- method public int getBandwidth();
- method public int getCodeRate();
- method public int getGuardInterval();
- method public int getMode();
- method public int getModulation();
- method public int getServiceAreaId();
- method public int getType();
- field public static final int BANDWIDTH_6MHZ = 8; // 0x8
- field public static final int BANDWIDTH_7MHZ = 4; // 0x4
- field public static final int BANDWIDTH_8MHZ = 2; // 0x2
- field public static final int BANDWIDTH_AUTO = 1; // 0x1
- field public static final int BANDWIDTH_UNDEFINED = 0; // 0x0
- field public static final int MODE_1 = 2; // 0x2
- field public static final int MODE_2 = 4; // 0x4
- field public static final int MODE_3 = 8; // 0x8
- field public static final int MODE_AUTO = 1; // 0x1
- field public static final int MODE_UNDEFINED = 0; // 0x0
- field public static final int MODULATION_AUTO = 1; // 0x1
- field public static final int MODULATION_MOD_16QAM = 8; // 0x8
- field public static final int MODULATION_MOD_64QAM = 16; // 0x10
- field public static final int MODULATION_MOD_DQPSK = 2; // 0x2
- field public static final int MODULATION_MOD_QPSK = 4; // 0x4
- field public static final int MODULATION_UNDEFINED = 0; // 0x0
- }
-
- public static class IsdbtFrontendSettings.Builder {
- method @NonNull public android.media.tv.tuner.frontend.IsdbtFrontendSettings build();
- method @NonNull public android.media.tv.tuner.frontend.IsdbtFrontendSettings.Builder setBandwidth(int);
- method @NonNull public android.media.tv.tuner.frontend.IsdbtFrontendSettings.Builder setCodeRate(int);
- method @IntRange(from=1) @NonNull public android.media.tv.tuner.frontend.IsdbtFrontendSettings.Builder setFrequency(int);
- method @NonNull public android.media.tv.tuner.frontend.IsdbtFrontendSettings.Builder setGuardInterval(int);
- method @NonNull public android.media.tv.tuner.frontend.IsdbtFrontendSettings.Builder setMode(int);
- method @NonNull public android.media.tv.tuner.frontend.IsdbtFrontendSettings.Builder setModulation(int);
- method @NonNull public android.media.tv.tuner.frontend.IsdbtFrontendSettings.Builder setServiceAreaId(int);
- }
-
- public interface OnTuneEventListener {
- method public void onTuneEvent(int);
- field public static final int SIGNAL_LOCKED = 0; // 0x0
- field public static final int SIGNAL_LOST_LOCK = 2; // 0x2
- field public static final int SIGNAL_NO_SIGNAL = 1; // 0x1
- }
-
- public interface ScanCallback {
- method public void onAnalogSifStandardReported(int);
- method public void onAtsc3PlpInfosReported(@NonNull android.media.tv.tuner.frontend.Atsc3PlpInfo[]);
- method public default void onDvbcAnnexReported(int);
- method public void onDvbsStandardReported(int);
- method public void onDvbtStandardReported(int);
- method public void onFrequenciesReported(@NonNull int[]);
- method public void onGroupIdsReported(@NonNull int[]);
- method public void onHierarchyReported(int);
- method public void onInputStreamIdsReported(@NonNull int[]);
- method public void onLocked();
- method public default void onModulationReported(int);
- method public void onPlpIdsReported(@NonNull int[]);
- method public default void onPriorityReported(boolean);
- method public void onProgress(@IntRange(from=0, to=100) int);
- method public void onScanStopped();
- method public void onSignalTypeReported(int);
- method public void onSymbolRatesReported(@NonNull int[]);
- }
-
-}
-
-package android.media.voice {
-
- public final class KeyphraseModelManager {
- method @RequiresPermission("android.permission.MANAGE_VOICE_KEYPHRASES") public void deleteKeyphraseSoundModel(int, @NonNull java.util.Locale);
- method @Nullable @RequiresPermission("android.permission.MANAGE_VOICE_KEYPHRASES") public android.hardware.soundtrigger.SoundTrigger.KeyphraseSoundModel getKeyphraseSoundModel(int, @NonNull java.util.Locale);
- method @RequiresPermission("android.permission.MANAGE_VOICE_KEYPHRASES") public void updateKeyphraseSoundModel(@NonNull android.hardware.soundtrigger.SoundTrigger.KeyphraseSoundModel);
- }
-
-}
-
-package android.metrics {
-
- public class LogMaker {
- ctor public LogMaker(int);
- ctor public LogMaker(Object[]);
- method public android.metrics.LogMaker addTaggedData(int, Object);
- method public android.metrics.LogMaker clearCategory();
- method public android.metrics.LogMaker clearPackageName();
- method public android.metrics.LogMaker clearSubtype();
- method public android.metrics.LogMaker clearTaggedData(int);
- method public android.metrics.LogMaker clearType();
- method public void deserialize(Object[]);
- method public int getCategory();
- method public long getCounterBucket();
- method public String getCounterName();
- method public int getCounterValue();
- method public String getPackageName();
- method public int getProcessId();
- method public int getSubtype();
- method public Object getTaggedData(int);
- method public long getTimestamp();
- method public int getType();
- method public int getUid();
- method public boolean isLongCounterBucket();
- method public boolean isSubsetOf(android.metrics.LogMaker);
- method public boolean isValidValue(Object);
- method public Object[] serialize();
- method public android.metrics.LogMaker setCategory(int);
- method public android.metrics.LogMaker setPackageName(String);
- method public android.metrics.LogMaker setSubtype(int);
- method public android.metrics.LogMaker setType(int);
- }
-
- public class MetricsReader {
- ctor public MetricsReader();
- method public void checkpoint();
- method public boolean hasNext();
- method public android.metrics.LogMaker next();
- method public void read(long);
- method public void reset();
- }
-
-}
-
-package android.net {
-
- public class CaptivePortal implements android.os.Parcelable {
- method public void logEvent(int, @NonNull String);
- method @RequiresPermission(android.Manifest.permission.NETWORK_STACK) public void reevaluateNetwork();
- method public void useNetwork();
- field public static final int APP_REQUEST_REEVALUATION_REQUIRED = 100; // 0x64
- field public static final int APP_RETURN_DISMISSED = 0; // 0x0
- field public static final int APP_RETURN_UNWANTED = 1; // 0x1
- field public static final int APP_RETURN_WANTED_AS_IS = 2; // 0x2
- }
-
- public final class CaptivePortalData implements android.os.Parcelable {
- method public int describeContents();
- method public long getByteLimit();
- method public long getExpiryTimeMillis();
- method public long getRefreshTimeMillis();
- method @Nullable public android.net.Uri getUserPortalUrl();
- method @Nullable public android.net.Uri getVenueInfoUrl();
- method public boolean isCaptive();
- method public boolean isSessionExtendable();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.net.CaptivePortalData> CREATOR;
- }
-
- public static class CaptivePortalData.Builder {
- ctor public CaptivePortalData.Builder();
- ctor public CaptivePortalData.Builder(@Nullable android.net.CaptivePortalData);
- method @NonNull public android.net.CaptivePortalData build();
- method @NonNull public android.net.CaptivePortalData.Builder setBytesRemaining(long);
- method @NonNull public android.net.CaptivePortalData.Builder setCaptive(boolean);
- method @NonNull public android.net.CaptivePortalData.Builder setExpiryTime(long);
- method @NonNull public android.net.CaptivePortalData.Builder setRefreshTime(long);
- method @NonNull public android.net.CaptivePortalData.Builder setSessionExtendable(boolean);
- method @NonNull public android.net.CaptivePortalData.Builder setUserPortalUrl(@Nullable android.net.Uri);
- method @NonNull public android.net.CaptivePortalData.Builder setVenueInfoUrl(@Nullable android.net.Uri);
- }
-
- public class ConnectivityManager {
- method @NonNull @RequiresPermission(android.Manifest.permission.PACKET_KEEPALIVE_OFFLOAD) public android.net.SocketKeepalive createNattKeepalive(@NonNull android.net.Network, @NonNull android.os.ParcelFileDescriptor, @NonNull java.net.InetAddress, @NonNull java.net.InetAddress, @NonNull java.util.concurrent.Executor, @NonNull android.net.SocketKeepalive.Callback);
- method @NonNull @RequiresPermission(android.Manifest.permission.PACKET_KEEPALIVE_OFFLOAD) public android.net.SocketKeepalive createSocketKeepalive(@NonNull android.net.Network, @NonNull java.net.Socket, @NonNull java.util.concurrent.Executor, @NonNull android.net.SocketKeepalive.Callback);
- method @Deprecated @RequiresPermission(android.Manifest.permission.NETWORK_SETTINGS) public String getCaptivePortalServerUrl();
- method @Deprecated @RequiresPermission(android.Manifest.permission.TETHER_PRIVILEGED) public void getLatestTetheringEntitlementResult(int, boolean, @NonNull java.util.concurrent.Executor, @NonNull android.net.ConnectivityManager.OnTetheringEntitlementResultListener);
- method @Deprecated @RequiresPermission(anyOf={android.Manifest.permission.TETHER_PRIVILEGED, android.Manifest.permission.WRITE_SETTINGS}) public boolean isTetheringSupported();
- method @RequiresPermission(anyOf={android.net.NetworkStack.PERMISSION_MAINLINE_NETWORK_STACK, android.Manifest.permission.NETWORK_FACTORY}) public int registerNetworkProvider(@NonNull android.net.NetworkProvider);
- method @Deprecated @RequiresPermission(android.Manifest.permission.TETHER_PRIVILEGED) public void registerTetheringEventCallback(@NonNull java.util.concurrent.Executor, @NonNull android.net.ConnectivityManager.OnTetheringEventCallback);
- method @RequiresPermission(android.net.NetworkStack.PERMISSION_MAINLINE_NETWORK_STACK) public void requestNetwork(@NonNull android.net.NetworkRequest, int, int, @NonNull android.os.Handler, @NonNull android.net.ConnectivityManager.NetworkCallback);
- method @RequiresPermission(anyOf={android.Manifest.permission.NETWORK_AIRPLANE_MODE, android.Manifest.permission.NETWORK_SETTINGS, android.Manifest.permission.NETWORK_SETUP_WIZARD, android.Manifest.permission.NETWORK_STACK}) public void setAirplaneMode(boolean);
- method @RequiresPermission(anyOf={android.net.NetworkStack.PERMISSION_MAINLINE_NETWORK_STACK, android.Manifest.permission.NETWORK_STACK}) public boolean shouldAvoidBadWifi();
- method @RequiresPermission(android.net.NetworkStack.PERMISSION_MAINLINE_NETWORK_STACK) public void startCaptivePortalApp(@NonNull android.net.Network, @NonNull android.os.Bundle);
- method @Deprecated @RequiresPermission(android.Manifest.permission.TETHER_PRIVILEGED) public void startTethering(int, boolean, android.net.ConnectivityManager.OnStartTetheringCallback);
- method @Deprecated @RequiresPermission(android.Manifest.permission.TETHER_PRIVILEGED) public void startTethering(int, boolean, android.net.ConnectivityManager.OnStartTetheringCallback, android.os.Handler);
- method @Deprecated @RequiresPermission(android.Manifest.permission.TETHER_PRIVILEGED) public void stopTethering(int);
- method @RequiresPermission(anyOf={android.net.NetworkStack.PERMISSION_MAINLINE_NETWORK_STACK, android.Manifest.permission.NETWORK_FACTORY}) public void unregisterNetworkProvider(@NonNull android.net.NetworkProvider);
- method @Deprecated @RequiresPermission(android.Manifest.permission.TETHER_PRIVILEGED) public void unregisterTetheringEventCallback(@NonNull android.net.ConnectivityManager.OnTetheringEventCallback);
- field public static final String EXTRA_CAPTIVE_PORTAL_PROBE_SPEC = "android.net.extra.CAPTIVE_PORTAL_PROBE_SPEC";
- field public static final String EXTRA_CAPTIVE_PORTAL_USER_AGENT = "android.net.extra.CAPTIVE_PORTAL_USER_AGENT";
- field public static final int TETHERING_BLUETOOTH = 2; // 0x2
- field public static final int TETHERING_USB = 1; // 0x1
- field public static final int TETHERING_WIFI = 0; // 0x0
- field @Deprecated public static final int TETHER_ERROR_ENTITLEMENT_UNKONWN = 13; // 0xd
- field @Deprecated public static final int TETHER_ERROR_NO_ERROR = 0; // 0x0
- field @Deprecated public static final int TETHER_ERROR_PROVISION_FAILED = 11; // 0xb
- field public static final int TYPE_NONE = -1; // 0xffffffff
- field @Deprecated public static final int TYPE_WIFI_P2P = 13; // 0xd
- }
-
- @Deprecated public abstract static class ConnectivityManager.OnStartTetheringCallback {
- ctor @Deprecated public ConnectivityManager.OnStartTetheringCallback();
- method @Deprecated public void onTetheringFailed();
- method @Deprecated public void onTetheringStarted();
- }
-
- @Deprecated public static interface ConnectivityManager.OnTetheringEntitlementResultListener {
- method @Deprecated public void onTetheringEntitlementResult(int);
- }
-
- @Deprecated public abstract static class ConnectivityManager.OnTetheringEventCallback {
- ctor @Deprecated public ConnectivityManager.OnTetheringEventCallback();
- method @Deprecated public void onUpstreamChanged(@Nullable android.net.Network);
- }
-
- public class EthernetManager {
- method @NonNull @RequiresPermission(anyOf={android.Manifest.permission.NETWORK_STACK, android.net.NetworkStack.PERMISSION_MAINLINE_NETWORK_STACK}) public android.net.EthernetManager.TetheredInterfaceRequest requestTetheredInterface(@NonNull java.util.concurrent.Executor, @NonNull android.net.EthernetManager.TetheredInterfaceCallback);
- }
-
- public static interface EthernetManager.TetheredInterfaceCallback {
- method public void onAvailable(@NonNull String);
- method public void onUnavailable();
- }
-
- public static class EthernetManager.TetheredInterfaceRequest {
- method public void release();
- }
-
- public final class InvalidPacketException extends java.lang.Exception {
- ctor public InvalidPacketException(int);
- method public int getError();
- field public static final int ERROR_INVALID_IP_ADDRESS = -21; // 0xffffffeb
- field public static final int ERROR_INVALID_LENGTH = -23; // 0xffffffe9
- field public static final int ERROR_INVALID_PORT = -22; // 0xffffffea
- }
-
- public final class IpConfiguration implements android.os.Parcelable {
- ctor public IpConfiguration();
- ctor public IpConfiguration(@NonNull android.net.IpConfiguration);
- method public int describeContents();
- method @Nullable public android.net.ProxyInfo getHttpProxy();
- method @NonNull public android.net.IpConfiguration.IpAssignment getIpAssignment();
- method @NonNull public android.net.IpConfiguration.ProxySettings getProxySettings();
- method @Nullable public android.net.StaticIpConfiguration getStaticIpConfiguration();
- method public void setHttpProxy(@Nullable android.net.ProxyInfo);
- method public void setIpAssignment(@NonNull android.net.IpConfiguration.IpAssignment);
- method public void setProxySettings(@NonNull android.net.IpConfiguration.ProxySettings);
- method public void setStaticIpConfiguration(@Nullable android.net.StaticIpConfiguration);
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.net.IpConfiguration> CREATOR;
- }
-
- public enum IpConfiguration.IpAssignment {
- enum_constant public static final android.net.IpConfiguration.IpAssignment DHCP;
- enum_constant public static final android.net.IpConfiguration.IpAssignment STATIC;
- enum_constant public static final android.net.IpConfiguration.IpAssignment UNASSIGNED;
- }
-
- public enum IpConfiguration.ProxySettings {
- enum_constant public static final android.net.IpConfiguration.ProxySettings NONE;
- enum_constant public static final android.net.IpConfiguration.ProxySettings PAC;
- enum_constant public static final android.net.IpConfiguration.ProxySettings STATIC;
- enum_constant public static final android.net.IpConfiguration.ProxySettings UNASSIGNED;
- }
-
- public final class IpPrefix implements android.os.Parcelable {
- ctor public IpPrefix(@NonNull java.net.InetAddress, @IntRange(from=0, to=128) int);
- ctor public IpPrefix(@NonNull String);
- }
-
- public final class IpSecManager {
- method @RequiresPermission(android.Manifest.permission.MANAGE_IPSEC_TUNNELS) public void applyTunnelModeTransform(@NonNull android.net.IpSecManager.IpSecTunnelInterface, int, @NonNull android.net.IpSecTransform) throws java.io.IOException;
- method @NonNull @RequiresPermission(android.Manifest.permission.MANAGE_IPSEC_TUNNELS) public android.net.IpSecManager.IpSecTunnelInterface createIpSecTunnelInterface(@NonNull java.net.InetAddress, @NonNull java.net.InetAddress, @NonNull android.net.Network) throws java.io.IOException, android.net.IpSecManager.ResourceUnavailableException;
- }
-
- public static final class IpSecManager.IpSecTunnelInterface implements java.lang.AutoCloseable {
- method @RequiresPermission(android.Manifest.permission.MANAGE_IPSEC_TUNNELS) public void addAddress(@NonNull java.net.InetAddress, int) throws java.io.IOException;
- method public void close();
- method @NonNull public String getInterfaceName();
- method @RequiresPermission(android.Manifest.permission.MANAGE_IPSEC_TUNNELS) public void removeAddress(@NonNull java.net.InetAddress, int) throws java.io.IOException;
- }
-
- public static class IpSecTransform.Builder {
- method @NonNull @RequiresPermission(android.Manifest.permission.MANAGE_IPSEC_TUNNELS) public android.net.IpSecTransform buildTunnelModeTransform(@NonNull java.net.InetAddress, @NonNull android.net.IpSecManager.SecurityParameterIndex) throws java.io.IOException, android.net.IpSecManager.ResourceUnavailableException, android.net.IpSecManager.SpiUnavailableException;
- }
-
- public class KeepalivePacketData {
- ctor protected KeepalivePacketData(@NonNull java.net.InetAddress, @IntRange(from=0, to=65535) int, @NonNull java.net.InetAddress, @IntRange(from=0, to=65535) int, @NonNull byte[]) throws android.net.InvalidPacketException;
- method @NonNull public java.net.InetAddress getDstAddress();
- method public int getDstPort();
- method @NonNull public byte[] getPacket();
- method @NonNull public java.net.InetAddress getSrcAddress();
- method public int getSrcPort();
- }
-
- public class LinkAddress implements android.os.Parcelable {
- ctor public LinkAddress(@NonNull java.net.InetAddress, @IntRange(from=0, to=128) int, int, int);
- ctor public LinkAddress(@NonNull java.net.InetAddress, @IntRange(from=0, to=128) int, int, int, long, long);
- ctor public LinkAddress(@NonNull java.net.InetAddress, @IntRange(from=0, to=128) int);
- ctor public LinkAddress(@NonNull String);
- ctor public LinkAddress(@NonNull String, int, int);
- method public long getDeprecationTime();
- method public long getExpirationTime();
- method public boolean isGlobalPreferred();
- method public boolean isIpv4();
- method public boolean isIpv6();
- method public boolean isSameAddressAs(@Nullable android.net.LinkAddress);
- field public static final long LIFETIME_PERMANENT = 9223372036854775807L; // 0x7fffffffffffffffL
- field public static final long LIFETIME_UNKNOWN = -1L; // 0xffffffffffffffffL
- }
-
- public final class LinkProperties implements android.os.Parcelable {
- ctor public LinkProperties(@Nullable android.net.LinkProperties);
- ctor public LinkProperties(@Nullable android.net.LinkProperties, boolean);
- method public boolean addDnsServer(@NonNull java.net.InetAddress);
- method public boolean addLinkAddress(@NonNull android.net.LinkAddress);
- method public boolean addPcscfServer(@NonNull java.net.InetAddress);
- method @NonNull public java.util.List<java.net.InetAddress> getAddresses();
- method @NonNull public java.util.List<java.lang.String> getAllInterfaceNames();
- method @NonNull public java.util.List<android.net.LinkAddress> getAllLinkAddresses();
- method @NonNull public java.util.List<android.net.RouteInfo> getAllRoutes();
- method @Nullable public android.net.Uri getCaptivePortalApiUrl();
- method @Nullable public android.net.CaptivePortalData getCaptivePortalData();
- method @NonNull public java.util.List<java.net.InetAddress> getPcscfServers();
- method @Nullable public String getTcpBufferSizes();
- method @NonNull public java.util.List<java.net.InetAddress> getValidatedPrivateDnsServers();
- method public boolean hasGlobalIpv6Address();
- method public boolean hasIpv4Address();
- method public boolean hasIpv4DefaultRoute();
- method public boolean hasIpv4DnsServer();
- method public boolean hasIpv6DefaultRoute();
- method public boolean hasIpv6DnsServer();
- method public boolean isIpv4Provisioned();
- method public boolean isIpv6Provisioned();
- method public boolean isProvisioned();
- method public boolean isReachable(@NonNull java.net.InetAddress);
- method public boolean removeDnsServer(@NonNull java.net.InetAddress);
- method public boolean removeLinkAddress(@NonNull android.net.LinkAddress);
- method public boolean removeRoute(@NonNull android.net.RouteInfo);
- method public void setCaptivePortalApiUrl(@Nullable android.net.Uri);
- method public void setCaptivePortalData(@Nullable android.net.CaptivePortalData);
- method public void setPcscfServers(@NonNull java.util.Collection<java.net.InetAddress>);
- method public void setPrivateDnsServerName(@Nullable String);
- method public void setTcpBufferSizes(@Nullable String);
- method public void setUsePrivateDns(boolean);
- method public void setValidatedPrivateDnsServers(@NonNull java.util.Collection<java.net.InetAddress>);
- }
-
- public final class MatchAllNetworkSpecifier extends android.net.NetworkSpecifier implements android.os.Parcelable {
- ctor public MatchAllNetworkSpecifier();
- method public int describeContents();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.net.MatchAllNetworkSpecifier> CREATOR;
- }
-
- public final class NattKeepalivePacketData extends android.net.KeepalivePacketData implements android.os.Parcelable {
- ctor public NattKeepalivePacketData(@NonNull java.net.InetAddress, int, @NonNull java.net.InetAddress, int, @NonNull byte[]) throws android.net.InvalidPacketException;
- method public int describeContents();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.net.NattKeepalivePacketData> CREATOR;
- }
-
- public class Network implements android.os.Parcelable {
- ctor public Network(@NonNull android.net.Network);
- method public int getNetId();
- method @NonNull public android.net.Network getPrivateDnsBypassingCopy();
- }
-
- public abstract class NetworkAgent {
- ctor public NetworkAgent(@NonNull android.content.Context, @NonNull android.os.Looper, @NonNull String, @NonNull android.net.NetworkCapabilities, @NonNull android.net.LinkProperties, int, @NonNull android.net.NetworkAgentConfig, @Nullable android.net.NetworkProvider);
- method @Nullable public android.net.Network getNetwork();
- method public void markConnected();
- method public void onAddKeepalivePacketFilter(int, @NonNull android.net.KeepalivePacketData);
- method public void onAutomaticReconnectDisabled();
- method public void onNetworkUnwanted();
- method public void onRemoveKeepalivePacketFilter(int);
- method public void onSaveAcceptUnvalidated(boolean);
- method public void onSignalStrengthThresholdsUpdated(@NonNull int[]);
- method public void onStartSocketKeepalive(int, @NonNull java.time.Duration, @NonNull android.net.KeepalivePacketData);
- method public void onStopSocketKeepalive(int);
- method public void onValidationStatus(int, @Nullable android.net.Uri);
- method @NonNull public android.net.Network register();
- method public final void sendLinkProperties(@NonNull android.net.LinkProperties);
- method public final void sendNetworkCapabilities(@NonNull android.net.NetworkCapabilities);
- method public final void sendNetworkScore(@IntRange(from=0, to=99) int);
- method public final void sendSocketKeepaliveEvent(int, int);
- method public void unregister();
- field public static final int VALIDATION_STATUS_NOT_VALID = 2; // 0x2
- field public static final int VALIDATION_STATUS_VALID = 1; // 0x1
- }
-
- public final class NetworkAgentConfig implements android.os.Parcelable {
- method public int describeContents();
- method public int getLegacyType();
- method @NonNull public String getLegacyTypeName();
- method public boolean isExplicitlySelected();
- method public boolean isPartialConnectivityAcceptable();
- method public boolean isUnvalidatedConnectivityAcceptable();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.net.NetworkAgentConfig> CREATOR;
- }
-
- public static final class NetworkAgentConfig.Builder {
- ctor public NetworkAgentConfig.Builder();
- method @NonNull public android.net.NetworkAgentConfig build();
- method @NonNull public android.net.NetworkAgentConfig.Builder setExplicitlySelected(boolean);
- method @NonNull public android.net.NetworkAgentConfig.Builder setLegacyType(int);
- method @NonNull public android.net.NetworkAgentConfig.Builder setLegacyTypeName(@NonNull String);
- method @NonNull public android.net.NetworkAgentConfig.Builder setPartialConnectivityAcceptable(boolean);
- method @NonNull public android.net.NetworkAgentConfig.Builder setUnvalidatedConnectivityAcceptable(boolean);
- }
-
- public final class NetworkCapabilities implements android.os.Parcelable {
- method @NonNull public int[] getAdministratorUids();
- method @Nullable public String getSsid();
- method @NonNull public int[] getTransportTypes();
- method public boolean satisfiedByNetworkCapabilities(@Nullable android.net.NetworkCapabilities);
- field public static final int NET_CAPABILITY_OEM_PAID = 22; // 0x16
- field public static final int NET_CAPABILITY_OEM_PRIVATE = 26; // 0x1a
- field public static final int NET_CAPABILITY_PARTIAL_CONNECTIVITY = 24; // 0x18
- }
-
- public static final class NetworkCapabilities.Builder {
- ctor public NetworkCapabilities.Builder();
- ctor public NetworkCapabilities.Builder(@NonNull android.net.NetworkCapabilities);
- method @NonNull public android.net.NetworkCapabilities.Builder addCapability(int);
- method @NonNull public android.net.NetworkCapabilities.Builder addTransportType(int);
- method @NonNull public android.net.NetworkCapabilities build();
- method @NonNull public android.net.NetworkCapabilities.Builder removeCapability(int);
- method @NonNull public android.net.NetworkCapabilities.Builder removeTransportType(int);
- method @NonNull @RequiresPermission(android.Manifest.permission.NETWORK_FACTORY) public android.net.NetworkCapabilities.Builder setAdministratorUids(@NonNull int[]);
- method @NonNull public android.net.NetworkCapabilities.Builder setLinkDownstreamBandwidthKbps(int);
- method @NonNull public android.net.NetworkCapabilities.Builder setLinkUpstreamBandwidthKbps(int);
- method @NonNull public android.net.NetworkCapabilities.Builder setNetworkSpecifier(@Nullable android.net.NetworkSpecifier);
- method @NonNull @RequiresPermission(android.Manifest.permission.NETWORK_FACTORY) public android.net.NetworkCapabilities.Builder setOwnerUid(int);
- method @NonNull @RequiresPermission(android.Manifest.permission.NETWORK_FACTORY) public android.net.NetworkCapabilities.Builder setRequestorPackageName(@Nullable String);
- method @NonNull @RequiresPermission(android.Manifest.permission.NETWORK_FACTORY) public android.net.NetworkCapabilities.Builder setRequestorUid(int);
- method @NonNull @RequiresPermission(android.Manifest.permission.NETWORK_SIGNAL_STRENGTH_WAKEUP) public android.net.NetworkCapabilities.Builder setSignalStrength(int);
- method @NonNull @RequiresPermission(android.Manifest.permission.NETWORK_FACTORY) public android.net.NetworkCapabilities.Builder setSsid(@Nullable String);
- method @NonNull public android.net.NetworkCapabilities.Builder setTransportInfo(@Nullable android.net.TransportInfo);
- }
-
- public class NetworkKey implements android.os.Parcelable {
- ctor public NetworkKey(android.net.WifiKey);
- method @Nullable public static android.net.NetworkKey createFromScanResult(@NonNull android.net.wifi.ScanResult);
- method public int describeContents();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.net.NetworkKey> CREATOR;
- field public static final int TYPE_WIFI = 1; // 0x1
- field public final int type;
- field public final android.net.WifiKey wifiKey;
- }
-
- public class NetworkProvider {
- ctor public NetworkProvider(@NonNull android.content.Context, @NonNull android.os.Looper, @NonNull String);
- method @RequiresPermission(android.Manifest.permission.NETWORK_FACTORY) public void declareNetworkRequestUnfulfillable(@NonNull android.net.NetworkRequest);
- method public int getProviderId();
- method public void onNetworkRequestWithdrawn(@NonNull android.net.NetworkRequest);
- method public void onNetworkRequested(@NonNull android.net.NetworkRequest, @IntRange(from=0, to=99) int, int);
- field public static final int ID_NONE = -1; // 0xffffffff
- }
-
- public abstract class NetworkRecommendationProvider {
- ctor public NetworkRecommendationProvider(android.content.Context, java.util.concurrent.Executor);
- method public final android.os.IBinder getBinder();
- method public abstract void onRequestScores(android.net.NetworkKey[]);
- }
-
- public class NetworkRequest implements android.os.Parcelable {
- method @Nullable public String getRequestorPackageName();
- method public int getRequestorUid();
- }
-
- public static class NetworkRequest.Builder {
- method @NonNull @RequiresPermission(android.Manifest.permission.NETWORK_SIGNAL_STRENGTH_WAKEUP) public android.net.NetworkRequest.Builder setSignalStrength(int);
- }
-
- public class NetworkScoreManager {
- method @RequiresPermission(anyOf={android.Manifest.permission.SCORE_NETWORKS, android.Manifest.permission.REQUEST_NETWORK_SCORES}) public boolean clearScores() throws java.lang.SecurityException;
- method @RequiresPermission(anyOf={android.Manifest.permission.SCORE_NETWORKS, android.Manifest.permission.REQUEST_NETWORK_SCORES}) public void disableScoring() throws java.lang.SecurityException;
- method @RequiresPermission(anyOf={android.Manifest.permission.SCORE_NETWORKS, android.Manifest.permission.REQUEST_NETWORK_SCORES}) public String getActiveScorerPackage();
- method @RequiresPermission(android.Manifest.permission.REQUEST_NETWORK_SCORES) public void registerNetworkScoreCallback(int, int, @NonNull java.util.concurrent.Executor, @NonNull android.net.NetworkScoreManager.NetworkScoreCallback) throws java.lang.SecurityException;
- method @RequiresPermission(android.Manifest.permission.REQUEST_NETWORK_SCORES) public boolean requestScores(@NonNull java.util.Collection<android.net.NetworkKey>) throws java.lang.SecurityException;
- method @RequiresPermission(anyOf={android.Manifest.permission.SCORE_NETWORKS, android.Manifest.permission.REQUEST_NETWORK_SCORES}) public boolean setActiveScorer(String) throws java.lang.SecurityException;
- method @RequiresPermission(android.Manifest.permission.SCORE_NETWORKS) public boolean updateScores(@NonNull android.net.ScoredNetwork[]) throws java.lang.SecurityException;
- field @Deprecated public static final String ACTION_CHANGE_ACTIVE = "android.net.scoring.CHANGE_ACTIVE";
- field public static final String ACTION_CUSTOM_ENABLE = "android.net.scoring.CUSTOM_ENABLE";
- field public static final String ACTION_RECOMMEND_NETWORKS = "android.net.action.RECOMMEND_NETWORKS";
- field public static final String ACTION_SCORER_CHANGED = "android.net.scoring.SCORER_CHANGED";
- field @Deprecated public static final String ACTION_SCORE_NETWORKS = "android.net.scoring.SCORE_NETWORKS";
- field @Deprecated public static final String EXTRA_NETWORKS_TO_SCORE = "networksToScore";
- field public static final String EXTRA_NEW_SCORER = "newScorer";
- field @Deprecated public static final String EXTRA_PACKAGE_NAME = "packageName";
- field public static final int SCORE_FILTER_CURRENT_NETWORK = 1; // 0x1
- field public static final int SCORE_FILTER_NONE = 0; // 0x0
- field public static final int SCORE_FILTER_SCAN_RESULTS = 2; // 0x2
- }
-
- public abstract static class NetworkScoreManager.NetworkScoreCallback {
- ctor public NetworkScoreManager.NetworkScoreCallback();
- method public abstract void onScoresInvalidated();
- method public abstract void onScoresUpdated(@NonNull java.util.Collection<android.net.ScoredNetwork>);
- }
-
- public abstract class NetworkSpecifier {
- method public boolean canBeSatisfiedBy(@Nullable android.net.NetworkSpecifier);
- method @Nullable public android.net.NetworkSpecifier redact();
- }
-
- public class NetworkStack {
- method @Nullable public static android.os.IBinder getService();
- field public static final String PERMISSION_MAINLINE_NETWORK_STACK = "android.permission.MAINLINE_NETWORK_STACK";
- }
-
- public final class NetworkStats implements android.os.Parcelable {
- ctor public NetworkStats(long, int);
- method @NonNull public android.net.NetworkStats add(@NonNull android.net.NetworkStats);
- method @NonNull public android.net.NetworkStats addEntry(@NonNull android.net.NetworkStats.Entry);
- method public int describeContents();
- method @NonNull public android.net.NetworkStats subtract(@NonNull android.net.NetworkStats);
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.net.NetworkStats> CREATOR;
- field public static final int DEFAULT_NETWORK_NO = 0; // 0x0
- field public static final int DEFAULT_NETWORK_YES = 1; // 0x1
- field public static final String IFACE_VT = "vt_data0";
- field public static final int METERED_NO = 0; // 0x0
- field public static final int METERED_YES = 1; // 0x1
- field public static final int ROAMING_NO = 0; // 0x0
- field public static final int ROAMING_YES = 1; // 0x1
- field public static final int SET_DEFAULT = 0; // 0x0
- field public static final int SET_FOREGROUND = 1; // 0x1
- field public static final int TAG_NONE = 0; // 0x0
- field public static final int UID_ALL = -1; // 0xffffffff
- field public static final int UID_TETHERING = -5; // 0xfffffffb
- }
-
- public static class NetworkStats.Entry {
- ctor public NetworkStats.Entry(@Nullable String, int, int, int, int, int, int, long, long, long, long, long);
- }
-
- public final class RouteInfo implements android.os.Parcelable {
- ctor public RouteInfo(@Nullable android.net.IpPrefix, @Nullable java.net.InetAddress, @Nullable String, int);
- ctor public RouteInfo(@Nullable android.net.IpPrefix, @Nullable java.net.InetAddress, @Nullable String, int, int);
- method public int getMtu();
- method public int getType();
- field public static final int RTN_THROW = 9; // 0x9
- field public static final int RTN_UNICAST = 1; // 0x1
- field public static final int RTN_UNREACHABLE = 7; // 0x7
- }
-
- public class RssiCurve implements android.os.Parcelable {
- ctor public RssiCurve(int, int, byte[]);
- ctor public RssiCurve(int, int, byte[], int);
- method public int describeContents();
- method public byte lookupScore(int);
- method public byte lookupScore(int, boolean);
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.net.RssiCurve> CREATOR;
- field public final int activeNetworkRssiBoost;
- field public final int bucketWidth;
- field public final byte[] rssiBuckets;
- field public final int start;
- }
-
- public class ScoredNetwork implements android.os.Parcelable {
- ctor public ScoredNetwork(android.net.NetworkKey, android.net.RssiCurve);
- ctor public ScoredNetwork(android.net.NetworkKey, android.net.RssiCurve, boolean);
- ctor public ScoredNetwork(android.net.NetworkKey, android.net.RssiCurve, boolean, @Nullable android.os.Bundle);
- method public int calculateBadge(int);
- method public int describeContents();
- method public void writeToParcel(android.os.Parcel, int);
- field public static final String ATTRIBUTES_KEY_BADGING_CURVE = "android.net.attributes.key.BADGING_CURVE";
- field public static final String ATTRIBUTES_KEY_HAS_CAPTIVE_PORTAL = "android.net.attributes.key.HAS_CAPTIVE_PORTAL";
- field public static final String ATTRIBUTES_KEY_RANKING_SCORE_OFFSET = "android.net.attributes.key.RANKING_SCORE_OFFSET";
- field @NonNull public static final android.os.Parcelable.Creator<android.net.ScoredNetwork> CREATOR;
- field @Nullable public final android.os.Bundle attributes;
- field public final boolean meteredHint;
- field public final android.net.NetworkKey networkKey;
- field public final android.net.RssiCurve rssiCurve;
- }
-
- public abstract class SocketKeepalive implements java.lang.AutoCloseable {
- field public static final int SUCCESS = 0; // 0x0
- }
-
- public final class StaticIpConfiguration implements android.os.Parcelable {
- ctor public StaticIpConfiguration();
- ctor public StaticIpConfiguration(@Nullable android.net.StaticIpConfiguration);
- method public void addDnsServer(@NonNull java.net.InetAddress);
- method public void clear();
- method public int describeContents();
- method @NonNull public java.util.List<java.net.InetAddress> getDnsServers();
- method @Nullable public String getDomains();
- method @Nullable public java.net.InetAddress getGateway();
- method @Nullable public android.net.LinkAddress getIpAddress();
- method @NonNull public java.util.List<android.net.RouteInfo> getRoutes(@Nullable String);
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.net.StaticIpConfiguration> CREATOR;
- }
-
- public static final class StaticIpConfiguration.Builder {
- ctor public StaticIpConfiguration.Builder();
- method @NonNull public android.net.StaticIpConfiguration build();
- method @NonNull public android.net.StaticIpConfiguration.Builder setDnsServers(@NonNull Iterable<java.net.InetAddress>);
- method @NonNull public android.net.StaticIpConfiguration.Builder setDomains(@Nullable String);
- method @NonNull public android.net.StaticIpConfiguration.Builder setGateway(@Nullable java.net.InetAddress);
- method @NonNull public android.net.StaticIpConfiguration.Builder setIpAddress(@Nullable android.net.LinkAddress);
- }
-
- public final class TetheredClient implements android.os.Parcelable {
- ctor public TetheredClient(@NonNull android.net.MacAddress, @NonNull java.util.Collection<android.net.TetheredClient.AddressInfo>, int);
- method public int describeContents();
- method @NonNull public java.util.List<android.net.TetheredClient.AddressInfo> getAddresses();
- method @NonNull public android.net.MacAddress getMacAddress();
- method public int getTetheringType();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.net.TetheredClient> CREATOR;
- }
-
- public static final class TetheredClient.AddressInfo implements android.os.Parcelable {
- method public int describeContents();
- method @NonNull public android.net.LinkAddress getAddress();
- method @Nullable public String getHostname();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.net.TetheredClient.AddressInfo> CREATOR;
- }
-
- public class TetheringManager {
- method @RequiresPermission(android.Manifest.permission.ACCESS_NETWORK_STATE) public void registerTetheringEventCallback(@NonNull java.util.concurrent.Executor, @NonNull android.net.TetheringManager.TetheringEventCallback);
- method @RequiresPermission(anyOf={android.Manifest.permission.TETHER_PRIVILEGED, android.Manifest.permission.WRITE_SETTINGS}) public void requestLatestTetheringEntitlementResult(int, boolean, @NonNull java.util.concurrent.Executor, @NonNull android.net.TetheringManager.OnTetheringEntitlementResultListener);
- method @RequiresPermission(anyOf={android.Manifest.permission.TETHER_PRIVILEGED, android.Manifest.permission.WRITE_SETTINGS}) public void startTethering(@NonNull android.net.TetheringManager.TetheringRequest, @NonNull java.util.concurrent.Executor, @NonNull android.net.TetheringManager.StartTetheringCallback);
- method @RequiresPermission(anyOf={android.Manifest.permission.TETHER_PRIVILEGED, android.Manifest.permission.WRITE_SETTINGS}) public void stopAllTethering();
- method @RequiresPermission(anyOf={android.Manifest.permission.TETHER_PRIVILEGED, android.Manifest.permission.WRITE_SETTINGS}) public void stopTethering(int);
- method @RequiresPermission(anyOf={android.Manifest.permission.TETHER_PRIVILEGED, android.Manifest.permission.ACCESS_NETWORK_STATE}) public void unregisterTetheringEventCallback(@NonNull android.net.TetheringManager.TetheringEventCallback);
- field public static final String ACTION_TETHER_STATE_CHANGED = "android.net.conn.TETHER_STATE_CHANGED";
- field public static final String EXTRA_ACTIVE_LOCAL_ONLY = "android.net.extra.ACTIVE_LOCAL_ONLY";
- field public static final String EXTRA_ACTIVE_TETHER = "tetherArray";
- field public static final String EXTRA_AVAILABLE_TETHER = "availableArray";
- field public static final String EXTRA_ERRORED_TETHER = "erroredArray";
- field public static final int TETHERING_BLUETOOTH = 2; // 0x2
- field public static final int TETHERING_ETHERNET = 5; // 0x5
- field public static final int TETHERING_INVALID = -1; // 0xffffffff
- field public static final int TETHERING_NCM = 4; // 0x4
- field public static final int TETHERING_USB = 1; // 0x1
- field public static final int TETHERING_WIFI = 0; // 0x0
- field public static final int TETHERING_WIFI_P2P = 3; // 0x3
- field public static final int TETHER_ERROR_DHCPSERVER_ERROR = 12; // 0xc
- field public static final int TETHER_ERROR_DISABLE_FORWARDING_ERROR = 9; // 0x9
- field public static final int TETHER_ERROR_ENABLE_FORWARDING_ERROR = 8; // 0x8
- field public static final int TETHER_ERROR_ENTITLEMENT_UNKNOWN = 13; // 0xd
- field public static final int TETHER_ERROR_IFACE_CFG_ERROR = 10; // 0xa
- field public static final int TETHER_ERROR_INTERNAL_ERROR = 5; // 0x5
- field public static final int TETHER_ERROR_NO_ACCESS_TETHERING_PERMISSION = 15; // 0xf
- field public static final int TETHER_ERROR_NO_CHANGE_TETHERING_PERMISSION = 14; // 0xe
- field public static final int TETHER_ERROR_NO_ERROR = 0; // 0x0
- field public static final int TETHER_ERROR_PROVISIONING_FAILED = 11; // 0xb
- field public static final int TETHER_ERROR_SERVICE_UNAVAIL = 2; // 0x2
- field public static final int TETHER_ERROR_TETHER_IFACE_ERROR = 6; // 0x6
- field public static final int TETHER_ERROR_UNAVAIL_IFACE = 4; // 0x4
- field public static final int TETHER_ERROR_UNKNOWN_IFACE = 1; // 0x1
- field public static final int TETHER_ERROR_UNKNOWN_TYPE = 16; // 0x10
- field public static final int TETHER_ERROR_UNSUPPORTED = 3; // 0x3
- field public static final int TETHER_ERROR_UNTETHER_IFACE_ERROR = 7; // 0x7
- field public static final int TETHER_HARDWARE_OFFLOAD_FAILED = 2; // 0x2
- field public static final int TETHER_HARDWARE_OFFLOAD_STARTED = 1; // 0x1
- field public static final int TETHER_HARDWARE_OFFLOAD_STOPPED = 0; // 0x0
- }
-
- public static interface TetheringManager.OnTetheringEntitlementResultListener {
- method public void onTetheringEntitlementResult(int);
- }
-
- public static interface TetheringManager.StartTetheringCallback {
- method public default void onTetheringFailed(int);
- method public default void onTetheringStarted();
- }
-
- public static interface TetheringManager.TetheringEventCallback {
- method public default void onClientsChanged(@NonNull java.util.Collection<android.net.TetheredClient>);
- method public default void onError(@NonNull String, int);
- method public default void onOffloadStatusChanged(int);
- method public default void onTetherableInterfacesChanged(@NonNull java.util.List<java.lang.String>);
- method public default void onTetheredInterfacesChanged(@NonNull java.util.List<java.lang.String>);
- method public default void onTetheringSupported(boolean);
- method public default void onUpstreamChanged(@Nullable android.net.Network);
- }
-
- public static class TetheringManager.TetheringRequest {
- method @Nullable public android.net.LinkAddress getClientStaticIpv4Address();
- method @Nullable public android.net.LinkAddress getLocalIpv4Address();
- method public boolean getShouldShowEntitlementUi();
- method public int getTetheringType();
- method public boolean isExemptFromEntitlementCheck();
- }
-
- public static class TetheringManager.TetheringRequest.Builder {
- ctor public TetheringManager.TetheringRequest.Builder(int);
- method @NonNull public android.net.TetheringManager.TetheringRequest build();
- method @NonNull @RequiresPermission(android.Manifest.permission.TETHER_PRIVILEGED) public android.net.TetheringManager.TetheringRequest.Builder setExemptFromEntitlementCheck(boolean);
- method @NonNull @RequiresPermission(android.Manifest.permission.TETHER_PRIVILEGED) public android.net.TetheringManager.TetheringRequest.Builder setShouldShowEntitlementUi(boolean);
- method @NonNull @RequiresPermission(android.Manifest.permission.TETHER_PRIVILEGED) public android.net.TetheringManager.TetheringRequest.Builder setStaticIpv4Addresses(@NonNull android.net.LinkAddress, @NonNull android.net.LinkAddress);
- }
-
- public class TrafficStats {
- method public static void setThreadStatsTagApp();
- method public static void setThreadStatsTagBackup();
- method public static void setThreadStatsTagRestore();
- field public static final int TAG_NETWORK_STACK_IMPERSONATION_RANGE_END = -113; // 0xffffff8f
- field public static final int TAG_NETWORK_STACK_IMPERSONATION_RANGE_START = -128; // 0xffffff80
- field public static final int TAG_NETWORK_STACK_RANGE_END = -257; // 0xfffffeff
- field public static final int TAG_NETWORK_STACK_RANGE_START = -768; // 0xfffffd00
- field public static final int TAG_SYSTEM_IMPERSONATION_RANGE_END = -241; // 0xffffff0f
- field public static final int TAG_SYSTEM_IMPERSONATION_RANGE_START = -256; // 0xffffff00
- }
-
- public abstract class Uri implements java.lang.Comparable<android.net.Uri> android.os.Parcelable {
- method @NonNull public String toSafeString();
- }
-
- public class VpnService extends android.app.Service {
- method @RequiresPermission(android.Manifest.permission.CONTROL_VPN) public static void prepareAndAuthorize(android.content.Context);
- }
-
- public class WebAddress {
- ctor public WebAddress(String) throws android.net.ParseException;
- }
-
- public class WifiKey implements android.os.Parcelable {
- ctor public WifiKey(String, String);
- method public int describeContents();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.net.WifiKey> CREATOR;
- field public final String bssid;
- field public final String ssid;
- }
-
-}
-
-package android.net.apf {
-
- public final class ApfCapabilities implements android.os.Parcelable {
- ctor public ApfCapabilities(int, int, int);
- method public int describeContents();
- method public static boolean getApfDrop8023Frames();
- method @NonNull public static int[] getApfEtherTypeBlackList();
- method public boolean hasDataAccess();
- method public void writeToParcel(android.os.Parcel, int);
- field public static final android.os.Parcelable.Creator<android.net.apf.ApfCapabilities> CREATOR;
- field public final int apfPacketFormat;
- field public final int apfVersionSupported;
- field public final int maximumApfProgramSize;
- }
-
-}
-
-package android.net.metrics {
-
- public final class ApfProgramEvent implements android.net.metrics.IpConnectivityLog.Event {
- }
-
- public static final class ApfProgramEvent.Builder {
- ctor public ApfProgramEvent.Builder();
- method @NonNull public android.net.metrics.ApfProgramEvent build();
- method @NonNull public android.net.metrics.ApfProgramEvent.Builder setActualLifetime(long);
- method @NonNull public android.net.metrics.ApfProgramEvent.Builder setCurrentRas(int);
- method @NonNull public android.net.metrics.ApfProgramEvent.Builder setFilteredRas(int);
- method @NonNull public android.net.metrics.ApfProgramEvent.Builder setFlags(boolean, boolean);
- method @NonNull public android.net.metrics.ApfProgramEvent.Builder setLifetime(long);
- method @NonNull public android.net.metrics.ApfProgramEvent.Builder setProgramLength(int);
- }
-
- public final class ApfStats implements android.net.metrics.IpConnectivityLog.Event {
- }
-
- public static final class ApfStats.Builder {
- ctor public ApfStats.Builder();
- method @NonNull public android.net.metrics.ApfStats build();
- method @NonNull public android.net.metrics.ApfStats.Builder setDroppedRas(int);
- method @NonNull public android.net.metrics.ApfStats.Builder setDurationMs(long);
- method @NonNull public android.net.metrics.ApfStats.Builder setMatchingRas(int);
- method @NonNull public android.net.metrics.ApfStats.Builder setMaxProgramSize(int);
- method @NonNull public android.net.metrics.ApfStats.Builder setParseErrors(int);
- method @NonNull public android.net.metrics.ApfStats.Builder setProgramUpdates(int);
- method @NonNull public android.net.metrics.ApfStats.Builder setProgramUpdatesAll(int);
- method @NonNull public android.net.metrics.ApfStats.Builder setProgramUpdatesAllowingMulticast(int);
- method @NonNull public android.net.metrics.ApfStats.Builder setReceivedRas(int);
- method @NonNull public android.net.metrics.ApfStats.Builder setZeroLifetimeRas(int);
- }
-
- public final class DhcpClientEvent implements android.net.metrics.IpConnectivityLog.Event {
- }
-
- public static final class DhcpClientEvent.Builder {
- ctor public DhcpClientEvent.Builder();
- method @NonNull public android.net.metrics.DhcpClientEvent build();
- method @NonNull public android.net.metrics.DhcpClientEvent.Builder setDurationMs(int);
- method @NonNull public android.net.metrics.DhcpClientEvent.Builder setMsg(String);
- }
-
- public final class DhcpErrorEvent implements android.net.metrics.IpConnectivityLog.Event {
- ctor public DhcpErrorEvent(int);
- method public static int errorCodeWithOption(int, int);
- field public static final int BOOTP_TOO_SHORT = 67174400; // 0x4010000
- field public static final int BUFFER_UNDERFLOW = 83951616; // 0x5010000
- field public static final int DHCP_BAD_MAGIC_COOKIE = 67239936; // 0x4020000
- field public static final int DHCP_ERROR = 4; // 0x4
- field public static final int DHCP_INVALID_OPTION_LENGTH = 67305472; // 0x4030000
- field public static final int DHCP_NO_COOKIE = 67502080; // 0x4060000
- field public static final int DHCP_NO_MSG_TYPE = 67371008; // 0x4040000
- field public static final int DHCP_UNKNOWN_MSG_TYPE = 67436544; // 0x4050000
- field public static final int L2_ERROR = 1; // 0x1
- field public static final int L2_TOO_SHORT = 16842752; // 0x1010000
- field public static final int L2_WRONG_ETH_TYPE = 16908288; // 0x1020000
- field public static final int L3_ERROR = 2; // 0x2
- field public static final int L3_INVALID_IP = 33751040; // 0x2030000
- field public static final int L3_NOT_IPV4 = 33685504; // 0x2020000
- field public static final int L3_TOO_SHORT = 33619968; // 0x2010000
- field public static final int L4_ERROR = 3; // 0x3
- field public static final int L4_NOT_UDP = 50397184; // 0x3010000
- field public static final int L4_WRONG_PORT = 50462720; // 0x3020000
- field public static final int MISC_ERROR = 5; // 0x5
- field public static final int PARSING_ERROR = 84082688; // 0x5030000
- field public static final int RECEIVE_ERROR = 84017152; // 0x5020000
- }
-
- public class IpConnectivityLog {
- ctor public IpConnectivityLog();
- method public boolean log(long, @NonNull android.net.metrics.IpConnectivityLog.Event);
- method public boolean log(@NonNull String, @NonNull android.net.metrics.IpConnectivityLog.Event);
- method public boolean log(@NonNull android.net.Network, @NonNull int[], @NonNull android.net.metrics.IpConnectivityLog.Event);
- method public boolean log(int, @NonNull int[], @NonNull android.net.metrics.IpConnectivityLog.Event);
- method public boolean log(@NonNull android.net.metrics.IpConnectivityLog.Event);
- }
-
- public static interface IpConnectivityLog.Event extends android.os.Parcelable {
- }
-
- public final class IpManagerEvent implements android.net.metrics.IpConnectivityLog.Event {
- ctor public IpManagerEvent(int, long);
- field public static final int COMPLETE_LIFECYCLE = 3; // 0x3
- field public static final int ERROR_INTERFACE_NOT_FOUND = 8; // 0x8
- field public static final int ERROR_INVALID_PROVISIONING = 7; // 0x7
- field public static final int ERROR_STARTING_IPREACHABILITYMONITOR = 6; // 0x6
- field public static final int ERROR_STARTING_IPV4 = 4; // 0x4
- field public static final int ERROR_STARTING_IPV6 = 5; // 0x5
- field public static final int PROVISIONING_FAIL = 2; // 0x2
- field public static final int PROVISIONING_OK = 1; // 0x1
- }
-
- public final class IpReachabilityEvent implements android.net.metrics.IpConnectivityLog.Event {
- ctor public IpReachabilityEvent(int);
- field public static final int NUD_FAILED = 512; // 0x200
- field public static final int NUD_FAILED_ORGANIC = 1024; // 0x400
- field public static final int PROBE = 256; // 0x100
- field public static final int PROVISIONING_LOST = 768; // 0x300
- field public static final int PROVISIONING_LOST_ORGANIC = 1280; // 0x500
- }
-
- public final class NetworkEvent implements android.net.metrics.IpConnectivityLog.Event {
- ctor public NetworkEvent(int, long);
- ctor public NetworkEvent(int);
- field public static final int NETWORK_CAPTIVE_PORTAL_FOUND = 4; // 0x4
- field public static final int NETWORK_CONNECTED = 1; // 0x1
- field public static final int NETWORK_CONSECUTIVE_DNS_TIMEOUT_FOUND = 12; // 0xc
- field public static final int NETWORK_DISCONNECTED = 7; // 0x7
- field public static final int NETWORK_FIRST_VALIDATION_PORTAL_FOUND = 10; // 0xa
- field public static final int NETWORK_FIRST_VALIDATION_SUCCESS = 8; // 0x8
- field public static final int NETWORK_LINGER = 5; // 0x5
- field public static final int NETWORK_PARTIAL_CONNECTIVITY = 13; // 0xd
- field public static final int NETWORK_REVALIDATION_PORTAL_FOUND = 11; // 0xb
- field public static final int NETWORK_REVALIDATION_SUCCESS = 9; // 0x9
- field public static final int NETWORK_UNLINGER = 6; // 0x6
- field public static final int NETWORK_VALIDATED = 2; // 0x2
- field public static final int NETWORK_VALIDATION_FAILED = 3; // 0x3
- }
-
- public final class RaEvent implements android.net.metrics.IpConnectivityLog.Event {
- }
-
- public static final class RaEvent.Builder {
- ctor public RaEvent.Builder();
- method @NonNull public android.net.metrics.RaEvent build();
- method @NonNull public android.net.metrics.RaEvent.Builder updateDnsslLifetime(long);
- method @NonNull public android.net.metrics.RaEvent.Builder updatePrefixPreferredLifetime(long);
- method @NonNull public android.net.metrics.RaEvent.Builder updatePrefixValidLifetime(long);
- method @NonNull public android.net.metrics.RaEvent.Builder updateRdnssLifetime(long);
- method @NonNull public android.net.metrics.RaEvent.Builder updateRouteInfoLifetime(long);
- method @NonNull public android.net.metrics.RaEvent.Builder updateRouterLifetime(long);
- }
-
- public final class ValidationProbeEvent implements android.net.metrics.IpConnectivityLog.Event {
- method @NonNull public static String getProbeName(int);
- field public static final int DNS_FAILURE = 0; // 0x0
- field public static final int DNS_SUCCESS = 1; // 0x1
- field public static final int PROBE_DNS = 0; // 0x0
- field public static final int PROBE_FALLBACK = 4; // 0x4
- field public static final int PROBE_HTTP = 1; // 0x1
- field public static final int PROBE_HTTPS = 2; // 0x2
- field public static final int PROBE_PAC = 3; // 0x3
- field public static final int PROBE_PRIVDNS = 5; // 0x5
- }
-
- public static final class ValidationProbeEvent.Builder {
- ctor public ValidationProbeEvent.Builder();
- method @NonNull public android.net.metrics.ValidationProbeEvent build();
- method @NonNull public android.net.metrics.ValidationProbeEvent.Builder setDurationMs(long);
- method @NonNull public android.net.metrics.ValidationProbeEvent.Builder setProbeType(int, boolean);
- method @NonNull public android.net.metrics.ValidationProbeEvent.Builder setReturnCode(int);
- }
-
-}
-
-package android.net.netstats.provider {
-
- public abstract class NetworkStatsProvider {
- ctor public NetworkStatsProvider();
- method public void notifyAlertReached();
- method public void notifyLimitReached();
- method public void notifyStatsUpdated(int, @NonNull android.net.NetworkStats, @NonNull android.net.NetworkStats);
- method public abstract void onRequestStatsUpdate(int);
- method public abstract void onSetAlert(long);
- method public abstract void onSetLimit(@NonNull String, long);
- field public static final int QUOTA_UNLIMITED = -1; // 0xffffffff
- }
-
-}
-
-package android.net.sip {
-
- public class SipAudioCall {
- method @Nullable public android.net.rtp.AudioGroup getAudioGroup();
- method public void setAudioGroup(@NonNull android.net.rtp.AudioGroup);
- }
-
- public class SipManager {
- method @NonNull public java.util.List<android.net.sip.SipProfile> getProfiles() throws android.net.sip.SipException;
- field public static final String ACTION_SIP_CALL_OPTION_CHANGED = "android.net.sip.action.SIP_CALL_OPTION_CHANGED";
- field public static final String ACTION_SIP_INCOMING_CALL = "android.net.sip.action.SIP_INCOMING_CALL";
- field public static final String ACTION_SIP_REMOVE_PROFILE = "android.net.sip.action.SIP_REMOVE_PROFILE";
- field public static final String ACTION_SIP_SERVICE_UP = "android.net.sip.action.SIP_SERVICE_UP";
- field public static final String ACTION_START_SIP = "android.net.sip.action.START_SIP";
- }
-
- public class SipProfile implements java.lang.Cloneable android.os.Parcelable java.io.Serializable {
- method public int getCallingUid();
- }
-
-}
-
-package android.net.util {
-
- public final class SocketUtils {
- method public static void bindSocketToInterface(@NonNull java.io.FileDescriptor, @NonNull String) throws android.system.ErrnoException;
- method public static void closeSocket(@Nullable java.io.FileDescriptor) throws java.io.IOException;
- method @NonNull public static java.net.SocketAddress makeNetlinkSocketAddress(int, int);
- method @NonNull public static java.net.SocketAddress makePacketSocketAddress(int, int);
- method @Deprecated @NonNull public static java.net.SocketAddress makePacketSocketAddress(int, @NonNull byte[]);
- method @NonNull public static java.net.SocketAddress makePacketSocketAddress(int, int, @NonNull byte[]);
- }
-
-}
-
-package android.net.wifi {
-
- public abstract class EasyConnectStatusCallback {
- ctor public EasyConnectStatusCallback();
- method public abstract void onConfiguratorSuccess(int);
- method public abstract void onEnrolleeSuccess(int);
- method public void onFailure(int);
- method public void onFailure(int, @Nullable String, @NonNull android.util.SparseArray<int[]>, @NonNull int[]);
- method public abstract void onProgress(int);
- field public static final int EASY_CONNECT_EVENT_PROGRESS_AUTHENTICATION_SUCCESS = 0; // 0x0
- field public static final int EASY_CONNECT_EVENT_PROGRESS_CONFIGURATION_ACCEPTED = 3; // 0x3
- field public static final int EASY_CONNECT_EVENT_PROGRESS_CONFIGURATION_SENT_WAITING_RESPONSE = 2; // 0x2
- field public static final int EASY_CONNECT_EVENT_PROGRESS_RESPONSE_PENDING = 1; // 0x1
- field public static final int EASY_CONNECT_EVENT_SUCCESS_CONFIGURATION_APPLIED = 1; // 0x1
- field public static final int EASY_CONNECT_EVENT_SUCCESS_CONFIGURATION_SENT = 0; // 0x0
- }
-
- @Deprecated public class RttManager {
- method @Deprecated @RequiresPermission(android.Manifest.permission.LOCATION_HARDWARE) public void disableResponder(android.net.wifi.RttManager.ResponderCallback);
- method @Deprecated @RequiresPermission(android.Manifest.permission.LOCATION_HARDWARE) public void enableResponder(android.net.wifi.RttManager.ResponderCallback);
- method @Deprecated public android.net.wifi.RttManager.Capabilities getCapabilities();
- method @Deprecated @RequiresPermission(android.Manifest.permission.LOCATION_HARDWARE) public android.net.wifi.RttManager.RttCapabilities getRttCapabilities();
- method @Deprecated @RequiresPermission(android.Manifest.permission.LOCATION_HARDWARE) public void startRanging(android.net.wifi.RttManager.RttParams[], android.net.wifi.RttManager.RttListener);
- method @Deprecated @RequiresPermission(android.Manifest.permission.LOCATION_HARDWARE) public void stopRanging(android.net.wifi.RttManager.RttListener);
- field @Deprecated public static final int BASE = 160256; // 0x27200
- field @Deprecated public static final int CMD_OP_ABORTED = 160260; // 0x27204
- field @Deprecated public static final int CMD_OP_DISABLE_RESPONDER = 160262; // 0x27206
- field @Deprecated public static final int CMD_OP_ENABLE_RESPONDER = 160261; // 0x27205
- field @Deprecated public static final int CMD_OP_ENALBE_RESPONDER_FAILED = 160264; // 0x27208
- field @Deprecated public static final int CMD_OP_ENALBE_RESPONDER_SUCCEEDED = 160263; // 0x27207
- field @Deprecated public static final int CMD_OP_FAILED = 160258; // 0x27202
- field @Deprecated public static final int CMD_OP_START_RANGING = 160256; // 0x27200
- field @Deprecated public static final int CMD_OP_STOP_RANGING = 160257; // 0x27201
- field @Deprecated public static final int CMD_OP_SUCCEEDED = 160259; // 0x27203
- field @Deprecated public static final String DESCRIPTION_KEY = "android.net.wifi.RttManager.Description";
- field @Deprecated public static final int PREAMBLE_HT = 2; // 0x2
- field @Deprecated public static final int PREAMBLE_LEGACY = 1; // 0x1
- field @Deprecated public static final int PREAMBLE_VHT = 4; // 0x4
- field @Deprecated public static final int REASON_INITIATOR_NOT_ALLOWED_WHEN_RESPONDER_ON = -6; // 0xfffffffa
- field @Deprecated public static final int REASON_INVALID_LISTENER = -3; // 0xfffffffd
- field @Deprecated public static final int REASON_INVALID_REQUEST = -4; // 0xfffffffc
- field @Deprecated public static final int REASON_NOT_AVAILABLE = -2; // 0xfffffffe
- field @Deprecated public static final int REASON_PERMISSION_DENIED = -5; // 0xfffffffb
- field @Deprecated public static final int REASON_UNSPECIFIED = -1; // 0xffffffff
- field @Deprecated public static final int RTT_BW_10_SUPPORT = 2; // 0x2
- field @Deprecated public static final int RTT_BW_160_SUPPORT = 32; // 0x20
- field @Deprecated public static final int RTT_BW_20_SUPPORT = 4; // 0x4
- field @Deprecated public static final int RTT_BW_40_SUPPORT = 8; // 0x8
- field @Deprecated public static final int RTT_BW_5_SUPPORT = 1; // 0x1
- field @Deprecated public static final int RTT_BW_80_SUPPORT = 16; // 0x10
- field @Deprecated public static final int RTT_CHANNEL_WIDTH_10 = 6; // 0x6
- field @Deprecated public static final int RTT_CHANNEL_WIDTH_160 = 3; // 0x3
- field @Deprecated public static final int RTT_CHANNEL_WIDTH_20 = 0; // 0x0
- field @Deprecated public static final int RTT_CHANNEL_WIDTH_40 = 1; // 0x1
- field @Deprecated public static final int RTT_CHANNEL_WIDTH_5 = 5; // 0x5
- field @Deprecated public static final int RTT_CHANNEL_WIDTH_80 = 2; // 0x2
- field @Deprecated public static final int RTT_CHANNEL_WIDTH_80P80 = 4; // 0x4
- field @Deprecated public static final int RTT_CHANNEL_WIDTH_UNSPECIFIED = -1; // 0xffffffff
- field @Deprecated public static final int RTT_PEER_NAN = 5; // 0x5
- field @Deprecated public static final int RTT_PEER_P2P_CLIENT = 4; // 0x4
- field @Deprecated public static final int RTT_PEER_P2P_GO = 3; // 0x3
- field @Deprecated public static final int RTT_PEER_TYPE_AP = 1; // 0x1
- field @Deprecated public static final int RTT_PEER_TYPE_STA = 2; // 0x2
- field @Deprecated public static final int RTT_PEER_TYPE_UNSPECIFIED = 0; // 0x0
- field @Deprecated public static final int RTT_STATUS_ABORTED = 8; // 0x8
- field @Deprecated public static final int RTT_STATUS_FAILURE = 1; // 0x1
- field @Deprecated public static final int RTT_STATUS_FAIL_AP_ON_DIFF_CHANNEL = 6; // 0x6
- field @Deprecated public static final int RTT_STATUS_FAIL_BUSY_TRY_LATER = 12; // 0xc
- field @Deprecated public static final int RTT_STATUS_FAIL_FTM_PARAM_OVERRIDE = 15; // 0xf
- field @Deprecated public static final int RTT_STATUS_FAIL_INVALID_TS = 9; // 0x9
- field @Deprecated public static final int RTT_STATUS_FAIL_NOT_SCHEDULED_YET = 4; // 0x4
- field @Deprecated public static final int RTT_STATUS_FAIL_NO_CAPABILITY = 7; // 0x7
- field @Deprecated public static final int RTT_STATUS_FAIL_NO_RSP = 2; // 0x2
- field @Deprecated public static final int RTT_STATUS_FAIL_PROTOCOL = 10; // 0xa
- field @Deprecated public static final int RTT_STATUS_FAIL_REJECTED = 3; // 0x3
- field @Deprecated public static final int RTT_STATUS_FAIL_SCHEDULE = 11; // 0xb
- field @Deprecated public static final int RTT_STATUS_FAIL_TM_TIMEOUT = 5; // 0x5
- field @Deprecated public static final int RTT_STATUS_INVALID_REQ = 13; // 0xd
- field @Deprecated public static final int RTT_STATUS_NO_WIFI = 14; // 0xe
- field @Deprecated public static final int RTT_STATUS_SUCCESS = 0; // 0x0
- field @Deprecated public static final int RTT_TYPE_11_MC = 4; // 0x4
- field @Deprecated public static final int RTT_TYPE_11_V = 2; // 0x2
- field @Deprecated public static final int RTT_TYPE_ONE_SIDED = 1; // 0x1
- field @Deprecated public static final int RTT_TYPE_TWO_SIDED = 2; // 0x2
- field @Deprecated public static final int RTT_TYPE_UNSPECIFIED = 0; // 0x0
- }
-
- @Deprecated public class RttManager.Capabilities {
- ctor @Deprecated public RttManager.Capabilities();
- field @Deprecated public int supportedPeerType;
- field @Deprecated public int supportedType;
- }
-
- @Deprecated public static class RttManager.ParcelableRttParams implements android.os.Parcelable {
- field @Deprecated @NonNull public android.net.wifi.RttManager.RttParams[] mParams;
- }
-
- @Deprecated public static class RttManager.ParcelableRttResults implements android.os.Parcelable {
- ctor @Deprecated public RttManager.ParcelableRttResults(android.net.wifi.RttManager.RttResult[]);
- field @Deprecated public android.net.wifi.RttManager.RttResult[] mResults;
- }
-
- @Deprecated public abstract static class RttManager.ResponderCallback {
- ctor @Deprecated public RttManager.ResponderCallback();
- method @Deprecated public abstract void onResponderEnableFailure(int);
- method @Deprecated public abstract void onResponderEnabled(android.net.wifi.RttManager.ResponderConfig);
- }
-
- @Deprecated public static class RttManager.ResponderConfig implements android.os.Parcelable {
- ctor @Deprecated public RttManager.ResponderConfig();
- method @Deprecated public int describeContents();
- method @Deprecated public void writeToParcel(android.os.Parcel, int);
- field @Deprecated @NonNull public static final android.os.Parcelable.Creator<android.net.wifi.RttManager.ResponderConfig> CREATOR;
- field @Deprecated public int centerFreq0;
- field @Deprecated public int centerFreq1;
- field @Deprecated public int channelWidth;
- field @Deprecated public int frequency;
- field @Deprecated public String macAddress;
- field @Deprecated public int preamble;
- }
-
- @Deprecated public static class RttManager.RttCapabilities implements android.os.Parcelable {
- ctor @Deprecated public RttManager.RttCapabilities();
- field @Deprecated public int bwSupported;
- field @Deprecated public boolean lciSupported;
- field @Deprecated public boolean lcrSupported;
- field @Deprecated public int mcVersion;
- field @Deprecated public boolean oneSidedRttSupported;
- field @Deprecated public int preambleSupported;
- field @Deprecated public boolean responderSupported;
- field @Deprecated public boolean secureRttSupported;
- field @Deprecated public boolean supportedPeerType;
- field @Deprecated public boolean supportedType;
- field @Deprecated public boolean twoSided11McRttSupported;
- }
-
- @Deprecated public static interface RttManager.RttListener {
- method @Deprecated public void onAborted();
- method @Deprecated public void onFailure(int, String);
- method @Deprecated public void onSuccess(android.net.wifi.RttManager.RttResult[]);
- }
-
- @Deprecated public static class RttManager.RttParams {
- ctor @Deprecated public RttManager.RttParams();
- field @Deprecated public boolean LCIRequest;
- field @Deprecated public boolean LCRRequest;
- field @Deprecated public int bandwidth;
- field @Deprecated public String bssid;
- field @Deprecated public int burstTimeout;
- field @Deprecated public int centerFreq0;
- field @Deprecated public int centerFreq1;
- field @Deprecated public int channelWidth;
- field @Deprecated public int deviceType;
- field @Deprecated public int frequency;
- field @Deprecated public int interval;
- field @Deprecated public int numRetriesPerFTMR;
- field @Deprecated public int numRetriesPerMeasurementFrame;
- field @Deprecated public int numSamplesPerBurst;
- field @Deprecated public int num_retries;
- field @Deprecated public int num_samples;
- field @Deprecated public int numberBurst;
- field @Deprecated public int preamble;
- field @Deprecated public int requestType;
- field @Deprecated public boolean secure;
- }
-
- @Deprecated public static class RttManager.RttResult {
- ctor @Deprecated public RttManager.RttResult();
- field @Deprecated public android.net.wifi.RttManager.WifiInformationElement LCI;
- field @Deprecated public android.net.wifi.RttManager.WifiInformationElement LCR;
- field @Deprecated public String bssid;
- field @Deprecated public int burstDuration;
- field @Deprecated public int burstNumber;
- field @Deprecated public int distance;
- field @Deprecated public int distanceSpread;
- field @Deprecated public int distanceStandardDeviation;
- field @Deprecated public int distance_cm;
- field @Deprecated public int distance_sd_cm;
- field @Deprecated public int distance_spread_cm;
- field @Deprecated public int frameNumberPerBurstPeer;
- field @Deprecated public int measurementFrameNumber;
- field @Deprecated public int measurementType;
- field @Deprecated public int negotiatedBurstNum;
- field @Deprecated public int requestType;
- field @Deprecated public int retryAfterDuration;
- field @Deprecated public int rssi;
- field @Deprecated public int rssiSpread;
- field @Deprecated public int rssi_spread;
- field @Deprecated public long rtt;
- field @Deprecated public long rttSpread;
- field @Deprecated public long rttStandardDeviation;
- field @Deprecated public long rtt_ns;
- field @Deprecated public long rtt_sd_ns;
- field @Deprecated public long rtt_spread_ns;
- field @Deprecated public int rxRate;
- field @Deprecated public boolean secure;
- field @Deprecated public int status;
- field @Deprecated public int successMeasurementFrameNumber;
- field @Deprecated public long ts;
- field @Deprecated public int txRate;
- field @Deprecated public int tx_rate;
- }
-
- @Deprecated public static class RttManager.WifiInformationElement {
- ctor @Deprecated public RttManager.WifiInformationElement();
- field @Deprecated public byte[] data;
- field @Deprecated public byte id;
- }
-
- public final class ScanResult implements android.os.Parcelable {
- field public static final int CIPHER_CCMP = 3; // 0x3
- field public static final int CIPHER_GCMP_256 = 4; // 0x4
- field public static final int CIPHER_NONE = 0; // 0x0
- field public static final int CIPHER_NO_GROUP_ADDRESSED = 1; // 0x1
- field public static final int CIPHER_SMS4 = 5; // 0x5
- field public static final int CIPHER_TKIP = 2; // 0x2
- field public static final int KEY_MGMT_EAP = 2; // 0x2
- field public static final int KEY_MGMT_EAP_SHA256 = 6; // 0x6
- field public static final int KEY_MGMT_EAP_SUITE_B_192 = 10; // 0xa
- field public static final int KEY_MGMT_FT_EAP = 4; // 0x4
- field public static final int KEY_MGMT_FT_PSK = 3; // 0x3
- field public static final int KEY_MGMT_FT_SAE = 11; // 0xb
- field public static final int KEY_MGMT_NONE = 0; // 0x0
- field public static final int KEY_MGMT_OSEN = 7; // 0x7
- field public static final int KEY_MGMT_OWE = 9; // 0x9
- field public static final int KEY_MGMT_OWE_TRANSITION = 12; // 0xc
- field public static final int KEY_MGMT_PSK = 1; // 0x1
- field public static final int KEY_MGMT_PSK_SHA256 = 5; // 0x5
- field public static final int KEY_MGMT_SAE = 8; // 0x8
- field public static final int KEY_MGMT_WAPI_CERT = 14; // 0xe
- field public static final int KEY_MGMT_WAPI_PSK = 13; // 0xd
- field public static final int PROTOCOL_NONE = 0; // 0x0
- field public static final int PROTOCOL_OSEN = 3; // 0x3
- field public static final int PROTOCOL_RSN = 2; // 0x2
- field public static final int PROTOCOL_WAPI = 4; // 0x4
- field public static final int PROTOCOL_WPA = 1; // 0x1
- }
-
- public final class SoftApCapability implements android.os.Parcelable {
- method public boolean areFeaturesSupported(long);
- method public int describeContents();
- method public int getMaxSupportedClients();
- method @NonNull public int[] getSupportedChannelList(int);
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.net.wifi.SoftApCapability> CREATOR;
- field public static final long SOFTAP_FEATURE_ACS_OFFLOAD = 1L; // 0x1L
- field public static final long SOFTAP_FEATURE_CLIENT_FORCE_DISCONNECT = 2L; // 0x2L
- field public static final long SOFTAP_FEATURE_MAC_ADDRESS_CUSTOMIZATION = 8L; // 0x8L
- field public static final long SOFTAP_FEATURE_WPA3_SAE = 4L; // 0x4L
- }
-
- public final class SoftApConfiguration implements android.os.Parcelable {
- method @NonNull public java.util.List<android.net.MacAddress> getAllowedClientList();
- method public int getBand();
- method @NonNull public int[] getBands();
- method @NonNull public java.util.List<android.net.MacAddress> getBlockedClientList();
- method public int getChannel();
- method @NonNull public android.util.SparseIntArray getChannels();
- method public int getMacRandomizationSetting();
- method public int getMaxNumberOfClients();
- method public long getShutdownTimeoutMillis();
- method public boolean isAutoShutdownEnabled();
- method public boolean isClientControlByUserEnabled();
- method @Nullable public android.net.wifi.WifiConfiguration toWifiConfiguration();
- field public static final int BAND_2GHZ = 1; // 0x1
- field public static final int BAND_5GHZ = 2; // 0x2
- field public static final int BAND_6GHZ = 4; // 0x4
- field @Deprecated public static final int BAND_ANY = 7; // 0x7
- field public static final int RANDOMIZATION_NONE = 0; // 0x0
- field public static final int RANDOMIZATION_PERSISTENT = 1; // 0x1
- }
-
- public static final class SoftApConfiguration.Builder {
- ctor public SoftApConfiguration.Builder();
- ctor public SoftApConfiguration.Builder(@NonNull android.net.wifi.SoftApConfiguration);
- method @NonNull public android.net.wifi.SoftApConfiguration build();
- method @NonNull public android.net.wifi.SoftApConfiguration.Builder setAllowedClientList(@NonNull java.util.List<android.net.MacAddress>);
- method @NonNull public android.net.wifi.SoftApConfiguration.Builder setAutoShutdownEnabled(boolean);
- method @NonNull public android.net.wifi.SoftApConfiguration.Builder setBand(int);
- method @NonNull public android.net.wifi.SoftApConfiguration.Builder setBands(@NonNull int[]);
- method @NonNull public android.net.wifi.SoftApConfiguration.Builder setBlockedClientList(@NonNull java.util.List<android.net.MacAddress>);
- method @NonNull public android.net.wifi.SoftApConfiguration.Builder setBssid(@Nullable android.net.MacAddress);
- method @NonNull public android.net.wifi.SoftApConfiguration.Builder setChannel(int, int);
- method @NonNull public android.net.wifi.SoftApConfiguration.Builder setChannels(@NonNull android.util.SparseIntArray);
- method @NonNull public android.net.wifi.SoftApConfiguration.Builder setClientControlByUserEnabled(boolean);
- method @NonNull public android.net.wifi.SoftApConfiguration.Builder setHiddenSsid(boolean);
- method @NonNull public android.net.wifi.SoftApConfiguration.Builder setMacRandomizationSetting(int);
- method @NonNull public android.net.wifi.SoftApConfiguration.Builder setMaxNumberOfClients(@IntRange(from=0) int);
- method @NonNull public android.net.wifi.SoftApConfiguration.Builder setPassphrase(@Nullable String, int);
- method @NonNull public android.net.wifi.SoftApConfiguration.Builder setShutdownTimeoutMillis(@IntRange(from=0) long);
- method @NonNull public android.net.wifi.SoftApConfiguration.Builder setSsid(@Nullable String);
- }
-
- public final class SoftApInfo implements android.os.Parcelable {
- method public int describeContents();
- method public int getBandwidth();
- method @Nullable public android.net.MacAddress getBssid();
- method public int getFrequency();
- method public int getWifiStandard();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field public static final int CHANNEL_WIDTH_160MHZ = 6; // 0x6
- field public static final int CHANNEL_WIDTH_20MHZ = 2; // 0x2
- field public static final int CHANNEL_WIDTH_20MHZ_NOHT = 1; // 0x1
- field public static final int CHANNEL_WIDTH_40MHZ = 3; // 0x3
- field public static final int CHANNEL_WIDTH_80MHZ = 4; // 0x4
- field public static final int CHANNEL_WIDTH_80MHZ_PLUS_MHZ = 5; // 0x5
- field public static final int CHANNEL_WIDTH_INVALID = 0; // 0x0
- field @NonNull public static final android.os.Parcelable.Creator<android.net.wifi.SoftApInfo> CREATOR;
- }
-
- public final class WifiClient implements android.os.Parcelable {
- method public int describeContents();
- method @NonNull public android.net.MacAddress getMacAddress();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.net.wifi.WifiClient> CREATOR;
- }
-
- @Deprecated public class WifiConfiguration implements android.os.Parcelable {
- method @Deprecated public int getAuthType();
- method @Deprecated @NonNull public android.net.IpConfiguration getIpConfiguration();
- method @Deprecated @NonNull public android.net.wifi.WifiConfiguration.NetworkSelectionStatus getNetworkSelectionStatus();
- method @Deprecated @NonNull public String getPrintableSsid();
- method @Deprecated @NonNull public String getProfileKey();
- method @Deprecated public int getRecentFailureReason();
- method @Deprecated public boolean hasNoInternetAccess();
- method @Deprecated public boolean isEphemeral();
- method @Deprecated public static boolean isMetered(@Nullable android.net.wifi.WifiConfiguration, @Nullable android.net.wifi.WifiInfo);
- method @Deprecated public boolean isNoInternetAccessExpected();
- method @Deprecated public void setIpConfiguration(@Nullable android.net.IpConfiguration);
- method @Deprecated public void setNetworkSelectionStatus(@NonNull android.net.wifi.WifiConfiguration.NetworkSelectionStatus);
- field @Deprecated public static final int INVALID_NETWORK_ID = -1; // 0xffffffff
- field @Deprecated public static final int METERED_OVERRIDE_METERED = 1; // 0x1
- field @Deprecated public static final int METERED_OVERRIDE_NONE = 0; // 0x0
- field @Deprecated public static final int METERED_OVERRIDE_NOT_METERED = 2; // 0x2
- field @Deprecated public static final int RANDOMIZATION_AUTO = 3; // 0x3
- field @Deprecated public static final int RANDOMIZATION_ENHANCED = 2; // 0x2
- field @Deprecated public static final int RANDOMIZATION_NONE = 0; // 0x0
- field @Deprecated public static final int RANDOMIZATION_PERSISTENT = 1; // 0x1
- field @Deprecated public static final int RECENT_FAILURE_AP_UNABLE_TO_HANDLE_NEW_STA = 17; // 0x11
- field @Deprecated public static final int RECENT_FAILURE_DISCONNECTION_AP_BUSY = 1004; // 0x3ec
- field @Deprecated public static final int RECENT_FAILURE_MBO_OCE_DISCONNECT = 1001; // 0x3e9
- field @Deprecated public static final int RECENT_FAILURE_NONE = 0; // 0x0
- field @Deprecated public static final int RECENT_FAILURE_POOR_CHANNEL_CONDITIONS = 1003; // 0x3eb
- field @Deprecated public static final int RECENT_FAILURE_REFUSED_TEMPORARILY = 1002; // 0x3ea
- field @Deprecated public boolean allowAutojoin;
- field @Deprecated public int carrierId;
- field @Deprecated public String creatorName;
- field @Deprecated public int creatorUid;
- field @Deprecated public boolean fromWifiNetworkSpecifier;
- field @Deprecated public boolean fromWifiNetworkSuggestion;
- field @Deprecated public String lastUpdateName;
- field @Deprecated public int lastUpdateUid;
- field @Deprecated public int macRandomizationSetting;
- field @Deprecated public boolean meteredHint;
- field @Deprecated public int meteredOverride;
- field @Deprecated public int numAssociation;
- field @Deprecated public int numScorerOverride;
- field @Deprecated public int numScorerOverrideAndSwitchedNetwork;
- field @Deprecated public boolean requirePmf;
- field @Deprecated public boolean shared;
- field @Deprecated public int subscriptionId;
- field @Deprecated public boolean useExternalScores;
- }
-
- @Deprecated public static class WifiConfiguration.KeyMgmt {
- field @Deprecated public static final int WAPI_CERT = 14; // 0xe
- field @Deprecated public static final int WAPI_PSK = 13; // 0xd
- field @Deprecated public static final int WPA2_PSK = 4; // 0x4
- }
-
- @Deprecated public static class WifiConfiguration.NetworkSelectionStatus {
- method @Deprecated public int getDisableReasonCounter(int);
- method @Deprecated public long getDisableTime();
- method @Deprecated public static int getMaxNetworkSelectionDisableReason();
- method @Deprecated public int getNetworkSelectionDisableReason();
- method @Deprecated @Nullable public static String getNetworkSelectionDisableReasonString(int);
- method @Deprecated public int getNetworkSelectionStatus();
- method @Deprecated @NonNull public String getNetworkStatusString();
- method @Deprecated public boolean hasEverConnected();
- field @Deprecated public static final int DISABLED_ASSOCIATION_REJECTION = 1; // 0x1
- field @Deprecated public static final int DISABLED_AUTHENTICATION_FAILURE = 2; // 0x2
- field @Deprecated public static final int DISABLED_AUTHENTICATION_NO_CREDENTIALS = 5; // 0x5
- field @Deprecated public static final int DISABLED_AUTHENTICATION_NO_SUBSCRIPTION = 9; // 0x9
- field @Deprecated public static final int DISABLED_BY_WIFI_MANAGER = 7; // 0x7
- field @Deprecated public static final int DISABLED_BY_WRONG_PASSWORD = 8; // 0x8
- field @Deprecated public static final int DISABLED_DHCP_FAILURE = 3; // 0x3
- field @Deprecated public static final int DISABLED_NONE = 0; // 0x0
- field @Deprecated public static final int DISABLED_NO_INTERNET_PERMANENT = 6; // 0x6
- field @Deprecated public static final int DISABLED_NO_INTERNET_TEMPORARY = 4; // 0x4
- field @Deprecated public static final int NETWORK_SELECTION_ENABLED = 0; // 0x0
- field @Deprecated public static final int NETWORK_SELECTION_PERMANENTLY_DISABLED = 2; // 0x2
- field @Deprecated public static final int NETWORK_SELECTION_TEMPORARY_DISABLED = 1; // 0x1
- }
-
- @Deprecated public static final class WifiConfiguration.NetworkSelectionStatus.Builder {
- ctor @Deprecated public WifiConfiguration.NetworkSelectionStatus.Builder();
- method @Deprecated @NonNull public android.net.wifi.WifiConfiguration.NetworkSelectionStatus build();
- method @Deprecated @NonNull public android.net.wifi.WifiConfiguration.NetworkSelectionStatus.Builder setNetworkSelectionDisableReason(int);
- method @Deprecated @NonNull public android.net.wifi.WifiConfiguration.NetworkSelectionStatus.Builder setNetworkSelectionStatus(int);
- }
-
- public class WifiEnterpriseConfig implements android.os.Parcelable {
- method @Nullable public String[] getCaCertificateAliases();
- method @NonNull public String getCaPath();
- method @NonNull public String getClientCertificateAlias();
- method public int getOcsp();
- method @NonNull public String getWapiCertSuite();
- method public void setCaCertificateAliases(@Nullable String[]);
- method public void setCaPath(@NonNull String);
- method public void setClientCertificateAlias(@NonNull String);
- method public void setOcsp(int);
- method public void setWapiCertSuite(@NonNull String);
- field public static final int OCSP_NONE = 0; // 0x0
- field public static final int OCSP_REQUEST_CERT_STATUS = 1; // 0x1
- field public static final int OCSP_REQUIRE_ALL_NON_TRUSTED_CERTS_STATUS = 3; // 0x3
- field public static final int OCSP_REQUIRE_CERT_STATUS = 2; // 0x2
- }
-
- public class WifiFrameworkInitializer {
- method public static void registerServiceWrappers();
- }
-
- public class WifiInfo implements android.os.Parcelable {
- method public double getLostTxPacketsPerSecond();
- method @Nullable public String getRequestingPackageName();
- method public double getRetriedTxPacketsPerSecond();
- method public int getScore();
- method public double getSuccessfulRxPacketsPerSecond();
- method public double getSuccessfulTxPacketsPerSecond();
- method public boolean isEphemeral();
- method public boolean isOemPaid();
- method public boolean isOemPrivate();
- method public boolean isOsuAp();
- method public boolean isPasspointAp();
- method public boolean isTrusted();
- method @Nullable public static String sanitizeSsid(@Nullable String);
- field public static final String DEFAULT_MAC_ADDRESS = "02:00:00:00:00:00";
- field public static final int INVALID_RSSI = -127; // 0xffffff81
- }
-
- public class WifiManager {
- method @RequiresPermission(android.Manifest.permission.WIFI_UPDATE_USABILITY_STATS_SCORE) public void addOnWifiUsabilityStatsListener(@NonNull java.util.concurrent.Executor, @NonNull android.net.wifi.WifiManager.OnWifiUsabilityStatsListener);
- method @RequiresPermission(android.Manifest.permission.NETWORK_SETTINGS) public void allowAutojoin(int, boolean);
- method @RequiresPermission(android.Manifest.permission.NETWORK_SETTINGS) public void allowAutojoinGlobal(boolean);
- method @RequiresPermission(android.Manifest.permission.NETWORK_SETTINGS) public void allowAutojoinPasspoint(@NonNull String, boolean);
- method @RequiresPermission(android.Manifest.permission.WIFI_UPDATE_USABILITY_STATS_SCORE) public void clearWifiConnectedNetworkScorer();
- method @RequiresPermission(anyOf={android.Manifest.permission.NETWORK_SETTINGS, android.Manifest.permission.NETWORK_SETUP_WIZARD, android.Manifest.permission.NETWORK_STACK}) public void connect(@NonNull android.net.wifi.WifiConfiguration, @Nullable android.net.wifi.WifiManager.ActionListener);
- method @RequiresPermission(anyOf={android.Manifest.permission.NETWORK_SETTINGS, android.Manifest.permission.NETWORK_SETUP_WIZARD, android.Manifest.permission.NETWORK_STACK}) public void connect(int, @Nullable android.net.wifi.WifiManager.ActionListener);
- method @Deprecated @RequiresPermission(anyOf={android.Manifest.permission.NETWORK_SETTINGS, android.Manifest.permission.NETWORK_SETUP_WIZARD, android.Manifest.permission.NETWORK_STACK}) public void disable(int, @Nullable android.net.wifi.WifiManager.ActionListener);
- method @RequiresPermission(anyOf={android.Manifest.permission.NETWORK_SETTINGS, android.Manifest.permission.NETWORK_STACK}) public void disableEphemeralNetwork(@NonNull String);
- method @RequiresPermission(android.Manifest.permission.NETWORK_SETTINGS) public void factoryReset();
- method @RequiresPermission(anyOf={android.Manifest.permission.NETWORK_SETTINGS, android.Manifest.permission.NETWORK_SETUP_WIZARD, android.Manifest.permission.NETWORK_STACK}) public void forget(int, @Nullable android.net.wifi.WifiManager.ActionListener);
- method @NonNull @RequiresPermission(anyOf={android.Manifest.permission.NETWORK_SETTINGS, android.Manifest.permission.NETWORK_SETUP_WIZARD}) public java.util.List<android.util.Pair<android.net.wifi.WifiConfiguration,java.util.Map<java.lang.Integer,java.util.List<android.net.wifi.ScanResult>>>> getAllMatchingWifiConfigs(@NonNull java.util.List<android.net.wifi.ScanResult>);
- method @Nullable @RequiresPermission(android.Manifest.permission.NETWORK_SETTINGS) public String getCountryCode();
- method @Nullable @RequiresPermission(anyOf={android.Manifest.permission.NETWORK_SETTINGS, android.Manifest.permission.NETWORK_SETUP_WIZARD}) public android.net.Network getCurrentNetwork();
- method @NonNull @RequiresPermission(android.Manifest.permission.NETWORK_SETTINGS) public String[] getFactoryMacAddresses();
- method @NonNull @RequiresPermission(anyOf={android.Manifest.permission.NETWORK_SETTINGS, android.Manifest.permission.NETWORK_SETUP_WIZARD}) public java.util.Map<android.net.wifi.hotspot2.OsuProvider,java.util.List<android.net.wifi.ScanResult>> getMatchingOsuProviders(@Nullable java.util.List<android.net.wifi.ScanResult>);
- method @NonNull @RequiresPermission(anyOf={android.Manifest.permission.NETWORK_SETTINGS, android.Manifest.permission.NETWORK_SETUP_WIZARD}) public java.util.Map<android.net.wifi.hotspot2.OsuProvider,android.net.wifi.hotspot2.PasspointConfiguration> getMatchingPasspointConfigsForOsuProviders(@NonNull java.util.Set<android.net.wifi.hotspot2.OsuProvider>);
- method @NonNull @RequiresPermission(allOf={android.Manifest.permission.ACCESS_FINE_LOCATION, android.Manifest.permission.ACCESS_WIFI_STATE}) public java.util.Map<android.net.wifi.WifiNetworkSuggestion,java.util.List<android.net.wifi.ScanResult>> getMatchingScanResults(@NonNull java.util.List<android.net.wifi.WifiNetworkSuggestion>, @Nullable java.util.List<android.net.wifi.ScanResult>);
- method @RequiresPermission(allOf={android.Manifest.permission.ACCESS_FINE_LOCATION, android.Manifest.permission.ACCESS_WIFI_STATE, android.Manifest.permission.READ_WIFI_CREDENTIAL}) public java.util.List<android.net.wifi.WifiConfiguration> getPrivilegedConfiguredNetworks();
- method @NonNull @RequiresPermission(anyOf={android.Manifest.permission.NETWORK_SETTINGS, android.Manifest.permission.OVERRIDE_WIFI_CONFIG}) public android.net.wifi.SoftApConfiguration getSoftApConfiguration();
- method @RequiresPermission(android.Manifest.permission.ACCESS_WIFI_STATE) public void getWifiActivityEnergyInfoAsync(@NonNull java.util.concurrent.Executor, @NonNull android.net.wifi.WifiManager.OnWifiActivityEnergyInfoListener);
- method @Deprecated @Nullable @RequiresPermission(android.Manifest.permission.ACCESS_WIFI_STATE) public android.net.wifi.WifiConfiguration getWifiApConfiguration();
- method @RequiresPermission(android.Manifest.permission.ACCESS_WIFI_STATE) public int getWifiApState();
- method @NonNull @RequiresPermission(anyOf={android.Manifest.permission.NETWORK_SETTINGS, android.Manifest.permission.NETWORK_SETUP_WIZARD}) public java.util.List<android.net.wifi.WifiConfiguration> getWifiConfigForMatchedNetworkSuggestionsSharedWithUser(@NonNull java.util.List<android.net.wifi.ScanResult>);
- method public boolean is60GHzBandSupported();
- method public boolean isApMacRandomizationSupported();
- method public boolean isConnectedMacRandomizationSupported();
- method @Deprecated public boolean isDeviceToDeviceRttSupported();
- method public boolean isPortableHotspotSupported();
- method public boolean isVerboseLoggingEnabled();
- method @RequiresPermission(android.Manifest.permission.ACCESS_WIFI_STATE) public boolean isWifiApEnabled();
- method public boolean isWifiScannerSupported();
- method @RequiresPermission(android.Manifest.permission.NETWORK_SETTINGS) public void registerNetworkRequestMatchCallback(@NonNull java.util.concurrent.Executor, @NonNull android.net.wifi.WifiManager.NetworkRequestMatchCallback);
- method @RequiresPermission(android.Manifest.permission.NETWORK_SETTINGS) public void registerSoftApCallback(@NonNull java.util.concurrent.Executor, @NonNull android.net.wifi.WifiManager.SoftApCallback);
- method @RequiresPermission(android.Manifest.permission.NETWORK_SETTINGS) public void registerTrafficStateCallback(@NonNull java.util.concurrent.Executor, @NonNull android.net.wifi.WifiManager.TrafficStateCallback);
- method @RequiresPermission(android.Manifest.permission.WIFI_UPDATE_USABILITY_STATS_SCORE) public void removeOnWifiUsabilityStatsListener(@NonNull android.net.wifi.WifiManager.OnWifiUsabilityStatsListener);
- method @RequiresPermission(android.Manifest.permission.NETWORK_SETTINGS) public void restoreBackupData(@NonNull byte[]);
- method @Nullable @RequiresPermission(android.Manifest.permission.NETWORK_SETTINGS) public android.net.wifi.SoftApConfiguration restoreSoftApBackupData(@NonNull byte[]);
- method @RequiresPermission(android.Manifest.permission.NETWORK_SETTINGS) public void restoreSupplicantBackupData(@NonNull byte[], @NonNull byte[]);
- method @NonNull @RequiresPermission(android.Manifest.permission.NETWORK_SETTINGS) public byte[] retrieveBackupData();
- method @NonNull @RequiresPermission(android.Manifest.permission.NETWORK_SETTINGS) public byte[] retrieveSoftApBackupData();
- method @RequiresPermission(anyOf={android.Manifest.permission.NETWORK_SETTINGS, android.Manifest.permission.NETWORK_SETUP_WIZARD, android.Manifest.permission.NETWORK_STACK}) public void save(@NonNull android.net.wifi.WifiConfiguration, @Nullable android.net.wifi.WifiManager.ActionListener);
- method @RequiresPermission(android.Manifest.permission.NETWORK_SETTINGS) public void setAutoWakeupEnabled(boolean);
- method @RequiresPermission(android.Manifest.permission.WIFI_SET_DEVICE_MOBILITY_STATE) public void setDeviceMobilityState(int);
- method @RequiresPermission(android.Manifest.permission.NETWORK_SETTINGS) public void setMacRandomizationSettingPasspointEnabled(@NonNull String, boolean);
- method @RequiresPermission(android.Manifest.permission.NETWORK_SETTINGS) public void setPasspointMeteredOverride(@NonNull String, int);
- method @RequiresPermission(android.Manifest.permission.NETWORK_SETTINGS) public void setScanAlwaysAvailable(boolean);
- method @RequiresPermission(android.Manifest.permission.NETWORK_SETTINGS) public void setScanThrottleEnabled(boolean);
- method @RequiresPermission(anyOf={android.Manifest.permission.NETWORK_SETTINGS, android.Manifest.permission.OVERRIDE_WIFI_CONFIG}) public boolean setSoftApConfiguration(@NonNull android.net.wifi.SoftApConfiguration);
- method @RequiresPermission(android.Manifest.permission.NETWORK_SETTINGS) public void setVerboseLoggingEnabled(boolean);
- method @Deprecated @RequiresPermission(android.Manifest.permission.CHANGE_WIFI_STATE) public boolean setWifiApConfiguration(android.net.wifi.WifiConfiguration);
- method @RequiresPermission(android.Manifest.permission.WIFI_UPDATE_USABILITY_STATS_SCORE) public boolean setWifiConnectedNetworkScorer(@NonNull java.util.concurrent.Executor, @NonNull android.net.wifi.WifiManager.WifiConnectedNetworkScorer);
- method @RequiresPermission(anyOf={android.Manifest.permission.NETWORK_SETTINGS, android.Manifest.permission.NETWORK_SETUP_WIZARD}) public void startEasyConnectAsConfiguratorInitiator(@NonNull String, int, int, @NonNull java.util.concurrent.Executor, @NonNull android.net.wifi.EasyConnectStatusCallback);
- method @RequiresPermission(anyOf={android.Manifest.permission.NETWORK_SETTINGS, android.Manifest.permission.NETWORK_SETUP_WIZARD}) public void startEasyConnectAsEnrolleeInitiator(@NonNull String, @NonNull java.util.concurrent.Executor, @NonNull android.net.wifi.EasyConnectStatusCallback);
- method @RequiresPermission(anyOf={android.Manifest.permission.NETWORK_SETTINGS, android.Manifest.permission.NETWORK_SETUP_WIZARD}) public void startLocalOnlyHotspot(@NonNull android.net.wifi.SoftApConfiguration, @Nullable java.util.concurrent.Executor, @Nullable android.net.wifi.WifiManager.LocalOnlyHotspotCallback);
- method @RequiresPermission(android.Manifest.permission.UPDATE_DEVICE_STATS) public boolean startScan(android.os.WorkSource);
- method @RequiresPermission(anyOf={android.Manifest.permission.NETWORK_SETTINGS, android.Manifest.permission.NETWORK_SETUP_WIZARD}) public void startSubscriptionProvisioning(@NonNull android.net.wifi.hotspot2.OsuProvider, @NonNull java.util.concurrent.Executor, @NonNull android.net.wifi.hotspot2.ProvisioningCallback);
- method @RequiresPermission(anyOf={android.Manifest.permission.NETWORK_STACK, android.net.NetworkStack.PERMISSION_MAINLINE_NETWORK_STACK}) public boolean startTetheredHotspot(@Nullable android.net.wifi.SoftApConfiguration);
- method @RequiresPermission(anyOf={android.Manifest.permission.NETWORK_SETTINGS, android.Manifest.permission.NETWORK_SETUP_WIZARD}) public void stopEasyConnectSession();
- method @RequiresPermission(anyOf={android.Manifest.permission.NETWORK_STACK, android.net.NetworkStack.PERMISSION_MAINLINE_NETWORK_STACK}) public boolean stopSoftAp();
- method @RequiresPermission(android.Manifest.permission.NETWORK_SETTINGS) public void unregisterNetworkRequestMatchCallback(@NonNull android.net.wifi.WifiManager.NetworkRequestMatchCallback);
- method @RequiresPermission(android.Manifest.permission.NETWORK_SETTINGS) public void unregisterSoftApCallback(@NonNull android.net.wifi.WifiManager.SoftApCallback);
- method @RequiresPermission(android.Manifest.permission.NETWORK_SETTINGS) public void unregisterTrafficStateCallback(@NonNull android.net.wifi.WifiManager.TrafficStateCallback);
- method @RequiresPermission(anyOf={android.Manifest.permission.NETWORK_STACK, android.net.NetworkStack.PERMISSION_MAINLINE_NETWORK_STACK}) public void updateInterfaceIpState(@Nullable String, int);
- method @RequiresPermission(android.Manifest.permission.WIFI_UPDATE_USABILITY_STATS_SCORE) public void updateWifiUsabilityScore(int, int, int);
- field public static final String ACTION_LINK_CONFIGURATION_CHANGED = "android.net.wifi.LINK_CONFIGURATION_CHANGED";
- field @RequiresPermission(android.Manifest.permission.NETWORK_CARRIER_PROVISIONING) public static final String ACTION_NETWORK_SETTINGS_RESET = "android.net.wifi.action.NETWORK_SETTINGS_RESET";
- field public static final String ACTION_PASSPOINT_LAUNCH_OSU_VIEW = "android.net.wifi.action.PASSPOINT_LAUNCH_OSU_VIEW";
- field public static final String ACTION_REQUEST_DISABLE = "android.net.wifi.action.REQUEST_DISABLE";
- field public static final String ACTION_REQUEST_ENABLE = "android.net.wifi.action.REQUEST_ENABLE";
- field public static final int CHANGE_REASON_ADDED = 0; // 0x0
- field public static final int CHANGE_REASON_CONFIG_CHANGE = 2; // 0x2
- field public static final int CHANGE_REASON_REMOVED = 1; // 0x1
- field public static final String CONFIGURED_NETWORKS_CHANGED_ACTION = "android.net.wifi.CONFIGURED_NETWORKS_CHANGE";
- field public static final int DEVICE_MOBILITY_STATE_HIGH_MVMT = 1; // 0x1
- field public static final int DEVICE_MOBILITY_STATE_LOW_MVMT = 2; // 0x2
- field public static final int DEVICE_MOBILITY_STATE_STATIONARY = 3; // 0x3
- field public static final int DEVICE_MOBILITY_STATE_UNKNOWN = 0; // 0x0
- field public static final int EASY_CONNECT_NETWORK_ROLE_AP = 1; // 0x1
- field public static final int EASY_CONNECT_NETWORK_ROLE_STA = 0; // 0x0
- field public static final String EXTRA_CHANGE_REASON = "changeReason";
- field @Deprecated public static final String EXTRA_LINK_PROPERTIES = "android.net.wifi.extra.LINK_PROPERTIES";
- field @Deprecated public static final String EXTRA_MULTIPLE_NETWORKS_CHANGED = "multipleChanges";
- field public static final String EXTRA_OSU_NETWORK = "android.net.wifi.extra.OSU_NETWORK";
- field public static final String EXTRA_PREVIOUS_WIFI_AP_STATE = "previous_wifi_state";
- field public static final String EXTRA_URL = "android.net.wifi.extra.URL";
- field public static final String EXTRA_WIFI_AP_FAILURE_REASON = "android.net.wifi.extra.WIFI_AP_FAILURE_REASON";
- field public static final String EXTRA_WIFI_AP_INTERFACE_NAME = "android.net.wifi.extra.WIFI_AP_INTERFACE_NAME";
- field public static final String EXTRA_WIFI_AP_MODE = "android.net.wifi.extra.WIFI_AP_MODE";
- field public static final String EXTRA_WIFI_AP_STATE = "wifi_state";
- field @Deprecated public static final String EXTRA_WIFI_CONFIGURATION = "wifiConfiguration";
- field public static final String EXTRA_WIFI_CREDENTIAL_EVENT_TYPE = "et";
- field public static final String EXTRA_WIFI_CREDENTIAL_SSID = "ssid";
- field public static final int IFACE_IP_MODE_CONFIGURATION_ERROR = 0; // 0x0
- field public static final int IFACE_IP_MODE_LOCAL_ONLY = 2; // 0x2
- field public static final int IFACE_IP_MODE_TETHERED = 1; // 0x1
- field public static final int IFACE_IP_MODE_UNSPECIFIED = -1; // 0xffffffff
- field public static final int PASSPOINT_HOME_NETWORK = 0; // 0x0
- field public static final int PASSPOINT_ROAMING_NETWORK = 1; // 0x1
- field public static final int SAP_CLIENT_BLOCK_REASON_CODE_BLOCKED_BY_USER = 0; // 0x0
- field public static final int SAP_CLIENT_BLOCK_REASON_CODE_NO_MORE_STAS = 1; // 0x1
- field public static final int SAP_START_FAILURE_GENERAL = 0; // 0x0
- field public static final int SAP_START_FAILURE_NO_CHANNEL = 1; // 0x1
- field public static final int SAP_START_FAILURE_UNSUPPORTED_CONFIGURATION = 2; // 0x2
- field public static final String WIFI_AP_STATE_CHANGED_ACTION = "android.net.wifi.WIFI_AP_STATE_CHANGED";
- field public static final int WIFI_AP_STATE_DISABLED = 11; // 0xb
- field public static final int WIFI_AP_STATE_DISABLING = 10; // 0xa
- field public static final int WIFI_AP_STATE_ENABLED = 13; // 0xd
- field public static final int WIFI_AP_STATE_ENABLING = 12; // 0xc
- field public static final int WIFI_AP_STATE_FAILED = 14; // 0xe
- field public static final String WIFI_CREDENTIAL_CHANGED_ACTION = "android.net.wifi.WIFI_CREDENTIAL_CHANGED";
- field public static final int WIFI_CREDENTIAL_FORGOT = 1; // 0x1
- field public static final int WIFI_CREDENTIAL_SAVED = 0; // 0x0
- }
-
- public static interface WifiManager.ActionListener {
- method public void onFailure(int);
- method public void onSuccess();
- }
-
- public static interface WifiManager.NetworkRequestMatchCallback {
- method public default void onAbort();
- method public default void onMatch(@NonNull java.util.List<android.net.wifi.ScanResult>);
- method public default void onUserSelectionCallbackRegistration(@NonNull android.net.wifi.WifiManager.NetworkRequestUserSelectionCallback);
- method public default void onUserSelectionConnectFailure(@NonNull android.net.wifi.WifiConfiguration);
- method public default void onUserSelectionConnectSuccess(@NonNull android.net.wifi.WifiConfiguration);
- }
-
- public static interface WifiManager.NetworkRequestUserSelectionCallback {
- method public default void reject();
- method public default void select(@NonNull android.net.wifi.WifiConfiguration);
- }
-
- public static interface WifiManager.OnWifiActivityEnergyInfoListener {
- method public void onWifiActivityEnergyInfo(@Nullable android.os.connectivity.WifiActivityEnergyInfo);
- }
-
- public static interface WifiManager.OnWifiUsabilityStatsListener {
- method public void onWifiUsabilityStats(int, boolean, @NonNull android.net.wifi.WifiUsabilityStatsEntry);
- }
-
- public static interface WifiManager.ScoreUpdateObserver {
- method public void notifyScoreUpdate(int, int);
- method public void triggerUpdateOfWifiUsabilityStats(int);
- }
-
- public static interface WifiManager.SoftApCallback {
- method public default void onBlockedClientConnecting(@NonNull android.net.wifi.WifiClient, int);
- method public default void onCapabilityChanged(@NonNull android.net.wifi.SoftApCapability);
- method public default void onConnectedClientsChanged(@NonNull java.util.List<android.net.wifi.WifiClient>);
- method public default void onInfoChanged(@NonNull android.net.wifi.SoftApInfo);
- method public default void onStateChanged(int, int);
- }
-
- public static interface WifiManager.TrafficStateCallback {
- method public void onStateChanged(int);
- field public static final int DATA_ACTIVITY_IN = 1; // 0x1
- field public static final int DATA_ACTIVITY_INOUT = 3; // 0x3
- field public static final int DATA_ACTIVITY_NONE = 0; // 0x0
- field public static final int DATA_ACTIVITY_OUT = 2; // 0x2
- }
-
- public static interface WifiManager.WifiConnectedNetworkScorer {
- method public void onSetScoreUpdateObserver(@NonNull android.net.wifi.WifiManager.ScoreUpdateObserver);
- method public void onStart(int);
- method public void onStop(int);
- }
-
- public final class WifiMigration {
- method @Nullable public static java.io.InputStream convertAndRetrieveSharedConfigStoreFile(int);
- method @Nullable public static java.io.InputStream convertAndRetrieveUserConfigStoreFile(int, @NonNull android.os.UserHandle);
- method @NonNull public static android.net.wifi.WifiMigration.SettingsMigrationData loadFromSettings(@NonNull android.content.Context);
- method public static void removeSharedConfigStoreFile(int);
- method public static void removeUserConfigStoreFile(int, @NonNull android.os.UserHandle);
- field public static final int STORE_FILE_SHARED_GENERAL = 0; // 0x0
- field public static final int STORE_FILE_SHARED_SOFTAP = 1; // 0x1
- field public static final int STORE_FILE_USER_GENERAL = 2; // 0x2
- field public static final int STORE_FILE_USER_NETWORK_SUGGESTIONS = 3; // 0x3
- }
-
- public static final class WifiMigration.SettingsMigrationData implements android.os.Parcelable {
- method public int describeContents();
- method @Nullable public String getP2pDeviceName();
- method public boolean isP2pFactoryResetPending();
- method public boolean isScanAlwaysAvailable();
- method public boolean isScanThrottleEnabled();
- method public boolean isSoftApTimeoutEnabled();
- method public boolean isVerboseLoggingEnabled();
- method public boolean isWakeUpEnabled();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.net.wifi.WifiMigration.SettingsMigrationData> CREATOR;
- }
-
- public static final class WifiMigration.SettingsMigrationData.Builder {
- ctor public WifiMigration.SettingsMigrationData.Builder();
- method @NonNull public android.net.wifi.WifiMigration.SettingsMigrationData build();
- method @NonNull public android.net.wifi.WifiMigration.SettingsMigrationData.Builder setP2pDeviceName(@Nullable String);
- method @NonNull public android.net.wifi.WifiMigration.SettingsMigrationData.Builder setP2pFactoryResetPending(boolean);
- method @NonNull public android.net.wifi.WifiMigration.SettingsMigrationData.Builder setScanAlwaysAvailable(boolean);
- method @NonNull public android.net.wifi.WifiMigration.SettingsMigrationData.Builder setScanThrottleEnabled(boolean);
- method @NonNull public android.net.wifi.WifiMigration.SettingsMigrationData.Builder setSoftApTimeoutEnabled(boolean);
- method @NonNull public android.net.wifi.WifiMigration.SettingsMigrationData.Builder setVerboseLoggingEnabled(boolean);
- method @NonNull public android.net.wifi.WifiMigration.SettingsMigrationData.Builder setWakeUpEnabled(boolean);
- }
-
- public class WifiNetworkConnectionStatistics implements android.os.Parcelable {
- ctor public WifiNetworkConnectionStatistics(int, int);
- ctor public WifiNetworkConnectionStatistics();
- ctor public WifiNetworkConnectionStatistics(android.net.wifi.WifiNetworkConnectionStatistics);
- method public int describeContents();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.net.wifi.WifiNetworkConnectionStatistics> CREATOR;
- field public int numConnection;
- field public int numUsage;
- }
-
- public final class WifiNetworkSuggestion implements android.os.Parcelable {
- method @NonNull public android.net.wifi.WifiConfiguration getWifiConfiguration();
- method public boolean isOemPaid();
- method public boolean isOemPrivate();
- }
-
- public static final class WifiNetworkSuggestion.Builder {
- method @NonNull @RequiresPermission(android.Manifest.permission.NETWORK_CARRIER_PROVISIONING) public android.net.wifi.WifiNetworkSuggestion.Builder setCarrierId(int);
- method @NonNull public android.net.wifi.WifiNetworkSuggestion.Builder setOemPaid(boolean);
- method @NonNull public android.net.wifi.WifiNetworkSuggestion.Builder setOemPrivate(boolean);
- }
-
- public class WifiScanner {
- method @Deprecated public void configureWifiChange(int, int, int, int, int, android.net.wifi.WifiScanner.BssidInfo[]);
- method @Deprecated public void configureWifiChange(android.net.wifi.WifiScanner.WifiChangeSettings);
- method @NonNull @RequiresPermission(android.Manifest.permission.LOCATION_HARDWARE) public java.util.List<java.lang.Integer> getAvailableChannels(int);
- method @Deprecated @RequiresPermission(android.Manifest.permission.LOCATION_HARDWARE) public boolean getScanResults();
- method @NonNull @RequiresPermission(android.Manifest.permission.LOCATION_HARDWARE) public java.util.List<android.net.wifi.ScanResult> getSingleScanResults();
- method @RequiresPermission(android.Manifest.permission.NETWORK_STACK) public void registerScanListener(@NonNull java.util.concurrent.Executor, @NonNull android.net.wifi.WifiScanner.ScanListener);
- method @RequiresPermission(android.Manifest.permission.NETWORK_STACK) public void setScanningEnabled(boolean);
- method @RequiresPermission(android.Manifest.permission.LOCATION_HARDWARE) public void startBackgroundScan(android.net.wifi.WifiScanner.ScanSettings, android.net.wifi.WifiScanner.ScanListener);
- method @Deprecated @RequiresPermission(android.Manifest.permission.LOCATION_HARDWARE) public void startBackgroundScan(android.net.wifi.WifiScanner.ScanSettings, android.net.wifi.WifiScanner.ScanListener, android.os.WorkSource);
- method @RequiresPermission(android.Manifest.permission.LOCATION_HARDWARE) public void startScan(android.net.wifi.WifiScanner.ScanSettings, android.net.wifi.WifiScanner.ScanListener);
- method @RequiresPermission(android.Manifest.permission.LOCATION_HARDWARE) public void startScan(android.net.wifi.WifiScanner.ScanSettings, android.net.wifi.WifiScanner.ScanListener, android.os.WorkSource);
- method @Deprecated public void startTrackingBssids(android.net.wifi.WifiScanner.BssidInfo[], int, android.net.wifi.WifiScanner.BssidListener);
- method @Deprecated public void startTrackingWifiChange(android.net.wifi.WifiScanner.WifiChangeListener);
- method @Deprecated @RequiresPermission(android.Manifest.permission.LOCATION_HARDWARE) public void stopBackgroundScan(android.net.wifi.WifiScanner.ScanListener);
- method @RequiresPermission(android.Manifest.permission.LOCATION_HARDWARE) public void stopScan(android.net.wifi.WifiScanner.ScanListener);
- method @Deprecated public void stopTrackingBssids(android.net.wifi.WifiScanner.BssidListener);
- method @Deprecated public void stopTrackingWifiChange(android.net.wifi.WifiScanner.WifiChangeListener);
- method public void unregisterScanListener(@NonNull android.net.wifi.WifiScanner.ScanListener);
- field public static final int MAX_SCAN_PERIOD_MS = 1024000; // 0xfa000
- field public static final int MIN_SCAN_PERIOD_MS = 1000; // 0x3e8
- field public static final int REASON_DUPLICATE_REQEUST = -5; // 0xfffffffb
- field public static final int REASON_INVALID_LISTENER = -2; // 0xfffffffe
- field public static final int REASON_INVALID_REQUEST = -3; // 0xfffffffd
- field public static final int REASON_NOT_AUTHORIZED = -4; // 0xfffffffc
- field public static final int REASON_SUCCEEDED = 0; // 0x0
- field public static final int REASON_UNSPECIFIED = -1; // 0xffffffff
- field @Deprecated public static final int REPORT_EVENT_AFTER_BUFFER_FULL = 0; // 0x0
- field public static final int REPORT_EVENT_AFTER_EACH_SCAN = 1; // 0x1
- field public static final int REPORT_EVENT_FULL_SCAN_RESULT = 2; // 0x2
- field public static final int REPORT_EVENT_NO_BATCH = 4; // 0x4
- field public static final int SCAN_TYPE_HIGH_ACCURACY = 2; // 0x2
- field public static final int SCAN_TYPE_LOW_LATENCY = 0; // 0x0
- field public static final int SCAN_TYPE_LOW_POWER = 1; // 0x1
- field public static final int WIFI_BAND_24_5_6_GHZ = 11; // 0xb
- field public static final int WIFI_BAND_24_5_WITH_DFS_6_GHZ = 15; // 0xf
- field public static final int WIFI_BAND_24_GHZ = 1; // 0x1
- field public static final int WIFI_BAND_5_GHZ = 2; // 0x2
- field public static final int WIFI_BAND_5_GHZ_DFS_ONLY = 4; // 0x4
- field public static final int WIFI_BAND_5_GHZ_WITH_DFS = 6; // 0x6
- field public static final int WIFI_BAND_60_GHZ = 16; // 0x10
- field public static final int WIFI_BAND_6_GHZ = 8; // 0x8
- field public static final int WIFI_BAND_BOTH = 3; // 0x3
- field public static final int WIFI_BAND_BOTH_WITH_DFS = 7; // 0x7
- field public static final int WIFI_BAND_UNSPECIFIED = 0; // 0x0
- }
-
- public static interface WifiScanner.ActionListener {
- method public void onFailure(int, String);
- method public void onSuccess();
- }
-
- @Deprecated public static class WifiScanner.BssidInfo {
- ctor @Deprecated public WifiScanner.BssidInfo();
- field @Deprecated public String bssid;
- field @Deprecated public int frequencyHint;
- field @Deprecated public int high;
- field @Deprecated public int low;
- }
-
- @Deprecated public static interface WifiScanner.BssidListener extends android.net.wifi.WifiScanner.ActionListener {
- method @Deprecated public void onFound(android.net.wifi.ScanResult[]);
- method @Deprecated public void onLost(android.net.wifi.ScanResult[]);
- }
-
- public static class WifiScanner.ChannelSpec {
- ctor public WifiScanner.ChannelSpec(int);
- field public int frequency;
- }
-
- @Deprecated public static class WifiScanner.HotlistSettings implements android.os.Parcelable {
- ctor @Deprecated public WifiScanner.HotlistSettings();
- field @Deprecated public int apLostThreshold;
- field @Deprecated public android.net.wifi.WifiScanner.BssidInfo[] bssidInfos;
- }
-
- public static class WifiScanner.ParcelableScanData implements android.os.Parcelable {
- ctor public WifiScanner.ParcelableScanData(android.net.wifi.WifiScanner.ScanData[]);
- method public android.net.wifi.WifiScanner.ScanData[] getResults();
- field public android.net.wifi.WifiScanner.ScanData[] mResults;
- }
-
- public static class WifiScanner.ParcelableScanResults implements android.os.Parcelable {
- ctor public WifiScanner.ParcelableScanResults(android.net.wifi.ScanResult[]);
- method public android.net.wifi.ScanResult[] getResults();
- field public android.net.wifi.ScanResult[] mResults;
- }
-
- public static class WifiScanner.ScanData implements android.os.Parcelable {
- ctor public WifiScanner.ScanData(int, int, android.net.wifi.ScanResult[]);
- ctor public WifiScanner.ScanData(android.net.wifi.WifiScanner.ScanData);
- method public int getFlags();
- method public int getId();
- method public android.net.wifi.ScanResult[] getResults();
- }
-
- public static interface WifiScanner.ScanListener extends android.net.wifi.WifiScanner.ActionListener {
- method public void onFullResult(android.net.wifi.ScanResult);
- method @Deprecated public void onPeriodChanged(int);
- method public void onResults(android.net.wifi.WifiScanner.ScanData[]);
- }
-
- public static class WifiScanner.ScanSettings implements android.os.Parcelable {
- ctor public WifiScanner.ScanSettings();
- field public int band;
- field public android.net.wifi.WifiScanner.ChannelSpec[] channels;
- field @NonNull @RequiresPermission(android.Manifest.permission.NETWORK_STACK) public final java.util.List<android.net.wifi.WifiScanner.ScanSettings.HiddenNetwork> hiddenNetworks;
- field public boolean hideFromAppOps;
- field public boolean ignoreLocationSettings;
- field @Deprecated public int maxPeriodInMs;
- field @Deprecated public int maxScansToCache;
- field @Deprecated public int numBssidsPerScan;
- field @Deprecated public int periodInMs;
- field @Deprecated public int reportEvents;
- field @Deprecated public int stepCount;
- field @RequiresPermission(android.Manifest.permission.NETWORK_STACK) public int type;
- }
-
- public static class WifiScanner.ScanSettings.HiddenNetwork {
- ctor public WifiScanner.ScanSettings.HiddenNetwork(@NonNull String);
- field @NonNull public final String ssid;
- }
-
- @Deprecated public static interface WifiScanner.WifiChangeListener extends android.net.wifi.WifiScanner.ActionListener {
- method @Deprecated public void onChanging(android.net.wifi.ScanResult[]);
- method @Deprecated public void onQuiescence(android.net.wifi.ScanResult[]);
- }
-
- @Deprecated public static class WifiScanner.WifiChangeSettings implements android.os.Parcelable {
- ctor @Deprecated public WifiScanner.WifiChangeSettings();
- field @Deprecated public android.net.wifi.WifiScanner.BssidInfo[] bssidInfos;
- field @Deprecated public int lostApSampleSize;
- field @Deprecated public int minApsBreachingThreshold;
- field @Deprecated public int periodInMs;
- field @Deprecated public int rssiSampleSize;
- field @Deprecated public int unchangedSampleSize;
- }
-
- public final class WifiUsabilityStatsEntry implements android.os.Parcelable {
- method public int describeContents();
- method public int getCellularDataNetworkType();
- method public int getCellularSignalStrengthDb();
- method public int getCellularSignalStrengthDbm();
- method public int getLinkSpeedMbps();
- method public int getProbeElapsedTimeSinceLastUpdateMillis();
- method public int getProbeMcsRateSinceLastUpdate();
- method public int getProbeStatusSinceLastUpdate();
- method public int getRssi();
- method public int getRxLinkSpeedMbps();
- method public long getTimeStampMillis();
- method public long getTotalBackgroundScanTimeMillis();
- method public long getTotalBeaconRx();
- method public long getTotalCcaBusyFreqTimeMillis();
- method public long getTotalHotspot2ScanTimeMillis();
- method public long getTotalNanScanTimeMillis();
- method public long getTotalPnoScanTimeMillis();
- method public long getTotalRadioOnFreqTimeMillis();
- method public long getTotalRadioOnTimeMillis();
- method public long getTotalRadioRxTimeMillis();
- method public long getTotalRadioTxTimeMillis();
- method public long getTotalRoamScanTimeMillis();
- method public long getTotalRxSuccess();
- method public long getTotalScanTimeMillis();
- method public long getTotalTxBad();
- method public long getTotalTxRetries();
- method public long getTotalTxSuccess();
- method public boolean isSameRegisteredCell();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.net.wifi.WifiUsabilityStatsEntry> CREATOR;
- field public static final int PROBE_STATUS_FAILURE = 3; // 0x3
- field public static final int PROBE_STATUS_NO_PROBE = 1; // 0x1
- field public static final int PROBE_STATUS_SUCCESS = 2; // 0x2
- field public static final int PROBE_STATUS_UNKNOWN = 0; // 0x0
- }
-
-}
-
-package android.net.wifi.aware {
-
- public class DiscoverySession implements java.lang.AutoCloseable {
- method @Deprecated public android.net.NetworkSpecifier createNetworkSpecifierPmk(@NonNull android.net.wifi.aware.PeerHandle, @NonNull byte[]);
- }
-
- public class WifiAwareManager {
- method public void enableInstantCommunicationMode(boolean);
- }
-
- public class WifiAwareSession implements java.lang.AutoCloseable {
- method public android.net.NetworkSpecifier createNetworkSpecifierPmk(int, @NonNull byte[], @NonNull byte[]);
- }
-
-}
-
-package android.net.wifi.hotspot2 {
-
- public final class OsuProvider implements android.os.Parcelable {
- method public int describeContents();
- method @Nullable public String getFriendlyName();
- method @Nullable public android.net.Uri getServerUri();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.net.wifi.hotspot2.OsuProvider> CREATOR;
- }
-
- public final class PasspointConfiguration implements android.os.Parcelable {
- method public int getMeteredOverride();
- method public boolean isAutojoinEnabled();
- method public boolean isMacRandomizationEnabled();
- }
-
- public abstract class ProvisioningCallback {
- ctor public ProvisioningCallback();
- method public abstract void onProvisioningComplete();
- method public abstract void onProvisioningFailure(int);
- method public abstract void onProvisioningStatus(int);
- field public static final int OSU_FAILURE_ADD_PASSPOINT_CONFIGURATION = 22; // 0x16
- field public static final int OSU_FAILURE_AP_CONNECTION = 1; // 0x1
- field public static final int OSU_FAILURE_INVALID_URL_FORMAT_FOR_OSU = 8; // 0x8
- field public static final int OSU_FAILURE_NO_AAA_SERVER_TRUST_ROOT_NODE = 17; // 0x11
- field public static final int OSU_FAILURE_NO_AAA_TRUST_ROOT_CERTIFICATE = 21; // 0x15
- field public static final int OSU_FAILURE_NO_OSU_ACTIVITY_FOUND = 14; // 0xe
- field public static final int OSU_FAILURE_NO_POLICY_SERVER_TRUST_ROOT_NODE = 19; // 0x13
- field public static final int OSU_FAILURE_NO_PPS_MO = 16; // 0x10
- field public static final int OSU_FAILURE_NO_REMEDIATION_SERVER_TRUST_ROOT_NODE = 18; // 0x12
- field public static final int OSU_FAILURE_OSU_PROVIDER_NOT_FOUND = 23; // 0x17
- field public static final int OSU_FAILURE_PROVISIONING_ABORTED = 6; // 0x6
- field public static final int OSU_FAILURE_PROVISIONING_NOT_AVAILABLE = 7; // 0x7
- field public static final int OSU_FAILURE_RETRIEVE_TRUST_ROOT_CERTIFICATES = 20; // 0x14
- field public static final int OSU_FAILURE_SERVER_CONNECTION = 3; // 0x3
- field public static final int OSU_FAILURE_SERVER_URL_INVALID = 2; // 0x2
- field public static final int OSU_FAILURE_SERVER_VALIDATION = 4; // 0x4
- field public static final int OSU_FAILURE_SERVICE_PROVIDER_VERIFICATION = 5; // 0x5
- field public static final int OSU_FAILURE_SOAP_MESSAGE_EXCHANGE = 11; // 0xb
- field public static final int OSU_FAILURE_START_REDIRECT_LISTENER = 12; // 0xc
- field public static final int OSU_FAILURE_TIMED_OUT_REDIRECT_LISTENER = 13; // 0xd
- field public static final int OSU_FAILURE_UNEXPECTED_COMMAND_TYPE = 9; // 0x9
- field public static final int OSU_FAILURE_UNEXPECTED_SOAP_MESSAGE_STATUS = 15; // 0xf
- field public static final int OSU_FAILURE_UNEXPECTED_SOAP_MESSAGE_TYPE = 10; // 0xa
- field public static final int OSU_STATUS_AP_CONNECTED = 2; // 0x2
- field public static final int OSU_STATUS_AP_CONNECTING = 1; // 0x1
- field public static final int OSU_STATUS_INIT_SOAP_EXCHANGE = 6; // 0x6
- field public static final int OSU_STATUS_REDIRECT_RESPONSE_RECEIVED = 8; // 0x8
- field public static final int OSU_STATUS_RETRIEVING_TRUST_ROOT_CERTS = 11; // 0xb
- field public static final int OSU_STATUS_SECOND_SOAP_EXCHANGE = 9; // 0x9
- field public static final int OSU_STATUS_SERVER_CONNECTED = 5; // 0x5
- field public static final int OSU_STATUS_SERVER_CONNECTING = 3; // 0x3
- field public static final int OSU_STATUS_SERVER_VALIDATED = 4; // 0x4
- field public static final int OSU_STATUS_THIRD_SOAP_EXCHANGE = 10; // 0xa
- field public static final int OSU_STATUS_WAITING_FOR_REDIRECT_RESPONSE = 7; // 0x7
- }
-
-}
-
-package android.net.wifi.nl80211 {
-
- public final class DeviceWiphyCapabilities implements android.os.Parcelable {
- ctor public DeviceWiphyCapabilities();
- method public int describeContents();
- method public int getMaxNumberRxSpatialStreams();
- method public int getMaxNumberTxSpatialStreams();
- method public boolean isChannelWidthSupported(int);
- method public boolean isWifiStandardSupported(int);
- method public void setWifiStandardSupport(int, boolean);
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.net.wifi.nl80211.DeviceWiphyCapabilities> CREATOR;
- }
-
- public final class NativeScanResult implements android.os.Parcelable {
- ctor public NativeScanResult();
- method public int describeContents();
- method @Nullable public android.net.MacAddress getBssid();
- method public int getCapabilities();
- method public int getFrequencyMhz();
- method @NonNull public byte[] getInformationElements();
- method @NonNull public java.util.List<android.net.wifi.nl80211.RadioChainInfo> getRadioChainInfos();
- method public int getSignalMbm();
- method @NonNull public byte[] getSsid();
- method public long getTsf();
- method public boolean isAssociated();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field public static final int BSS_CAPABILITY_APSD = 2048; // 0x800
- field public static final int BSS_CAPABILITY_CF_POLLABLE = 4; // 0x4
- field public static final int BSS_CAPABILITY_CF_POLL_REQUEST = 8; // 0x8
- field public static final int BSS_CAPABILITY_CHANNEL_AGILITY = 128; // 0x80
- field public static final int BSS_CAPABILITY_DELAYED_BLOCK_ACK = 16384; // 0x4000
- field public static final int BSS_CAPABILITY_DMG_ESS = 3; // 0x3
- field public static final int BSS_CAPABILITY_DMG_IBSS = 1; // 0x1
- field public static final int BSS_CAPABILITY_DSSS_OFDM = 8192; // 0x2000
- field public static final int BSS_CAPABILITY_ESS = 1; // 0x1
- field public static final int BSS_CAPABILITY_IBSS = 2; // 0x2
- field public static final int BSS_CAPABILITY_IMMEDIATE_BLOCK_ACK = 32768; // 0x8000
- field public static final int BSS_CAPABILITY_PBCC = 64; // 0x40
- field public static final int BSS_CAPABILITY_PRIVACY = 16; // 0x10
- field public static final int BSS_CAPABILITY_QOS = 512; // 0x200
- field public static final int BSS_CAPABILITY_RADIO_MANAGEMENT = 4096; // 0x1000
- field public static final int BSS_CAPABILITY_SHORT_PREAMBLE = 32; // 0x20
- field public static final int BSS_CAPABILITY_SHORT_SLOT_TIME = 1024; // 0x400
- field public static final int BSS_CAPABILITY_SPECTRUM_MANAGEMENT = 256; // 0x100
- field @NonNull public static final android.os.Parcelable.Creator<android.net.wifi.nl80211.NativeScanResult> CREATOR;
- }
-
- public final class NativeWifiClient implements android.os.Parcelable {
- ctor public NativeWifiClient(@Nullable android.net.MacAddress);
- method public int describeContents();
- method @Nullable public android.net.MacAddress getMacAddress();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.net.wifi.nl80211.NativeWifiClient> CREATOR;
- }
-
- public final class PnoNetwork implements android.os.Parcelable {
- ctor public PnoNetwork();
- method public int describeContents();
- method @NonNull public int[] getFrequenciesMhz();
- method @NonNull public byte[] getSsid();
- method public boolean isHidden();
- method public void setFrequenciesMhz(@NonNull int[]);
- method public void setHidden(boolean);
- method public void setSsid(@NonNull byte[]);
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.net.wifi.nl80211.PnoNetwork> CREATOR;
- }
-
- public final class PnoSettings implements android.os.Parcelable {
- ctor public PnoSettings();
- method public int describeContents();
- method public long getIntervalMillis();
- method public int getMin2gRssiDbm();
- method public int getMin5gRssiDbm();
- method public int getMin6gRssiDbm();
- method @NonNull public java.util.List<android.net.wifi.nl80211.PnoNetwork> getPnoNetworks();
- method public void setIntervalMillis(long);
- method public void setMin2gRssiDbm(int);
- method public void setMin5gRssiDbm(int);
- method public void setMin6gRssiDbm(int);
- method public void setPnoNetworks(@NonNull java.util.List<android.net.wifi.nl80211.PnoNetwork>);
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.net.wifi.nl80211.PnoSettings> CREATOR;
- }
-
- public final class RadioChainInfo implements android.os.Parcelable {
- ctor public RadioChainInfo(int, int);
- method public int describeContents();
- method public int getChainId();
- method public int getLevelDbm();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.net.wifi.nl80211.RadioChainInfo> CREATOR;
- }
-
- public class WifiNl80211Manager {
- method public void abortScan(@NonNull String);
- method public void enableVerboseLogging(boolean);
- method @NonNull public int[] getChannelsMhzForBand(int);
- method @Nullable public android.net.wifi.nl80211.DeviceWiphyCapabilities getDeviceWiphyCapabilities(@NonNull String);
- method @NonNull public java.util.List<android.net.wifi.nl80211.NativeScanResult> getScanResults(@NonNull String, int);
- method @Nullable public android.net.wifi.nl80211.WifiNl80211Manager.TxPacketCounters getTxPacketCounters(@NonNull String);
- method @Nullable public static android.net.wifi.nl80211.WifiNl80211Manager.OemSecurityType parseOemSecurityTypeElement(int, int, @NonNull byte[]);
- method @Deprecated public boolean registerApCallback(@NonNull String, @NonNull java.util.concurrent.Executor, @NonNull android.net.wifi.nl80211.WifiNl80211Manager.SoftApCallback);
- method public void sendMgmtFrame(@NonNull String, @NonNull byte[], int, @NonNull java.util.concurrent.Executor, @NonNull android.net.wifi.nl80211.WifiNl80211Manager.SendMgmtFrameCallback);
- method public void setOnServiceDeadCallback(@NonNull Runnable);
- method public boolean setupInterfaceForClientMode(@NonNull String, @NonNull java.util.concurrent.Executor, @NonNull android.net.wifi.nl80211.WifiNl80211Manager.ScanEventCallback, @NonNull android.net.wifi.nl80211.WifiNl80211Manager.ScanEventCallback);
- method public boolean setupInterfaceForSoftApMode(@NonNull String);
- method @Nullable public android.net.wifi.nl80211.WifiNl80211Manager.SignalPollResult signalPoll(@NonNull String);
- method public boolean startPnoScan(@NonNull String, @NonNull android.net.wifi.nl80211.PnoSettings, @NonNull java.util.concurrent.Executor, @NonNull android.net.wifi.nl80211.WifiNl80211Manager.PnoScanRequestCallback);
- method public boolean startScan(@NonNull String, int, @Nullable java.util.Set<java.lang.Integer>, @Nullable java.util.List<byte[]>);
- method public boolean stopPnoScan(@NonNull String);
- method public boolean tearDownClientInterface(@NonNull String);
- method public boolean tearDownInterfaces();
- method public boolean tearDownSoftApInterface(@NonNull String);
- field public static final int SCAN_TYPE_PNO_SCAN = 1; // 0x1
- field public static final int SCAN_TYPE_SINGLE_SCAN = 0; // 0x0
- field public static final int SEND_MGMT_FRAME_ERROR_ALREADY_STARTED = 5; // 0x5
- field public static final int SEND_MGMT_FRAME_ERROR_MCS_UNSUPPORTED = 2; // 0x2
- field public static final int SEND_MGMT_FRAME_ERROR_NO_ACK = 3; // 0x3
- field public static final int SEND_MGMT_FRAME_ERROR_TIMEOUT = 4; // 0x4
- field public static final int SEND_MGMT_FRAME_ERROR_UNKNOWN = 1; // 0x1
- }
-
- public static class WifiNl80211Manager.OemSecurityType {
- ctor public WifiNl80211Manager.OemSecurityType(int, @NonNull java.util.List<java.lang.Integer>, @NonNull java.util.List<java.lang.Integer>, int);
- field public final int groupCipher;
- field @NonNull public final java.util.List<java.lang.Integer> keyManagement;
- field @NonNull public final java.util.List<java.lang.Integer> pairwiseCipher;
- field public final int protocol;
- }
-
- public static interface WifiNl80211Manager.PnoScanRequestCallback {
- method public void onPnoRequestFailed();
- method public void onPnoRequestSucceeded();
- }
-
- public static interface WifiNl80211Manager.ScanEventCallback {
- method public void onScanFailed();
- method public void onScanResultReady();
- }
-
- public static interface WifiNl80211Manager.SendMgmtFrameCallback {
- method public void onAck(int);
- method public void onFailure(int);
- }
-
- public static class WifiNl80211Manager.SignalPollResult {
- field public final int associationFrequencyMHz;
- field public final int currentRssiDbm;
- field public final int rxBitrateMbps;
- field public final int txBitrateMbps;
- }
-
- @Deprecated public static interface WifiNl80211Manager.SoftApCallback {
- method @Deprecated public void onConnectedClientsChanged(@NonNull android.net.wifi.nl80211.NativeWifiClient, boolean);
- method @Deprecated public void onFailure();
- method @Deprecated public void onSoftApChannelSwitched(int, int);
- }
-
- public static class WifiNl80211Manager.TxPacketCounters {
- field public final int txPacketFailed;
- field public final int txPacketSucceeded;
- }
-
-}
-
-package android.net.wifi.p2p {
-
- public final class WifiP2pGroupList implements android.os.Parcelable {
- method public int describeContents();
- method @NonNull public java.util.List<android.net.wifi.p2p.WifiP2pGroup> getGroupList();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.net.wifi.p2p.WifiP2pGroupList> CREATOR;
- }
-
- public class WifiP2pManager {
- method @RequiresPermission(anyOf={android.Manifest.permission.NETWORK_SETTINGS, android.Manifest.permission.NETWORK_STACK, android.Manifest.permission.OVERRIDE_WIFI_CONFIG}) public void deletePersistentGroup(@NonNull android.net.wifi.p2p.WifiP2pManager.Channel, int, @Nullable android.net.wifi.p2p.WifiP2pManager.ActionListener);
- method @RequiresPermission(android.Manifest.permission.NETWORK_SETTINGS) public void factoryReset(@NonNull android.net.wifi.p2p.WifiP2pManager.Channel, @Nullable android.net.wifi.p2p.WifiP2pManager.ActionListener);
- method @RequiresPermission(anyOf={android.Manifest.permission.NETWORK_SETTINGS, android.Manifest.permission.NETWORK_STACK, android.Manifest.permission.READ_WIFI_CREDENTIAL}) public void requestPersistentGroupInfo(@NonNull android.net.wifi.p2p.WifiP2pManager.Channel, @Nullable android.net.wifi.p2p.WifiP2pManager.PersistentGroupInfoListener);
- method @RequiresPermission(anyOf={android.Manifest.permission.NETWORK_SETTINGS, android.Manifest.permission.NETWORK_STACK, android.Manifest.permission.OVERRIDE_WIFI_CONFIG}) public void setDeviceName(@NonNull android.net.wifi.p2p.WifiP2pManager.Channel, @NonNull String, @Nullable android.net.wifi.p2p.WifiP2pManager.ActionListener);
- method @RequiresPermission(android.Manifest.permission.CONFIGURE_WIFI_DISPLAY) public void setMiracastMode(int);
- method @RequiresPermission(android.Manifest.permission.CONFIGURE_WIFI_DISPLAY) public void setWfdInfo(@NonNull android.net.wifi.p2p.WifiP2pManager.Channel, @NonNull android.net.wifi.p2p.WifiP2pWfdInfo, @Nullable android.net.wifi.p2p.WifiP2pManager.ActionListener);
- method @RequiresPermission(anyOf={android.Manifest.permission.NETWORK_SETTINGS, android.Manifest.permission.NETWORK_STACK, android.Manifest.permission.OVERRIDE_WIFI_CONFIG}) public void setWifiP2pChannels(@NonNull android.net.wifi.p2p.WifiP2pManager.Channel, int, int, @Nullable android.net.wifi.p2p.WifiP2pManager.ActionListener);
- method @RequiresPermission(android.Manifest.permission.NETWORK_SETTINGS) public void startListening(@NonNull android.net.wifi.p2p.WifiP2pManager.Channel, @Nullable android.net.wifi.p2p.WifiP2pManager.ActionListener);
- method @RequiresPermission(android.Manifest.permission.NETWORK_SETTINGS) public void stopListening(@NonNull android.net.wifi.p2p.WifiP2pManager.Channel, @Nullable android.net.wifi.p2p.WifiP2pManager.ActionListener);
- field public static final String ACTION_WIFI_P2P_PERSISTENT_GROUPS_CHANGED = "android.net.wifi.p2p.action.WIFI_P2P_PERSISTENT_GROUPS_CHANGED";
- field public static final int MIRACAST_DISABLED = 0; // 0x0
- field public static final int MIRACAST_SINK = 2; // 0x2
- field public static final int MIRACAST_SOURCE = 1; // 0x1
- }
-
- public static interface WifiP2pManager.PersistentGroupInfoListener {
- method public void onPersistentGroupInfoAvailable(@NonNull android.net.wifi.p2p.WifiP2pGroupList);
- }
-
-}
-
-package android.net.wifi.rtt {
-
- public static final class RangingRequest.Builder {
- method public android.net.wifi.rtt.RangingRequest.Builder addResponder(@NonNull android.net.wifi.rtt.ResponderConfig);
- }
-
- public final class RangingResult implements android.os.Parcelable {
- method @NonNull public byte[] getLci();
- method @NonNull public byte[] getLcr();
- }
-
- public final class ResponderConfig implements android.os.Parcelable {
- ctor public ResponderConfig(@NonNull android.net.MacAddress, int, boolean, int, int, int, int, int);
- ctor public ResponderConfig(@NonNull android.net.wifi.aware.PeerHandle, int, boolean, int, int, int, int, int);
- method public int describeContents();
- method public static android.net.wifi.rtt.ResponderConfig fromScanResult(android.net.wifi.ScanResult);
- method public static android.net.wifi.rtt.ResponderConfig fromWifiAwarePeerHandleWithDefaults(android.net.wifi.aware.PeerHandle);
- method public static android.net.wifi.rtt.ResponderConfig fromWifiAwarePeerMacAddressWithDefaults(android.net.MacAddress);
- method public void writeToParcel(android.os.Parcel, int);
- field public static final int CHANNEL_WIDTH_160MHZ = 3; // 0x3
- field public static final int CHANNEL_WIDTH_20MHZ = 0; // 0x0
- field public static final int CHANNEL_WIDTH_40MHZ = 1; // 0x1
- field public static final int CHANNEL_WIDTH_80MHZ = 2; // 0x2
- field public static final int CHANNEL_WIDTH_80MHZ_PLUS_MHZ = 4; // 0x4
- field @NonNull public static final android.os.Parcelable.Creator<android.net.wifi.rtt.ResponderConfig> CREATOR;
- field public static final int PREAMBLE_HE = 3; // 0x3
- field public static final int PREAMBLE_HT = 1; // 0x1
- field public static final int PREAMBLE_LEGACY = 0; // 0x0
- field public static final int PREAMBLE_VHT = 2; // 0x2
- field public static final int RESPONDER_AP = 0; // 0x0
- field public static final int RESPONDER_AWARE = 4; // 0x4
- field public static final int RESPONDER_P2P_CLIENT = 3; // 0x3
- field public static final int RESPONDER_P2P_GO = 2; // 0x2
- field public static final int RESPONDER_STA = 1; // 0x1
- field public final int centerFreq0;
- field public final int centerFreq1;
- field public final int channelWidth;
- field public final int frequency;
- field public final android.net.MacAddress macAddress;
- field public final android.net.wifi.aware.PeerHandle peerHandle;
- field public final int preamble;
- field public final int responderType;
- field public final boolean supports80211mc;
- }
-
- public final class ResponderLocation implements android.os.Parcelable {
- method public boolean getExtraInfoOnAssociationIndication();
- }
-
- public class WifiRttManager {
- method @RequiresPermission(allOf={android.Manifest.permission.LOCATION_HARDWARE}) public void cancelRanging(@Nullable android.os.WorkSource);
- method @RequiresPermission(allOf={android.Manifest.permission.LOCATION_HARDWARE, android.Manifest.permission.ACCESS_FINE_LOCATION, android.Manifest.permission.CHANGE_WIFI_STATE, android.Manifest.permission.ACCESS_WIFI_STATE}) public void startRanging(@Nullable android.os.WorkSource, @NonNull android.net.wifi.rtt.RangingRequest, @NonNull java.util.concurrent.Executor, @NonNull android.net.wifi.rtt.RangingResultCallback);
- }
-
-}
-
-package android.nfc {
-
- public final class NfcAdapter {
- method @RequiresPermission(android.Manifest.permission.WRITE_SECURE_SETTINGS) public boolean addNfcUnlockHandler(android.nfc.NfcAdapter.NfcUnlockHandler, String[]);
- method @RequiresPermission(android.Manifest.permission.WRITE_SECURE_SETTINGS) public boolean disable();
- method @RequiresPermission(android.Manifest.permission.WRITE_SECURE_SETTINGS) public boolean disable(boolean);
- method @RequiresPermission(android.Manifest.permission.WRITE_SECURE_SETTINGS) public boolean disableNdefPush();
- method @RequiresPermission(android.Manifest.permission.WRITE_SECURE_SETTINGS) public boolean enable();
- method @RequiresPermission(android.Manifest.permission.WRITE_SECURE_SETTINGS) public boolean enableNdefPush();
- method @RequiresPermission(android.Manifest.permission.WRITE_SECURE_SETTINGS) public boolean enableSecureNfc(boolean);
- method @RequiresPermission(android.Manifest.permission.WRITE_SECURE_SETTINGS) public boolean removeNfcUnlockHandler(android.nfc.NfcAdapter.NfcUnlockHandler);
- method public void setNdefPushMessage(android.nfc.NdefMessage, android.app.Activity, int);
- field public static final int FLAG_NDEF_PUSH_NO_CONFIRM = 1; // 0x1
- }
-
- public static interface NfcAdapter.NfcUnlockHandler {
- method public boolean onUnlockAttempted(android.nfc.Tag);
- }
-
-}
-
-package android.os {
-
- public class BatteryManager {
- method @RequiresPermission(android.Manifest.permission.POWER_SAVER) public boolean setChargingStateUpdateDelayMillis(int);
- field public static final String EXTRA_EVENTS = "android.os.extra.EVENTS";
- field public static final String EXTRA_EVENT_TIMESTAMP = "android.os.extra.EVENT_TIMESTAMP";
- }
-
- public final class BatterySaverPolicyConfig implements android.os.Parcelable {
- method public int describeContents();
- method public float getAdjustBrightnessFactor();
- method public boolean getAdvertiseIsEnabled();
- method public boolean getDeferFullBackup();
- method public boolean getDeferKeyValueBackup();
- method @NonNull public java.util.Map<java.lang.String,java.lang.String> getDeviceSpecificSettings();
- method public boolean getDisableAnimation();
- method public boolean getDisableAod();
- method public boolean getDisableLaunchBoost();
- method public boolean getDisableOptionalSensors();
- method public boolean getDisableSoundTrigger();
- method public boolean getDisableVibration();
- method public boolean getEnableAdjustBrightness();
- method public boolean getEnableDataSaver();
- method public boolean getEnableFirewall();
- method public boolean getEnableNightMode();
- method public boolean getEnableQuickDoze();
- method public boolean getForceAllAppsStandby();
- method public boolean getForceBackgroundCheck();
- method public int getLocationMode();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.os.BatterySaverPolicyConfig> CREATOR;
- }
-
- public static final class BatterySaverPolicyConfig.Builder {
- ctor public BatterySaverPolicyConfig.Builder();
- method @NonNull public android.os.BatterySaverPolicyConfig.Builder addDeviceSpecificSetting(@NonNull String, @NonNull String);
- method @NonNull public android.os.BatterySaverPolicyConfig build();
- method @NonNull public android.os.BatterySaverPolicyConfig.Builder setAdjustBrightnessFactor(float);
- method @NonNull public android.os.BatterySaverPolicyConfig.Builder setAdvertiseIsEnabled(boolean);
- method @NonNull public android.os.BatterySaverPolicyConfig.Builder setDeferFullBackup(boolean);
- method @NonNull public android.os.BatterySaverPolicyConfig.Builder setDeferKeyValueBackup(boolean);
- method @NonNull public android.os.BatterySaverPolicyConfig.Builder setDisableAnimation(boolean);
- method @NonNull public android.os.BatterySaverPolicyConfig.Builder setDisableAod(boolean);
- method @NonNull public android.os.BatterySaverPolicyConfig.Builder setDisableLaunchBoost(boolean);
- method @NonNull public android.os.BatterySaverPolicyConfig.Builder setDisableOptionalSensors(boolean);
- method @NonNull public android.os.BatterySaverPolicyConfig.Builder setDisableSoundTrigger(boolean);
- method @NonNull public android.os.BatterySaverPolicyConfig.Builder setDisableVibration(boolean);
- method @NonNull public android.os.BatterySaverPolicyConfig.Builder setEnableAdjustBrightness(boolean);
- method @NonNull public android.os.BatterySaverPolicyConfig.Builder setEnableDataSaver(boolean);
- method @NonNull public android.os.BatterySaverPolicyConfig.Builder setEnableFirewall(boolean);
- method @NonNull public android.os.BatterySaverPolicyConfig.Builder setEnableNightMode(boolean);
- method @NonNull public android.os.BatterySaverPolicyConfig.Builder setEnableQuickDoze(boolean);
- method @NonNull public android.os.BatterySaverPolicyConfig.Builder setForceAllAppsStandby(boolean);
- method @NonNull public android.os.BatterySaverPolicyConfig.Builder setForceBackgroundCheck(boolean);
- method @NonNull public android.os.BatterySaverPolicyConfig.Builder setLocationMode(int);
- }
-
- public final class BatteryStatsManager {
- method @NonNull @RequiresPermission(android.Manifest.permission.UPDATE_DEVICE_STATS) public android.os.connectivity.CellularBatteryStats getCellularBatteryStats();
- method @NonNull @RequiresPermission(android.Manifest.permission.UPDATE_DEVICE_STATS) public android.os.connectivity.WifiBatteryStats getWifiBatteryStats();
- method @RequiresPermission(android.Manifest.permission.UPDATE_DEVICE_STATS) public void reportFullWifiLockAcquiredFromSource(@NonNull android.os.WorkSource);
- method @RequiresPermission(android.Manifest.permission.UPDATE_DEVICE_STATS) public void reportFullWifiLockReleasedFromSource(@NonNull android.os.WorkSource);
- method @RequiresPermission(android.Manifest.permission.UPDATE_DEVICE_STATS) public void reportWifiBatchedScanStartedFromSource(@NonNull android.os.WorkSource, @IntRange(from=0) int);
- method @RequiresPermission(android.Manifest.permission.UPDATE_DEVICE_STATS) public void reportWifiBatchedScanStoppedFromSource(@NonNull android.os.WorkSource);
- method @RequiresPermission(android.Manifest.permission.UPDATE_DEVICE_STATS) public void reportWifiMulticastDisabled(@NonNull android.os.WorkSource);
- method @RequiresPermission(android.Manifest.permission.UPDATE_DEVICE_STATS) public void reportWifiMulticastEnabled(@NonNull android.os.WorkSource);
- method @RequiresPermission(android.Manifest.permission.UPDATE_DEVICE_STATS) public void reportWifiOff();
- method @RequiresPermission(android.Manifest.permission.UPDATE_DEVICE_STATS) public void reportWifiOn();
- method @RequiresPermission(android.Manifest.permission.UPDATE_DEVICE_STATS) public void reportWifiRssiChanged(@IntRange(from=0xffffff81, to=0) int);
- method @RequiresPermission(android.Manifest.permission.UPDATE_DEVICE_STATS) public void reportWifiScanStartedFromSource(@NonNull android.os.WorkSource);
- method @RequiresPermission(android.Manifest.permission.UPDATE_DEVICE_STATS) public void reportWifiScanStoppedFromSource(@NonNull android.os.WorkSource);
- method @RequiresPermission(android.Manifest.permission.UPDATE_DEVICE_STATS) public void reportWifiState(int, @Nullable String);
- method @RequiresPermission(android.Manifest.permission.UPDATE_DEVICE_STATS) public void reportWifiSupplicantStateChanged(int, boolean);
- field public static final int WIFI_STATE_OFF = 0; // 0x0
- field public static final int WIFI_STATE_OFF_SCANNING = 1; // 0x1
- field public static final int WIFI_STATE_ON_CONNECTED_P2P = 5; // 0x5
- field public static final int WIFI_STATE_ON_CONNECTED_STA = 4; // 0x4
- field public static final int WIFI_STATE_ON_CONNECTED_STA_P2P = 6; // 0x6
- field public static final int WIFI_STATE_ON_DISCONNECTED = 3; // 0x3
- field public static final int WIFI_STATE_ON_NO_NETWORKS = 2; // 0x2
- field public static final int WIFI_STATE_SOFT_AP = 7; // 0x7
- field public static final int WIFI_SUPPL_STATE_ASSOCIATED = 7; // 0x7
- field public static final int WIFI_SUPPL_STATE_ASSOCIATING = 6; // 0x6
- field public static final int WIFI_SUPPL_STATE_AUTHENTICATING = 5; // 0x5
- field public static final int WIFI_SUPPL_STATE_COMPLETED = 10; // 0xa
- field public static final int WIFI_SUPPL_STATE_DISCONNECTED = 1; // 0x1
- field public static final int WIFI_SUPPL_STATE_DORMANT = 11; // 0xb
- field public static final int WIFI_SUPPL_STATE_FOUR_WAY_HANDSHAKE = 8; // 0x8
- field public static final int WIFI_SUPPL_STATE_GROUP_HANDSHAKE = 9; // 0x9
- field public static final int WIFI_SUPPL_STATE_INACTIVE = 3; // 0x3
- field public static final int WIFI_SUPPL_STATE_INTERFACE_DISABLED = 2; // 0x2
- field public static final int WIFI_SUPPL_STATE_INVALID = 0; // 0x0
- field public static final int WIFI_SUPPL_STATE_SCANNING = 4; // 0x4
- field public static final int WIFI_SUPPL_STATE_UNINITIALIZED = 12; // 0xc
- }
-
- public class Binder implements android.os.IBinder {
- method public int handleShellCommand(@NonNull android.os.ParcelFileDescriptor, @NonNull android.os.ParcelFileDescriptor, @NonNull android.os.ParcelFileDescriptor, @NonNull String[]);
- method public static void setProxyTransactListener(@Nullable android.os.Binder.ProxyTransactListener);
- }
-
- public static interface Binder.ProxyTransactListener {
- method public void onTransactEnded(@Nullable Object);
- method @Nullable public Object onTransactStarted(@NonNull android.os.IBinder, int);
- }
-
- public final class BugreportManager {
- method @RequiresPermission(android.Manifest.permission.DUMP) public void cancelBugreport();
- method @RequiresPermission(android.Manifest.permission.DUMP) public void requestBugreport(@NonNull android.os.BugreportParams, @Nullable CharSequence, @Nullable CharSequence);
- method @RequiresPermission(android.Manifest.permission.DUMP) public void startBugreport(@NonNull android.os.ParcelFileDescriptor, @Nullable android.os.ParcelFileDescriptor, @NonNull android.os.BugreportParams, @NonNull java.util.concurrent.Executor, @NonNull android.os.BugreportManager.BugreportCallback);
- }
-
- public abstract static class BugreportManager.BugreportCallback {
- ctor public BugreportManager.BugreportCallback();
- method public void onError(int);
- method public void onFinished();
- method public void onProgress(@FloatRange(from=0.0f, to=100.0f) float);
- field public static final int BUGREPORT_ERROR_ANOTHER_REPORT_IN_PROGRESS = 5; // 0x5
- field public static final int BUGREPORT_ERROR_INVALID_INPUT = 1; // 0x1
- field public static final int BUGREPORT_ERROR_RUNTIME = 2; // 0x2
- field public static final int BUGREPORT_ERROR_USER_CONSENT_TIMED_OUT = 4; // 0x4
- field public static final int BUGREPORT_ERROR_USER_DENIED_CONSENT = 3; // 0x3
- }
-
- public final class BugreportParams {
- ctor public BugreportParams(int);
- method public int getMode();
- field public static final int BUGREPORT_MODE_FULL = 0; // 0x0
- field public static final int BUGREPORT_MODE_INTERACTIVE = 1; // 0x1
- field public static final int BUGREPORT_MODE_REMOTE = 2; // 0x2
- field public static final int BUGREPORT_MODE_TELEPHONY = 4; // 0x4
- field public static final int BUGREPORT_MODE_WEAR = 3; // 0x3
- field public static final int BUGREPORT_MODE_WIFI = 5; // 0x5
- }
-
- public static class Build.VERSION {
- field @NonNull public static final String PREVIEW_SDK_FINGERPRINT;
- }
-
- public final class ConfigUpdate {
- field public static final String ACTION_UPDATE_CARRIER_ID_DB = "android.os.action.UPDATE_CARRIER_ID_DB";
- field public static final String ACTION_UPDATE_CARRIER_PROVISIONING_URLS = "android.intent.action.UPDATE_CARRIER_PROVISIONING_URLS";
- field public static final String ACTION_UPDATE_CONVERSATION_ACTIONS = "android.intent.action.UPDATE_CONVERSATION_ACTIONS";
- field public static final String ACTION_UPDATE_CT_LOGS = "android.intent.action.UPDATE_CT_LOGS";
- field public static final String ACTION_UPDATE_EMERGENCY_NUMBER_DB = "android.os.action.UPDATE_EMERGENCY_NUMBER_DB";
- field public static final String ACTION_UPDATE_INTENT_FIREWALL = "android.intent.action.UPDATE_INTENT_FIREWALL";
- field public static final String ACTION_UPDATE_LANG_ID = "android.intent.action.UPDATE_LANG_ID";
- field public static final String ACTION_UPDATE_NETWORK_WATCHLIST = "android.intent.action.UPDATE_NETWORK_WATCHLIST";
- field public static final String ACTION_UPDATE_PINS = "android.intent.action.UPDATE_PINS";
- field public static final String ACTION_UPDATE_SMART_SELECTION = "android.intent.action.UPDATE_SMART_SELECTION";
- field public static final String ACTION_UPDATE_SMS_SHORT_CODES = "android.intent.action.UPDATE_SMS_SHORT_CODES";
- field public static final String EXTRA_REQUIRED_HASH = "android.os.extra.REQUIRED_HASH";
- field public static final String EXTRA_VERSION = "android.os.extra.VERSION";
- }
-
- public class DeviceIdleManager {
- method @RequiresPermission(android.Manifest.permission.DEVICE_POWER) public void endIdle(@NonNull String);
- }
-
- public class Environment {
- method @NonNull public static java.util.Collection<java.io.File> getInternalMediaDirectories();
- method @NonNull public static java.io.File getOdmDirectory();
- method @NonNull public static java.io.File getOemDirectory();
- method @NonNull public static java.io.File getProductDirectory();
- method @Deprecated @NonNull public static java.io.File getProductServicesDirectory();
- method @NonNull public static java.io.File getSystemExtDirectory();
- method @NonNull public static java.io.File getVendorDirectory();
- }
-
- public class HidlMemory implements java.io.Closeable {
- ctor public HidlMemory(@NonNull String, @IntRange(from=0) long, @Nullable android.os.NativeHandle);
- method public void close() throws java.io.IOException;
- method @NonNull public android.os.HidlMemory dup() throws java.io.IOException;
- method protected void finalize();
- method @Nullable public android.os.NativeHandle getHandle();
- method @NonNull public String getName();
- method public long getSize();
- method @Nullable public android.os.NativeHandle releaseHandle();
- }
-
- public class HidlSupport {
- method public static boolean deepEquals(Object, Object);
- method public static int deepHashCode(Object);
- method public static int getPidIfSharable();
- method public static boolean interfacesEqual(android.os.IHwInterface, Object);
- }
-
- public abstract class HwBinder implements android.os.IHwBinder {
- ctor public HwBinder();
- method public static final void configureRpcThreadpool(long, boolean);
- method public static void enableInstrumentation();
- method public static final android.os.IHwBinder getService(String, String) throws java.util.NoSuchElementException, android.os.RemoteException;
- method public static final android.os.IHwBinder getService(String, String, boolean) throws java.util.NoSuchElementException, android.os.RemoteException;
- method public static final void joinRpcThreadpool();
- method public abstract void onTransact(int, android.os.HwParcel, android.os.HwParcel, int) throws android.os.RemoteException;
- method public final void registerService(String) throws android.os.RemoteException;
- method public final void transact(int, android.os.HwParcel, android.os.HwParcel, int) throws android.os.RemoteException;
- }
-
- public class HwBlob {
- ctor public HwBlob(int);
- method public final void copyToBoolArray(long, boolean[], int);
- method public final void copyToDoubleArray(long, double[], int);
- method public final void copyToFloatArray(long, float[], int);
- method public final void copyToInt16Array(long, short[], int);
- method public final void copyToInt32Array(long, int[], int);
- method public final void copyToInt64Array(long, long[], int);
- method public final void copyToInt8Array(long, byte[], int);
- method public final boolean getBool(long);
- method public final double getDouble(long);
- method public final long getFieldHandle(long);
- method public final float getFloat(long);
- method public final short getInt16(long);
- method public final int getInt32(long);
- method public final long getInt64(long);
- method public final byte getInt8(long);
- method public final String getString(long);
- method public final long handle();
- method public final void putBlob(long, android.os.HwBlob);
- method public final void putBool(long, boolean);
- method public final void putBoolArray(long, boolean[]);
- method public final void putDouble(long, double);
- method public final void putDoubleArray(long, double[]);
- method public final void putFloat(long, float);
- method public final void putFloatArray(long, float[]);
- method public final void putHidlMemory(long, @NonNull android.os.HidlMemory);
- method public final void putInt16(long, short);
- method public final void putInt16Array(long, short[]);
- method public final void putInt32(long, int);
- method public final void putInt32Array(long, int[]);
- method public final void putInt64(long, long);
- method public final void putInt64Array(long, long[]);
- method public final void putInt8(long, byte);
- method public final void putInt8Array(long, byte[]);
- method public final void putNativeHandle(long, @Nullable android.os.NativeHandle);
- method public final void putString(long, String);
- method public static Boolean[] wrapArray(@NonNull boolean[]);
- method public static Long[] wrapArray(@NonNull long[]);
- method public static Byte[] wrapArray(@NonNull byte[]);
- method public static Short[] wrapArray(@NonNull short[]);
- method public static Integer[] wrapArray(@NonNull int[]);
- method public static Float[] wrapArray(@NonNull float[]);
- method public static Double[] wrapArray(@NonNull double[]);
- }
-
- public class HwParcel {
- ctor public HwParcel();
- method public final void enforceInterface(String);
- method public final boolean readBool();
- method public final java.util.ArrayList<java.lang.Boolean> readBoolVector();
- method public final android.os.HwBlob readBuffer(long);
- method public final double readDouble();
- method public final java.util.ArrayList<java.lang.Double> readDoubleVector();
- method public final android.os.HwBlob readEmbeddedBuffer(long, long, long, boolean);
- method @NonNull @Nullable public final android.os.HidlMemory readEmbeddedHidlMemory(long, long, long);
- method @Nullable public final android.os.NativeHandle readEmbeddedNativeHandle(long, long);
- method public final float readFloat();
- method public final java.util.ArrayList<java.lang.Float> readFloatVector();
- method @NonNull public final android.os.HidlMemory readHidlMemory();
- method public final short readInt16();
- method public final java.util.ArrayList<java.lang.Short> readInt16Vector();
- method public final int readInt32();
- method public final java.util.ArrayList<java.lang.Integer> readInt32Vector();
- method public final long readInt64();
- method public final java.util.ArrayList<java.lang.Long> readInt64Vector();
- method public final byte readInt8();
- method public final java.util.ArrayList<java.lang.Byte> readInt8Vector();
- method @Nullable public final android.os.NativeHandle readNativeHandle();
- method @NonNull public final java.util.ArrayList<android.os.NativeHandle> readNativeHandleVector();
- method public final String readString();
- method public final java.util.ArrayList<java.lang.String> readStringVector();
- method public final android.os.IHwBinder readStrongBinder();
- method public final void release();
- method public final void releaseTemporaryStorage();
- method public final void send();
- method public final void verifySuccess();
- method public final void writeBool(boolean);
- method public final void writeBoolVector(java.util.ArrayList<java.lang.Boolean>);
- method public final void writeBuffer(android.os.HwBlob);
- method public final void writeDouble(double);
- method public final void writeDoubleVector(java.util.ArrayList<java.lang.Double>);
- method public final void writeFloat(float);
- method public final void writeFloatVector(java.util.ArrayList<java.lang.Float>);
- method public final void writeHidlMemory(@NonNull android.os.HidlMemory);
- method public final void writeInt16(short);
- method public final void writeInt16Vector(java.util.ArrayList<java.lang.Short>);
- method public final void writeInt32(int);
- method public final void writeInt32Vector(java.util.ArrayList<java.lang.Integer>);
- method public final void writeInt64(long);
- method public final void writeInt64Vector(java.util.ArrayList<java.lang.Long>);
- method public final void writeInt8(byte);
- method public final void writeInt8Vector(java.util.ArrayList<java.lang.Byte>);
- method public final void writeInterfaceToken(String);
- method public final void writeNativeHandle(@Nullable android.os.NativeHandle);
- method public final void writeNativeHandleVector(@NonNull java.util.ArrayList<android.os.NativeHandle>);
- method public final void writeStatus(int);
- method public final void writeString(String);
- method public final void writeStringVector(java.util.ArrayList<java.lang.String>);
- method public final void writeStrongBinder(android.os.IHwBinder);
- field public static final int STATUS_SUCCESS = 0; // 0x0
- }
-
- public interface IHwBinder {
- method public boolean linkToDeath(android.os.IHwBinder.DeathRecipient, long);
- method public android.os.IHwInterface queryLocalInterface(String);
- method public void transact(int, android.os.HwParcel, android.os.HwParcel, int) throws android.os.RemoteException;
- method public boolean unlinkToDeath(android.os.IHwBinder.DeathRecipient);
- }
-
- public static interface IHwBinder.DeathRecipient {
- method public void serviceDied(long);
- }
-
- public interface IHwInterface {
- method public android.os.IHwBinder asBinder();
- }
-
- public class IncidentManager {
- method @RequiresPermission(android.Manifest.permission.APPROVE_INCIDENT_REPORTS) public void approveReport(android.net.Uri);
- method @RequiresPermission("android.permission.REQUEST_INCIDENT_REPORT_APPROVAL") public void cancelAuthorization(android.os.IncidentManager.AuthListener);
- method @RequiresPermission(allOf={android.Manifest.permission.DUMP, android.Manifest.permission.PACKAGE_USAGE_STATS}) public void deleteIncidentReports(android.net.Uri);
- method @RequiresPermission(android.Manifest.permission.APPROVE_INCIDENT_REPORTS) public void denyReport(android.net.Uri);
- method @Nullable @RequiresPermission(allOf={android.Manifest.permission.DUMP, android.Manifest.permission.PACKAGE_USAGE_STATS}) public android.os.IncidentManager.IncidentReport getIncidentReport(android.net.Uri);
- method @NonNull @RequiresPermission(allOf={android.Manifest.permission.DUMP, android.Manifest.permission.PACKAGE_USAGE_STATS}) public java.util.List<android.net.Uri> getIncidentReportList(String);
- method @RequiresPermission(android.Manifest.permission.APPROVE_INCIDENT_REPORTS) public java.util.List<android.os.IncidentManager.PendingReport> getPendingReports();
- method public void registerSection(int, @NonNull String, @NonNull java.util.concurrent.Executor, @NonNull android.os.IncidentManager.DumpCallback);
- method @RequiresPermission(allOf={android.Manifest.permission.DUMP, android.Manifest.permission.PACKAGE_USAGE_STATS}) public void reportIncident(android.os.IncidentReportArgs);
- method @RequiresPermission("android.permission.REQUEST_INCIDENT_REPORT_APPROVAL") public void requestAuthorization(int, String, int, android.os.IncidentManager.AuthListener);
- method public void unregisterSection(int);
- field public static final int FLAG_CONFIRMATION_DIALOG = 1; // 0x1
- field public static final int PRIVACY_POLICY_AUTO = 200; // 0xc8
- field public static final int PRIVACY_POLICY_EXPLICIT = 100; // 0x64
- field public static final int PRIVACY_POLICY_LOCAL = 0; // 0x0
- }
-
- public static class IncidentManager.AuthListener {
- ctor public IncidentManager.AuthListener();
- method public void onReportApproved();
- method public void onReportDenied();
- }
-
- public static class IncidentManager.DumpCallback {
- ctor public IncidentManager.DumpCallback();
- method public void onDumpSection(int, @NonNull java.io.OutputStream);
- }
-
- public static class IncidentManager.IncidentReport implements java.io.Closeable android.os.Parcelable {
- ctor public IncidentManager.IncidentReport(android.os.Parcel);
- method public void close();
- method public int describeContents();
- method public java.io.InputStream getInputStream() throws java.io.IOException;
- method public long getPrivacyPolicy();
- method public long getTimestamp();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.os.IncidentManager.IncidentReport> CREATOR;
- }
-
- public static class IncidentManager.PendingReport {
- ctor public IncidentManager.PendingReport(@NonNull android.net.Uri);
- method public int getFlags();
- method @NonNull public String getRequestingPackage();
- method public long getTimestamp();
- method @NonNull public android.net.Uri getUri();
- }
-
- public final class IncidentReportArgs implements android.os.Parcelable {
- ctor public IncidentReportArgs();
- ctor public IncidentReportArgs(android.os.Parcel);
- method public void addHeader(byte[]);
- method public void addSection(int);
- method public boolean containsSection(int);
- method public int describeContents();
- method public boolean isAll();
- method public void readFromParcel(android.os.Parcel);
- method public int sectionCount();
- method public void setAll(boolean);
- method public void setPrivacyPolicy(int);
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.os.IncidentReportArgs> CREATOR;
- }
-
- public final class NativeHandle implements java.io.Closeable {
- ctor public NativeHandle();
- ctor public NativeHandle(@NonNull java.io.FileDescriptor, boolean);
- ctor public NativeHandle(@NonNull java.io.FileDescriptor[], @NonNull int[], boolean);
- method public void close() throws java.io.IOException;
- method @NonNull public android.os.NativeHandle dup() throws java.io.IOException;
- method @NonNull public java.io.FileDescriptor getFileDescriptor();
- method @NonNull public java.io.FileDescriptor[] getFileDescriptors();
- method @NonNull public int[] getInts();
- method public boolean hasSingleFileDescriptor();
- }
-
- public interface Parcelable {
- field public static final int PARCELABLE_STABILITY_LOCAL = 0; // 0x0
- field public static final int PARCELABLE_STABILITY_VINTF = 1; // 0x1
- }
-
- public final class ParcelableHolder implements android.os.Parcelable {
- ctor public ParcelableHolder(int);
- method public int describeContents();
- method @Nullable public <T extends android.os.Parcelable> T getParcelable(@NonNull Class<T>);
- method public int getStability();
- method public void readFromParcel(@NonNull android.os.Parcel);
- method public boolean setParcelable(@Nullable android.os.Parcelable);
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.os.ParcelableHolder> CREATOR;
- }
-
- public final class PowerManager {
- method @RequiresPermission(allOf={android.Manifest.permission.READ_DREAM_STATE, android.Manifest.permission.WRITE_DREAM_STATE}) public void dream(long);
- method @RequiresPermission(android.Manifest.permission.DEVICE_POWER) public boolean forceSuspend();
- method @RequiresPermission(android.Manifest.permission.POWER_SAVER) public int getPowerSaveModeTrigger();
- method @RequiresPermission(android.Manifest.permission.READ_DREAM_STATE) public boolean isAmbientDisplayAvailable();
- method @RequiresPermission(android.Manifest.permission.READ_DREAM_STATE) public boolean isAmbientDisplaySuppressed();
- method @RequiresPermission(android.Manifest.permission.READ_DREAM_STATE) public boolean isAmbientDisplaySuppressedForToken(@NonNull String);
- method @RequiresPermission(anyOf={android.Manifest.permission.DEVICE_POWER, android.Manifest.permission.POWER_SAVER}) public boolean setAdaptivePowerSaveEnabled(boolean);
- method @RequiresPermission(anyOf={android.Manifest.permission.DEVICE_POWER, android.Manifest.permission.POWER_SAVER}) public boolean setAdaptivePowerSavePolicy(@NonNull android.os.BatterySaverPolicyConfig);
- method @RequiresPermission(android.Manifest.permission.DEVICE_POWER) public void setBatteryDischargePrediction(@NonNull java.time.Duration, boolean);
- method @RequiresPermission(android.Manifest.permission.POWER_SAVER) public boolean setDynamicPowerSaveHint(boolean, int);
- method @RequiresPermission(anyOf={android.Manifest.permission.DEVICE_POWER, android.Manifest.permission.POWER_SAVER}) public boolean setPowerSaveModeEnabled(boolean);
- method @RequiresPermission(android.Manifest.permission.WRITE_DREAM_STATE) public void suppressAmbientDisplay(@NonNull String, boolean);
- method @RequiresPermission(anyOf={android.Manifest.permission.DEVICE_POWER, android.Manifest.permission.USER_ACTIVITY}) public void userActivity(long, int, int);
- field public static final int POWER_SAVE_MODE_TRIGGER_DYNAMIC = 1; // 0x1
- field public static final int POWER_SAVE_MODE_TRIGGER_PERCENTAGE = 0; // 0x0
- field public static final String REBOOT_USERSPACE = "userspace";
- field public static final int USER_ACTIVITY_EVENT_ACCESSIBILITY = 3; // 0x3
- field public static final int USER_ACTIVITY_EVENT_BUTTON = 1; // 0x1
- field public static final int USER_ACTIVITY_EVENT_OTHER = 0; // 0x0
- field public static final int USER_ACTIVITY_EVENT_TOUCH = 2; // 0x2
- field public static final int USER_ACTIVITY_FLAG_INDIRECT = 2; // 0x2
- field public static final int USER_ACTIVITY_FLAG_NO_CHANGE_LIGHTS = 1; // 0x1
- }
-
- public class PowerWhitelistManager {
- method @RequiresPermission(android.Manifest.permission.DEVICE_POWER) public void addToWhitelist(@NonNull String);
- method @RequiresPermission(android.Manifest.permission.DEVICE_POWER) public void addToWhitelist(@NonNull java.util.List<java.lang.String>);
- method @RequiresPermission(android.Manifest.permission.DEVICE_POWER) public void removeFromWhitelist(@NonNull String);
- method @RequiresPermission(android.Manifest.permission.CHANGE_DEVICE_IDLE_TEMP_WHITELIST) public void whitelistAppTemporarily(@NonNull String, long);
- method @RequiresPermission(android.Manifest.permission.CHANGE_DEVICE_IDLE_TEMP_WHITELIST) public long whitelistAppTemporarilyForEvent(@NonNull String, int, @NonNull String);
- field public static final int EVENT_MMS = 2; // 0x2
- field public static final int EVENT_SMS = 1; // 0x1
- field public static final int EVENT_UNSPECIFIED = 0; // 0x0
- }
-
- public class RecoverySystem {
- method @RequiresPermission(android.Manifest.permission.RECOVERY) public static void cancelScheduledUpdate(android.content.Context) throws java.io.IOException;
- method @RequiresPermission(android.Manifest.permission.RECOVERY) public static void clearPrepareForUnattendedUpdate(@NonNull android.content.Context) throws java.io.IOException;
- method @RequiresPermission(android.Manifest.permission.RECOVERY) public static void installPackage(android.content.Context, java.io.File, boolean) throws java.io.IOException;
- method @RequiresPermission(android.Manifest.permission.RECOVERY) public static void prepareForUnattendedUpdate(@NonNull android.content.Context, @NonNull String, @Nullable android.content.IntentSender) throws java.io.IOException;
- method @RequiresPermission(android.Manifest.permission.RECOVERY) public static void processPackage(android.content.Context, java.io.File, android.os.RecoverySystem.ProgressListener, android.os.Handler) throws java.io.IOException;
- method @RequiresPermission(android.Manifest.permission.RECOVERY) public static void processPackage(android.content.Context, java.io.File, android.os.RecoverySystem.ProgressListener) throws java.io.IOException;
- method @RequiresPermission(android.Manifest.permission.RECOVERY) public static void rebootAndApply(@NonNull android.content.Context, @NonNull String, @NonNull String) throws java.io.IOException;
- method @RequiresPermission(allOf={android.Manifest.permission.RECOVERY, android.Manifest.permission.REBOOT}) public static void rebootWipeAb(android.content.Context, java.io.File, String) throws java.io.IOException;
- method @RequiresPermission(android.Manifest.permission.RECOVERY) public static void scheduleUpdateOnBoot(android.content.Context, java.io.File) throws java.io.IOException;
- method public static boolean verifyPackageCompatibility(java.io.File) throws java.io.IOException;
- }
-
- public final class RemoteCallback implements android.os.Parcelable {
- ctor public RemoteCallback(android.os.RemoteCallback.OnResultListener);
- ctor public RemoteCallback(@NonNull android.os.RemoteCallback.OnResultListener, @Nullable android.os.Handler);
- method public int describeContents();
- method public void sendResult(@Nullable android.os.Bundle);
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.os.RemoteCallback> CREATOR;
- }
-
- public static interface RemoteCallback.OnResultListener {
- method public void onResult(@Nullable android.os.Bundle);
- }
-
- public class ServiceSpecificException extends java.lang.RuntimeException {
- ctor public ServiceSpecificException(int, @Nullable String);
- ctor public ServiceSpecificException(int);
- field public final int errorCode;
- }
-
- public final class StatsDimensionsValue implements android.os.Parcelable {
- method public int describeContents();
- method public boolean getBooleanValue();
- method public int getField();
- method public float getFloatValue();
- method public int getIntValue();
- method public long getLongValue();
- method public String getStringValue();
- method public java.util.List<android.os.StatsDimensionsValue> getTupleValueList();
- method public int getValueType();
- method public boolean isValueType(int);
- method public void writeToParcel(android.os.Parcel, int);
- field public static final int BOOLEAN_VALUE_TYPE = 5; // 0x5
- field @NonNull public static final android.os.Parcelable.Creator<android.os.StatsDimensionsValue> CREATOR;
- field public static final int FLOAT_VALUE_TYPE = 6; // 0x6
- field public static final int INT_VALUE_TYPE = 3; // 0x3
- field public static final int LONG_VALUE_TYPE = 4; // 0x4
- field public static final int STRING_VALUE_TYPE = 2; // 0x2
- field public static final int TUPLE_VALUE_TYPE = 7; // 0x7
- }
-
- public class SystemConfigManager {
- method @NonNull @RequiresPermission(android.Manifest.permission.READ_CARRIER_APP_INFO) public java.util.Set<java.lang.String> getDisabledUntilUsedPreinstalledCarrierApps();
- method @NonNull @RequiresPermission(android.Manifest.permission.READ_CARRIER_APP_INFO) public java.util.Map<java.lang.String,java.util.List<java.lang.String>> getDisabledUntilUsedPreinstalledCarrierAssociatedApps();
- }
-
- public class SystemProperties {
- method @NonNull public static String get(@NonNull String);
- method @NonNull public static String get(@NonNull String, @Nullable String);
- method public static boolean getBoolean(@NonNull String, boolean);
- method public static int getInt(@NonNull String, int);
- method public static long getLong(@NonNull String, long);
- }
-
- public class SystemUpdateManager {
- method @RequiresPermission(anyOf={android.Manifest.permission.READ_SYSTEM_UPDATE_INFO, android.Manifest.permission.RECOVERY}) public android.os.Bundle retrieveSystemUpdateInfo();
- method @RequiresPermission(android.Manifest.permission.RECOVERY) public void updateSystemUpdateInfo(android.os.PersistableBundle);
- field public static final String KEY_IS_SECURITY_UPDATE = "is_security_update";
- field public static final String KEY_STATUS = "status";
- field public static final String KEY_TARGET_BUILD_FINGERPRINT = "target_build_fingerprint";
- field public static final String KEY_TARGET_SECURITY_PATCH_LEVEL = "target_security_patch_level";
- field public static final String KEY_TITLE = "title";
- field public static final int STATUS_IDLE = 1; // 0x1
- field public static final int STATUS_IN_PROGRESS = 3; // 0x3
- field public static final int STATUS_UNKNOWN = 0; // 0x0
- field public static final int STATUS_WAITING_DOWNLOAD = 2; // 0x2
- field public static final int STATUS_WAITING_INSTALL = 4; // 0x4
- field public static final int STATUS_WAITING_REBOOT = 5; // 0x5
- }
-
- public class UpdateEngine {
- ctor public UpdateEngine();
- method @NonNull @WorkerThread public android.os.UpdateEngine.AllocateSpaceResult allocateSpace(@NonNull String, @NonNull String[]);
- method public void applyPayload(String, long, long, String[]);
- method public void applyPayload(@NonNull android.content.res.AssetFileDescriptor, @NonNull String[]);
- method public boolean bind(android.os.UpdateEngineCallback, android.os.Handler);
- method public boolean bind(android.os.UpdateEngineCallback);
- method public void cancel();
- method @WorkerThread public int cleanupAppliedPayload();
- method public void resetStatus();
- method public void resume();
- method public void suspend();
- method public boolean unbind();
- method public boolean verifyPayloadMetadata(String);
- }
-
- public static final class UpdateEngine.AllocateSpaceResult {
- method public int getErrorCode();
- method public long getFreeSpaceRequired();
- }
-
- public static final class UpdateEngine.ErrorCodeConstants {
- ctor public UpdateEngine.ErrorCodeConstants();
- field public static final int DEVICE_CORRUPTED = 61; // 0x3d
- field public static final int DOWNLOAD_PAYLOAD_VERIFICATION_ERROR = 12; // 0xc
- field public static final int DOWNLOAD_TRANSFER_ERROR = 9; // 0x9
- field public static final int ERROR = 1; // 0x1
- field public static final int FILESYSTEM_COPIER_ERROR = 4; // 0x4
- field public static final int INSTALL_DEVICE_OPEN_ERROR = 7; // 0x7
- field public static final int KERNEL_DEVICE_OPEN_ERROR = 8; // 0x8
- field public static final int NOT_ENOUGH_SPACE = 60; // 0x3c
- field public static final int PAYLOAD_HASH_MISMATCH_ERROR = 10; // 0xa
- field public static final int PAYLOAD_MISMATCHED_TYPE_ERROR = 6; // 0x6
- field public static final int PAYLOAD_SIZE_MISMATCH_ERROR = 11; // 0xb
- field public static final int PAYLOAD_TIMESTAMP_ERROR = 51; // 0x33
- field public static final int POST_INSTALL_RUNNER_ERROR = 5; // 0x5
- field public static final int SUCCESS = 0; // 0x0
- field public static final int UPDATED_BUT_NOT_ACTIVE = 52; // 0x34
- }
-
- public static final class UpdateEngine.UpdateStatusConstants {
- ctor public UpdateEngine.UpdateStatusConstants();
- field public static final int ATTEMPTING_ROLLBACK = 8; // 0x8
- field public static final int CHECKING_FOR_UPDATE = 1; // 0x1
- field public static final int DISABLED = 9; // 0x9
- field public static final int DOWNLOADING = 3; // 0x3
- field public static final int FINALIZING = 5; // 0x5
- field public static final int IDLE = 0; // 0x0
- field public static final int REPORTING_ERROR_EVENT = 7; // 0x7
- field public static final int UPDATED_NEED_REBOOT = 6; // 0x6
- field public static final int UPDATE_AVAILABLE = 2; // 0x2
- field public static final int VERIFYING = 4; // 0x4
- }
-
- public abstract class UpdateEngineCallback {
- ctor public UpdateEngineCallback();
- method public abstract void onPayloadApplicationComplete(int);
- method public abstract void onStatusUpdate(int, float);
- }
-
- public final class UserHandle implements android.os.Parcelable {
- method @NonNull public static String formatUid(int);
- method public static int getAppId(int);
- method public int getIdentifier();
- method @Deprecated public boolean isOwner();
- method public boolean isSystem();
- method public static int myUserId();
- method public static android.os.UserHandle of(int);
- field @NonNull public static final android.os.UserHandle ALL;
- field @NonNull public static final android.os.UserHandle CURRENT;
- field @NonNull public static final android.os.UserHandle SYSTEM;
- }
-
- public class UserManager {
- method @RequiresPermission(android.Manifest.permission.MANAGE_USERS) public void clearSeedAccountData();
- method @Nullable @RequiresPermission(anyOf={android.Manifest.permission.MANAGE_USERS, android.Manifest.permission.CREATE_USERS}) public android.os.UserHandle createProfile(@NonNull String, @NonNull String, @NonNull java.util.Set<java.lang.String>) throws android.os.UserManager.UserOperationException;
- method @NonNull @RequiresPermission(anyOf={android.Manifest.permission.MANAGE_USERS, android.Manifest.permission.CREATE_USERS}, conditional=true) public java.util.List<android.os.UserHandle> getAllProfiles();
- method @NonNull @RequiresPermission(anyOf={android.Manifest.permission.MANAGE_USERS, android.Manifest.permission.CREATE_USERS}, conditional=true) public java.util.List<android.os.UserHandle> getEnabledProfiles();
- method @Nullable @RequiresPermission(android.Manifest.permission.MANAGE_USERS) public android.os.UserHandle getProfileParent(@NonNull android.os.UserHandle);
- method @RequiresPermission(android.Manifest.permission.MANAGE_USERS) public String getSeedAccountName();
- method @RequiresPermission(android.Manifest.permission.MANAGE_USERS) public android.os.PersistableBundle getSeedAccountOptions();
- method @RequiresPermission(android.Manifest.permission.MANAGE_USERS) public String getSeedAccountType();
- method @RequiresPermission(android.Manifest.permission.MANAGE_USERS) public long[] getSerialNumbersOfUsers(boolean);
- method @NonNull @RequiresPermission(android.Manifest.permission.MANAGE_USERS) public java.util.List<android.os.UserHandle> getUserHandles(boolean);
- method @Nullable @RequiresPermission(anyOf={android.Manifest.permission.MANAGE_USERS, android.Manifest.permission.GET_ACCOUNTS_PRIVILEGED}) public android.graphics.Bitmap getUserIcon();
- method @Deprecated @android.os.UserManager.UserRestrictionSource @RequiresPermission(android.Manifest.permission.MANAGE_USERS) public int getUserRestrictionSource(String, android.os.UserHandle);
- method @RequiresPermission(android.Manifest.permission.MANAGE_USERS) public java.util.List<android.os.UserManager.EnforcingUser> getUserRestrictionSources(String, android.os.UserHandle);
- method @RequiresPermission(allOf={android.Manifest.permission.READ_PHONE_STATE, android.Manifest.permission.MANAGE_USERS, android.Manifest.permission.INTERACT_ACROSS_USERS}, conditional=true) public int getUserSwitchability();
- method @RequiresPermission(android.Manifest.permission.MANAGE_USERS) public boolean hasRestrictedProfiles();
- method @RequiresPermission(anyOf={android.Manifest.permission.MANAGE_USERS, android.Manifest.permission.INTERACT_ACROSS_USERS}, conditional=true) public boolean hasUserRestrictionForUser(@NonNull String, @NonNull android.os.UserHandle);
- method @RequiresPermission(android.Manifest.permission.MANAGE_USERS) public boolean isAdminUser();
- method @RequiresPermission(anyOf={android.Manifest.permission.MANAGE_USERS, android.Manifest.permission.CREATE_USERS}) public boolean isGuestUser();
- method @RequiresPermission(anyOf={android.Manifest.permission.MANAGE_USERS, android.Manifest.permission.INTERACT_ACROSS_USERS}, conditional=true) public boolean isManagedProfile(int);
- method @RequiresPermission(anyOf={android.Manifest.permission.MANAGE_USERS, android.Manifest.permission.CREATE_USERS}) public boolean isPrimaryUser();
- method @RequiresPermission(anyOf={android.Manifest.permission.MANAGE_USERS, android.Manifest.permission.INTERACT_ACROSS_USERS}, conditional=true) public boolean isProfile();
- method @RequiresPermission(android.Manifest.permission.MANAGE_USERS) public boolean isRestrictedProfile();
- method @RequiresPermission(anyOf={android.Manifest.permission.MANAGE_USERS, android.Manifest.permission.CREATE_USERS}) public boolean isRestrictedProfile(@NonNull android.os.UserHandle);
- method @RequiresPermission(android.Manifest.permission.MANAGE_USERS) public boolean isSameProfileGroup(@NonNull android.os.UserHandle, @NonNull android.os.UserHandle);
- method @RequiresPermission(anyOf={android.Manifest.permission.MANAGE_USERS, android.Manifest.permission.GET_ACCOUNTS_PRIVILEGED}) public boolean isUserNameSet();
- method @RequiresPermission(android.Manifest.permission.MANAGE_USERS) public boolean isUserOfType(@NonNull String);
- method @RequiresPermission(anyOf={android.Manifest.permission.MANAGE_USERS, android.Manifest.permission.INTERACT_ACROSS_USERS}, conditional=true) public boolean isUserUnlockingOrUnlocked(@NonNull android.os.UserHandle);
- method @RequiresPermission(anyOf={android.Manifest.permission.MANAGE_USERS, android.Manifest.permission.CREATE_USERS}) public boolean removeUser(@NonNull android.os.UserHandle);
- method @RequiresPermission(android.Manifest.permission.MANAGE_USERS) public void setUserIcon(@NonNull android.graphics.Bitmap) throws android.os.UserManager.UserOperationException;
- method @RequiresPermission(android.Manifest.permission.MANAGE_USERS) public void setUserName(@Nullable String);
- field public static final String ACTION_USER_RESTRICTIONS_CHANGED = "android.os.action.USER_RESTRICTIONS_CHANGED";
- field @Deprecated public static final String DISALLOW_OEM_UNLOCK = "no_oem_unlock";
- field public static final String DISALLOW_RUN_IN_BACKGROUND = "no_run_in_background";
- field public static final int RESTRICTION_NOT_SET = 0; // 0x0
- field public static final int RESTRICTION_SOURCE_DEVICE_OWNER = 2; // 0x2
- field public static final int RESTRICTION_SOURCE_PROFILE_OWNER = 4; // 0x4
- field public static final int RESTRICTION_SOURCE_SYSTEM = 1; // 0x1
- field public static final int SWITCHABILITY_STATUS_OK = 0; // 0x0
- field public static final int SWITCHABILITY_STATUS_SYSTEM_USER_LOCKED = 4; // 0x4
- field public static final int SWITCHABILITY_STATUS_USER_IN_CALL = 1; // 0x1
- field public static final int SWITCHABILITY_STATUS_USER_SWITCH_DISALLOWED = 2; // 0x2
- field public static final String USER_TYPE_FULL_SECONDARY = "android.os.usertype.full.SECONDARY";
- field public static final String USER_TYPE_FULL_SYSTEM = "android.os.usertype.full.SYSTEM";
- field public static final String USER_TYPE_PROFILE_MANAGED = "android.os.usertype.profile.MANAGED";
- field public static final String USER_TYPE_SYSTEM_HEADLESS = "android.os.usertype.system.HEADLESS";
- }
-
- public static final class UserManager.EnforcingUser implements android.os.Parcelable {
- method public int describeContents();
- method public android.os.UserHandle getUserHandle();
- method @android.os.UserManager.UserRestrictionSource public int getUserRestrictionSource();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.os.UserManager.EnforcingUser> CREATOR;
- }
-
- @IntDef(flag=true, prefix={"RESTRICTION_"}, value={android.os.UserManager.RESTRICTION_NOT_SET, android.os.UserManager.RESTRICTION_SOURCE_SYSTEM, android.os.UserManager.RESTRICTION_SOURCE_DEVICE_OWNER, android.os.UserManager.RESTRICTION_SOURCE_PROFILE_OWNER}) @java.lang.annotation.Retention(java.lang.annotation.RetentionPolicy.SOURCE) public static @interface UserManager.UserRestrictionSource {
- }
-
- public abstract class Vibrator {
- method @RequiresPermission(android.Manifest.permission.ACCESS_VIBRATOR_STATE) public void addVibratorStateListener(@NonNull android.os.Vibrator.OnVibratorStateChangedListener);
- method @RequiresPermission(android.Manifest.permission.ACCESS_VIBRATOR_STATE) public void addVibratorStateListener(@NonNull java.util.concurrent.Executor, @NonNull android.os.Vibrator.OnVibratorStateChangedListener);
- method @RequiresPermission(android.Manifest.permission.ACCESS_VIBRATOR_STATE) public boolean isVibrating();
- method @RequiresPermission(android.Manifest.permission.ACCESS_VIBRATOR_STATE) public void removeVibratorStateListener(@NonNull android.os.Vibrator.OnVibratorStateChangedListener);
- }
-
- public static interface Vibrator.OnVibratorStateChangedListener {
- method public void onVibratorStateChanged(boolean);
- }
-
- public class WorkSource implements android.os.Parcelable {
- ctor public WorkSource(int);
- ctor public WorkSource(int, @NonNull String);
- method public android.os.WorkSource.WorkChain createWorkChain();
- method @Nullable public String getPackageName(int);
- method public int getUid(int);
- method @Nullable public java.util.List<android.os.WorkSource.WorkChain> getWorkChains();
- method public boolean isEmpty();
- method public int size();
- method @NonNull public android.os.WorkSource withoutNames();
- }
-
- public static final class WorkSource.WorkChain implements android.os.Parcelable {
- ctor public WorkSource.WorkChain();
- method public android.os.WorkSource.WorkChain addNode(int, @Nullable String);
- method public int describeContents();
- method public String getAttributionTag();
- method public int getAttributionUid();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.os.WorkSource.WorkChain> CREATOR;
- }
-
-}
-
-package android.os.connectivity {
-
- public final class CellularBatteryStats implements android.os.Parcelable {
- method public int describeContents();
- method public long getEnergyConsumedMaMillis();
- method public long getIdleTimeMillis();
- method public long getKernelActiveTimeMillis();
- method public long getLoggingDurationMillis();
- method public long getMonitoredRailChargeConsumedMaMillis();
- method public long getNumBytesRx();
- method public long getNumBytesTx();
- method public long getNumPacketsRx();
- method public long getNumPacketsTx();
- method public long getRxTimeMillis();
- method public long getSleepTimeMillis();
- method @NonNull public long getTimeInRatMicros(int);
- method @NonNull public long getTimeInRxSignalStrengthLevelMicros(@IntRange(from=android.telephony.CellSignalStrength.SIGNAL_STRENGTH_NONE_OR_UNKNOWN, to=android.telephony.CellSignalStrength.SIGNAL_STRENGTH_GREAT) int);
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.os.connectivity.CellularBatteryStats> CREATOR;
- }
-
- public final class WifiActivityEnergyInfo implements android.os.Parcelable {
- ctor public WifiActivityEnergyInfo(long, int, @IntRange(from=0) long, @IntRange(from=0) long, @IntRange(from=0) long, @IntRange(from=0) long);
- method public int describeContents();
- method @IntRange(from=0) public long getControllerEnergyUsedMicroJoules();
- method @IntRange(from=0) public long getControllerIdleDurationMillis();
- method @IntRange(from=0) public long getControllerRxDurationMillis();
- method @IntRange(from=0) public long getControllerScanDurationMillis();
- method @IntRange(from=0) public long getControllerTxDurationMillis();
- method public int getStackState();
- method public long getTimeSinceBootMillis();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.os.connectivity.WifiActivityEnergyInfo> CREATOR;
- field public static final int STACK_STATE_INVALID = 0; // 0x0
- field public static final int STACK_STATE_STATE_ACTIVE = 1; // 0x1
- field public static final int STACK_STATE_STATE_IDLE = 3; // 0x3
- field public static final int STACK_STATE_STATE_SCANNING = 2; // 0x2
- }
-
- public final class WifiBatteryStats implements android.os.Parcelable {
- method public int describeContents();
- method public long getAppScanRequestCount();
- method public long getEnergyConsumedMaMillis();
- method public long getIdleTimeMillis();
- method public long getKernelActiveTimeMillis();
- method public long getLoggingDurationMillis();
- method public long getMonitoredRailChargeConsumedMaMillis();
- method public long getNumBytesRx();
- method public long getNumBytesTx();
- method public long getNumPacketsRx();
- method public long getNumPacketsTx();
- method public long getRxTimeMillis();
- method public long getScanTimeMillis();
- method public long getSleepTimeMillis();
- method public long getTxTimeMillis();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.os.connectivity.WifiBatteryStats> CREATOR;
- }
-
-}
-
-package android.os.ext {
-
- public class SdkExtensions {
- method public static int getExtensionVersion(int);
- }
-
-}
-
-package android.os.image {
-
- public class DynamicSystemClient {
- ctor public DynamicSystemClient(@NonNull android.content.Context);
- method @RequiresPermission(android.Manifest.permission.INSTALL_DYNAMIC_SYSTEM) public void bind();
- method public void setOnStatusChangedListener(@NonNull java.util.concurrent.Executor, @NonNull android.os.image.DynamicSystemClient.OnStatusChangedListener);
- method public void setOnStatusChangedListener(@NonNull android.os.image.DynamicSystemClient.OnStatusChangedListener);
- method @RequiresPermission(android.Manifest.permission.INSTALL_DYNAMIC_SYSTEM) public void start(@NonNull android.net.Uri, long);
- method @RequiresPermission(android.Manifest.permission.INSTALL_DYNAMIC_SYSTEM) public void start(@NonNull android.net.Uri, long, long);
- method @RequiresPermission(android.Manifest.permission.INSTALL_DYNAMIC_SYSTEM) public void unbind();
- field public static final int CAUSE_ERROR_EXCEPTION = 6; // 0x6
- field public static final int CAUSE_ERROR_INVALID_URL = 4; // 0x4
- field public static final int CAUSE_ERROR_IO = 3; // 0x3
- field public static final int CAUSE_ERROR_IPC = 5; // 0x5
- field public static final int CAUSE_INSTALL_CANCELLED = 2; // 0x2
- field public static final int CAUSE_INSTALL_COMPLETED = 1; // 0x1
- field public static final int CAUSE_NOT_SPECIFIED = 0; // 0x0
- field public static final int STATUS_IN_PROGRESS = 2; // 0x2
- field public static final int STATUS_IN_USE = 4; // 0x4
- field public static final int STATUS_NOT_STARTED = 1; // 0x1
- field public static final int STATUS_READY = 3; // 0x3
- field public static final int STATUS_UNKNOWN = 0; // 0x0
- }
-
- public static interface DynamicSystemClient.OnStatusChangedListener {
- method public void onStatusChanged(int, int, long, @Nullable Throwable);
- }
-
-}
-
-package android.os.storage {
-
- public class StorageManager {
- method @WorkerThread public void allocateBytes(@NonNull java.util.UUID, long, @RequiresPermission int) throws java.io.IOException;
- method @WorkerThread public void allocateBytes(java.io.FileDescriptor, long, @RequiresPermission int) throws java.io.IOException;
- method @WorkerThread public long getAllocatableBytes(@NonNull java.util.UUID, @RequiresPermission int) throws java.io.IOException;
- method public static boolean hasIsolatedStorage();
- method public void updateExternalStorageFileQuotaType(@NonNull java.io.File, int) throws java.io.IOException;
- field @RequiresPermission(android.Manifest.permission.ALLOCATE_AGGRESSIVE) public static final int FLAG_ALLOCATE_AGGRESSIVE = 1; // 0x1
- field public static final int QUOTA_TYPE_MEDIA_AUDIO = 2; // 0x2
- field public static final int QUOTA_TYPE_MEDIA_IMAGE = 1; // 0x1
- field public static final int QUOTA_TYPE_MEDIA_NONE = 0; // 0x0
- field public static final int QUOTA_TYPE_MEDIA_VIDEO = 3; // 0x3
- }
-
- public final class StorageVolume implements android.os.Parcelable {
- method @NonNull public String getId();
- }
-
-}
-
-package android.permission {
-
- public final class PermissionControllerManager {
- method @RequiresPermission(anyOf={android.Manifest.permission.GRANT_RUNTIME_PERMISSIONS, android.Manifest.permission.RESTORE_RUNTIME_PERMISSIONS}) public void applyStagedRuntimePermissionBackup(@NonNull String, @NonNull android.os.UserHandle, @NonNull java.util.concurrent.Executor, @NonNull java.util.function.Consumer<java.lang.Boolean>);
- method @RequiresPermission(android.Manifest.permission.GET_RUNTIME_PERMISSIONS) public void getRuntimePermissionBackup(@NonNull android.os.UserHandle, @NonNull java.util.concurrent.Executor, @NonNull java.util.function.Consumer<byte[]>);
- method @RequiresPermission(android.Manifest.permission.REVOKE_RUNTIME_PERMISSIONS) public void revokeRuntimePermissions(@NonNull java.util.Map<java.lang.String,java.util.List<java.lang.String>>, boolean, int, @NonNull java.util.concurrent.Executor, @NonNull android.permission.PermissionControllerManager.OnRevokeRuntimePermissionsCallback);
- method @RequiresPermission(anyOf={android.Manifest.permission.GRANT_RUNTIME_PERMISSIONS, android.Manifest.permission.RESTORE_RUNTIME_PERMISSIONS}) public void stageAndApplyRuntimePermissionsBackup(@NonNull byte[], @NonNull android.os.UserHandle);
- field public static final int COUNT_ONLY_WHEN_GRANTED = 1; // 0x1
- field public static final int COUNT_WHEN_SYSTEM = 2; // 0x2
- field public static final int REASON_INSTALLER_POLICY_VIOLATION = 2; // 0x2
- field public static final int REASON_MALWARE = 1; // 0x1
- }
-
- public abstract static class PermissionControllerManager.OnRevokeRuntimePermissionsCallback {
- ctor public PermissionControllerManager.OnRevokeRuntimePermissionsCallback();
- method public abstract void onRevokeRuntimePermissions(@NonNull java.util.Map<java.lang.String,java.util.List<java.lang.String>>);
- }
-
- public abstract class PermissionControllerService extends android.app.Service {
- ctor public PermissionControllerService();
- method @BinderThread public void onApplyStagedRuntimePermissionBackup(@NonNull String, @NonNull android.os.UserHandle, @NonNull java.util.function.Consumer<java.lang.Boolean>);
- method @NonNull public final android.os.IBinder onBind(android.content.Intent);
- method @BinderThread public abstract void onCountPermissionApps(@NonNull java.util.List<java.lang.String>, int, @NonNull java.util.function.IntConsumer);
- method @BinderThread public abstract void onGetAppPermissions(@NonNull String, @NonNull java.util.function.Consumer<java.util.List<android.permission.RuntimePermissionPresentationInfo>>);
- method @BinderThread public abstract void onGetPermissionUsages(boolean, long, @NonNull java.util.function.Consumer<java.util.List<android.permission.RuntimePermissionUsageInfo>>);
- method @BinderThread public abstract void onGetRuntimePermissionsBackup(@NonNull android.os.UserHandle, @NonNull java.io.OutputStream, @NonNull Runnable);
- method @BinderThread public abstract void onGrantOrUpgradeDefaultRuntimePermissions(@NonNull Runnable);
- method @BinderThread public void onOneTimePermissionSessionTimeout(@NonNull String);
- method @Deprecated @BinderThread public void onRestoreDelayedRuntimePermissionsBackup(@NonNull String, @NonNull android.os.UserHandle, @NonNull java.util.function.Consumer<java.lang.Boolean>);
- method @Deprecated @BinderThread public void onRestoreRuntimePermissionsBackup(@NonNull android.os.UserHandle, @NonNull java.io.InputStream, @NonNull Runnable);
- method @BinderThread public abstract void onRevokeRuntimePermission(@NonNull String, @NonNull String, @NonNull Runnable);
- method @BinderThread public abstract void onRevokeRuntimePermissions(@NonNull java.util.Map<java.lang.String,java.util.List<java.lang.String>>, boolean, int, @NonNull String, @NonNull java.util.function.Consumer<java.util.Map<java.lang.String,java.util.List<java.lang.String>>>);
- method @BinderThread public abstract void onSetRuntimePermissionGrantStateByDeviceAdmin(@NonNull String, @NonNull String, @NonNull String, int, @NonNull java.util.function.Consumer<java.lang.Boolean>);
- method @BinderThread public void onStageAndApplyRuntimePermissionsBackup(@NonNull android.os.UserHandle, @NonNull java.io.InputStream, @NonNull Runnable);
- method @BinderThread public void onUpdateUserSensitivePermissionFlags(int, @NonNull java.util.concurrent.Executor, @NonNull Runnable);
- method @BinderThread public void onUpdateUserSensitivePermissionFlags(int, @NonNull Runnable);
- field public static final String SERVICE_INTERFACE = "android.permission.PermissionControllerService";
- }
-
- public final class PermissionManager {
- method public int checkDeviceIdentifierAccess(@Nullable String, @Nullable String, @Nullable String, int, int);
- method @NonNull @RequiresPermission(android.Manifest.permission.ADJUST_RUNTIME_PERMISSIONS_POLICY) public java.util.Set<java.lang.String> getAutoRevokeExemptionGrantedPackages();
- method @NonNull @RequiresPermission(android.Manifest.permission.ADJUST_RUNTIME_PERMISSIONS_POLICY) public java.util.Set<java.lang.String> getAutoRevokeExemptionRequestedPackages();
- method @IntRange(from=0) @RequiresPermission(anyOf={android.Manifest.permission.ADJUST_RUNTIME_PERMISSIONS_POLICY, android.Manifest.permission.UPGRADE_RUNTIME_PERMISSIONS}) public int getRuntimePermissionsVersion();
- method @NonNull public java.util.List<android.permission.PermissionManager.SplitPermissionInfo> getSplitPermissions();
- method @RequiresPermission(anyOf={android.Manifest.permission.ADJUST_RUNTIME_PERMISSIONS_POLICY, android.Manifest.permission.UPGRADE_RUNTIME_PERMISSIONS}) public void setRuntimePermissionsVersion(@IntRange(from=0) int);
- method @RequiresPermission(android.Manifest.permission.MANAGE_ONE_TIME_PERMISSION_SESSIONS) public void startOneTimePermissionSession(@NonNull String, long, int, int);
- method @RequiresPermission(android.Manifest.permission.MANAGE_ONE_TIME_PERMISSION_SESSIONS) public void stopOneTimePermissionSession(@NonNull String);
- }
-
- public static final class PermissionManager.SplitPermissionInfo {
- method @NonNull public java.util.List<java.lang.String> getNewPermissions();
- method @NonNull public String getSplitPermission();
- method public int getTargetSdk();
- }
-
- public final class RuntimePermissionPresentationInfo implements android.os.Parcelable {
- ctor public RuntimePermissionPresentationInfo(@NonNull CharSequence, boolean, boolean);
- method public int describeContents();
- method @NonNull public CharSequence getLabel();
- method public boolean isGranted();
- method public boolean isStandard();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.permission.RuntimePermissionPresentationInfo> CREATOR;
- }
-
- public final class RuntimePermissionUsageInfo implements android.os.Parcelable {
- ctor public RuntimePermissionUsageInfo(@NonNull String, int);
- method public int describeContents();
- method public int getAppAccessCount();
- method @NonNull public String getName();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.permission.RuntimePermissionUsageInfo> CREATOR;
- }
-
-}
-
-package android.permissionpresenterservice {
-
- @Deprecated public abstract class RuntimePermissionPresenterService extends android.app.Service {
- ctor @Deprecated public RuntimePermissionPresenterService();
- method @Deprecated public final void attachBaseContext(android.content.Context);
- method @Deprecated public final android.os.IBinder onBind(android.content.Intent);
- method @Deprecated public abstract java.util.List<android.content.pm.permission.RuntimePermissionPresentationInfo> onGetAppPermissions(@NonNull String);
- field @Deprecated public static final String SERVICE_INTERFACE = "android.permissionpresenterservice.RuntimePermissionPresenterService";
- }
-
-}
-
-package android.preference {
-
- @Deprecated public class PreferenceManager {
- method @Deprecated public boolean isStorageCredentialProtected();
- method @Deprecated public void setStorageCredentialProtected();
- }
-
-}
-
-package android.print {
-
- public final class PrintManager {
- method @RequiresPermission(android.Manifest.permission.READ_PRINT_SERVICE_RECOMMENDATIONS) public void addPrintServiceRecommendationsChangeListener(@NonNull android.print.PrintManager.PrintServiceRecommendationsChangeListener, @Nullable android.os.Handler);
- method @RequiresPermission(android.Manifest.permission.READ_PRINT_SERVICES) public void addPrintServicesChangeListener(@NonNull android.print.PrintManager.PrintServicesChangeListener, @Nullable android.os.Handler);
- method @NonNull @RequiresPermission(android.Manifest.permission.READ_PRINT_SERVICE_RECOMMENDATIONS) public java.util.List<android.printservice.recommendation.RecommendationInfo> getPrintServiceRecommendations();
- method @NonNull @RequiresPermission(android.Manifest.permission.READ_PRINT_SERVICES) public java.util.List<android.printservice.PrintServiceInfo> getPrintServices(int);
- method @RequiresPermission(android.Manifest.permission.READ_PRINT_SERVICE_RECOMMENDATIONS) public void removePrintServiceRecommendationsChangeListener(@NonNull android.print.PrintManager.PrintServiceRecommendationsChangeListener);
- method @RequiresPermission(android.Manifest.permission.READ_PRINT_SERVICES) public void removePrintServicesChangeListener(@NonNull android.print.PrintManager.PrintServicesChangeListener);
- field public static final int ENABLED_SERVICES = 1; // 0x1
- }
-
- public static interface PrintManager.PrintServiceRecommendationsChangeListener {
- method public void onPrintServiceRecommendationsChanged();
- }
-
- public static interface PrintManager.PrintServicesChangeListener {
- method public void onPrintServicesChanged();
- }
-
-}
-
-package android.printservice {
-
- public final class PrintServiceInfo implements android.os.Parcelable {
- method public int describeContents();
- method @NonNull public android.content.ComponentName getComponentName();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.printservice.PrintServiceInfo> CREATOR;
- }
-
-}
-
-package android.printservice.recommendation {
-
- public final class RecommendationInfo implements android.os.Parcelable {
- ctor public RecommendationInfo(@NonNull CharSequence, @NonNull CharSequence, @NonNull java.util.List<java.net.InetAddress>, boolean);
- ctor @Deprecated public RecommendationInfo(@NonNull CharSequence, @NonNull CharSequence, @IntRange(from=0) int, boolean);
- method public int describeContents();
- method @NonNull public java.util.List<java.net.InetAddress> getDiscoveredPrinters();
- method public CharSequence getName();
- method public int getNumDiscoveredPrinters();
- method public CharSequence getPackageName();
- method public boolean recommendsMultiVendorService();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.printservice.recommendation.RecommendationInfo> CREATOR;
- }
-
- public abstract class RecommendationService extends android.app.Service {
- ctor public RecommendationService();
- method public final android.os.IBinder onBind(android.content.Intent);
- method public abstract void onConnected();
- method public abstract void onDisconnected();
- method public final void updateRecommendations(@Nullable java.util.List<android.printservice.recommendation.RecommendationInfo>);
- field public static final String SERVICE_INTERFACE = "android.printservice.recommendation.RecommendationService";
- }
-
-}
-
-package android.provider {
-
- @Deprecated public static final class ContactsContract.MetadataSync implements android.provider.BaseColumns android.provider.ContactsContract.MetadataSyncColumns {
- field @Deprecated public static final String CONTENT_ITEM_TYPE = "vnd.android.cursor.item/contact_metadata";
- field @Deprecated public static final String CONTENT_TYPE = "vnd.android.cursor.dir/contact_metadata";
- field @Deprecated public static final android.net.Uri CONTENT_URI;
- field @Deprecated public static final String METADATA_AUTHORITY = "com.android.contacts.metadata";
- field @Deprecated public static final android.net.Uri METADATA_AUTHORITY_URI;
- }
-
- @Deprecated protected static interface ContactsContract.MetadataSyncColumns {
- field @Deprecated public static final String ACCOUNT_NAME = "account_name";
- field @Deprecated public static final String ACCOUNT_TYPE = "account_type";
- field @Deprecated public static final String DATA = "data";
- field @Deprecated public static final String DATA_SET = "data_set";
- field @Deprecated public static final String DELETED = "deleted";
- field @Deprecated public static final String RAW_CONTACT_BACKUP_ID = "raw_contact_backup_id";
- }
-
- @Deprecated public static final class ContactsContract.MetadataSyncState implements android.provider.BaseColumns android.provider.ContactsContract.MetadataSyncStateColumns {
- field @Deprecated public static final String CONTENT_ITEM_TYPE = "vnd.android.cursor.item/contact_metadata_sync_state";
- field @Deprecated public static final String CONTENT_TYPE = "vnd.android.cursor.dir/contact_metadata_sync_state";
- field @Deprecated public static final android.net.Uri CONTENT_URI;
- }
-
- @Deprecated protected static interface ContactsContract.MetadataSyncStateColumns {
- field @Deprecated public static final String ACCOUNT_NAME = "account_name";
- field @Deprecated public static final String ACCOUNT_TYPE = "account_type";
- field @Deprecated public static final String DATA_SET = "data_set";
- field @Deprecated public static final String STATE = "state";
- }
-
- public final class DeviceConfig {
- method @RequiresPermission(android.Manifest.permission.READ_DEVICE_CONFIG) public static void addOnPropertiesChangedListener(@NonNull String, @NonNull java.util.concurrent.Executor, @NonNull android.provider.DeviceConfig.OnPropertiesChangedListener);
- method @RequiresPermission(android.Manifest.permission.READ_DEVICE_CONFIG) public static boolean getBoolean(@NonNull String, @NonNull String, boolean);
- method @RequiresPermission(android.Manifest.permission.READ_DEVICE_CONFIG) public static float getFloat(@NonNull String, @NonNull String, float);
- method @RequiresPermission(android.Manifest.permission.READ_DEVICE_CONFIG) public static int getInt(@NonNull String, @NonNull String, int);
- method @RequiresPermission(android.Manifest.permission.READ_DEVICE_CONFIG) public static long getLong(@NonNull String, @NonNull String, long);
- method @NonNull @RequiresPermission(android.Manifest.permission.READ_DEVICE_CONFIG) public static android.provider.DeviceConfig.Properties getProperties(@NonNull String, @NonNull java.lang.String...);
- method @RequiresPermission(android.Manifest.permission.READ_DEVICE_CONFIG) public static String getProperty(@NonNull String, @NonNull String);
- method @RequiresPermission(android.Manifest.permission.READ_DEVICE_CONFIG) public static String getString(@NonNull String, @NonNull String, @Nullable String);
- method public static void removeOnPropertiesChangedListener(@NonNull android.provider.DeviceConfig.OnPropertiesChangedListener);
- method @RequiresPermission(android.Manifest.permission.WRITE_DEVICE_CONFIG) public static void resetToDefaults(int, @Nullable String);
- method @RequiresPermission(android.Manifest.permission.WRITE_DEVICE_CONFIG) public static boolean setProperties(@NonNull android.provider.DeviceConfig.Properties) throws android.provider.DeviceConfig.BadConfigException;
- method @RequiresPermission(android.Manifest.permission.WRITE_DEVICE_CONFIG) public static boolean setProperty(@NonNull String, @NonNull String, @Nullable String, boolean);
- field public static final String NAMESPACE_ACTIVITY_MANAGER = "activity_manager";
- field public static final String NAMESPACE_ACTIVITY_MANAGER_NATIVE_BOOT = "activity_manager_native_boot";
- field public static final String NAMESPACE_APP_COMPAT = "app_compat";
- field public static final String NAMESPACE_ATTENTION_MANAGER_SERVICE = "attention_manager_service";
- field public static final String NAMESPACE_AUTOFILL = "autofill";
- field public static final String NAMESPACE_BIOMETRICS = "biometrics";
- field public static final String NAMESPACE_BLOBSTORE = "blobstore";
- field public static final String NAMESPACE_BLUETOOTH = "bluetooth";
- field public static final String NAMESPACE_CONNECTIVITY = "connectivity";
- field public static final String NAMESPACE_CONTENT_CAPTURE = "content_capture";
- field @Deprecated public static final String NAMESPACE_DEX_BOOT = "dex_boot";
- field public static final String NAMESPACE_DISPLAY_MANAGER = "display_manager";
- field public static final String NAMESPACE_GAME_DRIVER = "game_driver";
- field public static final String NAMESPACE_INPUT_NATIVE_BOOT = "input_native_boot";
- field public static final String NAMESPACE_INTELLIGENCE_ATTENTION = "intelligence_attention";
- field public static final String NAMESPACE_MEDIA_NATIVE = "media_native";
- field public static final String NAMESPACE_NETD_NATIVE = "netd_native";
- field public static final String NAMESPACE_PACKAGE_MANAGER_SERVICE = "package_manager_service";
- field public static final String NAMESPACE_PERMISSIONS = "permissions";
- field public static final String NAMESPACE_PRIVACY = "privacy";
- field public static final String NAMESPACE_PROFCOLLECT_NATIVE_BOOT = "profcollect_native_boot";
- field public static final String NAMESPACE_ROLLBACK = "rollback";
- field public static final String NAMESPACE_ROLLBACK_BOOT = "rollback_boot";
- field public static final String NAMESPACE_RUNTIME = "runtime";
- field public static final String NAMESPACE_RUNTIME_NATIVE = "runtime_native";
- field public static final String NAMESPACE_RUNTIME_NATIVE_BOOT = "runtime_native_boot";
- field public static final String NAMESPACE_SCHEDULER = "scheduler";
- field @Deprecated public static final String NAMESPACE_STORAGE = "storage";
- field public static final String NAMESPACE_STORAGE_NATIVE_BOOT = "storage_native_boot";
- field public static final String NAMESPACE_SYSTEMUI = "systemui";
- field public static final String NAMESPACE_TELEPHONY = "telephony";
- field public static final String NAMESPACE_TEXTCLASSIFIER = "textclassifier";
- field public static final String NAMESPACE_WINDOW_MANAGER_NATIVE_BOOT = "window_manager_native_boot";
- }
-
- public static class DeviceConfig.BadConfigException extends java.lang.Exception {
- ctor public DeviceConfig.BadConfigException();
- }
-
- public static interface DeviceConfig.OnPropertiesChangedListener {
- method public void onPropertiesChanged(@NonNull android.provider.DeviceConfig.Properties);
- }
-
- public static class DeviceConfig.Properties {
- method public boolean getBoolean(@NonNull String, boolean);
- method public float getFloat(@NonNull String, float);
- method public int getInt(@NonNull String, int);
- method @NonNull public java.util.Set<java.lang.String> getKeyset();
- method public long getLong(@NonNull String, long);
- method @NonNull public String getNamespace();
- method @Nullable public String getString(@NonNull String, @Nullable String);
- }
-
- public static final class DeviceConfig.Properties.Builder {
- ctor public DeviceConfig.Properties.Builder(@NonNull String);
- method @NonNull public android.provider.DeviceConfig.Properties build();
- method @NonNull public android.provider.DeviceConfig.Properties.Builder setBoolean(@NonNull String, boolean);
- method @NonNull public android.provider.DeviceConfig.Properties.Builder setFloat(@NonNull String, float);
- method @NonNull public android.provider.DeviceConfig.Properties.Builder setInt(@NonNull String, int);
- method @NonNull public android.provider.DeviceConfig.Properties.Builder setLong(@NonNull String, long);
- method @NonNull public android.provider.DeviceConfig.Properties.Builder setString(@NonNull String, @Nullable String);
- }
-
- public final class DocumentsContract {
- method @NonNull public static android.net.Uri buildDocumentUriAsUser(@NonNull String, @NonNull String, @NonNull android.os.UserHandle);
- method public static boolean isManageMode(@NonNull android.net.Uri);
- method @NonNull public static android.net.Uri setManageMode(@NonNull android.net.Uri);
- field public static final String ACTION_DOCUMENT_ROOT_SETTINGS = "android.provider.action.DOCUMENT_ROOT_SETTINGS";
- field public static final String ACTION_MANAGE_DOCUMENT = "android.provider.action.MANAGE_DOCUMENT";
- field public static final String EXTRA_SHOW_ADVANCED = "android.provider.extra.SHOW_ADVANCED";
- }
-
- public static final class DocumentsContract.Root {
- field public static final int FLAG_ADVANCED = 65536; // 0x10000
- field public static final int FLAG_HAS_SETTINGS = 131072; // 0x20000
- field public static final int FLAG_REMOVABLE_SD = 262144; // 0x40000
- field public static final int FLAG_REMOVABLE_USB = 524288; // 0x80000
- }
-
- public final class MediaStore {
- method @NonNull public static android.net.Uri rewriteToLegacy(@NonNull android.net.Uri);
- method @NonNull @WorkerThread public static android.net.Uri scanFile(@NonNull android.content.ContentResolver, @NonNull java.io.File);
- method @WorkerThread public static void scanVolume(@NonNull android.content.ContentResolver, @NonNull String);
- method @WorkerThread public static void waitForIdle(@NonNull android.content.ContentResolver);
- field public static final String AUTHORITY_LEGACY = "media_legacy";
- field @NonNull public static final android.net.Uri AUTHORITY_LEGACY_URI;
- }
-
- public abstract class SearchIndexableData {
- ctor public SearchIndexableData();
- ctor public SearchIndexableData(android.content.Context);
- field public String className;
- field public android.content.Context context;
- field public boolean enabled;
- field public int iconResId;
- field public String intentAction;
- field public String intentTargetClass;
- field public String intentTargetPackage;
- field public String key;
- field public java.util.Locale locale;
- field public String packageName;
- field public int rank;
- field public int userId;
- }
-
- public class SearchIndexableResource extends android.provider.SearchIndexableData {
- ctor public SearchIndexableResource(int, int, String, int);
- ctor public SearchIndexableResource(android.content.Context);
- field public int xmlResId;
- }
-
- public class SearchIndexablesContract {
- ctor public SearchIndexablesContract();
- field public static final int COLUMN_INDEX_NON_INDEXABLE_KEYS_KEY_VALUE = 0; // 0x0
- field public static final int COLUMN_INDEX_RAW_CLASS_NAME = 7; // 0x7
- field public static final int COLUMN_INDEX_RAW_ENTRIES = 4; // 0x4
- field public static final int COLUMN_INDEX_RAW_ICON_RESID = 8; // 0x8
- field public static final int COLUMN_INDEX_RAW_INTENT_ACTION = 9; // 0x9
- field public static final int COLUMN_INDEX_RAW_INTENT_TARGET_CLASS = 11; // 0xb
- field public static final int COLUMN_INDEX_RAW_INTENT_TARGET_PACKAGE = 10; // 0xa
- field public static final int COLUMN_INDEX_RAW_KEY = 12; // 0xc
- field public static final int COLUMN_INDEX_RAW_KEYWORDS = 5; // 0x5
- field public static final int COLUMN_INDEX_RAW_RANK = 0; // 0x0
- field public static final int COLUMN_INDEX_RAW_SCREEN_TITLE = 6; // 0x6
- field public static final int COLUMN_INDEX_RAW_SUMMARY_OFF = 3; // 0x3
- field public static final int COLUMN_INDEX_RAW_SUMMARY_ON = 2; // 0x2
- field public static final int COLUMN_INDEX_RAW_TITLE = 1; // 0x1
- field public static final int COLUMN_INDEX_RAW_USER_ID = 13; // 0xd
- field public static final int COLUMN_INDEX_XML_RES_CLASS_NAME = 2; // 0x2
- field public static final int COLUMN_INDEX_XML_RES_ICON_RESID = 3; // 0x3
- field public static final int COLUMN_INDEX_XML_RES_INTENT_ACTION = 4; // 0x4
- field public static final int COLUMN_INDEX_XML_RES_INTENT_TARGET_CLASS = 6; // 0x6
- field public static final int COLUMN_INDEX_XML_RES_INTENT_TARGET_PACKAGE = 5; // 0x5
- field public static final int COLUMN_INDEX_XML_RES_RANK = 0; // 0x0
- field public static final int COLUMN_INDEX_XML_RES_RESID = 1; // 0x1
- field public static final String DYNAMIC_INDEXABLES_RAW = "dynamic_indexables_raw";
- field public static final String DYNAMIC_INDEXABLES_RAW_PATH = "settings/dynamic_indexables_raw";
- field public static final String INDEXABLES_RAW = "indexables_raw";
- field public static final String[] INDEXABLES_RAW_COLUMNS;
- field public static final String INDEXABLES_RAW_PATH = "settings/indexables_raw";
- field public static final String INDEXABLES_XML_RES = "indexables_xml_res";
- field public static final String[] INDEXABLES_XML_RES_COLUMNS;
- field public static final String INDEXABLES_XML_RES_PATH = "settings/indexables_xml_res";
- field public static final String NON_INDEXABLES_KEYS = "non_indexables_key";
- field public static final String[] NON_INDEXABLES_KEYS_COLUMNS;
- field public static final String NON_INDEXABLES_KEYS_PATH = "settings/non_indexables_key";
- field public static final String PROVIDER_INTERFACE = "android.content.action.SEARCH_INDEXABLES_PROVIDER";
- field public static final String SLICE_URI_PAIRS = "slice_uri_pairs";
- field @NonNull public static final String[] SLICE_URI_PAIRS_COLUMNS;
- field public static final String SLICE_URI_PAIRS_PATH = "settings/slice_uri_pairs";
- }
-
- public static class SearchIndexablesContract.BaseColumns {
- field public static final String COLUMN_CLASS_NAME = "className";
- field public static final String COLUMN_ICON_RESID = "iconResId";
- field public static final String COLUMN_INTENT_ACTION = "intentAction";
- field public static final String COLUMN_INTENT_TARGET_CLASS = "intentTargetClass";
- field public static final String COLUMN_INTENT_TARGET_PACKAGE = "intentTargetPackage";
- field public static final String COLUMN_RANK = "rank";
- }
-
- public static final class SearchIndexablesContract.NonIndexableKey extends android.provider.SearchIndexablesContract.BaseColumns {
- field public static final String COLUMN_KEY_VALUE = "key";
- field public static final String MIME_TYPE = "vnd.android.cursor.dir/non_indexables_key";
- }
-
- public static final class SearchIndexablesContract.RawData extends android.provider.SearchIndexablesContract.BaseColumns {
- field public static final String COLUMN_ENTRIES = "entries";
- field public static final String COLUMN_KEY = "key";
- field public static final String COLUMN_KEYWORDS = "keywords";
- field public static final String COLUMN_SCREEN_TITLE = "screenTitle";
- field public static final String COLUMN_SUMMARY_OFF = "summaryOff";
- field public static final String COLUMN_SUMMARY_ON = "summaryOn";
- field public static final String COLUMN_TITLE = "title";
- field public static final String COLUMN_USER_ID = "user_id";
- field public static final String MIME_TYPE = "vnd.android.cursor.dir/indexables_raw";
- }
-
- public static final class SearchIndexablesContract.SliceUriPairColumns {
- field public static final String KEY = "key";
- field public static final String SLICE_URI = "slice_uri";
- }
-
- public static final class SearchIndexablesContract.XmlResource extends android.provider.SearchIndexablesContract.BaseColumns {
- field public static final String COLUMN_XML_RESID = "xmlResId";
- field public static final String MIME_TYPE = "vnd.android.cursor.dir/indexables_xml_res";
- }
-
- public abstract class SearchIndexablesProvider extends android.content.ContentProvider {
- ctor public SearchIndexablesProvider();
- method public final int delete(android.net.Uri, String, String[]);
- method public String getType(android.net.Uri);
- method public final android.net.Uri insert(android.net.Uri, android.content.ContentValues);
- method public android.database.Cursor query(android.net.Uri, String[], String, String[], String);
- method @Nullable public android.database.Cursor queryDynamicRawData(@Nullable String[]);
- method public abstract android.database.Cursor queryNonIndexableKeys(String[]);
- method public abstract android.database.Cursor queryRawData(String[]);
- method @Nullable public android.database.Cursor querySliceUriPairs();
- method public abstract android.database.Cursor queryXmlResources(String[]);
- method public final int update(android.net.Uri, android.content.ContentValues, String, String[]);
- }
-
- public final class Settings {
- method @Deprecated public static boolean checkAndNoteWriteSettingsOperation(@NonNull android.content.Context, int, @NonNull String, boolean);
- method public static boolean checkAndNoteWriteSettingsOperation(@NonNull android.content.Context, int, @NonNull String, @Nullable String, boolean);
- field public static final String ACTION_ACCESSIBILITY_DETAILS_SETTINGS = "android.settings.ACCESSIBILITY_DETAILS_SETTINGS";
- field public static final String ACTION_BUGREPORT_HANDLER_SETTINGS = "android.settings.BUGREPORT_HANDLER_SETTINGS";
- field public static final String ACTION_ENTERPRISE_PRIVACY_SETTINGS = "android.settings.ENTERPRISE_PRIVACY_SETTINGS";
- field public static final String ACTION_LOCATION_CONTROLLER_EXTRA_PACKAGE_SETTINGS = "android.settings.LOCATION_CONTROLLER_EXTRA_PACKAGE_SETTINGS";
- field public static final String ACTION_MANAGE_APP_OVERLAY_PERMISSION = "android.settings.MANAGE_APP_OVERLAY_PERMISSION";
- field public static final String ACTION_MANAGE_DOMAIN_URLS = "android.settings.MANAGE_DOMAIN_URLS";
- field public static final String ACTION_MANAGE_MORE_DEFAULT_APPS_SETTINGS = "android.settings.MANAGE_MORE_DEFAULT_APPS_SETTINGS";
- field public static final String ACTION_NOTIFICATION_POLICY_ACCESS_DETAIL_SETTINGS = "android.settings.NOTIFICATION_POLICY_ACCESS_DETAIL_SETTINGS";
- field public static final String ACTION_REQUEST_ENABLE_CONTENT_CAPTURE = "android.settings.REQUEST_ENABLE_CONTENT_CAPTURE";
- field public static final String ACTION_SHOW_ADMIN_SUPPORT_DETAILS = "android.settings.SHOW_ADMIN_SUPPORT_DETAILS";
- field public static final String ACTION_TETHER_PROVISIONING_UI = "android.settings.TETHER_PROVISIONING_UI";
- field public static final String ACTION_TETHER_SETTINGS = "android.settings.TETHER_SETTINGS";
- }
-
- public static final class Settings.Global extends android.provider.Settings.NameValueTable {
- method @RequiresPermission(android.Manifest.permission.WRITE_SECURE_SETTINGS) public static boolean putString(@NonNull android.content.ContentResolver, @NonNull String, @Nullable String, @Nullable String, boolean);
- method @RequiresPermission(android.Manifest.permission.WRITE_SECURE_SETTINGS) public static void resetToDefaults(@NonNull android.content.ContentResolver, @Nullable String);
- field public static final String AIRPLANE_MODE_TOGGLEABLE_RADIOS = "airplane_mode_toggleable_radios";
- field public static final String APP_STANDBY_ENABLED = "app_standby_enabled";
- field public static final String AUTOFILL_COMPAT_MODE_ALLOWED_PACKAGES = "autofill_compat_mode_allowed_packages";
- field public static final String CARRIER_APP_NAMES = "carrier_app_names";
- field public static final String CARRIER_APP_WHITELIST = "carrier_app_whitelist";
- field public static final String DEFAULT_SM_DP_PLUS = "default_sm_dp_plus";
- field public static final String DEVICE_DEMO_MODE = "device_demo_mode";
- field public static final String DEVICE_PROVISIONING_MOBILE_DATA_ENABLED = "device_provisioning_mobile_data";
- field public static final String EUICC_PROVISIONED = "euicc_provisioned";
- field public static final String EUICC_SUPPORTED_COUNTRIES = "euicc_supported_countries";
- field public static final String EUICC_UNSUPPORTED_COUNTRIES = "euicc_unsupported_countries";
- field public static final String INSTALL_CARRIER_APP_NOTIFICATION_PERSISTENT = "install_carrier_app_notification_persistent";
- field public static final String INSTALL_CARRIER_APP_NOTIFICATION_SLEEP_MILLIS = "install_carrier_app_notification_sleep_millis";
- field public static final String OTA_DISABLE_AUTOMATIC_UPDATE = "ota_disable_automatic_update";
- field public static final String REQUIRE_PASSWORD_TO_DECRYPT = "require_password_to_decrypt";
- field public static final String TETHER_OFFLOAD_DISABLED = "tether_offload_disabled";
- field public static final String TETHER_SUPPORTED = "tether_supported";
- field public static final String THEATER_MODE_ON = "theater_mode_on";
- field public static final String WEBVIEW_MULTIPROCESS = "webview_multiprocess";
- field public static final String WIFI_BADGING_THRESHOLDS = "wifi_badging_thresholds";
- field @Deprecated public static final String WIFI_WAKEUP_ENABLED = "wifi_wakeup_enabled";
- }
-
- public static final class Settings.Secure extends android.provider.Settings.NameValueTable {
- method @RequiresPermission(android.Manifest.permission.WRITE_SECURE_SETTINGS) public static boolean putString(@NonNull android.content.ContentResolver, @NonNull String, @Nullable String, @Nullable String, boolean);
- method @RequiresPermission(android.Manifest.permission.WRITE_SECURE_SETTINGS) public static void resetToDefaults(@NonNull android.content.ContentResolver, @Nullable String);
- field @Deprecated public static final String ACCESSIBILITY_DISPLAY_MAGNIFICATION_NAVBAR_ENABLED = "accessibility_display_magnification_navbar_enabled";
- field public static final String ASSIST_GESTURE_SETUP_COMPLETE = "assist_gesture_setup_complete";
- field public static final String AUTOFILL_FEATURE_FIELD_CLASSIFICATION = "autofill_field_classification";
- field public static final String AUTOFILL_USER_DATA_MAX_CATEGORY_COUNT = "autofill_user_data_max_category_count";
- field public static final String AUTOFILL_USER_DATA_MAX_FIELD_CLASSIFICATION_IDS_SIZE = "autofill_user_data_max_field_classification_size";
- field public static final String AUTOFILL_USER_DATA_MAX_USER_DATA_SIZE = "autofill_user_data_max_user_data_size";
- field public static final String AUTOFILL_USER_DATA_MAX_VALUE_LENGTH = "autofill_user_data_max_value_length";
- field public static final String AUTOFILL_USER_DATA_MIN_VALUE_LENGTH = "autofill_user_data_min_value_length";
- field public static final String AUTO_REVOKE_DISABLED = "auto_revoke_disabled";
- field public static final String COMPLETED_CATEGORY_PREFIX = "suggested.completed_category.";
- field public static final String DOZE_ALWAYS_ON = "doze_always_on";
- field public static final String HUSH_GESTURE_USED = "hush_gesture_used";
- field public static final String INSTANT_APPS_ENABLED = "instant_apps_enabled";
- field public static final String LAST_SETUP_SHOWN = "last_setup_shown";
- field public static final String LOCATION_ACCESS_CHECK_DELAY_MILLIS = "location_access_check_delay_millis";
- field public static final String LOCATION_ACCESS_CHECK_INTERVAL_MILLIS = "location_access_check_interval_millis";
- field public static final int LOCATION_MODE_ON = 3; // 0x3
- field @Deprecated public static final String LOCATION_PERMISSIONS_UPGRADE_TO_Q_MODE = "location_permissions_upgrade_to_q_mode";
- field public static final String LOCK_SCREEN_ALLOW_PRIVATE_NOTIFICATIONS = "lock_screen_allow_private_notifications";
- field public static final String LOCK_SCREEN_SHOW_NOTIFICATIONS = "lock_screen_show_notifications";
- field public static final String ODI_CAPTIONS_ENABLED = "odi_captions_enabled";
- field public static final String THEME_CUSTOMIZATION_OVERLAY_PACKAGES = "theme_customization_overlay_packages";
- field public static final String USER_SETUP_COMPLETE = "user_setup_complete";
- field public static final int USER_SETUP_PERSONALIZATION_COMPLETE = 10; // 0xa
- field public static final int USER_SETUP_PERSONALIZATION_NOT_STARTED = 0; // 0x0
- field public static final int USER_SETUP_PERSONALIZATION_PAUSED = 2; // 0x2
- field public static final int USER_SETUP_PERSONALIZATION_STARTED = 1; // 0x1
- field public static final String USER_SETUP_PERSONALIZATION_STATE = "user_setup_personalization_state";
- field public static final String VOLUME_HUSH_GESTURE = "volume_hush_gesture";
- field public static final int VOLUME_HUSH_MUTE = 2; // 0x2
- field public static final int VOLUME_HUSH_OFF = 0; // 0x0
- field public static final int VOLUME_HUSH_VIBRATE = 1; // 0x1
- }
-
- public static final class Settings.System extends android.provider.Settings.NameValueTable {
- method @RequiresPermission(android.Manifest.permission.MODIFY_SETTINGS_OVERRIDEABLE_BY_RESTORE) public static boolean putString(@NonNull android.content.ContentResolver, @NonNull String, @Nullable String, boolean);
- }
-
- public static final class Telephony.Carriers implements android.provider.BaseColumns {
- field public static final String APN_SET_ID = "apn_set_id";
- field public static final int CARRIER_EDITED = 4; // 0x4
- field public static final String EDITED_STATUS = "edited";
- field public static final int MATCH_ALL_APN_SET_ID = -1; // 0xffffffff
- field public static final String MAX_CONNECTIONS = "max_conns";
- field public static final String MODEM_PERSIST = "modem_cognitive";
- field public static final String MTU = "mtu";
- field public static final int NO_APN_SET_ID = 0; // 0x0
- field public static final String TIME_LIMIT_FOR_MAX_CONNECTIONS = "max_conns_time";
- field public static final int UNEDITED = 0; // 0x0
- field public static final int USER_DELETED = 2; // 0x2
- field public static final String USER_EDITABLE = "user_editable";
- field public static final int USER_EDITED = 1; // 0x1
- field public static final String USER_VISIBLE = "user_visible";
- field public static final String WAIT_TIME_RETRY = "wait_time";
- }
-
- public static final class Telephony.CellBroadcasts implements android.provider.BaseColumns {
- field @NonNull public static final String AUTHORITY_LEGACY = "cellbroadcast-legacy";
- field @NonNull public static final android.net.Uri AUTHORITY_LEGACY_URI;
- field @NonNull public static final String CALL_METHOD_GET_PREFERENCE = "get_preference";
- field public static final String CID = "cid";
- field public static final String CMAS_CATEGORY = "cmas_category";
- field public static final String CMAS_CERTAINTY = "cmas_certainty";
- field public static final String CMAS_MESSAGE_CLASS = "cmas_message_class";
- field public static final String CMAS_RESPONSE_TYPE = "cmas_response_type";
- field public static final String CMAS_SEVERITY = "cmas_severity";
- field public static final String CMAS_URGENCY = "cmas_urgency";
- field @NonNull public static final android.net.Uri CONTENT_URI;
- field public static final String DATA_CODING_SCHEME = "dcs";
- field public static final String DEFAULT_SORT_ORDER = "date DESC";
- field public static final String DELIVERY_TIME = "date";
- field public static final String ETWS_IS_PRIMARY = "etws_is_primary";
- field public static final String ETWS_WARNING_TYPE = "etws_warning_type";
- field public static final String GEOGRAPHICAL_SCOPE = "geo_scope";
- field public static final String GEOMETRIES = "geometries";
- field public static final String LAC = "lac";
- field public static final String LANGUAGE_CODE = "language";
- field public static final String LOCATION_CHECK_TIME = "location_check_time";
- field public static final String MAXIMUM_WAIT_TIME = "maximum_wait_time";
- field public static final String MESSAGE_BODY = "body";
- field public static final String MESSAGE_BROADCASTED = "message_broadcasted";
- field public static final String MESSAGE_DISPLAYED = "message_displayed";
- field public static final String MESSAGE_FORMAT = "format";
- field @NonNull @RequiresPermission(android.Manifest.permission.READ_CELL_BROADCASTS) public static final android.net.Uri MESSAGE_HISTORY_URI;
- field public static final String MESSAGE_PRIORITY = "priority";
- field public static final String MESSAGE_READ = "read";
- field public static final String PLMN = "plmn";
- field public static final String RECEIVED_TIME = "received_time";
- field public static final String SERIAL_NUMBER = "serial_number";
- field public static final String SERVICE_CATEGORY = "service_category";
- field public static final String SLOT_INDEX = "slot_index";
- field public static final String SUBSCRIPTION_ID = "sub_id";
- }
-
- public static final class Telephony.CellBroadcasts.Preference {
- field @NonNull public static final String ENABLE_ALERT_VIBRATION_PREF = "enable_alert_vibrate";
- field @NonNull public static final String ENABLE_AREA_UPDATE_INFO_PREF = "enable_area_update_info_alerts";
- field @NonNull public static final String ENABLE_CMAS_AMBER_PREF = "enable_cmas_amber_alerts";
- field @NonNull public static final String ENABLE_CMAS_EXTREME_THREAT_PREF = "enable_cmas_extreme_threat_alerts";
- field @NonNull public static final String ENABLE_CMAS_IN_SECOND_LANGUAGE_PREF = "receive_cmas_in_second_language";
- field @NonNull public static final String ENABLE_CMAS_PRESIDENTIAL_PREF = "enable_cmas_presidential_alerts";
- field @NonNull public static final String ENABLE_CMAS_SEVERE_THREAT_PREF = "enable_cmas_severe_threat_alerts";
- field @NonNull public static final String ENABLE_EMERGENCY_PERF = "enable_emergency_alerts";
- field @NonNull public static final String ENABLE_PUBLIC_SAFETY_PREF = "enable_public_safety_messages";
- field @NonNull public static final String ENABLE_STATE_LOCAL_TEST_PREF = "enable_state_local_test_alerts";
- field @NonNull public static final String ENABLE_TEST_ALERT_PREF = "enable_test_alerts";
- }
-
- public static final class Telephony.Sms.Intents {
- field public static final String ACTION_SMS_EMERGENCY_CB_RECEIVED = "android.provider.action.SMS_EMERGENCY_CB_RECEIVED";
- }
-
- public final class TimeZoneRulesDataContract {
- field public static final String AUTHORITY = "com.android.timezone";
- }
-
- public static final class TimeZoneRulesDataContract.Operation {
- field public static final String COLUMN_DISTRO_MAJOR_VERSION = "distro_major_version";
- field public static final String COLUMN_DISTRO_MINOR_VERSION = "distro_minor_version";
- field public static final String COLUMN_REVISION = "revision";
- field public static final String COLUMN_RULES_VERSION = "rules_version";
- field public static final String COLUMN_TYPE = "type";
- field public static final android.net.Uri CONTENT_URI;
- field public static final String TYPE_INSTALL = "INSTALL";
- field public static final String TYPE_NO_OP = "NOOP";
- field public static final String TYPE_UNINSTALL = "UNINSTALL";
- }
-
-}
-
-package android.se.omapi {
-
- public final class Reader {
- method @RequiresPermission(android.Manifest.permission.SECURE_ELEMENT_PRIVILEGED_OPERATION) public boolean reset();
- }
-
-}
-
-package android.security.keystore {
-
- public class AndroidKeyStoreProvider extends java.security.Provider {
- method @NonNull public static java.security.KeyStore getKeyStoreForUid(int) throws java.security.KeyStoreException, java.security.NoSuchProviderException;
- }
-
- public abstract class AttestationUtils {
- method @NonNull @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public static java.security.cert.X509Certificate[] attestDeviceIds(android.content.Context, @NonNull int[], @NonNull byte[]) throws android.security.keystore.DeviceIdAttestationException;
- field public static final int ID_TYPE_IMEI = 2; // 0x2
- field public static final int ID_TYPE_MEID = 3; // 0x3
- field public static final int ID_TYPE_SERIAL = 1; // 0x1
- field public static final int USE_INDIVIDUAL_ATTESTATION = 4; // 0x4
- }
-
- public class DeviceIdAttestationException extends java.lang.Exception {
- ctor public DeviceIdAttestationException(@Nullable String);
- ctor public DeviceIdAttestationException(@Nullable String, @Nullable Throwable);
- }
-
- public final class KeyGenParameterSpec implements java.security.spec.AlgorithmParameterSpec {
- method public int getNamespace();
- }
-
- public static final class KeyGenParameterSpec.Builder {
- method @NonNull public android.security.keystore.KeyGenParameterSpec.Builder setNamespace(int);
- method @Deprecated @NonNull public android.security.keystore.KeyGenParameterSpec.Builder setUid(int);
- }
-
-}
-
-package android.security.keystore.recovery {
-
- public class DecryptionFailedException extends java.security.GeneralSecurityException {
- ctor public DecryptionFailedException(String);
- }
-
- public class InternalRecoveryServiceException extends java.security.GeneralSecurityException {
- ctor public InternalRecoveryServiceException(String);
- ctor public InternalRecoveryServiceException(String, Throwable);
- }
-
- public final class KeyChainProtectionParams implements android.os.Parcelable {
- method public void clearSecret();
- method public int describeContents();
- method @NonNull public android.security.keystore.recovery.KeyDerivationParams getKeyDerivationParams();
- method public int getLockScreenUiFormat();
- method @NonNull public byte[] getSecret();
- method public int getUserSecretType();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.security.keystore.recovery.KeyChainProtectionParams> CREATOR;
- field public static final int TYPE_LOCKSCREEN = 100; // 0x64
- field public static final int UI_FORMAT_PASSWORD = 2; // 0x2
- field public static final int UI_FORMAT_PATTERN = 3; // 0x3
- field public static final int UI_FORMAT_PIN = 1; // 0x1
- }
-
- public static class KeyChainProtectionParams.Builder {
- ctor public KeyChainProtectionParams.Builder();
- method @NonNull public android.security.keystore.recovery.KeyChainProtectionParams build();
- method @NonNull public android.security.keystore.recovery.KeyChainProtectionParams.Builder setKeyDerivationParams(@NonNull android.security.keystore.recovery.KeyDerivationParams);
- method @NonNull public android.security.keystore.recovery.KeyChainProtectionParams.Builder setLockScreenUiFormat(int);
- method @NonNull public android.security.keystore.recovery.KeyChainProtectionParams.Builder setSecret(@NonNull byte[]);
- method @NonNull public android.security.keystore.recovery.KeyChainProtectionParams.Builder setUserSecretType(int);
- }
-
- public final class KeyChainSnapshot implements android.os.Parcelable {
- method public int describeContents();
- method public long getCounterId();
- method @NonNull public byte[] getEncryptedRecoveryKeyBlob();
- method @NonNull public java.util.List<android.security.keystore.recovery.KeyChainProtectionParams> getKeyChainProtectionParams();
- method public int getMaxAttempts();
- method @NonNull public byte[] getServerParams();
- method public int getSnapshotVersion();
- method @NonNull public java.security.cert.CertPath getTrustedHardwareCertPath();
- method @NonNull public java.util.List<android.security.keystore.recovery.WrappedApplicationKey> getWrappedApplicationKeys();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.security.keystore.recovery.KeyChainSnapshot> CREATOR;
- }
-
- public final class KeyDerivationParams implements android.os.Parcelable {
- method @NonNull public static android.security.keystore.recovery.KeyDerivationParams createScryptParams(@NonNull byte[], int);
- method @NonNull public static android.security.keystore.recovery.KeyDerivationParams createSha256Params(@NonNull byte[]);
- method public int describeContents();
- method public int getAlgorithm();
- method public int getMemoryDifficulty();
- method @NonNull public byte[] getSalt();
- method public void writeToParcel(android.os.Parcel, int);
- field public static final int ALGORITHM_SCRYPT = 2; // 0x2
- field public static final int ALGORITHM_SHA256 = 1; // 0x1
- field @NonNull public static final android.os.Parcelable.Creator<android.security.keystore.recovery.KeyDerivationParams> CREATOR;
- }
-
- public class LockScreenRequiredException extends java.security.GeneralSecurityException {
- ctor public LockScreenRequiredException(String);
- }
-
- public class RecoveryController {
- method @NonNull @RequiresPermission(android.Manifest.permission.RECOVER_KEYSTORE) public android.security.keystore.recovery.RecoverySession createRecoverySession();
- method @Deprecated @NonNull @RequiresPermission(android.Manifest.permission.RECOVER_KEYSTORE) public java.security.Key generateKey(@NonNull String) throws android.security.keystore.recovery.InternalRecoveryServiceException, android.security.keystore.recovery.LockScreenRequiredException;
- method @NonNull @RequiresPermission(android.Manifest.permission.RECOVER_KEYSTORE) public java.security.Key generateKey(@NonNull String, @Nullable byte[]) throws android.security.keystore.recovery.InternalRecoveryServiceException, android.security.keystore.recovery.LockScreenRequiredException;
- method @NonNull @RequiresPermission(android.Manifest.permission.RECOVER_KEYSTORE) public java.util.List<java.lang.String> getAliases() throws android.security.keystore.recovery.InternalRecoveryServiceException;
- method @NonNull @RequiresPermission(android.Manifest.permission.RECOVER_KEYSTORE) public static android.security.keystore.recovery.RecoveryController getInstance(@NonNull android.content.Context);
- method @Nullable @RequiresPermission(android.Manifest.permission.RECOVER_KEYSTORE) public java.security.Key getKey(@NonNull String) throws android.security.keystore.recovery.InternalRecoveryServiceException, java.security.UnrecoverableKeyException;
- method @Nullable @RequiresPermission(android.Manifest.permission.RECOVER_KEYSTORE) public android.security.keystore.recovery.KeyChainSnapshot getKeyChainSnapshot() throws android.security.keystore.recovery.InternalRecoveryServiceException;
- method @NonNull @RequiresPermission(android.Manifest.permission.RECOVER_KEYSTORE) public int[] getRecoverySecretTypes() throws android.security.keystore.recovery.InternalRecoveryServiceException;
- method @RequiresPermission(android.Manifest.permission.RECOVER_KEYSTORE) public int getRecoveryStatus(@NonNull String) throws android.security.keystore.recovery.InternalRecoveryServiceException;
- method @NonNull @RequiresPermission(android.Manifest.permission.RECOVER_KEYSTORE) public java.util.Map<java.lang.String,java.security.cert.X509Certificate> getRootCertificates();
- method @Deprecated @NonNull @RequiresPermission(android.Manifest.permission.RECOVER_KEYSTORE) public java.security.Key importKey(@NonNull String, @NonNull byte[]) throws android.security.keystore.recovery.InternalRecoveryServiceException, android.security.keystore.recovery.LockScreenRequiredException;
- method @NonNull @RequiresPermission(android.Manifest.permission.RECOVER_KEYSTORE) public java.security.Key importKey(@NonNull String, @NonNull byte[], @Nullable byte[]) throws android.security.keystore.recovery.InternalRecoveryServiceException, android.security.keystore.recovery.LockScreenRequiredException;
- method @RequiresPermission(android.Manifest.permission.RECOVER_KEYSTORE) public void initRecoveryService(@NonNull String, @NonNull byte[], @NonNull byte[]) throws java.security.cert.CertificateException, android.security.keystore.recovery.InternalRecoveryServiceException;
- method @RequiresPermission(android.Manifest.permission.RECOVER_KEYSTORE) public static boolean isRecoverableKeyStoreEnabled(@NonNull android.content.Context);
- method @RequiresPermission(android.Manifest.permission.RECOVER_KEYSTORE) public void removeKey(@NonNull String) throws android.security.keystore.recovery.InternalRecoveryServiceException;
- method @RequiresPermission(android.Manifest.permission.RECOVER_KEYSTORE) public void setRecoverySecretTypes(@NonNull int[]) throws android.security.keystore.recovery.InternalRecoveryServiceException;
- method @RequiresPermission(android.Manifest.permission.RECOVER_KEYSTORE) public void setRecoveryStatus(@NonNull String, int) throws android.security.keystore.recovery.InternalRecoveryServiceException;
- method @RequiresPermission(android.Manifest.permission.RECOVER_KEYSTORE) public void setServerParams(@NonNull byte[]) throws android.security.keystore.recovery.InternalRecoveryServiceException;
- method @RequiresPermission(android.Manifest.permission.RECOVER_KEYSTORE) public void setSnapshotCreatedPendingIntent(@Nullable android.app.PendingIntent) throws android.security.keystore.recovery.InternalRecoveryServiceException;
- field public static final int RECOVERY_STATUS_PERMANENT_FAILURE = 3; // 0x3
- field public static final int RECOVERY_STATUS_SYNCED = 0; // 0x0
- field public static final int RECOVERY_STATUS_SYNC_IN_PROGRESS = 1; // 0x1
- }
-
- public class RecoverySession implements java.lang.AutoCloseable {
- method @RequiresPermission(android.Manifest.permission.RECOVER_KEYSTORE) public void close();
- method @NonNull @RequiresPermission(android.Manifest.permission.RECOVER_KEYSTORE) public java.util.Map<java.lang.String,java.security.Key> recoverKeyChainSnapshot(@NonNull byte[], @NonNull java.util.List<android.security.keystore.recovery.WrappedApplicationKey>) throws android.security.keystore.recovery.DecryptionFailedException, android.security.keystore.recovery.InternalRecoveryServiceException, android.security.keystore.recovery.SessionExpiredException;
- method @NonNull @RequiresPermission(android.Manifest.permission.RECOVER_KEYSTORE) public byte[] start(@NonNull String, @NonNull java.security.cert.CertPath, @NonNull byte[], @NonNull byte[], @NonNull java.util.List<android.security.keystore.recovery.KeyChainProtectionParams>) throws java.security.cert.CertificateException, android.security.keystore.recovery.InternalRecoveryServiceException;
- }
-
- public class SessionExpiredException extends java.security.GeneralSecurityException {
- ctor public SessionExpiredException(String);
- }
-
- public final class WrappedApplicationKey implements android.os.Parcelable {
- method public int describeContents();
- method @NonNull public String getAlias();
- method @NonNull public byte[] getEncryptedKeyMaterial();
- method @Nullable public byte[] getMetadata();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.security.keystore.recovery.WrappedApplicationKey> CREATOR;
- }
-
- public static class WrappedApplicationKey.Builder {
- ctor public WrappedApplicationKey.Builder();
- method @NonNull public android.security.keystore.recovery.WrappedApplicationKey build();
- method @NonNull public android.security.keystore.recovery.WrappedApplicationKey.Builder setAlias(@NonNull String);
- method @NonNull public android.security.keystore.recovery.WrappedApplicationKey.Builder setEncryptedKeyMaterial(@NonNull byte[]);
- method @NonNull public android.security.keystore.recovery.WrappedApplicationKey.Builder setMetadata(@Nullable byte[]);
- }
-
-}
-
-package android.service.appprediction {
-
- public abstract class AppPredictionService extends android.app.Service {
- ctor public AppPredictionService();
- method @MainThread public abstract void onAppTargetEvent(@NonNull android.app.prediction.AppPredictionSessionId, @NonNull android.app.prediction.AppTargetEvent);
- method @NonNull public final android.os.IBinder onBind(@NonNull android.content.Intent);
- method public void onCreatePredictionSession(@NonNull android.app.prediction.AppPredictionContext, @NonNull android.app.prediction.AppPredictionSessionId);
- method @MainThread public void onDestroyPredictionSession(@NonNull android.app.prediction.AppPredictionSessionId);
- method @MainThread public abstract void onLaunchLocationShown(@NonNull android.app.prediction.AppPredictionSessionId, @NonNull String, @NonNull java.util.List<android.app.prediction.AppTargetId>);
- method @MainThread public abstract void onRequestPredictionUpdate(@NonNull android.app.prediction.AppPredictionSessionId);
- method @MainThread public abstract void onSortAppTargets(@NonNull android.app.prediction.AppPredictionSessionId, @NonNull java.util.List<android.app.prediction.AppTarget>, @NonNull android.os.CancellationSignal, @NonNull java.util.function.Consumer<java.util.List<android.app.prediction.AppTarget>>);
- method @MainThread public void onStartPredictionUpdates();
- method @MainThread public void onStopPredictionUpdates();
- method public final void updatePredictions(@NonNull android.app.prediction.AppPredictionSessionId, @NonNull java.util.List<android.app.prediction.AppTarget>);
- }
-
-}
-
-package android.service.attention {
-
- public abstract class AttentionService extends android.app.Service {
- ctor public AttentionService();
- method @Nullable public final android.os.IBinder onBind(@NonNull android.content.Intent);
- method public abstract void onCancelAttentionCheck(@NonNull android.service.attention.AttentionService.AttentionCallback);
- method public abstract void onCheckAttention(@NonNull android.service.attention.AttentionService.AttentionCallback);
- field public static final int ATTENTION_FAILURE_CAMERA_PERMISSION_ABSENT = 6; // 0x6
- field public static final int ATTENTION_FAILURE_CANCELLED = 3; // 0x3
- field public static final int ATTENTION_FAILURE_PREEMPTED = 4; // 0x4
- field public static final int ATTENTION_FAILURE_TIMED_OUT = 5; // 0x5
- field public static final int ATTENTION_FAILURE_UNKNOWN = 2; // 0x2
- field public static final int ATTENTION_SUCCESS_ABSENT = 0; // 0x0
- field public static final int ATTENTION_SUCCESS_PRESENT = 1; // 0x1
- field public static final String SERVICE_INTERFACE = "android.service.attention.AttentionService";
- }
-
- public static final class AttentionService.AttentionCallback {
- method public void onFailure(int);
- method public void onSuccess(int, long);
- }
-
-}
-
-package android.service.attestation {
-
- public abstract class ImpressionAttestationService extends android.app.Service {
- ctor public ImpressionAttestationService();
- method @NonNull public final android.os.IBinder onBind(@NonNull android.content.Intent);
- method @Nullable public abstract android.service.attestation.ImpressionToken onGenerateImpressionToken(@NonNull android.hardware.HardwareBuffer, @NonNull android.graphics.Rect, @NonNull String);
- method public abstract int onVerifyImpressionToken(@NonNull android.service.attestation.ImpressionToken);
- field public static final int VERIFICATION_STATUS_APP_DECLARED = 2; // 0x2
- field public static final int VERIFICATION_STATUS_OS_VERIFIED = 1; // 0x1
- field public static final int VERIFICATION_STATUS_UNKNOWN = 0; // 0x0
- }
-
- public final class ImpressionToken implements android.os.Parcelable {
- ctor public ImpressionToken(long, @NonNull android.graphics.Rect, @NonNull String, @NonNull byte[], @NonNull byte[]);
- method public int describeContents();
- method @NonNull public android.graphics.Rect getBoundsInWindow();
- method @NonNull public String getHashingAlgorithm();
- method @NonNull public byte[] getHmac();
- method @NonNull public byte[] getImageHash();
- method public long getScreenshotTimeMillis();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.service.attestation.ImpressionToken> CREATOR;
- }
-
-}
-
-package android.service.autofill {
-
- public abstract class AutofillFieldClassificationService extends android.app.Service {
- ctor public AutofillFieldClassificationService();
- method public android.os.IBinder onBind(android.content.Intent);
- method @Nullable public float[][] onCalculateScores(@NonNull java.util.List<android.view.autofill.AutofillValue>, @NonNull java.util.List<java.lang.String>, @NonNull java.util.List<java.lang.String>, @Nullable String, @Nullable android.os.Bundle, @Nullable java.util.Map, @Nullable java.util.Map);
- method @Deprecated @Nullable public float[][] onGetScores(@Nullable String, @Nullable android.os.Bundle, @NonNull java.util.List<android.view.autofill.AutofillValue>, @NonNull java.util.List<java.lang.String>);
- field public static final String REQUIRED_ALGORITHM_CREDIT_CARD = "CREDIT_CARD";
- field public static final String REQUIRED_ALGORITHM_EDIT_DISTANCE = "EDIT_DISTANCE";
- field public static final String REQUIRED_ALGORITHM_EXACT_MATCH = "EXACT_MATCH";
- field public static final String SERVICE_INTERFACE = "android.service.autofill.AutofillFieldClassificationService";
- field public static final String SERVICE_META_DATA_KEY_AVAILABLE_ALGORITHMS = "android.autofill.field_classification.available_algorithms";
- field public static final String SERVICE_META_DATA_KEY_DEFAULT_ALGORITHM = "android.autofill.field_classification.default_algorithm";
- }
-
- public static final class Dataset.Builder {
- ctor public Dataset.Builder(@NonNull android.service.autofill.InlinePresentation);
- method @NonNull public android.service.autofill.Dataset.Builder setContent(@NonNull android.view.autofill.AutofillId, @Nullable android.content.ClipData);
- method @NonNull public android.service.autofill.Dataset.Builder setFieldInlinePresentation(@NonNull android.view.autofill.AutofillId, @Nullable android.view.autofill.AutofillValue, @Nullable java.util.regex.Pattern, @NonNull android.service.autofill.InlinePresentation);
- }
-
- public abstract class InlineSuggestionRenderService extends android.app.Service {
- ctor public InlineSuggestionRenderService();
- method @Nullable public final android.os.IBinder onBind(@NonNull android.content.Intent);
- method @NonNull public android.os.Bundle onGetInlineSuggestionsRendererInfo();
- method @Nullable public android.view.View onRenderSuggestion(@NonNull android.service.autofill.InlinePresentation, int, int);
- method public final void startIntentSender(@NonNull android.content.IntentSender);
- field public static final String SERVICE_INTERFACE = "android.service.autofill.InlineSuggestionRenderService";
- }
-
-}
-
-package android.service.autofill.augmented {
-
- public abstract class AugmentedAutofillService extends android.app.Service {
- ctor public AugmentedAutofillService();
- method protected final void dump(java.io.FileDescriptor, java.io.PrintWriter, String[]);
- method protected void dump(@NonNull java.io.PrintWriter, @NonNull String[]);
- method @Nullable public final android.service.autofill.FillEventHistory getFillEventHistory();
- method public void onConnected();
- method public void onDisconnected();
- method public void onFillRequest(@NonNull android.service.autofill.augmented.FillRequest, @NonNull android.os.CancellationSignal, @NonNull android.service.autofill.augmented.FillController, @NonNull android.service.autofill.augmented.FillCallback);
- method public final boolean requestAutofill(@NonNull android.content.ComponentName, @NonNull android.view.autofill.AutofillId);
- field public static final String SERVICE_INTERFACE = "android.service.autofill.augmented.AugmentedAutofillService";
- }
-
- public final class FillCallback {
- method public void onSuccess(@Nullable android.service.autofill.augmented.FillResponse);
- }
-
- public final class FillController {
- method public void autofill(@NonNull java.util.List<android.util.Pair<android.view.autofill.AutofillId,android.view.autofill.AutofillValue>>);
- }
-
- public final class FillRequest {
- method @NonNull public android.content.ComponentName getActivityComponent();
- method @NonNull public android.view.autofill.AutofillId getFocusedId();
- method @NonNull public android.view.autofill.AutofillValue getFocusedValue();
- method @Nullable public android.view.inputmethod.InlineSuggestionsRequest getInlineSuggestionsRequest();
- method @Nullable public android.service.autofill.augmented.PresentationParams getPresentationParams();
- method public int getTaskId();
- }
-
- public final class FillResponse {
- }
-
- public static final class FillResponse.Builder {
- ctor public FillResponse.Builder();
- method @NonNull public android.service.autofill.augmented.FillResponse build();
- method @NonNull public android.service.autofill.augmented.FillResponse.Builder setClientState(@NonNull android.os.Bundle);
- method @NonNull public android.service.autofill.augmented.FillResponse.Builder setFillWindow(@NonNull android.service.autofill.augmented.FillWindow);
- method @NonNull public android.service.autofill.augmented.FillResponse.Builder setInlineSuggestions(@NonNull java.util.List<android.service.autofill.Dataset>);
- }
-
- public final class FillWindow implements java.lang.AutoCloseable {
- ctor public FillWindow();
- method public void destroy();
- method public boolean update(@NonNull android.service.autofill.augmented.PresentationParams.Area, @NonNull android.view.View, long);
- }
-
- public abstract class PresentationParams {
- method @Nullable public android.service.autofill.augmented.PresentationParams.Area getSuggestionArea();
- }
-
- public abstract static class PresentationParams.Area {
- method @NonNull public android.graphics.Rect getBounds();
- }
-
-}
-
-package android.service.carrier {
-
- public abstract class ApnService extends android.app.Service {
- ctor public ApnService();
- method @NonNull public android.os.IBinder onBind(@Nullable android.content.Intent);
- method @NonNull @WorkerThread public abstract java.util.List<android.content.ContentValues> onRestoreApns(int);
- }
-
-}
-
-package android.service.contentcapture {
-
- public final class ActivityEvent implements android.os.Parcelable {
- method public int describeContents();
- method @NonNull public android.content.ComponentName getComponentName();
- method public int getEventType();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.service.contentcapture.ActivityEvent> CREATOR;
- field public static final int TYPE_ACTIVITY_DESTROYED = 24; // 0x18
- field public static final int TYPE_ACTIVITY_PAUSED = 2; // 0x2
- field public static final int TYPE_ACTIVITY_RESUMED = 1; // 0x1
- field public static final int TYPE_ACTIVITY_STOPPED = 23; // 0x17
- }
-
- public abstract class ContentCaptureService extends android.app.Service {
- ctor public ContentCaptureService();
- method public final void disableSelf();
- method public void onActivityEvent(@NonNull android.service.contentcapture.ActivityEvent);
- method public void onActivitySnapshot(@NonNull android.view.contentcapture.ContentCaptureSessionId, @NonNull android.service.contentcapture.SnapshotData);
- method public void onConnected();
- method public void onContentCaptureEvent(@NonNull android.view.contentcapture.ContentCaptureSessionId, @NonNull android.view.contentcapture.ContentCaptureEvent);
- method public void onCreateContentCaptureSession(@NonNull android.view.contentcapture.ContentCaptureContext, @NonNull android.view.contentcapture.ContentCaptureSessionId);
- method public void onDataRemovalRequest(@NonNull android.view.contentcapture.DataRemovalRequest);
- method public void onDataShareRequest(@NonNull android.view.contentcapture.DataShareRequest, @NonNull android.service.contentcapture.DataShareCallback);
- method public void onDestroyContentCaptureSession(@NonNull android.view.contentcapture.ContentCaptureSessionId);
- method public void onDisconnected();
- method public final void setContentCaptureConditions(@NonNull String, @Nullable java.util.Set<android.view.contentcapture.ContentCaptureCondition>);
- method public final void setContentCaptureWhitelist(@Nullable java.util.Set<java.lang.String>, @Nullable java.util.Set<android.content.ComponentName>);
- field public static final String SERVICE_INTERFACE = "android.service.contentcapture.ContentCaptureService";
- field public static final String SERVICE_META_DATA = "android.content_capture";
- }
-
- public interface DataShareCallback {
- method public void onAccept(@NonNull java.util.concurrent.Executor, @NonNull android.service.contentcapture.DataShareReadAdapter);
- method public void onReject();
- }
-
- public interface DataShareReadAdapter {
- method public void onError(int);
- method public void onStart(@NonNull android.os.ParcelFileDescriptor);
- }
-
- public final class SnapshotData implements android.os.Parcelable {
- method public int describeContents();
- method @Nullable public android.app.assist.AssistContent getAssistContent();
- method @NonNull public android.os.Bundle getAssistData();
- method @NonNull public android.app.assist.AssistStructure getAssistStructure();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.service.contentcapture.SnapshotData> CREATOR;
- }
-
-}
-
-package android.service.contentsuggestions {
-
- public abstract class ContentSuggestionsService extends android.app.Service {
- ctor public ContentSuggestionsService();
- method public abstract void onClassifyContentSelections(@NonNull android.app.contentsuggestions.ClassificationsRequest, @NonNull android.app.contentsuggestions.ContentSuggestionsManager.ClassificationsCallback);
- method public abstract void onNotifyInteraction(@NonNull String, @NonNull android.os.Bundle);
- method public abstract void onProcessContextImage(int, @Nullable android.graphics.Bitmap, @NonNull android.os.Bundle);
- method public abstract void onSuggestContentSelections(@NonNull android.app.contentsuggestions.SelectionsRequest, @NonNull android.app.contentsuggestions.ContentSuggestionsManager.SelectionsCallback);
- field public static final String SERVICE_INTERFACE = "android.service.contentsuggestions.ContentSuggestionsService";
- }
-
-}
-
-package android.service.dataloader {
-
- public abstract class DataLoaderService extends android.app.Service {
- ctor public DataLoaderService();
- method @Nullable public android.service.dataloader.DataLoaderService.DataLoader onCreateDataLoader(@NonNull android.content.pm.DataLoaderParams);
- }
-
- public static interface DataLoaderService.DataLoader {
- method public boolean onCreate(@NonNull android.content.pm.DataLoaderParams, @NonNull android.service.dataloader.DataLoaderService.FileSystemConnector);
- method public boolean onPrepareImage(@NonNull java.util.Collection<android.content.pm.InstallationFile>, @NonNull java.util.Collection<java.lang.String>);
- }
-
- public static final class DataLoaderService.FileSystemConnector {
- method @RequiresPermission(android.Manifest.permission.INSTALL_PACKAGES) public void writeData(@NonNull String, long, long, @NonNull android.os.ParcelFileDescriptor) throws java.io.IOException;
- }
-
-}
-
-package android.service.euicc {
-
- public final class DownloadSubscriptionResult implements android.os.Parcelable {
- ctor public DownloadSubscriptionResult(int, int, int);
- method public int describeContents();
- method public int getCardId();
- method public int getResolvableErrors();
- method public int getResult();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.service.euicc.DownloadSubscriptionResult> CREATOR;
- }
-
- public final class EuiccProfileInfo implements android.os.Parcelable {
- method public int describeContents();
- method public android.service.carrier.CarrierIdentifier getCarrierIdentifier();
- method public String getIccid();
- method @Nullable public String getNickname();
- method @android.service.euicc.EuiccProfileInfo.PolicyRule public int getPolicyRules();
- method @android.service.euicc.EuiccProfileInfo.ProfileClass public int getProfileClass();
- method public String getProfileName();
- method public String getServiceProviderName();
- method @android.service.euicc.EuiccProfileInfo.ProfileState public int getState();
- method @Nullable public java.util.List<android.telephony.UiccAccessRule> getUiccAccessRules();
- method public boolean hasPolicyRule(@android.service.euicc.EuiccProfileInfo.PolicyRule int);
- method public boolean hasPolicyRules();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.service.euicc.EuiccProfileInfo> CREATOR;
- field public static final int POLICY_RULE_DELETE_AFTER_DISABLING = 4; // 0x4
- field public static final int POLICY_RULE_DO_NOT_DELETE = 2; // 0x2
- field public static final int POLICY_RULE_DO_NOT_DISABLE = 1; // 0x1
- field public static final int PROFILE_CLASS_OPERATIONAL = 2; // 0x2
- field public static final int PROFILE_CLASS_PROVISIONING = 1; // 0x1
- field public static final int PROFILE_CLASS_TESTING = 0; // 0x0
- field public static final int PROFILE_STATE_DISABLED = 0; // 0x0
- field public static final int PROFILE_STATE_ENABLED = 1; // 0x1
- }
-
- public static final class EuiccProfileInfo.Builder {
- ctor public EuiccProfileInfo.Builder(String);
- ctor public EuiccProfileInfo.Builder(android.service.euicc.EuiccProfileInfo);
- method public android.service.euicc.EuiccProfileInfo build();
- method public android.service.euicc.EuiccProfileInfo.Builder setCarrierIdentifier(android.service.carrier.CarrierIdentifier);
- method public android.service.euicc.EuiccProfileInfo.Builder setIccid(String);
- method public android.service.euicc.EuiccProfileInfo.Builder setNickname(String);
- method public android.service.euicc.EuiccProfileInfo.Builder setPolicyRules(@android.service.euicc.EuiccProfileInfo.PolicyRule int);
- method public android.service.euicc.EuiccProfileInfo.Builder setProfileClass(@android.service.euicc.EuiccProfileInfo.ProfileClass int);
- method public android.service.euicc.EuiccProfileInfo.Builder setProfileName(String);
- method public android.service.euicc.EuiccProfileInfo.Builder setServiceProviderName(String);
- method public android.service.euicc.EuiccProfileInfo.Builder setState(@android.service.euicc.EuiccProfileInfo.ProfileState int);
- method public android.service.euicc.EuiccProfileInfo.Builder setUiccAccessRule(@Nullable java.util.List<android.telephony.UiccAccessRule>);
- }
-
- @IntDef(flag=true, prefix={"POLICY_RULE_"}, value={android.service.euicc.EuiccProfileInfo.POLICY_RULE_DO_NOT_DISABLE, android.service.euicc.EuiccProfileInfo.POLICY_RULE_DO_NOT_DELETE, android.service.euicc.EuiccProfileInfo.POLICY_RULE_DELETE_AFTER_DISABLING}) @java.lang.annotation.Retention(java.lang.annotation.RetentionPolicy.SOURCE) public static @interface EuiccProfileInfo.PolicyRule {
- }
-
- @IntDef(prefix={"PROFILE_CLASS_"}, value={android.service.euicc.EuiccProfileInfo.PROFILE_CLASS_TESTING, android.service.euicc.EuiccProfileInfo.PROFILE_CLASS_PROVISIONING, android.service.euicc.EuiccProfileInfo.PROFILE_CLASS_OPERATIONAL, 0xffffffff}) @java.lang.annotation.Retention(java.lang.annotation.RetentionPolicy.SOURCE) public static @interface EuiccProfileInfo.ProfileClass {
- }
-
- @IntDef(prefix={"PROFILE_STATE_"}, value={android.service.euicc.EuiccProfileInfo.PROFILE_STATE_DISABLED, android.service.euicc.EuiccProfileInfo.PROFILE_STATE_ENABLED, 0xffffffff}) @java.lang.annotation.Retention(java.lang.annotation.RetentionPolicy.SOURCE) public static @interface EuiccProfileInfo.ProfileState {
- }
-
- public abstract class EuiccService extends android.app.Service {
- ctor public EuiccService();
- method public void dump(@NonNull java.io.PrintWriter);
- method public int encodeSmdxSubjectAndReasonCode(@Nullable String, @Nullable String);
- method @CallSuper public android.os.IBinder onBind(android.content.Intent);
- method public abstract int onDeleteSubscription(int, String);
- method public android.service.euicc.DownloadSubscriptionResult onDownloadSubscription(int, @NonNull android.telephony.euicc.DownloadableSubscription, boolean, boolean, @Nullable android.os.Bundle);
- method @Deprecated public int onDownloadSubscription(int, @NonNull android.telephony.euicc.DownloadableSubscription, boolean, boolean);
- method @Deprecated public abstract int onEraseSubscriptions(int);
- method public int onEraseSubscriptions(int, @android.telephony.euicc.EuiccCardManager.ResetOption int);
- method public abstract android.service.euicc.GetDefaultDownloadableSubscriptionListResult onGetDefaultDownloadableSubscriptionList(int, boolean);
- method public abstract android.service.euicc.GetDownloadableSubscriptionMetadataResult onGetDownloadableSubscriptionMetadata(int, android.telephony.euicc.DownloadableSubscription, boolean);
- method public abstract String onGetEid(int);
- method @NonNull public abstract android.telephony.euicc.EuiccInfo onGetEuiccInfo(int);
- method @NonNull public abstract android.service.euicc.GetEuiccProfileInfoListResult onGetEuiccProfileInfoList(int);
- method @android.telephony.euicc.EuiccManager.OtaStatus public abstract int onGetOtaStatus(int);
- method public abstract int onRetainSubscriptionsForFactoryReset(int);
- method public abstract void onStartOtaIfNecessary(int, android.service.euicc.EuiccService.OtaStatusChangedCallback);
- method public abstract int onSwitchToSubscription(int, @Nullable String, boolean);
- method public abstract int onUpdateSubscriptionNickname(int, String, String);
- field public static final String ACTION_BIND_CARRIER_PROVISIONING_SERVICE = "android.service.euicc.action.BIND_CARRIER_PROVISIONING_SERVICE";
- field public static final String ACTION_DELETE_SUBSCRIPTION_PRIVILEGED = "android.service.euicc.action.DELETE_SUBSCRIPTION_PRIVILEGED";
- field public static final String ACTION_MANAGE_EMBEDDED_SUBSCRIPTIONS = "android.service.euicc.action.MANAGE_EMBEDDED_SUBSCRIPTIONS";
- field public static final String ACTION_PROVISION_EMBEDDED_SUBSCRIPTION = "android.service.euicc.action.PROVISION_EMBEDDED_SUBSCRIPTION";
- field public static final String ACTION_RENAME_SUBSCRIPTION_PRIVILEGED = "android.service.euicc.action.RENAME_SUBSCRIPTION_PRIVILEGED";
- field @Deprecated public static final String ACTION_RESOLVE_CONFIRMATION_CODE = "android.service.euicc.action.RESOLVE_CONFIRMATION_CODE";
- field public static final String ACTION_RESOLVE_DEACTIVATE_SIM = "android.service.euicc.action.RESOLVE_DEACTIVATE_SIM";
- field public static final String ACTION_RESOLVE_NO_PRIVILEGES = "android.service.euicc.action.RESOLVE_NO_PRIVILEGES";
- field public static final String ACTION_RESOLVE_RESOLVABLE_ERRORS = "android.service.euicc.action.RESOLVE_RESOLVABLE_ERRORS";
- field public static final String ACTION_START_CARRIER_ACTIVATION = "android.service.euicc.action.START_CARRIER_ACTIVATION";
- field public static final String ACTION_START_EUICC_ACTIVATION = "android.service.euicc.action.START_EUICC_ACTIVATION";
- field public static final String ACTION_TOGGLE_SUBSCRIPTION_PRIVILEGED = "android.service.euicc.action.TOGGLE_SUBSCRIPTION_PRIVILEGED";
- field public static final String CATEGORY_EUICC_UI = "android.service.euicc.category.EUICC_UI";
- field public static final String EUICC_SERVICE_INTERFACE = "android.service.euicc.EuiccService";
- field public static final String EXTRA_RESOLUTION_ALLOW_POLICY_RULES = "android.service.euicc.extra.RESOLUTION_ALLOW_POLICY_RULES";
- field public static final String EXTRA_RESOLUTION_CALLING_PACKAGE = "android.service.euicc.extra.RESOLUTION_CALLING_PACKAGE";
- field public static final String EXTRA_RESOLUTION_CARD_ID = "android.service.euicc.extra.RESOLUTION_CARD_ID";
- field public static final String EXTRA_RESOLUTION_CONFIRMATION_CODE = "android.service.euicc.extra.RESOLUTION_CONFIRMATION_CODE";
- field public static final String EXTRA_RESOLUTION_CONFIRMATION_CODE_RETRIED = "android.service.euicc.extra.RESOLUTION_CONFIRMATION_CODE_RETRIED";
- field public static final String EXTRA_RESOLUTION_CONSENT = "android.service.euicc.extra.RESOLUTION_CONSENT";
- field public static final String EXTRA_RESOLVABLE_ERRORS = "android.service.euicc.extra.RESOLVABLE_ERRORS";
- field public static final int RESOLVABLE_ERROR_CONFIRMATION_CODE = 1; // 0x1
- field public static final int RESOLVABLE_ERROR_POLICY_RULES = 2; // 0x2
- field public static final int RESULT_FIRST_USER = 1; // 0x1
- field public static final int RESULT_MUST_DEACTIVATE_SIM = -1; // 0xffffffff
- field @Deprecated public static final int RESULT_NEED_CONFIRMATION_CODE = -2; // 0xfffffffe
- field public static final int RESULT_OK = 0; // 0x0
- field public static final int RESULT_RESOLVABLE_ERRORS = -2; // 0xfffffffe
- }
-
- public abstract static class EuiccService.OtaStatusChangedCallback {
- ctor public EuiccService.OtaStatusChangedCallback();
- method public abstract void onOtaStatusChanged(int);
- }
-
- public final class GetDefaultDownloadableSubscriptionListResult implements android.os.Parcelable {
- ctor public GetDefaultDownloadableSubscriptionListResult(int, @Nullable android.telephony.euicc.DownloadableSubscription[]);
- method public int describeContents();
- method @Nullable public java.util.List<android.telephony.euicc.DownloadableSubscription> getDownloadableSubscriptions();
- method public int getResult();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.service.euicc.GetDefaultDownloadableSubscriptionListResult> CREATOR;
- }
-
- public final class GetDownloadableSubscriptionMetadataResult implements android.os.Parcelable {
- ctor public GetDownloadableSubscriptionMetadataResult(int, @Nullable android.telephony.euicc.DownloadableSubscription);
- method public int describeContents();
- method @Nullable public android.telephony.euicc.DownloadableSubscription getDownloadableSubscription();
- method public int getResult();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.service.euicc.GetDownloadableSubscriptionMetadataResult> CREATOR;
- }
-
- public final class GetEuiccProfileInfoListResult implements android.os.Parcelable {
- ctor public GetEuiccProfileInfoListResult(int, @Nullable android.service.euicc.EuiccProfileInfo[], boolean);
- method public int describeContents();
- method public boolean getIsRemovable();
- method @Nullable public java.util.List<android.service.euicc.EuiccProfileInfo> getProfiles();
- method public int getResult();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.service.euicc.GetEuiccProfileInfoListResult> CREATOR;
- }
-
-}
-
-package android.service.notification {
-
- public final class Adjustment implements android.os.Parcelable {
- ctor public Adjustment(String, String, android.os.Bundle, CharSequence, int);
- ctor public Adjustment(@NonNull String, @NonNull String, @NonNull android.os.Bundle, @NonNull CharSequence, @NonNull android.os.UserHandle);
- ctor protected Adjustment(android.os.Parcel);
- method public int describeContents();
- method @NonNull public CharSequence getExplanation();
- method @NonNull public String getKey();
- method @NonNull public String getPackage();
- method @NonNull public android.os.Bundle getSignals();
- method public int getUser();
- method @NonNull public android.os.UserHandle getUserHandle();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.service.notification.Adjustment> CREATOR;
- field public static final String KEY_CONTEXTUAL_ACTIONS = "key_contextual_actions";
- field public static final String KEY_IMPORTANCE = "key_importance";
- field public static final String KEY_NOT_CONVERSATION = "key_not_conversation";
- field public static final String KEY_PEOPLE = "key_people";
- field public static final String KEY_RANKING_SCORE = "key_ranking_score";
- field public static final String KEY_SNOOZE_CRITERIA = "key_snooze_criteria";
- field public static final String KEY_TEXT_REPLIES = "key_text_replies";
- field public static final String KEY_USER_SENTIMENT = "key_user_sentiment";
- }
-
- public abstract class NotificationAssistantService extends android.service.notification.NotificationListenerService {
- ctor public NotificationAssistantService();
- method public final void adjustNotification(@NonNull android.service.notification.Adjustment);
- method public final void adjustNotifications(@NonNull java.util.List<android.service.notification.Adjustment>);
- method public void onActionInvoked(@NonNull String, @NonNull android.app.Notification.Action, int);
- method public void onAllowedAdjustmentsChanged();
- method @NonNull public final android.os.IBinder onBind(@Nullable android.content.Intent);
- method public void onNotificationDirectReplied(@NonNull String);
- method @Nullable public abstract android.service.notification.Adjustment onNotificationEnqueued(@NonNull android.service.notification.StatusBarNotification);
- method @Nullable public android.service.notification.Adjustment onNotificationEnqueued(@NonNull android.service.notification.StatusBarNotification, @NonNull android.app.NotificationChannel);
- method public void onNotificationExpansionChanged(@NonNull String, boolean, boolean);
- method public abstract void onNotificationSnoozedUntilContext(@NonNull android.service.notification.StatusBarNotification, @NonNull String);
- method public void onNotificationVisibilityChanged(@NonNull String, boolean);
- method public void onNotificationsSeen(@NonNull java.util.List<java.lang.String>);
- method public void onPanelHidden();
- method public void onPanelRevealed(int);
- method public void onSuggestedReplySent(@NonNull String, @NonNull CharSequence, int);
- method public final void unsnoozeNotification(@NonNull String);
- field public static final String SERVICE_INTERFACE = "android.service.notification.NotificationAssistantService";
- field public static final int SOURCE_FROM_APP = 0; // 0x0
- field public static final int SOURCE_FROM_ASSISTANT = 1; // 0x1
- }
-
- public abstract class NotificationListenerService extends android.app.Service {
- method public void onNotificationRemoved(@NonNull android.service.notification.StatusBarNotification, @NonNull android.service.notification.NotificationListenerService.RankingMap, @NonNull android.service.notification.NotificationStats, int);
- }
-
- public final class NotificationStats implements android.os.Parcelable {
- ctor public NotificationStats();
- ctor protected NotificationStats(android.os.Parcel);
- method public int describeContents();
- method public int getDismissalSentiment();
- method public int getDismissalSurface();
- method public boolean hasDirectReplied();
- method public boolean hasExpanded();
- method public boolean hasInteracted();
- method public boolean hasSeen();
- method public boolean hasSnoozed();
- method public boolean hasViewedSettings();
- method public void setDirectReplied();
- method public void setDismissalSentiment(int);
- method public void setDismissalSurface(int);
- method public void setExpanded();
- method public void setSeen();
- method public void setSnoozed();
- method public void setViewedSettings();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.service.notification.NotificationStats> CREATOR;
- field public static final int DISMISSAL_AOD = 2; // 0x2
- field public static final int DISMISSAL_NOT_DISMISSED = -1; // 0xffffffff
- field public static final int DISMISSAL_OTHER = 0; // 0x0
- field public static final int DISMISSAL_PEEK = 1; // 0x1
- field public static final int DISMISSAL_SHADE = 3; // 0x3
- field public static final int DISMISS_SENTIMENT_NEGATIVE = 0; // 0x0
- field public static final int DISMISS_SENTIMENT_NEUTRAL = 1; // 0x1
- field public static final int DISMISS_SENTIMENT_POSITIVE = 2; // 0x2
- field public static final int DISMISS_SENTIMENT_UNKNOWN = -1000; // 0xfffffc18
- }
-
- public final class SnoozeCriterion implements android.os.Parcelable {
- ctor public SnoozeCriterion(String, CharSequence, CharSequence);
- ctor protected SnoozeCriterion(android.os.Parcel);
- method public int describeContents();
- method public CharSequence getConfirmation();
- method public CharSequence getExplanation();
- method public String getId();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.service.notification.SnoozeCriterion> CREATOR;
- }
-
-}
-
-package android.service.oemlock {
-
- public class OemLockManager {
- method @Nullable @RequiresPermission(android.Manifest.permission.MANAGE_CARRIER_OEM_UNLOCK_STATE) public String getLockName();
- method @RequiresPermission(android.Manifest.permission.MANAGE_CARRIER_OEM_UNLOCK_STATE) public boolean isOemUnlockAllowedByCarrier();
- method @RequiresPermission(android.Manifest.permission.MANAGE_USER_OEM_UNLOCK_STATE) public boolean isOemUnlockAllowedByUser();
- method @RequiresPermission(android.Manifest.permission.MANAGE_CARRIER_OEM_UNLOCK_STATE) public void setOemUnlockAllowedByCarrier(boolean, @Nullable byte[]);
- method @RequiresPermission(android.Manifest.permission.MANAGE_USER_OEM_UNLOCK_STATE) public void setOemUnlockAllowedByUser(boolean);
- }
-
-}
-
-package android.service.persistentdata {
-
- public class PersistentDataBlockManager {
- method @RequiresPermission("android.permission.ACCESS_PDB_STATE") public int getDataBlockSize();
- method @android.service.persistentdata.PersistentDataBlockManager.FlashLockState @RequiresPermission(anyOf={android.Manifest.permission.READ_OEM_UNLOCK_STATE, "android.permission.OEM_UNLOCK_STATE"}) public int getFlashLockState();
- method public long getMaximumDataBlockSize();
- method @Deprecated @RequiresPermission(anyOf={android.Manifest.permission.READ_OEM_UNLOCK_STATE, "android.permission.OEM_UNLOCK_STATE"}) public boolean getOemUnlockEnabled();
- method public byte[] read();
- method @Deprecated @RequiresPermission("android.permission.OEM_UNLOCK_STATE") public void setOemUnlockEnabled(boolean);
- method @RequiresPermission("android.permission.OEM_UNLOCK_STATE") public void wipe();
- method public int write(byte[]);
- field public static final int FLASH_LOCK_LOCKED = 1; // 0x1
- field public static final int FLASH_LOCK_UNKNOWN = -1; // 0xffffffff
- field public static final int FLASH_LOCK_UNLOCKED = 0; // 0x0
- }
-
- @IntDef(prefix={"FLASH_LOCK_"}, value={android.service.persistentdata.PersistentDataBlockManager.FLASH_LOCK_UNKNOWN, android.service.persistentdata.PersistentDataBlockManager.FLASH_LOCK_LOCKED, android.service.persistentdata.PersistentDataBlockManager.FLASH_LOCK_UNLOCKED}) @java.lang.annotation.Retention(java.lang.annotation.RetentionPolicy.SOURCE) public static @interface PersistentDataBlockManager.FlashLockState {
- }
-
-}
-
-package android.service.quicksettings {
-
- public class TileService extends android.app.Service {
- method public final void setStatusIcon(android.graphics.drawable.Icon, String);
- }
-
-}
-
-package android.service.resolver {
-
- public abstract class ResolverRankerService extends android.app.Service {
- ctor public ResolverRankerService();
- method public android.os.IBinder onBind(android.content.Intent);
- method public void onPredictSharingProbabilities(java.util.List<android.service.resolver.ResolverTarget>);
- method public void onTrainRankingModel(java.util.List<android.service.resolver.ResolverTarget>, int);
- field public static final String BIND_PERMISSION = "android.permission.BIND_RESOLVER_RANKER_SERVICE";
- field public static final String HOLD_PERMISSION = "android.permission.PROVIDE_RESOLVER_RANKER_SERVICE";
- field public static final String SERVICE_INTERFACE = "android.service.resolver.ResolverRankerService";
- }
-
- public final class ResolverTarget implements android.os.Parcelable {
- ctor public ResolverTarget();
- method public int describeContents();
- method public float getChooserScore();
- method public float getLaunchScore();
- method public float getRecencyScore();
- method public float getSelectProbability();
- method public float getTimeSpentScore();
- method public void setChooserScore(float);
- method public void setLaunchScore(float);
- method public void setRecencyScore(float);
- method public void setSelectProbability(float);
- method public void setTimeSpentScore(float);
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.service.resolver.ResolverTarget> CREATOR;
- }
-
-}
-
-package android.service.settings.suggestions {
-
- public final class Suggestion implements android.os.Parcelable {
- method public int describeContents();
- method public int getFlags();
- method public android.graphics.drawable.Icon getIcon();
- method public String getId();
- method public android.app.PendingIntent getPendingIntent();
- method public CharSequence getSummary();
- method public CharSequence getTitle();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.service.settings.suggestions.Suggestion> CREATOR;
- field public static final int FLAG_HAS_BUTTON = 1; // 0x1
- }
-
- public static class Suggestion.Builder {
- ctor public Suggestion.Builder(String);
- method public android.service.settings.suggestions.Suggestion build();
- method public android.service.settings.suggestions.Suggestion.Builder setFlags(int);
- method public android.service.settings.suggestions.Suggestion.Builder setIcon(android.graphics.drawable.Icon);
- method public android.service.settings.suggestions.Suggestion.Builder setPendingIntent(android.app.PendingIntent);
- method public android.service.settings.suggestions.Suggestion.Builder setSummary(CharSequence);
- method public android.service.settings.suggestions.Suggestion.Builder setTitle(CharSequence);
- }
-
- public abstract class SuggestionService extends android.app.Service {
- ctor public SuggestionService();
- method public android.os.IBinder onBind(android.content.Intent);
- method public abstract java.util.List<android.service.settings.suggestions.Suggestion> onGetSuggestions();
- method public abstract void onSuggestionDismissed(android.service.settings.suggestions.Suggestion);
- method public abstract void onSuggestionLaunched(android.service.settings.suggestions.Suggestion);
- }
-
-}
-
-package android.service.storage {
-
- public abstract class ExternalStorageService extends android.app.Service {
- ctor public ExternalStorageService();
- method @NonNull public final android.os.IBinder onBind(@NonNull android.content.Intent);
- method public abstract void onEndSession(@NonNull String) throws java.io.IOException;
- method public abstract void onStartSession(@NonNull String, int, @NonNull android.os.ParcelFileDescriptor, @NonNull java.io.File, @NonNull java.io.File) throws java.io.IOException;
- method public abstract void onVolumeStateChanged(@NonNull android.os.storage.StorageVolume) throws java.io.IOException;
- field public static final int FLAG_SESSION_ATTRIBUTE_INDEXABLE = 2; // 0x2
- field public static final int FLAG_SESSION_TYPE_FUSE = 1; // 0x1
- field public static final String SERVICE_INTERFACE = "android.service.storage.ExternalStorageService";
- }
-
-}
-
-package android.service.textclassifier {
-
- public abstract class TextClassifierService extends android.app.Service {
- ctor public TextClassifierService();
- method @NonNull public static android.view.textclassifier.TextClassifier getDefaultTextClassifierImplementation(@NonNull android.content.Context);
- method @Deprecated public final android.view.textclassifier.TextClassifier getLocalTextClassifier();
- method @Nullable public final android.os.IBinder onBind(@NonNull android.content.Intent);
- method @MainThread public abstract void onClassifyText(@Nullable android.view.textclassifier.TextClassificationSessionId, @NonNull android.view.textclassifier.TextClassification.Request, @NonNull android.os.CancellationSignal, @NonNull android.service.textclassifier.TextClassifierService.Callback<android.view.textclassifier.TextClassification>);
- method public void onConnected();
- method @MainThread public void onCreateTextClassificationSession(@NonNull android.view.textclassifier.TextClassificationContext, @NonNull android.view.textclassifier.TextClassificationSessionId);
- method @MainThread public void onDestroyTextClassificationSession(@NonNull android.view.textclassifier.TextClassificationSessionId);
- method @MainThread public void onDetectLanguage(@Nullable android.view.textclassifier.TextClassificationSessionId, @NonNull android.view.textclassifier.TextLanguage.Request, @NonNull android.os.CancellationSignal, @NonNull android.service.textclassifier.TextClassifierService.Callback<android.view.textclassifier.TextLanguage>);
- method public void onDisconnected();
- method @MainThread public abstract void onGenerateLinks(@Nullable android.view.textclassifier.TextClassificationSessionId, @NonNull android.view.textclassifier.TextLinks.Request, @NonNull android.os.CancellationSignal, @NonNull android.service.textclassifier.TextClassifierService.Callback<android.view.textclassifier.TextLinks>);
- method @Deprecated @MainThread public void onSelectionEvent(@Nullable android.view.textclassifier.TextClassificationSessionId, @NonNull android.view.textclassifier.SelectionEvent);
- method @MainThread public void onSuggestConversationActions(@Nullable android.view.textclassifier.TextClassificationSessionId, @NonNull android.view.textclassifier.ConversationActions.Request, @NonNull android.os.CancellationSignal, @NonNull android.service.textclassifier.TextClassifierService.Callback<android.view.textclassifier.ConversationActions>);
- method @MainThread public abstract void onSuggestSelection(@Nullable android.view.textclassifier.TextClassificationSessionId, @NonNull android.view.textclassifier.TextSelection.Request, @NonNull android.os.CancellationSignal, @NonNull android.service.textclassifier.TextClassifierService.Callback<android.view.textclassifier.TextSelection>);
- method @MainThread public void onTextClassifierEvent(@Nullable android.view.textclassifier.TextClassificationSessionId, @NonNull android.view.textclassifier.TextClassifierEvent);
- field public static final String SERVICE_INTERFACE = "android.service.textclassifier.TextClassifierService";
- }
-
- public static interface TextClassifierService.Callback<T> {
- method public void onFailure(@NonNull CharSequence);
- method public void onSuccess(T);
- }
-
-}
-
-package android.service.trust {
-
- public class TrustAgentService extends android.app.Service {
- ctor public TrustAgentService();
- method public final void addEscrowToken(byte[], android.os.UserHandle);
- method @Deprecated public final void grantTrust(CharSequence, long, boolean);
- method public final void grantTrust(CharSequence, long, int);
- method public final void isEscrowTokenActive(long, android.os.UserHandle);
- method public final android.os.IBinder onBind(android.content.Intent);
- method public boolean onConfigure(java.util.List<android.os.PersistableBundle>);
- method public void onDeviceLocked();
- method public void onDeviceUnlockLockout(long);
- method public void onDeviceUnlocked();
- method public void onEscrowTokenAdded(byte[], long, android.os.UserHandle);
- method public void onEscrowTokenRemoved(long, boolean);
- method public void onEscrowTokenStateReceived(long, int);
- method public void onTrustTimeout();
- method public void onUnlockAttempt(boolean);
- method public final void removeEscrowToken(long, android.os.UserHandle);
- method public final void revokeTrust();
- method public final void setManagingTrust(boolean);
- method public final void showKeyguardErrorMessage(@NonNull CharSequence);
- method public final void unlockUserWithToken(long, byte[], android.os.UserHandle);
- field public static final int FLAG_GRANT_TRUST_DISMISS_KEYGUARD = 2; // 0x2
- field public static final int FLAG_GRANT_TRUST_INITIATED_BY_USER = 1; // 0x1
- field public static final String SERVICE_INTERFACE = "android.service.trust.TrustAgentService";
- field public static final int TOKEN_STATE_ACTIVE = 1; // 0x1
- field public static final int TOKEN_STATE_INACTIVE = 0; // 0x0
- field public static final String TRUST_AGENT_META_DATA = "android.service.trust.trustagent";
- }
-
-}
-
-package android.service.voice {
-
- public class AlwaysOnHotwordDetector {
- method @Nullable public android.content.Intent createEnrollIntent();
- method @Nullable public android.content.Intent createReEnrollIntent();
- method @Nullable public android.content.Intent createUnEnrollIntent();
- method @RequiresPermission(allOf={android.Manifest.permission.RECORD_AUDIO, android.Manifest.permission.CAPTURE_AUDIO_HOTWORD}) public int getParameter(int);
- method public int getSupportedAudioCapabilities();
- method public int getSupportedRecognitionModes();
- method @Nullable @RequiresPermission(allOf={android.Manifest.permission.RECORD_AUDIO, android.Manifest.permission.CAPTURE_AUDIO_HOTWORD}) public android.service.voice.AlwaysOnHotwordDetector.ModelParamRange queryParameter(int);
- method @RequiresPermission(allOf={android.Manifest.permission.RECORD_AUDIO, android.Manifest.permission.CAPTURE_AUDIO_HOTWORD}) public int setParameter(int, int);
- method @RequiresPermission(allOf={android.Manifest.permission.RECORD_AUDIO, android.Manifest.permission.CAPTURE_AUDIO_HOTWORD}) public boolean startRecognition(int);
- method @RequiresPermission(allOf={android.Manifest.permission.RECORD_AUDIO, android.Manifest.permission.CAPTURE_AUDIO_HOTWORD}) public boolean stopRecognition();
- field public static final int AUDIO_CAPABILITY_ECHO_CANCELLATION = 1; // 0x1
- field public static final int AUDIO_CAPABILITY_NOISE_SUPPRESSION = 2; // 0x2
- field public static final int MODEL_PARAM_THRESHOLD_FACTOR = 0; // 0x0
- field public static final int RECOGNITION_FLAG_ALLOW_MULTIPLE_TRIGGERS = 2; // 0x2
- field public static final int RECOGNITION_FLAG_CAPTURE_TRIGGER_AUDIO = 1; // 0x1
- field public static final int RECOGNITION_FLAG_ENABLE_AUDIO_ECHO_CANCELLATION = 4; // 0x4
- field public static final int RECOGNITION_FLAG_ENABLE_AUDIO_NOISE_SUPPRESSION = 8; // 0x8
- field public static final int RECOGNITION_MODE_USER_IDENTIFICATION = 2; // 0x2
- field public static final int RECOGNITION_MODE_VOICE_TRIGGER = 1; // 0x1
- field public static final int STATE_HARDWARE_UNAVAILABLE = -2; // 0xfffffffe
- field public static final int STATE_KEYPHRASE_ENROLLED = 2; // 0x2
- field public static final int STATE_KEYPHRASE_UNENROLLED = 1; // 0x1
- field @Deprecated public static final int STATE_KEYPHRASE_UNSUPPORTED = -1; // 0xffffffff
- }
-
- public abstract static class AlwaysOnHotwordDetector.Callback {
- ctor public AlwaysOnHotwordDetector.Callback();
- method public abstract void onAvailabilityChanged(int);
- method public abstract void onDetected(@NonNull android.service.voice.AlwaysOnHotwordDetector.EventPayload);
- method public abstract void onError();
- method public abstract void onRecognitionPaused();
- method public abstract void onRecognitionResumed();
- }
-
- public static class AlwaysOnHotwordDetector.EventPayload {
- method @Nullable public android.media.AudioFormat getCaptureAudioFormat();
- method @Nullable public byte[] getTriggerAudio();
- }
-
- public static final class AlwaysOnHotwordDetector.ModelParamRange {
- method public int getEnd();
- method public int getStart();
- }
-
- public class VoiceInteractionService extends android.app.Service {
- method @NonNull public final android.service.voice.AlwaysOnHotwordDetector createAlwaysOnHotwordDetector(String, java.util.Locale, android.service.voice.AlwaysOnHotwordDetector.Callback);
- method @NonNull @RequiresPermission("android.permission.MANAGE_VOICE_KEYPHRASES") public final android.media.voice.KeyphraseModelManager createKeyphraseModelManager();
- }
-
-}
-
-package android.service.wallpaper {
-
- public class WallpaperService.Engine {
- method public boolean isInAmbientMode();
- method public void onAmbientModeChanged(boolean, long);
- }
-
-}
-
-package android.service.watchdog {
-
- public abstract class ExplicitHealthCheckService extends android.app.Service {
- ctor public ExplicitHealthCheckService();
- method public final void notifyHealthCheckPassed(@NonNull String);
- method @NonNull public final android.os.IBinder onBind(@NonNull android.content.Intent);
- method public abstract void onCancelHealthCheck(@NonNull String);
- method @NonNull public abstract java.util.List<java.lang.String> onGetRequestedPackages();
- method @NonNull public abstract java.util.List<android.service.watchdog.ExplicitHealthCheckService.PackageConfig> onGetSupportedPackages();
- method public abstract void onRequestHealthCheck(@NonNull String);
- field public static final String BIND_PERMISSION = "android.permission.BIND_EXPLICIT_HEALTH_CHECK_SERVICE";
- field public static final String SERVICE_INTERFACE = "android.service.watchdog.ExplicitHealthCheckService";
- }
-
- public static final class ExplicitHealthCheckService.PackageConfig implements android.os.Parcelable {
- ctor public ExplicitHealthCheckService.PackageConfig(@NonNull String, long);
- method public int describeContents();
- method public long getHealthCheckTimeoutMillis();
- method @NonNull public String getPackageName();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.service.watchdog.ExplicitHealthCheckService.PackageConfig> CREATOR;
- }
-
-}
-
-package android.telecom {
-
- @Deprecated public class AudioState implements android.os.Parcelable {
- ctor @Deprecated public AudioState(boolean, int, int);
- ctor @Deprecated public AudioState(android.telecom.AudioState);
- ctor @Deprecated public AudioState(android.telecom.CallAudioState);
- method @Deprecated public static String audioRouteToString(int);
- method @Deprecated public int describeContents();
- method @Deprecated public int getRoute();
- method @Deprecated public int getSupportedRouteMask();
- method @Deprecated public boolean isMuted();
- method @Deprecated public void writeToParcel(android.os.Parcel, int);
- field @Deprecated @NonNull public static final android.os.Parcelable.Creator<android.telecom.AudioState> CREATOR;
- field @Deprecated public static final int ROUTE_BLUETOOTH = 2; // 0x2
- field @Deprecated public static final int ROUTE_EARPIECE = 1; // 0x1
- field @Deprecated public static final int ROUTE_SPEAKER = 8; // 0x8
- field @Deprecated public static final int ROUTE_WIRED_HEADSET = 4; // 0x4
- field @Deprecated public static final int ROUTE_WIRED_OR_EARPIECE = 5; // 0x5
- }
-
- public final class Call {
- method @Deprecated public void addListener(android.telecom.Call.Listener);
- method public void enterBackgroundAudioProcessing();
- method public void exitBackgroundAudioProcessing(boolean);
- method @Deprecated public void removeListener(android.telecom.Call.Listener);
- field @Deprecated public static final int STATE_PRE_DIAL_WAIT = 8; // 0x8
- }
-
- @Deprecated public abstract static class Call.Listener extends android.telecom.Call.Callback {
- ctor @Deprecated public Call.Listener();
- }
-
- public static class CallScreeningService.CallResponse.Builder {
- method @NonNull @RequiresPermission(android.Manifest.permission.CAPTURE_AUDIO_OUTPUT) public android.telecom.CallScreeningService.CallResponse.Builder setShouldScreenCallViaAudioProcessing(boolean);
- }
-
- public abstract class Conference extends android.telecom.Conferenceable {
- method @Deprecated public final android.telecom.AudioState getAudioState();
- method @Deprecated public final long getConnectTimeMillis();
- method public android.telecom.Connection getPrimaryConnection();
- method @NonNull public final String getTelecomCallId();
- method @Deprecated public void onAudioStateChanged(android.telecom.AudioState);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public final void setAddress(@NonNull android.net.Uri, int);
- method public final void setCallerDisplayName(@NonNull String, int);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void setConferenceState(boolean);
- method @Deprecated public final void setConnectTimeMillis(long);
- }
-
- public abstract class Connection extends android.telecom.Conferenceable {
- method @Deprecated public final android.telecom.AudioState getAudioState();
- method @IntRange(from=0) public final long getConnectTimeMillis();
- method public final long getConnectionStartElapsedRealtimeMillis();
- method @Nullable public android.telecom.PhoneAccountHandle getPhoneAccountHandle();
- method @Nullable public final String getTelecomCallId();
- method @Deprecated public void onAudioStateChanged(android.telecom.AudioState);
- method public final void resetConnectionTime();
- method public void setCallDirection(int);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public final void setConnectTimeMillis(@IntRange(from=0) long);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public final void setConnectionStartElapsedRealtimeMillis(long);
- method public void setPhoneAccountHandle(@NonNull android.telecom.PhoneAccountHandle);
- method public void setTelecomCallId(@NonNull String);
- field public static final int CAPABILITY_CONFERENCE_HAS_NO_CHILDREN = 2097152; // 0x200000
- field public static final int CAPABILITY_SPEED_UP_MT_AUDIO = 262144; // 0x40000
- field public static final String EXTRA_DISABLE_ADD_CALL = "android.telecom.extra.DISABLE_ADD_CALL";
- field public static final int PROPERTY_EMERGENCY_CALLBACK_MODE = 1; // 0x1
- field public static final int PROPERTY_GENERIC_CONFERENCE = 2; // 0x2
- field public static final int PROPERTY_IS_DOWNGRADED_CONFERENCE = 64; // 0x40
- field public static final int PROPERTY_REMOTELY_HOSTED = 2048; // 0x800
- }
-
- public final class ConnectionRequest implements android.os.Parcelable {
- method @Nullable public String getTelecomCallId();
- }
-
- public abstract class ConnectionService extends android.app.Service {
- method public final void addExistingConnection(@NonNull android.telecom.PhoneAccountHandle, @NonNull android.telecom.Connection, @NonNull android.telecom.Conference);
- }
-
- public abstract class InCallService extends android.app.Service {
- method @Deprecated public android.telecom.Phone getPhone();
- method @Deprecated public void onPhoneCreated(android.telecom.Phone);
- method @Deprecated public void onPhoneDestroyed(android.telecom.Phone);
- }
-
- public class ParcelableCallAnalytics implements android.os.Parcelable {
- ctor public ParcelableCallAnalytics(long, long, int, boolean, boolean, int, int, boolean, String, boolean, java.util.List<android.telecom.ParcelableCallAnalytics.AnalyticsEvent>, java.util.List<android.telecom.ParcelableCallAnalytics.EventTiming>);
- ctor public ParcelableCallAnalytics(android.os.Parcel);
- method public java.util.List<android.telecom.ParcelableCallAnalytics.AnalyticsEvent> analyticsEvents();
- method public int describeContents();
- method public long getCallDurationMillis();
- method public int getCallTechnologies();
- method public int getCallTerminationCode();
- method public int getCallType();
- method public String getConnectionService();
- method public java.util.List<android.telecom.ParcelableCallAnalytics.EventTiming> getEventTimings();
- method public long getStartTimeMillis();
- method public boolean isAdditionalCall();
- method public boolean isCreatedFromExistingConnection();
- method public boolean isEmergencyCall();
- method public boolean isInterrupted();
- method public void writeToParcel(android.os.Parcel, int);
- field public static final int CALLTYPE_INCOMING = 1; // 0x1
- field public static final int CALLTYPE_OUTGOING = 2; // 0x2
- field public static final int CALLTYPE_UNKNOWN = 0; // 0x0
- field public static final int CDMA_PHONE = 1; // 0x1
- field @NonNull public static final android.os.Parcelable.Creator<android.telecom.ParcelableCallAnalytics> CREATOR;
- field public static final int GSM_PHONE = 2; // 0x2
- field public static final int IMS_PHONE = 4; // 0x4
- field public static final long MILLIS_IN_1_SECOND = 1000L; // 0x3e8L
- field public static final long MILLIS_IN_5_MINUTES = 300000L; // 0x493e0L
- field public static final int SIP_PHONE = 8; // 0x8
- field public static final int STILL_CONNECTED = -1; // 0xffffffff
- field public static final int THIRD_PARTY_PHONE = 16; // 0x10
- }
-
- public static final class ParcelableCallAnalytics.AnalyticsEvent implements android.os.Parcelable {
- ctor public ParcelableCallAnalytics.AnalyticsEvent(int, long);
- method public int describeContents();
- method public int getEventName();
- method public long getTimeSinceLastEvent();
- method public void writeToParcel(android.os.Parcel, int);
- field public static final int AUDIO_ROUTE_BT = 204; // 0xcc
- field public static final int AUDIO_ROUTE_EARPIECE = 205; // 0xcd
- field public static final int AUDIO_ROUTE_HEADSET = 206; // 0xce
- field public static final int AUDIO_ROUTE_SPEAKER = 207; // 0xcf
- field public static final int BIND_CS = 5; // 0x5
- field public static final int BLOCK_CHECK_FINISHED = 105; // 0x69
- field public static final int BLOCK_CHECK_INITIATED = 104; // 0x68
- field public static final int CONFERENCE_WITH = 300; // 0x12c
- field @NonNull public static final android.os.Parcelable.Creator<android.telecom.ParcelableCallAnalytics.AnalyticsEvent> CREATOR;
- field public static final int CS_BOUND = 6; // 0x6
- field public static final int DIRECT_TO_VM_FINISHED = 103; // 0x67
- field public static final int DIRECT_TO_VM_INITIATED = 102; // 0x66
- field public static final int FILTERING_COMPLETED = 107; // 0x6b
- field public static final int FILTERING_INITIATED = 106; // 0x6a
- field public static final int FILTERING_TIMED_OUT = 108; // 0x6c
- field public static final int MUTE = 202; // 0xca
- field public static final int REMOTELY_HELD = 402; // 0x192
- field public static final int REMOTELY_UNHELD = 403; // 0x193
- field public static final int REQUEST_ACCEPT = 7; // 0x7
- field public static final int REQUEST_HOLD = 400; // 0x190
- field public static final int REQUEST_PULL = 500; // 0x1f4
- field public static final int REQUEST_REJECT = 8; // 0x8
- field public static final int REQUEST_UNHOLD = 401; // 0x191
- field public static final int SCREENING_COMPLETED = 101; // 0x65
- field public static final int SCREENING_SENT = 100; // 0x64
- field public static final int SET_ACTIVE = 1; // 0x1
- field public static final int SET_DIALING = 4; // 0x4
- field public static final int SET_DISCONNECTED = 2; // 0x2
- field public static final int SET_HOLD = 404; // 0x194
- field public static final int SET_PARENT = 302; // 0x12e
- field public static final int SET_SELECT_PHONE_ACCOUNT = 0; // 0x0
- field public static final int SILENCE = 201; // 0xc9
- field public static final int SKIP_RINGING = 200; // 0xc8
- field public static final int SPLIT_CONFERENCE = 301; // 0x12d
- field public static final int START_CONNECTION = 3; // 0x3
- field public static final int SWAP = 405; // 0x195
- field public static final int UNMUTE = 203; // 0xcb
- }
-
- public static final class ParcelableCallAnalytics.EventTiming implements android.os.Parcelable {
- ctor public ParcelableCallAnalytics.EventTiming(int, long);
- method public int describeContents();
- method public int getName();
- method public long getTime();
- method public void writeToParcel(android.os.Parcel, int);
- field public static final int ACCEPT_TIMING = 0; // 0x0
- field public static final int BIND_CS_TIMING = 6; // 0x6
- field public static final int BLOCK_CHECK_FINISHED_TIMING = 9; // 0x9
- field @NonNull public static final android.os.Parcelable.Creator<android.telecom.ParcelableCallAnalytics.EventTiming> CREATOR;
- field public static final int DIRECT_TO_VM_FINISHED_TIMING = 8; // 0x8
- field public static final int DISCONNECT_TIMING = 2; // 0x2
- field public static final int FILTERING_COMPLETED_TIMING = 10; // 0xa
- field public static final int FILTERING_TIMED_OUT_TIMING = 11; // 0xb
- field public static final int HOLD_TIMING = 3; // 0x3
- field public static final int INVALID = 999999; // 0xf423f
- field public static final int OUTGOING_TIME_TO_DIALING_TIMING = 5; // 0x5
- field public static final int REJECT_TIMING = 1; // 0x1
- field public static final int SCREENING_COMPLETED_TIMING = 7; // 0x7
- field public static final int UNHOLD_TIMING = 4; // 0x4
- }
-
- @Deprecated public final class Phone {
- method @Deprecated public void addListener(android.telecom.Phone.Listener);
- method @Deprecated public boolean canAddCall();
- method @Deprecated public android.telecom.AudioState getAudioState();
- method @Deprecated public android.telecom.CallAudioState getCallAudioState();
- method @Deprecated public java.util.List<android.telecom.Call> getCalls();
- method @Deprecated public void removeListener(android.telecom.Phone.Listener);
- method @Deprecated public void requestBluetoothAudio(String);
- method @Deprecated public void setAudioRoute(int);
- method @Deprecated public void setMuted(boolean);
- }
-
- @Deprecated public abstract static class Phone.Listener {
- ctor @Deprecated public Phone.Listener();
- method @Deprecated public void onAudioStateChanged(android.telecom.Phone, android.telecom.AudioState);
- method @Deprecated public void onBringToForeground(android.telecom.Phone, boolean);
- method @Deprecated public void onCallAdded(android.telecom.Phone, android.telecom.Call);
- method @Deprecated public void onCallAudioStateChanged(android.telecom.Phone, android.telecom.CallAudioState);
- method @Deprecated public void onCallRemoved(android.telecom.Phone, android.telecom.Call);
- method @Deprecated public void onCanAddCallChanged(android.telecom.Phone, boolean);
- method @Deprecated public void onSilenceRinger(android.telecom.Phone);
- }
-
- public final class PhoneAccount implements android.os.Parcelable {
- field public static final int CAPABILITY_EMERGENCY_CALLS_ONLY = 128; // 0x80
- field public static final int CAPABILITY_EMERGENCY_PREFERRED = 8192; // 0x2000
- field public static final int CAPABILITY_EMERGENCY_VIDEO_CALLING = 512; // 0x200
- field public static final int CAPABILITY_MULTI_USER = 32; // 0x20
- field public static final String EXTRA_PLAY_CALL_RECORDING_TONE = "android.telecom.extra.PLAY_CALL_RECORDING_TONE";
- field public static final String EXTRA_SORT_ORDER = "android.telecom.extra.SORT_ORDER";
- }
-
- public static class PhoneAccount.Builder {
- method @NonNull @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public android.telecom.PhoneAccount.Builder setGroupId(@NonNull String);
- }
-
- public class PhoneAccountSuggestionService extends android.app.Service {
- ctor public PhoneAccountSuggestionService();
- method public void onAccountSuggestionRequest(@NonNull String);
- method public android.os.IBinder onBind(android.content.Intent);
- method public final void suggestPhoneAccounts(@NonNull String, @NonNull java.util.List<android.telecom.PhoneAccountSuggestion>);
- field public static final String SERVICE_INTERFACE = "android.telecom.PhoneAccountSuggestionService";
- }
-
- public final class RemoteConference {
- method @Deprecated public void setAudioState(android.telecom.AudioState);
- }
-
- public final class RemoteConnection {
- method @Deprecated public void setAudioState(android.telecom.AudioState);
- }
-
- public final class StatusHints implements android.os.Parcelable {
- ctor @Deprecated public StatusHints(android.content.ComponentName, CharSequence, int, android.os.Bundle);
- method @Deprecated public android.graphics.drawable.Drawable getIcon(android.content.Context);
- method @Deprecated public int getIconResId();
- method @Deprecated public android.content.ComponentName getPackageName();
- }
-
- public final class TelecomAnalytics implements android.os.Parcelable {
- ctor public TelecomAnalytics(java.util.List<android.telecom.TelecomAnalytics.SessionTiming>, java.util.List<android.telecom.ParcelableCallAnalytics>);
- method public int describeContents();
- method public java.util.List<android.telecom.ParcelableCallAnalytics> getCallAnalytics();
- method public java.util.List<android.telecom.TelecomAnalytics.SessionTiming> getSessionTimings();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.telecom.TelecomAnalytics> CREATOR;
- }
-
- public static final class TelecomAnalytics.SessionTiming implements android.os.Parcelable {
- ctor public TelecomAnalytics.SessionTiming(int, long);
- method public int describeContents();
- method public Integer getKey();
- method public long getTime();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.telecom.TelecomAnalytics.SessionTiming> CREATOR;
- field public static final int CSW_ADD_CONFERENCE_CALL = 108; // 0x6c
- field public static final int CSW_HANDLE_CREATE_CONNECTION_COMPLETE = 100; // 0x64
- field public static final int CSW_REMOVE_CALL = 106; // 0x6a
- field public static final int CSW_SET_ACTIVE = 101; // 0x65
- field public static final int CSW_SET_DIALING = 103; // 0x67
- field public static final int CSW_SET_DISCONNECTED = 104; // 0x68
- field public static final int CSW_SET_IS_CONFERENCED = 107; // 0x6b
- field public static final int CSW_SET_ON_HOLD = 105; // 0x69
- field public static final int CSW_SET_RINGING = 102; // 0x66
- field public static final int ICA_ANSWER_CALL = 1; // 0x1
- field public static final int ICA_CONFERENCE = 8; // 0x8
- field public static final int ICA_DISCONNECT_CALL = 3; // 0x3
- field public static final int ICA_HOLD_CALL = 4; // 0x4
- field public static final int ICA_MUTE = 6; // 0x6
- field public static final int ICA_REJECT_CALL = 2; // 0x2
- field public static final int ICA_SET_AUDIO_ROUTE = 7; // 0x7
- field public static final int ICA_UNHOLD_CALL = 5; // 0x5
- }
-
- public class TelecomManager {
- method public void addNewUnknownCall(android.telecom.PhoneAccountHandle, android.os.Bundle);
- method @Deprecated public void clearAccounts();
- method public void clearPhoneAccounts();
- method @NonNull public android.content.Intent createLaunchEmergencyDialerIntent(@Nullable String);
- method @RequiresPermission(android.Manifest.permission.DUMP) public android.telecom.TelecomAnalytics dumpAnalytics();
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void enablePhoneAccount(android.telecom.PhoneAccountHandle, boolean);
- method public java.util.List<android.telecom.PhoneAccountHandle> getAllPhoneAccountHandles();
- method public java.util.List<android.telecom.PhoneAccount> getAllPhoneAccounts();
- method public int getAllPhoneAccountsCount();
- method @NonNull @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public java.util.List<android.telecom.PhoneAccountHandle> getCallCapablePhoneAccounts(boolean);
- method public int getCallState();
- method public android.telecom.PhoneAccountHandle getConnectionManager();
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public int getCurrentTtyMode();
- method @Nullable @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public String getDefaultDialerPackage(@NonNull android.os.UserHandle);
- method @Deprecated public android.content.ComponentName getDefaultPhoneApp();
- method @Deprecated public java.util.List<android.telecom.PhoneAccountHandle> getPhoneAccountsForPackage();
- method @RequiresPermission(anyOf={android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE, android.Manifest.permission.READ_PHONE_STATE}) public java.util.List<android.telecom.PhoneAccountHandle> getPhoneAccountsSupportingScheme(String);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public boolean isInEmergencyCall();
- method @RequiresPermission(anyOf={android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE, android.Manifest.permission.READ_PHONE_STATE}) public boolean isRinging();
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void setUserSelectedOutgoingPhoneAccount(@Nullable android.telecom.PhoneAccountHandle);
- field public static final String ACTION_CURRENT_TTY_MODE_CHANGED = "android.telecom.action.CURRENT_TTY_MODE_CHANGED";
- field public static final String ACTION_TTY_PREFERRED_MODE_CHANGED = "android.telecom.action.TTY_PREFERRED_MODE_CHANGED";
- field public static final int CALL_SOURCE_EMERGENCY_DIALPAD = 1; // 0x1
- field public static final int CALL_SOURCE_EMERGENCY_SHORTCUT = 2; // 0x2
- field public static final int CALL_SOURCE_UNSPECIFIED = 0; // 0x0
- field public static final String EXTRA_CALL_BACK_INTENT = "android.telecom.extra.CALL_BACK_INTENT";
- field public static final String EXTRA_CALL_SOURCE = "android.telecom.extra.CALL_SOURCE";
- field public static final String EXTRA_CALL_TECHNOLOGY_TYPE = "android.telecom.extra.CALL_TECHNOLOGY_TYPE";
- field public static final String EXTRA_CLEAR_MISSED_CALLS_INTENT = "android.telecom.extra.CLEAR_MISSED_CALLS_INTENT";
- field public static final String EXTRA_CONNECTION_SERVICE = "android.telecom.extra.CONNECTION_SERVICE";
- field public static final String EXTRA_CURRENT_TTY_MODE = "android.telecom.extra.CURRENT_TTY_MODE";
- field public static final String EXTRA_IS_USER_INTENT_EMERGENCY_CALL = "android.telecom.extra.IS_USER_INTENT_EMERGENCY_CALL";
- field public static final String EXTRA_TTY_PREFERRED_MODE = "android.telecom.extra.TTY_PREFERRED_MODE";
- field public static final String EXTRA_UNKNOWN_CALL_HANDLE = "android.telecom.extra.UNKNOWN_CALL_HANDLE";
- field public static final int TTY_MODE_FULL = 1; // 0x1
- field public static final int TTY_MODE_HCO = 2; // 0x2
- field public static final int TTY_MODE_OFF = 0; // 0x0
- field public static final int TTY_MODE_VCO = 3; // 0x3
- }
-
-}
-
-package android.telephony {
-
- public final class AccessNetworkConstants {
- field public static final int TRANSPORT_TYPE_INVALID = -1; // 0xffffffff
- }
-
- public static final class AccessNetworkConstants.NgranBands {
- method public static int getFrequencyRangeGroup(int);
- field public static final int FREQUENCY_RANGE_GROUP_1 = 1; // 0x1
- field public static final int FREQUENCY_RANGE_GROUP_2 = 2; // 0x2
- field public static final int FREQUENCY_RANGE_GROUP_UNKNOWN = 0; // 0x0
- }
-
- public final class BarringInfo implements android.os.Parcelable {
- ctor public BarringInfo();
- method @NonNull public android.telephony.BarringInfo createLocationInfoSanitizedCopy();
- }
-
- public final class CallAttributes implements android.os.Parcelable {
- ctor public CallAttributes(@NonNull android.telephony.PreciseCallState, int, @NonNull android.telephony.CallQuality);
- method public int describeContents();
- method @NonNull public android.telephony.CallQuality getCallQuality();
- method public int getNetworkType();
- method @NonNull public android.telephony.PreciseCallState getPreciseCallState();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.CallAttributes> CREATOR;
- }
-
- public final class CallForwardingInfo implements android.os.Parcelable {
- ctor public CallForwardingInfo(boolean, int, @Nullable String, int);
- method public int describeContents();
- method @Nullable public String getNumber();
- method public int getReason();
- method public int getTimeoutSeconds();
- method public boolean isEnabled();
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.CallForwardingInfo> CREATOR;
- field public static final int REASON_ALL = 4; // 0x4
- field public static final int REASON_ALL_CONDITIONAL = 5; // 0x5
- field public static final int REASON_BUSY = 1; // 0x1
- field public static final int REASON_NOT_REACHABLE = 3; // 0x3
- field public static final int REASON_NO_REPLY = 2; // 0x2
- field public static final int REASON_UNCONDITIONAL = 0; // 0x0
- }
-
- public final class CallQuality implements android.os.Parcelable {
- ctor public CallQuality(int, int, int, int, int, int, int, int, int, int, int);
- ctor public CallQuality(int, int, int, int, int, int, int, int, int, int, int, boolean, boolean, boolean);
- method public int describeContents();
- method public int getAverageRelativeJitter();
- method public int getAverageRoundTripTime();
- method public int getCallDuration();
- method public int getCodecType();
- method public int getDownlinkCallQualityLevel();
- method public int getMaxRelativeJitter();
- method public int getNumRtpPacketsNotReceived();
- method public int getNumRtpPacketsReceived();
- method public int getNumRtpPacketsTransmitted();
- method public int getNumRtpPacketsTransmittedLost();
- method public int getUplinkCallQualityLevel();
- method public boolean isIncomingSilenceDetectedAtCallSetup();
- method public boolean isOutgoingSilenceDetectedAtCallSetup();
- method public boolean isRtpInactivityDetected();
- method public void writeToParcel(android.os.Parcel, int);
- field public static final int CALL_QUALITY_BAD = 4; // 0x4
- field public static final int CALL_QUALITY_EXCELLENT = 0; // 0x0
- field public static final int CALL_QUALITY_FAIR = 2; // 0x2
- field public static final int CALL_QUALITY_GOOD = 1; // 0x1
- field public static final int CALL_QUALITY_NOT_AVAILABLE = 5; // 0x5
- field public static final int CALL_QUALITY_POOR = 3; // 0x3
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.CallQuality> CREATOR;
- }
-
- public final class CarrierBandwidth implements android.os.Parcelable {
- ctor public CarrierBandwidth(int, int, int, int);
- method public int describeContents();
- method public int getPrimaryDownlinkCapacityKbps();
- method public int getPrimaryUplinkCapacityKbps();
- method public int getSecondaryDownlinkCapacityKbps();
- method public int getSecondaryUplinkCapacityKbps();
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.CarrierBandwidth> CREATOR;
- field public static final int INVALID = -1; // 0xffffffff
- }
-
- public class CarrierConfigManager {
- method @NonNull @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public String getDefaultCarrierServicePackageName();
- method @NonNull public static android.os.PersistableBundle getDefaultConfig();
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void overrideConfig(int, @Nullable android.os.PersistableBundle);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void updateConfigForPhoneId(int, String);
- field public static final String KEY_CARRIER_SETUP_APP_STRING = "carrier_setup_app_string";
- field public static final String KEY_SUPPORT_CDMA_1X_VOICE_CALLS_BOOL = "support_cdma_1x_voice_calls_bool";
- }
-
- public static final class CarrierConfigManager.Wifi {
- field public static final String KEY_HOTSPOT_MAX_CLIENT_COUNT = "wifi.hotspot_maximum_client_count";
- field public static final String KEY_PREFIX = "wifi.";
- }
-
- public final class CarrierRestrictionRules implements android.os.Parcelable {
- method @NonNull public java.util.List<java.lang.Boolean> areCarrierIdentifiersAllowed(@NonNull java.util.List<android.service.carrier.CarrierIdentifier>);
- method public int describeContents();
- method @NonNull public java.util.List<android.service.carrier.CarrierIdentifier> getAllowedCarriers();
- method public int getDefaultCarrierRestriction();
- method @NonNull public java.util.List<android.service.carrier.CarrierIdentifier> getExcludedCarriers();
- method public int getMultiSimPolicy();
- method public boolean isAllCarriersAllowed();
- method public void writeToParcel(android.os.Parcel, int);
- field public static final int CARRIER_RESTRICTION_DEFAULT_ALLOWED = 1; // 0x1
- field public static final int CARRIER_RESTRICTION_DEFAULT_NOT_ALLOWED = 0; // 0x0
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.CarrierRestrictionRules> CREATOR;
- field public static final int MULTISIM_POLICY_NONE = 0; // 0x0
- field public static final int MULTISIM_POLICY_ONE_VALID_SIM_MUST_BE_PRESENT = 1; // 0x1
- }
-
- public static final class CarrierRestrictionRules.Builder {
- ctor public CarrierRestrictionRules.Builder();
- method @NonNull public android.telephony.CarrierRestrictionRules build();
- method @NonNull public android.telephony.CarrierRestrictionRules.Builder setAllCarriersAllowed();
- method @NonNull public android.telephony.CarrierRestrictionRules.Builder setAllowedCarriers(@NonNull java.util.List<android.service.carrier.CarrierIdentifier>);
- method @NonNull public android.telephony.CarrierRestrictionRules.Builder setDefaultCarrierRestriction(int);
- method @NonNull public android.telephony.CarrierRestrictionRules.Builder setExcludedCarriers(@NonNull java.util.List<android.service.carrier.CarrierIdentifier>);
- method @NonNull public android.telephony.CarrierRestrictionRules.Builder setMultiSimPolicy(int);
- }
-
- public class CbGeoUtils {
- }
-
- public static class CbGeoUtils.Circle implements android.telephony.CbGeoUtils.Geometry {
- ctor public CbGeoUtils.Circle(@NonNull android.telephony.CbGeoUtils.LatLng, double);
- method public boolean contains(@NonNull android.telephony.CbGeoUtils.LatLng);
- method @NonNull public android.telephony.CbGeoUtils.LatLng getCenter();
- method public double getRadius();
- }
-
- public static interface CbGeoUtils.Geometry {
- method public boolean contains(@NonNull android.telephony.CbGeoUtils.LatLng);
- }
-
- public static class CbGeoUtils.LatLng {
- ctor public CbGeoUtils.LatLng(double, double);
- method public double distance(@NonNull android.telephony.CbGeoUtils.LatLng);
- method @NonNull public android.telephony.CbGeoUtils.LatLng subtract(@NonNull android.telephony.CbGeoUtils.LatLng);
- field public final double lat;
- field public final double lng;
- }
-
- public static class CbGeoUtils.Polygon implements android.telephony.CbGeoUtils.Geometry {
- ctor public CbGeoUtils.Polygon(@NonNull java.util.List<android.telephony.CbGeoUtils.LatLng>);
- method public boolean contains(@NonNull android.telephony.CbGeoUtils.LatLng);
- method @NonNull public java.util.List<android.telephony.CbGeoUtils.LatLng> getVertices();
- }
-
- public class CellBroadcastIntents {
- method public static void sendSmsCbReceivedBroadcast(@NonNull android.content.Context, @Nullable android.os.UserHandle, @NonNull android.telephony.SmsCbMessage, @Nullable android.content.BroadcastReceiver, @Nullable android.os.Handler, int, int);
- field public static final String ACTION_AREA_INFO_UPDATED = "android.telephony.action.AREA_INFO_UPDATED";
- }
-
- public abstract class CellBroadcastService extends android.app.Service {
- ctor public CellBroadcastService();
- method @NonNull @WorkerThread public abstract CharSequence getCellBroadcastAreaInfo(int);
- method @CallSuper public android.os.IBinder onBind(@Nullable android.content.Intent);
- method public abstract void onCdmaCellBroadcastSms(int, @NonNull byte[], int);
- method public abstract void onCdmaScpMessage(int, @NonNull java.util.List<android.telephony.cdma.CdmaSmsCbProgramData>, @NonNull String, @NonNull java.util.function.Consumer<android.os.Bundle>);
- method public abstract void onGsmCellBroadcastSms(int, @NonNull byte[]);
- field public static final String CELL_BROADCAST_SERVICE_INTERFACE = "android.telephony.CellBroadcastService";
- }
-
- public abstract class CellIdentity implements android.os.Parcelable {
- method @NonNull public abstract android.telephony.CellLocation asCellLocation();
- method @NonNull public abstract android.telephony.CellIdentity sanitizeLocationInfo();
- }
-
- public final class CellIdentityCdma extends android.telephony.CellIdentity {
- method @NonNull public android.telephony.cdma.CdmaCellLocation asCellLocation();
- method @NonNull public android.telephony.CellIdentityCdma sanitizeLocationInfo();
- }
-
- public final class CellIdentityGsm extends android.telephony.CellIdentity {
- method @NonNull public android.telephony.gsm.GsmCellLocation asCellLocation();
- method @NonNull public android.telephony.CellIdentityGsm sanitizeLocationInfo();
- }
-
- public final class CellIdentityLte extends android.telephony.CellIdentity {
- method @NonNull public android.telephony.gsm.GsmCellLocation asCellLocation();
- method @NonNull public android.telephony.CellIdentityLte sanitizeLocationInfo();
- }
-
- public final class CellIdentityNr extends android.telephony.CellIdentity {
- method @NonNull public android.telephony.CellLocation asCellLocation();
- method @NonNull public android.telephony.CellIdentityNr sanitizeLocationInfo();
- }
-
- public final class CellIdentityTdscdma extends android.telephony.CellIdentity {
- method @NonNull public android.telephony.gsm.GsmCellLocation asCellLocation();
- method @NonNull public android.telephony.CellIdentityTdscdma sanitizeLocationInfo();
- }
-
- public final class CellIdentityWcdma extends android.telephony.CellIdentity {
- method @NonNull public android.telephony.gsm.GsmCellLocation asCellLocation();
- method @NonNull public android.telephony.CellIdentityWcdma sanitizeLocationInfo();
- }
-
- public final class DataFailCause {
- field @Deprecated public static final int VSNCP_APN_UNATHORIZED = 2238; // 0x8be
- }
-
- public final class DataSpecificRegistrationInfo implements android.os.Parcelable {
- method public int describeContents();
- method @NonNull public android.telephony.LteVopsSupportInfo getLteVopsSupportInfo();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.DataSpecificRegistrationInfo> CREATOR;
- }
-
- public final class ImsiEncryptionInfo implements android.os.Parcelable {
- method public int describeContents();
- method @Nullable public String getKeyIdentifier();
- method @Nullable public java.security.PublicKey getPublicKey();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.ImsiEncryptionInfo> CREATOR;
- }
-
- public final class LteVopsSupportInfo implements android.os.Parcelable {
- ctor public LteVopsSupportInfo(int, int);
- method public int describeContents();
- method public int getEmcBearerSupport();
- method public int getVopsSupport();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.LteVopsSupportInfo> CREATOR;
- field public static final int LTE_STATUS_NOT_AVAILABLE = 1; // 0x1
- field public static final int LTE_STATUS_NOT_SUPPORTED = 3; // 0x3
- field public static final int LTE_STATUS_SUPPORTED = 2; // 0x2
- }
-
- public class MbmsDownloadSession implements java.lang.AutoCloseable {
- field public static final String MBMS_DOWNLOAD_SERVICE_ACTION = "android.telephony.action.EmbmsDownload";
- }
-
- public class MbmsGroupCallSession implements java.lang.AutoCloseable {
- field public static final String MBMS_GROUP_CALL_SERVICE_ACTION = "android.telephony.action.EmbmsGroupCall";
- }
-
- public class MbmsStreamingSession implements java.lang.AutoCloseable {
- field public static final String MBMS_STREAMING_SERVICE_ACTION = "android.telephony.action.EmbmsStreaming";
- }
-
- public final class ModemActivityInfo implements android.os.Parcelable {
- method public int describeContents();
- method @NonNull public android.telephony.ModemActivityInfo getDelta(@NonNull android.telephony.ModemActivityInfo);
- method public long getIdleTimeMillis();
- method public static int getNumTxPowerLevels();
- method public long getReceiveTimeMillis();
- method public long getSleepTimeMillis();
- method public long getTimestampMillis();
- method public long getTransmitDurationMillisAtPowerLevel(int);
- method @NonNull public android.util.Range<java.lang.Integer> getTransmitPowerRange(int);
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.ModemActivityInfo> CREATOR;
- field public static final int TX_POWER_LEVEL_0 = 0; // 0x0
- field public static final int TX_POWER_LEVEL_1 = 1; // 0x1
- field public static final int TX_POWER_LEVEL_2 = 2; // 0x2
- field public static final int TX_POWER_LEVEL_3 = 3; // 0x3
- field public static final int TX_POWER_LEVEL_4 = 4; // 0x4
- }
-
- public final class NetworkRegistrationInfo implements android.os.Parcelable {
- method @Nullable public android.telephony.DataSpecificRegistrationInfo getDataSpecificInfo();
- method public int getRegistrationState();
- method public int getRejectCause();
- method public int getRoamingType();
- method public boolean isEmergencyEnabled();
- method public void writeToParcel(android.os.Parcel, int);
- field public static final int REGISTRATION_STATE_DENIED = 3; // 0x3
- field public static final int REGISTRATION_STATE_HOME = 1; // 0x1
- field public static final int REGISTRATION_STATE_NOT_REGISTERED_OR_SEARCHING = 0; // 0x0
- field public static final int REGISTRATION_STATE_NOT_REGISTERED_SEARCHING = 2; // 0x2
- field public static final int REGISTRATION_STATE_ROAMING = 5; // 0x5
- field public static final int REGISTRATION_STATE_UNKNOWN = 4; // 0x4
- }
-
- public static final class NetworkRegistrationInfo.Builder {
- ctor public NetworkRegistrationInfo.Builder();
- method @NonNull public android.telephony.NetworkRegistrationInfo build();
- method @NonNull public android.telephony.NetworkRegistrationInfo.Builder setAccessNetworkTechnology(int);
- method @NonNull public android.telephony.NetworkRegistrationInfo.Builder setAvailableServices(@NonNull java.util.List<java.lang.Integer>);
- method @NonNull public android.telephony.NetworkRegistrationInfo.Builder setCellIdentity(@Nullable android.telephony.CellIdentity);
- method @NonNull public android.telephony.NetworkRegistrationInfo.Builder setDomain(int);
- method @NonNull public android.telephony.NetworkRegistrationInfo.Builder setEmergencyOnly(boolean);
- method @NonNull public android.telephony.NetworkRegistrationInfo.Builder setRegisteredPlmn(@Nullable String);
- method @NonNull public android.telephony.NetworkRegistrationInfo.Builder setRegistrationState(int);
- method @NonNull public android.telephony.NetworkRegistrationInfo.Builder setRejectCause(int);
- method @NonNull public android.telephony.NetworkRegistrationInfo.Builder setTransportType(int);
- }
-
- public abstract class NetworkService extends android.app.Service {
- ctor public NetworkService();
- method public android.os.IBinder onBind(android.content.Intent);
- method @Nullable public abstract android.telephony.NetworkService.NetworkServiceProvider onCreateNetworkServiceProvider(int);
- field public static final String SERVICE_INTERFACE = "android.telephony.NetworkService";
- }
-
- public abstract class NetworkService.NetworkServiceProvider implements java.lang.AutoCloseable {
- ctor public NetworkService.NetworkServiceProvider(int);
- method public abstract void close();
- method public final int getSlotIndex();
- method public final void notifyNetworkRegistrationInfoChanged();
- method public void requestNetworkRegistrationInfo(int, @NonNull android.telephony.NetworkServiceCallback);
- }
-
- public class NetworkServiceCallback {
- method public void onRequestNetworkRegistrationInfoComplete(int, @Nullable android.telephony.NetworkRegistrationInfo);
- field public static final int RESULT_ERROR_BUSY = 3; // 0x3
- field public static final int RESULT_ERROR_FAILED = 5; // 0x5
- field public static final int RESULT_ERROR_ILLEGAL_STATE = 4; // 0x4
- field public static final int RESULT_ERROR_INVALID_ARG = 2; // 0x2
- field public static final int RESULT_ERROR_UNSUPPORTED = 1; // 0x1
- field public static final int RESULT_SUCCESS = 0; // 0x0
- }
-
- public interface NumberVerificationCallback {
- method public default void onCallReceived(@NonNull String);
- method public default void onVerificationFailed(int);
- field public static final int REASON_CONCURRENT_REQUESTS = 4; // 0x4
- field public static final int REASON_IN_ECBM = 5; // 0x5
- field public static final int REASON_IN_EMERGENCY_CALL = 6; // 0x6
- field public static final int REASON_NETWORK_NOT_AVAILABLE = 2; // 0x2
- field public static final int REASON_TIMED_OUT = 1; // 0x1
- field public static final int REASON_TOO_MANY_CALLS = 3; // 0x3
- field public static final int REASON_UNSPECIFIED = 0; // 0x0
- }
-
- public final class PhoneNumberRange implements android.os.Parcelable {
- ctor public PhoneNumberRange(@NonNull String, @NonNull String, @NonNull String, @NonNull String);
- method public int describeContents();
- method public boolean matches(@NonNull String);
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.PhoneNumberRange> CREATOR;
- }
-
- public class PhoneNumberUtils {
- method @NonNull public static String getUsernameFromUriNumber(@NonNull String);
- method public static boolean isUriNumber(@Nullable String);
- method public static boolean isVoiceMailNumber(@NonNull android.content.Context, int, @Nullable String);
- }
-
- public class PhoneStateListener {
- method public void onCallAttributesChanged(@NonNull android.telephony.CallAttributes);
- method @Deprecated public void onOutgoingEmergencyCall(@NonNull android.telephony.emergency.EmergencyNumber);
- method public void onOutgoingEmergencyCall(@NonNull android.telephony.emergency.EmergencyNumber, int);
- method @Deprecated public void onOutgoingEmergencySms(@NonNull android.telephony.emergency.EmergencyNumber);
- method public void onOutgoingEmergencySms(@NonNull android.telephony.emergency.EmergencyNumber, int);
- method public void onPhysicalChannelConfigurationChanged(@NonNull java.util.List<android.telephony.PhysicalChannelConfig>);
- method @RequiresPermission("android.permission.READ_PRECISE_PHONE_STATE") public void onPreciseCallStateChanged(@NonNull android.telephony.PreciseCallState);
- method public void onRadioPowerStateChanged(int);
- method public void onSrvccStateChanged(int);
- method public void onVoiceActivationStateChanged(int);
- field @RequiresPermission("android.permission.READ_PRECISE_PHONE_STATE") public static final int LISTEN_CALL_ATTRIBUTES_CHANGED = 67108864; // 0x4000000
- field @RequiresPermission(android.Manifest.permission.READ_ACTIVE_EMERGENCY_SESSION) public static final int LISTEN_OUTGOING_EMERGENCY_CALL = 268435456; // 0x10000000
- field @RequiresPermission(android.Manifest.permission.READ_ACTIVE_EMERGENCY_SESSION) public static final int LISTEN_OUTGOING_EMERGENCY_SMS = 536870912; // 0x20000000
- field @RequiresPermission(android.Manifest.permission.READ_PRECISE_PHONE_STATE) public static final long LISTEN_PHYSICAL_CHANNEL_CONFIGURATION = 4294967296L; // 0x100000000L
- field @RequiresPermission("android.permission.READ_PRECISE_PHONE_STATE") public static final int LISTEN_PRECISE_CALL_STATE = 2048; // 0x800
- field @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public static final int LISTEN_RADIO_POWER_STATE_CHANGED = 8388608; // 0x800000
- field @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public static final int LISTEN_SRVCC_STATE_CHANGED = 16384; // 0x4000
- field @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public static final int LISTEN_VOICE_ACTIVATION_STATE = 131072; // 0x20000
- }
-
- public final class PhysicalChannelConfig implements android.os.Parcelable {
- method public int describeContents();
- method public int getCellBandwidthDownlink();
- method public int getChannelNumber();
- method public int getConnectionStatus();
- method public int getNetworkType();
- method @IntRange(from=0, to=1007) public int getPhysicalCellId();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field public static final int CHANNEL_NUMBER_UNKNOWN = -1; // 0xffffffff
- field public static final int CONNECTION_PRIMARY_SERVING = 1; // 0x1
- field public static final int CONNECTION_SECONDARY_SERVING = 2; // 0x2
- field public static final int CONNECTION_UNKNOWN = -1; // 0xffffffff
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.PhysicalChannelConfig> CREATOR;
- field public static final int PHYSICAL_CELL_ID_UNKNOWN = -1; // 0xffffffff
- }
-
- public final class PinResult implements android.os.Parcelable {
- method public int describeContents();
- method public int getAttemptsRemaining();
- method public int getResult();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.PinResult> CREATOR;
- field public static final int PIN_RESULT_TYPE_ABORTED = 3; // 0x3
- field public static final int PIN_RESULT_TYPE_FAILURE = 2; // 0x2
- field public static final int PIN_RESULT_TYPE_INCORRECT = 1; // 0x1
- field public static final int PIN_RESULT_TYPE_SUCCESS = 0; // 0x0
- }
-
- public final class PreciseCallState implements android.os.Parcelable {
- ctor public PreciseCallState(int, int, int, int, int);
- method public int describeContents();
- method public int getBackgroundCallState();
- method public int getForegroundCallState();
- method public int getRingingCallState();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.PreciseCallState> CREATOR;
- field public static final int PRECISE_CALL_STATE_ACTIVE = 1; // 0x1
- field public static final int PRECISE_CALL_STATE_ALERTING = 4; // 0x4
- field public static final int PRECISE_CALL_STATE_DIALING = 3; // 0x3
- field public static final int PRECISE_CALL_STATE_DISCONNECTED = 7; // 0x7
- field public static final int PRECISE_CALL_STATE_DISCONNECTING = 8; // 0x8
- field public static final int PRECISE_CALL_STATE_HOLDING = 2; // 0x2
- field public static final int PRECISE_CALL_STATE_IDLE = 0; // 0x0
- field public static final int PRECISE_CALL_STATE_INCOMING = 5; // 0x5
- field public static final int PRECISE_CALL_STATE_NOT_VALID = -1; // 0xffffffff
- field public static final int PRECISE_CALL_STATE_WAITING = 6; // 0x6
- }
-
- public final class PreciseDataConnectionState implements android.os.Parcelable {
- method @Deprecated @NonNull public String getDataConnectionApn();
- method @Deprecated public int getDataConnectionApnTypeBitMask();
- method @Deprecated public int getDataConnectionFailCause();
- method @Deprecated public int getDataConnectionState();
- method public int getId();
- }
-
- public final class PreciseDisconnectCause {
- field public static final int ACCESS_CLASS_BLOCKED = 260; // 0x104
- field public static final int ACCESS_INFORMATION_DISCARDED = 43; // 0x2b
- field public static final int ACM_LIMIT_EXCEEDED = 68; // 0x44
- field public static final int BEARER_CAPABILITY_NOT_AUTHORIZED = 57; // 0x39
- field public static final int BEARER_NOT_AVAIL = 58; // 0x3a
- field public static final int BEARER_SERVICE_NOT_IMPLEMENTED = 65; // 0x41
- field public static final int BUSY = 17; // 0x11
- field public static final int CALL_BARRED = 240; // 0xf0
- field public static final int CALL_REJECTED = 21; // 0x15
- field public static final int CDMA_ACCESS_BLOCKED = 1009; // 0x3f1
- field public static final int CDMA_ACCESS_FAILURE = 1006; // 0x3ee
- field public static final int CDMA_DROP = 1001; // 0x3e9
- field public static final int CDMA_INTERCEPT = 1002; // 0x3ea
- field public static final int CDMA_LOCKED_UNTIL_POWER_CYCLE = 1000; // 0x3e8
- field public static final int CDMA_NOT_EMERGENCY = 1008; // 0x3f0
- field public static final int CDMA_PREEMPTED = 1007; // 0x3ef
- field public static final int CDMA_REORDER = 1003; // 0x3eb
- field public static final int CDMA_RETRY_ORDER = 1005; // 0x3ed
- field public static final int CDMA_SO_REJECT = 1004; // 0x3ec
- field public static final int CHANNEL_NOT_AVAIL = 44; // 0x2c
- field public static final int CHANNEL_UNACCEPTABLE = 6; // 0x6
- field public static final int CONDITIONAL_IE_ERROR = 100; // 0x64
- field public static final int DESTINATION_OUT_OF_ORDER = 27; // 0x1b
- field public static final int ERROR_UNSPECIFIED = 65535; // 0xffff
- field public static final int FACILITY_REJECTED = 29; // 0x1d
- field public static final int FDN_BLOCKED = 241; // 0xf1
- field public static final int IMEI_NOT_ACCEPTED = 243; // 0xf3
- field public static final int IMSI_UNKNOWN_IN_VLR = 242; // 0xf2
- field public static final int INCOMING_CALLS_BARRED_WITHIN_CUG = 55; // 0x37
- field public static final int INCOMPATIBLE_DESTINATION = 88; // 0x58
- field public static final int INFORMATION_ELEMENT_NON_EXISTENT = 99; // 0x63
- field public static final int INTERWORKING_UNSPECIFIED = 127; // 0x7f
- field public static final int INVALID_MANDATORY_INFORMATION = 96; // 0x60
- field public static final int INVALID_NUMBER_FORMAT = 28; // 0x1c
- field public static final int INVALID_TRANSACTION_IDENTIFIER = 81; // 0x51
- field public static final int MESSAGE_NOT_COMPATIBLE_WITH_PROTOCOL_STATE = 101; // 0x65
- field public static final int MESSAGE_TYPE_NON_IMPLEMENTED = 97; // 0x61
- field public static final int MESSAGE_TYPE_NOT_COMPATIBLE_WITH_PROTOCOL_STATE = 98; // 0x62
- field public static final int NETWORK_DETACH = 261; // 0x105
- field public static final int NETWORK_OUT_OF_ORDER = 38; // 0x26
- field public static final int NETWORK_REJECT = 252; // 0xfc
- field public static final int NETWORK_RESP_TIMEOUT = 251; // 0xfb
- field public static final int NORMAL = 16; // 0x10
- field public static final int NORMAL_UNSPECIFIED = 31; // 0x1f
- field public static final int NOT_VALID = -1; // 0xffffffff
- field public static final int NO_ANSWER_FROM_USER = 19; // 0x13
- field public static final int NO_CIRCUIT_AVAIL = 34; // 0x22
- field public static final int NO_DISCONNECT_CAUSE_AVAILABLE = 0; // 0x0
- field public static final int NO_ROUTE_TO_DESTINATION = 3; // 0x3
- field public static final int NO_USER_RESPONDING = 18; // 0x12
- field public static final int NO_VALID_SIM = 249; // 0xf9
- field public static final int NUMBER_CHANGED = 22; // 0x16
- field public static final int OEM_CAUSE_1 = 61441; // 0xf001
- field public static final int OEM_CAUSE_10 = 61450; // 0xf00a
- field public static final int OEM_CAUSE_11 = 61451; // 0xf00b
- field public static final int OEM_CAUSE_12 = 61452; // 0xf00c
- field public static final int OEM_CAUSE_13 = 61453; // 0xf00d
- field public static final int OEM_CAUSE_14 = 61454; // 0xf00e
- field public static final int OEM_CAUSE_15 = 61455; // 0xf00f
- field public static final int OEM_CAUSE_2 = 61442; // 0xf002
- field public static final int OEM_CAUSE_3 = 61443; // 0xf003
- field public static final int OEM_CAUSE_4 = 61444; // 0xf004
- field public static final int OEM_CAUSE_5 = 61445; // 0xf005
- field public static final int OEM_CAUSE_6 = 61446; // 0xf006
- field public static final int OEM_CAUSE_7 = 61447; // 0xf007
- field public static final int OEM_CAUSE_8 = 61448; // 0xf008
- field public static final int OEM_CAUSE_9 = 61449; // 0xf009
- field public static final int ONLY_DIGITAL_INFORMATION_BEARER_AVAILABLE = 70; // 0x46
- field public static final int OPERATOR_DETERMINED_BARRING = 8; // 0x8
- field public static final int OUT_OF_SRV = 248; // 0xf8
- field public static final int PREEMPTION = 25; // 0x19
- field public static final int PROTOCOL_ERROR_UNSPECIFIED = 111; // 0x6f
- field public static final int QOS_NOT_AVAIL = 49; // 0x31
- field public static final int RADIO_ACCESS_FAILURE = 253; // 0xfd
- field public static final int RADIO_INTERNAL_ERROR = 250; // 0xfa
- field public static final int RADIO_LINK_FAILURE = 254; // 0xfe
- field public static final int RADIO_LINK_LOST = 255; // 0xff
- field public static final int RADIO_OFF = 247; // 0xf7
- field public static final int RADIO_RELEASE_ABNORMAL = 259; // 0x103
- field public static final int RADIO_RELEASE_NORMAL = 258; // 0x102
- field public static final int RADIO_SETUP_FAILURE = 257; // 0x101
- field public static final int RADIO_UPLINK_FAILURE = 256; // 0x100
- field public static final int RECOVERY_ON_TIMER_EXPIRED = 102; // 0x66
- field public static final int REQUESTED_FACILITY_NOT_IMPLEMENTED = 69; // 0x45
- field public static final int REQUESTED_FACILITY_NOT_SUBSCRIBED = 50; // 0x32
- field public static final int RESOURCES_UNAVAILABLE_OR_UNSPECIFIED = 47; // 0x2f
- field public static final int SEMANTICALLY_INCORRECT_MESSAGE = 95; // 0x5f
- field public static final int SERVICE_OPTION_NOT_AVAILABLE = 63; // 0x3f
- field public static final int SERVICE_OR_OPTION_NOT_IMPLEMENTED = 79; // 0x4f
- field public static final int STATUS_ENQUIRY = 30; // 0x1e
- field public static final int SWITCHING_CONGESTION = 42; // 0x2a
- field public static final int TEMPORARY_FAILURE = 41; // 0x29
- field public static final int UNOBTAINABLE_NUMBER = 1; // 0x1
- field public static final int USER_NOT_MEMBER_OF_CUG = 87; // 0x57
- }
-
- public class ServiceState implements android.os.Parcelable {
- method @Nullable public android.telephony.NetworkRegistrationInfo getNetworkRegistrationInfo(int, int);
- method @NonNull public java.util.List<android.telephony.NetworkRegistrationInfo> getNetworkRegistrationInfoListForDomain(int);
- method @NonNull public java.util.List<android.telephony.NetworkRegistrationInfo> getNetworkRegistrationInfoListForTransportType(int);
- field public static final int ROAMING_TYPE_DOMESTIC = 2; // 0x2
- field public static final int ROAMING_TYPE_INTERNATIONAL = 3; // 0x3
- field public static final int ROAMING_TYPE_NOT_ROAMING = 0; // 0x0
- field public static final int ROAMING_TYPE_UNKNOWN = 1; // 0x1
- }
-
- public final class SmsCbCmasInfo implements android.os.Parcelable {
- ctor public SmsCbCmasInfo(int, int, int, int, int, int);
- method public int describeContents();
- method public int getCategory();
- method public int getCertainty();
- method public int getMessageClass();
- method public int getResponseType();
- method public int getSeverity();
- method public int getUrgency();
- method public void writeToParcel(android.os.Parcel, int);
- field public static final int CMAS_CATEGORY_CBRNE = 10; // 0xa
- field public static final int CMAS_CATEGORY_ENV = 7; // 0x7
- field public static final int CMAS_CATEGORY_FIRE = 5; // 0x5
- field public static final int CMAS_CATEGORY_GEO = 0; // 0x0
- field public static final int CMAS_CATEGORY_HEALTH = 6; // 0x6
- field public static final int CMAS_CATEGORY_INFRA = 9; // 0x9
- field public static final int CMAS_CATEGORY_MET = 1; // 0x1
- field public static final int CMAS_CATEGORY_OTHER = 11; // 0xb
- field public static final int CMAS_CATEGORY_RESCUE = 4; // 0x4
- field public static final int CMAS_CATEGORY_SAFETY = 2; // 0x2
- field public static final int CMAS_CATEGORY_SECURITY = 3; // 0x3
- field public static final int CMAS_CATEGORY_TRANSPORT = 8; // 0x8
- field public static final int CMAS_CATEGORY_UNKNOWN = -1; // 0xffffffff
- field public static final int CMAS_CERTAINTY_LIKELY = 1; // 0x1
- field public static final int CMAS_CERTAINTY_OBSERVED = 0; // 0x0
- field public static final int CMAS_CERTAINTY_UNKNOWN = -1; // 0xffffffff
- field public static final int CMAS_CLASS_CHILD_ABDUCTION_EMERGENCY = 3; // 0x3
- field public static final int CMAS_CLASS_CMAS_EXERCISE = 5; // 0x5
- field public static final int CMAS_CLASS_EXTREME_THREAT = 1; // 0x1
- field public static final int CMAS_CLASS_OPERATOR_DEFINED_USE = 6; // 0x6
- field public static final int CMAS_CLASS_PRESIDENTIAL_LEVEL_ALERT = 0; // 0x0
- field public static final int CMAS_CLASS_REQUIRED_MONTHLY_TEST = 4; // 0x4
- field public static final int CMAS_CLASS_SEVERE_THREAT = 2; // 0x2
- field public static final int CMAS_CLASS_UNKNOWN = -1; // 0xffffffff
- field public static final int CMAS_RESPONSE_TYPE_ASSESS = 6; // 0x6
- field public static final int CMAS_RESPONSE_TYPE_AVOID = 5; // 0x5
- field public static final int CMAS_RESPONSE_TYPE_EVACUATE = 1; // 0x1
- field public static final int CMAS_RESPONSE_TYPE_EXECUTE = 3; // 0x3
- field public static final int CMAS_RESPONSE_TYPE_MONITOR = 4; // 0x4
- field public static final int CMAS_RESPONSE_TYPE_NONE = 7; // 0x7
- field public static final int CMAS_RESPONSE_TYPE_PREPARE = 2; // 0x2
- field public static final int CMAS_RESPONSE_TYPE_SHELTER = 0; // 0x0
- field public static final int CMAS_RESPONSE_TYPE_UNKNOWN = -1; // 0xffffffff
- field public static final int CMAS_SEVERITY_EXTREME = 0; // 0x0
- field public static final int CMAS_SEVERITY_SEVERE = 1; // 0x1
- field public static final int CMAS_SEVERITY_UNKNOWN = -1; // 0xffffffff
- field public static final int CMAS_URGENCY_EXPECTED = 1; // 0x1
- field public static final int CMAS_URGENCY_IMMEDIATE = 0; // 0x0
- field public static final int CMAS_URGENCY_UNKNOWN = -1; // 0xffffffff
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.SmsCbCmasInfo> CREATOR;
- }
-
- public final class SmsCbEtwsInfo implements android.os.Parcelable {
- ctor public SmsCbEtwsInfo(int, boolean, boolean, boolean, @Nullable byte[]);
- method public int describeContents();
- method @Nullable public byte[] getPrimaryNotificationSignature();
- method public long getPrimaryNotificationTimestamp();
- method public int getWarningType();
- method public boolean isEmergencyUserAlert();
- method public boolean isPopupAlert();
- method public boolean isPrimary();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.SmsCbEtwsInfo> CREATOR;
- field public static final int ETWS_WARNING_TYPE_EARTHQUAKE = 0; // 0x0
- field public static final int ETWS_WARNING_TYPE_EARTHQUAKE_AND_TSUNAMI = 2; // 0x2
- field public static final int ETWS_WARNING_TYPE_OTHER_EMERGENCY = 4; // 0x4
- field public static final int ETWS_WARNING_TYPE_TEST_MESSAGE = 3; // 0x3
- field public static final int ETWS_WARNING_TYPE_TSUNAMI = 1; // 0x1
- field public static final int ETWS_WARNING_TYPE_UNKNOWN = -1; // 0xffffffff
- }
-
- public final class SmsCbLocation implements android.os.Parcelable {
- ctor public SmsCbLocation(@NonNull String, int, int);
- method public int describeContents();
- method public int getCid();
- method public int getLac();
- method @NonNull public String getPlmn();
- method public boolean isInLocationArea(@NonNull android.telephony.SmsCbLocation);
- method public boolean isInLocationArea(@Nullable String, int, int);
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.SmsCbLocation> CREATOR;
- }
-
- public final class SmsCbMessage implements android.os.Parcelable {
- ctor public SmsCbMessage(int, int, int, @NonNull android.telephony.SmsCbLocation, int, @Nullable String, int, @Nullable String, int, @Nullable android.telephony.SmsCbEtwsInfo, @Nullable android.telephony.SmsCbCmasInfo, int, @Nullable java.util.List<android.telephony.CbGeoUtils.Geometry>, long, int, int);
- method @NonNull public static android.telephony.SmsCbMessage createFromCursor(@NonNull android.database.Cursor);
- method public int describeContents();
- method @Nullable public android.telephony.SmsCbCmasInfo getCmasWarningInfo();
- method @NonNull public android.content.ContentValues getContentValues();
- method public int getDataCodingScheme();
- method @Nullable public android.telephony.SmsCbEtwsInfo getEtwsWarningInfo();
- method public int getGeographicalScope();
- method @NonNull public java.util.List<android.telephony.CbGeoUtils.Geometry> getGeometries();
- method @Nullable public String getLanguageCode();
- method @NonNull public android.telephony.SmsCbLocation getLocation();
- method public int getMaximumWaitingDuration();
- method @Nullable public String getMessageBody();
- method public int getMessageFormat();
- method public int getMessagePriority();
- method public long getReceivedTime();
- method public int getSerialNumber();
- method public int getServiceCategory();
- method public int getSlotIndex();
- method public int getSubscriptionId();
- method public boolean isCmasMessage();
- method public boolean isEmergencyMessage();
- method public boolean isEtwsMessage();
- method public boolean needGeoFencingCheck();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.SmsCbMessage> CREATOR;
- field public static final int GEOGRAPHICAL_SCOPE_CELL_WIDE = 3; // 0x3
- field public static final int GEOGRAPHICAL_SCOPE_CELL_WIDE_IMMEDIATE = 0; // 0x0
- field public static final int GEOGRAPHICAL_SCOPE_LOCATION_AREA_WIDE = 2; // 0x2
- field public static final int GEOGRAPHICAL_SCOPE_PLMN_WIDE = 1; // 0x1
- field public static final int MAXIMUM_WAIT_TIME_NOT_SET = 255; // 0xff
- field public static final int MESSAGE_FORMAT_3GPP = 1; // 0x1
- field public static final int MESSAGE_FORMAT_3GPP2 = 2; // 0x2
- field public static final int MESSAGE_PRIORITY_EMERGENCY = 3; // 0x3
- field public static final int MESSAGE_PRIORITY_INTERACTIVE = 1; // 0x1
- field public static final int MESSAGE_PRIORITY_NORMAL = 0; // 0x0
- field public static final int MESSAGE_PRIORITY_URGENT = 2; // 0x2
- }
-
- public final class SmsManager {
- method public boolean disableCellBroadcastRange(int, int, int);
- method public boolean enableCellBroadcastRange(int, int, int);
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public int getPremiumSmsConsent(@NonNull String);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void sendMultipartTextMessageWithoutPersisting(String, String, java.util.List<java.lang.String>, java.util.List<android.app.PendingIntent>, java.util.List<android.app.PendingIntent>);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void setPremiumSmsConsent(@NonNull String, int);
- field public static final int PREMIUM_SMS_CONSENT_ALWAYS_ALLOW = 3; // 0x3
- field public static final int PREMIUM_SMS_CONSENT_ASK_USER = 1; // 0x1
- field public static final int PREMIUM_SMS_CONSENT_NEVER_ALLOW = 2; // 0x2
- field public static final int PREMIUM_SMS_CONSENT_UNKNOWN = 0; // 0x0
- }
-
- public class SmsMessage {
- method @Nullable public static android.telephony.SmsMessage createFromNativeSmsSubmitPdu(@NonNull byte[], boolean);
- method @Nullable public static android.telephony.SmsMessage.SubmitPdu getSmsPdu(int, int, @Nullable String, @NonNull String, @NonNull String, long);
- method @NonNull @RequiresPermission(android.Manifest.permission.BLUETOOTH_PRIVILEGED) public static byte[] getSubmitPduEncodedMessage(boolean, @NonNull String, @NonNull String, int, @IntRange(from=0) int, @IntRange(from=0) int, @IntRange(from=0, to=255) int, @IntRange(from=1, to=255) int, @IntRange(from=1, to=255) int);
- }
-
- public class SubscriptionInfo implements android.os.Parcelable {
- method public boolean areUiccApplicationsEnabled();
- method @Nullable public java.util.List<android.telephony.UiccAccessRule> getAccessRules();
- method public int getProfileClass();
- method public boolean isGroupDisabled();
- }
-
- public class SubscriptionManager {
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public boolean canDisablePhysicalSubscription();
- method public boolean canManageSubscription(@NonNull android.telephony.SubscriptionInfo, @NonNull String);
- method @NonNull @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public int[] getActiveSubscriptionIdList();
- method @Nullable @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public android.telephony.SubscriptionInfo getActiveSubscriptionInfoForIcc(@NonNull String);
- method public java.util.List<android.telephony.SubscriptionInfo> getAvailableSubscriptionInfoList();
- method @NonNull @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public int[] getCompleteActiveSubscriptionIdList();
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public int getEnabledSubscriptionId(int);
- method @NonNull public static android.content.res.Resources getResourcesForSubId(@NonNull android.content.Context, int);
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public boolean isSubscriptionEnabled(int);
- method public void requestEmbeddedSubscriptionInfoListRefresh();
- method public void requestEmbeddedSubscriptionInfoListRefresh(int);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void setDefaultDataSubId(int);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void setDefaultSmsSubId(int);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void setDefaultVoiceSubscriptionId(int);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void setPreferredDataSubscriptionId(int, boolean, @Nullable java.util.concurrent.Executor, @Nullable java.util.function.Consumer<java.lang.Integer>);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public boolean setSubscriptionEnabled(int, boolean);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void setUiccApplicationsEnabled(int, boolean);
- field @RequiresPermission(android.Manifest.permission.MANAGE_SUBSCRIPTION_PLANS) public static final String ACTION_SUBSCRIPTION_PLANS_CHANGED = "android.telephony.action.SUBSCRIPTION_PLANS_CHANGED";
- field @NonNull public static final android.net.Uri ADVANCED_CALLING_ENABLED_CONTENT_URI;
- field @Deprecated public static final int PROFILE_CLASS_DEFAULT = -1; // 0xffffffff
- field public static final int PROFILE_CLASS_OPERATIONAL = 2; // 0x2
- field public static final int PROFILE_CLASS_PROVISIONING = 1; // 0x1
- field public static final int PROFILE_CLASS_TESTING = 0; // 0x0
- field public static final int PROFILE_CLASS_UNSET = -1; // 0xffffffff
- field @NonNull public static final android.net.Uri VT_ENABLED_CONTENT_URI;
- field @NonNull public static final android.net.Uri WFC_ENABLED_CONTENT_URI;
- field @NonNull public static final android.net.Uri WFC_MODE_CONTENT_URI;
- field @NonNull public static final android.net.Uri WFC_ROAMING_ENABLED_CONTENT_URI;
- field @NonNull public static final android.net.Uri WFC_ROAMING_MODE_CONTENT_URI;
- }
-
- public static class SubscriptionPlan.Builder {
- method @Deprecated public static android.telephony.SubscriptionPlan.Builder createRecurringDaily(java.time.ZonedDateTime);
- method @Deprecated public static android.telephony.SubscriptionPlan.Builder createRecurringMonthly(java.time.ZonedDateTime);
- method @Deprecated public static android.telephony.SubscriptionPlan.Builder createRecurringWeekly(java.time.ZonedDateTime);
- }
-
- public final class TelephonyHistogram implements android.os.Parcelable {
- ctor public TelephonyHistogram(int, int, int);
- ctor public TelephonyHistogram(android.telephony.TelephonyHistogram);
- ctor public TelephonyHistogram(android.os.Parcel);
- method public void addTimeTaken(int);
- method public int describeContents();
- method public int getAverageTime();
- method public int getBucketCount();
- method public int[] getBucketCounters();
- method public int[] getBucketEndPoints();
- method public int getCategory();
- method public int getId();
- method public int getMaxTime();
- method public int getMinTime();
- method public int getSampleCount();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.TelephonyHistogram> CREATOR;
- field public static final int TELEPHONY_CATEGORY_RIL = 1; // 0x1
- }
-
- public class TelephonyManager {
- method @Deprecated @RequiresPermission(android.Manifest.permission.CALL_PHONE) public void call(String, String);
- method @NonNull @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public android.telephony.PinResult changeIccLockPin(@NonNull String, @NonNull String);
- method public int checkCarrierPrivilegesForPackage(String);
- method public int checkCarrierPrivilegesForPackageAnyPhone(String);
- method public void dial(String);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public boolean disableDataConnectivity();
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public boolean enableDataConnectivity();
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public boolean enableModemForSlot(int, boolean);
- method @Deprecated @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void enableVideoCalling(boolean);
- method @Nullable @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public String getAidForAppType(int);
- method @Deprecated @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public java.util.List<android.service.carrier.CarrierIdentifier> getAllowedCarriers(int);
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public long getAllowedNetworkTypes();
- method @Nullable @RequiresPermission(android.Manifest.permission.INTERACT_ACROSS_USERS) public android.content.ComponentName getAndUpdateDefaultRespondViaMessageApplication();
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public void getCallForwarding(int, @NonNull java.util.concurrent.Executor, @NonNull android.telephony.TelephonyManager.CallForwardingInfoCallback);
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public void getCallWaitingStatus(@NonNull java.util.concurrent.Executor, @NonNull java.util.function.Consumer<java.lang.Integer>);
- method @NonNull @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public android.telephony.CarrierBandwidth getCarrierBandwidth();
- method @Nullable @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public android.telephony.ImsiEncryptionInfo getCarrierInfoForImsiEncryption(int);
- method public java.util.List<java.lang.String> getCarrierPackageNamesForIntent(android.content.Intent);
- method public java.util.List<java.lang.String> getCarrierPackageNamesForIntentAndPhone(android.content.Intent, int);
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public int getCarrierPrivilegeStatus(int);
- method @NonNull @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public java.util.List<java.lang.String> getCarrierPrivilegedPackagesForAllActiveSubscriptions();
- method @Nullable @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public android.telephony.CarrierRestrictionRules getCarrierRestrictionRules();
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public int getCdmaEnhancedRoamingIndicatorDisplayNumber();
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public String getCdmaMdn();
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public String getCdmaMdn(int);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public String getCdmaMin();
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public String getCdmaMin(int);
- method public String getCdmaPrlVersion();
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public int getCdmaRoamingMode();
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public int getCdmaSubscriptionMode();
- method public int getCurrentPhoneType();
- method public int getCurrentPhoneType(int);
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public int getDataActivationState();
- method @Deprecated public boolean getDataEnabled();
- method @Deprecated public boolean getDataEnabled(int);
- method @Nullable @RequiresPermission(android.Manifest.permission.INTERACT_ACROSS_USERS) public android.content.ComponentName getDefaultRespondViaMessageApplication();
- method @Nullable @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public String getDeviceSoftwareVersion(int);
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public boolean getEmergencyCallbackMode();
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public int getEmergencyNumberDbVersion();
- method @Nullable @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public String getIsimDomain();
- method @Nullable @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public String getIsimIst();
- method @NonNull @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public java.util.Map<java.lang.Integer,java.lang.Integer> getLogicalToPhysicalSlotMapping();
- method public int getMaxNumberOfSimultaneouslyActiveSims();
- method public static long getMaxNumberVerificationTimeoutMillis();
- method @NonNull @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public String[] getMergedImsisFromGroup();
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public long getPreferredNetworkTypeBitmask();
- method @RequiresPermission(anyOf={android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE, android.Manifest.permission.READ_PHONE_STATE}) public int getRadioPowerState();
- method public int getSimApplicationState();
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public int getSimApplicationState(int);
- method public int getSimCardState();
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public int getSimCardState(int);
- method @Nullable @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public java.util.Locale getSimLocale();
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public long getSupportedRadioAccessFamily();
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public java.util.List<android.telephony.TelephonyHistogram> getTelephonyHistograms();
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public android.telephony.UiccSlotInfo[] getUiccSlotsInfo();
- method @Nullable public android.os.Bundle getVisualVoicemailSettings();
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public int getVoiceActivationState();
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public boolean handlePinMmi(String);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public boolean handlePinMmiForSubscriber(int, String);
- method @Deprecated @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public boolean iccCloseLogicalChannelBySlot(int, int);
- method @Nullable @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public android.telephony.IccOpenLogicalChannelResponse iccOpenLogicalChannelBySlot(int, @Nullable String, int);
- method @Deprecated @NonNull @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public String iccTransmitApduBasicChannelBySlot(int, int, int, int, int, int, @Nullable String);
- method @Deprecated @Nullable @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public String iccTransmitApduLogicalChannelBySlot(int, int, int, int, int, int, int, @Nullable String);
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public boolean isAnyRadioPoweredOn();
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public boolean isApnMetered(int);
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public boolean isApplicationOnUicc(int);
- method public boolean isDataConnectivityPossible();
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public boolean isDataEnabledForApn(int);
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public boolean isEmergencyAssistanceEnabled();
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) @WorkerThread public boolean isIccLockEnabled();
- method @Deprecated @RequiresPermission(anyOf={android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE, android.Manifest.permission.READ_PHONE_STATE}) public boolean isIdle();
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public boolean isLteCdmaEvdoGsmWcdmaEnabled();
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public boolean isMobileDataPolicyEnabled(int);
- method public boolean isNrDualConnectivityEnabled();
- method @Deprecated @RequiresPermission(anyOf={android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE, android.Manifest.permission.READ_PHONE_STATE}) public boolean isOffhook();
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public boolean isOpportunisticNetworkEnabled();
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public boolean isPotentialEmergencyNumber(@NonNull String);
- method @Deprecated @RequiresPermission(anyOf={android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE, android.Manifest.permission.READ_PHONE_STATE}) public boolean isRadioOn();
- method @Deprecated @RequiresPermission(anyOf={android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE, android.Manifest.permission.READ_PHONE_STATE}) public boolean isRinging();
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public boolean isTetheringApnRequired();
- method @Deprecated @RequiresPermission(anyOf={android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE, android.Manifest.permission.READ_PHONE_STATE}) public boolean isVideoCallingEnabled();
- method @Deprecated @RequiresPermission(android.Manifest.permission.READ_PHONE_STATE) public boolean isVisualVoicemailEnabled(android.telecom.PhoneAccountHandle);
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public boolean matchesCurrentSimOperator(@NonNull String, int, @Nullable String);
- method public boolean needsOtaServiceProvisioning();
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void notifyOtaEmergencyNumberDbInstalled();
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public boolean rebootRadio();
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void reportDefaultNetworkStatus(boolean);
- method @RequiresPermission(allOf={android.Manifest.permission.ACCESS_FINE_LOCATION, android.Manifest.permission.MODIFY_PHONE_STATE}) public void requestCellInfoUpdate(@NonNull android.os.WorkSource, @NonNull java.util.concurrent.Executor, @NonNull android.telephony.TelephonyManager.CellInfoCallback);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void requestModemActivityInfo(@NonNull java.util.concurrent.Executor, @NonNull android.os.OutcomeReceiver<android.telephony.ModemActivityInfo,android.telephony.TelephonyManager.ModemActivityInfoException>);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void requestNumberVerification(@NonNull android.telephony.PhoneNumberRange, long, @NonNull java.util.concurrent.Executor, @NonNull android.telephony.NumberVerificationCallback);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void resetAllCarrierActions();
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void resetCarrierKeysForImsiEncryption();
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) @WorkerThread public void resetIms(int);
- method @RequiresPermission(android.Manifest.permission.READ_ACTIVE_EMERGENCY_SESSION) public void resetOtaEmergencyNumberDbFilePath();
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public boolean resetRadioConfig();
- method @RequiresPermission(android.Manifest.permission.CONNECTIVITY_INTERNAL) public void resetSettings();
- method @Deprecated @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public int setAllowedCarriers(int, java.util.List<android.service.carrier.CarrierIdentifier>);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public boolean setAllowedNetworkTypes(long);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void setCallForwarding(@NonNull android.telephony.CallForwardingInfo, @Nullable java.util.concurrent.Executor, @Nullable java.util.function.Consumer<java.lang.Integer>);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void setCallWaitingEnabled(boolean, @Nullable java.util.concurrent.Executor, @Nullable java.util.function.Consumer<java.lang.Integer>);
- method @Deprecated @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void setCarrierDataEnabled(boolean);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public int setCarrierRestrictionRules(@NonNull android.telephony.CarrierRestrictionRules);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void setCdmaRoamingMode(int);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void setCdmaSubscriptionMode(int);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void setDataActivationState(int);
- method @Deprecated @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void setDataEnabled(int, boolean);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void setDataRoamingEnabled(boolean);
- method @NonNull @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public android.telephony.PinResult setIccLockEnabled(boolean, @NonNull String);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void setMobileDataPolicyEnabledStatus(int, boolean);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void setMultiSimCarrierRestriction(boolean);
- method public int setNrDualConnectivityState(int);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public boolean setOpportunisticNetworkState(boolean);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public boolean setPreferredNetworkTypeBitmask(long);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public boolean setRadio(boolean);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void setRadioEnabled(boolean);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public boolean setRadioPower(boolean);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void setSimPowerState(int);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void setSimPowerStateForSlot(int, int);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void setSystemSelectionChannels(@NonNull java.util.List<android.telephony.RadioAccessSpecifier>, @NonNull java.util.concurrent.Executor, @NonNull java.util.function.Consumer<java.lang.Boolean>);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void setSystemSelectionChannels(@NonNull java.util.List<android.telephony.RadioAccessSpecifier>);
- method @Deprecated public void setVisualVoicemailEnabled(android.telecom.PhoneAccountHandle, boolean);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void setVoiceActivationState(int);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void shutdownAllRadios();
- method @NonNull @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public android.telephony.PinResult supplyIccLockPin(@NonNull String);
- method @NonNull @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public android.telephony.PinResult supplyIccLockPuk(@NonNull String, @NonNull String);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public boolean supplyPin(String);
- method @Deprecated @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public int[] supplyPinReportResult(String);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public boolean supplyPuk(String, String);
- method @Deprecated @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public int[] supplyPukReportResult(String, String);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public boolean switchSlots(int[]);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void toggleRadioOnOff();
- method @RequiresPermission(android.Manifest.permission.READ_ACTIVE_EMERGENCY_SESSION) public void updateOtaEmergencyNumberDbFilePath(@NonNull android.os.ParcelFileDescriptor);
- method public void updateServiceLocation();
- field @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public static final String ACTION_ANOMALY_REPORTED = "android.telephony.action.ANOMALY_REPORTED";
- field public static final String ACTION_DEFAULT_DATA_SUBSCRIPTION_CHANGED = "android.intent.action.ACTION_DEFAULT_DATA_SUBSCRIPTION_CHANGED";
- field public static final String ACTION_DEFAULT_VOICE_SUBSCRIPTION_CHANGED = "android.intent.action.ACTION_DEFAULT_VOICE_SUBSCRIPTION_CHANGED";
- field public static final String ACTION_EMERGENCY_ASSISTANCE = "android.telephony.action.EMERGENCY_ASSISTANCE";
- field public static final String ACTION_EMERGENCY_CALLBACK_MODE_CHANGED = "android.intent.action.EMERGENCY_CALLBACK_MODE_CHANGED";
- field public static final String ACTION_EMERGENCY_CALL_STATE_CHANGED = "android.intent.action.EMERGENCY_CALL_STATE_CHANGED";
- field public static final String ACTION_REQUEST_OMADM_CONFIGURATION_UPDATE = "com.android.omadm.service.CONFIGURATION_UPDATE";
- field public static final String ACTION_SHOW_NOTICE_ECM_BLOCK_OTHERS = "android.telephony.action.SHOW_NOTICE_ECM_BLOCK_OTHERS";
- field public static final String ACTION_SIM_APPLICATION_STATE_CHANGED = "android.telephony.action.SIM_APPLICATION_STATE_CHANGED";
- field public static final String ACTION_SIM_CARD_STATE_CHANGED = "android.telephony.action.SIM_CARD_STATE_CHANGED";
- field public static final String ACTION_SIM_SLOT_STATUS_CHANGED = "android.telephony.action.SIM_SLOT_STATUS_CHANGED";
- field public static final int CALL_WAITING_STATUS_DISABLED = 2; // 0x2
- field public static final int CALL_WAITING_STATUS_ENABLED = 1; // 0x1
- field public static final int CALL_WAITING_STATUS_NOT_SUPPORTED = 4; // 0x4
- field public static final int CALL_WAITING_STATUS_UNKNOWN_ERROR = 3; // 0x3
- field public static final int CARRIER_PRIVILEGE_STATUS_ERROR_LOADING_RULES = -2; // 0xfffffffe
- field public static final int CARRIER_PRIVILEGE_STATUS_HAS_ACCESS = 1; // 0x1
- field public static final int CARRIER_PRIVILEGE_STATUS_NO_ACCESS = 0; // 0x0
- field public static final int CARRIER_PRIVILEGE_STATUS_RULES_NOT_LOADED = -1; // 0xffffffff
- field public static final int CDMA_SUBSCRIPTION_NV = 1; // 0x1
- field public static final int CDMA_SUBSCRIPTION_RUIM_SIM = 0; // 0x0
- field public static final int CDMA_SUBSCRIPTION_UNKNOWN = -1; // 0xffffffff
- field public static final int ENABLE_NR_DUAL_CONNECTIVITY_INVALID_STATE = 4; // 0x4
- field public static final int ENABLE_NR_DUAL_CONNECTIVITY_NOT_SUPPORTED = 1; // 0x1
- field public static final int ENABLE_NR_DUAL_CONNECTIVITY_RADIO_ERROR = 3; // 0x3
- field public static final int ENABLE_NR_DUAL_CONNECTIVITY_RADIO_NOT_AVAILABLE = 2; // 0x2
- field public static final int ENABLE_NR_DUAL_CONNECTIVITY_SUCCESS = 0; // 0x0
- field public static final String EXTRA_ANOMALY_DESCRIPTION = "android.telephony.extra.ANOMALY_DESCRIPTION";
- field public static final String EXTRA_ANOMALY_ID = "android.telephony.extra.ANOMALY_ID";
- field public static final String EXTRA_PHONE_IN_ECM_STATE = "android.telephony.extra.PHONE_IN_ECM_STATE";
- field public static final String EXTRA_PHONE_IN_EMERGENCY_CALL = "android.telephony.extra.PHONE_IN_EMERGENCY_CALL";
- field public static final String EXTRA_SIM_STATE = "android.telephony.extra.SIM_STATE";
- field public static final String EXTRA_VISUAL_VOICEMAIL_ENABLED_BY_USER_BOOL = "android.telephony.extra.VISUAL_VOICEMAIL_ENABLED_BY_USER_BOOL";
- field public static final String EXTRA_VOICEMAIL_SCRAMBLED_PIN_STRING = "android.telephony.extra.VOICEMAIL_SCRAMBLED_PIN_STRING";
- field public static final int INVALID_EMERGENCY_NUMBER_DB_VERSION = -1; // 0xffffffff
- field public static final int KEY_TYPE_EPDG = 1; // 0x1
- field public static final int KEY_TYPE_WLAN = 2; // 0x2
- field public static final int MOBILE_DATA_POLICY_DATA_ON_NON_DEFAULT_DURING_VOICE_CALL = 1; // 0x1
- field public static final int MOBILE_DATA_POLICY_MMS_ALWAYS_ALLOWED = 2; // 0x2
- field public static final long NETWORK_TYPE_BITMASK_1xRTT = 64L; // 0x40L
- field public static final long NETWORK_TYPE_BITMASK_CDMA = 8L; // 0x8L
- field public static final long NETWORK_TYPE_BITMASK_EDGE = 2L; // 0x2L
- field public static final long NETWORK_TYPE_BITMASK_EHRPD = 8192L; // 0x2000L
- field public static final long NETWORK_TYPE_BITMASK_EVDO_0 = 16L; // 0x10L
- field public static final long NETWORK_TYPE_BITMASK_EVDO_A = 32L; // 0x20L
- field public static final long NETWORK_TYPE_BITMASK_EVDO_B = 2048L; // 0x800L
- field public static final long NETWORK_TYPE_BITMASK_GPRS = 1L; // 0x1L
- field public static final long NETWORK_TYPE_BITMASK_GSM = 32768L; // 0x8000L
- field public static final long NETWORK_TYPE_BITMASK_HSDPA = 128L; // 0x80L
- field public static final long NETWORK_TYPE_BITMASK_HSPA = 512L; // 0x200L
- field public static final long NETWORK_TYPE_BITMASK_HSPAP = 16384L; // 0x4000L
- field public static final long NETWORK_TYPE_BITMASK_HSUPA = 256L; // 0x100L
- field public static final long NETWORK_TYPE_BITMASK_IWLAN = 131072L; // 0x20000L
- field public static final long NETWORK_TYPE_BITMASK_LTE = 4096L; // 0x1000L
- field public static final long NETWORK_TYPE_BITMASK_LTE_CA = 262144L; // 0x40000L
- field public static final long NETWORK_TYPE_BITMASK_NR = 524288L; // 0x80000L
- field public static final long NETWORK_TYPE_BITMASK_TD_SCDMA = 65536L; // 0x10000L
- field public static final long NETWORK_TYPE_BITMASK_UMTS = 4L; // 0x4L
- field public static final long NETWORK_TYPE_BITMASK_UNKNOWN = 0L; // 0x0L
- field public static final int NR_DUAL_CONNECTIVITY_DISABLE = 2; // 0x2
- field public static final int NR_DUAL_CONNECTIVITY_DISABLE_IMMEDIATE = 3; // 0x3
- field public static final int NR_DUAL_CONNECTIVITY_ENABLE = 1; // 0x1
- field public static final int RADIO_POWER_OFF = 0; // 0x0
- field public static final int RADIO_POWER_ON = 1; // 0x1
- field public static final int RADIO_POWER_UNAVAILABLE = 2; // 0x2
- field public static final int SET_CARRIER_RESTRICTION_ERROR = 2; // 0x2
- field public static final int SET_CARRIER_RESTRICTION_NOT_SUPPORTED = 1; // 0x1
- field public static final int SET_CARRIER_RESTRICTION_SUCCESS = 0; // 0x0
- field public static final int SIM_ACTIVATION_STATE_ACTIVATED = 2; // 0x2
- field public static final int SIM_ACTIVATION_STATE_ACTIVATING = 1; // 0x1
- field public static final int SIM_ACTIVATION_STATE_DEACTIVATED = 3; // 0x3
- field public static final int SIM_ACTIVATION_STATE_RESTRICTED = 4; // 0x4
- field public static final int SIM_ACTIVATION_STATE_UNKNOWN = 0; // 0x0
- field public static final int SIM_STATE_LOADED = 10; // 0xa
- field public static final int SIM_STATE_PRESENT = 11; // 0xb
- field public static final int SRVCC_STATE_HANDOVER_CANCELED = 3; // 0x3
- field public static final int SRVCC_STATE_HANDOVER_COMPLETED = 1; // 0x1
- field public static final int SRVCC_STATE_HANDOVER_FAILED = 2; // 0x2
- field public static final int SRVCC_STATE_HANDOVER_NONE = -1; // 0xffffffff
- field public static final int SRVCC_STATE_HANDOVER_STARTED = 0; // 0x0
- }
-
- public static interface TelephonyManager.CallForwardingInfoCallback {
- method public void onCallForwardingInfoAvailable(@NonNull android.telephony.CallForwardingInfo);
- method public void onError(int);
- field public static final int RESULT_ERROR_FDN_CHECK_FAILURE = 2; // 0x2
- field public static final int RESULT_ERROR_NOT_SUPPORTED = 3; // 0x3
- field public static final int RESULT_ERROR_UNKNOWN = 1; // 0x1
- field public static final int RESULT_SUCCESS = 0; // 0x0
- }
-
- public static class TelephonyManager.ModemActivityInfoException extends java.lang.Exception {
- method public int getErrorCode();
- field public static final int ERROR_INVALID_INFO_RECEIVED = 2; // 0x2
- field public static final int ERROR_MODEM_RESPONSE_ERROR = 3; // 0x3
- field public static final int ERROR_PHONE_NOT_AVAILABLE = 1; // 0x1
- field public static final int ERROR_UNKNOWN = 0; // 0x0
- }
-
- public final class UiccAccessRule implements android.os.Parcelable {
- ctor public UiccAccessRule(byte[], @Nullable String, long);
- method public int describeContents();
- method public int getCarrierPrivilegeStatus(android.content.pm.PackageInfo);
- method public int getCarrierPrivilegeStatus(android.content.pm.Signature, String);
- method public String getCertificateHexString();
- method @Nullable public String getPackageName();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.UiccAccessRule> CREATOR;
- }
-
- public class UiccSlotInfo implements android.os.Parcelable {
- ctor @Deprecated public UiccSlotInfo(boolean, boolean, String, int, int, boolean);
- method public int describeContents();
- method public String getCardId();
- method public int getCardStateInfo();
- method public boolean getIsActive();
- method public boolean getIsEuicc();
- method public boolean getIsExtendedApduSupported();
- method public int getLogicalSlotIdx();
- method public boolean isRemovable();
- method public void writeToParcel(android.os.Parcel, int);
- field public static final int CARD_STATE_INFO_ABSENT = 1; // 0x1
- field public static final int CARD_STATE_INFO_ERROR = 3; // 0x3
- field public static final int CARD_STATE_INFO_PRESENT = 2; // 0x2
- field public static final int CARD_STATE_INFO_RESTRICTED = 4; // 0x4
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.UiccSlotInfo> CREATOR;
- }
-
- public abstract class VisualVoicemailService extends android.app.Service {
- method public static final void sendVisualVoicemailSms(android.content.Context, android.telecom.PhoneAccountHandle, String, short, String, android.app.PendingIntent);
- method public static final void setSmsFilterSettings(android.content.Context, android.telecom.PhoneAccountHandle, android.telephony.VisualVoicemailSmsFilterSettings);
- }
-
-}
-
-package android.telephony.cdma {
-
- public final class CdmaSmsCbProgramData implements android.os.Parcelable {
- method public int describeContents();
- method public int getCategory();
- method public int getOperation();
- method public void writeToParcel(android.os.Parcel, int);
- field public static final int CATEGORY_CMAS_CHILD_ABDUCTION_EMERGENCY = 4099; // 0x1003
- field public static final int CATEGORY_CMAS_EXTREME_THREAT = 4097; // 0x1001
- field public static final int CATEGORY_CMAS_LAST_RESERVED_VALUE = 4351; // 0x10ff
- field public static final int CATEGORY_CMAS_PRESIDENTIAL_LEVEL_ALERT = 4096; // 0x1000
- field public static final int CATEGORY_CMAS_SEVERE_THREAT = 4098; // 0x1002
- field public static final int CATEGORY_CMAS_TEST_MESSAGE = 4100; // 0x1004
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.cdma.CdmaSmsCbProgramData> CREATOR;
- field public static final int OPERATION_ADD_CATEGORY = 1; // 0x1
- field public static final int OPERATION_CLEAR_CATEGORIES = 2; // 0x2
- field public static final int OPERATION_DELETE_CATEGORY = 0; // 0x0
- }
-
-}
-
-package android.telephony.data {
-
- public final class DataCallResponse implements android.os.Parcelable {
- method public int describeContents();
- method @NonNull public java.util.List<android.net.LinkAddress> getAddresses();
- method public int getCause();
- method @NonNull public java.util.List<java.net.InetAddress> getDnsAddresses();
- method @NonNull public java.util.List<java.net.InetAddress> getGatewayAddresses();
- method public int getHandoverFailureMode();
- method public int getId();
- method @NonNull public String getInterfaceName();
- method public int getLinkStatus();
- method @Deprecated public int getMtu();
- method public int getMtuV4();
- method public int getMtuV6();
- method @NonNull public java.util.List<java.net.InetAddress> getPcscfAddresses();
- method public int getProtocolType();
- method public long getRetryDurationMillis();
- method @Deprecated public int getSuggestedRetryTime();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.data.DataCallResponse> CREATOR;
- field public static final int HANDOVER_FAILURE_MODE_DO_FALLBACK = 1; // 0x1
- field public static final int HANDOVER_FAILURE_MODE_LEGACY = 0; // 0x0
- field public static final int HANDOVER_FAILURE_MODE_NO_FALLBACK_RETRY_HANDOVER = 2; // 0x2
- field public static final int HANDOVER_FAILURE_MODE_NO_FALLBACK_RETRY_SETUP_NORMAL = 3; // 0x3
- field public static final int HANDOVER_FAILURE_MODE_UNKNOWN = -1; // 0xffffffff
- field public static final int LINK_STATUS_ACTIVE = 2; // 0x2
- field public static final int LINK_STATUS_DORMANT = 1; // 0x1
- field public static final int LINK_STATUS_INACTIVE = 0; // 0x0
- field public static final int LINK_STATUS_UNKNOWN = -1; // 0xffffffff
- field public static final int RETRY_DURATION_UNDEFINED = -1; // 0xffffffff
- }
-
- public static final class DataCallResponse.Builder {
- ctor public DataCallResponse.Builder();
- method @NonNull public android.telephony.data.DataCallResponse build();
- method @NonNull public android.telephony.data.DataCallResponse.Builder setAddresses(@NonNull java.util.List<android.net.LinkAddress>);
- method @NonNull public android.telephony.data.DataCallResponse.Builder setCause(int);
- method @NonNull public android.telephony.data.DataCallResponse.Builder setDnsAddresses(@NonNull java.util.List<java.net.InetAddress>);
- method @NonNull public android.telephony.data.DataCallResponse.Builder setGatewayAddresses(@NonNull java.util.List<java.net.InetAddress>);
- method @NonNull public android.telephony.data.DataCallResponse.Builder setHandoverFailureMode(int);
- method @NonNull public android.telephony.data.DataCallResponse.Builder setId(int);
- method @NonNull public android.telephony.data.DataCallResponse.Builder setInterfaceName(@NonNull String);
- method @NonNull public android.telephony.data.DataCallResponse.Builder setLinkStatus(int);
- method @Deprecated @NonNull public android.telephony.data.DataCallResponse.Builder setMtu(int);
- method @NonNull public android.telephony.data.DataCallResponse.Builder setMtuV4(int);
- method @NonNull public android.telephony.data.DataCallResponse.Builder setMtuV6(int);
- method @NonNull public android.telephony.data.DataCallResponse.Builder setPcscfAddresses(@NonNull java.util.List<java.net.InetAddress>);
- method @NonNull public android.telephony.data.DataCallResponse.Builder setProtocolType(int);
- method @NonNull public android.telephony.data.DataCallResponse.Builder setRetryDurationMillis(long);
- method @Deprecated @NonNull public android.telephony.data.DataCallResponse.Builder setSuggestedRetryTime(int);
- }
-
- public final class DataProfile implements android.os.Parcelable {
- method public int describeContents();
- method @NonNull public String getApn();
- method public int getAuthType();
- method public int getBearerBitmask();
- method @Deprecated public int getMtu();
- method public int getMtuV4();
- method public int getMtuV6();
- method @Nullable public String getPassword();
- method public int getProfileId();
- method public int getProtocolType();
- method public int getRoamingProtocolType();
- method public int getSupportedApnTypesBitmask();
- method public int getType();
- method @Nullable public String getUserName();
- method public boolean isEnabled();
- method public boolean isPersistent();
- method public boolean isPreferred();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.data.DataProfile> CREATOR;
- field public static final int TYPE_3GPP = 1; // 0x1
- field public static final int TYPE_3GPP2 = 2; // 0x2
- field public static final int TYPE_COMMON = 0; // 0x0
- }
-
- public static final class DataProfile.Builder {
- ctor public DataProfile.Builder();
- method @NonNull public android.telephony.data.DataProfile build();
- method @NonNull public android.telephony.data.DataProfile.Builder enable(boolean);
- method @NonNull public android.telephony.data.DataProfile.Builder setApn(@NonNull String);
- method @NonNull public android.telephony.data.DataProfile.Builder setAuthType(int);
- method @NonNull public android.telephony.data.DataProfile.Builder setBearerBitmask(int);
- method @Deprecated @NonNull public android.telephony.data.DataProfile.Builder setMtu(int);
- method @NonNull public android.telephony.data.DataProfile.Builder setMtuV4(int);
- method @NonNull public android.telephony.data.DataProfile.Builder setMtuV6(int);
- method @NonNull public android.telephony.data.DataProfile.Builder setPassword(@NonNull String);
- method @NonNull public android.telephony.data.DataProfile.Builder setPersistent(boolean);
- method @NonNull public android.telephony.data.DataProfile.Builder setPreferred(boolean);
- method @NonNull public android.telephony.data.DataProfile.Builder setProfileId(int);
- method @NonNull public android.telephony.data.DataProfile.Builder setProtocolType(int);
- method @NonNull public android.telephony.data.DataProfile.Builder setRoamingProtocolType(int);
- method @NonNull public android.telephony.data.DataProfile.Builder setSupportedApnTypesBitmask(int);
- method @NonNull public android.telephony.data.DataProfile.Builder setType(int);
- method @NonNull public android.telephony.data.DataProfile.Builder setUserName(@NonNull String);
- }
-
- public abstract class DataService extends android.app.Service {
- ctor public DataService();
- method public android.os.IBinder onBind(android.content.Intent);
- method @Nullable public abstract android.telephony.data.DataService.DataServiceProvider onCreateDataServiceProvider(int);
- field public static final int REQUEST_REASON_HANDOVER = 3; // 0x3
- field public static final int REQUEST_REASON_NORMAL = 1; // 0x1
- field public static final int REQUEST_REASON_SHUTDOWN = 2; // 0x2
- field public static final int REQUEST_REASON_UNKNOWN = 0; // 0x0
- field public static final String SERVICE_INTERFACE = "android.telephony.data.DataService";
- }
-
- public abstract class DataService.DataServiceProvider implements java.lang.AutoCloseable {
- ctor public DataService.DataServiceProvider(int);
- method public abstract void close();
- method public void deactivateDataCall(int, int, @Nullable android.telephony.data.DataServiceCallback);
- method public final int getSlotIndex();
- method public final void notifyDataCallListChanged(java.util.List<android.telephony.data.DataCallResponse>);
- method public void requestDataCallList(@NonNull android.telephony.data.DataServiceCallback);
- method public void setDataProfile(@NonNull java.util.List<android.telephony.data.DataProfile>, boolean, @NonNull android.telephony.data.DataServiceCallback);
- method public void setInitialAttachApn(@NonNull android.telephony.data.DataProfile, boolean, @NonNull android.telephony.data.DataServiceCallback);
- method public void setupDataCall(int, @NonNull android.telephony.data.DataProfile, boolean, boolean, int, @Nullable android.net.LinkProperties, @NonNull android.telephony.data.DataServiceCallback);
- }
-
- public class DataServiceCallback {
- method public void onDataCallListChanged(@NonNull java.util.List<android.telephony.data.DataCallResponse>);
- method public void onDeactivateDataCallComplete(int);
- method public void onRequestDataCallListComplete(int, @NonNull java.util.List<android.telephony.data.DataCallResponse>);
- method public void onSetDataProfileComplete(int);
- method public void onSetInitialAttachApnComplete(int);
- method public void onSetupDataCallComplete(int, @Nullable android.telephony.data.DataCallResponse);
- field public static final int RESULT_ERROR_BUSY = 3; // 0x3
- field public static final int RESULT_ERROR_ILLEGAL_STATE = 4; // 0x4
- field public static final int RESULT_ERROR_INVALID_ARG = 2; // 0x2
- field public static final int RESULT_ERROR_UNSUPPORTED = 1; // 0x1
- field public static final int RESULT_SUCCESS = 0; // 0x0
- }
-
- public abstract class QualifiedNetworksService extends android.app.Service {
- ctor public QualifiedNetworksService();
- method @NonNull public abstract android.telephony.data.QualifiedNetworksService.NetworkAvailabilityProvider onCreateNetworkAvailabilityProvider(int);
- field public static final String QUALIFIED_NETWORKS_SERVICE_INTERFACE = "android.telephony.data.QualifiedNetworksService";
- }
-
- public abstract class QualifiedNetworksService.NetworkAvailabilityProvider implements java.lang.AutoCloseable {
- ctor public QualifiedNetworksService.NetworkAvailabilityProvider(int);
- method public abstract void close();
- method public final int getSlotIndex();
- method public final void updateQualifiedNetworkTypes(int, @NonNull java.util.List<java.lang.Integer>);
- }
-
-}
-
-package android.telephony.euicc {
-
- public final class DownloadableSubscription implements android.os.Parcelable {
- method public java.util.List<android.telephony.UiccAccessRule> getAccessRules();
- method @Nullable public String getCarrierName();
- }
-
- public static final class DownloadableSubscription.Builder {
- ctor public DownloadableSubscription.Builder();
- ctor public DownloadableSubscription.Builder(android.telephony.euicc.DownloadableSubscription);
- method public android.telephony.euicc.DownloadableSubscription build();
- method public android.telephony.euicc.DownloadableSubscription.Builder setAccessRules(java.util.List<android.telephony.UiccAccessRule>);
- method public android.telephony.euicc.DownloadableSubscription.Builder setCarrierName(String);
- method public android.telephony.euicc.DownloadableSubscription.Builder setConfirmationCode(String);
- method public android.telephony.euicc.DownloadableSubscription.Builder setEncodedActivationCode(String);
- }
-
- public class EuiccCardManager {
- method public void authenticateServer(String, String, byte[], byte[], byte[], byte[], java.util.concurrent.Executor, android.telephony.euicc.EuiccCardManager.ResultCallback<byte[]>);
- method public void cancelSession(String, byte[], @android.telephony.euicc.EuiccCardManager.CancelReason int, java.util.concurrent.Executor, android.telephony.euicc.EuiccCardManager.ResultCallback<byte[]>);
- method public void deleteProfile(String, String, java.util.concurrent.Executor, android.telephony.euicc.EuiccCardManager.ResultCallback<java.lang.Void>);
- method public void disableProfile(String, String, boolean, java.util.concurrent.Executor, android.telephony.euicc.EuiccCardManager.ResultCallback<java.lang.Void>);
- method public void listNotifications(String, @android.telephony.euicc.EuiccNotification.Event int, java.util.concurrent.Executor, android.telephony.euicc.EuiccCardManager.ResultCallback<android.telephony.euicc.EuiccNotification[]>);
- method public void loadBoundProfilePackage(String, byte[], java.util.concurrent.Executor, android.telephony.euicc.EuiccCardManager.ResultCallback<byte[]>);
- method public void prepareDownload(String, @Nullable byte[], byte[], byte[], byte[], java.util.concurrent.Executor, android.telephony.euicc.EuiccCardManager.ResultCallback<byte[]>);
- method public void removeNotificationFromList(String, int, java.util.concurrent.Executor, android.telephony.euicc.EuiccCardManager.ResultCallback<java.lang.Void>);
- method public void requestAllProfiles(String, java.util.concurrent.Executor, android.telephony.euicc.EuiccCardManager.ResultCallback<android.service.euicc.EuiccProfileInfo[]>);
- method public void requestDefaultSmdpAddress(String, java.util.concurrent.Executor, android.telephony.euicc.EuiccCardManager.ResultCallback<java.lang.String>);
- method public void requestEuiccChallenge(String, java.util.concurrent.Executor, android.telephony.euicc.EuiccCardManager.ResultCallback<byte[]>);
- method public void requestEuiccInfo1(String, java.util.concurrent.Executor, android.telephony.euicc.EuiccCardManager.ResultCallback<byte[]>);
- method public void requestEuiccInfo2(String, java.util.concurrent.Executor, android.telephony.euicc.EuiccCardManager.ResultCallback<byte[]>);
- method public void requestProfile(String, String, java.util.concurrent.Executor, android.telephony.euicc.EuiccCardManager.ResultCallback<android.service.euicc.EuiccProfileInfo>);
- method public void requestRulesAuthTable(String, java.util.concurrent.Executor, android.telephony.euicc.EuiccCardManager.ResultCallback<android.telephony.euicc.EuiccRulesAuthTable>);
- method public void requestSmdsAddress(String, java.util.concurrent.Executor, android.telephony.euicc.EuiccCardManager.ResultCallback<java.lang.String>);
- method public void resetMemory(String, @android.telephony.euicc.EuiccCardManager.ResetOption int, java.util.concurrent.Executor, android.telephony.euicc.EuiccCardManager.ResultCallback<java.lang.Void>);
- method public void retrieveNotification(String, int, java.util.concurrent.Executor, android.telephony.euicc.EuiccCardManager.ResultCallback<android.telephony.euicc.EuiccNotification>);
- method public void retrieveNotificationList(String, @android.telephony.euicc.EuiccNotification.Event int, java.util.concurrent.Executor, android.telephony.euicc.EuiccCardManager.ResultCallback<android.telephony.euicc.EuiccNotification[]>);
- method public void setDefaultSmdpAddress(String, String, java.util.concurrent.Executor, android.telephony.euicc.EuiccCardManager.ResultCallback<java.lang.Void>);
- method public void setNickname(String, String, String, java.util.concurrent.Executor, android.telephony.euicc.EuiccCardManager.ResultCallback<java.lang.Void>);
- method public void switchToProfile(String, String, boolean, java.util.concurrent.Executor, android.telephony.euicc.EuiccCardManager.ResultCallback<android.service.euicc.EuiccProfileInfo>);
- field public static final int CANCEL_REASON_END_USER_REJECTED = 0; // 0x0
- field public static final int CANCEL_REASON_POSTPONED = 1; // 0x1
- field public static final int CANCEL_REASON_PPR_NOT_ALLOWED = 3; // 0x3
- field public static final int CANCEL_REASON_TIMEOUT = 2; // 0x2
- field public static final int RESET_OPTION_DELETE_FIELD_LOADED_TEST_PROFILES = 2; // 0x2
- field public static final int RESET_OPTION_DELETE_OPERATIONAL_PROFILES = 1; // 0x1
- field public static final int RESET_OPTION_RESET_DEFAULT_SMDP_ADDRESS = 4; // 0x4
- field public static final int RESULT_CALLER_NOT_ALLOWED = -3; // 0xfffffffd
- field public static final int RESULT_EUICC_NOT_FOUND = -2; // 0xfffffffe
- field public static final int RESULT_OK = 0; // 0x0
- field public static final int RESULT_UNKNOWN_ERROR = -1; // 0xffffffff
- }
-
- @IntDef(prefix={"CANCEL_REASON_"}, value={android.telephony.euicc.EuiccCardManager.CANCEL_REASON_END_USER_REJECTED, android.telephony.euicc.EuiccCardManager.CANCEL_REASON_POSTPONED, android.telephony.euicc.EuiccCardManager.CANCEL_REASON_TIMEOUT, android.telephony.euicc.EuiccCardManager.CANCEL_REASON_PPR_NOT_ALLOWED}) @java.lang.annotation.Retention(java.lang.annotation.RetentionPolicy.SOURCE) public static @interface EuiccCardManager.CancelReason {
- }
-
- @IntDef(flag=true, prefix={"RESET_OPTION_"}, value={android.telephony.euicc.EuiccCardManager.RESET_OPTION_DELETE_OPERATIONAL_PROFILES, android.telephony.euicc.EuiccCardManager.RESET_OPTION_DELETE_FIELD_LOADED_TEST_PROFILES, android.telephony.euicc.EuiccCardManager.RESET_OPTION_RESET_DEFAULT_SMDP_ADDRESS}) @java.lang.annotation.Retention(java.lang.annotation.RetentionPolicy.SOURCE) public static @interface EuiccCardManager.ResetOption {
- }
-
- public static interface EuiccCardManager.ResultCallback<T> {
- method public void onComplete(int, T);
- }
-
- public class EuiccManager {
- method @RequiresPermission(android.Manifest.permission.WRITE_EMBEDDED_SUBSCRIPTIONS) public void continueOperation(android.content.Intent, android.os.Bundle);
- method @Deprecated @RequiresPermission(android.Manifest.permission.WRITE_EMBEDDED_SUBSCRIPTIONS) public void eraseSubscriptions(@NonNull android.app.PendingIntent);
- method @RequiresPermission(android.Manifest.permission.WRITE_EMBEDDED_SUBSCRIPTIONS) public void eraseSubscriptions(@android.telephony.euicc.EuiccCardManager.ResetOption int, @NonNull android.app.PendingIntent);
- method @RequiresPermission(android.Manifest.permission.WRITE_EMBEDDED_SUBSCRIPTIONS) public void getDefaultDownloadableSubscriptionList(android.app.PendingIntent);
- method @RequiresPermission(android.Manifest.permission.WRITE_EMBEDDED_SUBSCRIPTIONS) public void getDownloadableSubscriptionMetadata(android.telephony.euicc.DownloadableSubscription, android.app.PendingIntent);
- method @RequiresPermission(android.Manifest.permission.WRITE_EMBEDDED_SUBSCRIPTIONS) public int getOtaStatus();
- method @NonNull @RequiresPermission(android.Manifest.permission.WRITE_EMBEDDED_SUBSCRIPTIONS) public java.util.List<java.lang.String> getSupportedCountries();
- method @NonNull @RequiresPermission(android.Manifest.permission.WRITE_EMBEDDED_SUBSCRIPTIONS) public java.util.List<java.lang.String> getUnsupportedCountries();
- method @RequiresPermission(android.Manifest.permission.WRITE_EMBEDDED_SUBSCRIPTIONS) public boolean isSupportedCountry(@NonNull String);
- method @RequiresPermission(android.Manifest.permission.WRITE_EMBEDDED_SUBSCRIPTIONS) public void setSupportedCountries(@NonNull java.util.List<java.lang.String>);
- method @RequiresPermission(android.Manifest.permission.WRITE_EMBEDDED_SUBSCRIPTIONS) public void setUnsupportedCountries(@NonNull java.util.List<java.lang.String>);
- field public static final String ACTION_DELETE_SUBSCRIPTION_PRIVILEGED = "android.telephony.euicc.action.DELETE_SUBSCRIPTION_PRIVILEGED";
- field @RequiresPermission(android.Manifest.permission.WRITE_EMBEDDED_SUBSCRIPTIONS) public static final String ACTION_OTA_STATUS_CHANGED = "android.telephony.euicc.action.OTA_STATUS_CHANGED";
- field public static final String ACTION_PROVISION_EMBEDDED_SUBSCRIPTION = "android.telephony.euicc.action.PROVISION_EMBEDDED_SUBSCRIPTION";
- field public static final String ACTION_RENAME_SUBSCRIPTION_PRIVILEGED = "android.telephony.euicc.action.RENAME_SUBSCRIPTION_PRIVILEGED";
- field public static final String ACTION_TOGGLE_SUBSCRIPTION_PRIVILEGED = "android.telephony.euicc.action.TOGGLE_SUBSCRIPTION_PRIVILEGED";
- field public static final int EUICC_ACTIVATION_TYPE_ACCOUNT_REQUIRED = 4; // 0x4
- field public static final int EUICC_ACTIVATION_TYPE_BACKUP = 2; // 0x2
- field public static final int EUICC_ACTIVATION_TYPE_DEFAULT = 1; // 0x1
- field public static final int EUICC_ACTIVATION_TYPE_TRANSFER = 3; // 0x3
- field public static final int EUICC_OTA_FAILED = 2; // 0x2
- field public static final int EUICC_OTA_IN_PROGRESS = 1; // 0x1
- field public static final int EUICC_OTA_NOT_NEEDED = 4; // 0x4
- field public static final int EUICC_OTA_STATUS_UNAVAILABLE = 5; // 0x5
- field public static final int EUICC_OTA_SUCCEEDED = 3; // 0x3
- field public static final String EXTRA_ACTIVATION_TYPE = "android.telephony.euicc.extra.ACTIVATION_TYPE";
- field public static final String EXTRA_EMBEDDED_SUBSCRIPTION_DOWNLOADABLE_SUBSCRIPTIONS = "android.telephony.euicc.extra.EMBEDDED_SUBSCRIPTION_DOWNLOADABLE_SUBSCRIPTIONS";
- field public static final String EXTRA_ENABLE_SUBSCRIPTION = "android.telephony.euicc.extra.ENABLE_SUBSCRIPTION";
- field public static final String EXTRA_FORCE_PROVISION = "android.telephony.euicc.extra.FORCE_PROVISION";
- field public static final String EXTRA_FROM_SUBSCRIPTION_ID = "android.telephony.euicc.extra.FROM_SUBSCRIPTION_ID";
- field public static final String EXTRA_PHYSICAL_SLOT_ID = "android.telephony.euicc.extra.PHYSICAL_SLOT_ID";
- field public static final String EXTRA_SUBSCRIPTION_ID = "android.telephony.euicc.extra.SUBSCRIPTION_ID";
- field public static final String EXTRA_SUBSCRIPTION_NICKNAME = "android.telephony.euicc.extra.SUBSCRIPTION_NICKNAME";
- }
-
- @IntDef(prefix={"EUICC_OTA_"}, value={android.telephony.euicc.EuiccManager.EUICC_OTA_IN_PROGRESS, android.telephony.euicc.EuiccManager.EUICC_OTA_FAILED, android.telephony.euicc.EuiccManager.EUICC_OTA_SUCCEEDED, android.telephony.euicc.EuiccManager.EUICC_OTA_NOT_NEEDED, android.telephony.euicc.EuiccManager.EUICC_OTA_STATUS_UNAVAILABLE}) @java.lang.annotation.Retention(java.lang.annotation.RetentionPolicy.SOURCE) public static @interface EuiccManager.OtaStatus {
- }
-
- public final class EuiccNotification implements android.os.Parcelable {
- ctor public EuiccNotification(int, String, @android.telephony.euicc.EuiccNotification.Event int, @Nullable byte[]);
- method public int describeContents();
- method @Nullable public byte[] getData();
- method @android.telephony.euicc.EuiccNotification.Event public int getEvent();
- method public int getSeq();
- method public String getTargetAddr();
- method public void writeToParcel(android.os.Parcel, int);
- field @android.telephony.euicc.EuiccNotification.Event public static final int ALL_EVENTS = 15; // 0xf
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.euicc.EuiccNotification> CREATOR;
- field public static final int EVENT_DELETE = 8; // 0x8
- field public static final int EVENT_DISABLE = 4; // 0x4
- field public static final int EVENT_ENABLE = 2; // 0x2
- field public static final int EVENT_INSTALL = 1; // 0x1
- }
-
- @IntDef(flag=true, prefix={"EVENT_"}, value={android.telephony.euicc.EuiccNotification.EVENT_INSTALL, android.telephony.euicc.EuiccNotification.EVENT_ENABLE, android.telephony.euicc.EuiccNotification.EVENT_DISABLE, android.telephony.euicc.EuiccNotification.EVENT_DELETE}) @java.lang.annotation.Retention(java.lang.annotation.RetentionPolicy.SOURCE) public static @interface EuiccNotification.Event {
- }
-
- public final class EuiccRulesAuthTable implements android.os.Parcelable {
- method public int describeContents();
- method public int findIndex(@android.service.euicc.EuiccProfileInfo.PolicyRule int, android.service.carrier.CarrierIdentifier);
- method public boolean hasPolicyRuleFlag(int, @android.telephony.euicc.EuiccRulesAuthTable.PolicyRuleFlag int);
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.euicc.EuiccRulesAuthTable> CREATOR;
- field public static final int POLICY_RULE_FLAG_CONSENT_REQUIRED = 1; // 0x1
- }
-
- public static final class EuiccRulesAuthTable.Builder {
- ctor public EuiccRulesAuthTable.Builder(int);
- method public android.telephony.euicc.EuiccRulesAuthTable.Builder add(int, java.util.List<android.service.carrier.CarrierIdentifier>, int);
- method public android.telephony.euicc.EuiccRulesAuthTable build();
- }
-
- @IntDef(flag=true, prefix={"POLICY_RULE_FLAG_"}, value={android.telephony.euicc.EuiccRulesAuthTable.POLICY_RULE_FLAG_CONSENT_REQUIRED}) @java.lang.annotation.Retention(java.lang.annotation.RetentionPolicy.SOURCE) public static @interface EuiccRulesAuthTable.PolicyRuleFlag {
- }
-
-}
-
-package android.telephony.ims {
-
- public final class AudioCodecAttributes implements android.os.Parcelable {
- ctor public AudioCodecAttributes(float, @NonNull android.util.Range<java.lang.Float>, float, @NonNull android.util.Range<java.lang.Float>);
- method public int describeContents();
- method public float getBandwidthKhz();
- method @NonNull public android.util.Range<java.lang.Float> getBandwidthRangeKhz();
- method public float getBitrateKbps();
- method @NonNull public android.util.Range<java.lang.Float> getBitrateRangeKbps();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.ims.AudioCodecAttributes> CREATOR;
- }
-
- public final class ImsCallForwardInfo implements android.os.Parcelable {
- ctor public ImsCallForwardInfo(int, int, int, int, @NonNull String, int);
- method public int describeContents();
- method public int getCondition();
- method public String getNumber();
- method public int getServiceClass();
- method public int getStatus();
- method public int getTimeSeconds();
- method public int getToA();
- method public void writeToParcel(android.os.Parcel, int);
- field public static final int CDIV_CF_REASON_ALL = 4; // 0x4
- field public static final int CDIV_CF_REASON_ALL_CONDITIONAL = 5; // 0x5
- field public static final int CDIV_CF_REASON_BUSY = 1; // 0x1
- field public static final int CDIV_CF_REASON_NOT_LOGGED_IN = 6; // 0x6
- field public static final int CDIV_CF_REASON_NOT_REACHABLE = 3; // 0x3
- field public static final int CDIV_CF_REASON_NO_REPLY = 2; // 0x2
- field public static final int CDIV_CF_REASON_UNCONDITIONAL = 0; // 0x0
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.ims.ImsCallForwardInfo> CREATOR;
- field public static final int STATUS_ACTIVE = 1; // 0x1
- field public static final int STATUS_NOT_ACTIVE = 0; // 0x0
- field public static final int TYPE_OF_ADDRESS_INTERNATIONAL = 145; // 0x91
- field public static final int TYPE_OF_ADDRESS_UNKNOWN = 129; // 0x81
- }
-
- public final class ImsCallProfile implements android.os.Parcelable {
- ctor public ImsCallProfile();
- ctor public ImsCallProfile(int, int);
- ctor public ImsCallProfile(int, int, android.os.Bundle, android.telephony.ims.ImsStreamMediaProfile);
- method public int describeContents();
- method @NonNull public java.util.Set<android.telephony.ims.RtpHeaderExtensionType> getAcceptedRtpHeaderExtensionTypes();
- method public String getCallExtra(String);
- method public String getCallExtra(String, String);
- method public boolean getCallExtraBoolean(String);
- method public boolean getCallExtraBoolean(String, boolean);
- method public int getCallExtraInt(String);
- method public int getCallExtraInt(String, int);
- method public android.os.Bundle getCallExtras();
- method public int getCallType();
- method public static int getCallTypeFromVideoState(int);
- method public int getCallerNumberVerificationStatus();
- method public int getEmergencyCallRouting();
- method public int getEmergencyServiceCategories();
- method @NonNull public java.util.List<java.lang.String> getEmergencyUrns();
- method public android.telephony.ims.ImsStreamMediaProfile getMediaProfile();
- method @NonNull public java.util.Set<android.telephony.ims.RtpHeaderExtensionType> getOfferedRtpHeaderExtensionTypes();
- method @NonNull public android.os.Bundle getProprietaryCallExtras();
- method public int getRestrictCause();
- method public int getServiceType();
- method public static int getVideoStateFromCallType(int);
- method public static int getVideoStateFromImsCallProfile(android.telephony.ims.ImsCallProfile);
- method public boolean hasKnownUserIntentEmergency();
- method public boolean isEmergencyCallTesting();
- method public boolean isVideoCall();
- method public boolean isVideoPaused();
- method public static int presentationToOir(int);
- method public void setAcceptedRtpHeaderExtensionTypes(@NonNull java.util.Set<android.telephony.ims.RtpHeaderExtensionType>);
- method public void setCallExtra(String, String);
- method public void setCallExtraBoolean(String, boolean);
- method public void setCallExtraInt(String, int);
- method public void setCallRestrictCause(int);
- method public void setCallerNumberVerificationStatus(int);
- method public void setEmergencyCallRouting(int);
- method public void setEmergencyCallTesting(boolean);
- method public void setEmergencyServiceCategories(int);
- method public void setEmergencyUrns(@NonNull java.util.List<java.lang.String>);
- method public void setHasKnownUserIntentEmergency(boolean);
- method public void setOfferedRtpHeaderExtensionTypes(@NonNull java.util.Set<android.telephony.ims.RtpHeaderExtensionType>);
- method public void updateCallExtras(android.telephony.ims.ImsCallProfile);
- method public void updateCallType(android.telephony.ims.ImsCallProfile);
- method public void updateMediaProfile(android.telephony.ims.ImsCallProfile);
- method public void writeToParcel(android.os.Parcel, int);
- field public static final int CALL_RESTRICT_CAUSE_DISABLED = 2; // 0x2
- field public static final int CALL_RESTRICT_CAUSE_HD = 3; // 0x3
- field public static final int CALL_RESTRICT_CAUSE_NONE = 0; // 0x0
- field public static final int CALL_RESTRICT_CAUSE_RAT = 1; // 0x1
- field public static final int CALL_TYPE_VIDEO_N_VOICE = 3; // 0x3
- field public static final int CALL_TYPE_VOICE = 2; // 0x2
- field public static final int CALL_TYPE_VOICE_N_VIDEO = 1; // 0x1
- field public static final int CALL_TYPE_VS = 8; // 0x8
- field public static final int CALL_TYPE_VS_RX = 10; // 0xa
- field public static final int CALL_TYPE_VS_TX = 9; // 0x9
- field public static final int CALL_TYPE_VT = 4; // 0x4
- field public static final int CALL_TYPE_VT_NODIR = 7; // 0x7
- field public static final int CALL_TYPE_VT_RX = 6; // 0x6
- field public static final int CALL_TYPE_VT_TX = 5; // 0x5
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.ims.ImsCallProfile> CREATOR;
- field public static final int DIALSTRING_NORMAL = 0; // 0x0
- field public static final int DIALSTRING_SS_CONF = 1; // 0x1
- field public static final int DIALSTRING_USSD = 2; // 0x2
- field public static final String EXTRA_ADDITIONAL_CALL_INFO = "AdditionalCallInfo";
- field public static final String EXTRA_ADDITIONAL_SIP_INVITE_FIELDS = "android.telephony.ims.extra.ADDITIONAL_SIP_INVITE_FIELDS";
- field public static final String EXTRA_CALL_DISCONNECT_CAUSE = "android.telephony.ims.extra.CALL_DISCONNECT_CAUSE";
- field public static final String EXTRA_CALL_NETWORK_TYPE = "android.telephony.ims.extra.CALL_NETWORK_TYPE";
- field @Deprecated public static final String EXTRA_CALL_RAT_TYPE = "CallRadioTech";
- field public static final String EXTRA_CHILD_NUMBER = "ChildNum";
- field public static final String EXTRA_CNA = "cna";
- field public static final String EXTRA_CNAP = "cnap";
- field public static final String EXTRA_CODEC = "Codec";
- field public static final String EXTRA_DIALSTRING = "dialstring";
- field public static final String EXTRA_DISPLAY_TEXT = "DisplayText";
- field public static final String EXTRA_EMERGENCY_CALL = "e_call";
- field public static final String EXTRA_FORWARDED_NUMBER = "android.telephony.ims.extra.FORWARDED_NUMBER";
- field public static final String EXTRA_IS_CALL_PULL = "CallPull";
- field public static final String EXTRA_OI = "oi";
- field public static final String EXTRA_OIR = "oir";
- field public static final String EXTRA_REMOTE_URI = "remote_uri";
- field public static final String EXTRA_USSD = "ussd";
- field public static final int OIR_DEFAULT = 0; // 0x0
- field public static final int OIR_PRESENTATION_NOT_RESTRICTED = 2; // 0x2
- field public static final int OIR_PRESENTATION_PAYPHONE = 4; // 0x4
- field public static final int OIR_PRESENTATION_RESTRICTED = 1; // 0x1
- field public static final int OIR_PRESENTATION_UNKNOWN = 3; // 0x3
- field public static final int SERVICE_TYPE_EMERGENCY = 2; // 0x2
- field public static final int SERVICE_TYPE_NONE = 0; // 0x0
- field public static final int SERVICE_TYPE_NORMAL = 1; // 0x1
- field public static final int VERIFICATION_STATUS_FAILED = 2; // 0x2
- field public static final int VERIFICATION_STATUS_NOT_VERIFIED = 0; // 0x0
- field public static final int VERIFICATION_STATUS_PASSED = 1; // 0x1
- }
-
- public class ImsCallSessionListener {
- method public void callQualityChanged(@NonNull android.telephony.CallQuality);
- method public void callSessionConferenceExtendFailed(android.telephony.ims.ImsReasonInfo);
- method public void callSessionConferenceExtendReceived(android.telephony.ims.stub.ImsCallSessionImplBase, android.telephony.ims.ImsCallProfile);
- method public void callSessionConferenceExtended(android.telephony.ims.stub.ImsCallSessionImplBase, android.telephony.ims.ImsCallProfile);
- method public void callSessionConferenceStateUpdated(android.telephony.ims.ImsConferenceState);
- method public void callSessionDtmfReceived(char);
- method @Deprecated public void callSessionHandover(int, int, android.telephony.ims.ImsReasonInfo);
- method @Deprecated public void callSessionHandoverFailed(int, int, android.telephony.ims.ImsReasonInfo);
- method public void callSessionHeld(android.telephony.ims.ImsCallProfile);
- method public void callSessionHoldFailed(android.telephony.ims.ImsReasonInfo);
- method public void callSessionHoldReceived(android.telephony.ims.ImsCallProfile);
- method public void callSessionInitiated(android.telephony.ims.ImsCallProfile);
- method public void callSessionInitiatedFailed(android.telephony.ims.ImsReasonInfo);
- method public void callSessionInviteParticipantsRequestDelivered();
- method public void callSessionInviteParticipantsRequestFailed(android.telephony.ims.ImsReasonInfo);
- method @Deprecated public void callSessionMayHandover(int, int);
- method public void callSessionMergeComplete(android.telephony.ims.stub.ImsCallSessionImplBase);
- method public void callSessionMergeFailed(android.telephony.ims.ImsReasonInfo);
- method public void callSessionMergeStarted(android.telephony.ims.stub.ImsCallSessionImplBase, android.telephony.ims.ImsCallProfile);
- method public void callSessionMultipartyStateChanged(boolean);
- method public void callSessionProgressing(android.telephony.ims.ImsStreamMediaProfile);
- method public void callSessionRemoveParticipantsRequestDelivered();
- method public void callSessionRemoveParticipantsRequestFailed(android.telephony.ims.ImsReasonInfo);
- method public void callSessionResumeFailed(android.telephony.ims.ImsReasonInfo);
- method public void callSessionResumeReceived(android.telephony.ims.ImsCallProfile);
- method public void callSessionResumed(android.telephony.ims.ImsCallProfile);
- method public void callSessionRtpHeaderExtensionsReceived(@NonNull java.util.Set<android.telephony.ims.RtpHeaderExtension>);
- method public void callSessionRttAudioIndicatorChanged(@NonNull android.telephony.ims.ImsStreamMediaProfile);
- method public void callSessionRttMessageReceived(String);
- method public void callSessionRttModifyRequestReceived(android.telephony.ims.ImsCallProfile);
- method public void callSessionRttModifyResponseReceived(int);
- method public void callSessionSuppServiceReceived(android.telephony.ims.ImsSuppServiceNotification);
- method public void callSessionTerminated(android.telephony.ims.ImsReasonInfo);
- method public void callSessionTtyModeReceived(int);
- method public void callSessionUpdateFailed(android.telephony.ims.ImsReasonInfo);
- method public void callSessionUpdateReceived(android.telephony.ims.ImsCallProfile);
- method public void callSessionUpdated(android.telephony.ims.ImsCallProfile);
- method public void callSessionUssdMessageReceived(int, String);
- method public void onHandover(int, int, @Nullable android.telephony.ims.ImsReasonInfo);
- method public void onHandoverFailed(int, int, @NonNull android.telephony.ims.ImsReasonInfo);
- method public void onMayHandover(int, int);
- }
-
- public final class ImsConferenceState implements android.os.Parcelable {
- method public int describeContents();
- method public static int getConnectionStateForStatus(String);
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.ims.ImsConferenceState> CREATOR;
- field public static final String DISPLAY_TEXT = "display-text";
- field public static final String ENDPOINT = "endpoint";
- field public static final String SIP_STATUS_CODE = "sipstatuscode";
- field public static final String STATUS = "status";
- field public static final String STATUS_ALERTING = "alerting";
- field public static final String STATUS_CONNECTED = "connected";
- field public static final String STATUS_CONNECT_FAIL = "connect-fail";
- field public static final String STATUS_DIALING_IN = "dialing-in";
- field public static final String STATUS_DIALING_OUT = "dialing-out";
- field public static final String STATUS_DISCONNECTED = "disconnected";
- field public static final String STATUS_DISCONNECTING = "disconnecting";
- field public static final String STATUS_MUTED_VIA_FOCUS = "muted-via-focus";
- field public static final String STATUS_ON_HOLD = "on-hold";
- field public static final String STATUS_PENDING = "pending";
- field public static final String STATUS_SEND_ONLY = "sendonly";
- field public static final String STATUS_SEND_RECV = "sendrecv";
- field public static final String USER = "user";
- field public final java.util.HashMap<java.lang.String,android.os.Bundle> mParticipants;
- }
-
- public final class ImsException extends java.lang.Exception {
- ctor public ImsException(@Nullable String);
- ctor public ImsException(@Nullable String, int);
- ctor public ImsException(@Nullable String, int, @Nullable Throwable);
- }
-
- public final class ImsExternalCallState implements android.os.Parcelable {
- ctor public ImsExternalCallState(@NonNull String, @NonNull android.net.Uri, @Nullable android.net.Uri, boolean, int, int, boolean);
- method public int describeContents();
- method @NonNull public android.net.Uri getAddress();
- method public int getCallId();
- method public int getCallState();
- method public int getCallType();
- method @Nullable public android.net.Uri getLocalAddress();
- method public boolean isCallHeld();
- method public boolean isCallPullable();
- method public void writeToParcel(android.os.Parcel, int);
- field public static final int CALL_STATE_CONFIRMED = 1; // 0x1
- field public static final int CALL_STATE_TERMINATED = 2; // 0x2
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.ims.ImsExternalCallState> CREATOR;
- }
-
- public class ImsManager {
- method @NonNull public android.telephony.ims.SipDelegateManager getSipDelegateManager(int);
- }
-
- public class ImsMmTelManager implements android.telephony.ims.RegistrationManager {
- method @Deprecated @NonNull @RequiresPermission(anyOf={android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE, android.Manifest.permission.READ_PRECISE_PHONE_STATE}) public static android.telephony.ims.ImsMmTelManager createForSubscriptionId(int);
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public void getFeatureState(@NonNull java.util.concurrent.Executor, @NonNull java.util.function.Consumer<java.lang.Integer>) throws android.telephony.ims.ImsException;
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public void getRegistrationState(@NonNull java.util.concurrent.Executor, @NonNull java.util.function.Consumer<java.lang.Integer>);
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public int getVoWiFiRoamingModeSetting();
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public boolean isAvailable(int, int);
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public boolean isCapable(int, int);
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public void isSupported(int, int, @NonNull java.util.concurrent.Executor, @NonNull java.util.function.Consumer<java.lang.Boolean>) throws android.telephony.ims.ImsException;
- method @Deprecated @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public void registerImsRegistrationCallback(@NonNull java.util.concurrent.Executor, @NonNull android.telephony.ims.ImsMmTelManager.RegistrationCallback) throws android.telephony.ims.ImsException;
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void setAdvancedCallingSettingEnabled(boolean);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void setRttCapabilitySetting(boolean);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void setVoWiFiModeSetting(int);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void setVoWiFiNonPersistent(boolean, int);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void setVoWiFiRoamingModeSetting(int);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void setVoWiFiRoamingSettingEnabled(boolean);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void setVoWiFiSettingEnabled(boolean);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void setVtSettingEnabled(boolean);
- method @Deprecated @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public void unregisterImsRegistrationCallback(@NonNull android.telephony.ims.ImsMmTelManager.RegistrationCallback);
- }
-
- @Deprecated public static class ImsMmTelManager.RegistrationCallback extends android.telephony.ims.RegistrationManager.RegistrationCallback {
- ctor @Deprecated public ImsMmTelManager.RegistrationCallback();
- }
-
- public final class ImsReasonInfo implements android.os.Parcelable {
- field public static final String EXTRA_MSG_SERVICE_NOT_AUTHORIZED = "Forbidden. Not Authorized for Service";
- }
-
- public class ImsService extends android.app.Service {
- ctor public ImsService();
- method public android.telephony.ims.feature.MmTelFeature createMmTelFeature(int);
- method public android.telephony.ims.feature.RcsFeature createRcsFeature(int);
- method public void disableIms(int);
- method public void enableIms(int);
- method public android.telephony.ims.stub.ImsConfigImplBase getConfig(int);
- method public long getImsServiceCapabilities();
- method public android.telephony.ims.stub.ImsRegistrationImplBase getRegistration(int);
- method @Nullable public android.telephony.ims.stub.SipTransportImplBase getSipTransport(int);
- method public final void onUpdateSupportedImsFeatures(android.telephony.ims.stub.ImsFeatureConfiguration) throws android.os.RemoteException;
- method public android.telephony.ims.stub.ImsFeatureConfiguration querySupportedImsFeatures();
- method public void readyForFeatureCreation();
- field public static final long CAPABILITY_SIP_DELEGATE_CREATION = 2L; // 0x2L
- }
-
- public final class ImsSsData implements android.os.Parcelable {
- ctor public ImsSsData(int, int, int, int, int);
- method public int describeContents();
- method @Nullable public java.util.List<android.telephony.ims.ImsCallForwardInfo> getCallForwardInfo();
- method public int getRequestType();
- method public int getResult();
- method public int getServiceClass();
- method public int getServiceType();
- method @NonNull public java.util.List<android.telephony.ims.ImsSsInfo> getSuppServiceInfo();
- method public int getTeleserviceType();
- method public boolean isTypeBarring();
- method public boolean isTypeCf();
- method public boolean isTypeClip();
- method public boolean isTypeClir();
- method public boolean isTypeColp();
- method public boolean isTypeColr();
- method public boolean isTypeCw();
- method public boolean isTypeIcb();
- method public boolean isTypeInterrogation();
- method public boolean isTypeUnConditional();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.ims.ImsSsData> CREATOR;
- field public static final int RESULT_SUCCESS = 0; // 0x0
- field public static final int SERVICE_CLASS_DATA = 2; // 0x2
- field public static final int SERVICE_CLASS_DATA_CIRCUIT_ASYNC = 32; // 0x20
- field public static final int SERVICE_CLASS_DATA_CIRCUIT_SYNC = 16; // 0x10
- field public static final int SERVICE_CLASS_DATA_PACKET_ACCESS = 64; // 0x40
- field public static final int SERVICE_CLASS_DATA_PAD = 128; // 0x80
- field public static final int SERVICE_CLASS_FAX = 4; // 0x4
- field public static final int SERVICE_CLASS_NONE = 0; // 0x0
- field public static final int SERVICE_CLASS_SMS = 8; // 0x8
- field public static final int SERVICE_CLASS_VOICE = 1; // 0x1
- field public static final int SS_ACTIVATION = 0; // 0x0
- field public static final int SS_ALL_BARRING = 18; // 0x12
- field public static final int SS_ALL_DATA_TELESERVICES = 3; // 0x3
- field public static final int SS_ALL_TELESERVICES_EXCEPT_SMS = 5; // 0x5
- field public static final int SS_ALL_TELESEVICES = 1; // 0x1
- field public static final int SS_ALL_TELE_AND_BEARER_SERVICES = 0; // 0x0
- field public static final int SS_BAIC = 16; // 0x10
- field public static final int SS_BAIC_ROAMING = 17; // 0x11
- field public static final int SS_BAOC = 13; // 0xd
- field public static final int SS_BAOIC = 14; // 0xe
- field public static final int SS_BAOIC_EXC_HOME = 15; // 0xf
- field public static final int SS_CFU = 0; // 0x0
- field public static final int SS_CFUT = 6; // 0x6
- field public static final int SS_CF_ALL = 4; // 0x4
- field public static final int SS_CF_ALL_CONDITIONAL = 5; // 0x5
- field public static final int SS_CF_BUSY = 1; // 0x1
- field public static final int SS_CF_NOT_REACHABLE = 3; // 0x3
- field public static final int SS_CF_NO_REPLY = 2; // 0x2
- field public static final int SS_CLIP = 7; // 0x7
- field public static final int SS_CLIR = 8; // 0x8
- field public static final int SS_CNAP = 11; // 0xb
- field public static final int SS_COLP = 9; // 0x9
- field public static final int SS_COLR = 10; // 0xa
- field public static final int SS_DEACTIVATION = 1; // 0x1
- field public static final int SS_ERASURE = 4; // 0x4
- field public static final int SS_INCOMING_BARRING = 20; // 0x14
- field public static final int SS_INCOMING_BARRING_ANONYMOUS = 22; // 0x16
- field public static final int SS_INCOMING_BARRING_DN = 21; // 0x15
- field public static final int SS_INTERROGATION = 2; // 0x2
- field public static final int SS_OUTGOING_BARRING = 19; // 0x13
- field public static final int SS_REGISTRATION = 3; // 0x3
- field public static final int SS_SMS_SERVICES = 4; // 0x4
- field public static final int SS_TELEPHONY = 2; // 0x2
- field public static final int SS_WAIT = 12; // 0xc
- }
-
- public static final class ImsSsData.Builder {
- ctor public ImsSsData.Builder(int, int, int, int, int);
- method @NonNull public android.telephony.ims.ImsSsData build();
- method @NonNull public android.telephony.ims.ImsSsData.Builder setCallForwardingInfo(@NonNull java.util.List<android.telephony.ims.ImsCallForwardInfo>);
- method @NonNull public android.telephony.ims.ImsSsData.Builder setSuppServiceInfo(@NonNull java.util.List<android.telephony.ims.ImsSsInfo>);
- }
-
- public final class ImsSsInfo implements android.os.Parcelable {
- ctor @Deprecated public ImsSsInfo(int, @Nullable String);
- method public int describeContents();
- method public int getClirInterrogationStatus();
- method public int getClirOutgoingState();
- method @Deprecated public String getIcbNum();
- method @Nullable public String getIncomingCommunicationBarringNumber();
- method public int getProvisionStatus();
- method public int getStatus();
- method public void writeToParcel(android.os.Parcel, int);
- field public static final int CLIR_OUTGOING_DEFAULT = 0; // 0x0
- field public static final int CLIR_OUTGOING_INVOCATION = 1; // 0x1
- field public static final int CLIR_OUTGOING_SUPPRESSION = 2; // 0x2
- field public static final int CLIR_STATUS_NOT_PROVISIONED = 0; // 0x0
- field public static final int CLIR_STATUS_PROVISIONED_PERMANENT = 1; // 0x1
- field public static final int CLIR_STATUS_TEMPORARILY_ALLOWED = 4; // 0x4
- field public static final int CLIR_STATUS_TEMPORARILY_RESTRICTED = 3; // 0x3
- field public static final int CLIR_STATUS_UNKNOWN = 2; // 0x2
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.ims.ImsSsInfo> CREATOR;
- field public static final int DISABLED = 0; // 0x0
- field public static final int ENABLED = 1; // 0x1
- field public static final int NOT_REGISTERED = -1; // 0xffffffff
- field public static final int SERVICE_NOT_PROVISIONED = 0; // 0x0
- field public static final int SERVICE_PROVISIONED = 1; // 0x1
- field public static final int SERVICE_PROVISIONING_UNKNOWN = -1; // 0xffffffff
- }
-
- public static final class ImsSsInfo.Builder {
- ctor public ImsSsInfo.Builder(int);
- method @NonNull public android.telephony.ims.ImsSsInfo build();
- method @NonNull public android.telephony.ims.ImsSsInfo.Builder setClirInterrogationStatus(int);
- method @NonNull public android.telephony.ims.ImsSsInfo.Builder setClirOutgoingState(int);
- method @NonNull public android.telephony.ims.ImsSsInfo.Builder setIncomingCommunicationBarringNumber(@NonNull String);
- method @NonNull public android.telephony.ims.ImsSsInfo.Builder setProvisionStatus(int);
- }
-
- public final class ImsStreamMediaProfile implements android.os.Parcelable {
- ctor public ImsStreamMediaProfile(int, int, int, int, int);
- method public void copyFrom(android.telephony.ims.ImsStreamMediaProfile);
- method public int describeContents();
- method @Nullable public android.telephony.ims.AudioCodecAttributes getAudioCodecAttributes();
- method public int getAudioDirection();
- method public int getAudioQuality();
- method public int getRttMode();
- method public int getVideoDirection();
- method public int getVideoQuality();
- method public boolean isReceivingRttAudio();
- method public boolean isRttCall();
- method public void setAudioCodecAttributes(@NonNull android.telephony.ims.AudioCodecAttributes);
- method public void setReceivingRttAudio(boolean);
- method public void setRttMode(int);
- method public void writeToParcel(android.os.Parcel, int);
- field public static final int AUDIO_QUALITY_AMR = 1; // 0x1
- field public static final int AUDIO_QUALITY_AMR_WB = 2; // 0x2
- field public static final int AUDIO_QUALITY_EVRC = 4; // 0x4
- field public static final int AUDIO_QUALITY_EVRC_B = 5; // 0x5
- field public static final int AUDIO_QUALITY_EVRC_NW = 7; // 0x7
- field public static final int AUDIO_QUALITY_EVRC_WB = 6; // 0x6
- field public static final int AUDIO_QUALITY_EVS_FB = 20; // 0x14
- field public static final int AUDIO_QUALITY_EVS_NB = 17; // 0x11
- field public static final int AUDIO_QUALITY_EVS_SWB = 19; // 0x13
- field public static final int AUDIO_QUALITY_EVS_WB = 18; // 0x12
- field public static final int AUDIO_QUALITY_G711A = 13; // 0xd
- field public static final int AUDIO_QUALITY_G711AB = 15; // 0xf
- field public static final int AUDIO_QUALITY_G711U = 11; // 0xb
- field public static final int AUDIO_QUALITY_G722 = 14; // 0xe
- field public static final int AUDIO_QUALITY_G723 = 12; // 0xc
- field public static final int AUDIO_QUALITY_G729 = 16; // 0x10
- field public static final int AUDIO_QUALITY_GSM_EFR = 8; // 0x8
- field public static final int AUDIO_QUALITY_GSM_FR = 9; // 0x9
- field public static final int AUDIO_QUALITY_GSM_HR = 10; // 0xa
- field public static final int AUDIO_QUALITY_NONE = 0; // 0x0
- field public static final int AUDIO_QUALITY_QCELP13K = 3; // 0x3
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.ims.ImsStreamMediaProfile> CREATOR;
- field public static final int DIRECTION_INACTIVE = 0; // 0x0
- field public static final int DIRECTION_INVALID = -1; // 0xffffffff
- field public static final int DIRECTION_RECEIVE = 1; // 0x1
- field public static final int DIRECTION_SEND = 2; // 0x2
- field public static final int DIRECTION_SEND_RECEIVE = 3; // 0x3
- field public static final int RTT_MODE_DISABLED = 0; // 0x0
- field public static final int RTT_MODE_FULL = 1; // 0x1
- field public static final int VIDEO_QUALITY_NONE = 0; // 0x0
- field public static final int VIDEO_QUALITY_QCIF = 1; // 0x1
- field public static final int VIDEO_QUALITY_QVGA_LANDSCAPE = 2; // 0x2
- field public static final int VIDEO_QUALITY_QVGA_PORTRAIT = 4; // 0x4
- field public static final int VIDEO_QUALITY_VGA_LANDSCAPE = 8; // 0x8
- field public static final int VIDEO_QUALITY_VGA_PORTRAIT = 16; // 0x10
- }
-
- public final class ImsSuppServiceNotification implements android.os.Parcelable {
- ctor public ImsSuppServiceNotification(int, int, int, int, String, String[]);
- method public int describeContents();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.ims.ImsSuppServiceNotification> CREATOR;
- field public final int code;
- field public final String[] history;
- field public final int index;
- field public final int notificationType;
- field public final String number;
- field public final int type;
- }
-
- public class ImsUtListener {
- method public void onLineIdentificationSupplementaryServiceResponse(int, @NonNull android.telephony.ims.ImsSsInfo);
- method public void onSupplementaryServiceIndication(android.telephony.ims.ImsSsData);
- method public void onUtConfigurationCallBarringQueried(int, android.telephony.ims.ImsSsInfo[]);
- method public void onUtConfigurationCallForwardQueried(int, android.telephony.ims.ImsCallForwardInfo[]);
- method public void onUtConfigurationCallWaitingQueried(int, android.telephony.ims.ImsSsInfo[]);
- method @Deprecated public void onUtConfigurationQueried(int, android.os.Bundle);
- method public void onUtConfigurationQueryFailed(int, android.telephony.ims.ImsReasonInfo);
- method public void onUtConfigurationUpdateFailed(int, android.telephony.ims.ImsReasonInfo);
- method public void onUtConfigurationUpdated(int);
- field @Deprecated public static final String BUNDLE_KEY_CLIR = "queryClir";
- field @Deprecated public static final String BUNDLE_KEY_SSINFO = "imsSsInfo";
- }
-
- public abstract class ImsVideoCallProvider {
- ctor public ImsVideoCallProvider();
- method public void changeCallDataUsage(long);
- method public void changeCameraCapabilities(android.telecom.VideoProfile.CameraCapabilities);
- method public void changePeerDimensions(int, int);
- method public void changeVideoQuality(int);
- method public void handleCallSessionEvent(int);
- method public abstract void onRequestCallDataUsage();
- method public abstract void onRequestCameraCapabilities();
- method public abstract void onSendSessionModifyRequest(android.telecom.VideoProfile, android.telecom.VideoProfile);
- method public abstract void onSendSessionModifyResponse(android.telecom.VideoProfile);
- method public abstract void onSetCamera(String);
- method public void onSetCamera(String, int);
- method public abstract void onSetDeviceOrientation(int);
- method public abstract void onSetDisplaySurface(android.view.Surface);
- method public abstract void onSetPauseImage(android.net.Uri);
- method public abstract void onSetPreviewSurface(android.view.Surface);
- method public abstract void onSetZoom(float);
- method public void receiveSessionModifyRequest(android.telecom.VideoProfile);
- method public void receiveSessionModifyResponse(int, android.telecom.VideoProfile, android.telecom.VideoProfile);
- }
-
- public class ProvisioningManager {
- method @NonNull public static android.telephony.ims.ProvisioningManager createForSubscriptionId(int);
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) @WorkerThread public int getProvisioningIntValue(int);
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) @WorkerThread public boolean getProvisioningStatusForCapability(int, int);
- method @Nullable @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) @WorkerThread public String getProvisioningStringValue(int);
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) @WorkerThread public boolean getRcsProvisioningStatusForCapability(int);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void notifyRcsAutoConfigurationReceived(@NonNull byte[], boolean);
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public void registerProvisioningChangedCallback(@NonNull java.util.concurrent.Executor, @NonNull android.telephony.ims.ProvisioningManager.Callback) throws android.telephony.ims.ImsException;
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) @WorkerThread public int setProvisioningIntValue(int, int);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) @WorkerThread public void setProvisioningStatusForCapability(int, int, boolean);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) @WorkerThread public int setProvisioningStringValue(int, @NonNull String);
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) @WorkerThread public void setRcsProvisioningStatusForCapability(int, boolean);
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public void unregisterProvisioningChangedCallback(@NonNull android.telephony.ims.ProvisioningManager.Callback);
- field public static final int KEY_VOICE_OVER_WIFI_ENTITLEMENT_ID = 67; // 0x43
- field public static final int KEY_VOICE_OVER_WIFI_MODE_OVERRIDE = 27; // 0x1b
- field public static final int KEY_VOICE_OVER_WIFI_ROAMING_ENABLED_OVERRIDE = 26; // 0x1a
- field public static final int PROVISIONING_VALUE_DISABLED = 0; // 0x0
- field public static final int PROVISIONING_VALUE_ENABLED = 1; // 0x1
- field public static final String STRING_QUERY_RESULT_ERROR_GENERIC = "STRING_QUERY_RESULT_ERROR_GENERIC";
- field public static final String STRING_QUERY_RESULT_ERROR_NOT_READY = "STRING_QUERY_RESULT_ERROR_NOT_READY";
- }
-
- public static class ProvisioningManager.Callback {
- ctor public ProvisioningManager.Callback();
- method public void onProvisioningIntChanged(int, int);
- method public void onProvisioningStringChanged(int, @NonNull String);
- }
-
- public class RcsUceAdapter {
- method @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void setUceSettingEnabled(boolean) throws android.telephony.ims.ImsException;
- }
-
- public final class RtpHeaderExtension implements android.os.Parcelable {
- ctor public RtpHeaderExtension(@IntRange(from=1, to=14) int, @NonNull byte[]);
- method public int describeContents();
- method @NonNull public byte[] getExtensionData();
- method @IntRange(from=1, to=14) public int getLocalIdentifier();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.ims.RtpHeaderExtension> CREATOR;
- }
-
- public final class RtpHeaderExtensionType implements android.os.Parcelable {
- ctor public RtpHeaderExtensionType(@IntRange(from=1, to=14) int, @NonNull android.net.Uri);
- method public int describeContents();
- method @IntRange(from=1, to=14) public int getLocalIdentifier();
- method @NonNull public android.net.Uri getUri();
- method public void writeToParcel(@NonNull android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.ims.RtpHeaderExtensionType> CREATOR;
- }
-
- public class SipDelegateManager {
- method @RequiresPermission(android.Manifest.permission.READ_PRIVILEGED_PHONE_STATE) public boolean isSupported() throws android.telephony.ims.ImsException;
- }
-
-}
-
-package android.telephony.ims.feature {
-
- public final class CapabilityChangeRequest implements android.os.Parcelable {
- method public void addCapabilitiesToDisableForTech(int, int);
- method public void addCapabilitiesToEnableForTech(int, int);
- method public int describeContents();
- method public java.util.List<android.telephony.ims.feature.CapabilityChangeRequest.CapabilityPair> getCapabilitiesToDisable();
- method public java.util.List<android.telephony.ims.feature.CapabilityChangeRequest.CapabilityPair> getCapabilitiesToEnable();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.ims.feature.CapabilityChangeRequest> CREATOR;
- }
-
- public static class CapabilityChangeRequest.CapabilityPair {
- ctor public CapabilityChangeRequest.CapabilityPair(int, int);
- method public int getCapability();
- method public int getRadioTech();
- }
-
- public abstract class ImsFeature {
- ctor public ImsFeature();
- method public abstract void changeEnabledCapabilities(android.telephony.ims.feature.CapabilityChangeRequest, android.telephony.ims.feature.ImsFeature.CapabilityCallbackProxy);
- method public int getFeatureState();
- method public final int getSlotIndex();
- method public abstract void onFeatureReady();
- method public abstract void onFeatureRemoved();
- method public final void setFeatureState(int);
- field public static final int CAPABILITY_ERROR_GENERIC = -1; // 0xffffffff
- field public static final int CAPABILITY_SUCCESS = 0; // 0x0
- field public static final int FEATURE_EMERGENCY_MMTEL = 0; // 0x0
- field public static final int FEATURE_MMTEL = 1; // 0x1
- field public static final int FEATURE_RCS = 2; // 0x2
- field public static final int STATE_INITIALIZING = 1; // 0x1
- field public static final int STATE_READY = 2; // 0x2
- field public static final int STATE_UNAVAILABLE = 0; // 0x0
- }
-
- @Deprecated public static class ImsFeature.Capabilities {
- field @Deprecated protected int mCapabilities;
- }
-
- protected static class ImsFeature.CapabilityCallbackProxy {
- method public void onChangeCapabilityConfigurationError(int, int, int);
- }
-
- public class MmTelFeature extends android.telephony.ims.feature.ImsFeature {
- ctor public MmTelFeature();
- method public void changeEnabledCapabilities(@NonNull android.telephony.ims.feature.CapabilityChangeRequest, @NonNull android.telephony.ims.feature.ImsFeature.CapabilityCallbackProxy);
- method @Nullable public android.telephony.ims.ImsCallProfile createCallProfile(int, int);
- method @Nullable public android.telephony.ims.stub.ImsCallSessionImplBase createCallSession(@NonNull android.telephony.ims.ImsCallProfile);
- method @NonNull public android.telephony.ims.stub.ImsEcbmImplBase getEcbm();
- method @NonNull public android.telephony.ims.stub.ImsMultiEndpointImplBase getMultiEndpoint();
- method @NonNull public android.telephony.ims.stub.ImsSmsImplBase getSmsImplementation();
- method @NonNull public android.telephony.ims.stub.ImsUtImplBase getUt();
- method public final void notifyCapabilitiesStatusChanged(@NonNull android.telephony.ims.feature.MmTelFeature.MmTelCapabilities);
- method public final void notifyIncomingCall(@NonNull android.telephony.ims.stub.ImsCallSessionImplBase, @NonNull android.os.Bundle);
- method public final void notifyRejectedCall(@NonNull android.telephony.ims.ImsCallProfile, @NonNull android.telephony.ims.ImsReasonInfo);
- method public final void notifyVoiceMessageCountUpdate(int);
- method public void onFeatureReady();
- method public void onFeatureRemoved();
- method public boolean queryCapabilityConfiguration(int, int);
- method @NonNull public final android.telephony.ims.feature.MmTelFeature.MmTelCapabilities queryCapabilityStatus();
- method public void setUiTtyMode(int, @Nullable android.os.Message);
- method public int shouldProcessCall(@NonNull String[]);
- field public static final String EXTRA_IS_UNKNOWN_CALL = "android.telephony.ims.feature.extra.IS_UNKNOWN_CALL";
- field public static final String EXTRA_IS_USSD = "android.telephony.ims.feature.extra.IS_USSD";
- field public static final int PROCESS_CALL_CSFB = 1; // 0x1
- field public static final int PROCESS_CALL_IMS = 0; // 0x0
- }
-
- public static class MmTelFeature.MmTelCapabilities extends android.telephony.ims.feature.ImsFeature.Capabilities {
- ctor public MmTelFeature.MmTelCapabilities();
- ctor @Deprecated public MmTelFeature.MmTelCapabilities(android.telephony.ims.feature.ImsFeature.Capabilities);
- ctor public MmTelFeature.MmTelCapabilities(int);
- method public final void addCapabilities(int);
- method public final void removeCapabilities(int);
- }
-
- public class RcsFeature extends android.telephony.ims.feature.ImsFeature {
- ctor public RcsFeature();
- method public void changeEnabledCapabilities(@NonNull android.telephony.ims.feature.CapabilityChangeRequest, @NonNull android.telephony.ims.feature.ImsFeature.CapabilityCallbackProxy);
- method public void onFeatureReady();
- method public void onFeatureRemoved();
- }
-
-}
-
-package android.telephony.ims.stub {
-
- public class ImsCallSessionImplBase implements java.lang.AutoCloseable {
- ctor public ImsCallSessionImplBase();
- method public void accept(int, android.telephony.ims.ImsStreamMediaProfile);
- method public void close();
- method public void deflect(String);
- method public void extendToConference(String[]);
- method public String getCallId();
- method public android.telephony.ims.ImsCallProfile getCallProfile();
- method public android.telephony.ims.ImsVideoCallProvider getImsVideoCallProvider();
- method public android.telephony.ims.ImsCallProfile getLocalCallProfile();
- method public String getProperty(String);
- method public android.telephony.ims.ImsCallProfile getRemoteCallProfile();
- method public int getState();
- method public void hold(android.telephony.ims.ImsStreamMediaProfile);
- method public void inviteParticipants(String[]);
- method public boolean isInCall();
- method public boolean isMultiparty();
- method public void merge();
- method public void reject(int);
- method public void removeParticipants(String[]);
- method public void resume(android.telephony.ims.ImsStreamMediaProfile);
- method public void sendDtmf(char, android.os.Message);
- method public void sendRtpHeaderExtensions(@NonNull java.util.Set<android.telephony.ims.RtpHeaderExtension>);
- method public void sendRttMessage(String);
- method public void sendRttModifyRequest(android.telephony.ims.ImsCallProfile);
- method public void sendRttModifyResponse(boolean);
- method public void sendUssd(String);
- method public void setListener(android.telephony.ims.ImsCallSessionListener);
- method public void setMute(boolean);
- method public void start(String, android.telephony.ims.ImsCallProfile);
- method public void startConference(String[], android.telephony.ims.ImsCallProfile);
- method public void startDtmf(char);
- method public void stopDtmf();
- method public void terminate(int);
- method public void update(int, android.telephony.ims.ImsStreamMediaProfile);
- field public static final int USSD_MODE_NOTIFY = 0; // 0x0
- field public static final int USSD_MODE_REQUEST = 1; // 0x1
- }
-
- public static class ImsCallSessionImplBase.State {
- method public static String toString(int);
- field public static final int ESTABLISHED = 4; // 0x4
- field public static final int ESTABLISHING = 3; // 0x3
- field public static final int IDLE = 0; // 0x0
- field public static final int INITIATED = 1; // 0x1
- field public static final int INVALID = -1; // 0xffffffff
- field public static final int NEGOTIATING = 2; // 0x2
- field public static final int REESTABLISHING = 6; // 0x6
- field public static final int RENEGOTIATING = 5; // 0x5
- field public static final int TERMINATED = 8; // 0x8
- field public static final int TERMINATING = 7; // 0x7
- }
-
- public class ImsConfigImplBase {
- ctor public ImsConfigImplBase();
- method public int getConfigInt(int);
- method public String getConfigString(int);
- method public final void notifyProvisionedValueChanged(int, int);
- method public final void notifyProvisionedValueChanged(int, String);
- method public void notifyRcsAutoConfigurationReceived(@NonNull byte[], boolean);
- method public int setConfig(int, int);
- method public int setConfig(int, String);
- field public static final int CONFIG_RESULT_FAILED = 1; // 0x1
- field public static final int CONFIG_RESULT_SUCCESS = 0; // 0x0
- field public static final int CONFIG_RESULT_UNKNOWN = -1; // 0xffffffff
- }
-
- public class ImsEcbmImplBase {
- ctor public ImsEcbmImplBase();
- method public final void enteredEcbm();
- method public void exitEmergencyCallbackMode();
- method public final void exitedEcbm();
- }
-
- public final class ImsFeatureConfiguration implements android.os.Parcelable {
- method public int describeContents();
- method public java.util.Set<android.telephony.ims.stub.ImsFeatureConfiguration.FeatureSlotPair> getServiceFeatures();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.ims.stub.ImsFeatureConfiguration> CREATOR;
- }
-
- public static class ImsFeatureConfiguration.Builder {
- ctor public ImsFeatureConfiguration.Builder();
- method public android.telephony.ims.stub.ImsFeatureConfiguration.Builder addFeature(int, int);
- method public android.telephony.ims.stub.ImsFeatureConfiguration build();
- }
-
- public static final class ImsFeatureConfiguration.FeatureSlotPair {
- ctor public ImsFeatureConfiguration.FeatureSlotPair(int, int);
- field public final int featureType;
- field public final int slotId;
- }
-
- public class ImsMultiEndpointImplBase {
- ctor public ImsMultiEndpointImplBase();
- method public final void onImsExternalCallStateUpdate(java.util.List<android.telephony.ims.ImsExternalCallState>);
- method public void requestImsExternalCallStateInfo();
- }
-
- public class ImsRegistrationImplBase {
- ctor public ImsRegistrationImplBase();
- method public final void onDeregistered(android.telephony.ims.ImsReasonInfo);
- method public final void onRegistered(int);
- method public final void onRegistering(int);
- method public final void onSubscriberAssociatedUriChanged(android.net.Uri[]);
- method public final void onTechnologyChangeFailed(int, android.telephony.ims.ImsReasonInfo);
- field public static final int REGISTRATION_TECH_IWLAN = 1; // 0x1
- field public static final int REGISTRATION_TECH_LTE = 0; // 0x0
- field public static final int REGISTRATION_TECH_NONE = -1; // 0xffffffff
- }
-
- public class ImsSmsImplBase {
- ctor public ImsSmsImplBase();
- method public void acknowledgeSms(int, @IntRange(from=0, to=65535) int, int);
- method public void acknowledgeSmsReport(int, @IntRange(from=0, to=65535) int, int);
- method public String getSmsFormat();
- method public void onReady();
- method @Deprecated public final void onSendSmsResult(int, @IntRange(from=0, to=65535) int, int, int) throws java.lang.RuntimeException;
- method public final void onSendSmsResultError(int, @IntRange(from=0, to=65535) int, int, int, int) throws java.lang.RuntimeException;
- method public final void onSendSmsResultSuccess(int, @IntRange(from=0, to=65535) int) throws java.lang.RuntimeException;
- method public final void onSmsReceived(int, String, byte[]) throws java.lang.RuntimeException;
- method @Deprecated public final void onSmsStatusReportReceived(int, @IntRange(from=0, to=65535) int, String, byte[]) throws java.lang.RuntimeException;
- method public final void onSmsStatusReportReceived(int, String, byte[]) throws java.lang.RuntimeException;
- method public void sendSms(int, @IntRange(from=0, to=65535) int, String, String, boolean, byte[]);
- field public static final int DELIVER_STATUS_ERROR_GENERIC = 2; // 0x2
- field public static final int DELIVER_STATUS_ERROR_NO_MEMORY = 3; // 0x3
- field public static final int DELIVER_STATUS_ERROR_REQUEST_NOT_SUPPORTED = 4; // 0x4
- field public static final int DELIVER_STATUS_OK = 1; // 0x1
- field public static final int RESULT_NO_NETWORK_ERROR = -1; // 0xffffffff
- field public static final int SEND_STATUS_ERROR = 2; // 0x2
- field public static final int SEND_STATUS_ERROR_FALLBACK = 4; // 0x4
- field public static final int SEND_STATUS_ERROR_RETRY = 3; // 0x3
- field public static final int SEND_STATUS_OK = 1; // 0x1
- field public static final int STATUS_REPORT_STATUS_ERROR = 2; // 0x2
- field public static final int STATUS_REPORT_STATUS_OK = 1; // 0x1
- }
-
- public class ImsUtImplBase {
- ctor public ImsUtImplBase();
- method public void close();
- method public int queryCallBarring(int);
- method public int queryCallBarringForServiceClass(int, int);
- method public int queryCallForward(int, String);
- method public int queryCallWaiting();
- method public int queryClip();
- method public int queryClir();
- method public int queryColp();
- method public int queryColr();
- method public void setListener(android.telephony.ims.ImsUtListener);
- method public int transact(android.os.Bundle);
- method public int updateCallBarring(int, int, String[]);
- method public int updateCallBarringForServiceClass(int, int, String[], int);
- method public int updateCallForward(int, int, String, int, int);
- method public int updateCallWaiting(boolean, int);
- method public int updateClip(boolean);
- method public int updateClir(int);
- method public int updateColp(boolean);
- method public int updateColr(int);
- }
-
- public class SipTransportImplBase {
- ctor public SipTransportImplBase(@NonNull java.util.concurrent.Executor);
- }
-
-}
-
-package android.telephony.mbms {
-
- public static class DownloadRequest.Builder {
- method public android.telephony.mbms.DownloadRequest.Builder setServiceId(String);
- }
-
- public final class FileInfo implements android.os.Parcelable {
- ctor public FileInfo(android.net.Uri, String);
- }
-
- public final class FileServiceInfo extends android.telephony.mbms.ServiceInfo implements android.os.Parcelable {
- ctor public FileServiceInfo(java.util.Map<java.util.Locale,java.lang.String>, String, java.util.List<java.util.Locale>, String, java.util.Date, java.util.Date, java.util.List<android.telephony.mbms.FileInfo>);
- }
-
- public class MbmsDownloadReceiver extends android.content.BroadcastReceiver {
- field public static final int RESULT_APP_NOTIFICATION_ERROR = 6; // 0x6
- field public static final int RESULT_BAD_TEMP_FILE_ROOT = 3; // 0x3
- field public static final int RESULT_DOWNLOAD_FINALIZATION_ERROR = 4; // 0x4
- field public static final int RESULT_INVALID_ACTION = 1; // 0x1
- field public static final int RESULT_MALFORMED_INTENT = 2; // 0x2
- field public static final int RESULT_OK = 0; // 0x0
- field public static final int RESULT_TEMP_FILE_GENERATION_ERROR = 5; // 0x5
- }
-
- public final class StreamingServiceInfo extends android.telephony.mbms.ServiceInfo implements android.os.Parcelable {
- ctor public StreamingServiceInfo(java.util.Map<java.util.Locale,java.lang.String>, String, java.util.List<java.util.Locale>, String, java.util.Date, java.util.Date);
- }
-
- public final class UriPathPair implements android.os.Parcelable {
- method public int describeContents();
- method public android.net.Uri getContentUri();
- method public android.net.Uri getFilePathUri();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.telephony.mbms.UriPathPair> CREATOR;
- }
-
-}
-
-package android.telephony.mbms.vendor {
-
- public class MbmsDownloadServiceBase extends android.os.Binder implements android.os.IInterface {
- ctor public MbmsDownloadServiceBase();
- method public int addProgressListener(android.telephony.mbms.DownloadRequest, android.telephony.mbms.DownloadProgressListener) throws android.os.RemoteException;
- method public int addServiceAnnouncement(int, @NonNull byte[]);
- method public int addStatusListener(android.telephony.mbms.DownloadRequest, android.telephony.mbms.DownloadStatusListener) throws android.os.RemoteException;
- method public android.os.IBinder asBinder();
- method public int cancelDownload(android.telephony.mbms.DownloadRequest) throws android.os.RemoteException;
- method public void dispose(int) throws android.os.RemoteException;
- method public int download(android.telephony.mbms.DownloadRequest) throws android.os.RemoteException;
- method public int initialize(int, android.telephony.mbms.MbmsDownloadSessionCallback) throws android.os.RemoteException;
- method @NonNull public java.util.List<android.telephony.mbms.DownloadRequest> listPendingDownloads(int) throws android.os.RemoteException;
- method public void onAppCallbackDied(int, int);
- method public boolean onTransact(int, android.os.Parcel, android.os.Parcel, int) throws android.os.RemoteException;
- method public int removeProgressListener(android.telephony.mbms.DownloadRequest, android.telephony.mbms.DownloadProgressListener) throws android.os.RemoteException;
- method public int removeStatusListener(android.telephony.mbms.DownloadRequest, android.telephony.mbms.DownloadStatusListener) throws android.os.RemoteException;
- method public int requestDownloadState(android.telephony.mbms.DownloadRequest, android.telephony.mbms.FileInfo) throws android.os.RemoteException;
- method public int requestUpdateFileServices(int, java.util.List<java.lang.String>) throws android.os.RemoteException;
- method public int resetDownloadKnowledge(android.telephony.mbms.DownloadRequest) throws android.os.RemoteException;
- method public int setTempFileRootDirectory(int, String) throws android.os.RemoteException;
- }
-
- public class MbmsGroupCallServiceBase extends android.app.Service {
- ctor public MbmsGroupCallServiceBase();
- method public void dispose(int) throws android.os.RemoteException;
- method public int initialize(@NonNull android.telephony.mbms.MbmsGroupCallSessionCallback, int) throws android.os.RemoteException;
- method public void onAppCallbackDied(int, int);
- method public android.os.IBinder onBind(android.content.Intent);
- method public int startGroupCall(int, long, @NonNull java.util.List<java.lang.Integer>, @NonNull java.util.List<java.lang.Integer>, @NonNull android.telephony.mbms.GroupCallCallback);
- method public void stopGroupCall(int, long);
- method public void updateGroupCall(int, long, @NonNull java.util.List<java.lang.Integer>, @NonNull java.util.List<java.lang.Integer>);
- }
-
- public class MbmsStreamingServiceBase extends android.os.Binder implements android.os.IInterface {
- ctor public MbmsStreamingServiceBase();
- method public android.os.IBinder asBinder();
- method public void dispose(int) throws android.os.RemoteException;
- method @Nullable public android.net.Uri getPlaybackUri(int, String) throws android.os.RemoteException;
- method public int initialize(android.telephony.mbms.MbmsStreamingSessionCallback, int) throws android.os.RemoteException;
- method public void onAppCallbackDied(int, int);
- method public boolean onTransact(int, android.os.Parcel, android.os.Parcel, int) throws android.os.RemoteException;
- method public int requestUpdateStreamingServices(int, java.util.List<java.lang.String>) throws android.os.RemoteException;
- method public int startStreaming(int, String, android.telephony.mbms.StreamingServiceCallback) throws android.os.RemoteException;
- method public void stopStreaming(int, String) throws android.os.RemoteException;
- }
-
- public class VendorUtils {
- ctor public VendorUtils();
- method public static android.content.ComponentName getAppReceiverFromPackageName(android.content.Context, String);
- field public static final String ACTION_CLEANUP = "android.telephony.mbms.action.CLEANUP";
- field public static final String ACTION_DOWNLOAD_RESULT_INTERNAL = "android.telephony.mbms.action.DOWNLOAD_RESULT_INTERNAL";
- field public static final String ACTION_FILE_DESCRIPTOR_REQUEST = "android.telephony.mbms.action.FILE_DESCRIPTOR_REQUEST";
- field public static final String EXTRA_FD_COUNT = "android.telephony.mbms.extra.FD_COUNT";
- field public static final String EXTRA_FINAL_URI = "android.telephony.mbms.extra.FINAL_URI";
- field public static final String EXTRA_FREE_URI_LIST = "android.telephony.mbms.extra.FREE_URI_LIST";
- field public static final String EXTRA_PAUSED_LIST = "android.telephony.mbms.extra.PAUSED_LIST";
- field public static final String EXTRA_PAUSED_URI_LIST = "android.telephony.mbms.extra.PAUSED_URI_LIST";
- field public static final String EXTRA_SERVICE_ID = "android.telephony.mbms.extra.SERVICE_ID";
- field public static final String EXTRA_TEMP_FILES_IN_USE = "android.telephony.mbms.extra.TEMP_FILES_IN_USE";
- field public static final String EXTRA_TEMP_FILE_ROOT = "android.telephony.mbms.extra.TEMP_FILE_ROOT";
- field public static final String EXTRA_TEMP_LIST = "android.telephony.mbms.extra.TEMP_LIST";
- }
-
-}
-
-package android.util {
-
- public class EventLog {
- method public static void readEventsOnWrapping(int[], long, java.util.Collection<android.util.EventLog.Event>) throws java.io.IOException;
- }
-
- public static final class EventLog.Event {
- method public int getUid();
- }
-
- public final class StatsEvent {
- method @NonNull public static android.util.StatsEvent.Builder newBuilder();
- }
-
- public static final class StatsEvent.Builder {
- method @NonNull public android.util.StatsEvent.Builder addBooleanAnnotation(byte, boolean);
- method @NonNull public android.util.StatsEvent.Builder addIntAnnotation(byte, int);
- method @NonNull public android.util.StatsEvent build();
- method @NonNull public android.util.StatsEvent.Builder setAtomId(int);
- method @NonNull public android.util.StatsEvent.Builder usePooledBuffer();
- method @NonNull public android.util.StatsEvent.Builder writeAttributionChain(@NonNull int[], @NonNull String[]);
- method @NonNull public android.util.StatsEvent.Builder writeBoolean(boolean);
- method @NonNull public android.util.StatsEvent.Builder writeByteArray(@NonNull byte[]);
- method @NonNull public android.util.StatsEvent.Builder writeFloat(float);
- method @NonNull public android.util.StatsEvent.Builder writeInt(int);
- method @NonNull public android.util.StatsEvent.Builder writeKeyValuePairs(@Nullable android.util.SparseIntArray, @Nullable android.util.SparseLongArray, @Nullable android.util.SparseArray<java.lang.String>, @Nullable android.util.SparseArray<java.lang.Float>);
- method @NonNull public android.util.StatsEvent.Builder writeLong(long);
- method @NonNull public android.util.StatsEvent.Builder writeString(@NonNull String);
- }
-
- public final class StatsLog {
- method public static void write(@NonNull android.util.StatsEvent);
- method public static void writeRaw(@NonNull byte[], int);
- }
-
-}
-
-package android.view {
-
- public abstract class Window {
- method public void addSystemFlags(@android.view.WindowManager.LayoutParams.SystemFlags int);
- }
-
- public interface WindowManager extends android.view.ViewManager {
- method @RequiresPermission(android.Manifest.permission.RESTRICTED_VR_ACCESS) public android.graphics.Region getCurrentImeTouchRegion();
- }
-
- public static class WindowManager.LayoutParams extends android.view.ViewGroup.LayoutParams implements android.os.Parcelable {
- method public final long getUserActivityTimeout();
- method public final void setUserActivityTimeout(long);
- field @RequiresPermission(android.Manifest.permission.HIDE_NON_SYSTEM_OVERLAY_WINDOWS) public static final int SYSTEM_FLAG_HIDE_NON_SYSTEM_OVERLAY_WINDOWS = 524288; // 0x80000
- field @RequiresPermission(android.Manifest.permission.INTERNAL_SYSTEM_WINDOW) public static final int SYSTEM_FLAG_SHOW_FOR_ALL_USERS = 16; // 0x10
- }
-
- @IntDef(flag=true, prefix={"SYSTEM_FLAG_"}, value={android.view.WindowManager.LayoutParams.SYSTEM_FLAG_HIDE_NON_SYSTEM_OVERLAY_WINDOWS, android.view.WindowManager.LayoutParams.SYSTEM_FLAG_SHOW_FOR_ALL_USERS}) @java.lang.annotation.Retention(java.lang.annotation.RetentionPolicy.SOURCE) public static @interface WindowManager.LayoutParams.SystemFlags {
- }
-
-}
-
-package android.view.accessibility {
-
- public final class AccessibilityManager {
- method public int getAccessibilityWindowId(@Nullable android.os.IBinder);
- method @RequiresPermission(android.Manifest.permission.MANAGE_ACCESSIBILITY) public void performAccessibilityShortcut();
- method @RequiresPermission(android.Manifest.permission.MANAGE_ACCESSIBILITY) public void registerSystemAction(@NonNull android.app.RemoteAction, int);
- method @RequiresPermission(android.Manifest.permission.MANAGE_ACCESSIBILITY) public void unregisterSystemAction(int);
- }
-
-}
-
-package android.view.autofill {
-
- public final class AutofillManager {
- method public void setAugmentedAutofillWhitelist(@Nullable java.util.Set<java.lang.String>, @Nullable java.util.Set<android.content.ComponentName>);
- }
-
-}
-
-package android.view.contentcapture {
-
- public final class ContentCaptureContext implements android.os.Parcelable {
- method @Nullable public android.content.ComponentName getActivityComponent();
- method public int getDisplayId();
- method public int getFlags();
- method @Nullable public android.view.contentcapture.ContentCaptureSessionId getParentSessionId();
- method public int getTaskId();
- field public static final int FLAG_DISABLED_BY_APP = 1; // 0x1
- field public static final int FLAG_DISABLED_BY_FLAG_SECURE = 2; // 0x2
- field public static final int FLAG_RECONNECTED = 4; // 0x4
- }
-
- public final class ContentCaptureEvent implements android.os.Parcelable {
- method public int describeContents();
- method @Nullable public android.view.contentcapture.ContentCaptureContext getContentCaptureContext();
- method public long getEventTime();
- method @Nullable public android.view.autofill.AutofillId getId();
- method @Nullable public java.util.List<android.view.autofill.AutofillId> getIds();
- method @Nullable public android.graphics.Insets getInsets();
- method @Nullable public CharSequence getText();
- method public int getType();
- method @Nullable public android.view.contentcapture.ViewNode getViewNode();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.view.contentcapture.ContentCaptureEvent> CREATOR;
- field public static final int TYPE_CONTEXT_UPDATED = 6; // 0x6
- field public static final int TYPE_SESSION_PAUSED = 8; // 0x8
- field public static final int TYPE_SESSION_RESUMED = 7; // 0x7
- field public static final int TYPE_VIEW_APPEARED = 1; // 0x1
- field public static final int TYPE_VIEW_DISAPPEARED = 2; // 0x2
- field public static final int TYPE_VIEW_INSETS_CHANGED = 9; // 0x9
- field public static final int TYPE_VIEW_TEXT_CHANGED = 3; // 0x3
- field public static final int TYPE_VIEW_TREE_APPEARED = 5; // 0x5
- field public static final int TYPE_VIEW_TREE_APPEARING = 4; // 0x4
- }
-
- public final class ContentCaptureManager {
- method public boolean isContentCaptureFeatureEnabled();
- field public static final int NO_SESSION_ID = 0; // 0x0
- }
-
- public final class ViewNode extends android.app.assist.AssistStructure.ViewNode {
- method @Nullable public android.view.autofill.AutofillId getParentAutofillId();
- }
-
-}
-
-package android.webkit {
-
- public abstract class CookieManager {
- method protected abstract boolean allowFileSchemeCookiesImpl();
- method public abstract String getCookie(String, boolean);
- method public String getCookie(android.net.WebAddress);
- method public abstract boolean hasCookies(boolean);
- method protected abstract void setAcceptFileSchemeCookiesImpl(boolean);
- }
-
- public class FindActionModeCallback implements android.view.ActionMode.Callback android.text.TextWatcher android.view.View.OnClickListener android.webkit.WebView.FindListener {
- ctor public FindActionModeCallback(android.content.Context);
- method public void afterTextChanged(android.text.Editable);
- method public void beforeTextChanged(CharSequence, int, int, int);
- method public void findAll();
- method public void finish();
- method public int getActionModeGlobalBottom();
- method public boolean onActionItemClicked(android.view.ActionMode, android.view.MenuItem);
- method public void onClick(android.view.View);
- method public boolean onCreateActionMode(android.view.ActionMode, android.view.Menu);
- method public void onDestroyActionMode(android.view.ActionMode);
- method public void onFindResultReceived(int, int, boolean);
- method public boolean onPrepareActionMode(android.view.ActionMode, android.view.Menu);
- method public void onTextChanged(CharSequence, int, int, int);
- method public void setText(String);
- method public void setWebView(@NonNull android.webkit.WebView);
- method public void showSoftInput();
- method public void updateMatchCount(int, int, boolean);
- }
-
- public static class FindActionModeCallback.NoAction implements android.view.ActionMode.Callback {
- ctor public FindActionModeCallback.NoAction();
- method public boolean onActionItemClicked(android.view.ActionMode, android.view.MenuItem);
- method public boolean onCreateActionMode(android.view.ActionMode, android.view.Menu);
- method public void onDestroyActionMode(android.view.ActionMode);
- method public boolean onPrepareActionMode(android.view.ActionMode, android.view.Menu);
- }
-
- public class GeolocationPermissions {
- ctor public GeolocationPermissions();
- }
-
- public class HttpAuthHandler extends android.os.Handler {
- ctor public HttpAuthHandler();
- }
-
- public class JsDialogHelper {
- ctor public JsDialogHelper(android.webkit.JsPromptResult, int, String, String, String);
- ctor public JsDialogHelper(android.webkit.JsPromptResult, android.os.Message);
- method public boolean invokeCallback(android.webkit.WebChromeClient, android.webkit.WebView);
- method public void showDialog(android.content.Context);
- field public static final int ALERT = 1; // 0x1
- field public static final int CONFIRM = 2; // 0x2
- field public static final int PROMPT = 3; // 0x3
- field public static final int UNLOAD = 4; // 0x4
- }
-
- public class JsPromptResult extends android.webkit.JsResult {
- ctor public JsPromptResult(android.webkit.JsResult.ResultReceiver);
- method public String getStringResult();
- }
-
- public class JsResult {
- ctor public JsResult(android.webkit.JsResult.ResultReceiver);
- method public final boolean getResult();
- }
-
- public static interface JsResult.ResultReceiver {
- method public void onJsResultComplete(android.webkit.JsResult);
- }
-
- public interface PacProcessor {
- method @NonNull public static android.webkit.PacProcessor createInstance();
- method @Nullable public String findProxyForUrl(@NonNull String);
- method @NonNull public static android.webkit.PacProcessor getInstance();
- method @Nullable public default android.net.Network getNetwork();
- method public default void release();
- method public default void setNetwork(@Nullable android.net.Network);
- method public boolean setProxyScript(@NonNull String);
- }
-
- public class SslErrorHandler extends android.os.Handler {
- ctor public SslErrorHandler();
- }
-
- @Deprecated public abstract class TokenBindingService {
- ctor @Deprecated public TokenBindingService();
- }
-
- public class WebChromeClient {
- method @Deprecated public void openFileChooser(android.webkit.ValueCallback<android.net.Uri>, String, String);
- }
-
- public abstract class WebHistoryItem implements java.lang.Cloneable {
- method @Deprecated public abstract int getId();
- }
-
- @Deprecated public abstract class WebIconDatabase {
- method @Deprecated public abstract void bulkRequestIconForPageUrl(android.content.ContentResolver, String, android.webkit.WebIconDatabase.IconListener);
- }
-
- public abstract class WebMessagePort {
- ctor public WebMessagePort();
- }
-
- public abstract class WebResourceError {
- ctor public WebResourceError();
- }
-
- public class WebResourceResponse {
- ctor public WebResourceResponse(boolean, String, String, int, String, java.util.Map<java.lang.String,java.lang.String>, java.io.InputStream);
- }
-
- public abstract class WebSettings {
- method public abstract boolean getAcceptThirdPartyCookies();
- method @Deprecated public abstract boolean getNavDump();
- method @Deprecated public abstract boolean getPluginsEnabled();
- method @Deprecated public abstract boolean getUseWebViewBackgroundForOverscrollBackground();
- method @Deprecated public abstract int getUserAgent();
- method public abstract boolean getVideoOverlayForEmbeddedEncryptedVideoEnabled();
- method public abstract void setAcceptThirdPartyCookies(boolean);
- method @Deprecated public abstract void setNavDump(boolean);
- method @Deprecated public abstract void setPluginsEnabled(boolean);
- method @Deprecated public abstract void setUseWebViewBackgroundForOverscrollBackground(boolean);
- method @Deprecated public abstract void setUserAgent(int);
- method public abstract void setVideoOverlayForEmbeddedEncryptedVideoEnabled(boolean);
- }
-
- public class WebStorage {
- ctor public WebStorage();
- }
-
- public static class WebStorage.Origin {
- ctor protected WebStorage.Origin(String, long, long);
- }
-
- public class WebView extends android.widget.AbsoluteLayout implements android.view.ViewGroup.OnHierarchyChangeListener android.view.ViewTreeObserver.OnGlobalFocusChangeListener {
- method public android.webkit.WebViewProvider getWebViewProvider();
- }
-
- public static class WebView.HitTestResult {
- ctor public WebView.HitTestResult();
- method public void setExtra(String);
- method public void setType(int);
- }
-
- public class WebView.PrivateAccess {
- ctor public WebView.PrivateAccess();
- method public void awakenScrollBars(int);
- method public void awakenScrollBars(int, boolean);
- method public float getHorizontalScrollFactor();
- method public int getHorizontalScrollbarHeight();
- method public float getVerticalScrollFactor();
- method public void onScrollChanged(int, int, int, int);
- method public void overScrollBy(int, int, int, int, int, int, int, int, boolean);
- method public void setMeasuredDimension(int, int);
- method public void setScrollXRaw(int);
- method public void setScrollYRaw(int);
- method public void super_computeScroll();
- method public boolean super_dispatchKeyEvent(android.view.KeyEvent);
- method public int super_getScrollBarStyle();
- method @Nullable public android.view.WindowInsets super_onApplyWindowInsets(@Nullable android.view.WindowInsets);
- method public void super_onDrawVerticalScrollBar(android.graphics.Canvas, android.graphics.drawable.Drawable, int, int, int, int);
- method public boolean super_onGenericMotionEvent(android.view.MotionEvent);
- method public boolean super_onHoverEvent(android.view.MotionEvent);
- method public boolean super_performAccessibilityAction(int, android.os.Bundle);
- method public boolean super_performLongClick();
- method public boolean super_requestFocus(int, android.graphics.Rect);
- method public void super_scrollTo(int, int);
- method public boolean super_setFrame(int, int, int, int);
- method public void super_setLayoutParams(android.view.ViewGroup.LayoutParams);
- method public void super_startActivityForResult(android.content.Intent, int);
- }
-
- public final class WebViewDelegate {
- method public void addWebViewAssetPath(android.content.Context);
- method @Deprecated public void callDrawGlFunction(android.graphics.Canvas, long);
- method @Deprecated public void callDrawGlFunction(@NonNull android.graphics.Canvas, long, @Nullable Runnable);
- method @Deprecated public boolean canInvokeDrawGlFunctor(android.view.View);
- method @Deprecated public void detachDrawGlFunctor(android.view.View, long);
- method public void drawWebViewFunctor(@NonNull android.graphics.Canvas, int);
- method public android.app.Application getApplication();
- method public String getDataDirectorySuffix();
- method public String getErrorString(android.content.Context, int);
- method public int getPackageId(android.content.res.Resources, String);
- method @Deprecated public void invokeDrawGlFunctor(android.view.View, long, boolean);
- method public boolean isMultiProcessEnabled();
- method public boolean isTraceTagEnabled();
- method public void setOnTraceEnabledChangeListener(android.webkit.WebViewDelegate.OnTraceEnabledChangeListener);
- }
-
- public static interface WebViewDelegate.OnTraceEnabledChangeListener {
- method public void onTraceEnabledChange(boolean);
- }
-
- public final class WebViewFactory {
- ctor public WebViewFactory();
- method public static android.content.pm.PackageInfo getLoadedPackageInfo();
- method public static int loadWebViewNativeLibraryFromPackage(String, ClassLoader);
- method public static void prepareWebViewInZygote();
- field public static final int LIBLOAD_ADDRESS_SPACE_NOT_RESERVED = 2; // 0x2
- field public static final int LIBLOAD_FAILED_JNI_CALL = 7; // 0x7
- field public static final int LIBLOAD_FAILED_LISTING_WEBVIEW_PACKAGES = 4; // 0x4
- field public static final int LIBLOAD_FAILED_TO_FIND_NAMESPACE = 10; // 0xa
- field public static final int LIBLOAD_FAILED_TO_LOAD_LIBRARY = 6; // 0x6
- field public static final int LIBLOAD_FAILED_TO_OPEN_RELRO_FILE = 5; // 0x5
- field public static final int LIBLOAD_FAILED_WAITING_FOR_RELRO = 3; // 0x3
- field public static final int LIBLOAD_FAILED_WAITING_FOR_WEBVIEW_REASON_UNKNOWN = 8; // 0x8
- field public static final int LIBLOAD_SUCCESS = 0; // 0x0
- field public static final int LIBLOAD_WRONG_PACKAGE_NAME = 1; // 0x1
- }
-
- public interface WebViewFactoryProvider {
- method @NonNull public default android.webkit.PacProcessor createPacProcessor();
- method public android.webkit.WebViewProvider createWebView(android.webkit.WebView, android.webkit.WebView.PrivateAccess);
- method public android.webkit.CookieManager getCookieManager();
- method public android.webkit.GeolocationPermissions getGeolocationPermissions();
- method @NonNull public default android.webkit.PacProcessor getPacProcessor();
- method public android.webkit.ServiceWorkerController getServiceWorkerController();
- method public android.webkit.WebViewFactoryProvider.Statics getStatics();
- method @Deprecated public android.webkit.TokenBindingService getTokenBindingService();
- method public android.webkit.TracingController getTracingController();
- method public android.webkit.WebIconDatabase getWebIconDatabase();
- method public android.webkit.WebStorage getWebStorage();
- method public ClassLoader getWebViewClassLoader();
- method public android.webkit.WebViewDatabase getWebViewDatabase(android.content.Context);
- }
-
- public static interface WebViewFactoryProvider.Statics {
- method public void clearClientCertPreferences(Runnable);
- method public void enableSlowWholeDocumentDraw();
- method public String findAddress(String);
- method public void freeMemoryForTests();
- method public String getDefaultUserAgent(android.content.Context);
- method @NonNull public android.net.Uri getSafeBrowsingPrivacyPolicyUrl();
- method public void initSafeBrowsing(android.content.Context, android.webkit.ValueCallback<java.lang.Boolean>);
- method public android.net.Uri[] parseFileChooserResult(int, android.content.Intent);
- method public void setSafeBrowsingWhitelist(java.util.List<java.lang.String>, android.webkit.ValueCallback<java.lang.Boolean>);
- method public void setWebContentsDebuggingEnabled(boolean);
- }
-
- public interface WebViewProvider {
- method public void addJavascriptInterface(Object, String);
- method public boolean canGoBack();
- method public boolean canGoBackOrForward(int);
- method public boolean canGoForward();
- method public boolean canZoomIn();
- method public boolean canZoomOut();
- method public android.graphics.Picture capturePicture();
- method public void clearCache(boolean);
- method public void clearFormData();
- method public void clearHistory();
- method public void clearMatches();
- method public void clearSslPreferences();
- method public void clearView();
- method public android.webkit.WebBackForwardList copyBackForwardList();
- method public android.print.PrintDocumentAdapter createPrintDocumentAdapter(String);
- method public android.webkit.WebMessagePort[] createWebMessageChannel();
- method public void destroy();
- method public void documentHasImages(android.os.Message);
- method public void dumpViewHierarchyWithProperties(java.io.BufferedWriter, int);
- method public void evaluateJavaScript(String, android.webkit.ValueCallback<java.lang.String>);
- method public int findAll(String);
- method public void findAllAsync(String);
- method public android.view.View findHierarchyView(String, int);
- method public void findNext(boolean);
- method public void flingScroll(int, int);
- method public void freeMemory();
- method public android.net.http.SslCertificate getCertificate();
- method public int getContentHeight();
- method public int getContentWidth();
- method public android.graphics.Bitmap getFavicon();
- method public android.webkit.WebView.HitTestResult getHitTestResult();
- method public String[] getHttpAuthUsernamePassword(String, String);
- method public String getOriginalUrl();
- method public int getProgress();
- method public boolean getRendererPriorityWaivedWhenNotVisible();
- method public int getRendererRequestedPriority();
- method public float getScale();
- method public android.webkit.WebViewProvider.ScrollDelegate getScrollDelegate();
- method public android.webkit.WebSettings getSettings();
- method @NonNull public default android.view.textclassifier.TextClassifier getTextClassifier();
- method public String getTitle();
- method public String getTouchIconUrl();
- method public String getUrl();
- method public android.webkit.WebViewProvider.ViewDelegate getViewDelegate();
- method public int getVisibleTitleHeight();
- method public android.webkit.WebChromeClient getWebChromeClient();
- method public android.webkit.WebViewClient getWebViewClient();
- method @Nullable public android.webkit.WebViewRenderProcess getWebViewRenderProcess();
- method @Nullable public android.webkit.WebViewRenderProcessClient getWebViewRenderProcessClient();
- method public android.view.View getZoomControls();
- method public void goBack();
- method public void goBackOrForward(int);
- method public void goForward();
- method public void init(java.util.Map<java.lang.String,java.lang.Object>, boolean);
- method public void insertVisualStateCallback(long, android.webkit.WebView.VisualStateCallback);
- method public void invokeZoomPicker();
- method public boolean isPaused();
- method public boolean isPrivateBrowsingEnabled();
- method public void loadData(String, String, String);
- method public void loadDataWithBaseURL(String, String, String, String, String);
- method public void loadUrl(String, java.util.Map<java.lang.String,java.lang.String>);
- method public void loadUrl(String);
- method public void notifyFindDialogDismissed();
- method public void onPause();
- method public void onResume();
- method public boolean overlayHorizontalScrollbar();
- method public boolean overlayVerticalScrollbar();
- method public boolean pageDown(boolean);
- method public boolean pageUp(boolean);
- method public void pauseTimers();
- method public void postMessageToMainFrame(android.webkit.WebMessage, android.net.Uri);
- method public void postUrl(String, byte[]);
- method public void reload();
- method public void removeJavascriptInterface(String);
- method public void requestFocusNodeHref(android.os.Message);
- method public void requestImageRef(android.os.Message);
- method public boolean restorePicture(android.os.Bundle, java.io.File);
- method public android.webkit.WebBackForwardList restoreState(android.os.Bundle);
- method public void resumeTimers();
- method public void savePassword(String, String, String);
- method public boolean savePicture(android.os.Bundle, java.io.File);
- method public android.webkit.WebBackForwardList saveState(android.os.Bundle);
- method public void saveWebArchive(String);
- method public void saveWebArchive(String, boolean, android.webkit.ValueCallback<java.lang.String>);
- method public void setCertificate(android.net.http.SslCertificate);
- method public void setDownloadListener(android.webkit.DownloadListener);
- method public void setFindListener(android.webkit.WebView.FindListener);
- method public void setHorizontalScrollbarOverlay(boolean);
- method public void setHttpAuthUsernamePassword(String, String, String, String);
- method public void setInitialScale(int);
- method public void setMapTrackballToArrowKeys(boolean);
- method public void setNetworkAvailable(boolean);
- method public void setPictureListener(android.webkit.WebView.PictureListener);
- method public void setRendererPriorityPolicy(int, boolean);
- method public default void setTextClassifier(@Nullable android.view.textclassifier.TextClassifier);
- method public void setVerticalScrollbarOverlay(boolean);
- method public void setWebChromeClient(android.webkit.WebChromeClient);
- method public void setWebViewClient(android.webkit.WebViewClient);
- method public void setWebViewRenderProcessClient(@Nullable java.util.concurrent.Executor, @Nullable android.webkit.WebViewRenderProcessClient);
- method public boolean showFindDialog(String, boolean);
- method public void stopLoading();
- method public boolean zoomBy(float);
- method public boolean zoomIn();
- method public boolean zoomOut();
- }
-
- public static interface WebViewProvider.ScrollDelegate {
- method public int computeHorizontalScrollOffset();
- method public int computeHorizontalScrollRange();
- method public void computeScroll();
- method public int computeVerticalScrollExtent();
- method public int computeVerticalScrollOffset();
- method public int computeVerticalScrollRange();
- }
-
- public static interface WebViewProvider.ViewDelegate {
- method public default void autofill(android.util.SparseArray<android.view.autofill.AutofillValue>);
- method public boolean dispatchKeyEvent(android.view.KeyEvent);
- method public android.view.View findFocus(android.view.View);
- method public android.view.accessibility.AccessibilityNodeProvider getAccessibilityNodeProvider();
- method public android.os.Handler getHandler(android.os.Handler);
- method public default boolean isVisibleToUserForAutofill(int);
- method public void onActivityResult(int, int, android.content.Intent);
- method @Nullable public default android.view.WindowInsets onApplyWindowInsets(@Nullable android.view.WindowInsets);
- method public void onAttachedToWindow();
- method public default boolean onCheckIsTextEditor();
- method public void onConfigurationChanged(android.content.res.Configuration);
- method public android.view.inputmethod.InputConnection onCreateInputConnection(android.view.inputmethod.EditorInfo);
- method public void onDetachedFromWindow();
- method public boolean onDragEvent(android.view.DragEvent);
- method public void onDraw(android.graphics.Canvas);
- method public void onDrawVerticalScrollBar(android.graphics.Canvas, android.graphics.drawable.Drawable, int, int, int, int);
- method public void onFinishTemporaryDetach();
- method public void onFocusChanged(boolean, int, android.graphics.Rect);
- method public boolean onGenericMotionEvent(android.view.MotionEvent);
- method public boolean onHoverEvent(android.view.MotionEvent);
- method public void onInitializeAccessibilityEvent(android.view.accessibility.AccessibilityEvent);
- method public void onInitializeAccessibilityNodeInfo(android.view.accessibility.AccessibilityNodeInfo);
- method public boolean onKeyDown(int, android.view.KeyEvent);
- method public boolean onKeyMultiple(int, int, android.view.KeyEvent);
- method public boolean onKeyUp(int, android.view.KeyEvent);
- method public void onMeasure(int, int);
- method public default void onMovedToDisplay(int, android.content.res.Configuration);
- method public void onOverScrolled(int, int, boolean, boolean);
- method public default void onProvideAutofillVirtualStructure(android.view.ViewStructure, int);
- method public default void onProvideContentCaptureStructure(@NonNull android.view.ViewStructure, int);
- method public void onProvideVirtualStructure(android.view.ViewStructure);
- method public void onScrollChanged(int, int, int, int);
- method public void onSizeChanged(int, int, int, int);
- method public void onStartTemporaryDetach();
- method public boolean onTouchEvent(android.view.MotionEvent);
- method public boolean onTrackballEvent(android.view.MotionEvent);
- method public void onVisibilityChanged(android.view.View, int);
- method public void onWindowFocusChanged(boolean);
- method public void onWindowVisibilityChanged(int);
- method public boolean performAccessibilityAction(int, android.os.Bundle);
- method public boolean performLongClick();
- method public void preDispatchDraw(android.graphics.Canvas);
- method public boolean requestChildRectangleOnScreen(android.view.View, android.graphics.Rect, boolean);
- method public boolean requestFocus(int, android.graphics.Rect);
- method public void setBackgroundColor(int);
- method public boolean setFrame(int, int, int, int);
- method public void setLayerType(int, android.graphics.Paint);
- method public void setLayoutParams(android.view.ViewGroup.LayoutParams);
- method public void setOverScrollMode(int);
- method public void setScrollBarStyle(int);
- method public boolean shouldDelayChildPressedState();
- }
-
- public final class WebViewProviderInfo implements android.os.Parcelable {
- ctor public WebViewProviderInfo(String, String, boolean, boolean, String[]);
- method public int describeContents();
- method public void writeToParcel(android.os.Parcel, int);
- field @NonNull public static final android.os.Parcelable.Creator<android.webkit.WebViewProviderInfo> CREATOR;
- field public final boolean availableByDefault;
- field public final String description;
- field public final boolean isFallback;
- field public final String packageName;
- field public final android.content.pm.Signature[] signatures;
- }
-
- public final class WebViewUpdateService {
- method public static android.webkit.WebViewProviderInfo[] getAllWebViewPackages();
- method public static String getCurrentWebViewPackageName();
- method public static android.webkit.WebViewProviderInfo[] getValidWebViewPackages();
- }
-
-}
-
diff --git a/api/system-lint-baseline.txt b/api/system-lint-baseline.txt
deleted file mode 100644
index 3ef1f35..0000000
--- a/api/system-lint-baseline.txt
+++ /dev/null
@@ -1,537 +0,0 @@
-// Baseline format: 1.0
-AcronymName: android.net.NetworkCapabilities#setSSID(String):
-
-
-
-ActionValue: android.location.Location#EXTRA_NO_GPS_LOCATION:
-
-ActionValue: android.net.TetheringManager#ACTION_TETHER_STATE_CHANGED:
-
-ActionValue: android.net.TetheringManager#EXTRA_ACTIVE_TETHER:
-
-ActionValue: android.net.TetheringManager#EXTRA_AVAILABLE_TETHER:
-
-ActionValue: android.net.TetheringManager#EXTRA_ERRORED_TETHER:
-
-ActionValue: android.net.wifi.WifiManager#ACTION_LINK_CONFIGURATION_CHANGED:
-
-
-
-ArrayReturn: android.bluetooth.BluetoothCodecStatus#BluetoothCodecStatus(android.bluetooth.BluetoothCodecConfig, android.bluetooth.BluetoothCodecConfig[], android.bluetooth.BluetoothCodecConfig[]) parameter #1:
-
-ArrayReturn: android.bluetooth.BluetoothCodecStatus#BluetoothCodecStatus(android.bluetooth.BluetoothCodecConfig, android.bluetooth.BluetoothCodecConfig[], android.bluetooth.BluetoothCodecConfig[]) parameter #2:
-
-ArrayReturn: android.bluetooth.BluetoothCodecStatus#getCodecsLocalCapabilities():
-
-ArrayReturn: android.bluetooth.BluetoothCodecStatus#getCodecsSelectableCapabilities():
-
-ArrayReturn: android.bluetooth.BluetoothUuid#containsAnyUuid(android.os.ParcelUuid[], android.os.ParcelUuid[]) parameter #0:
-
-ArrayReturn: android.bluetooth.BluetoothUuid#containsAnyUuid(android.os.ParcelUuid[], android.os.ParcelUuid[]) parameter #1:
-
-ArrayReturn: android.media.tv.tuner.Tuner.FilterCallback#onFilterEvent(android.media.tv.tuner.Tuner.Filter, android.media.tv.tuner.filter.FilterEvent[]) parameter #1:
-
-ArrayReturn: android.net.NetworkScoreManager#requestScores(android.net.NetworkKey[]) parameter #0:
-
-ArrayReturn: android.view.contentcapture.ViewNode#getAutofillOptions():
-
-
-
-BuilderSetStyle: android.net.IpSecTransform.Builder#buildTunnelModeTransform(java.net.InetAddress, android.net.IpSecManager.SecurityParameterIndex):
- Builder methods names should use setFoo() / addFoo() / clearFoo() style: method android.net.IpSecTransform.Builder.buildTunnelModeTransform(java.net.InetAddress,android.net.IpSecManager.SecurityParameterIndex)
-
-
-ExecutorRegistration: android.media.MediaPlayer#setOnRtpRxNoticeListener(android.content.Context, android.media.MediaPlayer.OnRtpRxNoticeListener, android.os.Handler):
- Registration methods should have overload that accepts delivery Executor: `setOnRtpRxNoticeListener`
-ExecutorRegistration: android.net.wifi.p2p.WifiP2pManager#deletePersistentGroup(android.net.wifi.p2p.WifiP2pManager.Channel, int, android.net.wifi.p2p.WifiP2pManager.ActionListener):
-
-ExecutorRegistration: android.net.wifi.p2p.WifiP2pManager#factoryReset(android.net.wifi.p2p.WifiP2pManager.Channel, android.net.wifi.p2p.WifiP2pManager.ActionListener):
-
-ExecutorRegistration: android.net.wifi.p2p.WifiP2pManager#listen(android.net.wifi.p2p.WifiP2pManager.Channel, boolean, android.net.wifi.p2p.WifiP2pManager.ActionListener):
-
-ExecutorRegistration: android.net.wifi.p2p.WifiP2pManager#requestPersistentGroupInfo(android.net.wifi.p2p.WifiP2pManager.Channel, android.net.wifi.p2p.WifiP2pManager.PersistentGroupInfoListener):
-
-ExecutorRegistration: android.net.wifi.p2p.WifiP2pManager#setDeviceName(android.net.wifi.p2p.WifiP2pManager.Channel, String, android.net.wifi.p2p.WifiP2pManager.ActionListener):
-
-ExecutorRegistration: android.net.wifi.p2p.WifiP2pManager#setWfdInfo(android.net.wifi.p2p.WifiP2pManager.Channel, android.net.wifi.p2p.WifiP2pWfdInfo, android.net.wifi.p2p.WifiP2pManager.ActionListener):
-
-ExecutorRegistration: android.net.wifi.p2p.WifiP2pManager#setWifiP2pChannels(android.net.wifi.p2p.WifiP2pManager.Channel, int, int, android.net.wifi.p2p.WifiP2pManager.ActionListener):
-
-
-
-GenericException: android.app.prediction.AppPredictor#finalize():
-
-GenericException: android.hardware.location.ContextHubClient#finalize():
-
-GenericException: android.net.IpSecManager.IpSecTunnelInterface#finalize():
-
-GenericException: android.service.autofill.augmented.FillWindow#finalize():
-
-
-
-IntentBuilderName: android.content.Context#registerReceiverForAllUsers(android.content.BroadcastReceiver, android.content.IntentFilter, String, android.os.Handler):
-
-
-
-KotlinKeyword: android.app.Notification#when:
-
-
-
-KotlinOperator: android.telephony.CbGeoUtils.Geometry#contains(android.telephony.CbGeoUtils.LatLng):
-
-
-
-MissingGetterMatchingBuilder: android.net.wifi.rtt.RangingRequest.Builder#addResponder(android.net.wifi.rtt.ResponderConfig):
- android.net.wifi.rtt.RangingRequest does not declare a `getResponders()` method matching method android.net.wifi.rtt.RangingRequest.Builder.addResponder(android.net.wifi.rtt.ResponderConfig)
-MissingGetterMatchingBuilder: android.security.keystore.KeyGenParameterSpec.Builder#setUid(int):
- android.security.keystore.KeyGenParameterSpec does not declare a `getUid()` method matching method android.security.keystore.KeyGenParameterSpec.Builder.setUid(int)
-MissingGetterMatchingBuilder: android.service.autofill.Dataset.Builder#setFieldInlinePresentation(android.view.autofill.AutofillId, android.view.autofill.AutofillValue, java.util.regex.Pattern, android.service.autofill.InlinePresentation):
- android.service.autofill.Dataset does not declare a `getFieldInlinePresentation()` method matching method android.service.autofill.Dataset.Builder.setFieldInlinePresentation(android.view.autofill.AutofillId,android.view.autofill.AutofillValue,java.util.regex.Pattern,android.service.autofill.InlinePresentation)
-MissingGetterMatchingBuilder: android.telecom.CallScreeningService.CallResponse.Builder#setShouldScreenCallViaAudioProcessing(boolean):
- android.telecom.CallScreeningService.CallResponse does not declare a `shouldScreenCallViaAudioProcessing()` method matching method android.telecom.CallScreeningService.CallResponse.Builder.setShouldScreenCallViaAudioProcessing(boolean)
-MissingGetterMatchingBuilder: android.telephony.mbms.DownloadRequest.Builder#setServiceId(String):
- android.telephony.mbms.DownloadRequest does not declare a `getServiceId()` method matching method android.telephony.mbms.DownloadRequest.Builder.setServiceId(String)
-
-
-MissingNullability: android.hardware.soundtrigger.SoundTrigger.ModuleProperties#toString():
-
-MissingNullability: android.hardware.soundtrigger.SoundTrigger.ModuleProperties#writeToParcel(android.os.Parcel, int) parameter #0:
-
-MissingNullability: android.media.session.MediaSessionManager.Callback#onAddressedPlayerChanged(android.content.ComponentName) parameter #0:
-
-MissingNullability: android.media.session.MediaSessionManager.Callback#onAddressedPlayerChanged(android.media.session.MediaSession.Token) parameter #0:
-
-MissingNullability: android.media.session.MediaSessionManager.Callback#onMediaKeyEventDispatched(android.view.KeyEvent, android.content.ComponentName) parameter #0:
-
-MissingNullability: android.media.session.MediaSessionManager.Callback#onMediaKeyEventDispatched(android.view.KeyEvent, android.content.ComponentName) parameter #1:
-
-MissingNullability: android.media.session.MediaSessionManager.Callback#onMediaKeyEventDispatched(android.view.KeyEvent, android.media.session.MediaSession.Token) parameter #0:
-
-MissingNullability: android.media.session.MediaSessionManager.Callback#onMediaKeyEventDispatched(android.view.KeyEvent, android.media.session.MediaSession.Token) parameter #1:
-
-MissingNullability: android.media.soundtrigger.SoundTriggerDetectionService#onUnbind(android.content.Intent) parameter #0:
-
-MissingNullability: android.media.tv.TvRecordingClient.RecordingCallback#onEvent(String, String, android.os.Bundle) parameter #0:
-
-MissingNullability: android.media.tv.TvRecordingClient.RecordingCallback#onEvent(String, String, android.os.Bundle) parameter #1:
-
-MissingNullability: android.media.tv.TvRecordingClient.RecordingCallback#onEvent(String, String, android.os.Bundle) parameter #2:
-
-MissingNullability: android.net.wifi.rtt.RangingRequest.Builder#addResponder(android.net.wifi.rtt.ResponderConfig):
-
-MissingNullability: android.printservice.recommendation.RecommendationService#attachBaseContext(android.content.Context) parameter #0:
-
-MissingNullability: android.provider.ContactsContract.MetadataSync#CONTENT_URI:
-
-MissingNullability: android.provider.ContactsContract.MetadataSync#METADATA_AUTHORITY_URI:
-
-MissingNullability: android.provider.ContactsContract.MetadataSyncState#CONTENT_URI:
-
-MissingNullability: android.provider.SearchIndexablesProvider#attachInfo(android.content.Context, android.content.pm.ProviderInfo) parameter #0:
-
-MissingNullability: android.provider.SearchIndexablesProvider#attachInfo(android.content.Context, android.content.pm.ProviderInfo) parameter #1:
-
-MissingNullability: android.service.autofill.augmented.AugmentedAutofillService#onUnbind(android.content.Intent) parameter #0:
-
-MissingNullability: android.service.contentcapture.ContentCaptureService#dump(java.io.FileDescriptor, java.io.PrintWriter, String[]) parameter #0:
-
-MissingNullability: android.service.contentcapture.ContentCaptureService#dump(java.io.FileDescriptor, java.io.PrintWriter, String[]) parameter #1:
-
-MissingNullability: android.service.contentcapture.ContentCaptureService#dump(java.io.FileDescriptor, java.io.PrintWriter, String[]) parameter #2:
-
-MissingNullability: android.service.notification.NotificationAssistantService#attachBaseContext(android.content.Context) parameter #0:
-
-MissingNullability: android.telecom.CallScreeningService.CallResponse.Builder#setShouldScreenCallFurther(boolean):
-
-MissingNullability: android.telephony.CallerInfo#toString():
-
-MissingNullability: android.telephony.CellBroadcastService#onBind(android.content.Intent):
-
-MissingNullability: android.telephony.CellBroadcastService#onBind(android.content.Intent) parameter #0:
-
-MissingNullability: android.telephony.CellBroadcastService#onCdmaCellBroadcastSms(int, byte[]) parameter #1:
-
-MissingNullability: android.telephony.CellBroadcastService#onCdmaCellBroadcastSms(int, byte[], int) parameter #1:
-
-MissingNullability: android.telephony.CellBroadcastService#onGsmCellBroadcastSms(int, byte[]) parameter #1:
-
-MissingNullability: android.telephony.ModemActivityInfo#toString():
-
-MissingNullability: android.telephony.ModemActivityInfo#writeToParcel(android.os.Parcel, int) parameter #0:
-
-MissingNullability: android.telephony.NetworkService#onUnbind(android.content.Intent) parameter #0:
-
-MissingNullability: android.telephony.SmsCbCmasInfo#toString():
-
-MissingNullability: android.telephony.SmsCbCmasInfo#writeToParcel(android.os.Parcel, int) parameter #0:
-
-MissingNullability: android.telephony.SmsCbEtwsInfo#toString():
-
-MissingNullability: android.telephony.SmsCbEtwsInfo#writeToParcel(android.os.Parcel, int) parameter #0:
-
-MissingNullability: android.telephony.SmsCbLocation#equals(Object) parameter #0:
-
-MissingNullability: android.telephony.SmsCbLocation#toString():
-
-MissingNullability: android.telephony.SmsCbLocation#writeToParcel(android.os.Parcel, int) parameter #0:
-
-MissingNullability: android.telephony.SmsCbMessage#toString():
-
-MissingNullability: android.telephony.SmsCbMessage#writeToParcel(android.os.Parcel, int) parameter #0:
-
-MissingNullability: android.telephony.SubscriptionPlan.Builder#createRecurringDaily(java.time.ZonedDateTime) parameter #0:
-
-MissingNullability: android.telephony.SubscriptionPlan.Builder#createRecurringMonthly(java.time.ZonedDateTime) parameter #0:
-
-MissingNullability: android.telephony.SubscriptionPlan.Builder#createRecurringWeekly(java.time.ZonedDateTime) parameter #0:
-
-MissingNullability: android.telephony.cdma.CdmaSmsCbProgramData#toString():
-
-MissingNullability: android.telephony.cdma.CdmaSmsCbProgramData#writeToParcel(android.os.Parcel, int) parameter #0:
-
-MissingNullability: android.telephony.data.DataService#onUnbind(android.content.Intent) parameter #0:
-
-MissingNullability: android.telephony.ims.stub.ImsSmsImplBase#onSmsStatusReportReceived(int, String, byte[]) parameter #1:
-
-MissingNullability: android.telephony.ims.stub.ImsSmsImplBase#onSmsStatusReportReceived(int, String, byte[]) parameter #2:
-
-MissingNullability: android.telephony.mbms.DownloadRequest.Builder#setServiceId(String):
-
-MissingNullability: android.telephony.mbms.DownloadRequest.Builder#setServiceId(String) parameter #0:
-
-
-
-MutableBareField: android.net.IpConfiguration#httpProxy:
-
-MutableBareField: android.net.IpConfiguration#ipAssignment:
-
-MutableBareField: android.net.IpConfiguration#proxySettings:
-
-MutableBareField: android.net.IpConfiguration#staticIpConfiguration:
-
-MutableBareField: android.net.wifi.WifiConfiguration#allowAutojoin:
-
-MutableBareField: android.net.wifi.WifiConfiguration#carrierId:
-
-MutableBareField: android.net.wifi.WifiConfiguration#fromWifiNetworkSpecifier:
-
-MutableBareField: android.net.wifi.WifiConfiguration#fromWifiNetworkSuggestion:
-
-MutableBareField: android.net.wifi.WifiConfiguration#macRandomizationSetting:
-
-MutableBareField: android.net.wifi.WifiConfiguration#meteredOverride:
-
-MutableBareField: android.net.wifi.WifiConfiguration#requirePmf:
-
-MutableBareField: android.net.wifi.WifiConfiguration#saePasswordId:
-
-MutableBareField: android.net.wifi.WifiConfiguration#shared:
-
-MutableBareField: android.net.wifi.WifiConfiguration#subscriptionId:
- Bare field subscriptionId must be marked final, or moved behind accessors if mutable
-MutableBareField: android.net.wifi.WifiScanner.ScanSettings#type:
-
-
-
-NoClone: android.service.contentcapture.ContentCaptureService#dump(java.io.FileDescriptor, java.io.PrintWriter, String[]) parameter #0:
-
-
-
-NoSettingsProvider: android.provider.Settings.Global#TETHER_OFFLOAD_DISABLED:
-
-NoSettingsProvider: android.provider.Settings.Global#TETHER_SUPPORTED:
-
-
-
-NotCloseable: android.bluetooth.BluetoothA2dpSink:
-
-NotCloseable: android.bluetooth.BluetoothMap:
-
-NotCloseable: android.bluetooth.BluetoothPan:
-
-NotCloseable: android.bluetooth.BluetoothPbap:
-
-
-
-OnNameExpected: android.content.ContentProvider#checkUriPermission(android.net.Uri, int, int):
-
-
-
-PairedRegistration: android.net.wifi.nl80211.WifiNl80211Manager#registerApCallback(String, java.util.concurrent.Executor, android.net.wifi.nl80211.WifiNl80211Manager.SoftApCallback):
-
-
-
-ProtectedMember: android.printservice.recommendation.RecommendationService#attachBaseContext(android.content.Context):
-
-ProtectedMember: android.service.contentcapture.ContentCaptureService#dump(java.io.FileDescriptor, java.io.PrintWriter, String[]):
-
-ProtectedMember: android.service.notification.NotificationAssistantService#attachBaseContext(android.content.Context):
-
-
-
-SamShouldBeLast: android.accounts.AccountManager#addAccount(String, String, String[], android.os.Bundle, android.app.Activity, android.accounts.AccountManagerCallback<android.os.Bundle>, android.os.Handler):
-
-SamShouldBeLast: android.accounts.AccountManager#addOnAccountsUpdatedListener(android.accounts.OnAccountsUpdateListener, android.os.Handler, boolean):
-
-SamShouldBeLast: android.accounts.AccountManager#addOnAccountsUpdatedListener(android.accounts.OnAccountsUpdateListener, android.os.Handler, boolean, String[]):
-
-SamShouldBeLast: android.accounts.AccountManager#confirmCredentials(android.accounts.Account, android.os.Bundle, android.app.Activity, android.accounts.AccountManagerCallback<android.os.Bundle>, android.os.Handler):
-
-SamShouldBeLast: android.accounts.AccountManager#editProperties(String, android.app.Activity, android.accounts.AccountManagerCallback<android.os.Bundle>, android.os.Handler):
-
-SamShouldBeLast: android.accounts.AccountManager#finishSession(android.os.Bundle, android.app.Activity, android.accounts.AccountManagerCallback<android.os.Bundle>, android.os.Handler):
-
-SamShouldBeLast: android.accounts.AccountManager#getAccountsByTypeAndFeatures(String, String[], android.accounts.AccountManagerCallback<android.accounts.Account[]>, android.os.Handler):
-
-SamShouldBeLast: android.accounts.AccountManager#getAuthToken(android.accounts.Account, String, android.os.Bundle, android.app.Activity, android.accounts.AccountManagerCallback<android.os.Bundle>, android.os.Handler):
-
-SamShouldBeLast: android.accounts.AccountManager#getAuthToken(android.accounts.Account, String, android.os.Bundle, boolean, android.accounts.AccountManagerCallback<android.os.Bundle>, android.os.Handler):
-
-SamShouldBeLast: android.accounts.AccountManager#getAuthToken(android.accounts.Account, String, boolean, android.accounts.AccountManagerCallback<android.os.Bundle>, android.os.Handler):
-
-SamShouldBeLast: android.accounts.AccountManager#getAuthTokenByFeatures(String, String, String[], android.app.Activity, android.os.Bundle, android.os.Bundle, android.accounts.AccountManagerCallback<android.os.Bundle>, android.os.Handler):
-
-SamShouldBeLast: android.accounts.AccountManager#hasFeatures(android.accounts.Account, String[], android.accounts.AccountManagerCallback<java.lang.Boolean>, android.os.Handler):
-
-SamShouldBeLast: android.accounts.AccountManager#isCredentialsUpdateSuggested(android.accounts.Account, String, android.accounts.AccountManagerCallback<java.lang.Boolean>, android.os.Handler):
-
-SamShouldBeLast: android.accounts.AccountManager#removeAccount(android.accounts.Account, android.accounts.AccountManagerCallback<java.lang.Boolean>, android.os.Handler):
-
-SamShouldBeLast: android.accounts.AccountManager#removeAccount(android.accounts.Account, android.app.Activity, android.accounts.AccountManagerCallback<android.os.Bundle>, android.os.Handler):
-
-SamShouldBeLast: android.accounts.AccountManager#renameAccount(android.accounts.Account, String, android.accounts.AccountManagerCallback<android.accounts.Account>, android.os.Handler):
-
-SamShouldBeLast: android.accounts.AccountManager#startAddAccountSession(String, String, String[], android.os.Bundle, android.app.Activity, android.accounts.AccountManagerCallback<android.os.Bundle>, android.os.Handler):
-
-SamShouldBeLast: android.accounts.AccountManager#startUpdateCredentialsSession(android.accounts.Account, String, android.os.Bundle, android.app.Activity, android.accounts.AccountManagerCallback<android.os.Bundle>, android.os.Handler):
-
-SamShouldBeLast: android.accounts.AccountManager#updateCredentials(android.accounts.Account, String, android.os.Bundle, android.app.Activity, android.accounts.AccountManagerCallback<android.os.Bundle>, android.os.Handler):
-
-SamShouldBeLast: android.app.AlarmManager#set(int, long, String, android.app.AlarmManager.OnAlarmListener, android.os.Handler):
-
-SamShouldBeLast: android.app.AlarmManager#setExact(int, long, String, android.app.AlarmManager.OnAlarmListener, android.os.Handler):
-
-SamShouldBeLast: android.app.AlarmManager#setWindow(int, long, long, String, android.app.AlarmManager.OnAlarmListener, android.os.Handler):
-
-SamShouldBeLast: android.app.WallpaperInfo#dump(android.util.Printer, String):
-
-SamShouldBeLast: android.app.WallpaperManager#addOnColorsChangedListener(android.app.WallpaperManager.OnColorsChangedListener, android.os.Handler):
-
-SamShouldBeLast: android.app.admin.DevicePolicyManager#installSystemUpdate(android.content.ComponentName, android.net.Uri, java.util.concurrent.Executor, android.app.admin.DevicePolicyManager.InstallSystemUpdateCallback):
-
-SamShouldBeLast: android.content.Context#bindIsolatedService(android.content.Intent, int, String, java.util.concurrent.Executor, android.content.ServiceConnection):
-
-SamShouldBeLast: android.content.Context#bindService(android.content.Intent, int, java.util.concurrent.Executor, android.content.ServiceConnection):
-
-SamShouldBeLast: android.content.ContextWrapper#bindIsolatedService(android.content.Intent, int, String, java.util.concurrent.Executor, android.content.ServiceConnection):
-
-SamShouldBeLast: android.content.ContextWrapper#bindService(android.content.Intent, int, java.util.concurrent.Executor, android.content.ServiceConnection):
-
-SamShouldBeLast: android.content.IntentFilter#dump(android.util.Printer, String):
-
-SamShouldBeLast: android.content.pm.ApplicationInfo#dump(android.util.Printer, String):
-
-SamShouldBeLast: android.content.pm.LauncherApps#registerPackageInstallerSessionCallback(java.util.concurrent.Executor, android.content.pm.PackageInstaller.SessionCallback):
-
-SamShouldBeLast: android.content.pm.PackageItemInfo#dumpBack(android.util.Printer, String):
-
-SamShouldBeLast: android.content.pm.PackageItemInfo#dumpFront(android.util.Printer, String):
-
-SamShouldBeLast: android.content.pm.ResolveInfo#dump(android.util.Printer, String):
-
-SamShouldBeLast: android.location.Location#dump(android.util.Printer, String):
-
-SamShouldBeLast: android.location.LocationManager#addNmeaListener(android.location.OnNmeaMessageListener, android.os.Handler):
-
-SamShouldBeLast: android.location.LocationManager#registerGnssMeasurementsCallback(java.util.concurrent.Executor, android.location.GnssMeasurementsEvent.Callback):
-
-SamShouldBeLast: android.location.LocationManager#registerGnssNavigationMessageCallback(java.util.concurrent.Executor, android.location.GnssNavigationMessage.Callback):
-
-SamShouldBeLast: android.location.LocationManager#registerGnssStatusCallback(java.util.concurrent.Executor, android.location.GnssStatus.Callback):
-
-SamShouldBeLast: android.location.LocationManager#requestLocationUpdates(String, long, float, android.location.LocationListener, android.os.Looper):
-
-SamShouldBeLast: android.location.LocationManager#requestLocationUpdates(String, long, float, java.util.concurrent.Executor, android.location.LocationListener):
-
-SamShouldBeLast: android.location.LocationManager#requestLocationUpdates(android.location.LocationRequest, java.util.concurrent.Executor, android.location.LocationListener):
-
-SamShouldBeLast: android.location.LocationManager#requestLocationUpdates(long, float, android.location.Criteria, android.location.LocationListener, android.os.Looper):
-
-SamShouldBeLast: android.location.LocationManager#requestLocationUpdates(long, float, android.location.Criteria, java.util.concurrent.Executor, android.location.LocationListener):
-
-SamShouldBeLast: android.location.LocationManager#requestSingleUpdate(String, android.location.LocationListener, android.os.Looper):
-
-SamShouldBeLast: android.location.LocationManager#requestSingleUpdate(android.location.Criteria, android.location.LocationListener, android.os.Looper):
-
-SamShouldBeLast: android.media.AudioFocusRequest.Builder#setOnAudioFocusChangeListener(android.media.AudioManager.OnAudioFocusChangeListener, android.os.Handler):
-
-SamShouldBeLast: android.media.AudioManager#requestAudioFocus(android.media.AudioManager.OnAudioFocusChangeListener, int, int):
-
-SamShouldBeLast: android.media.AudioRecord#addOnRoutingChangedListener(android.media.AudioRouting.OnRoutingChangedListener, android.os.Handler):
-
-SamShouldBeLast: android.media.AudioRecord#registerAudioRecordingCallback(java.util.concurrent.Executor, android.media.AudioManager.AudioRecordingCallback):
-
-SamShouldBeLast: android.media.AudioRecordingMonitor#registerAudioRecordingCallback(java.util.concurrent.Executor, android.media.AudioManager.AudioRecordingCallback):
-
-SamShouldBeLast: android.media.AudioRouting#addOnRoutingChangedListener(android.media.AudioRouting.OnRoutingChangedListener, android.os.Handler):
-
-SamShouldBeLast: android.media.AudioTrack#addOnRoutingChangedListener(android.media.AudioRouting.OnRoutingChangedListener, android.os.Handler):
- SAM-compatible parameters (such as parameter 1, "listener", in android.media.AudioTrack.addOnRoutingChangedListener) should be last to improve Kotlin interoperability; see https://kotlinlang.org/docs/reference/java-interop.html#sam-conversions
-SamShouldBeLast: android.media.MediaPlayer#setOnRtpRxNoticeListener(android.content.Context, android.media.MediaPlayer.OnRtpRxNoticeListener, android.os.Handler):
- SAM-compatible parameters (such as parameter 2, "listener", in android.media.MediaPlayer.setOnRtpRxNoticeListener) should be last to improve Kotlin interoperability; see https://kotlinlang.org/docs/reference/java-interop.html#sam-conversions
-SamShouldBeLast: android.media.MediaRecorder#addOnRoutingChangedListener(android.media.AudioRouting.OnRoutingChangedListener, android.os.Handler):
-
-SamShouldBeLast: android.media.MediaRecorder#registerAudioRecordingCallback(java.util.concurrent.Executor, android.media.AudioManager.AudioRecordingCallback):
-
-SamShouldBeLast: android.media.session.MediaSessionManager#addOnActiveSessionsChangedListener(android.media.session.MediaSessionManager.OnActiveSessionsChangedListener, android.content.ComponentName):
-
-SamShouldBeLast: android.media.session.MediaSessionManager#addOnActiveSessionsChangedListener(android.media.session.MediaSessionManager.OnActiveSessionsChangedListener, android.content.ComponentName, android.os.Handler):
-
-SamShouldBeLast: android.media.session.MediaSessionManager#addOnSession2TokensChangedListener(android.media.session.MediaSessionManager.OnSession2TokensChangedListener, android.os.Handler):
-
-SamShouldBeLast: android.media.session.MediaSessionManager#registerCallback(java.util.concurrent.Executor, android.media.session.MediaSessionManager.Callback):
-
-SamShouldBeLast: android.net.ConnectivityManager#createSocketKeepalive(android.net.Network, android.net.IpSecManager.UdpEncapsulationSocket, java.net.InetAddress, java.net.InetAddress, java.util.concurrent.Executor, android.net.SocketKeepalive.Callback):
-
-SamShouldBeLast: android.net.wifi.WifiManager#startLocalOnlyHotspot(android.net.wifi.SoftApConfiguration, java.util.concurrent.Executor, android.net.wifi.WifiManager.LocalOnlyHotspotCallback):
-
-SamShouldBeLast: android.net.wifi.rtt.WifiRttManager#startRanging(android.net.wifi.rtt.RangingRequest, java.util.concurrent.Executor, android.net.wifi.rtt.RangingResultCallback):
-
-SamShouldBeLast: android.nfc.NfcAdapter#enableReaderMode(android.app.Activity, android.nfc.NfcAdapter.ReaderCallback, int, android.os.Bundle):
-
-SamShouldBeLast: android.nfc.NfcAdapter#ignore(android.nfc.Tag, int, android.nfc.NfcAdapter.OnTagRemovedListener, android.os.Handler):
-
-SamShouldBeLast: android.nfc.NfcAdapter#setBeamPushUrisCallback(android.nfc.NfcAdapter.CreateBeamUrisCallback, android.app.Activity):
-
-SamShouldBeLast: android.nfc.NfcAdapter#setNdefPushMessageCallback(android.nfc.NfcAdapter.CreateNdefMessageCallback, android.app.Activity, android.app.Activity...):
-
-SamShouldBeLast: android.nfc.NfcAdapter#setOnNdefPushCompleteCallback(android.nfc.NfcAdapter.OnNdefPushCompleteCallback, android.app.Activity, android.app.Activity...):
-
-SamShouldBeLast: android.os.Binder#attachInterface(android.os.IInterface, String):
-
-SamShouldBeLast: android.os.Binder#linkToDeath(android.os.IBinder.DeathRecipient, int):
-
-SamShouldBeLast: android.os.Binder#unlinkToDeath(android.os.IBinder.DeathRecipient, int):
-
-SamShouldBeLast: android.os.Handler#dump(android.util.Printer, String):
-
-SamShouldBeLast: android.os.Handler#postAtTime(Runnable, Object, long):
-
-SamShouldBeLast: android.os.Handler#postAtTime(Runnable, long):
-
-SamShouldBeLast: android.os.Handler#postDelayed(Runnable, Object, long):
-
-SamShouldBeLast: android.os.Handler#postDelayed(Runnable, long):
-
-SamShouldBeLast: android.os.Handler#removeCallbacks(Runnable, Object):
-
-SamShouldBeLast: android.os.IBinder#linkToDeath(android.os.IBinder.DeathRecipient, int):
-
-SamShouldBeLast: android.os.IBinder#unlinkToDeath(android.os.IBinder.DeathRecipient, int):
-
-SamShouldBeLast: android.os.RecoverySystem#verifyPackage(java.io.File, android.os.RecoverySystem.ProgressListener, java.io.File):
-
-SamShouldBeLast: android.telephony.MbmsDownloadSession#addProgressListener(android.telephony.mbms.DownloadRequest, java.util.concurrent.Executor, android.telephony.mbms.DownloadProgressListener):
-
-SamShouldBeLast: android.telephony.MbmsDownloadSession#addStatusListener(android.telephony.mbms.DownloadRequest, java.util.concurrent.Executor, android.telephony.mbms.DownloadStatusListener):
-
-SamShouldBeLast: android.telephony.MbmsDownloadSession#create(android.content.Context, java.util.concurrent.Executor, android.telephony.mbms.MbmsDownloadSessionCallback):
-
-SamShouldBeLast: android.telephony.MbmsDownloadSession#create(android.content.Context, java.util.concurrent.Executor, int, android.telephony.mbms.MbmsDownloadSessionCallback):
-
-SamShouldBeLast: android.telephony.MbmsGroupCallSession#create(android.content.Context, int, java.util.concurrent.Executor, android.telephony.mbms.MbmsGroupCallSessionCallback):
-
-SamShouldBeLast: android.telephony.MbmsGroupCallSession#create(android.content.Context, java.util.concurrent.Executor, android.telephony.mbms.MbmsGroupCallSessionCallback):
-
-SamShouldBeLast: android.telephony.MbmsGroupCallSession#startGroupCall(long, java.util.List<java.lang.Integer>, java.util.List<java.lang.Integer>, java.util.concurrent.Executor, android.telephony.mbms.GroupCallCallback):
-
-SamShouldBeLast: android.telephony.MbmsStreamingSession#create(android.content.Context, java.util.concurrent.Executor, android.telephony.mbms.MbmsStreamingSessionCallback):
-
-SamShouldBeLast: android.telephony.MbmsStreamingSession#create(android.content.Context, java.util.concurrent.Executor, int, android.telephony.mbms.MbmsStreamingSessionCallback):
-
-SamShouldBeLast: android.telephony.MbmsStreamingSession#startStreaming(android.telephony.mbms.StreamingServiceInfo, java.util.concurrent.Executor, android.telephony.mbms.StreamingServiceCallback):
-
-SamShouldBeLast: android.telephony.SmsManager#getSmsMessagesForFinancialApp(android.os.Bundle, java.util.concurrent.Executor, android.telephony.SmsManager.FinancialSmsCallback):
-
-SamShouldBeLast: android.telephony.SubscriptionManager#addOnOpportunisticSubscriptionsChangedListener(java.util.concurrent.Executor, android.telephony.SubscriptionManager.OnOpportunisticSubscriptionsChangedListener):
-
-SamShouldBeLast: android.telephony.TelephonyManager#requestCellInfoUpdate(java.util.concurrent.Executor, android.telephony.TelephonyManager.CellInfoCallback):
-
-SamShouldBeLast: android.telephony.TelephonyManager#requestNetworkScan(android.telephony.NetworkScanRequest, java.util.concurrent.Executor, android.telephony.TelephonyScanManager.NetworkScanCallback):
-
-SamShouldBeLast: android.telephony.TelephonyManager#setPreferredOpportunisticDataSubscription(int, boolean, java.util.concurrent.Executor, java.util.function.Consumer<java.lang.Integer>):
-
-SamShouldBeLast: android.telephony.TelephonyManager#updateAvailableNetworks(java.util.List<android.telephony.AvailableNetworkInfo>, java.util.concurrent.Executor, java.util.function.Consumer<java.lang.Integer>):
-
-SamShouldBeLast: android.view.View#postDelayed(Runnable, long):
-
-SamShouldBeLast: android.view.View#postOnAnimationDelayed(Runnable, long):
-
-SamShouldBeLast: android.view.View#scheduleDrawable(android.graphics.drawable.Drawable, Runnable, long):
-
-SamShouldBeLast: android.view.Window#addOnFrameMetricsAvailableListener(android.view.Window.OnFrameMetricsAvailableListener, android.os.Handler):
-
-SamShouldBeLast: android.view.accessibility.AccessibilityManager#addAccessibilityStateChangeListener(android.view.accessibility.AccessibilityManager.AccessibilityStateChangeListener, android.os.Handler):
-
-SamShouldBeLast: android.view.accessibility.AccessibilityManager#addTouchExplorationStateChangeListener(android.view.accessibility.AccessibilityManager.TouchExplorationStateChangeListener, android.os.Handler):
-
-SamShouldBeLast: android.webkit.WebChromeClient#onShowFileChooser(android.webkit.WebView, android.webkit.ValueCallback<android.net.Uri[]>, android.webkit.WebChromeClient.FileChooserParams):
-
-SamShouldBeLast: android.webkit.WebView#setWebViewRenderProcessClient(java.util.concurrent.Executor, android.webkit.WebViewRenderProcessClient):
-
-
-
-ServiceName: android.Manifest.permission#BIND_ATTENTION_SERVICE:
-
-ServiceName: android.Manifest.permission#BIND_AUGMENTED_AUTOFILL_SERVICE:
-
-ServiceName: android.Manifest.permission#BIND_CELL_BROADCAST_SERVICE:
-
-ServiceName: android.Manifest.permission#BIND_CONTENT_CAPTURE_SERVICE:
-
-ServiceName: android.Manifest.permission#BIND_CONTENT_SUGGESTIONS_SERVICE:
-
-ServiceName: android.Manifest.permission#BIND_EUICC_SERVICE:
-
-ServiceName: android.Manifest.permission#BIND_EXTERNAL_STORAGE_SERVICE:
-
-ServiceName: android.Manifest.permission#BIND_IMS_SERVICE:
-
-ServiceName: android.Manifest.permission#BIND_NETWORK_RECOMMENDATION_SERVICE:
-
-ServiceName: android.Manifest.permission#BIND_NOTIFICATION_ASSISTANT_SERVICE:
-
-ServiceName: android.Manifest.permission#BIND_PHONE_ACCOUNT_SUGGESTION_SERVICE:
-
-ServiceName: android.Manifest.permission#BIND_PRINT_RECOMMENDATION_SERVICE:
-
-ServiceName: android.Manifest.permission#BIND_RESOLVER_RANKER_SERVICE:
-
-ServiceName: android.Manifest.permission#BIND_RUNTIME_PERMISSION_PRESENTER_SERVICE:
-
-ServiceName: android.Manifest.permission#BIND_SETTINGS_SUGGESTIONS_SERVICE:
-
-ServiceName: android.Manifest.permission#BIND_SOUND_TRIGGER_DETECTION_SERVICE:
-
-ServiceName: android.Manifest.permission#BIND_TELEPHONY_DATA_SERVICE:
-
-ServiceName: android.Manifest.permission#BIND_TELEPHONY_NETWORK_SERVICE:
-
-ServiceName: android.Manifest.permission#BIND_TEXTCLASSIFIER_SERVICE:
-
-ServiceName: android.Manifest.permission#BIND_TV_REMOTE_SERVICE:
-
-ServiceName: android.Manifest.permission#PROVIDE_RESOLVER_RANKER_SERVICE:
-
-ServiceName: android.Manifest.permission#REQUEST_NOTIFICATION_ASSISTANT_SERVICE:
-
-ServiceName: android.provider.DeviceConfig#NAMESPACE_PACKAGE_MANAGER_SERVICE:
-
-
-
-UserHandle: android.companion.CompanionDeviceManager#isDeviceAssociated(String, android.net.MacAddress, android.os.UserHandle):
-
-
-
-UserHandleName: android.telephony.CellBroadcastIntents#sendOrderedBroadcastForBackgroundReceivers(android.content.Context, android.os.UserHandle, android.content.Intent, String, String, android.content.BroadcastReceiver, android.os.Handler, int, String, android.os.Bundle):
-
diff --git a/api/system-removed.txt b/api/system-removed.txt
deleted file mode 100644
index 3acc225..0000000
--- a/api/system-removed.txt
+++ /dev/null
@@ -1,198 +0,0 @@
-// Signature format: 2.0
-package android {
-
- public static final class Manifest.permission {
- field public static final String MANAGE_DEVICE_ADMINS = "android.permission.MANAGE_DEVICE_ADMINS";
- }
-
-}
-
-package android.app {
-
- public class AppOpsManager {
- method @Deprecated @NonNull @RequiresPermission(android.Manifest.permission.GET_APP_OPS_STATS) public java.util.List<android.app.AppOpsManager.PackageOps> getOpsForPackage(int, @NonNull String, @Nullable int[]);
- method @Deprecated public void setNotedAppOpsCollector(@Nullable android.app.AppOpsManager.AppOpsCollector);
- }
-
- @Deprecated public abstract static class AppOpsManager.AppOpsCollector extends android.app.AppOpsManager.OnOpNotedCallback {
- ctor public AppOpsManager.AppOpsCollector();
- method @NonNull public java.util.concurrent.Executor getAsyncNotedExecutor();
- }
-
- public class Notification implements android.os.Parcelable {
- method public static Class<? extends android.app.Notification.Style> getNotificationStyleClass(String);
- }
-
- public static final class Notification.TvExtender implements android.app.Notification.Extender {
- method @Deprecated public String getChannel();
- }
-
-}
-
-package android.app.backup {
-
- public class RestoreSession {
- method @Deprecated public int restoreSome(long, android.app.backup.RestoreObserver, android.app.backup.BackupManagerMonitor, String[]);
- method @Deprecated public int restoreSome(long, android.app.backup.RestoreObserver, String[]);
- }
-
-}
-
-package android.app.prediction {
-
- public static final class AppTarget.Builder {
- ctor @Deprecated public AppTarget.Builder(@NonNull android.app.prediction.AppTargetId);
- method @Deprecated @NonNull public android.app.prediction.AppTarget.Builder setTarget(@NonNull String, @NonNull android.os.UserHandle);
- method @Deprecated @NonNull public android.app.prediction.AppTarget.Builder setTarget(@NonNull android.content.pm.ShortcutInfo);
- }
-
-}
-
-package android.content {
-
- public class Intent implements java.lang.Cloneable android.os.Parcelable {
- field @Deprecated public static final String ACTION_DEVICE_INITIALIZATION_WIZARD = "android.intent.action.DEVICE_INITIALIZATION_WIZARD";
- field @Deprecated public static final String ACTION_MASTER_CLEAR = "android.intent.action.MASTER_CLEAR";
- field @Deprecated public static final String ACTION_SERVICE_STATE = "android.intent.action.SERVICE_STATE";
- field @Deprecated public static final String EXTRA_CDMA_DEFAULT_ROAMING_INDICATOR = "cdmaDefaultRoamingIndicator";
- field @Deprecated public static final String EXTRA_CDMA_ROAMING_INDICATOR = "cdmaRoamingIndicator";
- field @Deprecated public static final String EXTRA_CSS_INDICATOR = "cssIndicator";
- field @Deprecated public static final String EXTRA_DATA_OPERATOR_ALPHA_LONG = "data-operator-alpha-long";
- field @Deprecated public static final String EXTRA_DATA_OPERATOR_ALPHA_SHORT = "data-operator-alpha-short";
- field @Deprecated public static final String EXTRA_DATA_OPERATOR_NUMERIC = "data-operator-numeric";
- field @Deprecated public static final String EXTRA_DATA_RADIO_TECH = "dataRadioTechnology";
- field @Deprecated public static final String EXTRA_DATA_REG_STATE = "dataRegState";
- field @Deprecated public static final String EXTRA_DATA_ROAMING_TYPE = "dataRoamingType";
- field @Deprecated public static final String EXTRA_EMERGENCY_ONLY = "emergencyOnly";
- field @Deprecated public static final String EXTRA_IS_DATA_ROAMING_FROM_REGISTRATION = "isDataRoamingFromRegistration";
- field @Deprecated public static final String EXTRA_IS_USING_CARRIER_AGGREGATION = "isUsingCarrierAggregation";
- field @Deprecated public static final String EXTRA_LTE_EARFCN_RSRP_BOOST = "LteEarfcnRsrpBoost";
- field @Deprecated public static final String EXTRA_MANUAL = "manual";
- field @Deprecated public static final String EXTRA_NETWORK_ID = "networkId";
- field @Deprecated public static final String EXTRA_OPERATOR_ALPHA_LONG = "operator-alpha-long";
- field @Deprecated public static final String EXTRA_OPERATOR_ALPHA_SHORT = "operator-alpha-short";
- field @Deprecated public static final String EXTRA_OPERATOR_NUMERIC = "operator-numeric";
- field @Deprecated public static final String EXTRA_SYSTEM_ID = "systemId";
- field @Deprecated public static final String EXTRA_VOICE_RADIO_TECH = "radioTechnology";
- field @Deprecated public static final String EXTRA_VOICE_REG_STATE = "voiceRegState";
- field @Deprecated public static final String EXTRA_VOICE_ROAMING_TYPE = "voiceRoamingType";
- }
-
-}
-
-package android.content.pm {
-
- public class PackageItemInfo {
- field @Deprecated public static final int SAFE_LABEL_FLAG_FIRST_LINE = 4; // 0x4
- field @Deprecated public static final int SAFE_LABEL_FLAG_SINGLE_LINE = 2; // 0x2
- field @Deprecated public static final int SAFE_LABEL_FLAG_TRIM = 1; // 0x1
- }
-
-}
-
-package android.hardware.hdmi {
-
- public final class HdmiControlManager {
- method @Deprecated public java.util.List<android.hardware.hdmi.HdmiDeviceInfo> getConnectedDevicesList();
- method @Deprecated public boolean isRemoteDeviceConnected(@NonNull android.hardware.hdmi.HdmiDeviceInfo);
- method @Deprecated public void powerOffRemoteDevice(@NonNull android.hardware.hdmi.HdmiDeviceInfo);
- method @Deprecated public void powerOnRemoteDevice(android.hardware.hdmi.HdmiDeviceInfo);
- method @Deprecated public void requestRemoteDeviceToBecomeActiveSource(@NonNull android.hardware.hdmi.HdmiDeviceInfo);
- }
-
-}
-
-package android.location {
-
- public class LocationManager {
- method @Deprecated public boolean addGpsMeasurementListener(android.location.GpsMeasurementsEvent.Listener);
- method @Deprecated public boolean addGpsNavigationMessageListener(android.location.GpsNavigationMessageEvent.Listener);
- method @Deprecated public void removeGpsMeasurementListener(android.location.GpsMeasurementsEvent.Listener);
- method @Deprecated public void removeGpsNavigationMessageListener(android.location.GpsNavigationMessageEvent.Listener);
- method @Deprecated @RequiresPermission(android.Manifest.permission.LOCATION_HARDWARE) public void setLocationControllerExtraPackage(String);
- method @Deprecated @RequiresPermission(android.Manifest.permission.LOCATION_HARDWARE) public void setLocationControllerExtraPackageEnabled(boolean);
- }
-
-}
-
-package android.media.tv {
-
- public final class TvInputManager {
- method @RequiresPermission(android.Manifest.permission.TV_INPUT_HARDWARE) public android.media.tv.TvInputManager.Hardware acquireTvInputHardware(int, android.media.tv.TvInputManager.HardwareCallback, android.media.tv.TvInputInfo);
- }
-
- public static final class TvInputManager.Hardware {
- method public boolean dispatchKeyEventToHdmi(android.view.KeyEvent);
- }
-
-}
-
-package android.net.wifi {
-
- @Deprecated public class BatchedScanResult implements android.os.Parcelable {
- ctor public BatchedScanResult();
- ctor public BatchedScanResult(android.net.wifi.BatchedScanResult);
- field public final java.util.List<android.net.wifi.ScanResult> scanResults;
- field public boolean truncated;
- }
-
- public final class ScanResult implements android.os.Parcelable {
- field public boolean untrusted;
- }
-
-}
-
-package android.os {
-
- public class Build {
- field public static final boolean PERMISSIONS_REVIEW_REQUIRED = true;
- }
-
-}
-
-package android.service.notification {
-
- public abstract class NotificationListenerService extends android.app.Service {
- method public android.service.notification.StatusBarNotification[] getActiveNotifications(int);
- method public android.service.notification.StatusBarNotification[] getActiveNotifications(String[], int);
- method public void registerAsSystemService(android.content.Context, android.content.ComponentName, int) throws android.os.RemoteException;
- method public final void setOnNotificationPostedTrim(int);
- method public final void snoozeNotification(String, String);
- method public void unregisterAsSystemService() throws android.os.RemoteException;
- field public static final int TRIM_FULL = 0; // 0x0
- field public static final int TRIM_LIGHT = 1; // 0x1
- }
-
- public static class NotificationListenerService.Ranking {
- method public java.util.List<java.lang.String> getAdditionalPeople();
- method public java.util.List<android.service.notification.SnoozeCriterion> getSnoozeCriteria();
- }
-
-}
-
-package android.telecom {
-
- public class TelecomManager {
- method @Deprecated @RequiresPermission(allOf={android.Manifest.permission.MODIFY_PHONE_STATE, android.Manifest.permission.WRITE_SECURE_SETTINGS}) public boolean setDefaultDialer(@Nullable String);
- }
-
-}
-
-package android.telephony {
-
- public class TelephonyManager {
- method @Deprecated @RequiresPermission(android.Manifest.permission.MODIFY_PHONE_STATE) public void answerRingingCall();
- method @Deprecated @RequiresPermission(android.Manifest.permission.CALL_PHONE) public boolean endCall();
- method @Deprecated public void silenceRinger();
- }
-
-}
-
-package android.telephony.data {
-
- public final class DataCallResponse implements android.os.Parcelable {
- ctor public DataCallResponse(int, int, int, int, int, @Nullable String, @Nullable java.util.List<android.net.LinkAddress>, @Nullable java.util.List<java.net.InetAddress>, @Nullable java.util.List<java.net.InetAddress>, @Nullable java.util.List<java.net.InetAddress>, int);
- }
-
-}
-
diff --git a/cmds/am/src/com/android/commands/am/Am.java b/cmds/am/src/com/android/commands/am/Am.java
index bdb8380..ebe6199 100644
--- a/cmds/am/src/com/android/commands/am/Am.java
+++ b/cmds/am/src/com/android/commands/am/Am.java
@@ -186,6 +186,8 @@
instrument.userId = parseUserArg(nextArgRequired());
} else if (opt.equals("--abi")) {
instrument.abi = nextArgRequired();
+ } else if (opt.equals("--no-restart")) {
+ instrument.noRestart = true;
} else {
System.err.println("Error: Unknown option: " + opt);
return;
diff --git a/cmds/am/src/com/android/commands/am/Instrument.java b/cmds/am/src/com/android/commands/am/Instrument.java
index 7c30c8b..2be8264 100644
--- a/cmds/am/src/com/android/commands/am/Instrument.java
+++ b/cmds/am/src/com/android/commands/am/Instrument.java
@@ -19,6 +19,7 @@
import static android.app.ActivityManager.INSTR_FLAG_DISABLE_HIDDEN_API_CHECKS;
import static android.app.ActivityManager.INSTR_FLAG_DISABLE_ISOLATED_STORAGE;
import static android.app.ActivityManager.INSTR_FLAG_DISABLE_TEST_API_CHECKS;
+import static android.app.ActivityManager.INSTR_FLAG_NO_RESTART;
import android.app.IActivityManager;
import android.app.IInstrumentationWatcher;
@@ -89,6 +90,7 @@
public boolean disableTestApiChecks = true;
public boolean disableIsolatedStorage = false;
public String abi = null;
+ public boolean noRestart = false;
public int userId = UserHandle.USER_CURRENT;
public Bundle args = new Bundle();
// Required
@@ -514,6 +516,9 @@
if (disableIsolatedStorage) {
flags |= INSTR_FLAG_DISABLE_ISOLATED_STORAGE;
}
+ if (noRestart) {
+ flags |= INSTR_FLAG_NO_RESTART;
+ }
if (!mAm.startInstrumentation(cn, profileFile, flags, args, watcher, connection, userId,
abi)) {
throw new AndroidException("INSTRUMENTATION_FAILED: " + cn.flattenToString());
diff --git a/cmds/idmap2/idmap2/Lookup.cpp b/cmds/idmap2/idmap2/Lookup.cpp
index c441709..8323d0b 100644
--- a/cmds/idmap2/idmap2/Lookup.cpp
+++ b/cmds/idmap2/idmap2/Lookup.cpp
@@ -45,11 +45,8 @@
using android::ApkAssetsCookie;
using android::AssetManager2;
using android::ConfigDescription;
-using android::is_valid_resid;
-using android::kInvalidCookie;
using android::Res_value;
using android::ResStringPool;
-using android::ResTable_config;
using android::StringPiece16;
using android::base::StringPrintf;
using android::idmap2::CommandLineOptions;
@@ -59,7 +56,6 @@
using android::idmap2::Result;
using android::idmap2::Unit;
using android::idmap2::utils::ExtractOverlayManifestInfo;
-using android::util::Utf16ToUtf8;
namespace {
@@ -69,25 +65,23 @@
// first, try to parse as a hex number
char* endptr = nullptr;
- ResourceId resid;
- resid = strtol(res.c_str(), &endptr, kBaseHex);
+ const ResourceId parsed_resid = strtol(res.c_str(), &endptr, kBaseHex);
if (*endptr == '\0') {
- return resid;
+ return parsed_resid;
}
// next, try to parse as a package:type/name string
- resid = am.GetResourceId(res, "", fallback_package);
- if (is_valid_resid(resid)) {
- return resid;
+ if (auto resid = am.GetResourceId(res, "", fallback_package)) {
+ return *resid;
}
// end of the road: res could not be parsed
return Error("failed to obtain resource id for %s", res.c_str());
}
-void PrintValue(AssetManager2* const am, const Res_value& value, const ApkAssetsCookie& cookie,
+void PrintValue(AssetManager2* const am, const AssetManager2::SelectedValue& value,
std::string* const out) {
- switch (value.dataType) {
+ switch (value.type) {
case Res_value::TYPE_INT_DEC:
out->append(StringPrintf("%d", value.data));
break;
@@ -98,30 +92,21 @@
out->append(value.data != 0 ? "true" : "false");
break;
case Res_value::TYPE_STRING: {
- const ResStringPool* pool = am->GetStringPoolForCookie(cookie);
+ const ResStringPool* pool = am->GetStringPoolForCookie(value.cookie);
out->append("\"");
- size_t len;
- if (pool->isUTF8()) {
- const char* str = pool->string8At(value.data, &len);
- out->append(str, len);
- } else {
- const char16_t* str16 = pool->stringAt(value.data, &len);
- out->append(Utf16ToUtf8(StringPiece16(str16, len)));
+ if (auto str = pool->string8ObjectAt(value.data)) {
+ out->append(*str);
}
- out->append("\"");
} break;
default:
- out->append(StringPrintf("dataType=0x%02x data=0x%08x", value.dataType, value.data));
+ out->append(StringPrintf("dataType=0x%02x data=0x%08x", value.type, value.data));
break;
}
}
Result<std::string> WARN_UNUSED GetValue(AssetManager2* const am, ResourceId resid) {
- Res_value value;
- ResTable_config config;
- uint32_t flags;
- ApkAssetsCookie cookie = am->GetResource(resid, true, 0, &value, &config, &flags);
- if (cookie == kInvalidCookie) {
+ auto value = am->GetResource(resid);
+ if (!value.has_value()) {
return Error("no resource 0x%08x in asset manager", resid);
}
@@ -129,41 +114,35 @@
// TODO(martenkongstad): use optional parameter GetResource(..., std::string*
// stacktrace = NULL) instead
- out.append(StringPrintf("cookie=%d ", cookie));
+ out.append(StringPrintf("cookie=%d ", value->cookie));
out.append("config='");
- out.append(config.toString().c_str());
+ out.append(value->config.toString().c_str());
out.append("' value=");
- if (value.dataType == Res_value::TYPE_REFERENCE) {
- const android::ResolvedBag* bag = am->GetBag(static_cast<uint32_t>(value.data));
- if (bag == nullptr) {
- out.append(StringPrintf("dataType=0x%02x data=0x%08x", value.dataType, value.data));
+ if (value->type == Res_value::TYPE_REFERENCE) {
+ auto bag_result = am->GetBag(static_cast<uint32_t>(value->data));
+ if (!bag_result.has_value()) {
+ out.append(StringPrintf("dataType=0x%02x data=0x%08x", value->type, value->data));
return out;
}
+
out.append("[");
- Res_value bag_val;
- ResTable_config selected_config;
- uint32_t flags;
- uint32_t ref;
- ApkAssetsCookie bag_cookie;
+ const android::ResolvedBag* bag = bag_result.value();
for (size_t i = 0; i < bag->entry_count; ++i) {
- const android::ResolvedBag::Entry& entry = bag->entries[i];
- bag_val = entry.value;
- bag_cookie = am->ResolveReference(entry.cookie, &bag_val, &selected_config, &flags, &ref);
- if (bag_cookie == kInvalidCookie) {
- out.append(
- StringPrintf("Error: dataType=0x%02x data=0x%08x", bag_val.dataType, bag_val.data));
+ AssetManager2::SelectedValue entry(bag, bag->entries[i]);
+ if (am->ResolveReference(entry).has_value()) {
+ out.append(StringPrintf("Error: dataType=0x%02x data=0x%08x", entry.type, entry.data));
continue;
}
- PrintValue(am, bag_val, bag_cookie, &out);
+ PrintValue(am, entry, &out);
if (i != bag->entry_count - 1) {
out.append(", ");
}
}
out.append("]");
} else {
- PrintValue(am, value, cookie, &out);
+ PrintValue(am, *value, &out);
}
return out;
diff --git a/cmds/idmap2/idmap2d/Idmap2Service.h b/cmds/idmap2/idmap2d/Idmap2Service.h
index 1d2090c..0127e87 100644
--- a/cmds/idmap2/idmap2d/Idmap2Service.h
+++ b/cmds/idmap2/idmap2d/Idmap2Service.h
@@ -17,8 +17,6 @@
#ifndef IDMAP2_IDMAP2D_IDMAP2SERVICE_H_
#define IDMAP2_IDMAP2D_IDMAP2SERVICE_H_
-#include <string>
-
#include <android-base/unique_fd.h>
#include <binder/BinderService.h>
diff --git a/cmds/idmap2/include/idmap2/ResourceMapping.h b/cmds/idmap2/include/idmap2/ResourceMapping.h
index 0a58ec4..f66916c 100644
--- a/cmds/idmap2/include/idmap2/ResourceMapping.h
+++ b/cmds/idmap2/include/idmap2/ResourceMapping.h
@@ -117,7 +117,8 @@
static Result<ResourceMapping> CreateResourceMappingLegacy(const AssetManager2* target_am,
const AssetManager2* overlay_am,
const LoadedPackage* target_package,
- const LoadedPackage* overlay_package);
+ const LoadedPackage* overlay_package,
+ LogInfo& log_info);
// Removes resources that do not pass policy or overlayable checks of the target package.
void FilterOverlayableResources(const AssetManager2* target_am,
diff --git a/cmds/idmap2/libidmap2/PrettyPrintVisitor.cpp b/cmds/idmap2/libidmap2/PrettyPrintVisitor.cpp
index a93202a..3037a79 100644
--- a/cmds/idmap2/libidmap2/PrettyPrintVisitor.cpp
+++ b/cmds/idmap2/libidmap2/PrettyPrintVisitor.cpp
@@ -100,10 +100,9 @@
stream_ << TAB << base::StringPrintf("0x%08x -> ", target_entry.target_id)
<< utils::DataTypeToString(target_entry.value.data_type);
- size_t unused;
if (target_entry.value.data_type == Res_value::TYPE_STRING) {
- auto str = string_pool.stringAt(target_entry.value.data_value - string_pool_offset, &unused);
- stream_ << " \"" << StringPiece16(str) << "\"";
+ auto str = string_pool.stringAt(target_entry.value.data_value - string_pool_offset);
+ stream_ << " \"" << str.value_or(StringPiece16(u"")) << "\"";
} else {
stream_ << " " << base::StringPrintf("0x%08x", target_entry.value.data_value);
}
diff --git a/cmds/idmap2/libidmap2/ResourceMapping.cpp b/cmds/idmap2/libidmap2/ResourceMapping.cpp
index 31f1c16..d777cbf 100644
--- a/cmds/idmap2/libidmap2/ResourceMapping.cpp
+++ b/cmds/idmap2/libidmap2/ResourceMapping.cpp
@@ -71,9 +71,10 @@
if (!target_package.DefinesOverlayable()) {
return (sDefaultPolicies & fulfilled_policies) != 0
? Result<Unit>({})
- : Error("overlay must be preinstalled, signed with the same signature as the target,"
- " or signed with the same signature as the package referenced through"
- " <overlay-config-signature>.");
+ : Error(
+ "overlay must be preinstalled, signed with the same signature as the target,"
+ " or signed with the same signature as the package referenced through"
+ " <overlay-config-signature>.");
}
const OverlayableInfo* overlayable_info = target_package.GetOverlayableInfo(target_resource);
@@ -119,32 +120,25 @@
Result<std::unique_ptr<Asset>> OpenNonAssetFromResource(const ResourceId& resource_id,
const AssetManager2& asset_manager) {
- Res_value value{};
- ResTable_config selected_config{};
- uint32_t flags;
- auto cookie =
- asset_manager.GetResource(resource_id, /* may_be_bag */ false,
- /* density_override */ 0U, &value, &selected_config, &flags);
- if (cookie == kInvalidCookie) {
+ auto value = asset_manager.GetResource(resource_id);
+ if (!value.has_value()) {
return Error("failed to find resource for id 0x%08x", resource_id);
}
- if (value.dataType != Res_value::TYPE_STRING) {
+ if (value->type != Res_value::TYPE_STRING) {
return Error("resource for is 0x%08x is not a file", resource_id);
}
- auto string_pool = asset_manager.GetStringPoolForCookie(cookie);
- size_t len;
- auto file_path16 = string_pool->stringAt(value.data, &len);
- if (file_path16 == nullptr) {
- return Error("failed to find string for index %d", value.data);
+ auto string_pool = asset_manager.GetStringPoolForCookie(value->cookie);
+ auto file = string_pool->string8ObjectAt(value->data);
+ if (!file.has_value()) {
+ return Error("failed to find string for index %d", value->data);
}
// Load the overlay resource mappings from the file specified using android:resourcesMap.
- auto file_path = String8(String16(file_path16));
- auto asset = asset_manager.OpenNonAsset(file_path.c_str(), Asset::AccessMode::ACCESS_BUFFER);
+ auto asset = asset_manager.OpenNonAsset(file->c_str(), Asset::AccessMode::ACCESS_BUFFER);
if (asset == nullptr) {
- return Error("file \"%s\" not found", file_path.c_str());
+ return Error("file \"%s\" not found", file->c_str());
}
return asset;
@@ -190,16 +184,16 @@
return Error(R"(<item> tag missing expected attribute "value")");
}
- ResourceId target_id =
+ auto target_id_result =
target_am->GetResourceId(*target_resource, "", target_package->GetPackageName());
- if (target_id == 0U) {
+ if (!target_id_result.has_value()) {
log_info.Warning(LogMessage() << "failed to find resource \"" << *target_resource
<< "\" in target resources");
continue;
}
// Retrieve the compile-time resource id of the target resource.
- target_id = REWRITE_PACKAGE(target_id, target_package_id);
+ uint32_t target_id = REWRITE_PACKAGE(*target_id_result, target_package_id);
if (overlay_resource->dataType == Res_value::TYPE_STRING) {
overlay_resource->data += string_pool_offset;
@@ -220,7 +214,7 @@
Result<ResourceMapping> ResourceMapping::CreateResourceMappingLegacy(
const AssetManager2* target_am, const AssetManager2* overlay_am,
- const LoadedPackage* target_package, const LoadedPackage* overlay_package) {
+ const LoadedPackage* target_package, const LoadedPackage* overlay_package, LogInfo& log_info) {
ResourceMapping resource_mapping;
const uint8_t target_package_id = target_package->GetPackageId();
const auto end = overlay_package->end();
@@ -234,13 +228,15 @@
// Find the resource with the same type and entry name within the target package.
const std::string full_name =
base::StringPrintf("%s:%s", target_package->GetPackageName().c_str(), name->c_str());
- ResourceId target_resource = target_am->GetResourceId(full_name);
- if (target_resource == 0U) {
+ auto target_resource_result = target_am->GetResourceId(full_name);
+ if (!target_resource_result.has_value()) {
+ log_info.Warning(LogMessage() << "failed to find resource \"" << full_name
+ << "\" in target resources");
continue;
}
// Retrieve the compile-time resource id of the target resource.
- target_resource = REWRITE_PACKAGE(target_resource, target_package_id);
+ ResourceId target_resource = REWRITE_PACKAGE(*target_resource_result, target_package_id);
resource_mapping.AddMapping(target_resource, overlay_resid,
false /* rewrite_overlay_reference */);
}
@@ -347,7 +343,9 @@
auto& string_pool = (*parser)->get_strings();
string_pool_data_length = string_pool.bytes();
string_pool_data.reset(new uint8_t[string_pool_data_length]);
- memcpy(string_pool_data.get(), string_pool.data(), string_pool_data_length);
+
+ // Overlays should not be incrementally installed, so calling unsafe_ptr is fine here.
+ memcpy(string_pool_data.get(), string_pool.data().unsafe_ptr(), string_pool_data_length);
// Offset string indices by the size of the overlay resource table string pool.
string_pool_offset = overlay_arsc->GetStringPool()->size();
@@ -358,7 +356,7 @@
// If no file is specified using android:resourcesMap, it is assumed that the overlay only
// defines resources intended to override target resources of the same type and name.
resource_mapping = CreateResourceMappingLegacy(&target_asset_manager, &overlay_asset_manager,
- target_pkg, overlay_pkg);
+ target_pkg, overlay_pkg, log_info);
}
if (!resource_mapping) {
diff --git a/cmds/idmap2/libidmap2/ResourceUtils.cpp b/cmds/idmap2/libidmap2/ResourceUtils.cpp
index 98d026b..e817140 100644
--- a/cmds/idmap2/libidmap2/ResourceUtils.cpp
+++ b/cmds/idmap2/libidmap2/ResourceUtils.cpp
@@ -72,21 +72,21 @@
}
Result<std::string> ResToTypeEntryName(const AssetManager2& am, uint32_t resid) {
- AssetManager2::ResourceName name;
- if (!am.GetResourceName(resid, &name)) {
+ const auto name = am.GetResourceName(resid);
+ if (!name.has_value()) {
return Error("no resource 0x%08x in asset manager", resid);
}
std::string out;
- if (name.type != nullptr) {
- out.append(name.type, name.type_len);
+ if (name->type != nullptr) {
+ out.append(name->type, name->type_len);
} else {
- out += Utf16ToUtf8(StringPiece16(name.type16, name.type_len));
+ out += Utf16ToUtf8(StringPiece16(name->type16, name->type_len));
}
out.append("/");
- if (name.entry != nullptr) {
- out.append(name.entry, name.entry_len);
+ if (name->entry != nullptr) {
+ out.append(name->entry, name->entry_len);
} else {
- out += Utf16ToUtf8(StringPiece16(name.entry16, name.entry_len));
+ out += Utf16ToUtf8(StringPiece16(name->entry16, name->entry_len));
}
return out;
}
diff --git a/cmds/idmap2/libidmap2/XmlParser.cpp b/cmds/idmap2/libidmap2/XmlParser.cpp
index 526a560..7c55b64 100644
--- a/cmds/idmap2/libidmap2/XmlParser.cpp
+++ b/cmds/idmap2/libidmap2/XmlParser.cpp
@@ -98,18 +98,19 @@
switch ((*value).dataType) {
case Res_value::TYPE_STRING: {
- size_t len;
- const String16 value16(parser_.getStrings().stringAt((*value).data, &len));
- return std::string(String8(value16).c_str());
+ if (auto str = parser_.getStrings().string8ObjectAt((*value).data)) {
+ return std::string(str->string());
+ }
+ break;
}
case Res_value::TYPE_INT_DEC:
case Res_value::TYPE_INT_HEX:
case Res_value::TYPE_INT_BOOLEAN: {
return std::to_string((*value).data);
}
- default:
- return Error(R"(Failed to convert attribute "%s" value to a string)", name.c_str());
}
+
+ return Error(R"(Failed to convert attribute "%s" value to a string)", name.c_str());
}
Result<Res_value> XmlParser::Node::GetAttributeValue(const std::string& name) const {
diff --git a/cmds/statsd/src/StatsLogProcessor.cpp b/cmds/statsd/src/StatsLogProcessor.cpp
index ae1ef21..6eff639 100644
--- a/cmds/statsd/src/StatsLogProcessor.cpp
+++ b/cmds/statsd/src/StatsLogProcessor.cpp
@@ -549,9 +549,7 @@
configValid = it->second->updateConfig(config, mTimeBaseNs, timestampNs,
mAnomalyAlarmMonitor, mPeriodicAlarmMonitor);
if (configValid) {
- // TODO(b/162323476): refresh TTL, ensure init() is handled properly.
mUidMap->OnConfigUpdated(key);
-
}
}
if (!configValid) {
diff --git a/cmds/statsd/src/metrics/MetricsManager.cpp b/cmds/statsd/src/metrics/MetricsManager.cpp
index 3b6e10b..f9b0a10 100644
--- a/cmds/statsd/src/metrics/MetricsManager.cpp
+++ b/cmds/statsd/src/metrics/MetricsManager.cpp
@@ -97,40 +97,8 @@
for (const auto& annotation : config.annotation()) {
mAnnotations.emplace_back(annotation.field_int64(), annotation.field_int32());
}
-
- // Guardrail. Reject the config if it's too big.
- if (mAllMetricProducers.size() > StatsdStats::kMaxMetricCountPerConfig ||
- mAllConditionTrackers.size() > StatsdStats::kMaxConditionCountPerConfig ||
- mAllAtomMatchingTrackers.size() > StatsdStats::kMaxMatcherCountPerConfig) {
- ALOGE("This config is too big! Reject!");
- mConfigValid = false;
- }
- if (mAllAnomalyTrackers.size() > StatsdStats::kMaxAlertCountPerConfig) {
- ALOGE("This config has too many alerts! Reject!");
- mConfigValid = false;
- }
-
- mIsAlwaysActive = (mMetricIndexesWithActivation.size() != mAllMetricProducers.size()) ||
- (mAllMetricProducers.size() == 0);
- bool isActive = mIsAlwaysActive;
- for (int metric : mMetricIndexesWithActivation) {
- isActive |= mAllMetricProducers[metric]->isActive();
- }
- mIsActive = isActive;
- VLOG("mIsActive is initialized to %d", mIsActive)
-
- // no matter whether this config is valid, log it in the stats.
- StatsdStats::getInstance().noteConfigReceived(
- key, mAllMetricProducers.size(), mAllConditionTrackers.size(),
- mAllAtomMatchingTrackers.size(), mAllAnomalyTrackers.size(), mAnnotations,
- mConfigValid);
- // Check active
- for (const auto& metric : mAllMetricProducers) {
- if (metric->isActive()) {
- mIsActive = true;
- break;
- }
- }
+ verifyGuardrailsAndUpdateStatsdStats();
+ initializeConfigActiveStatus();
}
MetricsManager::~MetricsManager() {
@@ -211,6 +179,9 @@
mPullAtomUids.clear();
mPullAtomPackages.clear();
createAllLogSourcesFromConfig(config);
+
+ verifyGuardrailsAndUpdateStatsdStats();
+ initializeConfigActiveStatus();
return mConfigValid;
}
@@ -272,6 +243,35 @@
}
}
+void MetricsManager::verifyGuardrailsAndUpdateStatsdStats() {
+ // Guardrail. Reject the config if it's too big.
+ if (mAllMetricProducers.size() > StatsdStats::kMaxMetricCountPerConfig ||
+ mAllConditionTrackers.size() > StatsdStats::kMaxConditionCountPerConfig ||
+ mAllAtomMatchingTrackers.size() > StatsdStats::kMaxMatcherCountPerConfig) {
+ ALOGE("This config is too big! Reject!");
+ mConfigValid = false;
+ }
+ if (mAllAnomalyTrackers.size() > StatsdStats::kMaxAlertCountPerConfig) {
+ ALOGE("This config has too many alerts! Reject!");
+ mConfigValid = false;
+ }
+ // no matter whether this config is valid, log it in the stats.
+ StatsdStats::getInstance().noteConfigReceived(
+ mConfigKey, mAllMetricProducers.size(), mAllConditionTrackers.size(),
+ mAllAtomMatchingTrackers.size(), mAllAnomalyTrackers.size(), mAnnotations,
+ mConfigValid);
+}
+
+void MetricsManager::initializeConfigActiveStatus() {
+ mIsAlwaysActive = (mMetricIndexesWithActivation.size() != mAllMetricProducers.size()) ||
+ (mAllMetricProducers.size() == 0);
+ mIsActive = mIsAlwaysActive;
+ for (int metric : mMetricIndexesWithActivation) {
+ mIsActive |= mAllMetricProducers[metric]->isActive();
+ }
+ VLOG("mIsActive is initialized to %d", mIsActive);
+}
+
void MetricsManager::initAllowedLogSources() {
std::lock_guard<std::mutex> lock(mAllowedLogSourcesMutex);
mAllowedLogSources.clear();
diff --git a/cmds/statsd/src/metrics/MetricsManager.h b/cmds/statsd/src/metrics/MetricsManager.h
index 98d4bff..3c9ecdb 100644
--- a/cmds/statsd/src/metrics/MetricsManager.h
+++ b/cmds/statsd/src/metrics/MetricsManager.h
@@ -292,6 +292,14 @@
// Calls initAllowedLogSources and initPullAtomSources. Sets mConfigValid to false on error.
void createAllLogSourcesFromConfig(const StatsdConfig& config);
+ // Verifies the config meets guardrails and updates statsdStats.
+ // Sets mConfigValid to false on error. Should be called on config creation/update
+ void verifyGuardrailsAndUpdateStatsdStats();
+
+ // Initializes mIsAlwaysActive and mIsActive.
+ // Should be called on config creation/update.
+ void initializeConfigActiveStatus();
+
// The metrics that don't need to be uploaded or even reported.
std::set<int64_t> mNoReportMetricIds;
diff --git a/cmds/statsd/src/metrics/parsing_utils/config_update_utils.cpp b/cmds/statsd/src/metrics/parsing_utils/config_update_utils.cpp
index af9606b..39789cd 100644
--- a/cmds/statsd/src/metrics/parsing_utils/config_update_utils.cpp
+++ b/cmds/statsd/src/metrics/parsing_utils/config_update_utils.cpp
@@ -396,6 +396,23 @@
return true;
}
+bool updateStates(const StatsdConfig& config, const map<int64_t, uint64_t>& oldStateProtoHashes,
+ unordered_map<int64_t, int>& stateAtomIdMap,
+ unordered_map<int64_t, unordered_map<int, int64_t>>& allStateGroupMaps,
+ map<int64_t, uint64_t>& newStateProtoHashes, set<int64_t>& replacedStates) {
+ // Share with metrics_manager_util.
+ if (!initStates(config, stateAtomIdMap, allStateGroupMaps, newStateProtoHashes)) {
+ return false;
+ }
+
+ for (const auto& [stateId, stateHash] : oldStateProtoHashes) {
+ const auto& it = newStateProtoHashes.find(stateId);
+ if (it != newStateProtoHashes.end() && it->second != stateHash) {
+ replacedStates.insert(stateId);
+ }
+ }
+ return true;
+}
// Returns true if any matchers in the metric activation were replaced.
bool metricActivationDepsChange(const StatsdConfig& config,
const unordered_map<int64_t, int>& metricToActivationMap,
@@ -895,6 +912,12 @@
}
}
+ // Init new/replaced metrics.
+ for (size_t i = 0; i < newMetricProducers.size(); i++) {
+ if (metricsToUpdate[i] == UPDATE_REPLACE || metricsToUpdate[i] == UPDATE_NEW) {
+ newMetricProducers[i]->prepareFirstBucket();
+ }
+ }
return true;
}
@@ -1036,6 +1059,7 @@
set<int64_t>& noReportMetricIds) {
set<int64_t> replacedMatchers;
set<int64_t> replacedConditions;
+ set<int64_t> replacedStates;
set<int64_t> replacedMetrics;
vector<ConditionState> conditionCache;
unordered_map<int64_t, int> stateAtomIdMap;
@@ -1047,7 +1071,6 @@
ALOGE("updateAtomMatchingTrackers failed");
return false;
}
- VLOG("updateAtomMatchingTrackers succeeded");
if (!updateConditions(key, config, newAtomMatchingTrackerMap, replacedMatchers,
oldConditionTrackerMap, oldConditionTrackers, newConditionTrackerMap,
@@ -1056,21 +1079,12 @@
ALOGE("updateConditions failed");
return false;
}
- VLOG("updateConditions succeeded");
- // Share with metrics_manager_util,
- if (!initStates(config, stateAtomIdMap, allStateGroupMaps, newStateProtoHashes)) {
- ALOGE("initStates failed");
+ if (!updateStates(config, oldStateProtoHashes, stateAtomIdMap, allStateGroupMaps,
+ newStateProtoHashes, replacedStates)) {
+ ALOGE("updateStates failed");
return false;
}
-
- set<int64_t> replacedStates;
- for (const auto& [stateId, stateHash] : oldStateProtoHashes) {
- const auto& it = newStateProtoHashes.find(stateId);
- if (it != newStateProtoHashes.end() && it->second != stateHash) {
- replacedStates.insert(stateId);
- }
- }
if (!updateMetrics(key, config, timeBaseNs, currentTimeNs, pullerManager,
oldAtomMatchingTrackerMap, newAtomMatchingTrackerMap, replacedMatchers,
newAtomMatchingTrackers, newConditionTrackerMap, replacedConditions,
diff --git a/cmds/statsd/src/metrics/parsing_utils/config_update_utils.h b/cmds/statsd/src/metrics/parsing_utils/config_update_utils.h
index 178a9d2..8e2be68 100644
--- a/cmds/statsd/src/metrics/parsing_utils/config_update_utils.h
+++ b/cmds/statsd/src/metrics/parsing_utils/config_update_utils.h
@@ -126,6 +126,13 @@
std::vector<ConditionState>& conditionCache,
std::set<int64_t>& replacedConditions);
+bool updateStates(const StatsdConfig& config,
+ const std::map<int64_t, uint64_t>& oldStateProtoHashes,
+ std::unordered_map<int64_t, int>& stateAtomIdMap,
+ std::unordered_map<int64_t, std::unordered_map<int, int64_t>>& allStateGroupMaps,
+ std::map<int64_t, uint64_t>& newStateProtoHashes,
+ std::set<int64_t>& replacedStates);
+
// Function to determine the update status (preserve/replace/new) of all metrics in the config.
// [config]: the input StatsdConfig
// [oldMetricProducerMap]: metric id to index mapping in the existing MetricsManager
diff --git a/cmds/statsd/tests/metrics/parsing_utils/config_update_utils_test.cpp b/cmds/statsd/tests/metrics/parsing_utils/config_update_utils_test.cpp
index 66bab4e..d78c14c 100644
--- a/cmds/statsd/tests/metrics/parsing_utils/config_update_utils_test.cpp
+++ b/cmds/statsd/tests/metrics/parsing_utils/config_update_utils_test.cpp
@@ -997,6 +997,57 @@
EXPECT_THAT(combinationTracker1->mSlicedChildren, IsEmpty());
}
+TEST_F(ConfigUpdateTest, TestUpdateStates) {
+ StatsdConfig config;
+ // Add states.
+ // Will be replaced because we add a state map.
+ State state1 = CreateScreenState();
+ int64_t state1Id = state1.id();
+ *config.add_state() = state1;
+
+ // Will be preserved.
+ State state2 = CreateUidProcessState();
+ int64_t state2Id = state2.id();
+ *config.add_state() = state2;
+
+ // Will be replaced since the atom changes from overlay to screen.
+ State state3 = CreateOverlayState();
+ int64_t state3Id = state3.id();
+ *config.add_state() = state3;
+
+ EXPECT_TRUE(initConfig(config));
+
+ // Change definitions of state1 and state3.
+ int64_t screenOnId = 0x4321, screenOffId = 0x1234;
+ *state1.mutable_map() = CreateScreenStateSimpleOnOffMap(screenOnId, screenOffId);
+ state3.set_atom_id(util::SCREEN_STATE_CHANGED);
+
+ StatsdConfig newConfig;
+ *newConfig.add_state() = state3;
+ *newConfig.add_state() = state1;
+ *newConfig.add_state() = state2;
+
+ unordered_map<int64_t, int> stateAtomIdMap;
+ unordered_map<int64_t, unordered_map<int, int64_t>> allStateGroupMaps;
+ map<int64_t, uint64_t> newStateProtoHashes;
+ set<int64_t> replacedStates;
+ EXPECT_TRUE(updateStates(newConfig, oldStateHashes, stateAtomIdMap, allStateGroupMaps,
+ newStateProtoHashes, replacedStates));
+ EXPECT_THAT(replacedStates, ContainerEq(set({state1Id, state3Id})));
+
+ unordered_map<int64_t, int> expectedStateAtomIdMap = {
+ {state1Id, util::SCREEN_STATE_CHANGED},
+ {state2Id, util::UID_PROCESS_STATE_CHANGED},
+ {state3Id, util::SCREEN_STATE_CHANGED}};
+ EXPECT_THAT(stateAtomIdMap, ContainerEq(expectedStateAtomIdMap));
+
+ unordered_map<int64_t, unordered_map<int, int64_t>> expectedStateGroupMaps = {
+ {state1Id,
+ {{android::view::DisplayStateEnum::DISPLAY_STATE_OFF, screenOffId},
+ {android::view::DisplayStateEnum::DISPLAY_STATE_ON, screenOnId}}}};
+ EXPECT_THAT(allStateGroupMaps, ContainerEq(expectedStateGroupMaps));
+}
+
TEST_F(ConfigUpdateTest, TestEventMetricPreserve) {
StatsdConfig config;
AtomMatcher startMatcher = CreateScreenTurnedOnAtomMatcher();
diff --git a/config/preloaded-classes b/config/preloaded-classes
index ecf11c2..f56656b 100644
--- a/config/preloaded-classes
+++ b/config/preloaded-classes
@@ -4532,6 +4532,7 @@
android.os.BadParcelableException
android.os.BaseBundle$NoImagePreloadHolder
android.os.BaseBundle
+android.os.BasicShellCommandHandler
android.os.BatteryManager
android.os.BatteryManagerInternal
android.os.BatteryProperty$1
@@ -9557,7 +9558,6 @@
com.android.internal.widget.VerifyCredentialResponse
com.android.internal.widget.ViewClippingUtil$ClippingParameters
com.android.internal.widget.ViewClippingUtil
-com.android.module.utils.BasicShellCommandHandler
com.android.okhttp.Address
com.android.okhttp.AndroidShimResponseCache
com.android.okhttp.Authenticator
diff --git a/core/api/current.txt b/core/api/current.txt
index 31264b9..8a139a6 100644
--- a/core/api/current.txt
+++ b/core/api/current.txt
@@ -6950,6 +6950,7 @@
method @Nullable public java.util.List<java.lang.String> getPermittedCrossProfileNotificationListeners(@NonNull android.content.ComponentName);
method @Nullable public java.util.List<java.lang.String> getPermittedInputMethods(@NonNull android.content.ComponentName);
method public int getPersonalAppsSuspendedReasons(@NonNull android.content.ComponentName);
+ method public int getRequiredPasswordComplexity();
method public long getRequiredStrongAuthTimeout(@Nullable android.content.ComponentName);
method public boolean getScreenCaptureDisabled(@Nullable android.content.ComponentName);
method public java.util.List<android.os.UserHandle> getSecondaryUsers(@NonNull android.content.ComponentName);
@@ -7081,6 +7082,7 @@
method public void setProfileEnabled(@NonNull android.content.ComponentName);
method public void setProfileName(@NonNull android.content.ComponentName, String);
method public void setRecommendedGlobalProxy(@NonNull android.content.ComponentName, @Nullable android.net.ProxyInfo);
+ method public void setRequiredPasswordComplexity(int);
method public void setRequiredStrongAuthTimeout(@NonNull android.content.ComponentName, long);
method public boolean setResetPasswordToken(android.content.ComponentName, byte[]);
method public void setRestrictionsProvider(@NonNull android.content.ComponentName, @Nullable android.content.ComponentName);
@@ -24370,6 +24372,8 @@
field public static final int ENCODING_MP3 = 9; // 0x9
field public static final int ENCODING_OPUS = 20; // 0x14
field public static final int ENCODING_PCM_16BIT = 2; // 0x2
+ field public static final int ENCODING_PCM_24BIT_PACKED = 21; // 0x15
+ field public static final int ENCODING_PCM_32BIT = 22; // 0x16
field public static final int ENCODING_PCM_8BIT = 3; // 0x3
field public static final int ENCODING_PCM_FLOAT = 4; // 0x4
field public static final int SAMPLE_RATE_UNSPECIFIED = 0; // 0x0
@@ -44250,6 +44254,8 @@
field public static final String EXTRA_ANSWERING_DROPS_FG_CALL = "android.telecom.extra.ANSWERING_DROPS_FG_CALL";
field public static final String EXTRA_ANSWERING_DROPS_FG_CALL_APP_NAME = "android.telecom.extra.ANSWERING_DROPS_FG_CALL_APP_NAME";
field public static final String EXTRA_AUDIO_CODEC = "android.telecom.extra.AUDIO_CODEC";
+ field public static final String EXTRA_AUDIO_CODEC_BANDWIDTH_KHZ = "android.telecom.extra.AUDIO_CODEC_BANDWIDTH_KHZ";
+ field public static final String EXTRA_AUDIO_CODEC_BITRATE_KBPS = "android.telecom.extra.AUDIO_CODEC_BITRATE_KBPS";
field public static final String EXTRA_CALL_SUBJECT = "android.telecom.extra.CALL_SUBJECT";
field public static final String EXTRA_CHILD_ADDRESS = "android.telecom.extra.CHILD_ADDRESS";
field public static final String EXTRA_IS_RTT_AUDIO_PRESENT = "android.telecom.extra.IS_RTT_AUDIO_PRESENT";
@@ -51959,16 +51965,17 @@
field public int toolType;
}
- public interface OnReceiveContentCallback<T extends android.view.View> {
- method public boolean onReceiveContent(@NonNull T, @NonNull android.view.OnReceiveContentCallback.Payload);
+ public interface OnReceiveContentListener {
+ method @Nullable public android.view.OnReceiveContentListener.Payload onReceiveContent(@NonNull android.view.View, @NonNull android.view.OnReceiveContentListener.Payload);
}
- public static final class OnReceiveContentCallback.Payload {
+ public static final class OnReceiveContentListener.Payload {
method @NonNull public android.content.ClipData getClip();
method @Nullable public android.os.Bundle getExtras();
method public int getFlags();
method @Nullable public android.net.Uri getLinkUri();
method public int getSource();
+ method @NonNull public java.util.Map<java.lang.Boolean,android.view.OnReceiveContentListener.Payload> partition(@NonNull java.util.function.Predicate<android.content.ClipData.Item>);
field public static final int FLAG_CONVERT_TO_PLAIN_TEXT = 1; // 0x1
field public static final int SOURCE_APP = 0; // 0x0
field public static final int SOURCE_AUTOFILL = 4; // 0x4
@@ -51978,12 +51985,15 @@
field public static final int SOURCE_PROCESS_TEXT = 5; // 0x5
}
- public static final class OnReceiveContentCallback.Payload.Builder {
- ctor public OnReceiveContentCallback.Payload.Builder(@NonNull android.content.ClipData, int);
- method @NonNull public android.view.OnReceiveContentCallback.Payload build();
- method @NonNull public android.view.OnReceiveContentCallback.Payload.Builder setExtras(@Nullable android.os.Bundle);
- method @NonNull public android.view.OnReceiveContentCallback.Payload.Builder setFlags(int);
- method @NonNull public android.view.OnReceiveContentCallback.Payload.Builder setLinkUri(@Nullable android.net.Uri);
+ public static final class OnReceiveContentListener.Payload.Builder {
+ ctor public OnReceiveContentListener.Payload.Builder(@NonNull android.view.OnReceiveContentListener.Payload);
+ ctor public OnReceiveContentListener.Payload.Builder(@NonNull android.content.ClipData, int);
+ method @NonNull public android.view.OnReceiveContentListener.Payload build();
+ method @NonNull public android.view.OnReceiveContentListener.Payload.Builder setClip(@NonNull android.content.ClipData);
+ method @NonNull public android.view.OnReceiveContentListener.Payload.Builder setExtras(@Nullable android.os.Bundle);
+ method @NonNull public android.view.OnReceiveContentListener.Payload.Builder setFlags(int);
+ method @NonNull public android.view.OnReceiveContentListener.Payload.Builder setLinkUri(@Nullable android.net.Uri);
+ method @NonNull public android.view.OnReceiveContentListener.Payload.Builder setSource(int);
}
public abstract class OrientationEventListener {
@@ -52732,7 +52742,7 @@
method public void onProvideContentCaptureStructure(@NonNull android.view.ViewStructure, int);
method public void onProvideStructure(android.view.ViewStructure);
method public void onProvideVirtualStructure(android.view.ViewStructure);
- method public boolean onReceiveContent(@NonNull android.view.OnReceiveContentCallback.Payload);
+ method @Nullable public android.view.OnReceiveContentListener.Payload onReceiveContent(@NonNull android.view.OnReceiveContentListener.Payload);
method public android.view.PointerIcon onResolvePointerIcon(android.view.MotionEvent, int);
method @CallSuper protected void onRestoreInstanceState(android.os.Parcelable);
method public void onRtlPropertiesChanged(int);
@@ -52890,7 +52900,7 @@
method public void setOnHoverListener(android.view.View.OnHoverListener);
method public void setOnKeyListener(android.view.View.OnKeyListener);
method public void setOnLongClickListener(@Nullable android.view.View.OnLongClickListener);
- method public void setOnReceiveContentCallback(@Nullable String[], @Nullable android.view.OnReceiveContentCallback);
+ method public void setOnReceiveContentListener(@Nullable String[], @Nullable android.view.OnReceiveContentListener);
method public void setOnScrollChangeListener(android.view.View.OnScrollChangeListener);
method @Deprecated public void setOnSystemUiVisibilityChangeListener(android.view.View.OnSystemUiVisibilityChangeListener);
method public void setOnTouchListener(android.view.View.OnTouchListener);
@@ -59907,11 +59917,6 @@
field @NonNull public static final android.os.Parcelable.Creator<android.widget.TextView.SavedState> CREATOR;
}
- public class TextViewOnReceiveContentCallback implements android.view.OnReceiveContentCallback<android.widget.TextView> {
- ctor public TextViewOnReceiveContentCallback();
- method public boolean onReceiveContent(@NonNull android.widget.TextView, @NonNull android.view.OnReceiveContentCallback.Payload);
- }
-
public interface ThemedSpinnerAdapter extends android.widget.SpinnerAdapter {
method @Nullable public android.content.res.Resources.Theme getDropDownViewTheme();
method public void setDropDownViewTheme(@Nullable android.content.res.Resources.Theme);
diff --git a/core/api/system-current.txt b/core/api/system-current.txt
index 37a5389..3a1972e 100644
--- a/core/api/system-current.txt
+++ b/core/api/system-current.txt
@@ -11358,7 +11358,6 @@
method public int getEmergencyServiceCategories();
method @NonNull public java.util.List<java.lang.String> getEmergencyUrns();
method public android.telephony.ims.ImsStreamMediaProfile getMediaProfile();
- method @NonNull public java.util.Set<android.telephony.ims.RtpHeaderExtensionType> getOfferedRtpHeaderExtensionTypes();
method @NonNull public android.os.Bundle getProprietaryCallExtras();
method public int getRestrictCause();
method public int getServiceType();
@@ -11380,7 +11379,6 @@
method public void setEmergencyServiceCategories(int);
method public void setEmergencyUrns(@NonNull java.util.List<java.lang.String>);
method public void setHasKnownUserIntentEmergency(boolean);
- method public void setOfferedRtpHeaderExtensionTypes(@NonNull java.util.Set<android.telephony.ims.RtpHeaderExtensionType>);
method public void updateCallExtras(android.telephony.ims.ImsCallProfile);
method public void updateCallType(android.telephony.ims.ImsCallProfile);
method public void updateMediaProfile(android.telephony.ims.ImsCallProfile);
@@ -11889,6 +11887,7 @@
public class MmTelFeature extends android.telephony.ims.feature.ImsFeature {
ctor public MmTelFeature();
method public void changeEnabledCapabilities(@NonNull android.telephony.ims.feature.CapabilityChangeRequest, @NonNull android.telephony.ims.feature.ImsFeature.CapabilityCallbackProxy);
+ method public void changeOfferedRtpHeaderExtensionTypes(@NonNull java.util.Set<android.telephony.ims.RtpHeaderExtensionType>);
method @Nullable public android.telephony.ims.ImsCallProfile createCallProfile(int, int);
method @Nullable public android.telephony.ims.stub.ImsCallSessionImplBase createCallSession(@NonNull android.telephony.ims.ImsCallProfile);
method @NonNull public android.telephony.ims.stub.ImsEcbmImplBase getEcbm();
diff --git a/core/api/test-current.txt b/core/api/test-current.txt
index ef4dfdf..1c72d02 100644
--- a/core/api/test-current.txt
+++ b/core/api/test-current.txt
@@ -282,7 +282,7 @@
}
public class StatusBarManager {
- method public void collapsePanels();
+ method @RequiresPermission(android.Manifest.permission.STATUS_BAR) public void collapsePanels();
method public void expandNotificationsPanel();
method @RequiresPermission(android.Manifest.permission.STATUS_BAR) public void setExpansionDisabledForSimNetworkLock(boolean);
}
diff --git a/core/java/android/app/ActivityManager.java b/core/java/android/app/ActivityManager.java
index f17b815..1e6e784 100644
--- a/core/java/android/app/ActivityManager.java
+++ b/core/java/android/app/ActivityManager.java
@@ -173,6 +173,12 @@
*/
public static final int INSTR_FLAG_DISABLE_TEST_API_CHECKS = 1 << 2;
+ /**
+ * Do not restart the target process when starting or finishing instrumentation.
+ * @hide
+ */
+ public static final int INSTR_FLAG_NO_RESTART = 1 << 3;
+
static final class UidObserver extends IUidObserver.Stub {
final OnUidImportanceListener mListener;
final Context mContext;
diff --git a/core/java/android/app/ActivityThread.java b/core/java/android/app/ActivityThread.java
index 0f6ebf2..2211807 100644
--- a/core/java/android/app/ActivityThread.java
+++ b/core/java/android/app/ActivityThread.java
@@ -381,6 +381,7 @@
String mInstrumentedAppDir = null;
String[] mInstrumentedSplitAppDirs = null;
String mInstrumentedLibDir = null;
+ boolean mInstrumentingWithoutRestart;
boolean mSystemThread = false;
boolean mSomeActivitiesChanged = false;
/* package */ boolean mHiddenApiWarningShown = false;
@@ -1774,6 +1775,19 @@
key.mLock.notifyAll();
}
}
+
+ @Override
+ public void instrumentWithoutRestart(ComponentName instrumentationName,
+ Bundle instrumentationArgs, IInstrumentationWatcher instrumentationWatcher,
+ IUiAutomationConnection instrumentationUiConnection, ApplicationInfo targetInfo) {
+ AppBindData data = new AppBindData();
+ data.instrumentationName = instrumentationName;
+ data.instrumentationArgs = instrumentationArgs;
+ data.instrumentationWatcher = instrumentationWatcher;
+ data.instrumentationUiAutomationConnection = instrumentationUiConnection;
+ data.appInfo = targetInfo;
+ sendMessage(H.INSTRUMENT_WITHOUT_RESTART, data);
+ }
}
private @NonNull SafeCancellationTransport createSafeCancellationTransport(
@@ -1879,6 +1893,9 @@
public static final int PURGE_RESOURCES = 161;
public static final int ATTACH_STARTUP_AGENTS = 162;
+ public static final int INSTRUMENT_WITHOUT_RESTART = 170;
+ public static final int FINISH_INSTRUMENTATION_WITHOUT_RESTART = 171;
+
String codeToString(int code) {
if (DEBUG_MESSAGES) {
switch (code) {
@@ -1921,6 +1938,9 @@
case RELAUNCH_ACTIVITY: return "RELAUNCH_ACTIVITY";
case PURGE_RESOURCES: return "PURGE_RESOURCES";
case ATTACH_STARTUP_AGENTS: return "ATTACH_STARTUP_AGENTS";
+ case INSTRUMENT_WITHOUT_RESTART: return "INSTRUMENT_WITHOUT_RESTART";
+ case FINISH_INSTRUMENTATION_WITHOUT_RESTART:
+ return "FINISH_INSTRUMENTATION_WITHOUT_RESTART";
}
}
return Integer.toString(code);
@@ -2102,6 +2122,12 @@
case ATTACH_STARTUP_AGENTS:
handleAttachStartupAgents((String) msg.obj);
break;
+ case INSTRUMENT_WITHOUT_RESTART:
+ handleInstrumentWithoutRestart((AppBindData) msg.obj);
+ break;
+ case FINISH_INSTRUMENTATION_WITHOUT_RESTART:
+ handleFinishInstrumentationWithoutRestart();
+ break;
}
Object obj = msg.obj;
if (obj instanceof SomeArgs) {
@@ -6500,32 +6526,7 @@
// setting up the app context.
final InstrumentationInfo ii;
if (data.instrumentationName != null) {
- try {
- ii = new ApplicationPackageManager(
- null, getPackageManager(), getPermissionManager())
- .getInstrumentationInfo(data.instrumentationName, 0);
- } catch (PackageManager.NameNotFoundException e) {
- throw new RuntimeException(
- "Unable to find instrumentation info for: " + data.instrumentationName);
- }
-
- // Warn of potential ABI mismatches.
- if (!Objects.equals(data.appInfo.primaryCpuAbi, ii.primaryCpuAbi)
- || !Objects.equals(data.appInfo.secondaryCpuAbi, ii.secondaryCpuAbi)) {
- Slog.w(TAG, "Package uses different ABI(s) than its instrumentation: "
- + "package[" + data.appInfo.packageName + "]: "
- + data.appInfo.primaryCpuAbi + ", " + data.appInfo.secondaryCpuAbi
- + " instrumentation[" + ii.packageName + "]: "
- + ii.primaryCpuAbi + ", " + ii.secondaryCpuAbi);
- }
-
- mInstrumentationPackageName = ii.packageName;
- mInstrumentationAppDir = ii.sourceDir;
- mInstrumentationSplitAppDirs = ii.splitSourceDirs;
- mInstrumentationLibDir = getInstrumentationLibrary(data.appInfo, ii);
- mInstrumentedAppDir = data.info.getAppDir();
- mInstrumentedSplitAppDirs = data.info.getSplitAppDirs();
- mInstrumentedLibDir = data.info.getLibDir();
+ ii = prepareInstrumentation(data);
} else {
ii = null;
}
@@ -6554,48 +6555,7 @@
// Continue loading instrumentation.
if (ii != null) {
- ApplicationInfo instrApp;
- try {
- instrApp = getPackageManager().getApplicationInfo(ii.packageName, 0,
- UserHandle.myUserId());
- } catch (RemoteException e) {
- instrApp = null;
- }
- if (instrApp == null) {
- instrApp = new ApplicationInfo();
- }
- ii.copyTo(instrApp);
- instrApp.initForUser(UserHandle.myUserId());
- final LoadedApk pi = getPackageInfo(instrApp, data.compatInfo,
- appContext.getClassLoader(), false, true, false);
-
- // The test context's op package name == the target app's op package name, because
- // the app ops manager checks the op package name against the real calling UID,
- // which is what the target package name is associated with.
- final ContextImpl instrContext = ContextImpl.createAppContext(this, pi,
- appContext.getOpPackageName());
-
- try {
- final ClassLoader cl = instrContext.getClassLoader();
- mInstrumentation = (Instrumentation)
- cl.loadClass(data.instrumentationName.getClassName()).newInstance();
- } catch (Exception e) {
- throw new RuntimeException(
- "Unable to instantiate instrumentation "
- + data.instrumentationName + ": " + e.toString(), e);
- }
-
- final ComponentName component = new ComponentName(ii.packageName, ii.name);
- mInstrumentation.init(this, instrContext, appContext, component,
- data.instrumentationWatcher, data.instrumentationUiAutomationConnection);
-
- if (mProfiler.profileFile != null && !ii.handleProfiling
- && mProfiler.profileFd == null) {
- mProfiler.handlingProfiling = true;
- final File file = new File(mProfiler.profileFile);
- file.getParentFile().mkdirs();
- Debug.startMethodTracing(file.toString(), 8 * 1024 * 1024);
- }
+ initInstrumentation(ii, data, appContext);
} else {
mInstrumentation = new Instrumentation();
mInstrumentation.basicInit(this);
@@ -6686,6 +6646,120 @@
}
}
+ private void handleInstrumentWithoutRestart(AppBindData data) {
+ try {
+ data.compatInfo = CompatibilityInfo.DEFAULT_COMPATIBILITY_INFO;
+ data.info = getPackageInfoNoCheck(data.appInfo, data.compatInfo);
+ mInstrumentingWithoutRestart = true;
+ final InstrumentationInfo ii = prepareInstrumentation(data);
+ final ContextImpl appContext =
+ ContextImpl.createAppContext(this, data.info);
+
+ initInstrumentation(ii, data, appContext);
+
+ try {
+ mInstrumentation.onCreate(data.instrumentationArgs);
+ } catch (Exception e) {
+ throw new RuntimeException(
+ "Exception thrown in onCreate() of "
+ + data.instrumentationName + ": " + e.toString(), e);
+ }
+
+ } catch (Exception e) {
+ Slog.e(TAG, "Error in handleInstrumentWithoutRestart", e);
+ }
+ }
+
+ private InstrumentationInfo prepareInstrumentation(AppBindData data) {
+ final InstrumentationInfo ii;
+ try {
+ ii = new ApplicationPackageManager(
+ null, getPackageManager(), getPermissionManager())
+ .getInstrumentationInfo(data.instrumentationName, 0);
+ } catch (PackageManager.NameNotFoundException e) {
+ throw new RuntimeException(
+ "Unable to find instrumentation info for: " + data.instrumentationName);
+ }
+
+ // Warn of potential ABI mismatches.
+ if (!Objects.equals(data.appInfo.primaryCpuAbi, ii.primaryCpuAbi)
+ || !Objects.equals(data.appInfo.secondaryCpuAbi, ii.secondaryCpuAbi)) {
+ Slog.w(TAG, "Package uses different ABI(s) than its instrumentation: "
+ + "package[" + data.appInfo.packageName + "]: "
+ + data.appInfo.primaryCpuAbi + ", " + data.appInfo.secondaryCpuAbi
+ + " instrumentation[" + ii.packageName + "]: "
+ + ii.primaryCpuAbi + ", " + ii.secondaryCpuAbi);
+ }
+
+ mInstrumentationPackageName = ii.packageName;
+ mInstrumentationAppDir = ii.sourceDir;
+ mInstrumentationSplitAppDirs = ii.splitSourceDirs;
+ mInstrumentationLibDir = getInstrumentationLibrary(data.appInfo, ii);
+ mInstrumentedAppDir = data.info.getAppDir();
+ mInstrumentedSplitAppDirs = data.info.getSplitAppDirs();
+ mInstrumentedLibDir = data.info.getLibDir();
+
+ return ii;
+ }
+
+ private void initInstrumentation(
+ InstrumentationInfo ii, AppBindData data, ContextImpl appContext) {
+ ApplicationInfo instrApp;
+ try {
+ instrApp = getPackageManager().getApplicationInfo(ii.packageName, 0,
+ UserHandle.myUserId());
+ } catch (RemoteException e) {
+ instrApp = null;
+ }
+ if (instrApp == null) {
+ instrApp = new ApplicationInfo();
+ }
+ ii.copyTo(instrApp);
+ instrApp.initForUser(UserHandle.myUserId());
+ final LoadedApk pi = getPackageInfo(instrApp, data.compatInfo,
+ appContext.getClassLoader(), false, true, false);
+
+ // The test context's op package name == the target app's op package name, because
+ // the app ops manager checks the op package name against the real calling UID,
+ // which is what the target package name is associated with.
+ final ContextImpl instrContext = ContextImpl.createAppContext(this, pi,
+ appContext.getOpPackageName());
+
+ try {
+ final ClassLoader cl = instrContext.getClassLoader();
+ mInstrumentation = (Instrumentation)
+ cl.loadClass(data.instrumentationName.getClassName()).newInstance();
+ } catch (Exception e) {
+ throw new RuntimeException(
+ "Unable to instantiate instrumentation "
+ + data.instrumentationName + ": " + e.toString(), e);
+ }
+
+ final ComponentName component = new ComponentName(ii.packageName, ii.name);
+ mInstrumentation.init(this, instrContext, appContext, component,
+ data.instrumentationWatcher, data.instrumentationUiAutomationConnection);
+
+ if (mProfiler.profileFile != null && !ii.handleProfiling
+ && mProfiler.profileFd == null) {
+ mProfiler.handlingProfiling = true;
+ final File file = new File(mProfiler.profileFile);
+ file.getParentFile().mkdirs();
+ Debug.startMethodTracing(file.toString(), 8 * 1024 * 1024);
+ }
+ }
+
+ private void handleFinishInstrumentationWithoutRestart() {
+ mInstrumentation.onDestroy();
+ mInstrumentationPackageName = null;
+ mInstrumentationAppDir = null;
+ mInstrumentationSplitAppDirs = null;
+ mInstrumentationLibDir = null;
+ mInstrumentedAppDir = null;
+ mInstrumentedSplitAppDirs = null;
+ mInstrumentedLibDir = null;
+ mInstrumentingWithoutRestart = false;
+ }
+
/*package*/ final void finishInstrumentation(int resultCode, Bundle results) {
IActivityManager am = ActivityManager.getService();
if (mProfiler.profileFile != null && mProfiler.handlingProfiling
@@ -6699,6 +6773,9 @@
} catch (RemoteException ex) {
throw ex.rethrowFromSystemServer();
}
+ if (mInstrumentingWithoutRestart) {
+ sendMessage(H.FINISH_INSTRUMENTATION_WITHOUT_RESTART, null);
+ }
}
@UnsupportedAppUsage
diff --git a/core/java/android/app/IApplicationThread.aidl b/core/java/android/app/IApplicationThread.aidl
index dc9918a..22ca42e 100644
--- a/core/java/android/app/IApplicationThread.aidl
+++ b/core/java/android/app/IApplicationThread.aidl
@@ -150,4 +150,9 @@
in RemoteCallback resultCallback);
void notifyContentProviderPublishStatus(in ContentProviderHolder holder, String auth,
int userId, boolean published);
+ void instrumentWithoutRestart(in ComponentName instrumentationName,
+ in Bundle instrumentationArgs,
+ IInstrumentationWatcher instrumentationWatcher,
+ IUiAutomationConnection instrumentationUiConnection,
+ in ApplicationInfo targetInfo);
}
diff --git a/core/java/android/app/LoadedApk.java b/core/java/android/app/LoadedApk.java
index 4eef616..6535387a 100644
--- a/core/java/android/app/LoadedApk.java
+++ b/core/java/android/app/LoadedApk.java
@@ -102,7 +102,6 @@
public final class LoadedApk {
static final String TAG = "LoadedApk";
static final boolean DEBUG = false;
- private static final String PROPERTY_NAME_APPEND_NATIVE = "pi.append_native_lib_paths";
@UnsupportedAppUsage
private final ActivityThread mActivityThread;
@@ -926,7 +925,7 @@
needToSetupJitProfiles = true;
}
- if (!libPaths.isEmpty() && SystemProperties.getBoolean(PROPERTY_NAME_APPEND_NATIVE, true)) {
+ if (!libPaths.isEmpty()) {
// Temporarily disable logging of disk reads on the Looper thread as this is necessary
StrictMode.ThreadPolicy oldPolicy = allowThreadDiskReads();
try {
diff --git a/core/java/android/app/StatusBarManager.java b/core/java/android/app/StatusBarManager.java
index b8fae67..4e3d85c 100644
--- a/core/java/android/app/StatusBarManager.java
+++ b/core/java/android/app/StatusBarManager.java
@@ -283,9 +283,15 @@
/**
* Collapse the notifications and settings panels.
*
+ * Starting in Android {@link Build.VERSION_CODES.S}, apps targeting SDK level {@link
+ * Build.VERSION_CODES.S} or higher will need {@link android.Manifest.permission.STATUS_BAR}
+ * permission to call this API.
+ *
* @hide
*/
- @UnsupportedAppUsage
+ @RequiresPermission(android.Manifest.permission.STATUS_BAR)
+ @UnsupportedAppUsage(maxTargetSdk = Build.VERSION_CODES.R, publicAlternatives = "Send {@link "
+ + "android.content.Intent#ACTION_CLOSE_SYSTEM_DIALOGS} instead.")
@TestApi
public void collapsePanels() {
try {
diff --git a/core/java/android/app/admin/DevicePolicyManager.java b/core/java/android/app/admin/DevicePolicyManager.java
index 01f3932..16ae081 100644
--- a/core/java/android/app/admin/DevicePolicyManager.java
+++ b/core/java/android/app/admin/DevicePolicyManager.java
@@ -2752,6 +2752,9 @@
* {@link #getParentProfileInstance(ComponentName)} in order to set restrictions on the parent
* profile.
*
+ * <p><strong>Note:</strong> Specifying password requirements using this method clears the
+ * password complexity requirements set using {@link #setRequiredPasswordComplexity(int)}.
+ *
* @param admin Which {@link DeviceAdminReceiver} this request is associated with.
* @param quality The new desired quality. One of {@link #PASSWORD_QUALITY_UNSPECIFIED},
* {@link #PASSWORD_QUALITY_BIOMETRIC_WEAK},
@@ -3630,13 +3633,18 @@
* <p>Note that when called from a profile which uses an unified challenge with its parent, the
* screen lock complexity of the parent will be returned.
*
+ * <p>Apps need the {@link permission#REQUEST_PASSWORD_COMPLEXITY} permission to call this
+ * method. On Android {@link android.os.Build.VERSION_CODES#S} and above, the calling
+ * application does not need this permission if it is a device owner or a profile owner.
+ *
* <p>This method can be called on the {@link DevicePolicyManager} instance
* returned by {@link #getParentProfileInstance(ComponentName)} in order to retrieve
* restrictions on the parent profile.
*
* @throws IllegalStateException if the user is not unlocked.
* @throws SecurityException if the calling application does not have the permission
- * {@link permission#REQUEST_PASSWORD_COMPLEXITY}
+ * {@link permission#REQUEST_PASSWORD_COMPLEXITY}, and is not a
+ * device owner or a profile owner.
*/
@PasswordComplexity
@RequiresPermission(android.Manifest.permission.REQUEST_PASSWORD_COMPLEXITY)
@@ -3653,6 +3661,66 @@
}
/**
+ * Sets a password complexity requirement for the user's screen lock.
+ * The complexity level is one of the pre-defined levels.
+ *
+ * <p>Note that when called on a profile which uses an unified challenge with its parent, the
+ * complexity would apply to the unified challenge.
+ *
+ * <p>This method can be called on the {@link DevicePolicyManager} instance
+ * returned by {@link #getParentProfileInstance(ComponentName)} in order to set
+ * restrictions on the parent profile.
+ *
+ * <p><strong>Note:</strong> Specifying password requirements using this method clears any
+ * password requirements set using the obsolete {@link #setPasswordQuality(ComponentName, int)}
+ * and any of its associated methods.
+ *
+ * @throws SecurityException if the calling application is not a device owner or a profile
+ * owner.
+ * @throws IllegalArgumentException if the complexity level is not one of the four above.
+ */
+ public void setRequiredPasswordComplexity(@PasswordComplexity int passwordComplexity) {
+ if (mService == null) {
+ return;
+ }
+
+ try {
+ mService.setRequiredPasswordComplexity(passwordComplexity, mParentInstance);
+ } catch (RemoteException e) {
+ throw e.rethrowFromSystemServer();
+ }
+ }
+
+
+ /**
+ * Gets the password complexity requirement set by {@link #setRequiredPasswordComplexity(int)},
+ * for the current user.
+ *
+ * <p>The difference between this method and {@link #getPasswordComplexity()} is that this
+ * method simply returns the value set by {@link #setRequiredPasswordComplexity(int)} while
+ * {@link #getPasswordComplexity()} returns the complexity of the actual password.
+ *
+ * <p>This method can be called on the {@link DevicePolicyManager} instance
+ * returned by {@link #getParentProfileInstance(ComponentName)} in order to get
+ * restrictions on the parent profile.
+ *
+ * @throws SecurityException if the calling application is not a device owner or a profile
+ * owner.
+ */
+ @PasswordComplexity
+ public int getRequiredPasswordComplexity() {
+ if (mService == null) {
+ return PASSWORD_COMPLEXITY_NONE;
+ }
+
+ try {
+ return mService.getRequiredPasswordComplexity(mParentInstance);
+ } catch (RemoteException e) {
+ throw e.rethrowFromSystemServer();
+ }
+ }
+
+ /**
* When called by a profile owner of a managed profile returns true if the profile uses unified
* challenge with its parent user.
*
@@ -6708,7 +6776,7 @@
* @hide
*/
@SystemApi
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
public boolean isDeviceManaged() {
try {
return mService.hasDeviceOwner();
@@ -10010,6 +10078,8 @@
* <li>{@link #getRequiredStrongAuthTimeout}</li>
* <li>{@link #setRequiredStrongAuthTimeout}</li>
* <li>{@link #getAccountTypesWithManagementDisabled}</li>
+ * <li>{@link #setRequiredPasswordComplexity(int)} </li>
+ * <li>{@link #getRequiredPasswordComplexity()}</li>
* </ul>
* <p>
* The following methods are supported for the parent instance but can only be called by the
@@ -10417,7 +10487,7 @@
* @hide
*/
@SystemApi
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
public @Nullable CharSequence getDeviceOwnerOrganizationName() {
try {
return mService.getDeviceOwnerOrganizationName();
diff --git a/core/java/android/app/admin/IDevicePolicyManager.aidl b/core/java/android/app/admin/IDevicePolicyManager.aidl
index f4105e9..58368bc 100644
--- a/core/java/android/app/admin/IDevicePolicyManager.aidl
+++ b/core/java/android/app/admin/IDevicePolicyManager.aidl
@@ -87,6 +87,8 @@
boolean isProfileActivePasswordSufficientForParent(int userHandle);
boolean isPasswordSufficientAfterProfileUnification(int userHandle, int profileUser);
int getPasswordComplexity(boolean parent);
+ void setRequiredPasswordComplexity(int passwordComplexity, boolean parent);
+ int getRequiredPasswordComplexity(boolean parent);
boolean isUsingUnifiedPassword(in ComponentName admin);
int getCurrentFailedPasswordAttempts(int userHandle, boolean parent);
int getProfileWithMinimumFailedPasswordsForWipe(int userHandle, boolean parent);
diff --git a/core/java/android/content/ContentResolver.java b/core/java/android/content/ContentResolver.java
index 422d3f7..e35fb03 100644
--- a/core/java/android/content/ContentResolver.java
+++ b/core/java/android/content/ContentResolver.java
@@ -839,6 +839,7 @@
}
/** @hide */
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage
protected abstract IContentProvider acquireProvider(Context c, String name);
@@ -855,15 +856,19 @@
}
/** @hide */
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage
public abstract boolean releaseProvider(IContentProvider icp);
/** @hide */
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage
protected abstract IContentProvider acquireUnstableProvider(Context c, String name);
/** @hide */
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage
public abstract boolean releaseUnstableProvider(IContentProvider icp);
/** @hide */
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage
public abstract void unstableProviderDied(IContentProvider icp);
diff --git a/core/java/android/content/Context.java b/core/java/android/content/Context.java
index 46d4f22..fb1366d 100644
--- a/core/java/android/content/Context.java
+++ b/core/java/android/content/Context.java
@@ -811,6 +811,7 @@
* case {@link #getOpPackageName()} will be the name of the primary package in
* that process (so that app ops uid verification will work with the name).
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage
public abstract String getBasePackageName();
@@ -927,6 +928,7 @@
* @see #MODE_PRIVATE
* @removed
*/
+ @SuppressWarnings("HiddenAbstractMethod")
public abstract SharedPreferences getSharedPreferences(File file, @PreferencesMode int mode);
/**
@@ -957,6 +959,7 @@
public abstract boolean deleteSharedPreferences(String name);
/** @hide */
+ @SuppressWarnings("HiddenAbstractMethod")
public abstract void reloadSharedPreferences();
/**
@@ -1045,6 +1048,7 @@
* @see #getSharedPreferences(String, int)
* @removed
*/
+ @SuppressWarnings("HiddenAbstractMethod")
public abstract File getSharedPreferencesPath(String name);
/**
@@ -1516,6 +1520,7 @@
* There is no guarantee when these files will be deleted.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@Nullable
@SystemApi
public abstract File getPreloadsFileCache();
@@ -2184,6 +2189,7 @@
* @see #sendOrderedBroadcast(Intent, String, BroadcastReceiver, Handler, int, String, Bundle)
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
public abstract void sendBroadcastAsUserMultiplePermissions(Intent intent, UserHandle user,
String[] receiverPermissions);
@@ -2214,6 +2220,7 @@
* @see #sendOrderedBroadcast(Intent, String, BroadcastReceiver, Handler, int, String, Bundle)
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
public abstract void sendBroadcast(Intent intent,
@Nullable String receiverPermission,
@@ -2224,6 +2231,7 @@
* of an associated app op as per {@link android.app.AppOpsManager}.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage
public abstract void sendBroadcast(Intent intent,
String receiverPermission, int appOp);
@@ -2339,6 +2347,7 @@
* @see android.app.Activity#RESULT_OK
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
public abstract void sendOrderedBroadcast(@NonNull Intent intent,
@Nullable String receiverPermission, @Nullable Bundle options,
@@ -2351,6 +2360,7 @@
* of an associated app op as per {@link android.app.AppOpsManager}.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage
public abstract void sendOrderedBroadcast(Intent intent,
String receiverPermission, int appOp, BroadcastReceiver resultReceiver,
@@ -2404,6 +2414,7 @@
* @see #sendBroadcast(Intent, String, Bundle)
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
@RequiresPermission(android.Manifest.permission.INTERACT_ACROSS_USERS)
public abstract void sendBroadcastAsUser(@RequiresPermission Intent intent,
@@ -2426,6 +2437,7 @@
*
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@RequiresPermission(android.Manifest.permission.INTERACT_ACROSS_USERS)
@UnsupportedAppUsage(maxTargetSdk = Build.VERSION_CODES.R, trackingBug = 170729553)
public abstract void sendBroadcastAsUser(@RequiresPermission Intent intent,
@@ -2472,6 +2484,7 @@
* BroadcastReceiver, Handler, int, String, Bundle)
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@RequiresPermission(android.Manifest.permission.INTERACT_ACROSS_USERS)
@UnsupportedAppUsage(maxTargetSdk = Build.VERSION_CODES.R, trackingBug = 170729553)
public abstract void sendOrderedBroadcastAsUser(Intent intent, UserHandle user,
@@ -2485,6 +2498,7 @@
* BroadcastReceiver, Handler, int, String, Bundle)
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@RequiresPermission(android.Manifest.permission.INTERACT_ACROSS_USERS)
@UnsupportedAppUsage
public abstract void sendOrderedBroadcastAsUser(Intent intent, UserHandle user,
@@ -2699,6 +2713,7 @@
* @hide
* This is just here for sending CONNECTIVITY_ACTION.
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@Deprecated
@RequiresPermission(allOf = {
android.Manifest.permission.INTERACT_ACROSS_USERS,
@@ -2989,6 +3004,7 @@
* @see #sendBroadcast
* @see #unregisterReceiver
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@Nullable
@RequiresPermission(android.Manifest.permission.INTERACT_ACROSS_USERS_FULL)
@UnsupportedAppUsage
@@ -3099,6 +3115,7 @@
/**
* @hide like {@link #startForegroundService(Intent)} but for a specific user.
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@Nullable
@RequiresPermission(android.Manifest.permission.INTERACT_ACROSS_USERS)
public abstract ComponentName startForegroundServiceAsUser(Intent service, UserHandle user);
@@ -3137,6 +3154,7 @@
/**
* @hide like {@link #startService(Intent)} but for a specific user.
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@Nullable
@RequiresPermission(android.Manifest.permission.INTERACT_ACROSS_USERS)
@UnsupportedAppUsage
@@ -3145,6 +3163,7 @@
/**
* @hide like {@link #stopService(Intent)} but for a specific user.
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@RequiresPermission(android.Manifest.permission.INTERACT_ACROSS_USERS)
public abstract boolean stopServiceAsUser(Intent service, UserHandle user);
@@ -5282,6 +5301,7 @@
public abstract int checkPermission(@NonNull String permission, int pid, int uid);
/** @hide */
+ @SuppressWarnings("HiddenAbstractMethod")
@PackageManager.PermissionResult
@UnsupportedAppUsage(maxTargetSdk = Build.VERSION_CODES.R, trackingBug = 170729553)
public abstract int checkPermission(@NonNull String permission, int pid, int uid,
@@ -5509,6 +5529,7 @@
@Intent.AccessUriMode int modeFlags);
/** @hide */
+ @SuppressWarnings("HiddenAbstractMethod")
@PackageManager.PermissionResult
public abstract int checkUriPermission(Uri uri, int pid, int uid,
@Intent.AccessUriMode int modeFlags, IBinder callerToken);
@@ -5793,6 +5814,7 @@
*
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage
public abstract Context createApplicationContext(ApplicationInfo application,
@CreatePackageOptions int flags) throws PackageManager.NameNotFoundException;
@@ -6024,6 +6046,7 @@
* @see #isCredentialProtectedStorage()
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
public abstract Context createCredentialProtectedStorageContext();
@@ -6036,6 +6059,7 @@
* @return The compatibility info holder, or null if not required by the application.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
public abstract DisplayAdjustments getDisplayAdjustments(int displayId);
/**
@@ -6070,12 +6094,14 @@
* @see #getDisplay()
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@TestApi
public abstract int getDisplayId();
/**
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
public abstract void updateDisplay(int displayId);
/**
@@ -6104,6 +6130,7 @@
* @see #createCredentialProtectedStorageContext()
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
public abstract boolean isCredentialProtectedStorage();
@@ -6111,6 +6138,7 @@
* Returns true if the context can load unsafe resources, e.g. fonts.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
public abstract boolean canLoadUnsafeResources();
/**
diff --git a/core/java/android/content/pm/PackageManager.java b/core/java/android/content/pm/PackageManager.java
index a77d8b1..cc484de 100644
--- a/core/java/android/content/pm/PackageManager.java
+++ b/core/java/android/content/pm/PackageManager.java
@@ -40,7 +40,7 @@
import android.app.admin.DevicePolicyManager;
import android.app.usage.StorageStatsManager;
import android.compat.annotation.ChangeId;
-import android.compat.annotation.EnabledAfter;
+import android.compat.annotation.EnabledSince;
import android.compat.annotation.UnsupportedAppUsage;
import android.content.ComponentName;
import android.content.Context;
@@ -3765,7 +3765,7 @@
* @hide
*/
@ChangeId
- @EnabledAfter(targetSdkVersion = Build.VERSION_CODES.Q)
+ @EnabledSince(targetSdkVersion = Build.VERSION_CODES.R)
public static final long FILTER_APPLICATION_QUERY = 135549675L;
/** {@hide} */
@@ -3919,6 +3919,7 @@
* found on the system.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@RequiresPermission(Manifest.permission.INTERACT_ACROSS_USERS)
@UnsupportedAppUsage
public abstract PackageInfo getPackageInfoAsUser(@NonNull String packageName,
@@ -3985,6 +3986,7 @@
* does not contain such an activity.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
public abstract @Nullable Intent getCarLaunchIntentForPackage(@NonNull String packageName);
/**
@@ -4050,6 +4052,7 @@
* found on the system.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage
public abstract int getPackageUidAsUser(@NonNull String packageName, @UserIdInt int userId)
throws NameNotFoundException;
@@ -4068,6 +4071,7 @@
* found on the system.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage
public abstract int getPackageUidAsUser(@NonNull String packageName,
@PackageInfoFlags int flags, @UserIdInt int userId) throws NameNotFoundException;
@@ -4110,6 +4114,7 @@
*
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
public abstract boolean arePermissionsIndividuallyControlled();
@@ -4118,6 +4123,7 @@
*
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
public abstract boolean isWirelessConsentModeEnabled();
/**
@@ -4170,6 +4176,7 @@
@ApplicationInfoFlags int flags) throws NameNotFoundException;
/** {@hide} */
+ @SuppressWarnings("HiddenAbstractMethod")
@NonNull
@UnsupportedAppUsage
public abstract ApplicationInfo getApplicationInfoAsUser(@NonNull String packageName,
@@ -4360,6 +4367,7 @@
* deleted with {@code DELETE_KEEP_DATA} flag set).
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@NonNull
@SystemApi
@RequiresPermission(android.Manifest.permission.INTERACT_ACROSS_USERS_FULL)
@@ -4408,6 +4416,7 @@
*
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage
@NonNull
@TestApi
@@ -4521,6 +4530,7 @@
*
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
@RequiresPermission(android.Manifest.permission.GRANT_RUNTIME_PERMISSIONS)
public abstract void grantRuntimePermission(@NonNull String packageName,
@@ -4547,6 +4557,7 @@
*
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
@RequiresPermission(android.Manifest.permission.REVOKE_RUNTIME_PERMISSIONS)
public abstract void revokeRuntimePermission(@NonNull String packageName,
@@ -4591,6 +4602,7 @@
*
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
@RequiresPermission(anyOf = {
android.Manifest.permission.GRANT_RUNTIME_PERMISSIONS,
@@ -4613,6 +4625,7 @@
*
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
@RequiresPermission(anyOf = {
android.Manifest.permission.GRANT_RUNTIME_PERMISSIONS,
@@ -4888,6 +4901,7 @@
*
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage
public abstract boolean shouldShowRequestPermissionRationale(@NonNull String permName);
@@ -5003,6 +5017,7 @@
*
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@TestApi
public abstract @Nullable String[] getNamesForUids(int[] uids);
@@ -5019,6 +5034,7 @@
* found on the system.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage
public abstract int getUidForSharedUser(@NonNull String sharedUserName)
throws NameNotFoundException;
@@ -5062,6 +5078,7 @@
* deleted with {@code DELETE_KEEP_DATA} flag set).
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@NonNull
@TestApi
public abstract List<ApplicationInfo> getInstalledApplicationsAsUser(
@@ -5074,6 +5091,7 @@
*
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
@RequiresPermission(Manifest.permission.ACCESS_INSTANT_APPS)
public abstract @NonNull List<InstantAppInfo> getInstantApps();
@@ -5085,6 +5103,7 @@
*
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
@RequiresPermission(Manifest.permission.ACCESS_INSTANT_APPS)
public abstract @Nullable Drawable getInstantAppIcon(String packageName);
@@ -5133,6 +5152,7 @@
* deprecated
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
public abstract int getInstantAppCookieMaxSize();
/**
@@ -5190,6 +5210,7 @@
/**
* @removed
*/
+ @SuppressWarnings("HiddenAbstractMethod")
public abstract boolean setInstantAppCookie(@Nullable byte[] cookie);
/**
@@ -5228,6 +5249,7 @@
*
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
public abstract @NonNull List<SharedLibraryInfo> getSharedLibrariesAsUser(
@InstallFlags int flags, @UserIdInt int userId);
@@ -5240,6 +5262,7 @@
*
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@NonNull
@RequiresPermission(Manifest.permission.ACCESS_SHARED_LIBRARIES)
@SystemApi
@@ -5259,6 +5282,7 @@
*
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage
@TestApi
public abstract @NonNull String getServicesSystemSharedLibraryPackageName();
@@ -5270,6 +5294,7 @@
*
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage
@TestApi
public abstract @NonNull String getSharedSystemSharedLibraryPackageName();
@@ -5376,6 +5401,7 @@
* containing something else, such as the activity resolver.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@Nullable
@UnsupportedAppUsage
public abstract ResolveInfo resolveActivityAsUser(@NonNull Intent intent,
@@ -5417,6 +5443,7 @@
* empty list is returned.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@NonNull
@UnsupportedAppUsage
public abstract List<ResolveInfo> queryIntentActivitiesAsUser(@NonNull Intent intent,
@@ -5440,6 +5467,7 @@
* empty list is returned.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@NonNull
@RequiresPermission(Manifest.permission.INTERACT_ACROSS_USERS)
@SystemApi
@@ -5502,6 +5530,7 @@
* no matching receivers, an empty list or null is returned.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@NonNull
@SystemApi
@RequiresPermission(Manifest.permission.INTERACT_ACROSS_USERS)
@@ -5513,6 +5542,7 @@
/**
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@NonNull
@UnsupportedAppUsage
public abstract List<ResolveInfo> queryBroadcastReceiversAsUser(@NonNull Intent intent,
@@ -5551,6 +5581,7 @@
/**
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@Nullable
public abstract ResolveInfo resolveServiceAsUser(@NonNull Intent intent,
@ResolveInfoFlags int flags, @UserIdInt int userId);
@@ -5583,6 +5614,7 @@
* empty list or null is returned.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@NonNull
@UnsupportedAppUsage
public abstract List<ResolveInfo> queryIntentServicesAsUser(@NonNull Intent intent,
@@ -5621,6 +5653,7 @@
* no matching services, an empty list or null is returned.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@NonNull
@UnsupportedAppUsage
public abstract List<ResolveInfo> queryIntentContentProvidersAsUser(
@@ -5688,6 +5721,7 @@
* provider. If a provider was not found, returns null.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@Nullable
@UnsupportedAppUsage
public abstract ProviderInfo resolveContentProviderAsUser(@NonNull String providerName,
@@ -6072,6 +6106,7 @@
* @return the drawable or null if no drawable is required.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@Nullable
@UnsupportedAppUsage
public abstract Drawable getUserBadgeForDensity(@NonNull UserHandle user, int density);
@@ -6090,6 +6125,7 @@
* @return the drawable or null if no drawable is required.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@Nullable
@UnsupportedAppUsage
public abstract Drawable getUserBadgeForDensityNoBackground(@NonNull UserHandle user,
@@ -6228,6 +6264,7 @@
* TODO(b/170852794): mark maxTargetSdk as {@code Build.VERSION_CODES.S}
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@NonNull
@UnsupportedAppUsage(maxTargetSdk = Build.VERSION_CODES.R, trackingBug = 170928809,
publicAlternatives = "Use {@code Context#createContextAsUser(UserHandle, int)}"
@@ -6280,6 +6317,7 @@
*
* @deprecated use {@link PackageInstaller#installExistingPackage()} instead.
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@Deprecated
@SystemApi
public abstract int installExistingPackage(@NonNull String packageName)
@@ -6292,6 +6330,7 @@
*
* @deprecated use {@link PackageInstaller#installExistingPackage()} instead.
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@Deprecated
@SystemApi
public abstract int installExistingPackage(@NonNull String packageName,
@@ -6304,6 +6343,7 @@
*
* @deprecated use {@link PackageInstaller#installExistingPackage()} instead.
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@Deprecated
@RequiresPermission(anyOf = {
Manifest.permission.INSTALL_EXISTING_PACKAGES,
@@ -6384,6 +6424,7 @@
*
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
@RequiresPermission(android.Manifest.permission.INTENT_FILTER_VERIFICATION_AGENT)
public abstract void verifyIntentFilter(int verificationId, int verificationCode,
@@ -6409,6 +6450,7 @@
*
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
@RequiresPermission(Manifest.permission.INTERACT_ACROSS_USERS_FULL)
public abstract int getIntentVerificationStatusAsUser(@NonNull String packageName,
@@ -6434,6 +6476,7 @@
*
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
@RequiresPermission(android.Manifest.permission.SET_PREFERRED_APPLICATIONS)
public abstract boolean updateIntentVerificationStatusAsUser(@NonNull String packageName,
@@ -6451,6 +6494,7 @@
*
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@NonNull
@SystemApi
public abstract List<IntentFilterVerificationInfo> getIntentFilterVerifications(
@@ -6467,6 +6511,7 @@
*
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@NonNull
@SystemApi
public abstract List<IntentFilter> getAllIntentFilters(@NonNull String packageName);
@@ -6481,6 +6526,7 @@
*
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@Nullable
@SystemApi
@RequiresPermission(Manifest.permission.INTERACT_ACROSS_USERS_FULL)
@@ -6498,6 +6544,7 @@
*
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
@RequiresPermission(allOf = {
Manifest.permission.SET_PREFERRED_APPLICATIONS,
@@ -6524,6 +6571,7 @@
@Nullable String installerPackageName);
/** @hide */
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
@RequiresPermission(Manifest.permission.INSTALL_PACKAGES)
public abstract void setUpdateAvailable(@NonNull String packageName, boolean updateAvaialble);
@@ -6544,6 +6592,7 @@
* indicate that no callback is desired.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@RequiresPermission(Manifest.permission.DELETE_PACKAGES)
@UnsupportedAppUsage
public abstract void deletePackage(@NonNull String packageName,
@@ -6564,6 +6613,7 @@
* @param userId The user Id
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@RequiresPermission(anyOf = {
Manifest.permission.DELETE_PACKAGES,
Manifest.permission.INTERACT_ACROSS_USERS_FULL})
@@ -6581,6 +6631,7 @@
*
* @deprecated use {@link #getInstallSourceInfo(String)} instead
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@Deprecated
@Nullable
public abstract String getInstallerPackageName(@NonNull String packageName);
@@ -6620,6 +6671,7 @@
*
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage
public abstract void clearApplicationUserData(@NonNull String packageName,
@Nullable IPackageDataObserver observer);
@@ -6639,6 +6691,7 @@
*
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage
public abstract void deleteApplicationCacheFiles(@NonNull String packageName,
@Nullable IPackageDataObserver observer);
@@ -6661,6 +6714,7 @@
* callback is desired.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage
public abstract void deleteApplicationCacheFilesAsUser(@NonNull String packageName,
@UserIdInt int userId, @Nullable IPackageDataObserver observer);
@@ -6694,6 +6748,7 @@
}
/** {@hide} */
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage
public abstract void freeStorageAndNotify(@Nullable String volumeUuid, long freeStorageSize,
@Nullable IPackageDataObserver observer);
@@ -6727,6 +6782,7 @@
}
/** {@hide} */
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage
public abstract void freeStorage(@Nullable String volumeUuid, long freeStorageSize,
@Nullable IntentSender pi);
@@ -6750,6 +6806,7 @@
* @deprecated use {@link StorageStatsManager} instead.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@Deprecated
@UnsupportedAppUsage
public abstract void getPackageSizeInfoAsUser(@NonNull String packageName,
@@ -6881,6 +6938,7 @@
* an app to be responsible for a particular role and to check current role
* holders, see {@link android.app.role.RoleManager}.
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@Deprecated
@UnsupportedAppUsage
public abstract void replacePreferredActivity(@NonNull IntentFilter filter, int match,
@@ -6988,6 +7046,7 @@
* default, if any.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@Nullable
@UnsupportedAppUsage
public abstract ComponentName getHomeActivities(@NonNull List<ResolveInfo> outActivities);
@@ -7089,6 +7148,7 @@
* @param userId Ther userId of the user whose restrictions are to be flushed.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage
public abstract void flushPackageRestrictionsAsUser(@UserIdInt int userId);
@@ -7099,6 +7159,7 @@
* or by installing it, such as with {@link #installExistingPackage(String)}
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage
public abstract boolean setApplicationHiddenSettingAsUser(@NonNull String packageName,
boolean hidden, @NonNull UserHandle userHandle);
@@ -7108,6 +7169,7 @@
* @see #setApplicationHiddenSettingAsUser(String, boolean, UserHandle)
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage
public abstract boolean getApplicationHiddenSettingAsUser(@NonNull String packageName,
@NonNull UserHandle userHandle);
@@ -7141,6 +7203,7 @@
*
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
@RequiresPermission(Manifest.permission.OBSERVE_GRANT_REVOKE_PERMISSIONS)
public abstract void addOnPermissionsChangeListener(
@@ -7153,6 +7216,7 @@
*
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
@RequiresPermission(Manifest.permission.OBSERVE_GRANT_REVOKE_PERMISSIONS)
public abstract void removeOnPermissionsChangeListener(
@@ -7166,6 +7230,7 @@
* application's AndroidManifest.xml.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@NonNull
@UnsupportedAppUsage
public abstract KeySet getKeySetByAlias(@NonNull String packageName, @NonNull String alias);
@@ -7173,6 +7238,7 @@
/** Return the signing {@link KeySet} for this application.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@NonNull
@UnsupportedAppUsage
public abstract KeySet getSigningKeySet(@NonNull String packageName);
@@ -7184,6 +7250,7 @@
* Compare to {@link #isSignedByExactly(String packageName, KeySet ks)}.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage
public abstract boolean isSignedBy(@NonNull String packageName, @NonNull KeySet ks);
@@ -7193,6 +7260,7 @@
* {@link #isSignedBy(String packageName, KeySet ks)}.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage
public abstract boolean isSignedByExactly(@NonNull String packageName, @NonNull KeySet ks);
@@ -7410,6 +7478,7 @@
* @throws IllegalArgumentException if the package was not found.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage
public abstract boolean isPackageSuspendedForUser(@NonNull String packageName, int userId);
@@ -7485,6 +7554,7 @@
* @param packageName the package to change the category hint for.
* @param categoryHint the category hint to set.
*/
+ @SuppressWarnings("HiddenAbstractMethod")
public abstract void setApplicationCategoryHint(@NonNull String packageName,
@ApplicationInfo.Category int categoryHint);
@@ -7500,34 +7570,43 @@
}
/** {@hide} */
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage
public abstract int getMoveStatus(int moveId);
/** {@hide} */
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage
public abstract void registerMoveCallback(@NonNull MoveCallback callback,
@NonNull Handler handler);
/** {@hide} */
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage
public abstract void unregisterMoveCallback(@NonNull MoveCallback callback);
/** {@hide} */
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage(maxTargetSdk = Build.VERSION_CODES.R, trackingBug = 170729553)
public abstract int movePackage(@NonNull String packageName, @NonNull VolumeInfo vol);
/** {@hide} */
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage(maxTargetSdk = Build.VERSION_CODES.R, trackingBug = 170729553)
public abstract @Nullable VolumeInfo getPackageCurrentVolume(@NonNull ApplicationInfo app);
/** {@hide} */
+ @SuppressWarnings("HiddenAbstractMethod")
@NonNull
@UnsupportedAppUsage(maxTargetSdk = Build.VERSION_CODES.R, trackingBug = 170729553)
public abstract List<VolumeInfo> getPackageCandidateVolumes(
@NonNull ApplicationInfo app);
/** {@hide} */
+ @SuppressWarnings("HiddenAbstractMethod")
public abstract int movePrimaryStorage(@NonNull VolumeInfo vol);
/** {@hide} */
+ @SuppressWarnings("HiddenAbstractMethod")
public abstract @Nullable VolumeInfo getPrimaryStorageCurrentVolume();
/** {@hide} */
+ @SuppressWarnings("HiddenAbstractMethod")
public abstract @NonNull List<VolumeInfo> getPrimaryStorageCandidateVolumes();
/**
@@ -7537,6 +7616,7 @@
* @return identity that uniquely identifies current device
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@NonNull
public abstract VerifierDeviceIdentity getVerifierDeviceIdentity();
@@ -7545,6 +7625,7 @@
*
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage
public abstract boolean isUpgrade();
@@ -7574,6 +7655,7 @@
* {@link #ONLY_IF_NO_MATCH_FOUND}.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage
public abstract void addCrossProfileIntentFilter(@NonNull IntentFilter filter,
@UserIdInt int sourceUserId, @UserIdInt int targetUserId, int flags);
@@ -7585,12 +7667,14 @@
* @param sourceUserId The source user id.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage
public abstract void clearCrossProfileIntentFilters(@UserIdInt int sourceUserId);
/**
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@NonNull
@UnsupportedAppUsage
public abstract Drawable loadItemIcon(@NonNull PackageItemInfo itemInfo,
@@ -7599,12 +7683,14 @@
/**
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@NonNull
@UnsupportedAppUsage
public abstract Drawable loadUnbadgedItemIcon(@NonNull PackageItemInfo itemInfo,
@Nullable ApplicationInfo appInfo);
/** {@hide} */
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage
public abstract boolean isPackageAvailable(@NonNull String packageName);
@@ -7825,6 +7911,7 @@
* user, {@code INSTALL_REASON_UNKNOWN} is returned.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@TestApi
@InstallReason
public abstract int getInstallReason(@NonNull String packageName, @NonNull UserHandle user);
@@ -7853,6 +7940,7 @@
* @see {@link android.content.Intent#ACTION_INSTANT_APP_RESOLVER_SETTINGS}
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@Nullable
@SystemApi
public abstract ComponentName getInstantAppResolverSettingsComponent();
@@ -7864,6 +7952,7 @@
* @see {@link android.content.Intent#ACTION_INSTALL_INSTANT_APP_PACKAGE}
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@Nullable
@SystemApi
public abstract ComponentName getInstantAppInstallerComponent();
@@ -7874,6 +7963,7 @@
* @see {@link android.provider.Settings.Secure#ANDROID_ID}
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@Nullable
public abstract String getInstantAppAndroidId(@NonNull String packageName,
@NonNull UserHandle user);
@@ -7918,6 +8008,7 @@
*
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
public abstract void registerDexModule(@NonNull String dexModulePath,
@Nullable DexModuleRegisterCallback callback);
diff --git a/core/java/android/content/pm/ShortcutInfo.java b/core/java/android/content/pm/ShortcutInfo.java
index 6a6be75..da75fba 100644
--- a/core/java/android/content/pm/ShortcutInfo.java
+++ b/core/java/android/content/pm/ShortcutInfo.java
@@ -1319,8 +1319,8 @@
* system services even after it has been unpublished as a dynamic shortcut.
*/
@NonNull
- public Builder setLongLived(boolean londLived) {
- mIsLongLived = londLived;
+ public Builder setLongLived(boolean longLived) {
+ mIsLongLived = longLived;
return this;
}
diff --git a/core/java/android/content/pm/parsing/PackageInfoWithoutStateUtils.java b/core/java/android/content/pm/parsing/PackageInfoWithoutStateUtils.java
index c5240c2..ddf3d90 100644
--- a/core/java/android/content/pm/parsing/PackageInfoWithoutStateUtils.java
+++ b/core/java/android/content/pm/parsing/PackageInfoWithoutStateUtils.java
@@ -419,7 +419,7 @@
return null;
}
- return generateActivityInfoUnchecked(a, applicationInfo);
+ return generateActivityInfoUnchecked(a, flags, applicationInfo);
}
/**
@@ -431,6 +431,7 @@
*/
@NonNull
public static ActivityInfo generateActivityInfoUnchecked(@NonNull ParsedActivity a,
+ @PackageManager.ComponentInfoFlags int flags,
@NonNull ApplicationInfo applicationInfo) {
// Make shallow copies so we can store the metadata safely
ActivityInfo ai = new ActivityInfo();
@@ -463,7 +464,9 @@
ai.rotationAnimation = a.getRotationAnimation();
ai.colorMode = a.getColorMode();
ai.windowLayout = a.getWindowLayout();
- ai.metaData = a.getMetaData();
+ if ((flags & PackageManager.GET_META_DATA) != 0) {
+ ai.metaData = a.getMetaData();
+ }
ai.applicationInfo = applicationInfo;
return ai;
}
@@ -489,7 +492,7 @@
return null;
}
- return generateServiceInfoUnchecked(s, applicationInfo);
+ return generateServiceInfoUnchecked(s, flags, applicationInfo);
}
/**
@@ -501,17 +504,20 @@
*/
@NonNull
public static ServiceInfo generateServiceInfoUnchecked(@NonNull ParsedService s,
+ @PackageManager.ComponentInfoFlags int flags,
@NonNull ApplicationInfo applicationInfo) {
// Make shallow copies so we can store the metadata safely
ServiceInfo si = new ServiceInfo();
assignSharedFieldsForComponentInfo(si, s);
si.exported = s.isExported();
si.flags = s.getFlags();
- si.metaData = s.getMetaData();
si.permission = s.getPermission();
si.processName = s.getProcessName();
si.mForegroundServiceType = s.getForegroundServiceType();
si.applicationInfo = applicationInfo;
+ if ((flags & PackageManager.GET_META_DATA) != 0) {
+ si.metaData = s.getMetaData();
+ }
return si;
}
@@ -566,10 +572,12 @@
pi.initOrder = p.getInitOrder();
pi.uriPermissionPatterns = p.getUriPermissionPatterns();
pi.pathPermissions = p.getPathPermissions();
- pi.metaData = p.getMetaData();
if ((flags & PackageManager.GET_URI_PERMISSION_PATTERNS) == 0) {
pi.uriPermissionPatterns = null;
}
+ if ((flags & PackageManager.GET_META_DATA) != 0) {
+ pi.metaData = p.getMetaData();
+ }
pi.applicationInfo = applicationInfo;
return pi;
}
diff --git a/core/java/android/hardware/camera2/CameraCaptureSession.java b/core/java/android/hardware/camera2/CameraCaptureSession.java
index f0a83f0..e858159 100644
--- a/core/java/android/hardware/camera2/CameraCaptureSession.java
+++ b/core/java/android/hardware/camera2/CameraCaptureSession.java
@@ -188,6 +188,7 @@
*
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
public abstract void prepare(int maxCount, @NonNull Surface surface)
throws CameraAccessException;
@@ -227,6 +228,7 @@
*
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
public abstract void tearDown(@NonNull Surface surface) throws CameraAccessException;
/**
diff --git a/core/java/android/hardware/hdmi/HdmiControlManager.java b/core/java/android/hardware/hdmi/HdmiControlManager.java
index 500b299..f1534d9 100644
--- a/core/java/android/hardware/hdmi/HdmiControlManager.java
+++ b/core/java/android/hardware/hdmi/HdmiControlManager.java
@@ -577,7 +577,7 @@
*/
@Nullable
@SystemApi
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
public HdmiClient getClient(int type) {
if (mService == null) {
return null;
@@ -610,7 +610,7 @@
*/
@Nullable
@SystemApi
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
public HdmiPlaybackClient getPlaybackClient() {
return (HdmiPlaybackClient) getClient(HdmiDeviceInfo.DEVICE_PLAYBACK);
}
@@ -628,7 +628,7 @@
*/
@Nullable
@SystemApi
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
public HdmiTvClient getTvClient() {
return (HdmiTvClient) getClient(HdmiDeviceInfo.DEVICE_TV);
}
@@ -646,7 +646,7 @@
* @hide
*/
@Nullable
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
public HdmiAudioSystemClient getAudioSystemClient() {
return (HdmiAudioSystemClient) getClient(HdmiDeviceInfo.DEVICE_AUDIO_SYSTEM);
}
@@ -661,7 +661,7 @@
* @return {@link HdmiSwitchClient} instance. {@code null} on failure.
*/
@Nullable
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
public HdmiSwitchClient getSwitchClient() {
return (HdmiSwitchClient) getClient(HdmiDeviceInfo.DEVICE_PURE_CEC_SWITCH);
}
diff --git a/core/java/android/hardware/location/ContextHubManager.java b/core/java/android/hardware/location/ContextHubManager.java
index 1ed791d..d444807 100644
--- a/core/java/android/hardware/location/ContextHubManager.java
+++ b/core/java/android/hardware/location/ContextHubManager.java
@@ -654,7 +654,7 @@
* register a {@link android.hardware.location.ContextHubClientCallback}.
*/
@Deprecated
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
public int registerCallback(@NonNull Callback callback) {
return registerCallback(callback, null);
}
@@ -688,7 +688,7 @@
* register a {@link android.hardware.location.ContextHubClientCallback}.
*/
@Deprecated
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
public int registerCallback(Callback callback, Handler handler) {
synchronized(this) {
if (mCallback != null) {
@@ -892,7 +892,7 @@
* @deprecated Use {@link android.hardware.location.ContextHubClient#close()} to unregister
* a {@link android.hardware.location.ContextHubClientCallback}.
*/
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
@Deprecated
public int unregisterCallback(@NonNull Callback callback) {
synchronized(this) {
diff --git a/core/java/android/hardware/radio/RadioTuner.java b/core/java/android/hardware/radio/RadioTuner.java
index 0edd055..969db96 100644
--- a/core/java/android/hardware/radio/RadioTuner.java
+++ b/core/java/android/hardware/radio/RadioTuner.java
@@ -257,6 +257,7 @@
* @throws IllegalArgumentException if id==0
* @hide This API is not thoroughly elaborated yet
*/
+ @SuppressWarnings("HiddenAbstractMethod")
public abstract @Nullable Bitmap getMetadataImage(int id);
/**
diff --git a/core/java/android/hardware/usb/UsbDeviceConnection.java b/core/java/android/hardware/usb/UsbDeviceConnection.java
index 21634cc..1c35cb6 100644
--- a/core/java/android/hardware/usb/UsbDeviceConnection.java
+++ b/core/java/android/hardware/usb/UsbDeviceConnection.java
@@ -299,7 +299,7 @@
* @hide
*/
@SystemApi
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
public boolean resetDevice() {
return native_reset_device();
}
diff --git a/core/java/android/inputmethodservice/AbstractInputMethodService.java b/core/java/android/inputmethodservice/AbstractInputMethodService.java
index 3ca5207..cd43637 100644
--- a/core/java/android/inputmethodservice/AbstractInputMethodService.java
+++ b/core/java/android/inputmethodservice/AbstractInputMethodService.java
@@ -202,6 +202,7 @@
* @param args The arguments passed to the dump method.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
abstract void dumpProtoInternal(FileDescriptor fd, String[] args);
/**
diff --git a/core/java/android/net/TrafficStats.java b/core/java/android/net/TrafficStats.java
index 7376830..4e019cf 100644
--- a/core/java/android/net/TrafficStats.java
+++ b/core/java/android/net/TrafficStats.java
@@ -301,7 +301,7 @@
* Changes only take effect during subsequent calls to
* {@link #tagSocket(Socket)}.
*/
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
public static void setThreadStatsUid(int uid) {
NetworkManagementSocketTagger.setThreadSocketStatsUid(uid);
}
@@ -339,7 +339,7 @@
*
* @see #setThreadStatsUid(int)
*/
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
public static void clearThreadStatsUid() {
NetworkManagementSocketTagger.setThreadSocketStatsUid(-1);
}
diff --git a/core/java/android/os/BasicShellCommandHandler.java b/core/java/android/os/BasicShellCommandHandler.java
new file mode 100644
index 0000000..366da3d
--- /dev/null
+++ b/core/java/android/os/BasicShellCommandHandler.java
@@ -0,0 +1,342 @@
+/*
+ * Copyright (C) 2019 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package android.os;
+
+import android.util.Log;
+
+import java.io.BufferedInputStream;
+import java.io.FileDescriptor;
+import java.io.FileInputStream;
+import java.io.FileOutputStream;
+import java.io.InputStream;
+import java.io.OutputStream;
+import java.io.PrintWriter;
+
+/**
+ * Helper for implementing {@link Binder#onShellCommand Binder.onShellCommand}. This is meant to
+ * be copied into mainline modules, so this class must not use any hidden APIs.
+ *
+ * @hide
+ */
+public abstract class BasicShellCommandHandler {
+ static final String TAG = "ShellCommand";
+ static final boolean DEBUG = false;
+
+ private Binder mTarget;
+ private FileDescriptor mIn;
+ private FileDescriptor mOut;
+ private FileDescriptor mErr;
+ private String[] mArgs;
+
+ private String mCmd;
+ private int mArgPos;
+ private String mCurArgData;
+
+ private FileInputStream mFileIn;
+ private FileOutputStream mFileOut;
+ private FileOutputStream mFileErr;
+
+ private PrintWriter mOutPrintWriter;
+ private PrintWriter mErrPrintWriter;
+ private InputStream mInputStream;
+
+ public void init(Binder target, FileDescriptor in, FileDescriptor out, FileDescriptor err,
+ String[] args, int firstArgPos) {
+ mTarget = target;
+ mIn = in;
+ mOut = out;
+ mErr = err;
+ mArgs = args;
+ mCmd = null;
+ mArgPos = firstArgPos;
+ mCurArgData = null;
+ mFileIn = null;
+ mFileOut = null;
+ mFileErr = null;
+ mOutPrintWriter = null;
+ mErrPrintWriter = null;
+ mInputStream = null;
+ }
+
+ public int exec(Binder target, FileDescriptor in, FileDescriptor out, FileDescriptor err,
+ String[] args) {
+ String cmd;
+ int start;
+ if (args != null && args.length > 0) {
+ cmd = args[0];
+ start = 1;
+ } else {
+ cmd = null;
+ start = 0;
+ }
+ init(target, in, out, err, args, start);
+ mCmd = cmd;
+
+ if (DEBUG) {
+ RuntimeException here = new RuntimeException("here");
+ here.fillInStackTrace();
+ Log.d(TAG, "Starting command " + mCmd + " on " + mTarget, here);
+ Log.d(TAG, "Calling uid=" + Binder.getCallingUid()
+ + " pid=" + Binder.getCallingPid());
+ }
+ int res = -1;
+ try {
+ res = onCommand(mCmd);
+ if (DEBUG) Log.d(TAG, "Executed command " + mCmd + " on " + mTarget);
+ } catch (Throwable e) {
+ // Unlike usual calls, in this case if an exception gets thrown
+ // back to us we want to print it back in to the dump data, since
+ // that is where the caller expects all interesting information to
+ // go.
+ PrintWriter eout = getErrPrintWriter();
+ eout.println();
+ eout.println("Exception occurred while executing '" + mCmd + "':");
+ e.printStackTrace(eout);
+ } finally {
+ if (DEBUG) Log.d(TAG, "Flushing output streams on " + mTarget);
+ if (mOutPrintWriter != null) {
+ mOutPrintWriter.flush();
+ }
+ if (mErrPrintWriter != null) {
+ mErrPrintWriter.flush();
+ }
+ if (DEBUG) Log.d(TAG, "Sending command result on " + mTarget);
+ }
+ if (DEBUG) Log.d(TAG, "Finished command " + mCmd + " on " + mTarget);
+ return res;
+ }
+
+ /**
+ * Return the raw FileDescriptor for the output stream.
+ */
+ public FileDescriptor getOutFileDescriptor() {
+ return mOut;
+ }
+
+ /**
+ * Return direct raw access (not buffered) to the command's output data stream.
+ */
+ public OutputStream getRawOutputStream() {
+ if (mFileOut == null) {
+ mFileOut = new FileOutputStream(mOut);
+ }
+ return mFileOut;
+ }
+
+ /**
+ * Return a PrintWriter for formatting output to {@link #getRawOutputStream()}.
+ */
+ public PrintWriter getOutPrintWriter() {
+ if (mOutPrintWriter == null) {
+ mOutPrintWriter = new PrintWriter(getRawOutputStream());
+ }
+ return mOutPrintWriter;
+ }
+
+ /**
+ * Return the raw FileDescriptor for the error stream.
+ */
+ public FileDescriptor getErrFileDescriptor() {
+ return mErr;
+ }
+
+ /**
+ * Return direct raw access (not buffered) to the command's error output data stream.
+ */
+ public OutputStream getRawErrorStream() {
+ if (mFileErr == null) {
+ mFileErr = new FileOutputStream(mErr);
+ }
+ return mFileErr;
+ }
+
+ /**
+ * Return a PrintWriter for formatting output to {@link #getRawErrorStream()}.
+ */
+ public PrintWriter getErrPrintWriter() {
+ if (mErr == null) {
+ return getOutPrintWriter();
+ }
+ if (mErrPrintWriter == null) {
+ mErrPrintWriter = new PrintWriter(getRawErrorStream());
+ }
+ return mErrPrintWriter;
+ }
+
+ /**
+ * Return the raw FileDescriptor for the input stream.
+ */
+ public FileDescriptor getInFileDescriptor() {
+ return mIn;
+ }
+
+ /**
+ * Return direct raw access (not buffered) to the command's input data stream.
+ */
+ public InputStream getRawInputStream() {
+ if (mFileIn == null) {
+ mFileIn = new FileInputStream(mIn);
+ }
+ return mFileIn;
+ }
+
+ /**
+ * Return buffered access to the command's {@link #getRawInputStream()}.
+ */
+ public InputStream getBufferedInputStream() {
+ if (mInputStream == null) {
+ mInputStream = new BufferedInputStream(getRawInputStream());
+ }
+ return mInputStream;
+ }
+
+ /**
+ * Return the next option on the command line -- that is an argument that
+ * starts with '-'. If the next argument is not an option, null is returned.
+ */
+ public String getNextOption() {
+ if (mCurArgData != null) {
+ String prev = mArgs[mArgPos - 1];
+ throw new IllegalArgumentException("No argument expected after \"" + prev + "\"");
+ }
+ if (mArgPos >= mArgs.length) {
+ return null;
+ }
+ String arg = mArgs[mArgPos];
+ if (!arg.startsWith("-")) {
+ return null;
+ }
+ mArgPos++;
+ if (arg.equals("--")) {
+ return null;
+ }
+ if (arg.length() > 1 && arg.charAt(1) != '-') {
+ if (arg.length() > 2) {
+ mCurArgData = arg.substring(2);
+ return arg.substring(0, 2);
+ } else {
+ mCurArgData = null;
+ return arg;
+ }
+ }
+ mCurArgData = null;
+ return arg;
+ }
+
+ /**
+ * Return the next argument on the command line, whatever it is; if there are
+ * no arguments left, return null.
+ */
+ public String getNextArg() {
+ if (mCurArgData != null) {
+ String arg = mCurArgData;
+ mCurArgData = null;
+ return arg;
+ } else if (mArgPos < mArgs.length) {
+ return mArgs[mArgPos++];
+ } else {
+ return null;
+ }
+ }
+
+ public String peekNextArg() {
+ if (mCurArgData != null) {
+ return mCurArgData;
+ } else if (mArgPos < mArgs.length) {
+ return mArgs[mArgPos];
+ } else {
+ return null;
+ }
+ }
+
+ /**
+ * @return all the remaining arguments in the command without moving the current position.
+ */
+ public String[] peekRemainingArgs() {
+ int remaining = getRemainingArgsCount();
+ String[] args = new String[remaining];
+ for (int pos = mArgPos; pos < mArgs.length; pos++) {
+ args[pos - mArgPos] = mArgs[pos];
+ }
+ return args;
+ }
+
+ /**
+ * Returns number of arguments that haven't been processed yet.
+ */
+ public int getRemainingArgsCount() {
+ if (mArgPos >= mArgs.length) {
+ return 0;
+ }
+ return mArgs.length - mArgPos;
+ }
+
+ /**
+ * Return the next argument on the command line, whatever it is; if there are
+ * no arguments left, throws an IllegalArgumentException to report this to the user.
+ */
+ public String getNextArgRequired() {
+ String arg = getNextArg();
+ if (arg == null) {
+ String prev = mArgs[mArgPos - 1];
+ throw new IllegalArgumentException("Argument expected after \"" + prev + "\"");
+ }
+ return arg;
+ }
+
+ public int handleDefaultCommands(String cmd) {
+ if (cmd == null || "help".equals(cmd) || "-h".equals(cmd)) {
+ onHelp();
+ } else {
+ getOutPrintWriter().println("Unknown command: " + cmd);
+ }
+ return -1;
+ }
+
+ public Binder getTarget() {
+ return mTarget;
+ }
+
+ public String[] getAllArgs() {
+ return mArgs;
+ }
+
+ /**
+ * Implement parsing and execution of a command. If it isn't a command you understand,
+ * call {@link #handleDefaultCommands(String)} and return its result as a last resort.
+ * Use {@link #getNextOption()}, {@link #getNextArg()}, and {@link #getNextArgRequired()}
+ * to process additional command line arguments. Command output can be written to
+ * {@link #getOutPrintWriter()} and errors to {@link #getErrPrintWriter()}.
+ *
+ * <p class="caution">Note that no permission checking has been done before entering this
+ * function, so you need to be sure to do your own security verification for any commands you
+ * are executing. The easiest way to do this is to have the ShellCommand contain
+ * only a reference to your service's aidl interface, and do all of your command
+ * implementations on top of that -- that way you can rely entirely on your executing security
+ * code behind that interface.</p>
+ *
+ * @param cmd The first command line argument representing the name of the command to execute.
+ * @return Return the command result; generally 0 or positive indicates success and
+ * negative values indicate error.
+ */
+ public abstract int onCommand(String cmd);
+
+ /**
+ * Implement this to print help text about your command to {@link #getOutPrintWriter()}.
+ */
+ public abstract void onHelp();
+}
diff --git a/core/java/android/os/FileUtils.java b/core/java/android/os/FileUtils.java
index d151c16..5db4107 100644
--- a/core/java/android/os/FileUtils.java
+++ b/core/java/android/os/FileUtils.java
@@ -1436,7 +1436,10 @@
public static FileDescriptor convertToModernFd(FileDescriptor fd) {
try {
Context context = AppGlobals.getInitialApplication();
- if (UserHandle.getAppId(Process.myUid()) == getMediaProviderAppId(context)) {
+ if (!SystemProperties.getBoolean("persist.sys.fuse.transcode", false)
+ || !SystemProperties.getBoolean("persist.sys.fuse.transcode_optimize", true)
+ || UserHandle.getAppId(Process.myUid()) == getMediaProviderAppId(context)) {
+ // If transcode is enabled we optimize by default, unless explicitly disabled.
// Never convert modern fd for MediaProvider, because this requires
// MediaStore#scanFile and can cause infinite loops when MediaProvider scans
return null;
diff --git a/core/java/android/os/RecoverySystem.java b/core/java/android/os/RecoverySystem.java
index 13b30f4..72cd8ba 100644
--- a/core/java/android/os/RecoverySystem.java
+++ b/core/java/android/os/RecoverySystem.java
@@ -422,7 +422,7 @@
* {@hide}
*/
@SystemApi
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
public static boolean verifyPackageCompatibility(File compatibilityFile) throws IOException {
try (InputStream inputStream = new FileInputStream(compatibilityFile)) {
return verifyPackageCompatibility(inputStream);
diff --git a/core/java/android/os/ShellCommand.java b/core/java/android/os/ShellCommand.java
index a2173a6..3358ce1 100644
--- a/core/java/android/os/ShellCommand.java
+++ b/core/java/android/os/ShellCommand.java
@@ -19,9 +19,15 @@
import android.compat.annotation.UnsupportedAppUsage;
import android.util.Slog;
-import com.android.modules.utils.BasicShellCommandHandler;
+import com.android.internal.util.FastPrintWriter;
+import java.io.BufferedInputStream;
import java.io.FileDescriptor;
+import java.io.FileInputStream;
+import java.io.FileOutputStream;
+import java.io.InputStream;
+import java.io.OutputStream;
+import java.io.PrintWriter;
/**
* Helper for implementing {@link Binder#onShellCommand Binder.onShellCommand}.
diff --git a/core/java/android/os/storage/StorageManager.java b/core/java/android/os/storage/StorageManager.java
index 5d3c66c..cfc3e01 100644
--- a/core/java/android/os/storage/StorageManager.java
+++ b/core/java/android/os/storage/StorageManager.java
@@ -2215,7 +2215,7 @@
/** @hide */
@SystemApi
@WorkerThread
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
public long getAllocatableBytes(@NonNull UUID storageUuid,
@RequiresPermission @AllocateFlags int flags) throws IOException {
try {
@@ -2264,7 +2264,7 @@
/** @hide */
@SystemApi
@WorkerThread
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
public void allocateBytes(@NonNull UUID storageUuid, @BytesLong long bytes,
@RequiresPermission @AllocateFlags int flags) throws IOException {
try {
@@ -2314,7 +2314,7 @@
/** @hide */
@SystemApi
@WorkerThread
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
public void allocateBytes(FileDescriptor fd, @BytesLong long bytes,
@RequiresPermission @AllocateFlags int flags) throws IOException {
final File file = ParcelFileDescriptor.getFile(fd);
diff --git a/core/java/android/service/autofill/InternalTransformation.java b/core/java/android/service/autofill/InternalTransformation.java
index 0dba2b9..d31ea99 100644
--- a/core/java/android/service/autofill/InternalTransformation.java
+++ b/core/java/android/service/autofill/InternalTransformation.java
@@ -45,6 +45,7 @@
* @param template the {@link RemoteViews presentation template}.
* @param childViewId resource id of the child view inside the template.
*/
+ @SuppressWarnings("HiddenAbstractMethod")
abstract void apply(@NonNull ValueFinder finder, @NonNull RemoteViews template,
int childViewId) throws Exception;
diff --git a/core/java/android/service/persistentdata/PersistentDataBlockManager.java b/core/java/android/service/persistentdata/PersistentDataBlockManager.java
index 0bf68b7..8242f4e 100644
--- a/core/java/android/service/persistentdata/PersistentDataBlockManager.java
+++ b/core/java/android/service/persistentdata/PersistentDataBlockManager.java
@@ -90,7 +90,7 @@
*
* @param data the data to write
*/
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
public int write(byte[] data) {
try {
return sService.write(data);
@@ -102,7 +102,7 @@
/**
* Returns the data block stored on the persistent partition.
*/
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
public byte[] read() {
try {
return sService.read();
@@ -130,7 +130,7 @@
*
* Returns -1 on error.
*/
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
public long getMaximumDataBlockSize() {
try {
return sService.getMaximumDataBlockSize();
diff --git a/core/java/android/view/OnReceiveContentCallback.java b/core/java/android/view/OnReceiveContentCallback.java
deleted file mode 100644
index d74938c..0000000
--- a/core/java/android/view/OnReceiveContentCallback.java
+++ /dev/null
@@ -1,322 +0,0 @@
-/*
- * Copyright (C) 2020 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package android.view;
-
-import android.annotation.IntDef;
-import android.annotation.NonNull;
-import android.annotation.Nullable;
-import android.content.ClipData;
-import android.net.Uri;
-import android.os.Bundle;
-
-import com.android.internal.util.Preconditions;
-
-import java.lang.annotation.Retention;
-import java.lang.annotation.RetentionPolicy;
-import java.util.Objects;
-
-/**
- * Callback for apps to implement handling for insertion of content. Content may be both text and
- * non-text (plain/styled text, HTML, images, videos, audio files, etc).
- *
- * <p>This callback can be attached to different types of UI components using
- * {@link View#setOnReceiveContentCallback}.
- *
- * <p>For editable {@link android.widget.TextView} components, implementations can extend from
- * {@link android.widget.TextViewOnReceiveContentCallback} to reuse default platform behavior for
- * handling text.
- *
- * <p>Example implementation:<br>
- * <pre class="prettyprint">
- * // (1) Define the callback
- * public class MyOnReceiveContentCallback implements OnReceiveContentCallback<TextView> {
- * public static final Set<String> MIME_TYPES = Collections.unmodifiableSet(
- * Set.of("image/*", "video/*"));
- *
- * @Override
- * public boolean onReceiveContent(@NonNull TextView view, @NonNull Payload payload) {
- * // ... app-specific logic to handle the content in the payload ...
- * }
- * }
- *
- * // (2) Register the callback
- * public class MyActivity extends Activity {
- * @Override
- * public void onCreate(Bundle savedInstanceState) {
- * // ...
- *
- * EditText myInput = findViewById(R.id.my_input);
- * myInput.setOnReceiveContentCallback(
- * MyOnReceiveContentCallback.MIME_TYPES,
- * new MyOnReceiveContentCallback());
- * }
- * </pre>
- *
- * @param <T> The type of {@link View} with which this callback can be associated.
- */
-public interface OnReceiveContentCallback<T extends View> {
- /**
- * Receive the given content.
- *
- * <p>This method is only invoked for content whose MIME type matches a type specified via
- * {@link View#setOnReceiveContentCallback}.
- *
- * <p>For text, if the view has a selection, the selection should be overwritten by the clip; if
- * there's no selection, this method should insert the content at the current cursor position.
- *
- * <p>For non-text content (e.g. an image), the content may be inserted inline, or it may be
- * added as an attachment (could potentially be shown in a completely separate view).
- *
- * @param view The view where the content insertion was requested.
- * @param payload The content to insert and related metadata.
- *
- * @return Returns true if the content was handled in some way, false otherwise. Actual
- * insertion may be processed asynchronously in the background and may or may not succeed even
- * if this method returns true. For example, an app may not end up inserting an item if it
- * exceeds the app's size limit for that type of content.
- */
- boolean onReceiveContent(@NonNull T view, @NonNull Payload payload);
-
- /**
- * Holds all the relevant data for a request to {@link OnReceiveContentCallback}.
- */
- final class Payload {
-
- /**
- * Specifies the UI through which content is being inserted. Future versions of Android may
- * support additional values.
- *
- * @hide
- */
- @IntDef(prefix = {"SOURCE_"}, value = {SOURCE_APP, SOURCE_CLIPBOARD, SOURCE_INPUT_METHOD,
- SOURCE_DRAG_AND_DROP, SOURCE_AUTOFILL, SOURCE_PROCESS_TEXT})
- @Retention(RetentionPolicy.SOURCE)
- public @interface Source {}
-
- /**
- * Specifies that the operation was triggered by the app that contains the target view.
- */
- public static final int SOURCE_APP = 0;
-
- /**
- * Specifies that the operation was triggered by a paste from the clipboard (e.g. "Paste" or
- * "Paste as plain text" action in the insertion/selection menu).
- */
- public static final int SOURCE_CLIPBOARD = 1;
-
- /**
- * Specifies that the operation was triggered from the soft keyboard (also known as input
- * method editor or IME). See https://developer.android.com/guide/topics/text/image-keyboard
- * for more info.
- */
- public static final int SOURCE_INPUT_METHOD = 2;
-
- /**
- * Specifies that the operation was triggered by the drag/drop framework. See
- * https://developer.android.com/guide/topics/ui/drag-drop for more info.
- */
- public static final int SOURCE_DRAG_AND_DROP = 3;
-
- /**
- * Specifies that the operation was triggered by the autofill framework. See
- * https://developer.android.com/guide/topics/text/autofill for more info.
- */
- public static final int SOURCE_AUTOFILL = 4;
-
- /**
- * Specifies that the operation was triggered by a result from a
- * {@link android.content.Intent#ACTION_PROCESS_TEXT PROCESS_TEXT} action in the selection
- * menu.
- */
- public static final int SOURCE_PROCESS_TEXT = 5;
-
- /**
- * Returns the symbolic name of the given source.
- *
- * @hide
- */
- static String sourceToString(@Source int source) {
- switch (source) {
- case SOURCE_APP: return "SOURCE_APP";
- case SOURCE_CLIPBOARD: return "SOURCE_CLIPBOARD";
- case SOURCE_INPUT_METHOD: return "SOURCE_INPUT_METHOD";
- case SOURCE_DRAG_AND_DROP: return "SOURCE_DRAG_AND_DROP";
- case SOURCE_AUTOFILL: return "SOURCE_AUTOFILL";
- case SOURCE_PROCESS_TEXT: return "SOURCE_PROCESS_TEXT";
- }
- return String.valueOf(source);
- }
-
- /**
- * Flags to configure the insertion behavior.
- *
- * @hide
- */
- @IntDef(flag = true, prefix = {"FLAG_"}, value = {FLAG_CONVERT_TO_PLAIN_TEXT})
- @Retention(RetentionPolicy.SOURCE)
- public @interface Flags {}
-
- /**
- * Flag requesting that the content should be converted to plain text prior to inserting.
- */
- public static final int FLAG_CONVERT_TO_PLAIN_TEXT = 1 << 0;
-
- /**
- * Returns the symbolic names of the set flags or {@code "0"} if no flags are set.
- *
- * @hide
- */
- static String flagsToString(@Flags int flags) {
- if ((flags & FLAG_CONVERT_TO_PLAIN_TEXT) != 0) {
- return "FLAG_CONVERT_TO_PLAIN_TEXT";
- }
- return String.valueOf(flags);
- }
-
- @NonNull private final ClipData mClip;
- private final @Source int mSource;
- private final @Flags int mFlags;
- @Nullable private final Uri mLinkUri;
- @Nullable private final Bundle mExtras;
-
- private Payload(Builder b) {
- this.mClip = Objects.requireNonNull(b.mClip);
- this.mSource = Preconditions.checkArgumentInRange(b.mSource, 0, SOURCE_PROCESS_TEXT,
- "source");
- this.mFlags = Preconditions.checkFlagsArgument(b.mFlags, FLAG_CONVERT_TO_PLAIN_TEXT);
- this.mLinkUri = b.mLinkUri;
- this.mExtras = b.mExtras;
- }
-
- @NonNull
- @Override
- public String toString() {
- return "Payload{"
- + "clip=" + mClip.getDescription()
- + ", source=" + sourceToString(mSource)
- + ", flags=" + flagsToString(mFlags)
- + ", linkUri=" + mLinkUri
- + ", extras=" + mExtras
- + "}";
- }
-
- /**
- * The data to be inserted.
- */
- public @NonNull ClipData getClip() {
- return mClip;
- }
-
- /**
- * The source of the operation. See {@code SOURCE_} constants. Future versions of Android
- * may pass additional values.
- */
- public @Source int getSource() {
- return mSource;
- }
-
- /**
- * Optional flags that control the insertion behavior. See {@code FLAG_} constants.
- */
- public @Flags int getFlags() {
- return mFlags;
- }
-
- /**
- * Optional http/https URI for the content that may be provided by the IME. This is only
- * populated if the source is {@link #SOURCE_INPUT_METHOD} and if a non-empty
- * {@link android.view.inputmethod.InputContentInfo#getLinkUri linkUri} was passed by the
- * IME.
- */
- public @Nullable Uri getLinkUri() {
- return mLinkUri;
- }
-
- /**
- * Optional additional metadata. If the source is {@link #SOURCE_INPUT_METHOD}, this will
- * include the {@link android.view.inputmethod.InputConnection#commitContent opts} passed by
- * the IME.
- */
- public @Nullable Bundle getExtras() {
- return mExtras;
- }
-
- /**
- * Builder for {@link Payload}.
- */
- public static final class Builder {
- @NonNull private final ClipData mClip;
- private final @Source int mSource;
- private @Flags int mFlags;
- @Nullable private Uri mLinkUri;
- @Nullable private Bundle mExtras;
-
- /**
- * Creates a new builder.
- * @param clip The data to insert.
- * @param source The source of the operation. See {@code SOURCE_} constants.
- */
- public Builder(@NonNull ClipData clip, @Source int source) {
- mClip = clip;
- mSource = source;
- }
-
- /**
- * Sets flags that control content insertion behavior.
- * @param flags Optional flags to configure the insertion behavior. Use 0 for default
- * behavior. See {@code FLAG_} constants.
- * @return this builder
- */
- @NonNull
- public Builder setFlags(@Flags int flags) {
- mFlags = flags;
- return this;
- }
-
- /**
- * Sets the http/https URI for the content. See
- * {@link android.view.inputmethod.InputContentInfo#getLinkUri} for more info.
- * @param linkUri Optional http/https URI for the content.
- * @return this builder
- */
- @NonNull
- public Builder setLinkUri(@Nullable Uri linkUri) {
- mLinkUri = linkUri;
- return this;
- }
-
- /**
- * Sets additional metadata.
- * @param extras Optional bundle with additional metadata.
- * @return this builder
- */
- @NonNull
- public Builder setExtras(@Nullable Bundle extras) {
- mExtras = extras;
- return this;
- }
-
- /**
- * @return A new {@link Payload} instance with the data from this builder.
- */
- @NonNull
- public Payload build() {
- return new Payload(this);
- }
- }
- }
-}
diff --git a/core/java/android/view/OnReceiveContentListener.java b/core/java/android/view/OnReceiveContentListener.java
new file mode 100644
index 0000000..4955289
--- /dev/null
+++ b/core/java/android/view/OnReceiveContentListener.java
@@ -0,0 +1,416 @@
+/*
+ * Copyright (C) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package android.view;
+
+import android.annotation.IntDef;
+import android.annotation.NonNull;
+import android.annotation.Nullable;
+import android.content.ClipData;
+import android.net.Uri;
+import android.os.Bundle;
+import android.util.ArrayMap;
+
+import com.android.internal.util.Preconditions;
+
+import java.lang.annotation.Retention;
+import java.lang.annotation.RetentionPolicy;
+import java.util.ArrayList;
+import java.util.Map;
+import java.util.Objects;
+import java.util.function.Predicate;
+
+/**
+ * Listener for apps to implement handling for insertion of content. Content may be both text and
+ * non-text (plain/styled text, HTML, images, videos, audio files, etc).
+ *
+ * <p>This listener can be attached to different types of UI components using
+ * {@link View#setOnReceiveContentListener}.
+ *
+ * <p>Here is a sample implementation that handles content URIs and delegates the processing for
+ * text and everything else to the platform:<br>
+ * <pre class="prettyprint">
+ * // (1) Define the listener
+ * public class MyReceiver implements OnReceiveContentListener {
+ * public static final String[] MIME_TYPES = new String[] {"image/*", "video/*"};
+ *
+ * @Override
+ * public Payload onReceiveContent(TextView view, Payload payload) {
+ * Map<Boolean, Payload> split = payload.partition(item -> item.getUri() != null);
+ * if (split.get(true) != null) {
+ * ClipData clip = payload.getClip();
+ * for (int i = 0; i < clip.getItemCount(); i++) {
+ * Uri uri = clip.getItemAt(i).getUri();
+ * // ... app-specific logic to handle the URI ...
+ * }
+ * }
+ * // Return anything that we didn't handle ourselves. This preserves the default platform
+ * // behavior for text and anything else for which we are not implementing custom handling.
+ * return split.get(false);
+ * }
+ * }
+ *
+ * // (2) Register the listener
+ * public class MyActivity extends Activity {
+ * @Override
+ * public void onCreate(Bundle savedInstanceState) {
+ * // ...
+ *
+ * EditText myInput = findViewById(R.id.my_input);
+ * myInput.setOnReceiveContentListener(MyReceiver.MIME_TYPES, new MyReceiver());
+ * }
+ * </pre>
+ */
+public interface OnReceiveContentListener {
+ /**
+ * Receive the given content.
+ *
+ * <p>Implementations should handle any content items of interest and return all unhandled
+ * items to preserve the default platform behavior for content that does not have app-specific
+ * handling. For example, an implementation may provide handling for content URIs (to provide
+ * support for inserting images, etc) and delegate the processing of text to the platform to
+ * preserve the common behavior for inserting text. See the class javadoc for a sample
+ * implementation and see {@link Payload#partition} for a convenient way to split the passed-in
+ * content.
+ *
+ * <p>If implementing handling for text: if the view has a selection, the selection should
+ * be overwritten by the passed-in content; if there's no selection, the passed-in content
+ * should be inserted at the current cursor position.
+ *
+ * <p>If implementing handling for non-text content (e.g. images): the content may be
+ * inserted inline, or it may be added as an attachment (could potentially be shown in a
+ * completely separate view).
+ *
+ * @param view The view where the content insertion was requested.
+ * @param payload The content to insert and related metadata.
+ *
+ * @return The portion of the passed-in content whose processing should be delegated to
+ * the platform. Return null if all content was handled in some way. Actual insertion of
+ * the content may be processed asynchronously in the background and may or may not
+ * succeed even if this method returns null. For example, an app may end up not inserting
+ * an item if it exceeds the app's size limit for that type of content.
+ */
+ @Nullable Payload onReceiveContent(@NonNull View view, @NonNull Payload payload);
+
+ /**
+ * Holds all the relevant data for a request to {@link OnReceiveContentListener}.
+ */
+ final class Payload {
+
+ /**
+ * Specifies the UI through which content is being inserted. Future versions of Android may
+ * support additional values.
+ *
+ * @hide
+ */
+ @IntDef(prefix = {"SOURCE_"}, value = {SOURCE_APP, SOURCE_CLIPBOARD, SOURCE_INPUT_METHOD,
+ SOURCE_DRAG_AND_DROP, SOURCE_AUTOFILL, SOURCE_PROCESS_TEXT})
+ @Retention(RetentionPolicy.SOURCE)
+ public @interface Source {}
+
+ /**
+ * Specifies that the operation was triggered by the app that contains the target view.
+ */
+ public static final int SOURCE_APP = 0;
+
+ /**
+ * Specifies that the operation was triggered by a paste from the clipboard (e.g. "Paste" or
+ * "Paste as plain text" action in the insertion/selection menu).
+ */
+ public static final int SOURCE_CLIPBOARD = 1;
+
+ /**
+ * Specifies that the operation was triggered from the soft keyboard (also known as input
+ * method editor or IME). See https://developer.android.com/guide/topics/text/image-keyboard
+ * for more info.
+ */
+ public static final int SOURCE_INPUT_METHOD = 2;
+
+ /**
+ * Specifies that the operation was triggered by the drag/drop framework. See
+ * https://developer.android.com/guide/topics/ui/drag-drop for more info.
+ */
+ public static final int SOURCE_DRAG_AND_DROP = 3;
+
+ /**
+ * Specifies that the operation was triggered by the autofill framework. See
+ * https://developer.android.com/guide/topics/text/autofill for more info.
+ */
+ public static final int SOURCE_AUTOFILL = 4;
+
+ /**
+ * Specifies that the operation was triggered by a result from a
+ * {@link android.content.Intent#ACTION_PROCESS_TEXT PROCESS_TEXT} action in the selection
+ * menu.
+ */
+ public static final int SOURCE_PROCESS_TEXT = 5;
+
+ /**
+ * Returns the symbolic name of the given source.
+ *
+ * @hide
+ */
+ static String sourceToString(@Source int source) {
+ switch (source) {
+ case SOURCE_APP: return "SOURCE_APP";
+ case SOURCE_CLIPBOARD: return "SOURCE_CLIPBOARD";
+ case SOURCE_INPUT_METHOD: return "SOURCE_INPUT_METHOD";
+ case SOURCE_DRAG_AND_DROP: return "SOURCE_DRAG_AND_DROP";
+ case SOURCE_AUTOFILL: return "SOURCE_AUTOFILL";
+ case SOURCE_PROCESS_TEXT: return "SOURCE_PROCESS_TEXT";
+ }
+ return String.valueOf(source);
+ }
+
+ /**
+ * Flags to configure the insertion behavior.
+ *
+ * @hide
+ */
+ @IntDef(flag = true, prefix = {"FLAG_"}, value = {FLAG_CONVERT_TO_PLAIN_TEXT})
+ @Retention(RetentionPolicy.SOURCE)
+ public @interface Flags {}
+
+ /**
+ * Flag requesting that the content should be converted to plain text prior to inserting.
+ */
+ public static final int FLAG_CONVERT_TO_PLAIN_TEXT = 1 << 0;
+
+ /**
+ * Returns the symbolic names of the set flags or {@code "0"} if no flags are set.
+ *
+ * @hide
+ */
+ static String flagsToString(@Flags int flags) {
+ if ((flags & FLAG_CONVERT_TO_PLAIN_TEXT) != 0) {
+ return "FLAG_CONVERT_TO_PLAIN_TEXT";
+ }
+ return String.valueOf(flags);
+ }
+
+ @NonNull private final ClipData mClip;
+ private final @Source int mSource;
+ private final @Flags int mFlags;
+ @Nullable private final Uri mLinkUri;
+ @Nullable private final Bundle mExtras;
+
+ private Payload(Builder b) {
+ this.mClip = Objects.requireNonNull(b.mClip);
+ this.mSource = Preconditions.checkArgumentInRange(b.mSource, 0, SOURCE_PROCESS_TEXT,
+ "source");
+ this.mFlags = Preconditions.checkFlagsArgument(b.mFlags, FLAG_CONVERT_TO_PLAIN_TEXT);
+ this.mLinkUri = b.mLinkUri;
+ this.mExtras = b.mExtras;
+ }
+
+ @NonNull
+ @Override
+ public String toString() {
+ return "Payload{"
+ + "clip=" + mClip
+ + ", source=" + sourceToString(mSource)
+ + ", flags=" + flagsToString(mFlags)
+ + ", linkUri=" + mLinkUri
+ + ", extras=" + mExtras
+ + "}";
+ }
+
+ /**
+ * The data to be inserted.
+ */
+ public @NonNull ClipData getClip() {
+ return mClip;
+ }
+
+ /**
+ * The source of the operation. See {@code SOURCE_} constants. Future versions of Android
+ * may pass additional values.
+ */
+ public @Source int getSource() {
+ return mSource;
+ }
+
+ /**
+ * Optional flags that control the insertion behavior. See {@code FLAG_} constants.
+ */
+ public @Flags int getFlags() {
+ return mFlags;
+ }
+
+ /**
+ * Optional http/https URI for the content that may be provided by the IME. This is only
+ * populated if the source is {@link #SOURCE_INPUT_METHOD} and if a non-empty
+ * {@link android.view.inputmethod.InputContentInfo#getLinkUri linkUri} was passed by the
+ * IME.
+ */
+ public @Nullable Uri getLinkUri() {
+ return mLinkUri;
+ }
+
+ /**
+ * Optional additional metadata. If the source is {@link #SOURCE_INPUT_METHOD}, this will
+ * include the {@link android.view.inputmethod.InputConnection#commitContent opts} passed by
+ * the IME.
+ */
+ public @Nullable Bundle getExtras() {
+ return mExtras;
+ }
+
+ /**
+ * Partitions this payload based on the given predicate.
+ *
+ * <p>Similar to a
+ * {@link java.util.stream.Collectors#partitioningBy(Predicate) partitioning collector},
+ * this function classifies the content in this payload and organizes it into a map,
+ * grouping the content that matched vs didn't match the predicate.
+ *
+ * <p>Except for the {@link ClipData} items, the returned payloads will contain all the same
+ * metadata as the original payload.
+ *
+ * @param itemPredicate The predicate to test each {@link ClipData.Item} to determine which
+ * partition to place it into.
+ * @return A map containing the partitioned content. The map will contain a single entry if
+ * all items were classified into the same partition (all matched or all didn't match the
+ * predicate) or two entries (if there's at least one item that matched the predicate and at
+ * least one item that didn't match the predicate).
+ */
+ public @NonNull Map<Boolean, Payload> partition(
+ @NonNull Predicate<ClipData.Item> itemPredicate) {
+ if (mClip.getItemCount() == 1) {
+ Map<Boolean, Payload> result = new ArrayMap<>(1);
+ result.put(itemPredicate.test(mClip.getItemAt(0)), this);
+ return result;
+ }
+ ArrayList<ClipData.Item> accepted = new ArrayList<>();
+ ArrayList<ClipData.Item> remaining = new ArrayList<>();
+ for (int i = 0; i < mClip.getItemCount(); i++) {
+ ClipData.Item item = mClip.getItemAt(i);
+ if (itemPredicate.test(item)) {
+ accepted.add(item);
+ } else {
+ remaining.add(item);
+ }
+ }
+ Map<Boolean, Payload> result = new ArrayMap<>(2);
+ if (!accepted.isEmpty()) {
+ ClipData acceptedClip = new ClipData(mClip.getDescription(), accepted);
+ result.put(true, new Builder(this).setClip(acceptedClip).build());
+ }
+ if (!remaining.isEmpty()) {
+ ClipData remainingClip = new ClipData(mClip.getDescription(), remaining);
+ result.put(false, new Builder(this).setClip(remainingClip).build());
+ }
+ return result;
+ }
+
+ /**
+ * Builder for {@link Payload}.
+ */
+ public static final class Builder {
+ @NonNull private ClipData mClip;
+ private @Source int mSource;
+ private @Flags int mFlags;
+ @Nullable private Uri mLinkUri;
+ @Nullable private Bundle mExtras;
+
+ /**
+ * Creates a new builder initialized with the data from the given builder.
+ */
+ public Builder(@NonNull Payload payload) {
+ mClip = payload.mClip;
+ mSource = payload.mSource;
+ mFlags = payload.mFlags;
+ mLinkUri = payload.mLinkUri;
+ mExtras = payload.mExtras;
+ }
+
+ /**
+ * Creates a new builder.
+ * @param clip The data to insert.
+ * @param source The source of the operation. See {@code SOURCE_} constants.
+ */
+ public Builder(@NonNull ClipData clip, @Source int source) {
+ mClip = clip;
+ mSource = source;
+ }
+
+ /**
+ * Sets the data to be inserted.
+ * @param clip The data to insert.
+ * @return this builder
+ */
+ @NonNull
+ public Builder setClip(@NonNull ClipData clip) {
+ mClip = clip;
+ return this;
+ }
+
+ /**
+ * Sets the source of the operation.
+ * @param source The source of the operation. See {@code SOURCE_} constants.
+ * @return this builder
+ */
+ @NonNull
+ public Builder setSource(@Source int source) {
+ mSource = source;
+ return this;
+ }
+
+ /**
+ * Sets flags that control content insertion behavior.
+ * @param flags Optional flags to configure the insertion behavior. Use 0 for default
+ * behavior. See {@code FLAG_} constants.
+ * @return this builder
+ */
+ @NonNull
+ public Builder setFlags(@Flags int flags) {
+ mFlags = flags;
+ return this;
+ }
+
+ /**
+ * Sets the http/https URI for the content. See
+ * {@link android.view.inputmethod.InputContentInfo#getLinkUri} for more info.
+ * @param linkUri Optional http/https URI for the content.
+ * @return this builder
+ */
+ @NonNull
+ public Builder setLinkUri(@Nullable Uri linkUri) {
+ mLinkUri = linkUri;
+ return this;
+ }
+
+ /**
+ * Sets additional metadata.
+ * @param extras Optional bundle with additional metadata.
+ * @return this builder
+ */
+ @NonNull
+ public Builder setExtras(@Nullable Bundle extras) {
+ mExtras = extras;
+ return this;
+ }
+
+ /**
+ * @return A new {@link Payload} instance with the data from this builder.
+ */
+ @NonNull
+ public Payload build() {
+ return new Payload(this);
+ }
+ }
+ }
+}
diff --git a/core/java/android/view/View.java b/core/java/android/view/View.java
index cefddd8..a88ad9f 100644
--- a/core/java/android/view/View.java
+++ b/core/java/android/view/View.java
@@ -112,6 +112,7 @@
import android.view.AccessibilityIterators.WordTextSegmentIterator;
import android.view.ContextMenu.ContextMenuInfo;
import android.view.InputDevice.InputSourceClass;
+import android.view.OnReceiveContentListener.Payload;
import android.view.Window.OnContentApplyWindowInsetsListener;
import android.view.WindowInsets.Type;
import android.view.WindowInsetsAnimation.Bounds;
@@ -143,6 +144,7 @@
import android.widget.ScrollBarDrawable;
import com.android.internal.R;
+import com.android.internal.util.ArrayUtils;
import com.android.internal.util.FrameworkStatsLog;
import com.android.internal.util.Preconditions;
import com.android.internal.view.ScrollCaptureInternal;
@@ -4713,6 +4715,9 @@
* Allows the application to implement custom scroll capture support.
*/
ScrollCaptureCallback mScrollCaptureCallback;
+
+ @Nullable
+ private OnReceiveContentListener mOnReceiveContentListener;
}
@UnsupportedAppUsage
@@ -5246,8 +5251,6 @@
@Nullable
private String[] mOnReceiveContentMimeTypes;
- @Nullable
- private OnReceiveContentCallback mOnReceiveContentCallback;
/**
* Simple constructor to use when creating a view from code.
@@ -9005,72 +9008,92 @@
}
/**
- * Sets the callback to handle insertion of content into this view.
+ * Sets the listener to be {@link #onReceiveContent used} to handle insertion of
+ * content into this view.
*
- * <p>Depending on the view, this callback may be invoked for scenarios such as content
- * insertion from the IME, Autofill, etc.
+ * <p>Depending on the type of view, this listener may be invoked for different scenarios. For
+ * example, for editable TextViews, this listener will be invoked for the following scenarios:
+ * <ol>
+ * <li>Paste from the clipboard (e.g. "Paste" or "Paste as plain text" action in the
+ * insertion/selection menu)
+ * <li>Content insertion from the keyboard (from {@link InputConnection#commitContent})
+ * <li>Drag and drop (drop events from {@link #onDragEvent(DragEvent)})
+ * <li>Autofill
+ * <li>Selection replacement via {@link Intent#ACTION_PROCESS_TEXT}
+ * </ol>
*
- * <p>This callback is only invoked for content whose MIME type matches a type specified via
- * the {code mimeTypes} parameter. If the MIME type is not supported by the callback, the
- * default platform handling will be executed instead (no-op for the default {@link View}).
+ * <p>When setting a listener, clients should also declare the MIME types accepted by it.
+ * When invoked with other types of content, the listener may reject the content (defer to
+ * the default platform behavior) or execute some other fallback logic. The MIME types
+ * declared here allow different features to optionally alter their behavior. For example,
+ * the soft keyboard may choose to hide its UI for inserting GIFs for a particular input
+ * field if the MIME types set here for that field don't include "image/gif" or "image/*".
*
- * <p><em>Note: MIME type matching in the Android framework is case-sensitive, unlike formal RFC
- * MIME types. As a result, you should always write your MIME types with lower case letters, or
- * use {@link android.content.Intent#normalizeMimeType} to ensure that it is converted to lower
- * case.</em>
+ * <p>Note: MIME type matching in the Android framework is case-sensitive, unlike formal RFC
+ * MIME types. As a result, you should always write your MIME types with lowercase letters,
+ * or use {@link android.content.Intent#normalizeMimeType} to ensure that it is converted to
+ * lowercase.
*
- * @param mimeTypes The type of content for which the callback should be invoked. This may use
- * wildcards such as "text/*", "image/*", etc. This must not be null or empty if a non-null
- * callback is passed in.
- * @param callback The callback to use. This can be null to reset to the default behavior.
+ * @param mimeTypes The MIME types accepted by the given listener. These may use patterns
+ * such as "image/*", but may not start with a wildcard. This argument must
+ * not be null or empty if a non-null listener is passed in.
+ * @param listener The listener to use. This can be null to reset to the default behavior.
*/
@SuppressWarnings("rawtypes")
- public void setOnReceiveContentCallback(@Nullable String[] mimeTypes,
- @Nullable OnReceiveContentCallback callback) {
- if (callback != null) {
+ public void setOnReceiveContentListener(@Nullable String[] mimeTypes,
+ @Nullable OnReceiveContentListener listener) {
+ if (listener != null) {
Preconditions.checkArgument(mimeTypes != null && mimeTypes.length > 0,
- "When the callback is set, MIME types must also be set");
+ "When the listener is set, MIME types must also be set");
}
- mOnReceiveContentMimeTypes = mimeTypes;
- mOnReceiveContentCallback = callback;
+ if (mimeTypes != null) {
+ Preconditions.checkArgument(Arrays.stream(mimeTypes).noneMatch(t -> t.startsWith("*")),
+ "A MIME type set here must not start with *: " + Arrays.toString(mimeTypes));
+ }
+ mOnReceiveContentMimeTypes = ArrayUtils.isEmpty(mimeTypes) ? null : mimeTypes;
+ getListenerInfo().mOnReceiveContentListener = listener;
}
/**
- * Receives the given content. The default implementation invokes the callback set via
- * {@link #setOnReceiveContentCallback}. If no callback is set or if the callback does not
- * support the given content (based on the MIME type), returns false.
+ * Receives the given content. Invokes the listener configured via
+ * {@link #setOnReceiveContentListener}; if no listener is set, the default implementation is a
+ * no-op (returns the passed-in content without acting on it).
*
* @param payload The content to insert and related metadata.
*
- * @return Returns true if the content was handled in some way, false otherwise. Actual
- * insertion may be processed asynchronously in the background and may or may not succeed even
- * if this method returns true. For example, an app may not end up inserting an item if it
- * exceeds the app's size limit for that type of content.
+ * @return The portion of the passed-in content that was not accepted (may be all, some, or none
+ * of the passed-in content).
*/
- public boolean onReceiveContent(@NonNull OnReceiveContentCallback.Payload payload) {
- ClipDescription description = payload.getClip().getDescription();
- if (mOnReceiveContentCallback != null && mOnReceiveContentMimeTypes != null
- && description.hasMimeType(mOnReceiveContentMimeTypes)) {
- return mOnReceiveContentCallback.onReceiveContent(this, payload);
+ @SuppressWarnings({"rawtypes", "unchecked"})
+ public @Nullable Payload onReceiveContent(@NonNull Payload payload) {
+ final OnReceiveContentListener listener = (mListenerInfo == null) ? null
+ : getListenerInfo().mOnReceiveContentListener;
+ if (listener != null) {
+ return listener.onReceiveContent(this, payload);
}
- return false;
+ return payload;
}
/**
- * Returns the MIME types that can be handled by {@link #onReceiveContent} for this view, as
- * configured via {@link #setOnReceiveContentCallback}. By default returns null.
+ * Returns the MIME types accepted by {@link #onReceiveContent} for this view, as
+ * configured via {@link #setOnReceiveContentListener}. By default returns null.
*
- * <p>Different platform features (e.g. pasting from the clipboard, inserting stickers from the
- * keyboard, etc) may use this function to conditionally alter their behavior. For example, the
- * soft keyboard may choose to hide its UI for inserting GIFs for a particular input field if
- * the MIME types returned here for that field don't include "image/gif".
+ * <p>Different features (e.g. pasting from the clipboard, inserting stickers from the soft
+ * keyboard, etc) may optionally use this metadata to conditionally alter their behavior. For
+ * example, a soft keyboard may choose to hide its UI for inserting GIFs for a particular
+ * input field if the MIME types returned here for that field don't include "image/gif" or
+ * "image/*".
*
* <p>Note: Comparisons of MIME types should be performed using utilities such as
* {@link ClipDescription#compareMimeTypes} rather than simple string equality, in order to
- * correctly handle patterns (e.g. "text/*").
+ * correctly handle patterns such as "text/*", "image/*", etc. Note that MIME type matching
+ * in the Android framework is case-sensitive, unlike formal RFC MIME types. As a result,
+ * you should always write your MIME types with lowercase letters, or use
+ * {@link android.content.Intent#normalizeMimeType} to ensure that it is converted to
+ * lowercase.
*
- * @return The MIME types supported by {@link #onReceiveContent} for this view. The returned
- * MIME types may contain wildcards such as "text/*", "image/*", etc.
+ * @return The MIME types accepted by {@link #onReceiveContent} for this view (may
+ * include patterns such as "image/*").
*/
public @Nullable String[] getOnReceiveContentMimeTypes() {
return mOnReceiveContentMimeTypes;
diff --git a/core/java/android/view/ViewStructure.java b/core/java/android/view/ViewStructure.java
index 606e8f9..29ce231 100644
--- a/core/java/android/view/ViewStructure.java
+++ b/core/java/android/view/ViewStructure.java
@@ -97,6 +97,7 @@
public abstract void setVisibility(int visibility);
/** @hide */
+ @SuppressWarnings("HiddenAbstractMethod")
public abstract void setAssistBlocked(boolean state);
/**
@@ -431,6 +432,7 @@
public abstract void asyncCommit();
/** @hide */
+ @SuppressWarnings("HiddenAbstractMethod")
public abstract Rect getTempRect();
/**
diff --git a/core/java/android/view/Window.java b/core/java/android/view/Window.java
index 8dd4b66..9c16378 100644
--- a/core/java/android/view/Window.java
+++ b/core/java/android/view/Window.java
@@ -1387,6 +1387,7 @@
}
/** @hide */
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage
public abstract void alwaysReadCloseOnTouchAttr();
@@ -1567,6 +1568,7 @@
*
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
public abstract void clearContentView();
/**
@@ -2636,18 +2638,21 @@
* Called when the activity changes from fullscreen mode to multi-window mode and visa-versa.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
public abstract void onMultiWindowModeChanged();
/**
* Called when the activity changes to/from picture-in-picture mode.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
public abstract void onPictureInPictureModeChanged(boolean isInPictureInPictureMode);
/**
* Called when the activity just relaunched.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
public abstract void reportActivityRelaunched();
/**
diff --git a/core/java/android/view/autofill/AutofillManager.java b/core/java/android/view/autofill/AutofillManager.java
index 81db628..299c41b 100644
--- a/core/java/android/view/autofill/AutofillManager.java
+++ b/core/java/android/view/autofill/AutofillManager.java
@@ -19,7 +19,7 @@
import static android.service.autofill.FillRequest.FLAG_MANUAL_REQUEST;
import static android.service.autofill.FillRequest.FLAG_PASSWORD_INPUT_TYPE;
import static android.service.autofill.FillRequest.FLAG_VIEW_NOT_FOCUSED;
-import static android.view.OnReceiveContentCallback.Payload.SOURCE_AUTOFILL;
+import static android.view.OnReceiveContentListener.Payload.SOURCE_AUTOFILL;
import static android.view.autofill.Helper.sDebug;
import static android.view.autofill.Helper.sVerbose;
import static android.view.autofill.Helper.toList;
@@ -62,7 +62,7 @@
import android.util.SparseArray;
import android.view.Choreographer;
import android.view.KeyEvent;
-import android.view.OnReceiveContentCallback;
+import android.view.OnReceiveContentListener.Payload;
import android.view.View;
import android.view.accessibility.AccessibilityEvent;
import android.view.accessibility.AccessibilityManager;
@@ -2371,12 +2371,10 @@
reportAutofillContentFailure(id);
return;
}
- OnReceiveContentCallback.Payload payload =
- new OnReceiveContentCallback.Payload.Builder(clip, SOURCE_AUTOFILL)
- .build();
- boolean handled = view.onReceiveContent(payload);
- if (!handled) {
- Log.w(TAG, "autofillContent(): receiver returned false: id=" + id
+ Payload payload = new Payload.Builder(clip, SOURCE_AUTOFILL).build();
+ Payload result = view.onReceiveContent(payload);
+ if (result != null) {
+ Log.w(TAG, "autofillContent(): receiver could not insert content: id=" + id
+ ", view=" + view + ", clip=" + clip);
reportAutofillContentFailure(id);
return;
diff --git a/core/java/android/view/inputmethod/BaseInputConnection.java b/core/java/android/view/inputmethod/BaseInputConnection.java
index 62b1b1f..a92d1f5 100644
--- a/core/java/android/view/inputmethod/BaseInputConnection.java
+++ b/core/java/android/view/inputmethod/BaseInputConnection.java
@@ -16,7 +16,7 @@
package android.view.inputmethod;
-import static android.view.OnReceiveContentCallback.Payload.SOURCE_INPUT_METHOD;
+import static android.view.OnReceiveContentListener.Payload.SOURCE_INPUT_METHOD;
import android.annotation.CallSuper;
import android.annotation.IntRange;
@@ -40,7 +40,7 @@
import android.util.LogPrinter;
import android.view.KeyCharacterMap;
import android.view.KeyEvent;
-import android.view.OnReceiveContentCallback;
+import android.view.OnReceiveContentListener;
import android.view.View;
class ComposingText implements NoCopySpan {
@@ -928,17 +928,14 @@
/**
* Default implementation which invokes {@link View#onReceiveContent} on the target view if the
- * MIME type of the content matches one of the MIME types returned by
- * {@link View#getOnReceiveContentMimeTypes()}. If the MIME type of the content is not matched,
- * returns false without any side effects.
+ * view {@link View#getOnReceiveContentMimeTypes allows} content insertion; otherwise returns
+ * false without any side effects.
*/
public boolean commitContent(InputContentInfo inputContentInfo, int flags, Bundle opts) {
ClipDescription description = inputContentInfo.getDescription();
- final String[] viewMimeTypes = mTargetView.getOnReceiveContentMimeTypes();
- if (viewMimeTypes == null || !description.hasMimeType(viewMimeTypes)) {
+ if (mTargetView.getOnReceiveContentMimeTypes() == null) {
if (DEBUG) {
- Log.d(TAG, "Can't insert content from IME; unsupported MIME type: content="
- + description + ", viewMimeTypes=" + viewMimeTypes);
+ Log.d(TAG, "Can't insert content from IME: content=" + description);
}
return false;
}
@@ -950,13 +947,13 @@
return false;
}
}
- final ClipData clip = new ClipData(description,
+ final ClipData clip = new ClipData(inputContentInfo.getDescription(),
new ClipData.Item(inputContentInfo.getContentUri()));
- final OnReceiveContentCallback.Payload payload =
- new OnReceiveContentCallback.Payload.Builder(clip, SOURCE_INPUT_METHOD)
+ final OnReceiveContentListener.Payload payload =
+ new OnReceiveContentListener.Payload.Builder(clip, SOURCE_INPUT_METHOD)
.setLinkUri(inputContentInfo.getLinkUri())
.setExtras(opts)
.build();
- return mTargetView.onReceiveContent(payload);
+ return mTargetView.onReceiveContent(payload) == null;
}
}
diff --git a/core/java/android/webkit/CookieManager.java b/core/java/android/webkit/CookieManager.java
index f62a28e..023d9ff2 100644
--- a/core/java/android/webkit/CookieManager.java
+++ b/core/java/android/webkit/CookieManager.java
@@ -154,6 +154,7 @@
* HTTP request header
* @hide Used by Browser and by WebViewProvider implementations.
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
public abstract String getCookie(String url, boolean privateBrowsing);
@@ -230,6 +231,7 @@
* @param privateBrowsing whether to use the private browsing cookie jar
* @hide Used by Browser and WebViewProvider implementations.
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
public abstract boolean hasCookies(boolean privateBrowsing);
@@ -264,6 +266,7 @@
*
* @hide Only for use by WebViewProvider implementations
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
protected abstract boolean allowFileSchemeCookiesImpl();
@@ -299,6 +302,7 @@
*
* @hide Only for use by WebViewProvider implementations
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
protected abstract void setAcceptFileSchemeCookiesImpl(boolean accept);
}
diff --git a/core/java/android/webkit/WebHistoryItem.java b/core/java/android/webkit/WebHistoryItem.java
index b9e7042..2cb37b4 100644
--- a/core/java/android/webkit/WebHistoryItem.java
+++ b/core/java/android/webkit/WebHistoryItem.java
@@ -35,6 +35,7 @@
* @deprecated This method is now obsolete.
* @hide Since API level {@link android.os.Build.VERSION_CODES#JELLY_BEAN_MR1}
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
@Deprecated
public abstract int getId();
diff --git a/core/java/android/webkit/WebIconDatabase.java b/core/java/android/webkit/WebIconDatabase.java
index 08956e0..b705658 100644
--- a/core/java/android/webkit/WebIconDatabase.java
+++ b/core/java/android/webkit/WebIconDatabase.java
@@ -75,6 +75,7 @@
/** {@hide}
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
public abstract void bulkRequestIconForPageUrl(ContentResolver cr, String where,
IconListener listener);
diff --git a/core/java/android/webkit/WebSettings.java b/core/java/android/webkit/WebSettings.java
index 91b9390..9b753f1 100644
--- a/core/java/android/webkit/WebSettings.java
+++ b/core/java/android/webkit/WebSettings.java
@@ -268,6 +268,7 @@
* @deprecated This method is now obsolete.
* @hide Since API level {@link android.os.Build.VERSION_CODES#JELLY_BEAN_MR1}
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
@Deprecated
public abstract void setNavDump(boolean enabled);
@@ -280,6 +281,7 @@
* @deprecated This method is now obsolete.
* @hide Since API level {@link android.os.Build.VERSION_CODES#JELLY_BEAN_MR1}
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
@Deprecated
public abstract boolean getNavDump();
@@ -457,6 +459,7 @@
* @deprecated This method is now obsolete.
* @hide Since API level {@link android.os.Build.VERSION_CODES#JELLY_BEAN_MR1}
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
@Deprecated
public abstract void setUseWebViewBackgroundForOverscrollBackground(boolean view);
@@ -469,6 +472,7 @@
* @deprecated This method is now obsolete.
* @hide Since API level {@link android.os.Build.VERSION_CODES#JELLY_BEAN_MR1}
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
@Deprecated
public abstract boolean getUseWebViewBackgroundForOverscrollBackground();
@@ -534,6 +538,7 @@
* Developers should access this via {@link CookieManager#setShouldAcceptThirdPartyCookies}.
* @hide Internal API.
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
public abstract void setAcceptThirdPartyCookies(boolean accept);
@@ -542,6 +547,7 @@
* Developers should access this via {@link CookieManager#getShouldAcceptThirdPartyCookies}.
* @hide Internal API
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
public abstract boolean getAcceptThirdPartyCookies();
@@ -669,6 +675,7 @@
* @deprecated Please use {@link #setUserAgentString} instead.
* @hide Since API level {@link android.os.Build.VERSION_CODES#JELLY_BEAN_MR1}
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
@Deprecated
public abstract void setUserAgent(int ua);
@@ -687,6 +694,7 @@
* @deprecated Please use {@link #getUserAgentString} instead.
* @hide Since API level {@link android.os.Build.VERSION_CODES#JELLY_BEAN_MR1}
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
@Deprecated
public abstract int getUserAgent();
@@ -1050,6 +1058,7 @@
* {@link #setPluginState}
* @hide Since API level {@link android.os.Build.VERSION_CODES#JELLY_BEAN_MR2}
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
@Deprecated
public abstract void setPluginsEnabled(boolean flag);
@@ -1259,6 +1268,7 @@
* @deprecated This method has been replaced by {@link #getPluginState}
* @hide Since API level {@link android.os.Build.VERSION_CODES#JELLY_BEAN_MR2}
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
@Deprecated
public abstract boolean getPluginsEnabled();
@@ -1445,6 +1455,7 @@
* WebView.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
public abstract void setVideoOverlayForEmbeddedEncryptedVideoEnabled(boolean flag);
@@ -1455,6 +1466,7 @@
* @see #setVideoOverlayForEmbeddedEncryptedVideoEnabled
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@SystemApi
public abstract boolean getVideoOverlayForEmbeddedEncryptedVideoEnabled();
diff --git a/core/java/android/widget/AbsListView.java b/core/java/android/widget/AbsListView.java
index 88c0809..e740cc2 100644
--- a/core/java/android/widget/AbsListView.java
+++ b/core/java/android/widget/AbsListView.java
@@ -5348,6 +5348,7 @@
*
* @param down true if the scroll is going down, false if it is going up
*/
+ @SuppressWarnings("HiddenAbstractMethod")
abstract void fillGap(boolean down);
void hideSelector() {
@@ -5385,6 +5386,7 @@
* @param y Where the user touched
* @return The position of the first (or only) item in the row containing y
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage
abstract int findMotionRow(int y);
@@ -5432,6 +5434,7 @@
*
* @param position the position of the new selection
*/
+ @SuppressWarnings("HiddenAbstractMethod")
abstract void setSelectionInt(int position);
/**
diff --git a/core/java/android/widget/AbsSpinner.java b/core/java/android/widget/AbsSpinner.java
index daf6914..76e97ad 100644
--- a/core/java/android/widget/AbsSpinner.java
+++ b/core/java/android/widget/AbsSpinner.java
@@ -310,6 +310,7 @@
}
}
+ @SuppressWarnings("HiddenAbstractMethod")
abstract void layout(int delta, boolean animate);
@Override
diff --git a/core/java/android/widget/Editor.java b/core/java/android/widget/Editor.java
index e36243c..da14f2c 100644
--- a/core/java/android/widget/Editor.java
+++ b/core/java/android/widget/Editor.java
@@ -16,7 +16,7 @@
package android.widget;
-import static android.view.OnReceiveContentCallback.Payload.SOURCE_DRAG_AND_DROP;
+import static android.view.OnReceiveContentListener.Payload.SOURCE_DRAG_AND_DROP;
import android.R;
import android.animation.ValueAnimator;
@@ -98,7 +98,7 @@
import android.view.Menu;
import android.view.MenuItem;
import android.view.MotionEvent;
-import android.view.OnReceiveContentCallback;
+import android.view.OnReceiveContentListener;
import android.view.SubMenu;
import android.view.View;
import android.view.View.DragShadowBuilder;
@@ -207,8 +207,8 @@
}
// Default content insertion handler.
- private final TextViewOnReceiveContentCallback mDefaultOnReceiveContentCallback =
- new TextViewOnReceiveContentCallback();
+ private final TextViewOnReceiveContentListener mDefaultOnReceiveContentListener =
+ new TextViewOnReceiveContentListener();
// Each Editor manages its own undo stack.
private final UndoManager mUndoManager = new UndoManager();
@@ -589,8 +589,8 @@
}
@VisibleForTesting
- public @NonNull TextViewOnReceiveContentCallback getDefaultOnReceiveContentCallback() {
- return mDefaultOnReceiveContentCallback;
+ public @NonNull TextViewOnReceiveContentListener getDefaultOnReceiveContentListener() {
+ return mDefaultOnReceiveContentListener;
}
/**
@@ -719,7 +719,7 @@
hideCursorAndSpanControllers();
stopTextActionModeWithPreservingSelection();
- mDefaultOnReceiveContentCallback.clearInputConnectionInfo();
+ mDefaultOnReceiveContentListener.clearInputConnectionInfo();
}
private void discardTextDisplayLists() {
@@ -2869,8 +2869,8 @@
final int originalLength = mTextView.getText().length();
Selection.setSelection((Spannable) mTextView.getText(), offset);
final ClipData clip = event.getClipData();
- final OnReceiveContentCallback.Payload payload =
- new OnReceiveContentCallback.Payload.Builder(clip, SOURCE_DRAG_AND_DROP)
+ final OnReceiveContentListener.Payload payload =
+ new OnReceiveContentListener.Payload.Builder(clip, SOURCE_DRAG_AND_DROP)
.build();
mTextView.onReceiveContent(payload);
if (dragDropIntoItself) {
diff --git a/core/java/android/widget/TextView.java b/core/java/android/widget/TextView.java
index 3ac78ba..9485753 100644
--- a/core/java/android/widget/TextView.java
+++ b/core/java/android/widget/TextView.java
@@ -17,10 +17,10 @@
package android.widget;
import static android.Manifest.permission.INTERACT_ACROSS_USERS_FULL;
-import static android.view.OnReceiveContentCallback.Payload.FLAG_CONVERT_TO_PLAIN_TEXT;
-import static android.view.OnReceiveContentCallback.Payload.SOURCE_AUTOFILL;
-import static android.view.OnReceiveContentCallback.Payload.SOURCE_CLIPBOARD;
-import static android.view.OnReceiveContentCallback.Payload.SOURCE_PROCESS_TEXT;
+import static android.view.OnReceiveContentListener.Payload.FLAG_CONVERT_TO_PLAIN_TEXT;
+import static android.view.OnReceiveContentListener.Payload.SOURCE_AUTOFILL;
+import static android.view.OnReceiveContentListener.Payload.SOURCE_CLIPBOARD;
+import static android.view.OnReceiveContentListener.Payload.SOURCE_PROCESS_TEXT;
import static android.view.accessibility.AccessibilityNodeInfo.EXTRA_DATA_RENDERING_INFO_KEY;
import static android.view.accessibility.AccessibilityNodeInfo.EXTRA_DATA_TEXT_CHARACTER_LOCATION_ARG_LENGTH;
import static android.view.accessibility.AccessibilityNodeInfo.EXTRA_DATA_TEXT_CHARACTER_LOCATION_ARG_START_INDEX;
@@ -154,7 +154,7 @@
import android.view.KeyCharacterMap;
import android.view.KeyEvent;
import android.view.MotionEvent;
-import android.view.OnReceiveContentCallback;
+import android.view.OnReceiveContentListener.Payload;
import android.view.PointerIcon;
import android.view.View;
import android.view.ViewConfiguration;
@@ -2151,10 +2151,7 @@
if (result != null) {
if (isTextEditable()) {
ClipData clip = ClipData.newPlainText("", result);
- OnReceiveContentCallback.Payload payload =
- new OnReceiveContentCallback.Payload.Builder(
- clip, SOURCE_PROCESS_TEXT)
- .build();
+ Payload payload = new Payload.Builder(clip, SOURCE_PROCESS_TEXT).build();
onReceiveContent(payload);
if (mEditor != null) {
mEditor.refreshTextActionMode();
@@ -11858,8 +11855,7 @@
+ " cannot be autofilled into " + this);
return;
}
- final OnReceiveContentCallback.Payload payload =
- new OnReceiveContentCallback.Payload.Builder(clip, SOURCE_AUTOFILL).build();
+ final Payload payload = new Payload.Builder(clip, SOURCE_AUTOFILL).build();
onReceiveContent(payload);
}
@@ -12926,8 +12922,7 @@
if (clip == null) {
return;
}
- final OnReceiveContentCallback.Payload payload =
- new OnReceiveContentCallback.Payload.Builder(clip, SOURCE_CLIPBOARD)
+ final Payload payload = new Payload.Builder(clip, SOURCE_CLIPBOARD)
.setFlags(withFormatting ? 0 : FLAG_CONVERT_TO_PLAIN_TEXT)
.build();
onReceiveContent(payload);
@@ -13717,7 +13712,8 @@
public void onInputConnectionOpenedInternal(@NonNull InputConnection ic,
@NonNull EditorInfo editorInfo, @Nullable Handler handler) {
if (mEditor != null) {
- mEditor.getDefaultOnReceiveContentCallback().setInputConnectionInfo(ic, editorInfo);
+ mEditor.getDefaultOnReceiveContentListener().setInputConnectionInfo(this, ic,
+ editorInfo);
}
}
@@ -13725,68 +13721,35 @@
@Override
public void onInputConnectionClosedInternal() {
if (mEditor != null) {
- mEditor.getDefaultOnReceiveContentCallback().clearInputConnectionInfo();
+ mEditor.getDefaultOnReceiveContentListener().clearInputConnectionInfo();
}
}
/**
- * Sets the callback to handle insertion of content into this view.
+ * Receives the given content. Clients wishing to provide custom behavior should configure a
+ * listener via {@link #setOnReceiveContentListener}.
*
- * <p>This callback will be invoked for the following scenarios:
- * <ol>
- * <li>Paste from the clipboard (e.g. "Paste" or "Paste as plain text" action in the
- * insertion/selection menu)
- * <li>Content insertion from the keyboard (from {@link InputConnection#commitContent})
- * <li>Drag and drop (drop events from {@link #onDragEvent(DragEvent)})
- * <li>Autofill (from {@link #autofill(AutofillValue)})
- * <li>{@link Intent#ACTION_PROCESS_TEXT} replacement
- * </ol>
+ * <p>If a listener is set, invokes the listener. If the listener returns a non-null result,
+ * executes the default platform handling for the portion of the content returned by the
+ * listener.
*
- * <p>This callback is only invoked for content whose MIME type matches a type specified via
- * the {code mimeTypes} parameter. If the MIME type is not supported by the callback, the
- * default platform handling will be executed instead (no-op for the default {@link View}).
- *
- * <p><em>Note: MIME type matching in the Android framework is case-sensitive, unlike formal RFC
- * MIME types. As a result, you should always write your MIME types with lower case letters, or
- * use {@link android.content.Intent#normalizeMimeType} to ensure that it is converted to lower
- * case.</em>
- *
- * @param mimeTypes The type of content for which the callback should be invoked. This may use
- * wildcards such as "text/*", "image/*", etc. This must not be null or empty if a non-null
- * callback is passed in.
- * @param callback The callback to use. This can be null to reset to the default behavior.
- */
- @SuppressWarnings("rawtypes")
- @Override
- public void setOnReceiveContentCallback(
- @Nullable String[] mimeTypes,
- @Nullable OnReceiveContentCallback callback) {
- super.setOnReceiveContentCallback(mimeTypes, callback);
- }
-
- /**
- * Receives the given content. The default implementation invokes the callback set via
- * {@link #setOnReceiveContentCallback}. If no callback is set or if the callback does not
- * support the given content (based on the MIME type), executes the default platform handling
- * (e.g. coerces content to text if the source is
- * {@link OnReceiveContentCallback.Payload#SOURCE_CLIPBOARD} and this is an editable
- * {@link TextView}).
+ * <p>If no listener is set, executes the default platform behavior. For non-editable TextViews
+ * the default behavior is a no-op (returns the passed-in content without acting on it). For
+ * editable TextViews the default behavior coerces all content to text and inserts into the
+ * view.
*
* @param payload The content to insert and related metadata.
*
- * @return Returns true if the content was handled in some way, false otherwise. Actual
- * insertion may be processed asynchronously in the background and may or may not succeed even
- * if this method returns true. For example, an app may not end up inserting an item if it
- * exceeds the app's size limit for that type of content.
+ * @return The portion of the passed-in content that was not handled (may be all, some, or none
+ * of the passed-in content).
*/
@Override
- public boolean onReceiveContent(@NonNull OnReceiveContentCallback.Payload payload) {
- if (super.onReceiveContent(payload)) {
- return true;
- } else if (mEditor != null) {
- return mEditor.getDefaultOnReceiveContentCallback().onReceiveContent(this, payload);
+ public @Nullable Payload onReceiveContent(@NonNull Payload payload) {
+ Payload remaining = super.onReceiveContent(payload);
+ if (remaining != null && mEditor != null) {
+ return mEditor.getDefaultOnReceiveContentListener().onReceiveContent(this, remaining);
}
- return false;
+ return remaining;
}
private static void logCursor(String location, @Nullable String msgFormat, Object ... msgArgs) {
diff --git a/core/java/android/widget/TextViewOnReceiveContentCallback.java b/core/java/android/widget/TextViewOnReceiveContentListener.java
similarity index 70%
rename from core/java/android/widget/TextViewOnReceiveContentCallback.java
rename to core/java/android/widget/TextViewOnReceiveContentListener.java
index 7ed70ec..7ef68ec 100644
--- a/core/java/android/widget/TextViewOnReceiveContentCallback.java
+++ b/core/java/android/widget/TextViewOnReceiveContentListener.java
@@ -17,12 +17,10 @@
package android.widget;
import static android.content.ContentResolver.SCHEME_CONTENT;
-import static android.view.OnReceiveContentCallback.Payload.FLAG_CONVERT_TO_PLAIN_TEXT;
-import static android.view.OnReceiveContentCallback.Payload.SOURCE_AUTOFILL;
-import static android.view.OnReceiveContentCallback.Payload.SOURCE_DRAG_AND_DROP;
-import static android.view.OnReceiveContentCallback.Payload.SOURCE_INPUT_METHOD;
-
-import static java.util.Collections.singleton;
+import static android.view.OnReceiveContentListener.Payload.FLAG_CONVERT_TO_PLAIN_TEXT;
+import static android.view.OnReceiveContentListener.Payload.SOURCE_AUTOFILL;
+import static android.view.OnReceiveContentListener.Payload.SOURCE_DRAG_AND_DROP;
+import static android.view.OnReceiveContentListener.Payload.SOURCE_INPUT_METHOD;
import android.annotation.NonNull;
import android.annotation.Nullable;
@@ -39,11 +37,10 @@
import android.text.Selection;
import android.text.SpannableStringBuilder;
import android.text.Spanned;
-import android.util.ArraySet;
import android.util.Log;
-import android.view.OnReceiveContentCallback;
-import android.view.OnReceiveContentCallback.Payload.Flags;
-import android.view.OnReceiveContentCallback.Payload.Source;
+import android.view.OnReceiveContentListener;
+import android.view.OnReceiveContentListener.Payload.Flags;
+import android.view.OnReceiveContentListener.Payload.Source;
import android.view.View;
import android.view.inputmethod.EditorInfo;
import android.view.inputmethod.InputConnection;
@@ -54,42 +51,38 @@
import java.lang.ref.WeakReference;
import java.util.ArrayList;
import java.util.Arrays;
-import java.util.Set;
/**
- * Default implementation of {@link android.view.OnReceiveContentCallback} for editable
+ * Default implementation of {@link OnReceiveContentListener} for editable
* {@link TextView} components. This class handles insertion of text (plain text, styled text, HTML,
- * etc) but not images or other content. This class can be used as a base class for an
- * implementation of {@link android.view.OnReceiveContentCallback} for a {@link TextView}, to
- * provide consistent behavior for insertion of text.
+ * etc) but not images or other content.
+ *
+ * @hide
*/
-public class TextViewOnReceiveContentCallback implements OnReceiveContentCallback<TextView> {
+@VisibleForTesting
+public final class TextViewOnReceiveContentListener implements OnReceiveContentListener {
private static final String LOG_TAG = "OnReceiveContent";
- private static final String MIME_TYPE_ALL_TEXT = "text/*";
- private static final Set<String> MIME_TYPES_ALL_TEXT = singleton(MIME_TYPE_ALL_TEXT);
-
@Nullable private InputConnectionInfo mInputConnectionInfo;
- @Nullable private ArraySet<String> mCachedSupportedMimeTypes;
@Override
- public boolean onReceiveContent(@NonNull TextView view, @NonNull Payload payload) {
+ public @Nullable Payload onReceiveContent(@NonNull View view, @NonNull Payload payload) {
if (Log.isLoggable(LOG_TAG, Log.DEBUG)) {
Log.d(LOG_TAG, "onReceive: " + payload);
}
- ClipData clip = payload.getClip();
- @Source int source = payload.getSource();
- @Flags int flags = payload.getFlags();
+ final @Source int source = payload.getSource();
if (source == SOURCE_INPUT_METHOD) {
// InputConnection.commitContent() should only be used for non-text input which is not
// supported by the default implementation.
- return false;
+ return payload;
}
if (source == SOURCE_AUTOFILL) {
- return onReceiveForAutofill(view, clip, flags);
+ onReceiveForAutofill((TextView) view, payload);
+ return null;
}
if (source == SOURCE_DRAG_AND_DROP) {
- return onReceiveForDragAndDrop(view, clip, flags);
+ onReceiveForDragAndDrop((TextView) view, payload);
+ return null;
}
// The code here follows the original paste logic from TextView:
@@ -97,7 +90,9 @@
// In particular, multiple items within the given ClipData will trigger separate calls to
// replace/insert. This is to preserve the original behavior with respect to TextWatcher
// notifications fired from SpannableStringBuilder when replace/insert is called.
- final Editable editable = (Editable) view.getText();
+ final ClipData clip = payload.getClip();
+ final @Flags int flags = payload.getFlags();
+ final Editable editable = (Editable) ((TextView) view).getText();
final Context context = view.getContext();
boolean didFirst = false;
for (int i = 0; i < clip.getItemCount(); i++) {
@@ -118,7 +113,7 @@
}
}
}
- return didFirst;
+ return null;
}
private static void replaceSelection(@NonNull Editable editable,
@@ -131,37 +126,33 @@
editable.replace(start, end, replacement);
}
- private boolean onReceiveForAutofill(@NonNull TextView view, @NonNull ClipData clip,
- @Flags int flags) {
+ private void onReceiveForAutofill(@NonNull TextView view, @NonNull Payload payload) {
+ ClipData clip = payload.getClip();
if (isUsageOfImeCommitContentEnabled(view)) {
clip = handleNonTextViaImeCommitContent(clip);
if (clip == null) {
if (Log.isLoggable(LOG_TAG, Log.VERBOSE)) {
Log.v(LOG_TAG, "onReceive: Handled via IME");
}
- return true;
+ return;
}
}
- final CharSequence text = coerceToText(clip, view.getContext(), flags);
+ final CharSequence text = coerceToText(clip, view.getContext(), payload.getFlags());
// First autofill it...
view.setText(text);
// ...then move cursor to the end.
final Editable editable = (Editable) view.getText();
Selection.setSelection(editable, editable.length());
- return true;
}
- private static boolean onReceiveForDragAndDrop(@NonNull TextView textView,
- @NonNull ClipData clip, @Flags int flags) {
- final CharSequence text = coerceToText(clip, textView.getContext(), flags);
- if (text.length() == 0) {
- return false;
- }
- replaceSelection((Editable) textView.getText(), text);
- return true;
+ private static void onReceiveForDragAndDrop(@NonNull TextView view, @NonNull Payload payload) {
+ final CharSequence text = coerceToText(payload.getClip(), view.getContext(),
+ payload.getFlags());
+ replaceSelection((Editable) view.getText(), text);
}
- private static CharSequence coerceToText(ClipData clip, Context context, @Flags int flags) {
+ private static @NonNull CharSequence coerceToText(@NonNull ClipData clip,
+ @NonNull Context context, @Flags int flags) {
SpannableStringBuilder ssb = new SpannableStringBuilder();
for (int i = 0; i < clip.getItemCount(); i++) {
CharSequence itemText;
@@ -183,17 +174,17 @@
* augmented autofill framework (see
* <a href="/guide/topics/text/autofill-services">autofill services</a>). In order for an app to
* be able to handle these suggestions, it must normally implement the
- * {@link android.view.OnReceiveContentCallback} API. To make the adoption of this smoother for
+ * {@link android.view.OnReceiveContentListener} API. To make the adoption of this smoother for
* apps that have previously implemented the
* {@link android.view.inputmethod.InputConnection#commitContent(InputContentInfo, int, Bundle)}
- * API, we reuse that API as a fallback if {@link android.view.OnReceiveContentCallback} is not
+ * API, we reuse that API as a fallback if {@link android.view.OnReceiveContentListener} is not
* yet implemented by the app. This fallback is only enabled on Android S. This change ID
* disables the fallback, such that apps targeting Android T and above must implement the
- * {@link android.view.OnReceiveContentCallback} API in order to accept non-text suggestions.
+ * {@link android.view.OnReceiveContentListener} API in order to accept non-text suggestions.
*/
@ChangeId
@EnabledAfter(targetSdkVersion = Build.VERSION_CODES.S) // Enabled on Android T and higher
- private static final long AUTOFILL_NON_TEXT_REQUIRES_ON_RECEIVE_CONTENT_CALLBACK = 163400105L;
+ private static final long AUTOFILL_NON_TEXT_REQUIRES_ON_RECEIVE_CONTENT_LISTENER = 163400105L;
/**
* Returns true if we can use the IME {@link InputConnection#commitContent} API in order handle
@@ -206,7 +197,7 @@
}
return false;
}
- if (Compatibility.isChangeEnabled(AUTOFILL_NON_TEXT_REQUIRES_ON_RECEIVE_CONTENT_CALLBACK)) {
+ if (Compatibility.isChangeEnabled(AUTOFILL_NON_TEXT_REQUIRES_ON_RECEIVE_CONTENT_LISTENER)) {
if (Log.isLoggable(LOG_TAG, Log.VERBOSE)) {
Log.v(LOG_TAG, "Fallback to commitContent disabled (target SDK is above S)");
}
@@ -238,11 +229,16 @@
* Invoked by the platform when an {@link InputConnection} is successfully created for the view
* that owns this callback instance.
*/
- void setInputConnectionInfo(@NonNull InputConnection ic, @NonNull EditorInfo editorInfo) {
+ void setInputConnectionInfo(@NonNull TextView view, @NonNull InputConnection ic,
+ @NonNull EditorInfo editorInfo) {
if (Log.isLoggable(LOG_TAG, Log.VERBOSE)) {
Log.v(LOG_TAG, "setInputConnectionInfo: "
+ Arrays.toString(editorInfo.contentMimeTypes));
}
+ if (!isUsageOfImeCommitContentEnabled(view)) {
+ mInputConnectionInfo = null;
+ return;
+ }
String[] contentMimeTypes = editorInfo.contentMimeTypes;
if (contentMimeTypes == null || contentMimeTypes.length == 0) {
mInputConnectionInfo = null;
@@ -262,82 +258,26 @@
mInputConnectionInfo = null;
}
- // TODO(b/168253885): Use this to populate the assist structure for Autofill
-
/** @hide */
@VisibleForTesting
- public Set<String> getMimeTypes(TextView view) {
+ @Nullable
+ public String[] getEditorInfoMimeTypes(@NonNull TextView view) {
if (!isUsageOfImeCommitContentEnabled(view)) {
- return MIME_TYPES_ALL_TEXT;
+ return null;
}
- return getSupportedMimeTypesAugmentedWithImeCommitContentMimeTypes();
- }
-
- private Set<String> getSupportedMimeTypesAugmentedWithImeCommitContentMimeTypes() {
- InputConnectionInfo icInfo = mInputConnectionInfo;
+ final InputConnectionInfo icInfo = mInputConnectionInfo;
if (icInfo == null) {
if (Log.isLoggable(LOG_TAG, Log.VERBOSE)) {
- Log.v(LOG_TAG, "getSupportedMimeTypes: No usable EditorInfo/InputConnection");
+ Log.v(LOG_TAG, "getEditorInfoMimeTypes: No usable EditorInfo");
}
- return MIME_TYPES_ALL_TEXT;
+ return null;
}
- String[] editorInfoContentMimeTypes = icInfo.mEditorInfoContentMimeTypes;
+ final String[] editorInfoContentMimeTypes = icInfo.mEditorInfoContentMimeTypes;
if (Log.isLoggable(LOG_TAG, Log.VERBOSE)) {
- Log.v(LOG_TAG, "getSupportedMimeTypes: Augmenting with EditorInfo.contentMimeTypes: "
+ Log.v(LOG_TAG, "getEditorInfoMimeTypes: "
+ Arrays.toString(editorInfoContentMimeTypes));
}
- ArraySet<String> supportedMimeTypes = mCachedSupportedMimeTypes;
- if (canReuse(supportedMimeTypes, editorInfoContentMimeTypes)) {
- return supportedMimeTypes;
- }
- supportedMimeTypes = new ArraySet<>(editorInfoContentMimeTypes);
- supportedMimeTypes.add(MIME_TYPE_ALL_TEXT);
- mCachedSupportedMimeTypes = supportedMimeTypes;
- return supportedMimeTypes;
- }
-
- /**
- * We want to avoid creating a new set on every invocation of
- * {@link #getSupportedMimeTypesAugmentedWithImeCommitContentMimeTypes()}.
- * This method will check if the cached set of MIME types matches the data in the given array
- * from {@link EditorInfo} or if a new set should be created. The custom logic is needed for
- * comparing the data because the set contains the additional "text/*" MIME type.
- *
- * @param cachedMimeTypes Previously cached set of MIME types.
- * @param newEditorInfoMimeTypes MIME types from {@link EditorInfo}.
- *
- * @return Returns true if the data in the given cached set matches the data in the array.
- *
- * @hide
- */
- @VisibleForTesting
- public static boolean canReuse(@Nullable ArraySet<String> cachedMimeTypes,
- @NonNull String[] newEditorInfoMimeTypes) {
- if (cachedMimeTypes == null) {
- return false;
- }
- if (newEditorInfoMimeTypes.length != cachedMimeTypes.size()
- && newEditorInfoMimeTypes.length != (cachedMimeTypes.size() - 1)) {
- return false;
- }
- final boolean ignoreAllTextMimeType =
- newEditorInfoMimeTypes.length == (cachedMimeTypes.size() - 1);
- for (String mimeType : cachedMimeTypes) {
- if (ignoreAllTextMimeType && mimeType.equals(MIME_TYPE_ALL_TEXT)) {
- continue;
- }
- boolean present = false;
- for (String editorInfoContentMimeType : newEditorInfoMimeTypes) {
- if (editorInfoContentMimeType.equals(mimeType)) {
- present = true;
- break;
- }
- }
- if (!present) {
- return false;
- }
- }
- return true;
+ return editorInfoContentMimeTypes;
}
/**
diff --git a/core/java/com/android/internal/inputmethod/CancellationGroup.java b/core/java/com/android/internal/inputmethod/CancellationGroup.java
index a4a2208..aef9e3b 100644
--- a/core/java/com/android/internal/inputmethod/CancellationGroup.java
+++ b/core/java/com/android/internal/inputmethod/CancellationGroup.java
@@ -24,11 +24,10 @@
import java.util.ArrayList;
import java.util.concurrent.CountDownLatch;
-import java.util.concurrent.TimeUnit;
/**
- * A utility class, which works as both a factory class of completable objects and a cancellation
- * signal to cancel all the completable objects created by this object.
+ * A utility class, which works as both a factory class of a cancellation signal to cancel
+ * all the completable objects.
*/
public final class CancellationGroup {
private final Object mLock = new Object();
@@ -46,274 +45,8 @@
@GuardedBy("mLock")
private boolean mCanceled = false;
- /**
- * An inner class to consolidate completable object types supported by
- * {@link CancellationGroup}.
- */
- public static final class Completable {
-
- /**
- * Not intended to be instantiated.
- */
- private Completable() {
- }
-
- /**
- * Base class of all the completable types supported by {@link CancellationGroup}.
- */
- protected static class ValueBase {
- /**
- * {@link CountDownLatch} to be signaled to unblock {@link #await(int, TimeUnit)}.
- */
- private final CountDownLatch mLatch = new CountDownLatch(1);
-
- /**
- * {@link CancellationGroup} to which this completable object belongs.
- */
- @NonNull
- private final CancellationGroup mParentGroup;
-
- /**
- * Lock {@link Object} to guard complete operations within this class.
- */
- protected final Object mValueLock = new Object();
-
- /**
- * {@code true} after {@link #onComplete()} gets called.
- */
- @GuardedBy("mValueLock")
- protected boolean mHasValue = false;
-
- /**
- * Base constructor.
- *
- * @param parentGroup {@link CancellationGroup} to which this completable object
- * belongs.
- */
- protected ValueBase(@NonNull CancellationGroup parentGroup) {
- mParentGroup = parentGroup;
- }
-
- /**
- * @return {@link true} if {@link #onComplete()} gets called already.
- */
- @AnyThread
- public boolean hasValue() {
- synchronized (mValueLock) {
- return mHasValue;
- }
- }
-
- /**
- * Called by subclasses to signale {@link #mLatch}.
- */
- @AnyThread
- protected void onComplete() {
- mLatch.countDown();
- }
-
- /**
- * Blocks the calling thread until at least one of the following conditions is met.
- *
- * <p>
- * <ol>
- * <li>This object becomes ready to return the value.</li>
- * <li>{@link CancellationGroup#cancelAll()} gets called.</li>
- * <li>The given timeout period has passed.</li>
- * </ol>
- * </p>
- *
- * <p>The caller can distinguish the case 1 and case 2 by calling {@link #hasValue()}.
- * Note that the return value of {@link #hasValue()} can change from {@code false} to
- * {@code true} at any time, even after this methods finishes with returning
- * {@code true}.</p>
- *
- * @param timeout length of the timeout.
- * @param timeUnit unit of {@code timeout}.
- * @return {@code false} if and only if the given timeout period has passed. Otherwise
- * {@code true}.
- */
- @AnyThread
- public boolean await(int timeout, @NonNull TimeUnit timeUnit) {
- if (!mParentGroup.registerLatch(mLatch)) {
- // Already canceled when this method gets called.
- return false;
- }
- try {
- return mLatch.await(timeout, timeUnit);
- } catch (InterruptedException e) {
- return true;
- } finally {
- mParentGroup.unregisterLatch(mLatch);
- }
- }
- }
-
- /**
- * Completable object of integer primitive.
- */
- public static final class Int extends ValueBase {
- @GuardedBy("mValueLock")
- private int mValue = 0;
-
- private Int(@NonNull CancellationGroup factory) {
- super(factory);
- }
-
- /**
- * Notify when a value is set to this completable object.
- *
- * @param value value to be set.
- */
- @AnyThread
- void onComplete(int value) {
- synchronized (mValueLock) {
- if (mHasValue) {
- throw new UnsupportedOperationException(
- "onComplete() cannot be called multiple times");
- }
- mValue = value;
- mHasValue = true;
- }
- onComplete();
- }
-
- /**
- * @return value associated with this object.
- * @throws UnsupportedOperationException when called while {@link #hasValue()} returns
- * {@code false}.
- */
- @AnyThread
- public int getValue() {
- synchronized (mValueLock) {
- if (!mHasValue) {
- throw new UnsupportedOperationException(
- "getValue() is allowed only if hasValue() returns true");
- }
- return mValue;
- }
- }
- }
-
- /**
- * Base class of completable object types.
- *
- * @param <T> type associated with this completable object.
- */
- public static class Values<T> extends ValueBase {
- @GuardedBy("mValueLock")
- @Nullable
- private T mValue = null;
-
- protected Values(@NonNull CancellationGroup factory) {
- super(factory);
- }
-
- /**
- * Notify when a value is set to this completable value object.
- *
- * @param value value to be set.
- */
- @AnyThread
- void onComplete(@Nullable T value) {
- synchronized (mValueLock) {
- if (mHasValue) {
- throw new UnsupportedOperationException(
- "onComplete() cannot be called multiple times");
- }
- mValue = value;
- mHasValue = true;
- }
- onComplete();
- }
-
- /**
- * @return value associated with this object.
- * @throws UnsupportedOperationException when called while {@link #hasValue()} returns
- * {@code false}.
- */
- @AnyThread
- @Nullable
- public T getValue() {
- synchronized (mValueLock) {
- if (!mHasValue) {
- throw new UnsupportedOperationException(
- "getValue() is allowed only if hasValue() returns true");
- }
- return mValue;
- }
- }
- }
-
- /**
- * Completable object of {@link java.lang.CharSequence}.
- */
- public static final class CharSequence extends Values<java.lang.CharSequence> {
- private CharSequence(@NonNull CancellationGroup factory) {
- super(factory);
- }
- }
-
- /**
- * Completable object of {@link android.view.inputmethod.ExtractedText}.
- */
- public static final class ExtractedText
- extends Values<android.view.inputmethod.ExtractedText> {
- private ExtractedText(@NonNull CancellationGroup factory) {
- super(factory);
- }
- }
-
- /**
- * Completable object of {@link android.view.inputmethod.SurroundingText}.
- */
- public static final class SurroundingText
- extends Values<android.view.inputmethod.SurroundingText> {
- private SurroundingText(@NonNull CancellationGroup factory) {
- super(factory);
- }
- }
- }
-
- /**
- * @return an instance of {@link Completable.Int} that is associated with this
- * {@link CancellationGroup}.
- */
@AnyThread
- public Completable.Int createCompletableInt() {
- return new Completable.Int(this);
- }
-
- /**
- * @return an instance of {@link Completable.CharSequence} that is associated with this
- * {@link CancellationGroup}.
- */
- @AnyThread
- public Completable.CharSequence createCompletableCharSequence() {
- return new Completable.CharSequence(this);
- }
-
- /**
- * @return an instance of {@link Completable.ExtractedText} that is associated with this
- * {@link CancellationGroup}.
- */
- @AnyThread
- public Completable.ExtractedText createCompletableExtractedText() {
- return new Completable.ExtractedText(this);
- }
-
- /**
- * @return an instance of {@link Completable.SurroundingText} that is associated with this
- * {@link CancellationGroup}.
- */
- @AnyThread
- public Completable.SurroundingText createCompletableSurroundingText() {
- return new Completable.SurroundingText(this);
- }
-
-
- @AnyThread
- private boolean registerLatch(@NonNull CountDownLatch latch) {
+ boolean registerLatch(@NonNull CountDownLatch latch) {
synchronized (mLock) {
if (mCanceled) {
return false;
@@ -329,7 +62,7 @@
}
@AnyThread
- private void unregisterLatch(@NonNull CountDownLatch latch) {
+ void unregisterLatch(@NonNull CountDownLatch latch) {
synchronized (mLock) {
if (mLatchList != null) {
mLatchList.remove(latch);
diff --git a/core/java/com/android/internal/inputmethod/Completable.java b/core/java/com/android/internal/inputmethod/Completable.java
new file mode 100644
index 0000000..16473b9
--- /dev/null
+++ b/core/java/com/android/internal/inputmethod/Completable.java
@@ -0,0 +1,278 @@
+/*
+ * Copyright (C) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package com.android.internal.inputmethod;
+
+import android.annotation.AnyThread;
+import android.annotation.NonNull;
+import android.annotation.Nullable;
+
+import com.android.internal.annotations.GuardedBy;
+
+import java.util.concurrent.CountDownLatch;
+import java.util.concurrent.TimeUnit;
+
+/**
+ * An class to consolidate completable object types supported by
+ * {@link CancellationGroup}.
+ */
+public final class Completable {
+
+ /**
+ * Not intended to be instantiated.
+ */
+ private Completable() {
+ }
+
+ /**
+ * Base class of all the completable types supported by {@link CancellationGroup}.
+ */
+ protected static class ValueBase {
+ /**
+ * {@link CountDownLatch} to be signaled to unblock
+ * {@link #await(int, TimeUnit, CancellationGroup)}.
+ */
+ private final CountDownLatch mLatch = new CountDownLatch(1);
+
+ /**
+ * Lock {@link Object} to guard complete operations within this class.
+ */
+ protected final Object mValueLock = new Object();
+
+ /**
+ * {@code true} after {@link #onComplete()} gets called.
+ */
+ @GuardedBy("mValueLock")
+ protected boolean mHasValue = false;
+
+ /**
+ * @return {@link true} if {@link #onComplete()} gets called already.
+ */
+ @AnyThread
+ public boolean hasValue() {
+ synchronized (mValueLock) {
+ return mHasValue;
+ }
+ }
+
+ /**
+ * Called by subclasses to signale {@link #mLatch}.
+ */
+ @AnyThread
+ protected void onComplete() {
+ mLatch.countDown();
+ }
+
+ /**
+ * Blocks the calling thread until at least one of the following conditions is met.
+ *
+ * <p>
+ * <ol>
+ * <li>This object becomes ready to return the value.</li>
+ * <li>{@link CancellationGroup#cancelAll()} gets called.</li>
+ * <li>The given timeout period has passed.</li>
+ * </ol>
+ * </p>
+ *
+ * <p>The caller can distinguish the case 1 and case 2 by calling {@link #hasValue()}.
+ * Note that the return value of {@link #hasValue()} can change from {@code false} to
+ * {@code true} at any time, even after this methods finishes with returning
+ * {@code true}.</p>
+ *
+ * @param timeout length of the timeout.
+ * @param timeUnit unit of {@code timeout}.
+ * @param cancellationGroup {@link CancellationGroup} to cancel completable objects.
+ * @return {@code false} if and only if the given timeout period has passed. Otherwise
+ * {@code true}.
+ */
+ @AnyThread
+ public boolean await(int timeout, @NonNull TimeUnit timeUnit,
+ @Nullable CancellationGroup cancellationGroup) {
+ if (cancellationGroup == null) {
+ return awaitInner(timeout, timeUnit);
+ }
+
+ if (!cancellationGroup.registerLatch(mLatch)) {
+ // Already canceled when this method gets called.
+ return false;
+ }
+ try {
+ return awaitInner(timeout, timeUnit);
+ } finally {
+ cancellationGroup.unregisterLatch(mLatch);
+ }
+ }
+
+ private boolean awaitInner(int timeout, @NonNull TimeUnit timeUnit) {
+ try {
+ return mLatch.await(timeout, timeUnit);
+ } catch (InterruptedException e) {
+ return true;
+ }
+ }
+ }
+
+ /**
+ * Completable object of integer primitive.
+ */
+ public static final class Int extends ValueBase {
+ @GuardedBy("mValueLock")
+ private int mValue = 0;
+
+ /**
+ * Notify when a value is set to this completable object.
+ *
+ * @param value value to be set.
+ */
+ @AnyThread
+ void onComplete(int value) {
+ synchronized (mValueLock) {
+ if (mHasValue) {
+ throw new UnsupportedOperationException(
+ "onComplete() cannot be called multiple times");
+ }
+ mValue = value;
+ mHasValue = true;
+ }
+ onComplete();
+ }
+
+ /**
+ * @return value associated with this object.
+ * @throws UnsupportedOperationException when called while {@link #hasValue()} returns
+ * {@code false}.
+ */
+ @AnyThread
+ public int getValue() {
+ synchronized (mValueLock) {
+ if (!mHasValue) {
+ throw new UnsupportedOperationException(
+ "getValue() is allowed only if hasValue() returns true");
+ }
+ return mValue;
+ }
+ }
+ }
+
+ /**
+ * Base class of completable object types.
+ *
+ * @param <T> type associated with this completable object.
+ */
+ public static class Values<T> extends ValueBase {
+ @GuardedBy("mValueLock")
+ @Nullable
+ private T mValue = null;
+
+ /**
+ * Notify when a value is set to this completable value object.
+ *
+ * @param value value to be set.
+ */
+ @AnyThread
+ void onComplete(@Nullable T value) {
+ synchronized (mValueLock) {
+ if (mHasValue) {
+ throw new UnsupportedOperationException(
+ "onComplete() cannot be called multiple times");
+ }
+ mValue = value;
+ mHasValue = true;
+ }
+ onComplete();
+ }
+
+ /**
+ * @return value associated with this object.
+ * @throws UnsupportedOperationException when called while {@link #hasValue()} returns
+ * {@code false}.
+ */
+ @AnyThread
+ @Nullable
+ public T getValue() {
+ synchronized (mValueLock) {
+ if (!mHasValue) {
+ throw new UnsupportedOperationException(
+ "getValue() is allowed only if hasValue() returns true");
+ }
+ return mValue;
+ }
+ }
+ }
+
+ /**
+ * @return an instance of {@link Completable.Int}.
+ */
+ public static Completable.Int createInt() {
+ return new Completable.Int();
+ }
+
+ /**
+ * @return an instance of {@link Completable.Boolean}.
+ */
+ public static Completable.Boolean createBoolean() {
+ return new Completable.Boolean();
+ }
+
+ /**
+ * @return an instance of {@link Completable.CharSequence}.
+ */
+ public static Completable.CharSequence createCharSequence() {
+ return new Completable.CharSequence();
+ }
+
+ /**
+ * @return an instance of {@link Completable.ExtractedText}.
+ */
+ public static Completable.ExtractedText createExtractedText() {
+ return new Completable.ExtractedText();
+ }
+
+ /**
+ * @return an instance of {@link Completable.SurroundingText}.
+ */
+ public static Completable.SurroundingText createSurroundingText() {
+ return new Completable.SurroundingText();
+ }
+
+ /**
+ * Completable object of {@link java.lang.Boolean}.
+ */
+ public static final class Boolean extends Values<java.lang.Boolean> { }
+
+ /**
+ * Completable object of {@link java.lang.CharSequence}.
+ */
+ public static final class CharSequence extends Values<java.lang.CharSequence> { }
+
+ /**
+ * Completable object of {@link android.view.inputmethod.ExtractedText}.
+ */
+ public static final class ExtractedText
+ extends Values<android.view.inputmethod.ExtractedText> { }
+
+ /**
+ * Completable object of {@link android.view.inputmethod.SurroundingText}.
+ */
+ public static final class SurroundingText
+ extends Values<android.view.inputmethod.SurroundingText> { }
+
+ /**
+ * Completable object of {@link com.android.internal.view.InputBindResult}.
+ */
+ public static final class InputBindResult
+ extends Values<com.android.internal.view.InputBindResult> { }
+}
diff --git a/core/java/com/android/internal/inputmethod/ResultCallbacks.java b/core/java/com/android/internal/inputmethod/ResultCallbacks.java
index 5eba898..7131284 100644
--- a/core/java/com/android/internal/inputmethod/ResultCallbacks.java
+++ b/core/java/com/android/internal/inputmethod/ResultCallbacks.java
@@ -26,7 +26,7 @@
/**
* Defines a set of factory methods to create {@link android.os.IBinder}-based callbacks that are
- * associated with completable objects defined in {@link CancellationGroup.Completable}.
+ * associated with completable objects defined in {@link Completable}.
*/
public final class ResultCallbacks {
@@ -50,22 +50,22 @@
}
/**
- * Creates {@link IIntResultCallback.Stub} that is to set
- * {@link CancellationGroup.Completable.Int} when receiving the result.
+ * Creates {@link IIntResultCallback.Stub} that is to set {@link Completable.Int} when receiving
+ * the result.
*
- * @param value {@link CancellationGroup.Completable.Int} to be set when receiving the result.
+ * @param value {@link Completable.Int} to be set when receiving the result.
* @return {@link IIntResultCallback.Stub} that can be passed as a binder IPC parameter.
*/
@AnyThread
- public static IIntResultCallback.Stub of(@NonNull CancellationGroup.Completable.Int value) {
- final AtomicReference<WeakReference<CancellationGroup.Completable.Int>>
+ public static IIntResultCallback.Stub of(@NonNull Completable.Int value) {
+ final AtomicReference<WeakReference<Completable.Int>>
atomicRef = new AtomicReference<>(new WeakReference<>(value));
return new IIntResultCallback.Stub() {
@BinderThread
@Override
public void onResult(int result) {
- final CancellationGroup.Completable.Int value = unwrap(atomicRef);
+ final Completable.Int value = unwrap(atomicRef);
if (value == null) {
return;
}
@@ -76,24 +76,23 @@
/**
* Creates {@link ICharSequenceResultCallback.Stub} that is to set
- * {@link CancellationGroup.Completable.CharSequence} when receiving the result.
+ * {@link Completable.CharSequence} when receiving the result.
*
- * @param value {@link CancellationGroup.Completable.CharSequence} to be set when receiving the
- * result.
+ * @param value {@link Completable.CharSequence} to be set when receiving the result.
* @return {@link ICharSequenceResultCallback.Stub} that can be passed as a binder IPC
* parameter.
*/
@AnyThread
public static ICharSequenceResultCallback.Stub of(
- @NonNull CancellationGroup.Completable.CharSequence value) {
- final AtomicReference<WeakReference<CancellationGroup.Completable.CharSequence>> atomicRef =
+ @NonNull Completable.CharSequence value) {
+ final AtomicReference<WeakReference<Completable.CharSequence>> atomicRef =
new AtomicReference<>(new WeakReference<>(value));
return new ICharSequenceResultCallback.Stub() {
@BinderThread
@Override
public void onResult(CharSequence result) {
- final CancellationGroup.Completable.CharSequence value = unwrap(atomicRef);
+ final Completable.CharSequence value = unwrap(atomicRef);
if (value == null) {
return;
}
@@ -104,24 +103,23 @@
/**
* Creates {@link IExtractedTextResultCallback.Stub} that is to set
- * {@link CancellationGroup.Completable.ExtractedText} when receiving the result.
+ * {@link Completable.ExtractedText} when receiving the result.
*
- * @param value {@link CancellationGroup.Completable.ExtractedText} to be set when receiving the
- * result.
+ * @param value {@link Completable.ExtractedText} to be set when receiving the result.
* @return {@link IExtractedTextResultCallback.Stub} that can be passed as a binder IPC
* parameter.
*/
@AnyThread
public static IExtractedTextResultCallback.Stub of(
- @NonNull CancellationGroup.Completable.ExtractedText value) {
- final AtomicReference<WeakReference<CancellationGroup.Completable.ExtractedText>>
+ @NonNull Completable.ExtractedText value) {
+ final AtomicReference<WeakReference<Completable.ExtractedText>>
atomicRef = new AtomicReference<>(new WeakReference<>(value));
return new IExtractedTextResultCallback.Stub() {
@BinderThread
@Override
public void onResult(android.view.inputmethod.ExtractedText result) {
- final CancellationGroup.Completable.ExtractedText value = unwrap(atomicRef);
+ final Completable.ExtractedText value = unwrap(atomicRef);
if (value == null) {
return;
}
@@ -132,24 +130,23 @@
/**
* Creates {@link ISurroundingTextResultCallback.Stub} that is to set
- * {@link CancellationGroup.Completable.SurroundingText} when receiving the result.
+ * {@link Completable.SurroundingText} when receiving the result.
*
- * @param value {@link CancellationGroup.Completable.SurroundingText} to be set when receiving
- * the result.
+ * @param value {@link Completable.SurroundingText} to be set when receiving the result.
* @return {@link ISurroundingTextResultCallback.Stub} that can be passed as a binder IPC
* parameter.
*/
@AnyThread
public static ISurroundingTextResultCallback.Stub of(
- @NonNull CancellationGroup.Completable.SurroundingText value) {
- final AtomicReference<WeakReference<CancellationGroup.Completable.SurroundingText>>
+ @NonNull Completable.SurroundingText value) {
+ final AtomicReference<WeakReference<Completable.SurroundingText>>
atomicRef = new AtomicReference<>(new WeakReference<>(value));
return new ISurroundingTextResultCallback.Stub() {
@BinderThread
@Override
public void onResult(android.view.inputmethod.SurroundingText result) {
- final CancellationGroup.Completable.SurroundingText value = unwrap(atomicRef);
+ final Completable.SurroundingText value = unwrap(atomicRef);
if (value == null) {
return;
}
diff --git a/core/java/com/android/internal/os/BaseCommand.java b/core/java/com/android/internal/os/BaseCommand.java
index c85b5d7..c110b26 100644
--- a/core/java/com/android/internal/os/BaseCommand.java
+++ b/core/java/com/android/internal/os/BaseCommand.java
@@ -18,10 +18,9 @@
package com.android.internal.os;
import android.compat.annotation.UnsupportedAppUsage;
+import android.os.BasicShellCommandHandler;
import android.os.Build;
-import com.android.modules.utils.BasicShellCommandHandler;
-
import java.io.PrintStream;
public abstract class BaseCommand {
diff --git a/core/java/com/android/internal/util/LatencyTracker.java b/core/java/com/android/internal/util/LatencyTracker.java
index c7ac189..a87e8aa 100644
--- a/core/java/com/android/internal/util/LatencyTracker.java
+++ b/core/java/com/android/internal/util/LatencyTracker.java
@@ -139,6 +139,38 @@
BackgroundThread.getHandler().post(this::readSettings);
}
+ /**
+ * A helper method to translate action type to name.
+ *
+ * @param action the action type defined in AtomsProto.java
+ * @return the name of the action
+ */
+ public static String getNameOfAction(int action) {
+ // Defined in AtomsProto.java
+ switch (action) {
+ case 0:
+ return "UNKNOWN";
+ case 1:
+ return "ACTION_EXPAND_PANEL";
+ case 2:
+ return "ACTION_TOGGLE_RECENTS";
+ case 3:
+ return "ACTION_FINGERPRINT_WAKE_AND_UNLOCK";
+ case 4:
+ return "ACTION_CHECK_CREDENTIAL";
+ case 5:
+ return "ACTION_CHECK_CREDENTIAL_UNLOCKED";
+ case 6:
+ return "ACTION_TURN_ON_SCREEN";
+ case 7:
+ return "ACTION_ROTATE_SCREEN";
+ case 8:
+ return "ACTION_FACE_WAKE_AND_UNLOCK";
+ default:
+ throw new IllegalArgumentException("Invalid action");
+ }
+ }
+
private void registerSettingsObserver() {
Uri settingsUri = Settings.Global.getUriFor(Settings.Global.LATENCY_TRACKER);
mContext.getContentResolver().registerContentObserver(
diff --git a/core/java/com/android/internal/view/InputConnectionWrapper.java b/core/java/com/android/internal/view/InputConnectionWrapper.java
index e05aa83..ec4fe17 100644
--- a/core/java/com/android/internal/view/InputConnectionWrapper.java
+++ b/core/java/com/android/internal/view/InputConnectionWrapper.java
@@ -37,6 +37,7 @@
import android.view.inputmethod.SurroundingText;
import com.android.internal.inputmethod.CancellationGroup;
+import com.android.internal.inputmethod.Completable;
import com.android.internal.inputmethod.ResultCallbacks;
import java.lang.ref.WeakReference;
@@ -85,9 +86,10 @@
}
@AnyThread
- private static int getResultOrZero(@NonNull CancellationGroup.Completable.Int value,
- @NonNull String methodName) {
- final boolean timedOut = value.await(MAX_WAIT_TIME_MILLIS, TimeUnit.MILLISECONDS);
+ private static int getResultOrZero(@NonNull Completable.Int value, @NonNull String methodName,
+ @Nullable CancellationGroup cancellationGroup) {
+ final boolean timedOut =
+ value.await(MAX_WAIT_TIME_MILLIS, TimeUnit.MILLISECONDS, cancellationGroup);
if (value.hasValue()) {
return value.getValue();
}
@@ -97,9 +99,10 @@
@AnyThread
@Nullable
- private static <T> T getResultOrNull(@NonNull CancellationGroup.Completable.Values<T> value,
- @NonNull String methodName) {
- final boolean timedOut = value.await(MAX_WAIT_TIME_MILLIS, TimeUnit.MILLISECONDS);
+ private static <T> T getResultOrNull(@NonNull Completable.Values<T> value,
+ @NonNull String methodName, @Nullable CancellationGroup cancellationGroup) {
+ final boolean timedOut =
+ value.await(MAX_WAIT_TIME_MILLIS, TimeUnit.MILLISECONDS, cancellationGroup);
if (value.hasValue()) {
return value.getValue();
}
@@ -117,14 +120,13 @@
return null;
}
- final CancellationGroup.Completable.CharSequence value =
- mCancellationGroup.createCompletableCharSequence();
+ final Completable.CharSequence value = Completable.createCharSequence();
try {
mIInputContext.getTextAfterCursor(length, flags, ResultCallbacks.of(value));
} catch (RemoteException e) {
return null;
}
- return getResultOrNull(value, "getTextAfterCursor()");
+ return getResultOrNull(value, "getTextAfterCursor()", mCancellationGroup);
}
/**
@@ -137,14 +139,13 @@
return null;
}
- final CancellationGroup.Completable.CharSequence value =
- mCancellationGroup.createCompletableCharSequence();
+ final Completable.CharSequence value = Completable.createCharSequence();
try {
mIInputContext.getTextBeforeCursor(length, flags, ResultCallbacks.of(value));
} catch (RemoteException e) {
return null;
}
- return getResultOrNull(value, "getTextBeforeCursor()");
+ return getResultOrNull(value, "getTextBeforeCursor()", mCancellationGroup);
}
@AnyThread
@@ -157,14 +158,13 @@
// This method is not implemented.
return null;
}
- final CancellationGroup.Completable.CharSequence value =
- mCancellationGroup.createCompletableCharSequence();
+ final Completable.CharSequence value = Completable.createCharSequence();
try {
mIInputContext.getSelectedText(flags, ResultCallbacks.of(value));
} catch (RemoteException e) {
return null;
}
- return getResultOrNull(value, "getSelectedText()");
+ return getResultOrNull(value, "getSelectedText()", mCancellationGroup);
}
/**
@@ -190,15 +190,14 @@
// This method is not implemented.
return null;
}
- final CancellationGroup.Completable.SurroundingText value =
- mCancellationGroup.createCompletableSurroundingText();
+ final Completable.SurroundingText value = Completable.createSurroundingText();
try {
mIInputContext.getSurroundingText(beforeLength, afterLength, flags,
ResultCallbacks.of(value));
} catch (RemoteException e) {
return null;
}
- return getResultOrNull(value, "getSurroundingText()");
+ return getResultOrNull(value, "getSurroundingText()", mCancellationGroup);
}
@AnyThread
@@ -207,14 +206,13 @@
return 0;
}
- final CancellationGroup.Completable.Int value =
- mCancellationGroup.createCompletableInt();
+ final Completable.Int value = Completable.createInt();
try {
mIInputContext.getCursorCapsMode(reqModes, ResultCallbacks.of(value));
} catch (RemoteException e) {
return 0;
}
- return getResultOrZero(value, "getCursorCapsMode()");
+ return getResultOrZero(value, "getCursorCapsMode()", mCancellationGroup);
}
@AnyThread
@@ -223,14 +221,13 @@
return null;
}
- final CancellationGroup.Completable.ExtractedText value =
- mCancellationGroup.createCompletableExtractedText();
+ final Completable.ExtractedText value = Completable.createExtractedText();
try {
mIInputContext.getExtractedText(request, flags, ResultCallbacks.of(value));
} catch (RemoteException e) {
return null;
}
- return getResultOrNull(value, "getExtractedText()");
+ return getResultOrNull(value, "getExtractedText()", mCancellationGroup);
}
@AnyThread
@@ -434,14 +431,14 @@
// This method is not implemented.
return false;
}
- final CancellationGroup.Completable.Int value = mCancellationGroup.createCompletableInt();
+ final Completable.Int value = Completable.createInt();
try {
mIInputContext.requestUpdateCursorAnchorInfo(cursorUpdateMode,
ResultCallbacks.of(value));
} catch (RemoteException e) {
return false;
}
- return getResultOrZero(value, "requestUpdateCursorAnchorInfo()") != 0;
+ return getResultOrZero(value, "requestUpdateCursorAnchorInfo()", mCancellationGroup) != 0;
}
@AnyThread
@@ -475,13 +472,13 @@
inputMethodService.exposeContent(inputContentInfo, this);
}
- final CancellationGroup.Completable.Int value = mCancellationGroup.createCompletableInt();
+ final Completable.Int value = Completable.createInt();
try {
mIInputContext.commitContent(inputContentInfo, flags, opts, ResultCallbacks.of(value));
} catch (RemoteException e) {
return false;
}
- return getResultOrZero(value, "commitContent()") != 0;
+ return getResultOrZero(value, "commitContent()", mCancellationGroup) != 0;
}
@AnyThread
diff --git a/core/jni/android_content_res_ApkAssets.cpp b/core/jni/android_content_res_ApkAssets.cpp
index fbdd406..444bb66 100644
--- a/core/jni/android_content_res_ApkAssets.cpp
+++ b/core/jni/android_content_res_ApkAssets.cpp
@@ -24,6 +24,7 @@
#include "utils/misc.h"
#include "utils/Trace.h"
+#include "android_util_AssetManager_private.h"
#include "core_jni_helpers.h"
#include "jni.h"
#include "nativehelper/ScopedUtfChars.h"
@@ -347,12 +348,17 @@
return 0;
}
+ const auto buffer = asset->getIncFsBuffer(true /* aligned */);
+ const size_t length = asset->getLength();
+ if (!buffer.convert<uint8_t>().verify(length)) {
+ jniThrowException(env, kResourcesNotFound, kIOErrorMessage);
+ return 0;
+ }
+
// DynamicRefTable is only needed when looking up resource references. Opening an XML file
// directly from an ApkAssets has no notion of proper resource references.
- std::unique_ptr<ResXMLTree> xml_tree = util::make_unique<ResXMLTree>(nullptr /*dynamicRefTable*/);
- status_t err = xml_tree->setTo(asset->getBuffer(true), asset->getLength(), true);
- asset.reset();
-
+ auto xml_tree = util::make_unique<ResXMLTree>(nullptr /*dynamicRefTable*/);
+ status_t err = xml_tree->setTo(buffer.unsafe_ptr(), length, true);
if (err != NO_ERROR) {
jniThrowException(env, "java/io/FileNotFoundException", "Corrupt XML binary file");
return 0;
diff --git a/core/jni/android_media_AudioFormat.h b/core/jni/android_media_AudioFormat.h
index b1b39f3..5f2dcdf 100644
--- a/core/jni/android_media_AudioFormat.h
+++ b/core/jni/android_media_AudioFormat.h
@@ -39,6 +39,8 @@
#define ENCODING_E_AC3_JOC 18
#define ENCODING_DOLBY_MAT 19
#define ENCODING_OPUS 20
+#define ENCODING_PCM_24BIT_PACKED 21
+#define ENCODING_PCM_32BIT 22
#define ENCODING_INVALID 0
#define ENCODING_DEFAULT 1
@@ -92,6 +94,10 @@
return AUDIO_FORMAT_MAT;
case ENCODING_OPUS:
return AUDIO_FORMAT_OPUS;
+ case ENCODING_PCM_24BIT_PACKED:
+ return AUDIO_FORMAT_PCM_24_BIT_PACKED;
+ case ENCODING_PCM_32BIT:
+ return AUDIO_FORMAT_PCM_32_BIT;
default:
return AUDIO_FORMAT_INVALID;
}
@@ -107,10 +113,15 @@
case AUDIO_FORMAT_PCM_FLOAT:
return ENCODING_PCM_FLOAT;
- // map these to ENCODING_PCM_FLOAT
- case AUDIO_FORMAT_PCM_8_24_BIT:
+ // As of S, these extend integer precision formats now return more specific values
+ // than ENCODING_PCM_FLOAT.
case AUDIO_FORMAT_PCM_24_BIT_PACKED:
+ return ENCODING_PCM_24BIT_PACKED;
case AUDIO_FORMAT_PCM_32_BIT:
+ return ENCODING_PCM_32BIT;
+
+ // map this to ENCODING_PCM_FLOAT
+ case AUDIO_FORMAT_PCM_8_24_BIT:
return ENCODING_PCM_FLOAT;
case AUDIO_FORMAT_AC3:
diff --git a/core/jni/android_util_AssetManager.cpp b/core/jni/android_util_AssetManager.cpp
index efca33a..b2c69a0 100644
--- a/core/jni/android_util_AssetManager.cpp
+++ b/core/jni/android_util_AssetManager.cpp
@@ -42,6 +42,7 @@
#include "androidfw/ResourceTypes.h"
#include "androidfw/ResourceUtils.h"
+#include "android_util_AssetManager_private.h"
#include "core_jni_helpers.h"
#include "jni.h"
#include "nativehelper/JNIPlatformHelp.h"
@@ -112,19 +113,17 @@
return cookie > 0 ? static_cast<ApkAssetsCookie>(cookie - 1) : kInvalidCookie;
}
-static jint CopyValue(JNIEnv* env, ApkAssetsCookie cookie, const Res_value& value, uint32_t ref,
- uint32_t type_spec_flags, ResTable_config* config, jobject out_typed_value) {
- env->SetIntField(out_typed_value, gTypedValueOffsets.mType, value.dataType);
+static jint CopyValue(JNIEnv* env, const AssetManager2::SelectedValue& value,
+ jobject out_typed_value) {
+ env->SetIntField(out_typed_value, gTypedValueOffsets.mType, value.type);
env->SetIntField(out_typed_value, gTypedValueOffsets.mAssetCookie,
- ApkAssetsCookieToJavaCookie(cookie));
+ ApkAssetsCookieToJavaCookie(value.cookie));
env->SetIntField(out_typed_value, gTypedValueOffsets.mData, value.data);
env->SetObjectField(out_typed_value, gTypedValueOffsets.mString, nullptr);
- env->SetIntField(out_typed_value, gTypedValueOffsets.mResourceId, ref);
- env->SetIntField(out_typed_value, gTypedValueOffsets.mChangingConfigurations, type_spec_flags);
- if (config != nullptr) {
- env->SetIntField(out_typed_value, gTypedValueOffsets.mDensity, config->density);
- }
- return static_cast<jint>(ApkAssetsCookieToJavaCookie(cookie));
+ env->SetIntField(out_typed_value, gTypedValueOffsets.mResourceId, value.resid);
+ env->SetIntField(out_typed_value, gTypedValueOffsets.mChangingConfigurations, value.flags);
+ env->SetIntField(out_typed_value, gTypedValueOffsets.mDensity, value.config.density);
+ return static_cast<jint>(ApkAssetsCookieToJavaCookie(value.cookie));
}
// ----------------------------------------------------------------------------
@@ -569,15 +568,15 @@
return 0;
}
- // May be nullptr.
- std::shared_ptr<const DynamicRefTable> dynamic_ref_table =
- assetmanager->GetDynamicRefTableForCookie(cookie);
+ const incfs::map_ptr<void> buffer = asset->getIncFsBuffer(true /* aligned */);
+ const size_t length = asset->getLength();
+ if (!buffer.convert<uint8_t>().verify(length)) {
+ jniThrowException(env, kResourcesNotFound, kIOErrorMessage);
+ return 0;
+ }
- std::unique_ptr<ResXMLTree> xml_tree = util::make_unique<ResXMLTree>(
- std::move(dynamic_ref_table));
- status_t err = xml_tree->setTo(asset->getBuffer(true), asset->getLength(), true);
- asset.reset();
-
+ auto xml_tree = util::make_unique<ResXMLTree>(assetmanager->GetDynamicRefTableForCookie(cookie));
+ status_t err = xml_tree->setTo(buffer.unsafe_ptr(), length, true);
if (err != NO_ERROR) {
jniThrowException(env, "java/io/FileNotFoundException", "Corrupt XML binary file");
return 0;
@@ -606,15 +605,15 @@
ScopedLock<AssetManager2> assetmanager(AssetManagerFromLong(ptr));
ApkAssetsCookie cookie = JavaCookieToApkAssetsCookie(jcookie);
- // May be nullptr.
- std::shared_ptr<const DynamicRefTable> dynamic_ref_table =
- assetmanager->GetDynamicRefTableForCookie(cookie);
+ const incfs::map_ptr<void> buffer = asset->getIncFsBuffer(true /* aligned */);
+ const size_t length = asset->getLength();
+ if (!buffer.convert<uint8_t>().verify(length)) {
+ jniThrowException(env, kResourcesNotFound, kIOErrorMessage);
+ return 0;
+ }
- std::unique_ptr<ResXMLTree> xml_tree = util::make_unique<ResXMLTree>(
- std::move(dynamic_ref_table));
- status_t err = xml_tree->setTo(asset->getBuffer(true), asset->getLength(), true);
- asset.reset();
-
+ auto xml_tree = util::make_unique<ResXMLTree>(assetmanager->GetDynamicRefTableForCookie(cookie));
+ status_t err = xml_tree->setTo(buffer.unsafe_ptr(), length, true);
if (err != NO_ERROR) {
jniThrowException(env, "java/io/FileNotFoundException", "Corrupt XML binary file");
return 0;
@@ -626,67 +625,62 @@
jshort density, jobject typed_value,
jboolean resolve_references) {
ScopedLock<AssetManager2> assetmanager(AssetManagerFromLong(ptr));
- Res_value value;
- ResTable_config selected_config;
- uint32_t flags;
- ApkAssetsCookie cookie =
- assetmanager->GetResource(static_cast<uint32_t>(resid), false /*may_be_bag*/,
- static_cast<uint16_t>(density), &value, &selected_config, &flags);
- if (cookie == kInvalidCookie) {
+ auto value = assetmanager->GetResource(static_cast<uint32_t>(resid), false /*may_be_bag*/,
+ static_cast<uint16_t>(density));
+ if (!value.has_value()) {
+ ThrowIfIOError(env, value);
return ApkAssetsCookieToJavaCookie(kInvalidCookie);
}
- uint32_t ref = static_cast<uint32_t>(resid);
if (resolve_references) {
- cookie = assetmanager->ResolveReference(cookie, &value, &selected_config, &flags, &ref);
- if (cookie == kInvalidCookie) {
+ auto result = assetmanager->ResolveReference(value.value());
+ if (!result.has_value()) {
+ ThrowIfIOError(env, result);
return ApkAssetsCookieToJavaCookie(kInvalidCookie);
}
}
- return CopyValue(env, cookie, value, ref, flags, &selected_config, typed_value);
+ return CopyValue(env, *value, typed_value);
}
static jint NativeGetResourceBagValue(JNIEnv* env, jclass /*clazz*/, jlong ptr, jint resid,
jint bag_entry_id, jobject typed_value) {
ScopedLock<AssetManager2> assetmanager(AssetManagerFromLong(ptr));
- const ResolvedBag* bag = assetmanager->GetBag(static_cast<uint32_t>(resid));
- if (bag == nullptr) {
+ auto bag = assetmanager->GetBag(static_cast<uint32_t>(resid));
+ if (!bag.has_value()) {
+ ThrowIfIOError(env, bag);
return ApkAssetsCookieToJavaCookie(kInvalidCookie);
}
- uint32_t type_spec_flags = bag->type_spec_flags;
- ApkAssetsCookie cookie = kInvalidCookie;
- const Res_value* bag_value = nullptr;
- for (const ResolvedBag::Entry& entry : bag) {
- if (entry.key == static_cast<uint32_t>(bag_entry_id)) {
- cookie = entry.cookie;
- bag_value = &entry.value;
+ // The legacy would find the last entry with the target bag entry id
+ using reverse_bag_iterator = std::reverse_iterator<const ResolvedBag::Entry*>;
+ const auto rbegin = reverse_bag_iterator(end(*bag));
+ const auto rend = reverse_bag_iterator(begin(*bag));
+ auto entry = std::find_if(rbegin, rend, [bag_entry_id](auto&& e) {
+ return e.key == static_cast<uint32_t>(bag_entry_id);
+ });
- // Keep searching (the old implementation did that).
- }
- }
-
- if (cookie == kInvalidCookie) {
+ if (entry == rend) {
return ApkAssetsCookieToJavaCookie(kInvalidCookie);
}
- Res_value value = *bag_value;
- uint32_t ref = static_cast<uint32_t>(resid);
- ResTable_config selected_config;
- cookie = assetmanager->ResolveReference(cookie, &value, &selected_config, &type_spec_flags, &ref);
- if (cookie == kInvalidCookie) {
+ AssetManager2::SelectedValue attr_value(*bag, *entry);
+ auto result = assetmanager->ResolveReference(attr_value);
+ if (!result.has_value()) {
+ ThrowIfIOError(env, result);
return ApkAssetsCookieToJavaCookie(kInvalidCookie);
}
- return CopyValue(env, cookie, value, ref, type_spec_flags, nullptr, typed_value);
+ return CopyValue(env, attr_value, typed_value);
}
static jintArray NativeGetStyleAttributes(JNIEnv* env, jclass /*clazz*/, jlong ptr, jint resid) {
ScopedLock<AssetManager2> assetmanager(AssetManagerFromLong(ptr));
- const ResolvedBag* bag = assetmanager->GetBag(static_cast<uint32_t>(resid));
- if (bag == nullptr) {
+ auto bag_result = assetmanager->GetBag(static_cast<uint32_t>(resid));
+ if (!bag_result.has_value()) {
+ ThrowIfIOError(env, bag_result);
return nullptr;
}
+ const ResolvedBag* bag = *bag_result;
jintArray array = env->NewIntArray(bag->entry_count);
if (env->ExceptionCheck()) {
return nullptr;
@@ -702,42 +696,47 @@
static jobjectArray NativeGetResourceStringArray(JNIEnv* env, jclass /*clazz*/, jlong ptr,
jint resid) {
ScopedLock<AssetManager2> assetmanager(AssetManagerFromLong(ptr));
- const ResolvedBag* bag = assetmanager->GetBag(static_cast<uint32_t>(resid));
- if (bag == nullptr) {
+ auto bag_result = assetmanager->GetBag(static_cast<uint32_t>(resid));
+ if (!bag_result.has_value()) {
+ ThrowIfIOError(env, bag_result);
return nullptr;
}
+ const ResolvedBag* bag = *bag_result;
jobjectArray array = env->NewObjectArray(bag->entry_count, g_stringClass, nullptr);
if (array == nullptr) {
return nullptr;
}
for (uint32_t i = 0; i < bag->entry_count; i++) {
- const ResolvedBag::Entry& entry = bag->entries[i];
-
// Resolve any references to their final value.
- Res_value value = entry.value;
- ResTable_config selected_config;
- uint32_t flags;
- uint32_t ref;
- ApkAssetsCookie cookie =
- assetmanager->ResolveReference(entry.cookie, &value, &selected_config, &flags, &ref);
- if (cookie == kInvalidCookie) {
+ AssetManager2::SelectedValue attr_value(bag, bag->entries[i]);
+ auto result = assetmanager->ResolveReference(attr_value);
+ if (!result.has_value()) {
+ ThrowIfIOError(env, result);
return nullptr;
}
- if (value.dataType == Res_value::TYPE_STRING) {
- const ApkAssets* apk_assets = assetmanager->GetApkAssets()[cookie];
+ if (attr_value.type == Res_value::TYPE_STRING) {
+ const ApkAssets* apk_assets = assetmanager->GetApkAssets()[attr_value.cookie];
const ResStringPool* pool = apk_assets->GetLoadedArsc()->GetStringPool();
jstring java_string = nullptr;
- size_t str_len;
- const char* str_utf8 = pool->string8At(value.data, &str_len);
- if (str_utf8 != nullptr) {
- java_string = env->NewStringUTF(str_utf8);
+ auto str_utf8 = pool->string8At(attr_value.data);
+ if (UNLIKELY(ThrowIfIOError(env, str_utf8))) {
+ return nullptr;
+ }
+
+ if (str_utf8.has_value()) {
+ java_string = env->NewStringUTF(str_utf8->data());
} else {
- const char16_t* str_utf16 = pool->stringAt(value.data, &str_len);
- java_string = env->NewString(reinterpret_cast<const jchar*>(str_utf16), str_len);
+ auto str_utf16 = pool->stringAt(attr_value.data);
+ if (!str_utf16.has_value()) {
+ ThrowIfIOError(env, str_utf16);
+ return nullptr;
+ }
+ java_string = env->NewString(reinterpret_cast<const jchar*>(str_utf16->data()),
+ str_utf16->size());
}
// Check for errors creating the strings (if malformed or no memory).
@@ -758,11 +757,13 @@
static jintArray NativeGetResourceStringArrayInfo(JNIEnv* env, jclass /*clazz*/, jlong ptr,
jint resid) {
ScopedLock<AssetManager2> assetmanager(AssetManagerFromLong(ptr));
- const ResolvedBag* bag = assetmanager->GetBag(static_cast<uint32_t>(resid));
- if (bag == nullptr) {
+ auto bag_result = assetmanager->GetBag(static_cast<uint32_t>(resid));
+ if (!bag_result.has_value()) {
+ ThrowIfIOError(env, bag_result);
return nullptr;
}
+ const ResolvedBag* bag = *bag_result;
jintArray array = env->NewIntArray(bag->entry_count * 2);
if (array == nullptr) {
return nullptr;
@@ -774,24 +775,20 @@
}
for (size_t i = 0; i < bag->entry_count; i++) {
- const ResolvedBag::Entry& entry = bag->entries[i];
- Res_value value = entry.value;
- ResTable_config selected_config;
- uint32_t flags;
- uint32_t ref;
- ApkAssetsCookie cookie =
- assetmanager->ResolveReference(entry.cookie, &value, &selected_config, &flags, &ref);
- if (cookie == kInvalidCookie) {
+ AssetManager2::SelectedValue attr_value(bag, bag->entries[i]);
+ auto result = assetmanager->ResolveReference(attr_value);
+ if (!result.has_value()) {
env->ReleasePrimitiveArrayCritical(array, buffer, JNI_ABORT);
+ ThrowIfIOError(env, result);
return nullptr;
}
jint string_index = -1;
- if (value.dataType == Res_value::TYPE_STRING) {
- string_index = static_cast<jint>(value.data);
+ if (attr_value.type == Res_value::TYPE_STRING) {
+ string_index = static_cast<jint>(attr_value.data);
}
- buffer[i * 2] = ApkAssetsCookieToJavaCookie(cookie);
+ buffer[i * 2] = ApkAssetsCookieToJavaCookie(attr_value.cookie);
buffer[(i * 2) + 1] = string_index;
}
env->ReleasePrimitiveArrayCritical(array, buffer, 0);
@@ -800,11 +797,13 @@
static jintArray NativeGetResourceIntArray(JNIEnv* env, jclass /*clazz*/, jlong ptr, jint resid) {
ScopedLock<AssetManager2> assetmanager(AssetManagerFromLong(ptr));
- const ResolvedBag* bag = assetmanager->GetBag(static_cast<uint32_t>(resid));
- if (bag == nullptr) {
+ auto bag_result = assetmanager->GetBag(static_cast<uint32_t>(resid));
+ if (!bag_result.has_value()) {
+ ThrowIfIOError(env, bag_result);
return nullptr;
}
+ const ResolvedBag* bag = *bag_result;
jintArray array = env->NewIntArray(bag->entry_count);
if (array == nullptr) {
return nullptr;
@@ -816,40 +815,39 @@
}
for (size_t i = 0; i < bag->entry_count; i++) {
- const ResolvedBag::Entry& entry = bag->entries[i];
- Res_value value = entry.value;
- ResTable_config selected_config;
- uint32_t flags;
- uint32_t ref;
- ApkAssetsCookie cookie =
- assetmanager->ResolveReference(entry.cookie, &value, &selected_config, &flags, &ref);
- if (cookie == kInvalidCookie) {
- env->ReleasePrimitiveArrayCritical(array, buffer, JNI_ABORT);
+ AssetManager2::SelectedValue attr_value(bag, bag->entries[i]);
+ auto result = assetmanager->ResolveReference(attr_value);
+ if (!result.has_value()) {
+ env->ReleasePrimitiveArrayCritical(array, buffer, 0);
+ ThrowIfIOError(env, result);
return nullptr;
}
- if (value.dataType >= Res_value::TYPE_FIRST_INT && value.dataType <= Res_value::TYPE_LAST_INT) {
- buffer[i] = static_cast<jint>(value.data);
+ if (attr_value.type >= Res_value::TYPE_FIRST_INT &&
+ attr_value.type <= Res_value::TYPE_LAST_INT) {
+ buffer[i] = static_cast<jint>(attr_value.data);
}
}
env->ReleasePrimitiveArrayCritical(array, buffer, 0);
return array;
}
-static jint NativeGetResourceArraySize(JNIEnv* /*env*/, jclass /*clazz*/, jlong ptr, jint resid) {
- ScopedLock<AssetManager2> assetmanager(AssetManagerFromLong(ptr));
- const ResolvedBag* bag = assetmanager->GetBag(static_cast<uint32_t>(resid));
- if (bag == nullptr) {
- return -1;
- }
- return static_cast<jint>(bag->entry_count);
+static jint NativeGetResourceArraySize(JNIEnv* env, jclass /*clazz*/, jlong ptr, jint resid) {
+ ScopedLock<AssetManager2> assetmanager(AssetManagerFromLong(ptr));
+ auto bag = assetmanager->GetBag(static_cast<uint32_t>(resid));
+ if (!bag.has_value()) {
+ ThrowIfIOError(env, bag);
+ return -1;
+ }
+ return static_cast<jint>((*bag)->entry_count);
}
static jint NativeGetResourceArray(JNIEnv* env, jclass /*clazz*/, jlong ptr, jint resid,
jintArray out_data) {
ScopedLock<AssetManager2> assetmanager(AssetManagerFromLong(ptr));
- const ResolvedBag* bag = assetmanager->GetBag(static_cast<uint32_t>(resid));
- if (bag == nullptr) {
+ auto bag_result = assetmanager->GetBag(static_cast<uint32_t>(resid));
+ if (!bag_result.has_value()) {
+ ThrowIfIOError(env, bag_result);
return -1;
}
@@ -858,8 +856,10 @@
return -1;
}
+ const ResolvedBag* bag = *bag_result;
if (static_cast<jsize>(bag->entry_count) > out_data_length * STYLE_NUM_ENTRIES) {
- jniThrowException(env, "java/lang/IllegalArgumentException", "Input array is not large enough");
+ jniThrowException(env, "java/lang/IllegalArgumentException",
+ "Input array is not large enough");
return -1;
}
@@ -870,31 +870,26 @@
jint* cursor = buffer;
for (size_t i = 0; i < bag->entry_count; i++) {
- const ResolvedBag::Entry& entry = bag->entries[i];
- Res_value value = entry.value;
- ResTable_config selected_config;
- selected_config.density = 0;
- uint32_t flags = bag->type_spec_flags;
- uint32_t ref = 0;
- ApkAssetsCookie cookie =
- assetmanager->ResolveReference(entry.cookie, &value, &selected_config, &flags, &ref);
- if (cookie == kInvalidCookie) {
+ AssetManager2::SelectedValue attr_value(bag, bag->entries[i]);
+ auto result = assetmanager->ResolveReference(attr_value);
+ if (!result.has_value()) {
env->ReleasePrimitiveArrayCritical(out_data, buffer, JNI_ABORT);
+ ThrowIfIOError(env, bag_result);
return -1;
}
// Deal with the special @null value -- it turns back to TYPE_NULL.
- if (value.dataType == Res_value::TYPE_REFERENCE && value.data == 0) {
- value.dataType = Res_value::TYPE_NULL;
- value.data = Res_value::DATA_NULL_UNDEFINED;
+ if (attr_value.type == Res_value::TYPE_REFERENCE && attr_value.data == 0) {
+ attr_value.type = Res_value::TYPE_NULL;
+ attr_value.data = Res_value::DATA_NULL_UNDEFINED;
}
- cursor[STYLE_TYPE] = static_cast<jint>(value.dataType);
- cursor[STYLE_DATA] = static_cast<jint>(value.data);
- cursor[STYLE_ASSET_COOKIE] = ApkAssetsCookieToJavaCookie(cookie);
- cursor[STYLE_RESOURCE_ID] = static_cast<jint>(ref);
- cursor[STYLE_CHANGING_CONFIGURATIONS] = static_cast<jint>(flags);
- cursor[STYLE_DENSITY] = static_cast<jint>(selected_config.density);
+ cursor[STYLE_TYPE] = static_cast<jint>(attr_value.type);
+ cursor[STYLE_DATA] = static_cast<jint>(attr_value.data);
+ cursor[STYLE_ASSET_COOKIE] = ApkAssetsCookieToJavaCookie(attr_value.cookie);
+ cursor[STYLE_RESOURCE_ID] = static_cast<jint>(attr_value.resid);
+ cursor[STYLE_CHANGING_CONFIGURATIONS] = static_cast<jint>(attr_value.flags);
+ cursor[STYLE_DENSITY] = static_cast<jint>(attr_value.config.density);
cursor += STYLE_NUM_ENTRIES;
}
env->ReleasePrimitiveArrayCritical(out_data, buffer, 0);
@@ -922,60 +917,71 @@
CHECK(package_utf8.c_str() != nullptr);
package = package_utf8.c_str();
}
+
ScopedLock<AssetManager2> assetmanager(AssetManagerFromLong(ptr));
- return static_cast<jint>(assetmanager->GetResourceId(name_utf8.c_str(), type, package));
+ auto resid = assetmanager->GetResourceId(name_utf8.c_str(), type, package);
+ if (!resid.has_value()) {
+ ThrowIfIOError(env, resid);
+ return 0;
+ }
+
+ return static_cast<jint>(*resid);
}
static jstring NativeGetResourceName(JNIEnv* env, jclass /*clazz*/, jlong ptr, jint resid) {
ScopedLock<AssetManager2> assetmanager(AssetManagerFromLong(ptr));
- AssetManager2::ResourceName name;
- if (!assetmanager->GetResourceName(static_cast<uint32_t>(resid), &name)) {
+ auto name = assetmanager->GetResourceName(static_cast<uint32_t>(resid));
+ if (!name.has_value()) {
+ ThrowIfIOError(env, name);
return nullptr;
}
- std::string result = ToFormattedResourceString(&name);
+ const std::string result = ToFormattedResourceString(name.value());
return env->NewStringUTF(result.c_str());
}
static jstring NativeGetResourcePackageName(JNIEnv* env, jclass /*clazz*/, jlong ptr, jint resid) {
ScopedLock<AssetManager2> assetmanager(AssetManagerFromLong(ptr));
- AssetManager2::ResourceName name;
- if (!assetmanager->GetResourceName(static_cast<uint32_t>(resid), &name)) {
+ auto name = assetmanager->GetResourceName(static_cast<uint32_t>(resid));
+ if (!name.has_value()) {
+ ThrowIfIOError(env, name);
return nullptr;
}
- if (name.package != nullptr) {
- return env->NewStringUTF(name.package);
+ if (name->package != nullptr) {
+ return env->NewStringUTF(name->package);
}
return nullptr;
}
static jstring NativeGetResourceTypeName(JNIEnv* env, jclass /*clazz*/, jlong ptr, jint resid) {
ScopedLock<AssetManager2> assetmanager(AssetManagerFromLong(ptr));
- AssetManager2::ResourceName name;
- if (!assetmanager->GetResourceName(static_cast<uint32_t>(resid), &name)) {
+ auto name = assetmanager->GetResourceName(static_cast<uint32_t>(resid));
+ if (!name.has_value()) {
+ ThrowIfIOError(env, name);
return nullptr;
}
- if (name.type != nullptr) {
- return env->NewStringUTF(name.type);
- } else if (name.type16 != nullptr) {
- return env->NewString(reinterpret_cast<const jchar*>(name.type16), name.type_len);
+ if (name->type != nullptr) {
+ return env->NewStringUTF(name->type);
+ } else if (name->type16 != nullptr) {
+ return env->NewString(reinterpret_cast<const jchar*>(name->type16), name->type_len);
}
return nullptr;
}
static jstring NativeGetResourceEntryName(JNIEnv* env, jclass /*clazz*/, jlong ptr, jint resid) {
ScopedLock<AssetManager2> assetmanager(AssetManagerFromLong(ptr));
- AssetManager2::ResourceName name;
- if (!assetmanager->GetResourceName(static_cast<uint32_t>(resid), &name)) {
+ auto name = assetmanager->GetResourceName(static_cast<uint32_t>(resid));
+ if (!name.has_value()) {
+ ThrowIfIOError(env, name);
return nullptr;
}
- if (name.entry != nullptr) {
- return env->NewStringUTF(name.entry);
- } else if (name.entry16 != nullptr) {
- return env->NewString(reinterpret_cast<const jchar*>(name.entry16), name.entry_len);
+ if (name->entry != nullptr) {
+ return env->NewStringUTF(name->entry);
+ } else if (name->entry16 != nullptr) {
+ return env->NewString(reinterpret_cast<const jchar*>(name->entry16), name->entry_len);
}
return nullptr;
}
@@ -1039,17 +1045,21 @@
static jobjectArray NativeGetSizeConfigurations(JNIEnv* env, jclass /*clazz*/, jlong ptr) {
ScopedLock<AssetManager2> assetmanager(AssetManagerFromLong(ptr));
- std::set<ResTable_config> configurations =
- assetmanager->GetResourceConfigurations(true /*exclude_system*/, false /*exclude_mipmap*/);
+ auto configurations = assetmanager->GetResourceConfigurations(true /*exclude_system*/,
+ false /*exclude_mipmap*/);
+ if (!configurations.has_value()) {
+ ThrowIfIOError(env, configurations);
+ return nullptr;
+ }
jobjectArray array =
- env->NewObjectArray(configurations.size(), gConfigurationOffsets.classObject, nullptr);
+ env->NewObjectArray(configurations->size(), gConfigurationOffsets.classObject, nullptr);
if (array == nullptr) {
return nullptr;
}
size_t idx = 0;
- for (const ResTable_config& configuration : configurations) {
+ for (const ResTable_config& configuration : *configurations) {
jobject java_configuration = ConstructConfigurationObject(env, configuration);
if (java_configuration == nullptr) {
return nullptr;
@@ -1072,13 +1082,10 @@
(void) assetmanager;
// Load default style from attribute, if specified...
- uint32_t def_style_flags = 0u;
if (def_style_attr != 0) {
- Res_value value;
- if (theme->GetAttribute(def_style_attr, &value, &def_style_flags) != kInvalidCookie) {
- if (value.dataType == Res_value::TYPE_REFERENCE) {
- def_style_resid = value.data;
- }
+ auto value = theme->GetAttribute(def_style_attr);
+ if (value.has_value() && value->type == Res_value::TYPE_REFERENCE) {
+ def_style_resid = value->data;
}
}
@@ -1119,10 +1126,11 @@
return;
}
- ApplyStyle(theme, xml_parser, static_cast<uint32_t>(def_style_attr),
- static_cast<uint32_t>(def_style_resid), reinterpret_cast<uint32_t*>(attrs), attrs_len,
- out_values, out_indices);
+ auto result = ApplyStyle(theme, xml_parser, static_cast<uint32_t>(def_style_attr),
+ static_cast<uint32_t>(def_style_resid),
+ reinterpret_cast<uint32_t*>(attrs), attrs_len, out_values, out_indices);
env->ReleasePrimitiveArrayCritical(java_attrs, attrs, JNI_ABORT);
+ ThrowIfIOError(env, result);
}
static jboolean NativeResolveAttrs(JNIEnv* env, jclass /*clazz*/, jlong ptr, jlong theme_ptr,
@@ -1183,11 +1191,12 @@
Theme* theme = reinterpret_cast<Theme*>(theme_ptr);
CHECK(theme->GetAssetManager() == &(*assetmanager));
(void) assetmanager;
-
- bool result = ResolveAttrs(
- theme, static_cast<uint32_t>(def_style_attr), static_cast<uint32_t>(def_style_resid),
- reinterpret_cast<uint32_t*>(values), values_len, reinterpret_cast<uint32_t*>(attrs),
- attrs_len, reinterpret_cast<uint32_t*>(out_values), reinterpret_cast<uint32_t*>(out_indices));
+ auto result =
+ ResolveAttrs(theme, static_cast<uint32_t>(def_style_attr),
+ static_cast<uint32_t>(def_style_resid), reinterpret_cast<uint32_t*>(values),
+ values_len, reinterpret_cast<uint32_t*>(attrs), attrs_len,
+ reinterpret_cast<uint32_t*>(out_values),
+ reinterpret_cast<uint32_t*>(out_indices));
if (out_indices != nullptr) {
env->ReleasePrimitiveArrayCritical(out_java_indices, out_indices, 0);
}
@@ -1196,8 +1205,13 @@
if (values != nullptr) {
env->ReleasePrimitiveArrayCritical(java_values, values, JNI_ABORT);
}
+
env->ReleasePrimitiveArrayCritical(java_attrs, attrs, JNI_ABORT);
- return result ? JNI_TRUE : JNI_FALSE;
+ if (!result.has_value()) {
+ ThrowIfIOError(env, result);
+ return JNI_FALSE;
+ }
+ return JNI_TRUE;
}
static jboolean NativeRetrieveAttributes(JNIEnv* env, jclass /*clazz*/, jlong ptr,
@@ -1238,18 +1252,22 @@
ScopedLock<AssetManager2> assetmanager(AssetManagerFromLong(ptr));
ResXMLParser* xml_parser = reinterpret_cast<ResXMLParser*>(xml_parser_ptr);
-
- bool result = RetrieveAttributes(assetmanager.get(), xml_parser,
- reinterpret_cast<uint32_t*>(attrs), attrs_len,
- reinterpret_cast<uint32_t*>(out_values),
- reinterpret_cast<uint32_t*>(out_indices));
+ auto result =
+ RetrieveAttributes(assetmanager.get(), xml_parser, reinterpret_cast<uint32_t*>(attrs),
+ attrs_len, reinterpret_cast<uint32_t*>(out_values),
+ reinterpret_cast<uint32_t*>(out_indices));
if (out_indices != nullptr) {
env->ReleasePrimitiveArrayCritical(out_java_indices, out_indices, 0);
}
+
env->ReleasePrimitiveArrayCritical(out_java_values, out_values, 0);
env->ReleasePrimitiveArrayCritical(java_attrs, attrs, JNI_ABORT);
- return result ? JNI_TRUE : JNI_FALSE;
+ if (!result.has_value()) {
+ ThrowIfIOError(env, result);
+ return JNI_FALSE;
+ }
+ return JNI_TRUE;
}
static jlong NativeThemeCreate(JNIEnv* /*env*/, jclass /*clazz*/, jlong ptr) {
@@ -1268,7 +1286,9 @@
Theme* theme = reinterpret_cast<Theme*>(theme_ptr);
CHECK(theme->GetAssetManager() == &(*assetmanager));
(void) assetmanager;
- theme->ApplyStyle(static_cast<uint32_t>(resid), force);
+
+ auto result = theme->ApplyStyle(static_cast<uint32_t>(resid), force);
+ ThrowIfIOError(env, result);
// TODO(adamlesinski): Consider surfacing exception when result is failure.
// CTS currently expects no exceptions from this method.
@@ -1281,19 +1301,22 @@
Theme* dst_theme = reinterpret_cast<Theme*>(dst_theme_ptr);
Theme* src_theme = reinterpret_cast<Theme*>(src_theme_ptr);
+ ScopedLock<AssetManager2> src_assetmanager(AssetManagerFromLong(src_asset_manager_ptr));
+ CHECK(src_theme->GetAssetManager() == &(*src_assetmanager));
+ (void) src_assetmanager;
+
if (dst_asset_manager_ptr != src_asset_manager_ptr) {
ScopedLock<AssetManager2> dst_assetmanager(AssetManagerFromLong(dst_asset_manager_ptr));
CHECK(dst_theme->GetAssetManager() == &(*dst_assetmanager));
(void) dst_assetmanager;
- ScopedLock <AssetManager2> src_assetmanager(AssetManagerFromLong(src_asset_manager_ptr));
- CHECK(src_theme->GetAssetManager() == &(*src_assetmanager));
- (void) src_assetmanager;
-
- dst_theme->SetTo(*src_theme);
- } else {
- dst_theme->SetTo(*src_theme);
+ auto result = dst_theme->SetTo(*src_theme);
+ ThrowIfIOError(env, result);
+ return;
}
+
+ auto result = dst_theme->SetTo(*src_theme);
+ ThrowIfIOError(env, result);
}
static void NativeThemeClear(JNIEnv* /*env*/, jclass /*clazz*/, jlong theme_ptr) {
@@ -1308,23 +1331,21 @@
CHECK(theme->GetAssetManager() == &(*assetmanager));
(void) assetmanager;
- Res_value value;
- uint32_t flags;
- ApkAssetsCookie cookie = theme->GetAttribute(static_cast<uint32_t>(resid), &value, &flags);
- if (cookie == kInvalidCookie) {
+ auto value = theme->GetAttribute(static_cast<uint32_t>(resid));
+ if (!value.has_value()) {
return ApkAssetsCookieToJavaCookie(kInvalidCookie);
}
- uint32_t ref = 0u;
- if (resolve_references) {
- ResTable_config selected_config;
- cookie =
- theme->GetAssetManager()->ResolveReference(cookie, &value, &selected_config, &flags, &ref);
- if (cookie == kInvalidCookie) {
- return ApkAssetsCookieToJavaCookie(kInvalidCookie);
- }
+ if (!resolve_references) {
+ return CopyValue(env, *value, typed_value);
}
- return CopyValue(env, cookie, value, ref, flags, nullptr, typed_value);
+
+ auto result = theme->GetAssetManager()->ResolveReference(*value);
+ if (!result.has_value()) {
+ ThrowIfIOError(env, result);
+ return ApkAssetsCookieToJavaCookie(kInvalidCookie);
+ }
+ return CopyValue(env, *value, typed_value);
}
static void NativeThemeDump(JNIEnv* /*env*/, jclass /*clazz*/, jlong ptr, jlong theme_ptr,
diff --git a/core/jni/android_util_AssetManager_private.h b/core/jni/android_util_AssetManager_private.h
new file mode 100644
index 0000000..153509b9
--- /dev/null
+++ b/core/jni/android_util_AssetManager_private.h
@@ -0,0 +1,54 @@
+/*
+ * Copyright (C) 2008 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef ANDROID_UTIL_ASSETMANAGER_PRIVATE_H
+#define ANDROID_UTIL_ASSETMANAGER_PRIVATE_H
+
+#include <optional>
+
+#include <androidfw/Errors.h>
+#include <android-base/expected.h>
+
+#include "core_jni_helpers.h"
+#include "jni.h"
+#include "nativehelper/JNIHelp.h"
+
+namespace android {
+
+constexpr const char* kResourcesNotFound = "android/content/res/Resources$NotFoundException";
+constexpr const static char* kIOErrorMessage = "failed to read resources.arsc data";
+
+template <typename T, typename E>
+static bool ThrowIfIOError(JNIEnv* env, const base::expected<T, E>& result) {
+ if constexpr (std::is_same<NullOrIOError, E>::value) {
+ if (IsIOError(result)) {
+ jniThrowException(env, kResourcesNotFound, kIOErrorMessage);
+ return true;
+ }
+ return false;
+ } else {
+ if (!result.has_value()) {
+ static_assert(std::is_same<IOError, E>::value, "Unknown result error type");
+ jniThrowException(env, kResourcesNotFound, kIOErrorMessage);
+ return true;
+ }
+ return false;
+ }
+}
+
+} // namespace android
+
+#endif //ANDROID_UTIL_ASSETMANAGER_PRIVATE_H
diff --git a/core/jni/android_util_StringBlock.cpp b/core/jni/android_util_StringBlock.cpp
index 760f9e3..45f6b72 100644
--- a/core/jni/android_util_StringBlock.cpp
+++ b/core/jni/android_util_StringBlock.cpp
@@ -17,6 +17,7 @@
#define LOG_TAG "StringBlock"
+#include "android_util_AssetManager_private.h"
#include "jni.h"
#include <nativehelper/JNIHelp.h>
#include <utils/misc.h>
@@ -31,10 +32,8 @@
// ----------------------------------------------------------------------------
-static jlong android_content_StringBlock_nativeCreate(JNIEnv* env, jobject clazz,
- jbyteArray bArray,
- jint off, jint len)
-{
+static jlong android_content_StringBlock_nativeCreate(JNIEnv* env, jobject clazz, jbyteArray bArray,
+ jint off, jint len) {
if (bArray == NULL) {
jniThrowNullPointerException(env, NULL);
return 0;
@@ -59,9 +58,7 @@
return reinterpret_cast<jlong>(osb);
}
-static jint android_content_StringBlock_nativeGetSize(JNIEnv* env, jobject clazz,
- jlong token)
-{
+static jint android_content_StringBlock_nativeGetSize(JNIEnv* env, jobject clazz, jlong token) {
ResStringPool* osb = reinterpret_cast<ResStringPool*>(token);
if (osb == NULL) {
jniThrowNullPointerException(env, NULL);
@@ -71,76 +68,84 @@
return osb->size();
}
-static jstring android_content_StringBlock_nativeGetString(JNIEnv* env, jobject clazz,
- jlong token, jint idx)
-{
+static jstring android_content_StringBlock_nativeGetString(JNIEnv* env, jobject clazz, jlong token,
+ jint idx) {
ResStringPool* osb = reinterpret_cast<ResStringPool*>(token);
if (osb == NULL) {
jniThrowNullPointerException(env, NULL);
return 0;
}
- size_t len;
- const char* str8 = osb->string8At(idx, &len);
- if (str8 != NULL) {
- return env->NewStringUTF(str8);
+ auto str8 = osb->string8At(idx);
+ if (UNLIKELY(ThrowIfIOError(env, str8))) {
+ return 0;
+ } else if (str8.has_value()) {
+ return env->NewStringUTF(str8->data());
}
- const char16_t* str = osb->stringAt(idx, &len);
- if (str == NULL) {
+ auto str = osb->stringAt(idx);
+ if (UNLIKELY(ThrowIfIOError(env, str))) {
+ return 0;
+ } else if (UNLIKELY(!str.has_value())) {
jniThrowException(env, "java/lang/IndexOutOfBoundsException", NULL);
return 0;
}
- return env->NewString((const jchar*)str, len);
+ return env->NewString((const jchar*)str->data(), str->size());
}
-static jintArray android_content_StringBlock_nativeGetStyle(JNIEnv* env, jobject clazz,
- jlong token, jint idx)
-{
+static jintArray android_content_StringBlock_nativeGetStyle(JNIEnv* env, jobject clazz, jlong token,
+ jint idx) {
ResStringPool* osb = reinterpret_cast<ResStringPool*>(token);
if (osb == NULL) {
jniThrowNullPointerException(env, NULL);
return NULL;
}
- const ResStringPool_span* spans = osb->styleAt(idx);
- if (spans == NULL) {
+ auto spans = osb->styleAt(idx);
+ if (!spans.has_value()) {
+ ThrowIfIOError(env, spans);
return NULL;
}
- const ResStringPool_span* pos = spans;
- int num = 0;
- while (pos->name.index != ResStringPool_span::END) {
- num++;
- pos++;
- }
+ jintArray array;
+ {
+ int num = 0;
+ auto pos = *spans;
+ while (true) {
+ if (UNLIKELY(!pos)) {
+ jniThrowException(env, kResourcesNotFound, kIOErrorMessage);
+ return NULL;
+ }
+ if (pos->name.index == ResStringPool_span::END) {
+ break;
+ }
+ num++;
+ pos++;
+ }
- if (num == 0) {
- return NULL;
- }
+ if (num == 0) {
+ return NULL;
+ }
- jintArray array = env->NewIntArray((num*sizeof(ResStringPool_span))/sizeof(jint));
- if (array == NULL) { // NewIntArray already threw OutOfMemoryError.
- return NULL;
+ array = env->NewIntArray((num * sizeof(ResStringPool_span)) / sizeof(jint));
+ if (array == NULL) { // NewIntArray already threw OutOfMemoryError.
+ return NULL;
+ }
}
-
- num = 0;
- static const int numInts = sizeof(ResStringPool_span)/sizeof(jint);
- while (spans->name.index != ResStringPool_span::END) {
- env->SetIntArrayRegion(array,
- num*numInts, numInts,
- (jint*)spans);
- spans++;
- num++;
+ {
+ int num = 0;
+ static const int numInts = sizeof(ResStringPool_span) / sizeof(jint);
+ while ((*spans)->name.index != ResStringPool_span::END) {
+ env->SetIntArrayRegion(array, num * numInts, numInts, (jint*)spans->unsafe_ptr());
+ (*spans)++;
+ num++;
+ }
}
-
return array;
}
-static void android_content_StringBlock_nativeDestroy(JNIEnv* env, jobject clazz,
- jlong token)
-{
+static void android_content_StringBlock_nativeDestroy(JNIEnv* env, jobject clazz, jlong token) {
ResStringPool* osb = reinterpret_cast<ResStringPool*>(token);
if (osb == NULL) {
jniThrowNullPointerException(env, NULL);
diff --git a/core/res/AndroidManifest.xml b/core/res/AndroidManifest.xml
index fbc5287..ea667277 100644
--- a/core/res/AndroidManifest.xml
+++ b/core/res/AndroidManifest.xml
@@ -668,6 +668,10 @@
<!-- For tether entitlement recheck-->
<protected-broadcast
android:name="com.android.server.connectivity.tethering.PROVISIONING_RECHECK_ALARM" />
+
+ <!-- Made protected in S (was added in R) -->
+ <protected-broadcast android:name="com.android.internal.intent.action.BUGREPORT_REQUESTED" />
+
<!-- ====================================================================== -->
<!-- RUNTIME PERMISSIONS -->
<!-- ====================================================================== -->
diff --git a/core/res/res/values-mcc311-mnc180-as/strings.xml b/core/res/res/values-mcc311-mnc180-as/strings.xml
new file mode 100644
index 0000000..daa090c
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc180-as/strings.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+/* //device/apps/common/assets/res/any/strings.xml
+**
+** Copyright 2006, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+** http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="mmcc_imsi_unknown_in_hlr" msgid="604133804161351810">"ছিমখন প্ৰ\'ভিজন কৰা হোৱা নাই MM#2"</string>
+ <string name="mmcc_illegal_ms" msgid="4073997279280371621">"ছিমৰ অনুমতি নাই MM#3"</string>
+ <string name="mmcc_illegal_me" msgid="4936539345546223576">"ফ\'নৰ অনুমতি নাই MM#6"</string>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc180-az/strings.xml b/core/res/res/values-mcc311-mnc180-az/strings.xml
new file mode 100644
index 0000000..7b8bd89
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc180-az/strings.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+/* //device/apps/common/assets/res/any/strings.xml
+**
+** Copyright 2006, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+** http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="mmcc_imsi_unknown_in_hlr" msgid="604133804161351810">"SIM MM#2 təmin etmir"</string>
+ <string name="mmcc_illegal_ms" msgid="4073997279280371621">"SIM MM#3 dəstəkləmir"</string>
+ <string name="mmcc_illegal_me" msgid="4936539345546223576">"MM#6 telefonu dəstəklənmir"</string>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc180-b+sr+Latn/strings.xml b/core/res/res/values-mcc311-mnc180-b+sr+Latn/strings.xml
new file mode 100644
index 0000000..6cbc6ee
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc180-b+sr+Latn/strings.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+/* //device/apps/common/assets/res/any/strings.xml
+**
+** Copyright 2006, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+** http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="mmcc_imsi_unknown_in_hlr" msgid="604133804161351810">"SIM kartica nije podešena MM#2"</string>
+ <string name="mmcc_illegal_ms" msgid="4073997279280371621">"SIM kartica nije dozvoljena MM#3"</string>
+ <string name="mmcc_illegal_me" msgid="4936539345546223576">"Telefon nije dozvoljen MM#6"</string>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc180-be/strings.xml b/core/res/res/values-mcc311-mnc180-be/strings.xml
new file mode 100644
index 0000000..363bcde5
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc180-be/strings.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+/* //device/apps/common/assets/res/any/strings.xml
+**
+** Copyright 2006, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+** http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="mmcc_imsi_unknown_in_hlr" msgid="604133804161351810">"SIM-карты няма MM#2"</string>
+ <string name="mmcc_illegal_ms" msgid="4073997279280371621">"SIM-карта не дапускаецца MM#3"</string>
+ <string name="mmcc_illegal_me" msgid="4936539345546223576">"Тэлефон не дапускаецца MM#6"</string>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc180-bn/strings.xml b/core/res/res/values-mcc311-mnc180-bn/strings.xml
new file mode 100644
index 0000000..23b9fdf
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc180-bn/strings.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+/* //device/apps/common/assets/res/any/strings.xml
+**
+** Copyright 2006, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+** http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="mmcc_imsi_unknown_in_hlr" msgid="604133804161351810">"সিমের জন্য প্রস্তুত নয় MM#2"</string>
+ <string name="mmcc_illegal_ms" msgid="4073997279280371621">"সিমের অনুমতি নেই MM#3"</string>
+ <string name="mmcc_illegal_me" msgid="4936539345546223576">"ফোন অনুমোদিত নয় MM#6"</string>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc180-bs/strings.xml b/core/res/res/values-mcc311-mnc180-bs/strings.xml
new file mode 100644
index 0000000..c73e0dc
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc180-bs/strings.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+/* //device/apps/common/assets/res/any/strings.xml
+**
+** Copyright 2006, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+** http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="mmcc_imsi_unknown_in_hlr" msgid="604133804161351810">"SIM kartica nije dodijeljena MM#2"</string>
+ <string name="mmcc_illegal_ms" msgid="4073997279280371621">"SIM kartica nije dozvoljena MM#3"</string>
+ <string name="mmcc_illegal_me" msgid="4936539345546223576">"Telefon nije dozvoljen MM#6"</string>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc180-en-rAU/strings.xml b/core/res/res/values-mcc311-mnc180-en-rAU/strings.xml
new file mode 100644
index 0000000..bd58d57
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc180-en-rAU/strings.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+/* //device/apps/common/assets/res/any/strings.xml
+**
+** Copyright 2006, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+** http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="mmcc_imsi_unknown_in_hlr" msgid="604133804161351810">"SIM not provisioned MM#2"</string>
+ <string name="mmcc_illegal_ms" msgid="4073997279280371621">"SIM not allowed MM#3"</string>
+ <string name="mmcc_illegal_me" msgid="4936539345546223576">"Phone not allowed MM#6"</string>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc180-en-rCA/strings.xml b/core/res/res/values-mcc311-mnc180-en-rCA/strings.xml
new file mode 100644
index 0000000..bd58d57
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc180-en-rCA/strings.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+/* //device/apps/common/assets/res/any/strings.xml
+**
+** Copyright 2006, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+** http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="mmcc_imsi_unknown_in_hlr" msgid="604133804161351810">"SIM not provisioned MM#2"</string>
+ <string name="mmcc_illegal_ms" msgid="4073997279280371621">"SIM not allowed MM#3"</string>
+ <string name="mmcc_illegal_me" msgid="4936539345546223576">"Phone not allowed MM#6"</string>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc180-en-rXC/strings.xml b/core/res/res/values-mcc311-mnc180-en-rXC/strings.xml
new file mode 100644
index 0000000..a9fdf61
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc180-en-rXC/strings.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+/* //device/apps/common/assets/res/any/strings.xml
+**
+** Copyright 2006, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+** http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="mmcc_imsi_unknown_in_hlr" msgid="604133804161351810">"SIM not provisioned MM#2"</string>
+ <string name="mmcc_illegal_ms" msgid="4073997279280371621">"SIM not allowed MM#3"</string>
+ <string name="mmcc_illegal_me" msgid="4936539345546223576">"Phone not allowed MM#6"</string>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc180-gu/strings.xml b/core/res/res/values-mcc311-mnc180-gu/strings.xml
new file mode 100644
index 0000000..26f735b
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc180-gu/strings.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+/* //device/apps/common/assets/res/any/strings.xml
+**
+** Copyright 2006, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+** http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="mmcc_imsi_unknown_in_hlr" msgid="604133804161351810">"SIMને MM#2ની જોગવાઈ નથી"</string>
+ <string name="mmcc_illegal_ms" msgid="4073997279280371621">"SIMને MM#3 કરવાની મંજૂરી નથી"</string>
+ <string name="mmcc_illegal_me" msgid="4936539345546223576">"MM#6 ફોનની મંજૂરી નથી"</string>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc180-kk/strings.xml b/core/res/res/values-mcc311-mnc180-kk/strings.xml
new file mode 100644
index 0000000..18c492d
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc180-kk/strings.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+/* //device/apps/common/assets/res/any/strings.xml
+**
+** Copyright 2006, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+** http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="mmcc_imsi_unknown_in_hlr" msgid="604133804161351810">"SIM картасы қарастырылмаған MM#2"</string>
+ <string name="mmcc_illegal_ms" msgid="4073997279280371621">"SIM картасына рұқсат етілмеген MM#3"</string>
+ <string name="mmcc_illegal_me" msgid="4936539345546223576">"Телефон пайдалануға болмайды MM#6"</string>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc180-kn/strings.xml b/core/res/res/values-mcc311-mnc180-kn/strings.xml
new file mode 100644
index 0000000..6de3655
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc180-kn/strings.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+/* //device/apps/common/assets/res/any/strings.xml
+**
+** Copyright 2006, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+** http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="mmcc_imsi_unknown_in_hlr" msgid="604133804161351810">"MM#2 ಗೆ ಸಿಮ್ ಸಿದ್ಧವಾಗಿಲ್ಲ"</string>
+ <string name="mmcc_illegal_ms" msgid="4073997279280371621">"ಸಿಮ್ MM#3 ಅನ್ನು ಅನುಮತಿಸುವುದಿಲ್ಲ"</string>
+ <string name="mmcc_illegal_me" msgid="4936539345546223576">"ಫೋನ್ MM#6 ಅನ್ನು ಅನುಮತಿಸುವುದಿಲ್ಲ"</string>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc180-or/strings.xml b/core/res/res/values-mcc311-mnc180-or/strings.xml
new file mode 100644
index 0000000..8b2ffd9
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc180-or/strings.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+/* //device/apps/common/assets/res/any/strings.xml
+**
+** Copyright 2006, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+** http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="mmcc_imsi_unknown_in_hlr" msgid="604133804161351810">"SIM କାର୍ଡ ପ୍ରସ୍ତୁତ କରାଯାଇନାହିଁ MM#2"</string>
+ <string name="mmcc_illegal_ms" msgid="4073997279280371621">"SIM କାର୍ଡର ଅନୁମତି ନାହିଁ MM#3"</string>
+ <string name="mmcc_illegal_me" msgid="4936539345546223576">"ଫୋନ୍ର ଅନୁମତି ନାହିଁ MM#6"</string>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc180-pa/strings.xml b/core/res/res/values-mcc311-mnc180-pa/strings.xml
new file mode 100644
index 0000000..b716a2e1
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc180-pa/strings.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+/* //device/apps/common/assets/res/any/strings.xml
+**
+** Copyright 2006, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+** http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="mmcc_imsi_unknown_in_hlr" msgid="604133804161351810">"ਸਿਮ ਦੀ ਵਿਵਸਥਾ ਨਹੀਂ ਹੈ MM#2"</string>
+ <string name="mmcc_illegal_ms" msgid="4073997279280371621">"ਸਿਮ ਦੀ ਇਜਾਜ਼ਤ ਨਹੀਂ ਹੈ MM#3"</string>
+ <string name="mmcc_illegal_me" msgid="4936539345546223576">"ਫ਼ੋਨ ਨੂੰ ਇਜਾਜ਼ਤ ਨਹੀਂ ਹੈ MM#6"</string>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc180-pt-rBR/strings.xml b/core/res/res/values-mcc311-mnc180-pt-rBR/strings.xml
new file mode 100644
index 0000000..6788df9
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc180-pt-rBR/strings.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+/* //device/apps/common/assets/res/any/strings.xml
+**
+** Copyright 2006, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+** http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="mmcc_imsi_unknown_in_hlr" msgid="604133804161351810">"Chip não aprovisionado MM#2"</string>
+ <string name="mmcc_illegal_ms" msgid="4073997279280371621">"Chip não permitido MM#3"</string>
+ <string name="mmcc_illegal_me" msgid="4936539345546223576">"Smartphone não permitido MM#6"</string>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc180-sq/strings.xml b/core/res/res/values-mcc311-mnc180-sq/strings.xml
new file mode 100644
index 0000000..eeec051
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc180-sq/strings.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+/* //device/apps/common/assets/res/any/strings.xml
+**
+** Copyright 2006, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+** http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="mmcc_imsi_unknown_in_hlr" msgid="604133804161351810">"Karta SIM nuk është dhënë MM#2"</string>
+ <string name="mmcc_illegal_ms" msgid="4073997279280371621">"Karta SIM nuk lejohet MM#3"</string>
+ <string name="mmcc_illegal_me" msgid="4936539345546223576">"Telefoni nuk lejohet MM#6"</string>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc180-ta/strings.xml b/core/res/res/values-mcc311-mnc180-ta/strings.xml
new file mode 100644
index 0000000..5a9f97b
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc180-ta/strings.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+/* //device/apps/common/assets/res/any/strings.xml
+**
+** Copyright 2006, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+** http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="mmcc_imsi_unknown_in_hlr" msgid="604133804161351810">"சிம் அமைக்கப்படவில்லை MM#2"</string>
+ <string name="mmcc_illegal_ms" msgid="4073997279280371621">"சிம் அனுமதிக்கப்படவில்லை MM#3"</string>
+ <string name="mmcc_illegal_me" msgid="4936539345546223576">"ஃபோன் அனுமதிக்கப்படவில்லை MM#6"</string>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc180-te/strings.xml b/core/res/res/values-mcc311-mnc180-te/strings.xml
new file mode 100644
index 0000000..7368dae3
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc180-te/strings.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+/* //device/apps/common/assets/res/any/strings.xml
+**
+** Copyright 2006, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+** http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="mmcc_imsi_unknown_in_hlr" msgid="604133804161351810">"SIM MM#2ని సక్రియం చేయలేదు"</string>
+ <string name="mmcc_illegal_ms" msgid="4073997279280371621">"SIM MM#3ని అనుమతించలేదు"</string>
+ <string name="mmcc_illegal_me" msgid="4936539345546223576">"ఫోన్ అనుమతించబడదు MM#6"</string>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc180-ur/strings.xml b/core/res/res/values-mcc311-mnc180-ur/strings.xml
new file mode 100644
index 0000000..57695ec
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc180-ur/strings.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+/* //device/apps/common/assets/res/any/strings.xml
+**
+** Copyright 2006, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+** http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="mmcc_imsi_unknown_in_hlr" msgid="604133804161351810">"SIM فراہم کردہ نہیں ہے MM#2"</string>
+ <string name="mmcc_illegal_ms" msgid="4073997279280371621">"SIM کی اجازت نہیں ہے MM#3"</string>
+ <string name="mmcc_illegal_me" msgid="4936539345546223576">"فون کی اجازت نہیں ہے MM#6"</string>
+</resources>
diff --git a/core/res/res/values-mcc311-mnc180-uz/strings.xml b/core/res/res/values-mcc311-mnc180-uz/strings.xml
new file mode 100644
index 0000000..bb1f84a
--- /dev/null
+++ b/core/res/res/values-mcc311-mnc180-uz/strings.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+/* //device/apps/common/assets/res/any/strings.xml
+**
+** Copyright 2006, The Android Open Source Project
+**
+** Licensed under the Apache License, Version 2.0 (the "License");
+** you may not use this file except in compliance with the License.
+** You may obtain a copy of the License at
+**
+** http://www.apache.org/licenses/LICENSE-2.0
+**
+** Unless required by applicable law or agreed to in writing, software
+** distributed under the License is distributed on an "AS IS" BASIS,
+** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+** See the License for the specific language governing permissions and
+** limitations under the License.
+*/
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="mmcc_imsi_unknown_in_hlr" msgid="604133804161351810">"SIM karta ishlatish taqiqlangan (MM#2)"</string>
+ <string name="mmcc_illegal_ms" msgid="4073997279280371621">"SIM karta ishlatish taqiqlangan (MM#3)"</string>
+ <string name="mmcc_illegal_me" msgid="4936539345546223576">"Chaqiruvlar taqiqlangan (MM#6)"</string>
+</resources>
diff --git a/core/res/res/values-te/strings.xml b/core/res/res/values-te/strings.xml
index 2d56fb1..d959a37 100644
--- a/core/res/res/values-te/strings.xml
+++ b/core/res/res/values-te/strings.xml
@@ -829,12 +829,12 @@
<string name="keyguard_password_enter_password_code" msgid="2751130557661643482">"అన్లాక్ చేయడానికి పాస్వర్డ్ను టైప్ చేయండి"</string>
<string name="keyguard_password_enter_pin_password_code" msgid="7792964196473964340">"అన్లాక్ చేయడానికి పిన్ను టైప్ చేయండి"</string>
<string name="keyguard_password_wrong_pin_code" msgid="8583732939138432793">"చెల్లని పిన్ కోడ్."</string>
- <string name="keyguard_label_text" msgid="3841953694564168384">"అన్లాక్ చేయడానికి, మెను ఆపై 0ని నొక్కండి."</string>
+ <string name="keyguard_label_text" msgid="3841953694564168384">"అన్లాక్ చేయడానికి, మెనూ ఆపై 0ని నొక్కండి."</string>
<string name="emergency_call_dialog_number_for_display" msgid="2978165477085612673">"అత్యవసర నంబర్"</string>
<string name="lockscreen_carrier_default" msgid="6192313772955399160">"సేవ లేదు"</string>
<string name="lockscreen_screen_locked" msgid="7364905540516041817">"స్క్రీన్ లాక్ చేయబడింది."</string>
- <string name="lockscreen_instructions_when_pattern_enabled" msgid="7982445492532123308">"అన్లాక్ చేయడానికి లేదా అత్యవసర కాల్ చేయడానికి మెను నొక్కండి."</string>
- <string name="lockscreen_instructions_when_pattern_disabled" msgid="7434061749374801753">"అన్లాక్ చేయడానికి మెను నొక్కండి."</string>
+ <string name="lockscreen_instructions_when_pattern_enabled" msgid="7982445492532123308">"అన్లాక్ చేయడానికి లేదా అత్యవసర కాల్ చేయడానికి మెనూ నొక్కండి."</string>
+ <string name="lockscreen_instructions_when_pattern_disabled" msgid="7434061749374801753">"అన్లాక్ చేయడానికి మెనూ నొక్కండి."</string>
<string name="lockscreen_pattern_instructions" msgid="3169991838169244941">"అన్లాక్ చేయడానికి నమూనాను గీయండి"</string>
<string name="lockscreen_emergency_call" msgid="7549683825868928636">"ఎమర్జెన్సీ కాల్"</string>
<string name="lockscreen_return_to_call" msgid="3156883574692006382">"కాల్కు తిరిగి వెళ్లు"</string>
@@ -977,7 +977,7 @@
<string name="text_copied" msgid="2531420577879738860">"వచనం క్లిప్బోర్డ్కు కాపీ చేయబడింది."</string>
<string name="copied" msgid="4675902854553014676">"కాపీ చేయబడింది"</string>
<string name="more_item_label" msgid="7419249600215749115">"ఎక్కువ"</string>
- <string name="prepend_shortcut_label" msgid="1743716737502867951">"మెను+"</string>
+ <string name="prepend_shortcut_label" msgid="1743716737502867951">"మెనూ+"</string>
<string name="menu_meta_shortcut_label" msgid="1623390163674762478">"Meta+"</string>
<string name="menu_ctrl_shortcut_label" msgid="131911133027196485">"Ctrl+"</string>
<string name="menu_alt_shortcut_label" msgid="343761069945250991">"Alt+"</string>
diff --git a/core/tests/coretests/src/android/app/servertransaction/TransactionParcelTests.java b/core/tests/coretests/src/android/app/servertransaction/TransactionParcelTests.java
index 7766b57..5871e2e 100644
--- a/core/tests/coretests/src/android/app/servertransaction/TransactionParcelTests.java
+++ b/core/tests/coretests/src/android/app/servertransaction/TransactionParcelTests.java
@@ -672,5 +672,11 @@
public void notifyContentProviderPublishStatus(ContentProviderHolder holder, String auth,
int userId, boolean published) {
}
+
+ @Override
+ public void instrumentWithoutRestart(ComponentName instrumentationName,
+ Bundle instrumentationArgs, IInstrumentationWatcher instrumentationWatcher,
+ IUiAutomationConnection instrumentationUiConnection, ApplicationInfo targetInfo) {
+ }
}
}
diff --git a/core/tests/coretests/src/android/graphics/TypefaceTest.java b/core/tests/coretests/src/android/graphics/TypefaceTest.java
index 4393e9e7..cfed2ce 100644
--- a/core/tests/coretests/src/android/graphics/TypefaceTest.java
+++ b/core/tests/coretests/src/android/graphics/TypefaceTest.java
@@ -17,14 +17,12 @@
package android.graphics;
import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertNotEquals;
+import static org.junit.Assert.assertNotNull;
import static org.junit.Assert.assertTrue;
import android.content.Context;
import android.content.res.AssetManager;
import android.content.res.Resources;
-import android.graphics.fonts.SystemFonts;
-import android.os.SharedMemory;
import androidx.test.InstrumentationRegistry;
import androidx.test.filters.LargeTest;
@@ -37,8 +35,9 @@
import org.junit.Test;
import org.junit.runner.RunWith;
-import java.util.HashMap;
-import java.util.Map;
+import java.nio.ByteBuffer;
+import java.util.Arrays;
+import java.util.List;
import java.util.Random;
@RunWith(AndroidJUnit4.class)
@@ -55,33 +54,14 @@
Typeface.create(Typeface.MONOSPACE, 0)
};
- private static final int[] STYLES = {
- Typeface.NORMAL, Typeface.BOLD, Typeface.ITALIC, Typeface.BOLD_ITALIC,
- };
-
@SmallTest
@Test
- public void testBasic() {
- assertNotEquals("basic", 0, Typeface.DEFAULT.native_instance);
- assertNotEquals("basic", 0, Typeface.DEFAULT_BOLD.native_instance);
- assertNotEquals("basic", 0, Typeface.SANS_SERIF.native_instance);
- assertNotEquals("basic", 0, Typeface.SERIF.native_instance);
- assertNotEquals("basic", 0, Typeface.MONOSPACE.native_instance);
- assertEquals("basic", Typeface.NORMAL, Typeface.DEFAULT.getStyle());
- assertEquals("basic", Typeface.BOLD, Typeface.DEFAULT_BOLD.getStyle());
- assertEquals("basic", Typeface.NORMAL, Typeface.SANS_SERIF.getStyle());
- assertEquals("basic", Typeface.NORMAL, Typeface.SERIF.getStyle());
- assertEquals("basic", Typeface.NORMAL, Typeface.MONOSPACE.getStyle());
- }
-
- @SmallTest
- @Test
- public void testDefaults() {
- for (int style : STYLES) {
- String msg = "style = " + style;
- assertNotEquals(msg, 0, Typeface.defaultFromStyle(style).native_instance);
- assertEquals(msg, style, Typeface.defaultFromStyle(style).getStyle());
- }
+ public void testBasic() throws Exception {
+ assertTrue("basic", Typeface.DEFAULT != null);
+ assertTrue("basic", Typeface.DEFAULT_BOLD != null);
+ assertTrue("basic", Typeface.SANS_SERIF != null);
+ assertTrue("basic", Typeface.SERIF != null);
+ assertTrue("basic", Typeface.MONOSPACE != null);
}
@SmallTest
@@ -198,67 +178,21 @@
@SmallTest
@Test
public void testSerialize() throws Exception {
- HashMap<String, Typeface> systemFontMap = new HashMap<>();
- Typeface.initSystemDefaultTypefaces(systemFontMap, SystemFonts.getRawSystemFallbackMap(),
- SystemFonts.getAliases());
- SharedMemory sharedMemory = Typeface.serializeFontMap(systemFontMap);
- Map<String, Typeface> copiedFontMap = Typeface.deserializeFontMap(sharedMemory);
- assertEquals(systemFontMap.size(), copiedFontMap.size());
- for (String key : systemFontMap.keySet()) {
- assertTrue(copiedFontMap.containsKey(key));
- Typeface original = systemFontMap.get(key);
- Typeface copied = copiedFontMap.get(key);
+ int size = Typeface.writeTypefaces(null, Arrays.asList(mFaces));
+ ByteBuffer buffer = ByteBuffer.allocateDirect(size);
+ Typeface.writeTypefaces(buffer, Arrays.asList(mFaces));
+ List<Typeface> copiedTypefaces = Typeface.readTypefaces(buffer);
+ assertNotNull(copiedTypefaces);
+ assertEquals(mFaces.length, copiedTypefaces.size());
+ for (int i = 0; i < mFaces.length; i++) {
+ Typeface original = mFaces[i];
+ Typeface copied = copiedTypefaces.get(i);
assertEquals(original.getStyle(), copied.getStyle());
assertEquals(original.getWeight(), copied.getWeight());
assertEquals(measureText(original, "hello"), measureText(copied, "hello"), 1e-6);
}
}
- @SmallTest
- @Test
- public void testSetSystemFontMap() throws Exception {
- Context context = InstrumentationRegistry.getInstrumentation().getTargetContext();
- Resources res = context.getResources();
- Map<String, Typeface> fontMap = Map.of(
- "sans-serif", Typeface.create(res.getFont(R.font.samplefont), Typeface.NORMAL),
- "serif", Typeface.create(res.getFont(R.font.samplefont2), Typeface.NORMAL),
- "monospace", Typeface.create(res.getFont(R.font.samplefont3), Typeface.NORMAL),
- "sample", Typeface.create(res.getFont(R.font.samplefont4), Typeface.NORMAL),
- "sample-italic", Typeface.create(res.getFont(R.font.samplefont4), Typeface.ITALIC));
- Typeface.setSystemFontMap(fontMap);
-
- // Test public static final fields
- assertEquals(fontMap.get("sans-serif").native_instance, Typeface.DEFAULT.native_instance);
- assertNotEquals(0, Typeface.DEFAULT_BOLD.native_instance);
- assertEquals(
- fontMap.get("sans-serif").native_instance, Typeface.SANS_SERIF.native_instance);
- assertEquals(fontMap.get("serif").native_instance, Typeface.SERIF.native_instance);
- assertEquals(fontMap.get("monospace").native_instance, Typeface.MONOSPACE.native_instance);
- assertEquals(Typeface.NORMAL, Typeface.DEFAULT.getStyle());
- assertEquals(Typeface.BOLD, Typeface.DEFAULT_BOLD.getStyle());
- assertEquals(Typeface.NORMAL, Typeface.SANS_SERIF.getStyle());
- assertEquals(Typeface.NORMAL, Typeface.SERIF.getStyle());
- assertEquals(Typeface.NORMAL, Typeface.MONOSPACE.getStyle());
-
- // Test defaults
- assertEquals(
- fontMap.get("sans-serif").native_instance,
- Typeface.defaultFromStyle(Typeface.NORMAL).native_instance);
- for (int style : STYLES) {
- String msg = "style = " + style;
- assertNotEquals(msg, 0, Typeface.defaultFromStyle(style).native_instance);
- assertEquals(msg, style, Typeface.defaultFromStyle(style).getStyle());
- }
-
- // Test create()
- assertEquals(
- fontMap.get("sample").native_instance,
- Typeface.create("sample", Typeface.NORMAL).native_instance);
- assertEquals(
- fontMap.get("sample-italic").native_instance,
- Typeface.create("sample-italic", Typeface.ITALIC).native_instance);
- }
-
private static float measureText(Typeface typeface, String text) {
Paint paint = new Paint();
paint.setTypeface(typeface);
diff --git a/core/tests/coretests/src/android/widget/TextViewOnReceiveContentTest.java b/core/tests/coretests/src/android/widget/TextViewOnReceiveContentTest.java
index 8efd3b4..7b9283b 100644
--- a/core/tests/coretests/src/android/widget/TextViewOnReceiveContentTest.java
+++ b/core/tests/coretests/src/android/widget/TextViewOnReceiveContentTest.java
@@ -16,12 +16,11 @@
package android.widget;
-import static android.view.OnReceiveContentCallback.Payload.SOURCE_AUTOFILL;
-import static android.view.OnReceiveContentCallback.Payload.SOURCE_CLIPBOARD;
-import static android.view.OnReceiveContentCallback.Payload.SOURCE_DRAG_AND_DROP;
-import static android.view.OnReceiveContentCallback.Payload.SOURCE_INPUT_METHOD;
-import static android.view.OnReceiveContentCallback.Payload.SOURCE_PROCESS_TEXT;
-import static android.widget.TextViewOnReceiveContentCallback.canReuse;
+import static android.view.OnReceiveContentListener.Payload.SOURCE_AUTOFILL;
+import static android.view.OnReceiveContentListener.Payload.SOURCE_CLIPBOARD;
+import static android.view.OnReceiveContentListener.Payload.SOURCE_DRAG_AND_DROP;
+import static android.view.OnReceiveContentListener.Payload.SOURCE_INPUT_METHOD;
+import static android.view.OnReceiveContentListener.Payload.SOURCE_PROCESS_TEXT;
import static android.widget.espresso.TextViewActions.clickOnTextAtIndex;
import static androidx.test.espresso.Espresso.onView;
@@ -42,8 +41,7 @@
import android.content.ClipDescription;
import android.net.Uri;
import android.os.Bundle;
-import android.util.ArraySet;
-import android.view.OnReceiveContentCallback;
+import android.view.OnReceiveContentListener;
import android.view.inputmethod.InputConnection;
import android.view.inputmethod.InputConnectionWrapper;
import android.view.inputmethod.InputContentInfo;
@@ -62,7 +60,7 @@
import org.mockito.Mockito;
/**
- * Tests for {@link TextViewOnReceiveContentCallback}. Most of the test cases are in the CTS test
+ * Tests for {@link TextViewOnReceiveContentListener}. Most of the test cases are in the CTS test
* {@link android.widget.cts.TextViewOnReceiveContentTest}. This class tests some internal
* implementation details, e.g. fallback to the keyboard image API.
*/
@@ -78,35 +76,34 @@
private Instrumentation mInstrumentation;
private Activity mActivity;
private CustomInputConnectionEditText mEditText;
- private TextViewOnReceiveContentCallback mDefaultCallback;
+ private TextViewOnReceiveContentListener mDefaultReceiver;
@Before
public void before() {
mInstrumentation = InstrumentationRegistry.getInstrumentation();
mActivity = mActivityRule.getActivity();
mEditText = mActivity.findViewById(R.id.edittext2);
- mDefaultCallback = mEditText.getEditorForTesting().getDefaultOnReceiveContentCallback();
+ mDefaultReceiver = mEditText.getEditorForTesting().getDefaultOnReceiveContentListener();
}
@Test
- public void testGetSupportedMimeTypes_fallbackToCommitContent() throws Throwable {
+ public void testGetEditorInfoMimeTypes_fallbackToCommitContent() throws Throwable {
// Configure the EditText with an EditorInfo/InputConnection that supports some image MIME
// types.
- mEditText.setContentMimeTypes(new String[] {"image/gif", "image/png"});
+ String[] mimeTypes = {"image/gif", "image/png"};
+ mEditText.setContentMimeTypes(mimeTypes);
MyInputConnection ic = new MyInputConnection();
mEditText.setInputConnectionWrapper(ic);
// Focus into the EditText.
onView(withId(mEditText.getId())).perform(clickOnTextAtIndex(0));
- // Assert that the callback returns the MIME types declared in the EditorInfo in addition to
- // the default.
- assertThat(mDefaultCallback.getMimeTypes(mEditText)).containsExactly(
- "text/*", "image/gif", "image/png");
+ // Assert that the default listener returns the MIME types declared in the EditorInfo.
+ assertThat(mDefaultReceiver.getEditorInfoMimeTypes(mEditText)).isEqualTo(mimeTypes);
}
@Test
- public void testGetSupportedMimeTypes_fallbackToCommitContent_noMimeTypesInEditorInfo()
+ public void testGetEditorInfoMimeTypes_fallbackToCommitContent_noMimeTypesInEditorInfo()
throws Throwable {
// Configure the EditText with an EditorInfo/InputConnection that doesn't declare any MIME
// types.
@@ -117,8 +114,8 @@
// Focus into the EditText.
onView(withId(mEditText.getId())).perform(clickOnTextAtIndex(0));
- // Assert that the callback returns the default MIME types.
- assertThat(mDefaultCallback.getMimeTypes(mEditText)).containsExactly("text/*");
+ // Assert that the default listener returns null as the MIME types.
+ assertThat(mDefaultReceiver.getEditorInfoMimeTypes(mEditText)).isNull();
}
@Test
@@ -132,13 +129,13 @@
// Focus into the EditText.
onView(withId(mEditText.getId())).perform(clickOnTextAtIndex(0));
- // Invoke the callback with SOURCE_AUTOFILL and assert that it triggers a call to
+ // Invoke the listener with SOURCE_AUTOFILL and assert that it triggers a call to
// InputConnection.commitContent.
ClipDescription description = new ClipDescription("", new String[] {"image/gif"});
ClipData clip = new ClipData(description, new ClipData.Item(SAMPLE_CONTENT_URI));
- OnReceiveContentCallback.Payload payload =
- new OnReceiveContentCallback.Payload.Builder(clip, SOURCE_AUTOFILL).build();
- mDefaultCallback.onReceiveContent(mEditText, payload);
+ OnReceiveContentListener.Payload payload =
+ new OnReceiveContentListener.Payload.Builder(clip, SOURCE_AUTOFILL).build();
+ mDefaultReceiver.onReceiveContent(mEditText, payload);
verify(ic.mMock, times(1))
.commitContent(any(InputContentInfo.class), eq(0), eq(null));
verifyNoMoreInteractions(ic.mMock);
@@ -155,12 +152,12 @@
// Focus into the EditText.
onView(withId(mEditText.getId())).perform(clickOnTextAtIndex(0));
- // Invoke the callback and assert that the InputConnection is not invoked.
+ // Invoke the listener and assert that the InputConnection is not invoked.
ClipDescription description = new ClipDescription("", new String[] {"image/gif"});
ClipData clip = new ClipData(description, new ClipData.Item(SAMPLE_CONTENT_URI));
- OnReceiveContentCallback.Payload payload =
- new OnReceiveContentCallback.Payload.Builder(clip, SOURCE_AUTOFILL).build();
- mDefaultCallback.onReceiveContent(mEditText, payload);
+ OnReceiveContentListener.Payload payload =
+ new OnReceiveContentListener.Payload.Builder(clip, SOURCE_AUTOFILL).build();
+ mDefaultReceiver.onReceiveContent(mEditText, payload);
verifyZeroInteractions(ic.mMock);
}
@@ -175,71 +172,28 @@
// Focus into the EditText.
onView(withId(mEditText.getId())).perform(clickOnTextAtIndex(0));
- // Invoke the callback with sources other than SOURCE_AUTOFILL and assert that it does NOT
+ // Invoke the listener with sources other than SOURCE_AUTOFILL and assert that it does NOT
// trigger calls to InputConnection.commitContent.
ClipDescription description = new ClipDescription("", new String[] {"image/gif"});
ClipData clip = new ClipData(description, new ClipData.Item(SAMPLE_CONTENT_URI));
- OnReceiveContentCallback.Payload payload =
- new OnReceiveContentCallback.Payload.Builder(clip, SOURCE_CLIPBOARD).build();
- mDefaultCallback.onReceiveContent(mEditText, payload);
+ OnReceiveContentListener.Payload payload =
+ new OnReceiveContentListener.Payload.Builder(clip, SOURCE_CLIPBOARD).build();
+ mDefaultReceiver.onReceiveContent(mEditText, payload);
verifyZeroInteractions(ic.mMock);
- payload = new OnReceiveContentCallback.Payload.Builder(clip, SOURCE_INPUT_METHOD).build();
- mDefaultCallback.onReceiveContent(mEditText, payload);
+ payload = new OnReceiveContentListener.Payload.Builder(clip, SOURCE_INPUT_METHOD).build();
+ mDefaultReceiver.onReceiveContent(mEditText, payload);
verifyZeroInteractions(ic.mMock);
- payload = new OnReceiveContentCallback.Payload.Builder(clip, SOURCE_DRAG_AND_DROP).build();
- mDefaultCallback.onReceiveContent(mEditText, payload);
+ payload = new OnReceiveContentListener.Payload.Builder(clip, SOURCE_DRAG_AND_DROP).build();
+ mDefaultReceiver.onReceiveContent(mEditText, payload);
verifyZeroInteractions(ic.mMock);
- payload = new OnReceiveContentCallback.Payload.Builder(clip, SOURCE_PROCESS_TEXT).build();
- mDefaultCallback.onReceiveContent(mEditText, payload);
+ payload = new OnReceiveContentListener.Payload.Builder(clip, SOURCE_PROCESS_TEXT).build();
+ mDefaultReceiver.onReceiveContent(mEditText, payload);
verifyZeroInteractions(ic.mMock);
}
- @Test
- public void testCanReuse() throws Throwable {
- ArraySet<String> mimeTypes = null;
- String[] editorContentMimeTypes = new String[0];
- assertThat(canReuse(mimeTypes, editorContentMimeTypes)).isFalse();
-
- mimeTypes = new ArraySet<>();
- editorContentMimeTypes = new String[0];
- assertThat(canReuse(mimeTypes, editorContentMimeTypes)).isTrue();
-
- mimeTypes = newArraySet("text/*");
- editorContentMimeTypes = new String[0];
- assertThat(canReuse(mimeTypes, editorContentMimeTypes)).isTrue();
-
- mimeTypes = newArraySet("text/*");
- editorContentMimeTypes = new String[] {"text/*"};
- assertThat(canReuse(mimeTypes, editorContentMimeTypes)).isTrue();
-
- mimeTypes = newArraySet("image/gif", "image/png", "text/*");
- editorContentMimeTypes = new String[] {"image/gif", "image/png"};
- assertThat(canReuse(mimeTypes, editorContentMimeTypes)).isTrue();
-
- mimeTypes = newArraySet("image/gif", "image/png", "text/*");
- editorContentMimeTypes = new String[] {"image/gif", "image/png", "text/*"};
- assertThat(canReuse(mimeTypes, editorContentMimeTypes)).isTrue();
-
- mimeTypes = newArraySet("image/gif", "image/png", "text/*");
- editorContentMimeTypes = new String[] {"image/gif"};
- assertThat(canReuse(mimeTypes, editorContentMimeTypes)).isFalse();
-
- mimeTypes = newArraySet("image/gif", "image/png", "text/*");
- editorContentMimeTypes = new String[] {"image/gif", "image/png", "image/jpg"};
- assertThat(canReuse(mimeTypes, editorContentMimeTypes)).isFalse();
-
- mimeTypes = newArraySet("image/gif", "image/png", "text/*");
- editorContentMimeTypes = new String[] {"image/gif", "image/jpg"};
- assertThat(canReuse(mimeTypes, editorContentMimeTypes)).isFalse();
-
- mimeTypes = newArraySet("image/gif", "image/png", "text/*");
- editorContentMimeTypes = new String[] {"image/gif", "image/jpg", "text/*"};
- assertThat(canReuse(mimeTypes, editorContentMimeTypes)).isFalse();
- }
-
private static class MyInputConnection extends InputConnectionWrapper {
public final InputConnection mMock;
@@ -254,9 +208,4 @@
return true;
}
}
-
- @SafeVarargs
- private static <T> ArraySet<T> newArraySet(T ... elements) {
- return new ArraySet<>(elements);
- }
}
diff --git a/graphics/java/android/graphics/Typeface.java b/graphics/java/android/graphics/Typeface.java
index d44cb9c..c58e5f3 100644
--- a/graphics/java/android/graphics/Typeface.java
+++ b/graphics/java/android/graphics/Typeface.java
@@ -34,12 +34,8 @@
import android.graphics.fonts.SystemFonts;
import android.os.Build;
import android.os.ParcelFileDescriptor;
-import android.os.SharedMemory;
-import android.os.Trace;
import android.provider.FontRequest;
import android.provider.FontsContract;
-import android.system.ErrnoException;
-import android.system.OsConstants;
import android.text.FontConfig;
import android.util.Base64;
import android.util.LongSparseArray;
@@ -54,7 +50,6 @@
import libcore.util.NativeAllocationRegistry;
-import java.io.ByteArrayOutputStream;
import java.io.File;
import java.io.FileDescriptor;
import java.io.IOException;
@@ -62,7 +57,6 @@
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.nio.ByteBuffer;
-import java.nio.ByteOrder;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collections;
@@ -85,19 +79,19 @@
Typeface.class.getClassLoader(), nativeGetReleaseFunc());
/** The default NORMAL typeface object */
- public static final Typeface DEFAULT = new Typeface();
+ public static final Typeface DEFAULT;
/**
* The default BOLD typeface object. Note: this may be not actually be
* bold, depending on what fonts are installed. Call getStyle() to know
* for sure.
*/
- public static final Typeface DEFAULT_BOLD = new Typeface();
+ public static final Typeface DEFAULT_BOLD;
/** The NORMAL style of the default sans serif typeface. */
- public static final Typeface SANS_SERIF = new Typeface();
+ public static final Typeface SANS_SERIF;
/** The NORMAL style of the default serif typeface. */
- public static final Typeface SERIF = new Typeface();
+ public static final Typeface SERIF;
/** The NORMAL style of the default monospace typeface. */
- public static final Typeface MONOSPACE = new Typeface();
+ public static final Typeface MONOSPACE;
/**
* The default {@link Typeface}s for different text styles.
@@ -139,7 +133,7 @@
* Use public API {@link #create(String, int)} to get the typeface for given familyName.
*/
@UnsupportedAppUsage(trackingBug = 123769347)
- static final Map<String, Typeface> sSystemFontMap = new HashMap<>();
+ static final Map<String, Typeface> sSystemFontMap;
// We cannot support sSystemFallbackMap since we will migrate to public FontFamily API.
/**
@@ -156,9 +150,6 @@
@UnsupportedAppUsage
public long native_instance;
- // This destructs native_instance.
- private Runnable mCleaner;
-
/** @hide */
@IntDef(value = {NORMAL, BOLD, ITALIC, BOLD_ITALIC})
@Retention(RetentionPolicy.SOURCE)
@@ -1095,41 +1086,19 @@
return new Typeface(nativeCreateFromArray(ptrArray, weight, italic));
}
- /**
- * Creates a fake Typeface object that are later modified to point to another Typeface object
- * using {@link #reset(Typeface, int)}.
- *
- * <p>This constructor is only for filling 'static final' Typeface instances in Zygote process.
- */
- private Typeface() {
- }
-
// don't allow clients to call this directly
@UnsupportedAppUsage(maxTargetSdk = Build.VERSION_CODES.P, trackingBug = 115609023)
private Typeface(long ni) {
- init(ni);
- }
-
- private void init(long ni) {
if (ni == 0) {
throw new RuntimeException("native typeface cannot be made");
}
- if (mCleaner != null) {
- mCleaner.run();
- }
+
native_instance = ni;
- mCleaner = sRegistry.registerNativeAllocation(this, native_instance);
+ sRegistry.registerNativeAllocation(this, native_instance);
mStyle = nativeGetStyle(ni);
mWeight = nativeGetWeight(ni);
}
- private void reset(Typeface typeface, int style) {
- // Just create a new native instance without looking into the cache, because we are going to
- // claim the ownership.
- long ni = nativeCreateFromTypeface(typeface.native_instance, style);
- init(ni);
- }
-
private static Typeface getSystemDefaultTypeface(@NonNull String familyName) {
Typeface tf = sSystemFontMap.get(familyName);
return tf == null ? Typeface.DEFAULT : tf;
@@ -1168,105 +1137,23 @@
}
}
- /** @hide */
- public static SharedMemory serializeFontMap(Map<String, Typeface> fontMap)
- throws IOException, ErrnoException {
- long[] nativePtrs = new long[fontMap.size()];
- // The name table will not be large, so let's create a byte array in memory.
- ByteArrayOutputStream namesBytes = new ByteArrayOutputStream();
- int i = 0;
- for (Map.Entry<String, Typeface> entry : fontMap.entrySet()) {
- nativePtrs[i++] = entry.getValue().native_instance;
- writeString(namesBytes, entry.getKey());
- }
- int typefacesBytesCount = nativeWriteTypefaces(null, nativePtrs);
- // int (typefacesBytesCount), typefaces, namesBytes
- SharedMemory sharedMemory = SharedMemory.create(
- "fontMap", Integer.BYTES + typefacesBytesCount + namesBytes.size());
- ByteBuffer writableBuffer = sharedMemory.mapReadWrite().order(ByteOrder.BIG_ENDIAN);
- try {
- writableBuffer.putInt(typefacesBytesCount);
- int writtenBytesCount = nativeWriteTypefaces(writableBuffer.slice(), nativePtrs);
- if (writtenBytesCount != typefacesBytesCount) {
- throw new IOException(String.format("Unexpected bytes written: %d, expected: %d",
- writtenBytesCount, typefacesBytesCount));
- }
- writableBuffer.position(writableBuffer.position() + writtenBytesCount);
- writableBuffer.put(namesBytes.toByteArray());
- } finally {
- SharedMemory.unmap(writableBuffer);
- }
- sharedMemory.setProtect(OsConstants.PROT_READ);
- return sharedMemory;
- }
-
- /** @hide */
- @VisibleForTesting
- public static Map<String, Typeface> deserializeFontMap(SharedMemory sharedMemory)
- throws IOException, ErrnoException {
- Trace.traceBegin(Trace.TRACE_TAG_GRAPHICS, "deserializeFontMap");
- try {
- // TODO: unmap buffer when all Typefaces are gone.
- // Currently deserializeFontMap() should be called at most once per process, so we don't
- // need to unmap this buffer.
- ByteBuffer buffer = sharedMemory.mapReadOnly().order(ByteOrder.BIG_ENDIAN);
- Map<String, Typeface> fontMap = new HashMap<>();
- int typefacesBytesCount = buffer.getInt();
- long[] nativePtrs = nativeReadTypefaces(buffer.slice());
- if (nativePtrs == null) {
- throw new IOException("Could not read typefaces");
- }
- buffer.position(buffer.position() + typefacesBytesCount);
- for (long nativePtr : nativePtrs) {
- String name = readString(buffer);
- fontMap.put(name, new Typeface(nativePtr));
- }
- return fontMap;
- } finally {
- Trace.traceEnd(Trace.TRACE_TAG_GRAPHICS);
- }
- }
-
- private static String readString(ByteBuffer buffer) {
- int length = buffer.getInt();
- byte[] bytes = new byte[length];
- buffer.get(bytes);
- return new String(bytes);
- }
-
- private static void writeString(ByteArrayOutputStream bos, String value) throws IOException {
- byte[] bytes = value.getBytes();
- writeInt(bos, bytes.length);
- bos.write(bytes);
- }
-
- private static void writeInt(ByteArrayOutputStream bos, int value) {
- // Write in the big endian order.
- bos.write((value >> 24) & 0xFF);
- bos.write((value >> 16) & 0xFF);
- bos.write((value >> 8) & 0xFF);
- bos.write(value & 0xFF);
- }
-
- /** @hide */
- @VisibleForTesting
- public static void setSystemFontMap(Map<String, Typeface> systemFontMap) {
- sSystemFontMap.clear();
- sSystemFontMap.putAll(systemFontMap);
+ static {
+ final HashMap<String, Typeface> systemFontMap = new HashMap<>();
+ initSystemDefaultTypefaces(systemFontMap, SystemFonts.getRawSystemFallbackMap(),
+ SystemFonts.getAliases());
+ sSystemFontMap = Collections.unmodifiableMap(systemFontMap);
// We can't assume DEFAULT_FAMILY available on Roboletric.
if (sSystemFontMap.containsKey(DEFAULT_FAMILY)) {
setDefault(sSystemFontMap.get(DEFAULT_FAMILY));
}
- // Set up defaults and typefaces exposed in public API.
- // We cannot use getSystemDefaultTypeface() here to initialize DEFAULT, because it returns
- // DEFAULT.
- DEFAULT.reset(sDefaultTypeface, Typeface.NORMAL);
- DEFAULT_BOLD.reset(sDefaultTypeface, Typeface.BOLD);
- SANS_SERIF.reset(getSystemDefaultTypeface("sans-serif"), Typeface.NORMAL);
- SERIF.reset(getSystemDefaultTypeface("serif"), Typeface.NORMAL);
- MONOSPACE.reset(getSystemDefaultTypeface("monospace"), Typeface.NORMAL);
+ // Set up defaults and typefaces exposed in public API
+ DEFAULT = create((String) null, 0);
+ DEFAULT_BOLD = create((String) null, Typeface.BOLD);
+ SANS_SERIF = create("sans-serif", 0);
+ SERIF = create("serif", 0);
+ MONOSPACE = create("monospace", 0);
sDefaults = new Typeface[] {
DEFAULT,
@@ -1286,13 +1173,6 @@
}
}
- static {
- final HashMap<String, Typeface> systemFontMap = new HashMap<>();
- initSystemDefaultTypefaces(systemFontMap, SystemFonts.getRawSystemFallbackMap(),
- SystemFonts.getAliases());
- setSystemFontMap(systemFontMap);
- }
-
@Override
public boolean equals(Object o) {
if (this == o) return true;
@@ -1330,6 +1210,36 @@
return Arrays.binarySearch(mSupportedAxes, axis) >= 0;
}
+ /**
+ * Writes Typeface instances to the ByteBuffer and returns the number of bytes written.
+ *
+ * <p>If {@code buffer} is null, this method returns the number of bytes required to serialize
+ * the typefaces, without writing anything.
+ * @hide
+ */
+ public static int writeTypefaces(
+ @Nullable ByteBuffer buffer, @NonNull List<Typeface> typefaces) {
+ long[] nativePtrs = new long[typefaces.size()];
+ for (int i = 0; i < nativePtrs.length; i++) {
+ nativePtrs[i] = typefaces.get(i).native_instance;
+ }
+ return nativeWriteTypefaces(buffer, nativePtrs);
+ }
+
+ /**
+ * Reads serialized Typeface instances from the ByteBuffer. Returns null on errors.
+ * @hide
+ */
+ public static @Nullable List<Typeface> readTypefaces(@NonNull ByteBuffer buffer) {
+ long[] nativePtrs = nativeReadTypefaces(buffer);
+ if (nativePtrs == null) return null;
+ List<Typeface> typefaces = new ArrayList<>(nativePtrs.length);
+ for (long nativePtr : nativePtrs) {
+ typefaces.add(new Typeface(nativePtr));
+ }
+ return typefaces;
+ }
+
private static native long nativeCreateFromTypeface(long native_instance, int style);
private static native long nativeCreateFromTypefaceWithExactStyle(
long native_instance, int weight, boolean italic);
diff --git a/keystore/java/android/security/keystore/ArrayUtils.java b/keystore/java/android/security/keystore/ArrayUtils.java
index f519c7c..c8c1de4 100644
--- a/keystore/java/android/security/keystore/ArrayUtils.java
+++ b/keystore/java/android/security/keystore/ArrayUtils.java
@@ -18,6 +18,8 @@
import libcore.util.EmptyArray;
+import java.util.function.Consumer;
+
/**
* @hide
*/
@@ -107,4 +109,16 @@
return result;
}
}
+
+ /**
+ * Runs {@code consumer.accept()} for each element of {@code array}.
+ * @param array
+ * @param consumer
+ * @hide
+ */
+ public static void forEach(int[] array, Consumer<Integer> consumer) {
+ for (int i : array) {
+ consumer.accept(i);
+ }
+ }
}
diff --git a/libs/WindowManager/Shell/res/raw/wm_shell_protolog.json b/libs/WindowManager/Shell/res/raw/wm_shell_protolog.json
index 6342c00..8213f2f 100644
--- a/libs/WindowManager/Shell/res/raw/wm_shell_protolog.json
+++ b/libs/WindowManager/Shell/res/raw/wm_shell_protolog.json
@@ -79,6 +79,12 @@
"group": "WM_SHELL_TASK_ORG",
"at": "com\/android\/wm\/shell\/splitscreen\/SplitScreenTaskListener.java"
},
+ "-742394458": {
+ "message": "pair task1=%d task2=%d in AppPair=%s",
+ "level": "VERBOSE",
+ "group": "WM_SHELL_TASK_ORG",
+ "at": "com\/android\/wm\/shell\/apppairs\/AppPair.java"
+ },
"-710770147": {
"message": "Add target: %s",
"level": "VERBOSE",
@@ -91,6 +97,12 @@
"group": "WM_SHELL_TASK_ORG",
"at": "com\/android\/wm\/shell\/splitscreen\/SplitScreenTaskListener.java"
},
+ "-234284913": {
+ "message": "unpair taskId=%d pair=%s",
+ "level": "VERBOSE",
+ "group": "WM_SHELL_TASK_ORG",
+ "at": "com\/android\/wm\/shell\/apppairs\/AppPairsController.java"
+ },
"-191422040": {
"message": "Transition animations finished, notifying core %s",
"level": "VERBOSE",
@@ -139,12 +151,30 @@
"group": "WM_SHELL_TASK_ORG",
"at": "com\/android\/wm\/shell\/ShellTaskOrganizer.java"
},
+ "900599280": {
+ "message": "Can't pair unresizeable tasks task1.isResizeable=%b task1.isResizeable=%b",
+ "level": "ERROR",
+ "group": "WM_SHELL_TASK_ORG",
+ "at": "com\/android\/wm\/shell\/apppairs\/AppPair.java"
+ },
+ "950299522": {
+ "message": "taskId %d isn't isn't in an app-pair.",
+ "level": "VERBOSE",
+ "group": "WM_SHELL_TASK_ORG",
+ "at": "com\/android\/wm\/shell\/apppairs\/AppPairsController.java"
+ },
"980952660": {
"message": "Task root back pressed taskId=%d",
"level": "VERBOSE",
"group": "WM_SHELL_TASK_ORG",
"at": "com\/android\/wm\/shell\/ShellTaskOrganizer.java"
},
+ "1079041527": {
+ "message": "incrementPool size=%d",
+ "level": "VERBOSE",
+ "group": "WM_SHELL_TASK_ORG",
+ "at": "com\/android\/wm\/shell\/apppairs\/AppPairsPool.java"
+ },
"1104702476": {
"message": "Letterbox Task Changed: #%d",
"level": "VERBOSE",
@@ -175,12 +205,24 @@
"group": "WM_SHELL_DRAG_AND_DROP",
"at": "com\/android\/wm\/shell\/draganddrop\/DragAndDropController.java"
},
+ "1891981945": {
+ "message": "release entry.taskId=%s listener=%s size=%d",
+ "level": "VERBOSE",
+ "group": "WM_SHELL_TASK_ORG",
+ "at": "com\/android\/wm\/shell\/apppairs\/AppPairsPool.java"
+ },
"1990759023": {
"message": "addListenerForType types=%s listener=%s",
"level": "VERBOSE",
"group": "WM_SHELL_TASK_ORG",
"at": "com\/android\/wm\/shell\/ShellTaskOrganizer.java"
},
+ "2006473416": {
+ "message": "acquire entry.taskId=%s listener=%s size=%d",
+ "level": "VERBOSE",
+ "group": "WM_SHELL_TASK_ORG",
+ "at": "com\/android\/wm\/shell\/apppairs\/AppPairsPool.java"
+ },
"2057038970": {
"message": "Display changed: %d",
"level": "VERBOSE",
diff --git a/libs/WindowManager/Shell/res/values-af/strings.xml b/libs/WindowManager/Shell/res/values-af/strings.xml
new file mode 100644
index 0000000..7698e51
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-af/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Maak toe"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Vou uit"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Instellings"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Kieslys"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> is in beeld-in-beeld"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"As jy nie wil hê dat <xliff:g id="NAME">%s</xliff:g> hierdie kenmerk moet gebruik nie, tik om instellings oop te maak en skakel dit af."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Speel"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Laat wag"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Slaan oor na volgende"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Slaan oor na vorige"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Verander grootte"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Program steun nie verdeelde skerm nie."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Program sal dalk nie op \'n sekondêre skerm werk nie."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Program steun nie begin op sekondêre skerms nie."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Skermverdeler"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Volskerm links"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Links 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Links 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Links 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Volskerm regs"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Volskerm bo"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Bo 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Bo 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Bo 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Volskerm onder"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Instellings vir <xliff:g id="APP_NAME">%1$s</xliff:g>-borrels"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Oorloop"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Voeg terug op stapel"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> vanaf <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> van <xliff:g id="APP_NAME">%2$s</xliff:g> en <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> meer af"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Beweeg na links bo"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Beweeg na regs bo"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Beweeg na links onder"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Beweeg na regs onder"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>-instellings"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Maak borrel toe"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Moenie dat gesprek \'n borrel word nie"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Klets met borrels"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Nuwe gesprekke verskyn as swerwende ikone, of borrels Tik op borrel om dit oop te maak. Sleep om dit te skuif."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Beheer borrels enige tyd"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Tik op Bestuur om borrels vanaf hierdie program af te skakel"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Geen onlangse borrels nie"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Onlangse borrels en borrels wat toegemaak is, sal hier verskyn"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Borrel"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Bestuur"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Borrel is toegemaak."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-af/strings_tv.xml b/libs/WindowManager/Shell/res/values-af/strings_tv.xml
new file mode 100644
index 0000000..d5e9b92
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-af/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Titellose program)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Maak PIP toe"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Volskerm"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-am/strings.xml b/libs/WindowManager/Shell/res/values-am/strings.xml
new file mode 100644
index 0000000..49436ba
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-am/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"ዝጋ"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"ዘርጋ"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"ቅንብሮች"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"ምናሌ"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> በስዕል-ላይ-ስዕል ውስጥ ነው"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"<xliff:g id="NAME">%s</xliff:g> ይህን ባህሪ እንዲጠቀም ካልፈለጉ ቅንብሮችን ለመክፈት መታ ያድርጉና ያጥፉት።"</string>
+ <string name="pip_play" msgid="3496151081459417097">"አጫውት"</string>
+ <string name="pip_pause" msgid="690688849510295232">"ባለበት አቁም"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"ወደ ቀጣይ ዝለል"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"ወደ ቀዳሚ ዝለል"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"መጠን ይቀይሩ"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"መተግበሪያው የተከፈለ ማያ ገጽን አይደግፍም።"</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"መተግበሪያ በሁለተኛ ማሳያ ላይ ላይሠራ ይችላል።"</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"መተግበሪያ በሁለተኛ ማሳያዎች ላይ ማስጀመርን አይደግፍም።"</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"የተከፈለ የማያ ገጽ ከፋይ"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"የግራ ሙሉ ማያ ገጽ"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"ግራ 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"ግራ 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"ግራ 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"የቀኝ ሙሉ ማያ ገጽ"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"የላይ ሙሉ ማያ ገጽ"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"ከላይ 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"ከላይ 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"ከላይ 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"የታች ሙሉ ማያ ገጽ"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"ቅንብሮች ለ <xliff:g id="APP_NAME">%1$s</xliff:g> አረፋዎች"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"ትርፍ ፍሰት"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"ወደ ቁልል መልሰው ያክሉ"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> ከ<xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> ከ <xliff:g id="APP_NAME">%2$s</xliff:g> እና <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> ተጨማሪ"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"ወደ ላይኛው ግራ አንቀሳቅስ"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"ወደ ላይኛው ቀኝ አንቀሳቅስ"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"የግርጌውን ግራ አንቀሳቅስ"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"ታችኛውን ቀኝ ያንቀሳቅሱ"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"የ<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> ቅንብሮች"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"አረፋን አሰናብት"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"ውይይቶችን በአረፋ አታሳይ"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"አረፋዎችን በመጠቀም ይወያዩ"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"አዲስ ውይይቶች እንደ ተንሳፋፊ አዶዎች ወይም አረፋዎች ሆነው ይታያሉ። አረፋን ለመክፈት መታ ያድርጉ። ለመውሰድ ይጎትቱት።"</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"በማንኛውም ጊዜ አረፋዎችን ይቆጣጠሩ"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"የዚህ መተግበሪያ አረፋዎችን ለማጥፋት አቀናብርን መታ ያድርጉ"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"ምንም የቅርብ ጊዜ አረፋዎች የሉም"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"የቅርብ ጊዜ አረፋዎች እና የተሰናበቱ አረፋዎች እዚህ ብቅ ይላሉ"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"አረፋ"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"ያቀናብሩ"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"አረፋ ተሰናብቷል።"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-am/strings_tv.xml b/libs/WindowManager/Shell/res/values-am/strings_tv.xml
new file mode 100644
index 0000000..1661882
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-am/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(ርዕስ የሌለው ፕሮግራም)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"PIPን ዝጋ"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"ሙሉ ማያ ገጽ"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-ar/strings.xml b/libs/WindowManager/Shell/res/values-ar/strings.xml
new file mode 100644
index 0000000..3e81255
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-ar/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"إغلاق"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"توسيع"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"الإعدادات"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"القائمة"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> يظهر في صورة داخل صورة"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"إذا كنت لا تريد أن يستخدم <xliff:g id="NAME">%s</xliff:g> هذه الميزة، فانقر لفتح الإعدادات، ثم أوقِف تفعيل هذه الميزة."</string>
+ <string name="pip_play" msgid="3496151081459417097">"تشغيل"</string>
+ <string name="pip_pause" msgid="690688849510295232">"إيقاف مؤقت"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"التخطي إلى التالي"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"التخطي إلى السابق"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"تغيير الحجم"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"التطبيق لا يتيح تقسيم الشاشة."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"قد لا يعمل التطبيق على شاشة عرض ثانوية."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"لا يمكن تشغيل التطبيق على شاشات عرض ثانوية."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"أداة تقسيم الشاشة"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"عرض النافذة اليسرى بملء الشاشة"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"ضبط حجم النافذة اليسرى ليكون ٧٠%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"ضبط حجم النافذة اليسرى ليكون ٥٠%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"ضبط حجم النافذة اليسرى ليكون ٣٠%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"عرض النافذة اليمنى بملء الشاشة"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"عرض النافذة العلوية بملء الشاشة"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"ضبط حجم النافذة العلوية ليكون ٧٠%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"ضبط حجم النافذة العلوية ليكون ٥٠%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"ضبط حجم النافذة العلوية ليكون ٣٠%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"عرض النافذة السفلية بملء الشاشة"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"إعدادات فقاعات المحادثات على <xliff:g id="APP_NAME">%1$s</xliff:g>"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"القائمة الكاملة"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"إضافة دعم إلى الحزم"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> من <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> من <xliff:g id="APP_NAME">%2$s</xliff:g> و<xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> أيضًا"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"نقل إلى أعلى يمين الشاشة"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"الانتقال إلى أعلى اليسار"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"نقل إلى أسفل يمين الشاشة"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"نقل إلى أسفل اليسار"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"إعدادات <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"إغلاق فقاعة المحادثة"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"عدم عرض المحادثة كفقاعة محادثة"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"الدردشة باستخدام فقاعات المحادثات"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"تظهر المحادثات الجديدة كرموز عائمة أو كفقاعات. انقر لفتح فقاعة المحادثة، واسحبها لتحريكها."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"التحكّم في فقاعات المحادثات في أي وقت"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"انقر على \"إدارة\" لإيقاف فقاعات المحادثات من هذا التطبيق."</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"ليس هناك فقاعات محادثات"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"ستظهر هنا أحدث فقاعات المحادثات وفقاعات المحادثات التي تم إغلاقها."</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"فقاعة"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"إدارة"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"تم إغلاق الفقاعة."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-ar/strings_tv.xml b/libs/WindowManager/Shell/res/values-ar/strings_tv.xml
new file mode 100644
index 0000000..61588a0
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-ar/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(ليس هناك عنوان للبرنامج)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"إغلاق PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"ملء الشاشة"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-as/strings.xml b/libs/WindowManager/Shell/res/values-as/strings.xml
new file mode 100644
index 0000000..81cdc7f
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-as/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"বন্ধ কৰক"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"বিস্তাৰ কৰক"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"ছেটিংসমূহ"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"মেনু"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> চিত্ৰৰ ভিতৰৰ চিত্ৰত আছে"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"আপুনি যদি <xliff:g id="NAME">%s</xliff:g> সুবিধাটো ব্যৱহাৰ কৰিব নোখোজে, তেন্তে ছেটিংসমূহ খুলিবলৈ টিপক আৰু তালৈ গৈ ইয়াক অফ কৰক।"</string>
+ <string name="pip_play" msgid="3496151081459417097">"প্লে কৰক"</string>
+ <string name="pip_pause" msgid="690688849510295232">"পজ কৰক"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"পৰৱৰ্তী মিডিয়ালৈ যাওক"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"আগৰটো মিডিয়ালৈ যাওক"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"আকাৰ সলনি কৰক"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"এপটোৱে বিভাজিত স্ক্ৰীণ সমৰ্থন নকৰে।"</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"গৌণ ডিছপ্লেত এপে সঠিকভাৱে কাম নকৰিব পাৰে।"</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"গৌণ ডিছপ্লেত এপ্ লঞ্চ কৰিব নোৱাৰি।"</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"স্প্লিট স্ক্ৰীণৰ বিভাজক"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"বাওঁফালৰ স্ক্ৰীণখন সম্পূৰ্ণ স্ক্ৰীণ কৰক"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"বাওঁফালৰ স্ক্ৰীণখন ৭০% কৰক"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"বাওঁফালৰ স্ক্ৰীণখন ৫০% কৰক"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"বাওঁফালৰ স্ক্ৰীণখন ৩০% কৰক"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"সোঁফালৰ স্ক্ৰীণখন সম্পূৰ্ণ স্ক্ৰীণ কৰক"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"শীৰ্ষ স্ক্ৰীণখন সম্পূৰ্ণ স্ক্ৰীণ কৰক"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"শীর্ষ স্ক্ৰীণখন ৭০% কৰক"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"শীর্ষ স্ক্ৰীণখন ৫০% কৰক"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"শীর্ষ স্ক্ৰীণখন ৩০% কৰক"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"তলৰ স্ক্ৰীণখন সম্পূৰ্ণ স্ক্ৰীণ কৰক"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"<xliff:g id="APP_NAME">%1$s</xliff:g>ৰ bubblesৰ ছেটিংসমূহ"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"অভাৰফ্ল’"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"ষ্টেকত পুনৰ যোগ দিয়ক"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="APP_NAME">%2$s</xliff:g>ৰ পৰা <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="APP_NAME">%2$s</xliff:g> আৰু<xliff:g id="BUBBLE_COUNT">%3$d</xliff:g>টাৰ পৰা <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"শীৰ্ষৰ বাওঁফালে নিয়ক"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"শীৰ্ষৰ সোঁফালে নিয়ক"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"বুটামটো বাওঁফালে নিয়ক"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"তলৰ সোঁফালে নিয়ক"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> ছেটিংসমূহ"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"বাবল অগ্ৰাহ্য কৰক"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"বাৰ্তালাপ বাবল নকৰিব"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Bubbles ব্যৱহাৰ কৰি চাট কৰক"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"নতুন বাৰ্তালাপ উপঙি থকা চিহ্নসমূহ অথবা bubbles হিচাপে প্ৰদর্শিত হয়। Bubbles খুলিবলৈ টিপক। এইটো স্থানান্তৰ কৰিবলৈ টানি নিয়ক।"</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"যিকোনো সময়তে bubbles নিয়ন্ত্ৰণ কৰক"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"এই এপ্টোৰ পৰা bubbles অফ কৰিবলৈ পৰিচালনা কৰকত টিপক"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"কোনো শেহতীয়া bubbles নাই"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"শেহতীয়া bubbles আৰু অগ্ৰাহ্য কৰা bubbles ইয়াত প্ৰদর্শিত হ\'ব"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"বাবল"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"পৰিচালনা কৰক"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"বাবল অগ্ৰাহ্য কৰা হৈছে"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-as/strings_tv.xml b/libs/WindowManager/Shell/res/values-as/strings_tv.xml
new file mode 100644
index 0000000..c4e3f38
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-as/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(শিৰোনামবিহীন কাৰ্যক্ৰম)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"পিপ বন্ধ কৰক"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"সম্পূৰ্ণ স্ক্ৰীণ"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-az/strings.xml b/libs/WindowManager/Shell/res/values-az/strings.xml
new file mode 100644
index 0000000..7e8590f
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-az/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Bağlayın"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Genişləndirin"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Ayarlar"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Menyu"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> şəkil içində şəkildədir"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"<xliff:g id="NAME">%s</xliff:g> tətbiqinin bu funksiyadan istifadə etməyini istəmirsinizsə, ayarları açmaq və deaktiv etmək üçün klikləyin."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Oxudun"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Fasilə verin"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Növbətiyə keçin"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Əvvəlkinə keçin"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Ölçüsünü dəyişin"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Tətbiq ekran bölünməsini dəstəkləmir."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Tətbiq ikinci ekranda işləməyə bilər."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Tətbiq ikinci ekranda başlamağı dəstəkləmir."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Bölünmüş ekran ayırıcısı"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Sol tam ekran"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Sol 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Sol 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Sol 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Sağ tam ekran"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Yuxarı tam ekran"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Yuxarı 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Yuxarı 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Yuxarı 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Aşağı tam ekran"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"<xliff:g id="APP_NAME">%1$s</xliff:g> yumrucuqları üçün ayarlar"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Kənara çıxma"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Yenidən dəstəyə əlavə edin"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="APP_NAME">%2$s</xliff:g> tətbiqindən <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="APP_NAME">%2$s</xliff:g> tətbiqindən <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> və daha <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> qabarcıq"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Yuxarıya sola köçürün"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Yuxarıya sağa köçürün"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Aşağıya sola köçürün"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Aşağıya sağa köçürün"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> ayarları"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Yumrucuğu ləğv edin"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Söhbəti yumrucuqda göstərmə"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Yumrucuqlardan istifadə edərək söhbət edin"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Yeni söhbətlər üzən nişanlar və ya yumrucuqlar kimi görünür. Yumrucuğu açmaq üçün toxunun. Hərəkət etdirmək üçün sürüşdürün."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Yumrucuqları istənilən vaxt idarə edin"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Bu tətbiqdə yumrucuqları deaktiv etmək üçün \"İdarə edin\" seçiminə toxunun"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Yumrucuqlar yoxdur"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Son yumrucuqlar və buraxılmış yumrucuqlar burada görünəcək"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Qabarcıq"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"İdarə edin"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Qabarcıqdan imtina edilib."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-az/strings_tv.xml b/libs/WindowManager/Shell/res/values-az/strings_tv.xml
new file mode 100644
index 0000000..58e9d10
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-az/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Başlıqsız proqram)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"PIP bağlayın"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Tam ekran"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-b+sr+Latn/strings.xml b/libs/WindowManager/Shell/res/values-b+sr+Latn/strings.xml
new file mode 100644
index 0000000..9b2c49a
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-b+sr+Latn/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Zatvori"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Proširi"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Podešavanja"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Meni"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> je slika u slici"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Ako ne želite da <xliff:g id="NAME">%s</xliff:g> koristi ovu funkciju, dodirnite da biste otvorili podešavanja i isključili je."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Pusti"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Pauziraj"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Pređi na sledeće"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Pređi na prethodno"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Promenite veličinu"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Aplikacija ne podržava podeljeni ekran."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Aplikacija možda neće funkcionisati na sekundarnom ekranu."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Aplikacija ne podržava pokretanje na sekundarnim ekranima."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Razdelnik podeljenog ekrana"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Režim celog ekrana za levi ekran"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Levi ekran 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Levi ekran 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Levi ekran 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Režim celog ekrana za donji ekran"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Režim celog ekrana za gornji ekran"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Gornji ekran 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Gornji ekran 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Gornji ekran 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Režim celog ekrana za donji ekran"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Podešavanja za <xliff:g id="APP_NAME">%1$s</xliff:g> oblačiće"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Preklapanje"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Dodaj ponovo u grupu"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> iz aplikacije <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> iz aplikacije <xliff:g id="APP_NAME">%2$s</xliff:g> i još <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Premesti gore levo"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Premesti gore desno"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Premesti dole levo"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Premesti dole desno"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"Podešavanja za <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Odbaci oblačić"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Ne koristi oblačiće za konverzaciju"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Ćaskajte u oblačićima"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Nove konverzacije se prikazuju kao plutajuće ikone ili oblačići. Dodirnite da biste otvorili oblačić. Prevucite da biste ga premestili."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Kontrolišite oblačiće u bilo kom trenutku"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Dodirnite Upravljajte da biste isključili oblačiće iz ove aplikacije"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Nema nedavnih oblačića"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Ovde se prikazuju nedavni i odbačeni oblačići"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Oblačić"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Upravljajte"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Oblačić je odbačen."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-b+sr+Latn/strings_tv.xml b/libs/WindowManager/Shell/res/values-b+sr+Latn/strings_tv.xml
new file mode 100644
index 0000000..d341fd2
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-b+sr+Latn/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Program bez naslova)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Zatvori PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Ceo ekran"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-be/strings.xml b/libs/WindowManager/Shell/res/values-be/strings.xml
new file mode 100644
index 0000000..b42e2ce
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-be/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Закрыць"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Разгарнуць"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Налады"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Меню"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> з’яўляецца відарысам у відарысе"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Калі вы не хочаце, каб праграма <xliff:g id="NAME">%s</xliff:g> выкарыстоўвала гэту функцыю, дакраніцеся, каб адкрыць налады і адключыць яе."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Прайграць"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Прыпыніць"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Перайсці да наступнага"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Перайсці да папярэдняга"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Змяніць памер"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Праграма не падтрымлівае функцыю дзялення экрана."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Праграма можа не працаваць на дадатковых экранах."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Праграма не падтрымлівае запуск на дадатковых экранах."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Раздзяляльнік падзеленага экрана"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Левы экран – поўнаэкранны рэжым"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Левы экран – 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Левы экран – 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Левы экран – 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Правы экран – поўнаэкранны рэжым"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Верхні экран – поўнаэкранны рэжым"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Верхні экран – 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Верхні экран – 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Верхні экран – 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Ніжні экран – поўнаэкранны рэжым"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Налады ўсплывальных апавяшчэнняў у праграме \"<xliff:g id="APP_NAME">%1$s</xliff:g>\""</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Дадатковае меню"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Зноў дадаць у стос"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> ад праграмы \"<xliff:g id="APP_NAME">%2$s</xliff:g>\""</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> ад праграмы \"<xliff:g id="APP_NAME">%2$s</xliff:g>\" і яшчэ <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Перамясціць лявей і вышэй"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Перамясціце правей і вышэй"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Перамясціць лявей і ніжэй"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Перамясціць правей і ніжэй"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"Налады \"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>\""</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Адхіліць апавяшчэнне"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Не паказваць размову ў выглядзе ўсплывальных апавяшчэнняў"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Усплывальныя апавяшчэнні"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Новыя размовы будуць паказвацца як рухомыя значкі ці ўсплывальныя апавяшчэнні. Націсніце, каб адкрыць усплывальнае апавяшчэнне. Перацягніце яго, каб перамясціць."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Кіруйце ўсплывальнымі апавяшчэннямі ў любы час"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Каб выключыць усплывальныя апавяшчэнні з гэтай праграмы, націсніце \"Кіраваць\""</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Няма нядаўніх усплывальных апавяшчэнняў"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Нядаўнія і адхіленыя ўсплывальныя апавяшчэнні будуць паказаны тут"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Усплывальнае апавяшчэнне"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Кіраваць"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Усплывальнае апавяшчэнне адхілена."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-be/strings_tv.xml b/libs/WindowManager/Shell/res/values-be/strings_tv.xml
new file mode 100644
index 0000000..527b5af
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-be/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Праграма без назвы)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Закрыць PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Ва ўвесь экран"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-bg/strings.xml b/libs/WindowManager/Shell/res/values-bg/strings.xml
new file mode 100644
index 0000000..df25b8f
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-bg/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Затваряне"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Разгъване"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Настройки"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Меню"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> е в режима „Картина в картината“"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Ако не искате <xliff:g id="NAME">%s</xliff:g> да използва тази функция, докоснете, за да отворите настройките, и я изключете."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Пускане"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Поставяне на пауза"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Към следващия елемент"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Към предишния елемент"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Преоразмеряване"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Приложението не поддържа разделен екран."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Възможно е приложението да не работи на алтернативни дисплеи."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Приложението не поддържа използването на алтернативни дисплеи."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Разделител в режима за разделен екран"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Ляв екран: Показване на цял екран"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Ляв екран: 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Ляв екран: 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Ляв екран: 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Десен екран: Показване на цял екран"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Горен екран: Показване на цял екран"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Горен екран: 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Горен екран: 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Горен екран: 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Долен екран: Показване на цял екран"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Настройки за балончетата за <xliff:g id="APP_NAME">%1$s</xliff:g>"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Препълване"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Добавяне обратно към стека"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> от <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"„<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>“ от<xliff:g id="APP_NAME">%2$s</xliff:g> и още <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Преместване горе вляво"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Преместване горе вдясно"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Преместване долу вляво"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Преместване долу вдясно"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"Настройки за <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Отхвърляне на балончетата"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Без балончета за разговора"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Чат с балончета"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Новите разговори се показват като плаващи икони, или балончета. Докоснете балонче, за да го отворите, или го плъзнете, за да го преместите."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Управление на балончетата по всяко време"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Докоснете „Управление“, за да изключите балончетата от това приложение"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Няма скорошни балончета"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Скорошните и отхвърлените балончета ще се показват тук"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Балонче"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Управление"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Балончето е отхвърлено."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-bg/strings_tv.xml b/libs/WindowManager/Shell/res/values-bg/strings_tv.xml
new file mode 100644
index 0000000..388eb84
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-bg/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Програма без заглавие)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Затваряне на PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Цял екран"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-bn/strings.xml b/libs/WindowManager/Shell/res/values-bn/strings.xml
new file mode 100644
index 0000000..e92f8c9
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-bn/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"বন্ধ করুন"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"বড় করুন"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"সেটিংস"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"মেনু"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"ছবির-মধ্যে-ছবি তে <xliff:g id="NAME">%s</xliff:g> আছেন"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"<xliff:g id="NAME">%s</xliff:g> কে এই বৈশিষ্ট্যটি ব্যবহার করতে দিতে না চাইলে ট্যাপ করে সেটিংসে গিয়ে সেটি বন্ধ করে দিন।"</string>
+ <string name="pip_play" msgid="3496151081459417097">"চালান"</string>
+ <string name="pip_pause" msgid="690688849510295232">"বিরাম দিন"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"এগিয়ে যাওয়ার জন্য এড়িয়ে যান"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"পিছনে যাওয়ার জন্য এড়িয়ে যান"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"রিসাইজ করুন"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"অ্যাপ্লিকেশান বিভক্ত-স্ক্রিন সমর্থন করে না৷"</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"সেকেন্ডারি ডিসপ্লেতে অ্যাপটি কাজ নাও করতে পারে।"</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"সেকেন্ডারি ডিসপ্লেতে অ্যাপ লঞ্চ করা যাবে না।"</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"বিভক্ত-স্ক্রিন বিভাজক"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"বাঁ দিকের অংশ নিয়ে পূর্ণ স্ক্রিন"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"৭০% বাকি আছে"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"৫০% বাকি আছে"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"৩০% বাকি আছে"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"ডান দিকের অংশ নিয়ে পূর্ণ স্ক্রিন"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"উপর দিকের অংশ নিয়ে পূর্ণ স্ক্রিন"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"শীর্ষ ৭০%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"শীর্ষ ৫০%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"শীর্ষ ৩০%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"নীচের অংশ নিয়ে পূর্ণ স্ক্রিন"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"<xliff:g id="APP_NAME">%1$s</xliff:g> বাবলের জন্য সেটিংস"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"ওভারফ্লো"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"স্ট্যাকে আবার যোগ করুন"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="APP_NAME">%2$s</xliff:g> অ্যাপ থেকে <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="APP_NAME">%2$s</xliff:g> অ্যাপ এবং আরও <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g>টি থেকে <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"উপরে বাঁদিকে সরান"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"উপরে ডানদিকে সরান"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"নিচে বাঁদিকে সরান"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"নিচে ডান দিকে সরান"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> সেটিংস"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"বাবল খারিজ করুন"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"কথোপকথন বাবল হিসেবে দেখাবে না"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"বাবল ব্যবহার করে চ্যাট করুন"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"নতুন কথোপকথন ভেসে থাকা আইকন বা বাবল হিসেবে দেখানো হয়। বাবল খুলতে ট্যাপ করুন। সেটি সরাতে ধরে টেনে আনুন।"</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"যেকোনও সময় বাবল নিয়ন্ত্রণ করুন"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"এই অ্যাপ থেকে বাবল বন্ধ করতে \'ম্যানেজ করুন\' বিকল্প ট্যাপ করুন"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"কোনও সাম্প্রতিক বাবল নেই"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"সাম্প্রতিক ও বাতিল করা বাবল এখানে দেখা যাবে"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"বাবল"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"ম্যানেজ করুন"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"বাবল বাতিল করা হয়েছে।"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-bn/strings_tv.xml b/libs/WindowManager/Shell/res/values-bn/strings_tv.xml
new file mode 100644
index 0000000..783cb92
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-bn/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(শিরোনামহীন প্রোগ্রাম)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"PIP বন্ধ করুন"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"পূর্ণ স্ক্রিন"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-bs/strings.xml b/libs/WindowManager/Shell/res/values-bs/strings.xml
new file mode 100644
index 0000000..938e8b5
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-bs/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Zatvori"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Proširi"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Postavke"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Meni"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> je u načinu priakza Slika u slici"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Ako ne želite da <xliff:g id="NAME">%s</xliff:g> koristi ovu funkciju, dodirnite da otvorite postavke i isključite je."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Reproduciraj"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Pauziraj"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Preskoči na sljedeći"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Preskoči na prethodni"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Promjena veličine"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Aplikacija ne podržava dijeljenje ekrana."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Aplikacija možda neće raditi na sekundarnom ekranu."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Aplikacija ne podržava pokretanje na sekundarnim ekranima."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Razdjelnik ekrana"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Lijevo cijeli ekran"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Lijevo 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Lijevo 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Lijevo 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Desno cijeli ekran"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Gore cijeli ekran"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Gore 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Gore 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Gore 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Donji ekran kao cijeli ekran"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Postavke za oblačiće aplikacije <xliff:g id="APP_NAME">%1$s</xliff:g>"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Preklapanje"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Dodaj nazad u grupu"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> od aplikacije <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"Obavještenje <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> aplikacije <xliff:g id="APP_NAME">%2$s</xliff:g> i još <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Pomjeri gore lijevo"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Pomjerite gore desno"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Pomjeri dolje lijevo"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Pomjerite dolje desno"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"Postavke aplikacije <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Odbaci oblačić"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Nemoj prikazivati razgovor u oblačićima"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Chatajte koristeći oblačiće"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Novi razgovori se prikazuju kao plutajuće ikone ili oblačići. Dodirnite da otvorite oblačić. Prevucite da ga premjestite."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Upravljajte oblačićima u svakom trenutku"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Dodirnite Upravljaj da isključite oblačiće iz ove aplikacije"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Nema nedavnih oblačića"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Nedavni i odbačeni oblačići će se pojaviti ovdje"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Oblačić"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Upravljaj"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Oblačić je odbačen."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-bs/strings_tv.xml b/libs/WindowManager/Shell/res/values-bs/strings_tv.xml
new file mode 100644
index 0000000..6845ef46
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-bs/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Program bez naslova)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Zatvori PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Cijeli ekran"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-ca/strings.xml b/libs/WindowManager/Shell/res/values-ca/strings.xml
new file mode 100644
index 0000000..9cfdc55
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-ca/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Tanca"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Desplega"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Configuració"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Menú"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> està en pantalla en pantalla"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Si no vols que <xliff:g id="NAME">%s</xliff:g> utilitzi aquesta funció, toca per obrir la configuració i desactiva-la."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Reprodueix"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Posa en pausa"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Ves al següent"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Torna a l\'anterior"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Canvia la mida"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"L\'aplicació no admet la pantalla dividida."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"És possible que l\'aplicació no funcioni en una pantalla secundària."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"L\'aplicació no es pot obrir en pantalles secundàries."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Divisor de pantalles"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Pantalla esquerra completa"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Pantalla esquerra al 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Pantalla esquerra al 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Pantalla esquerra al 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Pantalla dreta completa"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Pantalla superior completa"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Pantalla superior al 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Pantalla superior al 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Pantalla superior al 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Pantalla inferior completa"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Configuració de les bombolles: <xliff:g id="APP_NAME">%1$s</xliff:g>"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Menú addicional"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Torna a afegir a la pila"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> de: <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> (<xliff:g id="APP_NAME">%2$s</xliff:g>) i <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> més"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Mou a dalt a l\'esquerra"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Mou a dalt a la dreta"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Mou a baix a l\'esquerra"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Mou a baix a la dreta"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"Configuració de l\'aplicació <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Ignora la bombolla"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"No mostris la conversa com a bombolla"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Xateja amb bombolles"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Les converses noves es mostren com a icones flotants o bombolles. Toca per obrir una bombolla. Arrossega-la per moure-la."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Controla les bombolles en qualsevol moment"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Toca Gestiona per desactivar les bombolles d\'aquesta aplicació"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"No hi ha bombolles recents"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Les bombolles recents i les ignorades es mostraran aquí"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Bombolla"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Gestiona"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"La bombolla s\'ha ignorat."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-ca/strings_tv.xml b/libs/WindowManager/Shell/res/values-ca/strings_tv.xml
new file mode 100644
index 0000000..ba89b0c
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-ca/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Programa sense títol)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Tanca PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Pantalla completa"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-cs/strings.xml b/libs/WindowManager/Shell/res/values-cs/strings.xml
new file mode 100644
index 0000000..973a5f9
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-cs/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Zavřít"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Rozbalit"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Nastavení"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Nabídka"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"Aplikace <xliff:g id="NAME">%s</xliff:g> je v režimu obraz v obraze"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Pokud nechcete, aby aplikace <xliff:g id="NAME">%s</xliff:g> tuto funkci používala, klepnutím otevřete nastavení a funkci vypněte."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Přehrát"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Pozastavit"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Přeskočit na další"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Přeskočit na předchozí"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Změnit velikost"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Aplikace nepodporuje režim rozdělené obrazovky."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Aplikace na sekundárním displeji nemusí fungovat."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Aplikace nepodporuje spuštění na sekundárních displejích."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Čára rozdělující obrazovku"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Levá část na celou obrazovku"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"70 % vlevo"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"50 % vlevo"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"30 % vlevo"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Pravá část na celou obrazovku"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Horní část na celou obrazovku"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"70 % nahoře"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"50 % nahoře"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"30 % nahoře"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Dolní část na celou obrazovku"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Nastavení bublin aplikace <xliff:g id="APP_NAME">%1$s</xliff:g>"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Rozbalovací nabídka"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Přidat zpět do sady"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"Oznámení <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> z aplikace <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> z aplikace <xliff:g id="APP_NAME">%2$s</xliff:g> a dalších (<xliff:g id="BUBBLE_COUNT">%3$d</xliff:g>)"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Přesunout vlevo nahoru"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Přesunout vpravo nahoru"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Přesunout vlevo dolů"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Přesunout vpravo dolů"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"Nastavení <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Zavřít bublinu"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Nezobrazovat konverzaci v bublinách"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Chatujte pomocí bublin"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Nové konverzace se zobrazují jako plovoucí ikony, neboli bubliny. Klepnutím bublinu otevřete. Přetažením ji posunete."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Nastavení bublin můžete kdykoli upravit"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Bubliny pro tuto aplikaci můžete vypnout klepnutím na Spravovat"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Žádné nedávné bubliny"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Zde se budou zobrazovat nedávné bubliny a zavřené bubliny"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Bublina"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Spravovat"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Bublina byla zavřena."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-cs/strings_tv.xml b/libs/WindowManager/Shell/res/values-cs/strings_tv.xml
new file mode 100644
index 0000000..c75ee13
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-cs/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Bez názvu)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Ukončit obraz v obraze (PIP)"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Celá obrazovka"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-da/strings.xml b/libs/WindowManager/Shell/res/values-da/strings.xml
new file mode 100644
index 0000000..cdde84c
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-da/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Luk"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Udvid"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Indstillinger"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Menu"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> vises som integreret billede"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Hvis du ikke ønsker, at <xliff:g id="NAME">%s</xliff:g> skal benytte denne funktion, kan du åbne indstillingerne og deaktivere den."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Afspil"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Sæt på pause"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Gå videre til næste"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Gå til forrige"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Rediger størrelse"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Appen understøtter ikke opdelt skærm."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Appen fungerer muligvis ikke på sekundære skærme."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Appen kan ikke åbnes på sekundære skærme."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Adskiller til opdelt skærm"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Vis venstre del i fuld skærm"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Venstre 70 %"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Venstre 50 %"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Venstre 30 %"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Vis højre del i fuld skærm"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Vis øverste del i fuld skærm"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Øverste 70 %"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Øverste 50 %"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Øverste 30 %"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Vis nederste del i fuld skærm"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Indstillinger for <xliff:g id="APP_NAME">%1$s</xliff:g>-bobler"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Overløb"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Føj til stak igen"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> fra <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> fra <xliff:g id="APP_NAME">%2$s</xliff:g> og <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> andre"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Flyt op til venstre"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Flyt op til højre"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Flyt ned til venstre"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Flyt ned til højre"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"Indstillinger for <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Afvis boble"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Vis ikke samtaler i bobler"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Chat ved hjælp af bobler"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Nye samtaler vises som svævende ikoner eller bobler. Tryk for at åbne boblen. Træk for at flytte den."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Styr bobler når som helst"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Tryk på Administrer for at deaktivere bobler fra denne app"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Ingen seneste bobler"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Nye bobler og afviste bobler vises her"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Boble"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Administrer"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Boblen blev lukket."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-da/strings_tv.xml b/libs/WindowManager/Shell/res/values-da/strings_tv.xml
new file mode 100644
index 0000000..edf10d7
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-da/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Program uden titel)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Luk integreret billede"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Fuld skærm"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-de/strings.xml b/libs/WindowManager/Shell/res/values-de/strings.xml
new file mode 100644
index 0000000..4979a40
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-de/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Schließen"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Maximieren"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Einstellungen"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Menü"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> ist in Bild im Bild"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Wenn du nicht möchtest, dass <xliff:g id="NAME">%s</xliff:g> diese Funktion verwendet, tippe, um die Einstellungen zu öffnen und die Funktion zu deaktivieren."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Wiedergeben"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Pausieren"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Vorwärts springen"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Rückwärts springen"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Größe anpassen"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Das Teilen des Bildschirms wird in dieser App nicht unterstützt."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Die App funktioniert auf einem sekundären Display möglicherweise nicht."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Die App unterstützt den Start auf sekundären Displays nicht."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Bildschirmteiler"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Vollbild links"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"70 % links"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"50 % links"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"30 % links"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Vollbild rechts"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Vollbild oben"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"70 % oben"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"50 % oben"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"30 % oben"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Vollbild unten"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Einstellungen für <xliff:g id="APP_NAME">%1$s</xliff:g>-Bubbles"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Mehr anzeigen"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Wieder dem Stapel hinzufügen"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> von <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> aus <xliff:g id="APP_NAME">%2$s</xliff:g> und <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> weiteren"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Nach oben links verschieben"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Nach rechts oben verschieben"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Nach unten links verschieben"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Nach unten rechts verschieben"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"Einstellungen für <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Bubble schließen"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Unterhaltung nicht als Bubble anzeigen"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Bubbles zum Chatten verwenden"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Neue Unterhaltungen erscheinen als unverankerte Symbole, \"Bubbles\" genannt. Wenn du die Bubble öffnen möchtest, tippe sie an. Wenn du sie verschieben möchtest, zieh an ihr."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Bubble-Einstellungen festlegen"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Tippe auf \"Verwalten\", um Bubbles für diese App zu deaktivieren"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Keine kürzlich geschlossenen Bubbles"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Hier werden aktuelle und geschlossene Bubbles angezeigt"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Bubble"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Verwalten"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Bubble verworfen."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-de/strings_tv.xml b/libs/WindowManager/Shell/res/values-de/strings_tv.xml
new file mode 100644
index 0000000..0432f1c
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-de/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Kein Sendungsname gefunden)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"PIP schließen"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Vollbild"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-el/strings.xml b/libs/WindowManager/Shell/res/values-el/strings.xml
new file mode 100644
index 0000000..2fa31f0
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-el/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Κλείσιμο"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Ανάπτυξη"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Ρυθμίσεις"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Μενού"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"Η λειτουργία picture-in-picture είναι ενεργή σε <xliff:g id="NAME">%s</xliff:g>."</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Εάν δεν θέλετε να χρησιμοποιείται αυτή η λειτουργία από την εφαρμογή <xliff:g id="NAME">%s</xliff:g>, πατήστε για να ανοίξετε τις ρυθμίσεις και απενεργοποιήστε την."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Αναπαραγωγή"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Παύση"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Μετάβαση στο επόμενο"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Μετάβαση στο προηγούμενο"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Αλλαγή μεγέθους"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Η εφαρμογή δεν υποστηρίζει διαχωρισμό οθόνης."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Η εφαρμογή ίσως να μην λειτουργήσει σε δευτερεύουσα οθόνη."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Η εφαρμογή δεν υποστηρίζει την εκκίνηση σε δευτερεύουσες οθόνες."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Διαχωριστικό οθόνης"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Αριστερή πλήρης οθόνη"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Αριστερή 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Αριστερή 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Αριστερή 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Δεξιά πλήρης οθόνη"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Πάνω πλήρης οθόνη"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Πάνω 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Πάνω 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Πάνω 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Κάτω πλήρης οθόνη"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Ρυθμίσεις για συννεφάκια <xliff:g id="APP_NAME">%1$s</xliff:g>"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Υπερχείλιση"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Προσθήκη ξανά στη στοίβα"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> από <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> από την εφαρμογή <xliff:g id="APP_NAME">%2$s</xliff:g> και <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> ακόμη"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Μετακίνηση επάνω αριστερά"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Μετακίνηση επάνω δεξιά"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Μετακίνηση κάτω αριστερά"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Μετακίνηση κάτω δεξιά"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"Ρυθμίσεις <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Παράβλ. για συννεφ."</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Να μην γίνει προβολή της συζήτησης σε συννεφάκια."</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Συζητήστε χρησιμοποιώντας συννεφάκια."</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Οι νέες συζητήσεις εμφανίζονται ως κινούμενα εικονίδια ή συννεφάκια. Πατήστε για να ανοίξετε το συννεφάκι. Σύρετε για να το μετακινήσετε."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Ελέγξτε τα συννεφάκια ανά πάσα στιγμή."</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Πατήστε Διαχείριση για να απενεργοποιήσετε τα συννεφάκια από αυτήν την εφαρμογή."</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Δεν υπάρχουν πρόσφατα συννεφάκια"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Τα πρόσφατα συννεφάκια και τα συννεφάκια που παραβλέψατε θα εμφανίζονται εδώ."</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Συννεφάκι"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Διαχείριση"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Το συννεφάκι παραβλέφθηκε."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-el/strings_tv.xml b/libs/WindowManager/Shell/res/values-el/strings_tv.xml
new file mode 100644
index 0000000..7e4466a
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-el/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Δεν υπάρχει τίτλος προγράμματος)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Κλείσιμο PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Πλήρης οθόνη"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-en-rAU/strings.xml b/libs/WindowManager/Shell/res/values-en-rAU/strings.xml
new file mode 100644
index 0000000..3a790ec
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-en-rAU/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Close"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Expand"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Settings"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Menu"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> is in picture-in-picture"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"If you don\'t want <xliff:g id="NAME">%s</xliff:g> to use this feature, tap to open settings and turn it off."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Play"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Pause"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Skip to next"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Skip to previous"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Resize"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"App does not support split-screen."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"App may not work on a secondary display."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"App does not support launch on secondary displays."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Split screen divider"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Left full screen"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Left 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Left 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Left 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Right full screen"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Top full screen"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Top 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Top 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Top 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Bottom full screen"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Settings for <xliff:g id="APP_NAME">%1$s</xliff:g> bubbles"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Overflow"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Add back to stack"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> from <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> from <xliff:g id="APP_NAME">%2$s</xliff:g> and <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> more"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Move top left"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Move top right"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Move bottom left"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Move bottom right"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> settings"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Dismiss bubble"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Don’t bubble conversation"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Chat using bubbles"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"New conversations appear as floating icons, or bubbles. Tap to open bubble. Drag to move it."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Control bubbles at any time"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Tap Manage to turn off bubbles from this app"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"No recent bubbles"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Recent bubbles and dismissed bubbles will appear here"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Bubble"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Manage"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Bubble dismissed."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-en-rAU/strings_tv.xml b/libs/WindowManager/Shell/res/values-en-rAU/strings_tv.xml
new file mode 100644
index 0000000..d1d8141
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-en-rAU/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(No title program)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Close PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Full screen"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-en-rCA/strings.xml b/libs/WindowManager/Shell/res/values-en-rCA/strings.xml
new file mode 100644
index 0000000..3a790ec
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-en-rCA/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Close"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Expand"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Settings"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Menu"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> is in picture-in-picture"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"If you don\'t want <xliff:g id="NAME">%s</xliff:g> to use this feature, tap to open settings and turn it off."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Play"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Pause"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Skip to next"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Skip to previous"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Resize"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"App does not support split-screen."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"App may not work on a secondary display."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"App does not support launch on secondary displays."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Split screen divider"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Left full screen"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Left 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Left 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Left 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Right full screen"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Top full screen"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Top 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Top 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Top 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Bottom full screen"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Settings for <xliff:g id="APP_NAME">%1$s</xliff:g> bubbles"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Overflow"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Add back to stack"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> from <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> from <xliff:g id="APP_NAME">%2$s</xliff:g> and <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> more"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Move top left"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Move top right"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Move bottom left"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Move bottom right"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> settings"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Dismiss bubble"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Don’t bubble conversation"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Chat using bubbles"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"New conversations appear as floating icons, or bubbles. Tap to open bubble. Drag to move it."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Control bubbles at any time"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Tap Manage to turn off bubbles from this app"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"No recent bubbles"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Recent bubbles and dismissed bubbles will appear here"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Bubble"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Manage"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Bubble dismissed."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-en-rCA/strings_tv.xml b/libs/WindowManager/Shell/res/values-en-rCA/strings_tv.xml
new file mode 100644
index 0000000..d1d8141
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-en-rCA/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(No title program)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Close PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Full screen"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-en-rGB/strings.xml b/libs/WindowManager/Shell/res/values-en-rGB/strings.xml
new file mode 100644
index 0000000..3a790ec
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-en-rGB/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Close"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Expand"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Settings"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Menu"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> is in picture-in-picture"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"If you don\'t want <xliff:g id="NAME">%s</xliff:g> to use this feature, tap to open settings and turn it off."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Play"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Pause"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Skip to next"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Skip to previous"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Resize"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"App does not support split-screen."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"App may not work on a secondary display."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"App does not support launch on secondary displays."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Split screen divider"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Left full screen"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Left 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Left 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Left 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Right full screen"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Top full screen"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Top 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Top 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Top 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Bottom full screen"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Settings for <xliff:g id="APP_NAME">%1$s</xliff:g> bubbles"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Overflow"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Add back to stack"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> from <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> from <xliff:g id="APP_NAME">%2$s</xliff:g> and <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> more"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Move top left"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Move top right"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Move bottom left"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Move bottom right"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> settings"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Dismiss bubble"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Don’t bubble conversation"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Chat using bubbles"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"New conversations appear as floating icons, or bubbles. Tap to open bubble. Drag to move it."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Control bubbles at any time"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Tap Manage to turn off bubbles from this app"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"No recent bubbles"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Recent bubbles and dismissed bubbles will appear here"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Bubble"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Manage"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Bubble dismissed."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-en-rGB/strings_tv.xml b/libs/WindowManager/Shell/res/values-en-rGB/strings_tv.xml
new file mode 100644
index 0000000..d1d8141
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-en-rGB/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(No title program)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Close PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Full screen"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-en-rIN/strings.xml b/libs/WindowManager/Shell/res/values-en-rIN/strings.xml
new file mode 100644
index 0000000..3a790ec
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-en-rIN/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Close"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Expand"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Settings"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Menu"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> is in picture-in-picture"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"If you don\'t want <xliff:g id="NAME">%s</xliff:g> to use this feature, tap to open settings and turn it off."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Play"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Pause"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Skip to next"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Skip to previous"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Resize"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"App does not support split-screen."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"App may not work on a secondary display."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"App does not support launch on secondary displays."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Split screen divider"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Left full screen"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Left 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Left 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Left 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Right full screen"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Top full screen"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Top 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Top 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Top 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Bottom full screen"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Settings for <xliff:g id="APP_NAME">%1$s</xliff:g> bubbles"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Overflow"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Add back to stack"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> from <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> from <xliff:g id="APP_NAME">%2$s</xliff:g> and <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> more"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Move top left"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Move top right"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Move bottom left"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Move bottom right"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> settings"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Dismiss bubble"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Don’t bubble conversation"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Chat using bubbles"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"New conversations appear as floating icons, or bubbles. Tap to open bubble. Drag to move it."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Control bubbles at any time"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Tap Manage to turn off bubbles from this app"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"No recent bubbles"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Recent bubbles and dismissed bubbles will appear here"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Bubble"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Manage"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Bubble dismissed."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-en-rIN/strings_tv.xml b/libs/WindowManager/Shell/res/values-en-rIN/strings_tv.xml
new file mode 100644
index 0000000..d1d8141
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-en-rIN/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(No title program)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Close PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Full screen"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-en-rXC/strings.xml b/libs/WindowManager/Shell/res/values-en-rXC/strings.xml
new file mode 100644
index 0000000..d8b5b400
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-en-rXC/strings.xml
@@ -0,0 +1,72 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Close"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Expand"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Settings"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Menu"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> is in picture-in-picture"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"If you don\'t want <xliff:g id="NAME">%s</xliff:g> to use this feature, tap to open settings and turn it off."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Play"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Pause"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Skip to next"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Skip to previous"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Resize"</string>
+ <string name="dock_forced_resizable" msgid="1749750436092293116">"App may not work with split-screen."</string>
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"App does not support split-screen."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"App may not work on a secondary display."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"App does not support launch on secondary displays."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Split-screen divider"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Left full screen"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Left 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Left 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Left 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Right full screen"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Top full screen"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Top 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Top 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Top 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Bottom full screen"</string>
+ <string name="one_handed_tutorial_title" msgid="4583241688067426350">"Using one-handed mode"</string>
+ <string name="one_handed_tutorial_description" msgid="3486582858591353067">"To exit, swipe up from the bottom of the screen or tap anywhere above the app"</string>
+ <string name="accessibility_action_start_one_handed" msgid="5070337354072861426">"Start one-handed mode"</string>
+ <string name="accessibility_action_stop_one_handed" msgid="1369940261782179442">"Exit one-handed mode"</string>
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Settings for <xliff:g id="APP_NAME">%1$s</xliff:g> bubbles"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Overflow"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Add back to stack"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> from <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> from <xliff:g id="APP_NAME">%2$s</xliff:g> and <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> more"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Move top left"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Move top right"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Move bottom left"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Move bottom right"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> settings"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Dismiss bubble"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Don’t bubble conversation"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Chat using bubbles"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"New conversations appear as floating icons, or bubbles. Tap to open bubble. Drag to move it."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Control bubbles anytime"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Tap Manage to turn off bubbles from this app"</string>
+ <string name="bubbles_user_education_got_it" msgid="3382046149225428296">"Got it"</string>
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"No recent bubbles"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Recent bubbles and dismissed bubbles will appear here"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Bubble"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Manage"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Bubble dismissed."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-en-rXC/strings_tv.xml b/libs/WindowManager/Shell/res/values-en-rXC/strings_tv.xml
new file mode 100644
index 0000000..3f9ef0e
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-en-rXC/strings_tv.xml
@@ -0,0 +1,24 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="notification_channel_tv_pip" msgid="2576686079160402435">"Picture-in-Picture"</string>
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(No title program)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Close PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Full screen"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-es-rUS/strings.xml b/libs/WindowManager/Shell/res/values-es-rUS/strings.xml
new file mode 100644
index 0000000..2cac751
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-es-rUS/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Cerrar"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Expandir"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Configuración"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Menú"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> está en modo de Pantalla en pantalla"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Si no quieres que <xliff:g id="NAME">%s</xliff:g> use esta función, presiona para abrir la configuración y desactivarla."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Reproducir"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Pausar"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Siguiente"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Anterior"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Cambiar el tamaño"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"La app no es compatible con la función de pantalla dividida."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Es posible que la app no funcione en una pantalla secundaria."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"La app no puede iniciarse en pantallas secundarias."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Divisor de pantalla dividida"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Pantalla izquierda completa"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Izquierda: 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Izquierda: 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Izquierda: 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Pantalla derecha completa"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Pantalla superior completa"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Superior: 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Superior: 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Superior: 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Pantalla inferior completa"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Configuración para burbujas de <xliff:g id="APP_NAME">%1$s</xliff:g>"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Menú ampliado"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Volver a agregar a la pila"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> de <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> de <xliff:g id="APP_NAME">%2$s</xliff:g> y <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> más"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Ubicar arriba a la izquierda"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Ubicar arriba a la derecha"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Ubicar abajo a la izquierda"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Ubicar abajo a la derecha"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"Configuración de <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Descartar burbuja"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"No mostrar la conversación en burbujas"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Chat con burbujas"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Las conversaciones nuevas aparecen como elementos flotantes o burbujas. Presiona para abrir la burbuja. Arrástrala para moverla."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Controla las burbujas"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Presiona Administrar para desactivar las burbujas de esta app"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"No hay burbujas recientes"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Las burbujas recientes y las que se descartaron aparecerán aquí"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Cuadro"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Administrar"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Se descartó el cuadro."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-es-rUS/strings_tv.xml b/libs/WindowManager/Shell/res/values-es-rUS/strings_tv.xml
new file mode 100644
index 0000000..b275b6c
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-es-rUS/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Sin título de programa)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Cerrar PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Pantalla completa"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-es/strings.xml b/libs/WindowManager/Shell/res/values-es/strings.xml
new file mode 100644
index 0000000..7b5045a
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-es/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Cerrar"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Mostrar"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Ajustes"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Menú"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> está en imagen en imagen"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Si no quieres que <xliff:g id="NAME">%s</xliff:g> utilice esta función, toca la notificación para abrir los ajustes y desactivarla."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Reproducir"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Pausar"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Saltar al siguiente"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Volver al anterior"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Cambiar tamaño"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"La aplicación no admite la pantalla dividida."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Es posible que la aplicación no funcione en una pantalla secundaria."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"La aplicación no se puede abrir en pantallas secundarias."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Dividir la pantalla"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Pantalla izquierda completa"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Izquierda 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Izquierda 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Izquierda 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Pantalla derecha completa"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Pantalla superior completa"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Superior 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Superior 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Superior 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Pantalla inferior completa"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Ajustes de las burbujas de <xliff:g id="APP_NAME">%1$s</xliff:g>"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Menú adicional"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Volver a añadir a la pila"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> de <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> de <xliff:g id="APP_NAME">%2$s</xliff:g> y <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> más"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Mover arriba a la izquierda"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Mover arriba a la derecha"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Mover abajo a la izquierda."</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Mover abajo a la derecha"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"Ajustes de <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Cerrar burbuja"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"No mostrar conversación en burbuja"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Chatea con burbujas"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Las conversaciones nuevas aparecen como iconos flotantes llamadas \"burbujas\". Toca para abrir la burbuja. Arrastra para moverla."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Controla las burbujas"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Toca Gestionar para desactivar las burbujas de esta aplicación"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"No hay burbujas recientes"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Las burbujas recientes y las cerradas aparecerán aquí"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Burbuja"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Gestionar"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Burbuja cerrada."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-es/strings_tv.xml b/libs/WindowManager/Shell/res/values-es/strings_tv.xml
new file mode 100644
index 0000000..6a6ad13
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-es/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Programa sin título)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Cerrar PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Pantalla completa"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-et/strings.xml b/libs/WindowManager/Shell/res/values-et/strings.xml
new file mode 100644
index 0000000..2a261db
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-et/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Sule"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Laiendamine"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Seaded"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Menüü"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> on režiimis Pilt pildis"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Kui te ei soovi, et rakendus <xliff:g id="NAME">%s</xliff:g> seda funktsiooni kasutaks, puudutage seadete avamiseks ja lülitage see välja."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Esita"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Peata"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Järgmise juurde"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Eelmise juurde"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Suuruse muutmine"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Rakendus ei toeta jagatud ekraani."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Rakendus ei pruugi teisesel ekraanil töötada."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Rakendus ei toeta teisestel ekraanidel käivitamist."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Ekraanijagaja"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Vasak täisekraan"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Vasak: 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Vasak: 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Vasak: 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Parem täisekraan"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Ülemine täisekraan"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Ülemine: 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Ülemine: 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Ülemine: 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Alumine täisekraan"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Rakenduse <xliff:g id="APP_NAME">%1$s</xliff:g> mullide seaded"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Ületäide"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Lisa tagasi virna"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> rakendusest <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> rakenduselt <xliff:g id="APP_NAME">%2$s</xliff:g> ja veel <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Teisalda üles vasakule"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Teisalda üles paremale"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Teisalda alla vasakule"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Teisalda alla paremale"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"Rakenduse <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> seaded"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Sule mull"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Ära kuva vestlust mullina"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Vestelge mullide abil"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Uued vestlused kuvatakse hõljuvate ikoonidena ehk mullidena. Puudutage mulli avamiseks. Lohistage mulli, et seda liigutada."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Juhtige mulle igal ajal"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Selle rakenduse puhul mullide väljalülitamiseks puudutage valikut Halda"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Hiljutisi mulle pole"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Siin kuvatakse hiljutised ja suletud mullid."</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Mull"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Halda"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Mullist loobuti."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-et/strings_tv.xml b/libs/WindowManager/Shell/res/values-et/strings_tv.xml
new file mode 100644
index 0000000..26cfae2
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-et/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Programmi pealkiri puudub)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Sule PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Täisekraan"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-eu/strings.xml b/libs/WindowManager/Shell/res/values-eu/strings.xml
new file mode 100644
index 0000000..9167e8e
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-eu/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Itxi"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Zabaldu"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Ezarpenak"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Menua"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"Pantaila txiki gainjarrian dago <xliff:g id="NAME">%s</xliff:g>"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Ez baduzu nahi <xliff:g id="NAME">%s</xliff:g> zerbitzuak eginbide hori erabiltzea, sakatu hau ezarpenak ireki eta aukera desaktibatzeko."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Erreproduzitu"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Pausatu"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Saltatu hurrengora"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Saltatu aurrekora"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Aldatu tamaina"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Aplikazioak ez du onartzen pantaila zatitua"</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Baliteke aplikazioak ez funtzionatzea bigarren mailako pantailetan."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Aplikazioa ezin da abiarazi bigarren mailako pantailatan."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Pantaila-zatitzailea"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Ezarri ezkerraldea pantaila osoan"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Ezarri ezkerraldea % 70en"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Ezarri ezkerraldea % 50en"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Ezarri ezkerraldea % 30en"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Ezarri eskuinaldea pantaila osoan"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Ezarri goialdea pantaila osoan"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Ezarri goialdea % 70en"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Ezarri goialdea % 50en"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Ezarri goialdea % 30en"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Ezarri behealdea pantaila osoan"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"<xliff:g id="APP_NAME">%1$s</xliff:g> aplikazioaren ezarpenen burbuilak"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Gainezkatzea"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Gehitu berriro errenkadan"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> (<xliff:g id="APP_NAME">%2$s</xliff:g>)"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="APP_NAME">%2$s</xliff:g> aplikazioaren \"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>\" jakinarazpena, eta beste <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Eraman goialdera, ezkerretara"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Eraman goialdera, eskuinetara"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Eraman behealdera, ezkerretara"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Eraman behealdera, eskuinetara"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> aplikazioaren ezarpenak"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Baztertu burbuila"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Ez erakutsi elkarrizketak burbuila gisa"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Txateatu burbuilen bidez"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Elkarrizketa berriak ikono gainerakor edo burbuila gisa agertzen dira. Sakatu burbuila irekitzeko. Arrasta ezazu mugitzeko."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Kontrolatu burbuilak edonoiz"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Aplikazioaren burbuilak desaktibatzeko, sakatu Kudeatu"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Ez dago azkenaldiko burbuilarik"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Azken burbuilak eta baztertutakoak agertuko dira hemen"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Burbuila"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Kudeatu"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Baztertu da globoa."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-eu/strings_tv.xml b/libs/WindowManager/Shell/res/values-eu/strings_tv.xml
new file mode 100644
index 0000000..985677f
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-eu/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Programa izengabea)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Itxi PIPa"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Pantaila osoa"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-fa/strings.xml b/libs/WindowManager/Shell/res/values-fa/strings.xml
new file mode 100644
index 0000000..3f566bf
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-fa/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"بستن"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"بزرگ کردن"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"تنظیمات"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"منو"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> درحالت تصویر در تصویر است"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"اگر نمیخواهید <xliff:g id="NAME">%s</xliff:g> از این قابلیت استفاده کند، با ضربه زدن، تنظیمات را باز کنید و آن را خاموش کنید."</string>
+ <string name="pip_play" msgid="3496151081459417097">"پخش"</string>
+ <string name="pip_pause" msgid="690688849510295232">"توقف موقت"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"رد شدن به بعدی"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"رد شدن به قبلی"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"تغییر اندازه"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"برنامه از تقسیم صفحه پشتیبانی نمیکند."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"ممکن است برنامه در نمایشگر ثانویه کار نکند."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"برنامه از راهاندازی در نمایشگرهای ثانویه پشتیبانی نمیکند."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"تقسیمکننده صفحه"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"تمامصفحه چپ"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"٪۷۰ چپ"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"٪۵۰ چپ"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"٪۳۰ چپ"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"تمامصفحه راست"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"تمامصفحه بالا"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"٪۷۰ بالا"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"٪۵۰ بالا"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"٪۳۰ بالا"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"تمامصفحه پایین"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"تنظیمات برای حبابکهای <xliff:g id="APP_NAME">%1$s</xliff:g>"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"لبریزشده"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"افزودن برگشت به پشته"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> از <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> از <xliff:g id="APP_NAME">%2$s</xliff:g> و <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> مورد بیشتر"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"انتقال به بالا سمت راست"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"انتقال به بالا سمت چپ"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"انتقال به پایین سمت راست"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"انتقال به پایین سمت چپ"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"تنظیمات <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"رد کردن حبابک"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"مکالمه در حباب نشان داده نشود"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"گپ بااستفاده از حبابکها"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"مکالمههای جدید بهصورت نمادهای شناور یا حبابکها نشان داده میشوند. برای باز کردن حبابکها ضربه بزنید. برای جابهجایی، آن را بکشید."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"کنترل حبابکها در هرزمانی"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"برای خاموش کردن «حبابکها» از این برنامه، روی «مدیریت» ضربه بزنید"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"هیچ حبابک جدیدی وجود ندارد"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"حبابکها اخیر و حبابکها ردشده اینجا ظاهر خواهند شد"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"حباب"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"مدیریت"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"حبابک رد شد."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-fa/strings_tv.xml b/libs/WindowManager/Shell/res/values-fa/strings_tv.xml
new file mode 100644
index 0000000..c17dc33
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-fa/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(برنامه بدون عنوان)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"بستن PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"تمام صفحه"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-fi/strings.xml b/libs/WindowManager/Shell/res/values-fi/strings.xml
new file mode 100644
index 0000000..0aa4b40
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-fi/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Sulje"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Laajenna"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Asetukset"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Valikko"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> on kuva kuvassa ‑tilassa"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Jos et halua, että <xliff:g id="NAME">%s</xliff:g> voi käyttää tätä ominaisuutta, avaa asetukset napauttamalla ja poista se käytöstä."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Toista"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Keskeytä"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Siirry seuraavaan"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Siirry edelliseen"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Muuta kokoa"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Sovellus ei tue jaetun näytön tilaa."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Sovellus ei ehkä toimi toissijaisella näytöllä."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Sovellus ei tue käynnistämistä toissijaisilla näytöillä."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Näytön jakaja"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Vasen koko näytölle"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Vasen 70 %"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Vasen 50 %"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Vasen 30 %"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Oikea koko näytölle"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Yläosa koko näytölle"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Yläosa 70 %"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Yläosa 50 %"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Yläosa 30 %"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Alaosa koko näytölle"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Kuplien asetukset: <xliff:g id="APP_NAME">%1$s</xliff:g>"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Ylivuoto"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Lisää takaisin pinoon"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="APP_NAME">%2$s</xliff:g>: <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> (<xliff:g id="APP_NAME">%2$s</xliff:g>) ja <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> muuta"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Siirrä vasempaan yläreunaan"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Siirrä oikeaan yläreunaan"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Siirrä vasempaan alareunaan"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Siirrä oikeaan alareunaan"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>: asetukset"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Ohita kupla"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Älä näytä kuplia keskusteluista"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Chattaile kuplien avulla"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Uudet keskustelut näkyvät kelluvina kuvakkeina tai kuplina. Avaa kupla napauttamalla. Siirrä sitä vetämällä."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Muuta kuplien asetuksia milloin tahansa"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Valitse Ylläpidä, jos haluat poistaa kuplat käytöstä tästä sovelluksesta"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Ei viimeaikaisia kuplia"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Viimeaikaiset ja äskettäin ohitetut kuplat näkyvät täällä"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Kupla"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Ylläpidä"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Kupla ohitettu."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-fi/strings_tv.xml b/libs/WindowManager/Shell/res/values-fi/strings_tv.xml
new file mode 100644
index 0000000..55c1680
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-fi/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Nimetön)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Sulje PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Koko näyttö"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-fr-rCA/strings.xml b/libs/WindowManager/Shell/res/values-fr-rCA/strings.xml
new file mode 100644
index 0000000..6a50593
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-fr-rCA/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Fermer"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Développer"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Paramètres"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Menu"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> est en mode d\'incrustation d\'image"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Si vous ne voulez pas que <xliff:g id="NAME">%s</xliff:g> utilise cette fonctionnalité, touchez l\'écran pour ouvrir les paramètres, puis désactivez-la."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Lire"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Interrompre"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Passer au suivant"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Revenir au précédent"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Redimensionner"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"L\'application n\'est pas compatible avec l\'écran partagé."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Il est possible que l\'application ne fonctionne pas sur un écran secondaire."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"L\'application ne peut pas être lancée sur des écrans secondaires."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Séparateur d\'écran partagé"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Plein écran à la gauche"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"70 % à la gauche"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"50 % à la gauche"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"30 % à la gauche"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Plein écran à la droite"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Plein écran dans le haut"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"70 % dans le haut"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"50 % dans le haut"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"30 % dans le haut"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Plein écran dans le bas"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Paramètres pour les bulles de l\'application <xliff:g id="APP_NAME">%1$s</xliff:g>"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Menu déroulant"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Replacer sur la pile"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> de <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> de <xliff:g id="APP_NAME">%2$s</xliff:g> et <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> autres"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Déplacer dans coin sup. gauche"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Déplacer dans coin sup. droit"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Déplacer dans coin inf. gauche"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Déplacer dans coin inf. droit"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"Paramètres <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Ignorer la bulle"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Ne pas afficher les conversations dans des bulles"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Clavarder en utilisant des bulles"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Les nouvelles conversations s\'affichent sous forme d\'icônes flottantes (de bulles). Touchez une bulle pour l\'ouvrir. Faites-la glisser pour la déplacer."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Paramètres des bulles"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Toucher Gérer pour désactiver les bulles de cette application"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Aucune bulle récente"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Les bulles récentes et les bulles ignorées s\'afficheront ici"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Bulle"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Gérer"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Bulle ignorée."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-fr-rCA/strings_tv.xml b/libs/WindowManager/Shell/res/values-fr-rCA/strings_tv.xml
new file mode 100644
index 0000000..5f813e6
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-fr-rCA/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Aucun programme de titre)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Fermer mode IDI"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Plein écran"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-fr/strings.xml b/libs/WindowManager/Shell/res/values-fr/strings.xml
new file mode 100644
index 0000000..fd6e743
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-fr/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Fermer"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Développer"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Paramètres"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Menu"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> est en mode Picture-in-picture"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Si vous ne voulez pas que l\'application <xliff:g id="NAME">%s</xliff:g> utilise cette fonctionnalité, appuyez ici pour ouvrir les paramètres et la désactiver."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Lecture"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Suspendre"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Passer au contenu suivant"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Passer au contenu précédent"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Redimensionner"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Application incompatible avec l\'écran partagé."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Il est possible que l\'application ne fonctionne pas sur un écran secondaire."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"L\'application ne peut pas être lancée sur des écrans secondaires."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Séparateur d\'écran partagé"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Écran de gauche en plein écran"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Écran de gauche à 70 %"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Écran de gauche à 50 %"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Écran de gauche à 30 %"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Écran de droite en plein écran"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Écran du haut en plein écran"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Écran du haut à 70 %"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Écran du haut à 50 %"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Écran du haut à 30 %"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Écran du bas en plein écran"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Paramètres des bulles de <xliff:g id="APP_NAME">%1$s</xliff:g>"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Dépassement"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Ajouter à nouveau l\'élément à la pile"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> de <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> de l\'application <xliff:g id="APP_NAME">%2$s</xliff:g> et <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> autres"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Déplacer en haut à gauche"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Déplacer en haut à droite"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Déplacer en bas à gauche"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Déplacer en bas à droite"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"Paramètres <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Fermer la bulle"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Ne pas afficher la conversation dans une bulle"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Chatter en utilisant des bulles"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Les nouvelles conversations s\'affichent sous forme d\'icônes flottantes ou bulles. Appuyez sur la bulle pour l\'ouvrir. Faites-la glisser pour la déplacer."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Contrôler les paramètres des bulles"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Appuyez sur \"Gérer\" pour désactiver les bulles de cette application"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Aucune bulle récente"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Les bulles récentes et ignorées s\'afficheront ici"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Bulle"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Gérer"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Bulle fermée."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-fr/strings_tv.xml b/libs/WindowManager/Shell/res/values-fr/strings_tv.xml
new file mode 100644
index 0000000..52d942d
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-fr/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Programme sans titre)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Fermer mode PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Plein écran"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-gl/strings.xml b/libs/WindowManager/Shell/res/values-gl/strings.xml
new file mode 100644
index 0000000..057881b
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-gl/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Pechar"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Despregar"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Configuración"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Menú"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> está na pantalla superposta"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Se non queres que <xliff:g id="NAME">%s</xliff:g> utilice esta función, toca a configuración para abrir as opcións e desactivar a función."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Reproducir"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Pausar"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Ir ao seguinte"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Ir ao anterior"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Cambiar tamaño"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"A aplicación non é compatible coa función de pantalla dividida."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"É posible que a aplicación non funcione nunha pantalla secundaria."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"A aplicación non se pode iniciar en pantallas secundarias."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Divisor de pantalla dividida"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Pantalla completa á esquerda"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"70 % á esquerda"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"50 % á esquerda"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"30 % á esquerda"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Pantalla completa á dereita"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Pantalla completa arriba"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"70 % arriba"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"50 % arriba"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"30 % arriba"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Pantalla completa abaixo"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Configuración das burbullas de <xliff:g id="APP_NAME">%1$s</xliff:g>"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Mostrar menú adicional"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Engadir de novo á pilla"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> de <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> de <xliff:g id="APP_NAME">%2$s</xliff:g> e <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> máis"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Mover á parte super. esquerda"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Mover á parte superior dereita"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Mover á parte infer. esquerda"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Mover á parte inferior dereita"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"Configuración de <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Ignorar burbulla"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Non mostrar a conversa como burbulla"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Chatear usando burbullas"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"As conversas novas aparecen como iconas flotantes ou burbullas. Toca para abrir a burbulla e arrastra para movela."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Controla as burbullas"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Para desactivar as burbullas nesta aplicación, toca Xestionar"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Non hai burbullas recentes"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"As burbullas recentes e ignoradas aparecerán aquí."</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Burbulla"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Xestionar"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Ignorouse a burbulla."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-gl/strings_tv.xml b/libs/WindowManager/Shell/res/values-gl/strings_tv.xml
new file mode 100644
index 0000000..a896d88
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-gl/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Programa sen título)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Pechar PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Pantalla completa"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-gu/strings.xml b/libs/WindowManager/Shell/res/values-gu/strings.xml
new file mode 100644
index 0000000..d9950aa
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-gu/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"બંધ કરો"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"વિસ્તૃત કરો"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"સેટિંગ"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"મેનૂ"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> ચિત્રમાં-ચિત્રની અંદર છે"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"જો તમે નથી ઇચ્છતા કે <xliff:g id="NAME">%s</xliff:g> આ સુવિધાનો ઉપયોગ કરે, તો સેટિંગ ખોલવા માટે ટૅપ કરો અને તેને બંધ કરો."</string>
+ <string name="pip_play" msgid="3496151081459417097">"ચલાવો"</string>
+ <string name="pip_pause" msgid="690688849510295232">"થોભાવો"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"આગલા પર જાઓ"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"પહેલાંના પર જાઓ"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"કદ બદલો"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"ઍપ્લિકેશન સ્ક્રીન-વિભાજનનું સમર્થન કરતી નથી."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"ઍપ્લિકેશન ગૌણ ડિસ્પ્લે પર કદાચ કામ ન કરે."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"ઍપ્લિકેશન ગૌણ ડિસ્પ્લે પર લૉન્ચનું સમર્થન કરતી નથી."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"સ્પ્લિટ-સ્ક્રીન વિભાજક"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"ડાબી પૂર્ણ સ્ક્રીન"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"ડાબે 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"ડાબે 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"ડાબે 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"જમણી સ્ક્રીન સ્ક્રીન"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"શીર્ષ પૂર્ણ સ્ક્રીન"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"શીર્ષ 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"શીર્ષ 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"શીર્ષ 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"તળિયાની પૂર્ણ સ્ક્રીન"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"<xliff:g id="APP_NAME">%1$s</xliff:g> બબલ માટેનાં સેટિંગ"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"ઓવરફ્લો"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"સ્ટૅકમાં ફરી ઉમેરો"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="APP_NAME">%2$s</xliff:g> તરફથી <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="APP_NAME">%2$s</xliff:g> અને વધુ <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> તરફથી <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"ઉપર ડાબે ખસેડો"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"ઉપર જમણે ખસેડો"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"નીચે ડાબે ખસેડો"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"નીચે જમણે ખસેડો"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> સેટિંગ"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"બબલને છોડી દો"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"વાતચીતને બબલ કરશો નહીં"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"બબલનો ઉપયોગ કરીને ચેટ કરો"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"નવી વાતચીત ફ્લોટિંગ આઇકન અથવા બબલ જેવી દેખાશે. બબલને ખોલવા માટે ટૅપ કરો. તેને ખસેડવા માટે ખેંચો."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"બબલને કોઈપણ સમયે નિયંત્રિત કરો"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"આ ઍપમાંથી બબલને બંધ કરવા માટે મેનેજ કરો પર ટૅપ કરો"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"તાજેતરના કોઈ બબલ નથી"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"એકદમ નવા બબલ અને છોડી દીધેલા બબલ અહીં દેખાશે"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"બબલ"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"મેનેજ કરો"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"બબલ છોડી દેવાયો."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-gu/strings_tv.xml b/libs/WindowManager/Shell/res/values-gu/strings_tv.xml
new file mode 100644
index 0000000..a5c0c31
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-gu/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(કોઈ ટાઇટલ પ્રોગ્રામ નથી)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"PIP બંધ કરો"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"પૂર્ણ સ્ક્રીન"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-hi/strings.xml b/libs/WindowManager/Shell/res/values-hi/strings.xml
new file mode 100644
index 0000000..b1117bd
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-hi/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"बंद करें"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"विस्तार करें"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"सेटिंग"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"मेन्यू"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> \"पिक्चर में पिक्चर\" के अंदर है"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"अगर आप नहीं चाहते कि <xliff:g id="NAME">%s</xliff:g> इस सुविधा का उपयोग करे, तो सेटिंग खोलने के लिए टैप करें और उसे बंद करें ."</string>
+ <string name="pip_play" msgid="3496151081459417097">"चलाएं"</string>
+ <string name="pip_pause" msgid="690688849510295232">"रोकें"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"अगले पर जाएं"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"पिछले पर जाएं"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"आकार बदलें"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"ऐप विभाजित स्क्रीन का समर्थन नहीं करता है."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"हो सकता है कि ऐप प्राइमरी (मुख्य) डिस्प्ले के अलावा बाकी दूसरे डिस्प्ले पर काम न करे."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"प्राइमरी (मुख्य) डिस्प्ले के अलावा बाकी दूसरे डिस्प्ले पर ऐप लॉन्च नहीं किया जा सकता."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"विभाजित स्क्रीन विभाजक"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"बाईं स्क्रीन को फ़ुल स्क्रीन बनाएं"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"बाईं स्क्रीन को 70% बनाएं"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"बाईं स्क्रीन को 50% बनाएं"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"बाईं स्क्रीन को 30% बनाएं"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"दाईं स्क्रीन को फ़ुल स्क्रीन बनाएं"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"ऊपर की स्क्रीन को फ़ुल स्क्रीन बनाएं"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"ऊपर की स्क्रीन को 70% बनाएं"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"ऊपर की स्क्रीन को 50% बनाएं"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"ऊपर की स्क्रीन को 30% बनाएं"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"नीचे की स्क्रीन को फ़ुल स्क्रीन बनाएं"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"<xliff:g id="APP_NAME">%1$s</xliff:g> बबल्स की सेटिंग"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"ओवरफ़्लो"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"स्टैक में वापस जोड़ें"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="APP_NAME">%2$s</xliff:g> से <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="APP_NAME">%2$s</xliff:g> और <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> अन्य ऐप्लिकेशन से <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"सबसे ऊपर बाईं ओर ले जाएं"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"सबसे ऊपर दाईं ओर ले जाएं"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"बाईं ओर सबसे नीचे ले जाएं"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"सबसे नीचे दाईं ओर ले जाएं"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> की सेटिंग"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"बबल खारिज करें"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"बातचीत को बबल न करें"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"बबल्स का इस्तेमाल करके चैट करें"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"नई बातचीत फ़्लोटिंग आइकॉन या बबल्स की तरह दिखेंगी. बबल को खोलने के लिए टैप करें. इसे एक जगह से दूसरी जगह ले जाने के लिए खींचें और छोड़ें."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"जब चाहें, बबल्स को कंट्रोल करें"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"इस ऐप्लिकेशन पर बबल्स को बंद करने के लिए \'प्रबंधित करें\' पर टैप करें"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"हाल ही के बबल्स मौजूद नहीं हैं"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"हाल ही के बबल्स और हटाए गए बबल्स यहां दिखेंगे"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"बबल"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"प्रबंधित करें"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"बबल खारिज किया गया."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-hi/strings_tv.xml b/libs/WindowManager/Shell/res/values-hi/strings_tv.xml
new file mode 100644
index 0000000..c2131eb
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-hi/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(कोई शीर्षक कार्यक्रम नहीं)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"PIP बंद करें"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"फ़ुल स्क्रीन"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-hr/strings.xml b/libs/WindowManager/Shell/res/values-hr/strings.xml
new file mode 100644
index 0000000..0f617f3
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-hr/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Zatvori"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Proširivanje"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Postavke"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Izbornik"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> jest na slici u slici"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Ako ne želite da aplikacija <xliff:g id="NAME">%s</xliff:g> upotrebljava tu značajku, dodirnite da biste otvorili postavke i isključili je."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Reproduciraj"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Pauziraj"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Preskoči na sljedeće"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Preskoči na prethodno"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Promjena veličine"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Aplikacija ne podržava podijeljeni zaslon."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Aplikacija možda neće funkcionirati na sekundarnom zaslonu."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Aplikacija ne podržava pokretanje na sekundarnim zaslonima."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Razdjelnik podijeljenog zaslona"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Lijevi zaslon u cijeli zaslon"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Lijevi zaslon na 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Lijevi zaslon na 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Lijevi zaslon na 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Desni zaslon u cijeli zaslon"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Gornji zaslon u cijeli zaslon"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Gornji zaslon na 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Gornji zaslon na 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Gornji zaslon na 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Donji zaslon u cijeli zaslon"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Postavke za oblačiće za aplikaciju <xliff:g id="APP_NAME">%1$s</xliff:g>"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Dodatno"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Dodajte natrag u nizove"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> iz aplikacije <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> iz aplikacije <xliff:g id="APP_NAME">%2$s</xliff:g> i još <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Premjesti u gornji lijevi kut"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Premjesti u gornji desni kut"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Premjesti u donji lijevi kut"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Premjestite u donji desni kut"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"Postavke za <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Odbaci oblačić"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Zaustavi razgovor u oblačićima"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Oblačići u chatu"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Novi razgovori pojavljuju se kao pomične ikone ili oblačići. Dodirnite za otvaranje oblačića. Povucite da biste ga premjestili."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Upravljanje oblačićima u svakom trenutku"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Dodirnite Upravljanje da biste isključili oblačiće iz ove aplikacije"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Nema nedavnih oblačića"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Ovdje će se prikazivati nedavni i odbačeni oblačići"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Oblačić"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Upravljanje"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Oblačić odbačen."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-hr/strings_tv.xml b/libs/WindowManager/Shell/res/values-hr/strings_tv.xml
new file mode 100644
index 0000000..76994a5
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-hr/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Program bez naslova)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Zatvori PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Cijeli zaslon"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-hu/strings.xml b/libs/WindowManager/Shell/res/values-hu/strings.xml
new file mode 100644
index 0000000..1fd87e6
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-hu/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Bezárás"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Kibontás"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Beállítások"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Menü"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"A(z) <xliff:g id="NAME">%s</xliff:g> kép a képben funkciót használ"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Ha nem szeretné, hogy a(z) <xliff:g id="NAME">%s</xliff:g> használja ezt a funkciót, koppintson a beállítások megnyitásához, és kapcsolja ki."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Lejátszás"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Szüneteltetés"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Ugrás a következőre"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Ugrás az előzőre"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Átméretezés"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Az alkalmazás nem támogatja az osztott képernyős nézetet."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Előfordulhat, hogy az alkalmazás nem működik másodlagos kijelzőn."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Az alkalmazást nem lehet másodlagos kijelzőn elindítani."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Elválasztó az osztott nézetben"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Bal oldali teljes képernyőre"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Bal oldali 70%-ra"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Bal oldali 50%-ra"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Bal oldali 30%-ra"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Jobb oldali teljes képernyőre"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Felső teljes képernyőre"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Felső 70%-ra"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Felső 50%-ra"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Felső 30%-ra"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Alsó teljes képernyőre"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"A(z) <xliff:g id="APP_NAME">%1$s</xliff:g>-buborékok beállításai"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"További elemeket tartalmazó menü"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Visszaküldés a verembe"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>, <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> a(z) <xliff:g id="APP_NAME">%2$s</xliff:g> alkalmazásból és <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> további"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Áthelyezés fel és balra"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Áthelyezés fel és jobbra"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Áthelyezés le és balra"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Áthelyezés le és jobbra"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> beállításai"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Buborék elvetése"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Ne jelenjen meg a beszélgetés buborékban"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Buborékokat használó csevegés"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Az új beszélgetések lebegő ikonként, vagyis buborékként jelennek meg. A buborék megnyitásához koppintson rá. Áthelyezéshez húzza a kívánt helyre."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Buborékok vezérlése bármikor"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"A Kezelés gombra koppintva kapcsolhatja ki az alkalmazásból származó buborékokat"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Nincsenek buborékok a közelmúltból"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"A legutóbbi és az elvetett buborékok itt jelennek majd meg"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Buborék"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Kezelés"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Buborék elvetve."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-hu/strings_tv.xml b/libs/WindowManager/Shell/res/values-hu/strings_tv.xml
new file mode 100644
index 0000000..5254ccc
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-hu/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Cím nélküli program)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"PIP bezárása"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Teljes képernyő"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-hy/strings.xml b/libs/WindowManager/Shell/res/values-hy/strings.xml
new file mode 100644
index 0000000..c374927
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-hy/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Փակել"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Ընդարձակել"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Կարգավորումներ"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Ընտրացանկ"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g>-ը «Նկար նկարի մեջ» ռեժիմում է"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Եթե չեք ցանկանում, որ <xliff:g id="NAME">%s</xliff:g>-ն օգտագործի այս գործառույթը, հպեք՝ կարգավորումները բացելու և այն անջատելու համար։"</string>
+ <string name="pip_play" msgid="3496151081459417097">"Նվագարկել"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Դադարեցնել"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Անցնել հաջորդին"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Վերադառնալ նախորդին"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Փոխել չափը"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Հավելվածը չի աջակցում էկրանի տրոհումը:"</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Հավելվածը կարող է չաշխատել լրացուցիչ էկրանի վրա"</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Հավելվածը չի աջակցում գործարկումը լրացուցիչ էկրանների վրա"</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Տրոհված էկրանի բաժանիչ"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Ձախ էկրանը՝ լիաէկրան"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Ձախ էկրանը՝ 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Ձախ էկրանը՝ 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Ձախ էկրանը՝ 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Աջ էկրանը՝ լիաէկրան"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Վերևի էկրանը՝ լիաէկրան"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Վերևի էկրանը՝ 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Վերևի էկրանը՝ 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Վերևի էկրանը՝ 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Ներքևի էկրանը՝ լիաէկրան"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"<xliff:g id="APP_NAME">%1$s</xliff:g>-ի ամպիկների կարգավորումներ"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Լրացուցիչ ընտրացանկ"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Նորից ավելացնել զտիչներում"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>՝ <xliff:g id="APP_NAME">%2$s</xliff:g>-ից"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>` <xliff:g id="APP_NAME">%2$s</xliff:g>-ից ու ևս <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> ամպիկ"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Տեղափոխել վերև՝ ձախ"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Տեղափոխել վերև՝ աջ"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Տեղափոխել ներքև՝ ձախ"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Տեղափոխել ներքև՝ աջ"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> – կարգավորումներ"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Փակել ամպիկը"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Զրույցը չցուցադրել ամպիկի տեսքով"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Զրույցի ամպիկներ"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Նոր զրույցները կհայտնվեն լողացող պատկերակների կամ ամպիկների տեսքով։ Հպեք՝ ամպիկը բացելու համար։ Քաշեք՝ այն տեղափոխելու համար։"</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Ամպիկների կարգավորումներ"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Հպեք «Կառավարել» կոճակին՝ այս հավելվածի ամպիկներն անջատելու համար։"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Ամպիկներ չկան"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Այստեղ կցուցադրվեն վերջերս օգտագործված և փակված ամպիկները, որոնք կկարողանաք հեշտությամբ վերաբացել"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Պղպջակ"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Կառավարել"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Ամպիկը փակվեց։"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-hy/strings_tv.xml b/libs/WindowManager/Shell/res/values-hy/strings_tv.xml
new file mode 100644
index 0000000..36680e9
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-hy/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Առանց վերնագրի ծրագիր)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Փակել PIP-ն"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Լիէկրան"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-in/strings.xml b/libs/WindowManager/Shell/res/values-in/strings.xml
new file mode 100644
index 0000000..2cb26b4
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-in/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Tutup"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Luaskan"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Setelan"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Menu"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> adalah picture-in-picture"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Jika Anda tidak ingin <xliff:g id="NAME">%s</xliff:g> menggunakan fitur ini, ketuk untuk membuka setelan dan menonaktifkannya."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Putar"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Jeda"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Lewati ke berikutnya"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Lewati ke sebelumnya"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Ubah ukuran"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"App tidak mendukung layar terpisah."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Aplikasi mungkin tidak berfungsi pada layar sekunder."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Aplikasi tidak mendukung peluncuran pada layar sekunder."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Pembagi layar terpisah"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Layar penuh di kiri"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Kiri 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Kiri 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Kiri 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Layar penuh di kanan"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Layar penuh di atas"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Atas 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Atas 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Atas 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Layar penuh di bawah"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Setelan untuk balon <xliff:g id="APP_NAME">%1$s</xliff:g>"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Tambahan"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Tambahkan kembali ke stack"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> dari <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> dari <xliff:g id="APP_NAME">%2$s</xliff:g> dan <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> lainnya"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Pindahkan ke kiri atas"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Pindahkan ke kanan atas"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Pindahkan ke kiri bawah"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Pindahkan ke kanan bawah"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"Setelan <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Tutup balon"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Jangan gunakan percakapan balon"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Chat dalam tampilan balon"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Percakapan baru muncul sebagai ikon mengambang, atau balon. Ketuk untuk membuka balon. Tarik untuk memindahkannya."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Kontrol balon kapan saja"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Ketuk Kelola untuk menonaktifkan balon dari aplikasi ini"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Tidak ada balon baru-baru ini"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Balon yang baru dipakai dan balon yang telah ditutup akan muncul di sini"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Balon"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Kelola"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Balon ditutup."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-in/strings_tv.xml b/libs/WindowManager/Shell/res/values-in/strings_tv.xml
new file mode 100644
index 0000000..30544b5
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-in/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Program tanpa judul)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Tutup PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Layar penuh"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-is/strings.xml b/libs/WindowManager/Shell/res/values-is/strings.xml
new file mode 100644
index 0000000..3b749bd
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-is/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Loka"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Stækka"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Stillingar"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Valmynd"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> er með mynd í mynd"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Ef þú vilt ekki að <xliff:g id="NAME">%s</xliff:g> noti þennan eiginleika skaltu ýta til að opna stillingarnar og slökkva á því."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Spila"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Gera hlé"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Fara á næsta"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Fara á fyrra"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Breyta stærð"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Forritið styður ekki að skjánum sé skipt."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Hugsanlegt er að forritið virki ekki á öðrum skjá."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Forrit styður ekki opnun á öðrum skjá."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Skjáskipting"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Vinstri á öllum skjánum"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Vinstri 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Vinstri 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Vinstri 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Hægri á öllum skjánum"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Efri á öllum skjánum"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Efri 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Efri 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Efri 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Neðri á öllum skjánum"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Stillingar fyrir blöðrur frá <xliff:g id="APP_NAME">%1$s</xliff:g>"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Yfirflæði"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Bæta aftur í stafla"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> frá <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"„<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>“ frá <xliff:g id="APP_NAME">%2$s</xliff:g> og <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> í viðbót"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Færa efst til vinstri"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Færa efst til hægri"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Færa neðst til vinstri"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Færðu neðst til hægri"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"Stillingar <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Loka blöðru"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Ekki setja samtal í blöðru"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Spjalla með blöðrum"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Ný samtöl birtast sem fljótandi tákn eða blöðrur. Ýttu til að opna blöðru. Dragðu hana til að færa."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Hægt er að stjórna blöðrum hvenær sem er"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Ýttu á „Stjórna“ til að slökkva á blöðrum frá þessu forriti"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Engar nýlegar blöðrur"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Nýlegar blöðrur og blöðrur sem þú hefur lokað birtast hér"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Blaðra"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Stjórna"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Blöðru lokað."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-is/strings_tv.xml b/libs/WindowManager/Shell/res/values-is/strings_tv.xml
new file mode 100644
index 0000000..ab3f3a6
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-is/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Efni án titils)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Loka mynd í mynd"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Allur skjárinn"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-it/strings.xml b/libs/WindowManager/Shell/res/values-it/strings.xml
new file mode 100644
index 0000000..bb4f9d7
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-it/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Chiudi"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Espandi"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Impostazioni"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Menu"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> è in Picture in picture"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Se non desideri che l\'app <xliff:g id="NAME">%s</xliff:g> utilizzi questa funzione, tocca per aprire le impostazioni e disattivarla."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Riproduci"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Metti in pausa"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Passa ai contenuti successivi"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Passa ai contenuti precedenti"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Ridimensiona"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"L\'app non supporta la modalità Schermo diviso."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"L\'app potrebbe non funzionare su un display secondario."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"L\'app non supporta l\'avvio su display secondari."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Strumento per schermo diviso"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Schermata sinistra a schermo intero"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Schermata sinistra al 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Schermata sinistra al 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Schermata sinistra al 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Schermata destra a schermo intero"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Schermata superiore a schermo intero"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Schermata superiore al 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Schermata superiore al 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Schermata superiore al 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Schermata inferiore a schermo intero"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Impostazioni per bolle <xliff:g id="APP_NAME">%1$s</xliff:g>"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Altre"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Aggiungi di nuovo all\'elenco"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> da <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> da <xliff:g id="APP_NAME">%2$s</xliff:g> e altre <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Sposta in alto a sinistra"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Sposta in alto a destra"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Sposta in basso a sinistra"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Sposta in basso a destra"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"Impostazioni <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Ignora bolla"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Non mettere la conversazione nella bolla"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Chatta utilizzando le bolle"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Le nuove conversazioni vengono visualizzate come icone mobili o bolle. Tocca per aprire la bolla. Trascinala per spostarla."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Controlla le bolle quando vuoi"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Tocca Gestisci per disattivare le bolle dall\'app"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Nessuna bolla recente"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Le bolle recenti e ignorate appariranno qui"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Fumetto"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Gestisci"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Fumetto ignorato."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-it/strings_tv.xml b/libs/WindowManager/Shell/res/values-it/strings_tv.xml
new file mode 100644
index 0000000..0d50580
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-it/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Programma senza titolo)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Chiudi PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Schermo intero"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-iw/strings.xml b/libs/WindowManager/Shell/res/values-iw/strings.xml
new file mode 100644
index 0000000..f163dcf
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-iw/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"סגירה"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"הרחב"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"הגדרות"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"תפריט"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> במצב תמונה בתוך תמונה"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"אם אינך רוצה שהתכונה הזו תשמש את <xliff:g id="NAME">%s</xliff:g>, יש להקיש כדי לפתוח את ההגדרות ולכבות את התכונה."</string>
+ <string name="pip_play" msgid="3496151081459417097">"הפעל"</string>
+ <string name="pip_pause" msgid="690688849510295232">"השהה"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"אפשר לדלג אל הבא"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"אפשר לדלג אל הקודם"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"שינוי גודל"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"האפליקציה אינה תומכת במסך מפוצל."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"ייתכן שהאפליקציה לא תפעל במסך משני."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"האפליקציה אינה תומכת בהפעלה במסכים משניים."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"מחלק מסך מפוצל"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"מסך שמאלי מלא"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"שמאלה 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"שמאלה 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"שמאלה 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"מסך ימני מלא"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"מסך עליון מלא"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"עליון 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"עליון 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"עליון 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"מסך תחתון מלא"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"הגדרות בשביל בועות של <xliff:g id="APP_NAME">%1$s</xliff:g>"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"גלישה"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"הוספה בחזרה לערימה"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> מהאפליקציה <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> מ-<xliff:g id="APP_NAME">%2$s</xliff:g> ועוד <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"העברה לפינה השמאלית העליונה"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"העברה לפינה הימנית העליונה"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"העברה לפינה השמאלית התחתונה"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"העברה לפינה הימנית התחתונה"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"הגדרות <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"סגירת בועה"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"אין להציג בועות לשיחה"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"לדבר בבועות"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"שיחות חדשות מופיעות כסמלים צפים, או בועות. יש להקיש כדי לפתוח בועה. יש לגרור כדי להזיז אותה."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"שליטה בבועות, בכל זמן"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"יש להקיש על \'ניהול\' כדי להשבית את הבועות מהאפליקציה הזו"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"אין בועות מהזמן האחרון"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"בועות אחרונות ובועות שנסגרו יופיעו כאן"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"בועה"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"ניהול"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"הבועה נסגרה."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-iw/strings_tv.xml b/libs/WindowManager/Shell/res/values-iw/strings_tv.xml
new file mode 100644
index 0000000..528d557
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-iw/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(תוכנית ללא כותרת)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"סגור PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"מסך מלא"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-ja/strings.xml b/libs/WindowManager/Shell/res/values-ja/strings.xml
new file mode 100644
index 0000000..c31d01c
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-ja/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"閉じる"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"展開"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"設定"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"メニュー"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g>はピクチャー イン ピクチャーで表示中です"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"<xliff:g id="NAME">%s</xliff:g>でこの機能を使用しない場合は、タップして設定を開いて OFF にしてください。"</string>
+ <string name="pip_play" msgid="3496151081459417097">"再生"</string>
+ <string name="pip_pause" msgid="690688849510295232">"一時停止"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"次へスキップ"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"前へスキップ"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"サイズ変更"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"アプリで分割画面がサポートされていません。"</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"アプリはセカンダリ ディスプレイでは動作しないことがあります。"</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"アプリはセカンダリ ディスプレイでの起動に対応していません。"</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"分割画面の分割線"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"左全画面"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"左 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"左 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"左 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"右全画面"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"上部全画面"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"上 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"上 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"上 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"下部全画面"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"<xliff:g id="APP_NAME">%1$s</xliff:g> のバブルの設定"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"オーバーフロー"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"スタックに戻す"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>(<xliff:g id="APP_NAME">%2$s</xliff:g>)"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>(<xliff:g id="APP_NAME">%2$s</xliff:g>)、他 <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> 件"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"左上に移動"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"右上に移動"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"左下に移動"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"右下に移動"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> の設定"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"バブルを閉じる"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"会話をバブルで表示しない"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"チャットでバブルを使う"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"新しい会話はフローティング アイコン(バブル)として表示されます。タップするとバブルが開きます。ドラッグしてバブルを移動できます。"</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"いつでもバブルを管理"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"このアプリからのバブルを OFF にするには、[管理] をタップしてください"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"最近閉じたバブルはありません"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"最近表示されたバブルや閉じたバブルが、ここに表示されます"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"バブル"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"管理"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"ふきだしが非表示になっています。"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-ja/strings_tv.xml b/libs/WindowManager/Shell/res/values-ja/strings_tv.xml
new file mode 100644
index 0000000..4a9cc40
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-ja/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(無題の番組)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"PIP を閉じる"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"全画面表示"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-ka/strings.xml b/libs/WindowManager/Shell/res/values-ka/strings.xml
new file mode 100644
index 0000000..9e86c8a
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-ka/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"დახურვა"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"გაშლა"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"პარამეტრები"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"მენიუ"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> იყენებს რეჟიმს „ეკრანი ეკრანში“"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"თუ არ გსურთ, რომ <xliff:g id="NAME">%s</xliff:g> ამ ფუნქციას იყენებდეს, აქ შეხებით შეგიძლიათ გახსნათ პარამეტრები და გამორთოთ ის."</string>
+ <string name="pip_play" msgid="3496151081459417097">"დაკვრა"</string>
+ <string name="pip_pause" msgid="690688849510295232">"დაპაუზება"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"შემდეგზე გადასვლა"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"წინაზე გადასვლა"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"ზომის შეცვლა"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"ეკრანის გაყოფა არ არის მხარდაჭერილი აპის მიერ."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"აპმა შეიძლება არ იმუშაოს მეორეულ ეკრანზე."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"აპს არ გააჩნია მეორეული ეკრანის მხარდაჭერა."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"გაყოფილი ეკრანის რეჟიმის გამყოფი"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"მარცხენა ნაწილის სრულ ეკრანზე გაშლა"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"მარცხენა ეკრანი — 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"მარცხენა ეკრანი — 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"მარცხენა ეკრანი — 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"მარჯვენა ნაწილის სრულ ეკრანზე გაშლა"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"ზედა ნაწილის სრულ ეკრანზე გაშლა"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"ზედა ეკრანი — 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"ზედა ეკრანი — 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"ზედა ეკრანი — 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"ქვედა ნაწილის სრულ ეკრანზე გაშლა"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"პარამეტრები <xliff:g id="APP_NAME">%1$s</xliff:g> ბუშტებისთვის"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"გადავსება"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"ისევ დამატება დასტაზე"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> <xliff:g id="APP_NAME">%2$s</xliff:g>-ისგან"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> <xliff:g id="APP_NAME">%2$s</xliff:g>-დან და კიდევ <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"ზევით და მარცხნივ გადატანა"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"გადაანაცვლეთ ზევით და მარჯვნივ"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"ქვევით და მარცხნივ გადატანა"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"გადაანაცვ. ქვემოთ და მარჯვნივ"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>-ის პარამეტრები"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"ბუშტის დახურვა"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"აიკრძალოს საუბრის ბუშტები"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"ჩეთი ბუშტების გამოყენებით"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"ახალი საუბრები გამოჩნდება როგორც მოტივტივე ხატულები ან ბუშტები. შეეხეთ ბუშტის გასახსნელად. გადაიტანეთ ჩავლებით."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"ბუშტების ნებისმიერ დროს გაკონტროლება"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"ამ აპის ბუშტების გამოსართავად შეეხეთ „მართვას“"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"ბოლო დროს გამოყენებული ბუშტები არ არის"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"აქ გამოჩნდება ბოლოდროინდელი ბუშტები და უარყოფილი ბუშტები"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"ბუშტი"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"მართვა"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"ბუშტი დაიხურა."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-ka/strings_tv.xml b/libs/WindowManager/Shell/res/values-ka/strings_tv.xml
new file mode 100644
index 0000000..be420a3
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-ka/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(პროგრამის სათაურის გარეშე)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"PIP-ის დახურვა"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"სრულ ეკრანზე"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-kk/strings.xml b/libs/WindowManager/Shell/res/values-kk/strings.xml
new file mode 100644
index 0000000..0cda01e
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-kk/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Жабу"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Жаю"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Параметрлер"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Mәзір"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> \"суреттегі сурет\" режимінде"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"<xliff:g id="NAME">%s</xliff:g> деген пайдаланушының бұл мүмкіндікті пайдалануын қаламасаңыз, параметрлерді түртіп ашыңыз да, оларды өшіріңіз."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Ойнату"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Кідірту"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Келесіге өту"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Алдыңғысына оралу"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Өлшемін өзгерту"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Қодланба бөлінген экранды қолдамайды."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Қолданба қосымша дисплейде жұмыс істемеуі мүмкін."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Қолданба қосымша дисплейлерде іске қосуды қолдамайды."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Бөлінген экран бөлгіші"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Сол жағын толық экранға шығару"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"70% сол жақта"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"50% сол жақта"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"30% сол жақта"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Оң жағын толық экранға шығару"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Жоғарғы жағын толық экранға шығару"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"70% жоғарғы жақта"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"50% жоғарғы жақта"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"30% жоғарғы жақта"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Төменгісін толық экранға шығару"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"<xliff:g id="APP_NAME">%1$s</xliff:g> қалқыма хабарларының параметрлері"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Қосымша мәзір"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Стекке қайта енгізу"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="APP_NAME">%2$s</xliff:g> жіберген хабарландыру: <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="APP_NAME">%2$s</xliff:g> қолданбасы жіберген <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> және тағы <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Жоғарғы сол жаққа жылжыту"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Жоғары оң жаққа жылжыту"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Төменгі сол жаққа жылжыту"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Төменгі оң жаққа жылжыту"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> параметрлері"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Қалқымалы хабарды жабу"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Әңгіменің қалқыма хабары көрсетілмесін"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Қалқыма хабарлар арқылы сөйлесу"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Жаңа әңгімелер қалқыма белгішелер немесе хабарлар түрінде көрсетіледі. Қалқыма хабарды ашу үшін түртіңіз. Жылжыту үшін сүйреңіз."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Қалқыма хабарларды реттеу"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Бұл қолданбадан қалқыма хабарларды өшіру үшін \"Басқару\" түймесін түртіңіз."</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Жақындағы қалқыма хабарлар жоқ"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Соңғы және жабылған қалқыма хабарлар осы жерде көрсетіледі."</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Көпіршік"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Басқару"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Қалқымалы анықтама өшірілді."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-kk/strings_tv.xml b/libs/WindowManager/Shell/res/values-kk/strings_tv.xml
new file mode 100644
index 0000000..9b12cff
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-kk/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Атаусыз бағдарлама)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"PIP жабу"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Толық экран"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-km/strings.xml b/libs/WindowManager/Shell/res/values-km/strings.xml
new file mode 100644
index 0000000..d0b1876
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-km/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"បិទ"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"ពង្រីក"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"ការកំណត់"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"ម៉ឺនុយ"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> ស្ថិតក្នុងមុខងាររូបក្នុងរូប"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"ប្រសិនបើអ្នកមិនចង់ឲ្យ <xliff:g id="NAME">%s</xliff:g> ប្រើមុខងារនេះ សូមចុចបើកការកំណត់ រួចបិទវា។"</string>
+ <string name="pip_play" msgid="3496151081459417097">"លេង"</string>
+ <string name="pip_pause" msgid="690688849510295232">"ផ្អាក"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"រំលងទៅបន្ទាប់"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"រំលងទៅក្រោយ"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"ប្ដូរទំហំ"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"កម្មវិធីមិនគាំទ្រអេក្រង់បំបែកជាពីរទេ"</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"កម្មវិធីនេះប្រហែលជាមិនដំណើរការនៅលើអេក្រង់បន្ទាប់បន្សំទេ។"</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"កម្មវិធីនេះមិនអាចចាប់ផ្តើមនៅលើអេក្រង់បន្ទាប់បន្សំបានទេ។"</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"កម្មវិធីចែកអេក្រង់បំបែក"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"អេក្រង់ពេញខាងឆ្វេង"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"ឆ្វេង 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"ឆ្វេង 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"ឆ្វេង 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"អេក្រង់ពេញខាងស្តាំ"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"អេក្រង់ពេញខាងលើ"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"ខាងលើ 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"ខាងលើ 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"ខាងលើ 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"អេក្រង់ពេញខាងក្រោម"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"ការកំណត់សម្រាប់ពពុះ <xliff:g id="APP_NAME">%1$s</xliff:g>"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"ម៉ឺនុយបន្ថែម"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"បញ្ចូលទៅក្នុងគំនរវិញ"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> ពី <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> ពី <xliff:g id="APP_NAME">%2$s</xliff:g> និង <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> ទៀត"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"ផ្លាស់ទីទៅផ្នែកខាងលើខាងឆ្វេង"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"ផ្លាស់ទីទៅផ្នែកខាងលើខាងស្ដាំ"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"ផ្លាស់ទីទៅផ្នែកខាងក្រោមខាងឆ្វេង"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"ផ្លាស់ទីទៅផ្នែកខាងក្រោមខាងស្ដាំ"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"ការកំណត់ <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"ច្រានចោលពពុះ"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"កុំបង្ហាញការសន្ទនាជាពពុះ"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"ជជែកដោយប្រើពពុះ"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"ការសន្ទនាថ្មីៗបង្ហាញជាពពុះ ឬរូបអណ្ដែត។ ចុច ដើម្បីបើកពពុះ។ អូស ដើម្បីផ្លាស់ទីពពុះនេះ។"</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"គ្រប់គ្រងពពុះបានគ្រប់ពេល"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"ចុច \"គ្រប់គ្រង\" ដើម្បីបិទពពុះពីកម្មវិធីនេះ"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"មិនមានពពុះថ្មីៗទេ"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"ពពុះថ្មីៗ និងពពុះដែលបានបិទនឹងបង្ហាញនៅទីនេះ"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"ពពុះ"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"គ្រប់គ្រង"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"បានច្រានចោលសារលេចឡើង។"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-km/strings_tv.xml b/libs/WindowManager/Shell/res/values-km/strings_tv.xml
new file mode 100644
index 0000000..e1a673e
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-km/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(កម្មវិធីគ្មានចំណងជើង)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"បិទ PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"ពេញអេក្រង់"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-kn/strings.xml b/libs/WindowManager/Shell/res/values-kn/strings.xml
new file mode 100644
index 0000000..456dc06
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-kn/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"ಮುಚ್ಚಿ"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"ವಿಸ್ತೃತಗೊಳಿಸು"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"ಸೆಟ್ಟಿಂಗ್ಗಳು"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"ಮೆನು"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> ಚಿತ್ರದಲ್ಲಿ ಚಿತ್ರವಾಗಿದೆ"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"<xliff:g id="NAME">%s</xliff:g> ಈ ವೈಶಿಷ್ಟ್ಯ ಬಳಸುವುದನ್ನು ನೀವು ಬಯಸದಿದ್ದರೆ, ಸೆಟ್ಟಿಂಗ್ಗಳನ್ನು ತೆರೆಯಲು ಮತ್ತು ಅದನ್ನು ಆಫ್ ಮಾಡಲು ಟ್ಯಾಪ್ ಮಾಡಿ."</string>
+ <string name="pip_play" msgid="3496151081459417097">"ಪ್ಲೇ"</string>
+ <string name="pip_pause" msgid="690688849510295232">"ವಿರಾಮಗೊಳಿಸಿ"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"ಮುಂದಕ್ಕೆ ಸ್ಕಿಪ್ ಮಾಡಿ"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"ಹಿಂದಕ್ಕೆ ಸ್ಕಿಪ್ ಮಾಡಿ"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"ಮರುಗಾತ್ರಗೊಳಿಸಿ"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"ಅಪ್ಲಿಕೇಶನ್ ಸ್ಪ್ಲಿಟ್ ಸ್ಕ್ರೀನ್ ಅನ್ನು ಬೆಂಬಲಿಸುವುದಿಲ್ಲ."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"ಸೆಕೆಂಡರಿ ಡಿಸ್ಪ್ಲೇಗಳಲ್ಲಿ ಅಪ್ಲಿಕೇಶನ್ ಕಾರ್ಯ ನಿರ್ವಹಿಸದೇ ಇರಬಹುದು."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"ಸೆಕೆಂಡರಿ ಡಿಸ್ಪ್ಲೇಗಳಲ್ಲಿ ಪ್ರಾರಂಭಿಸುವಿಕೆಯನ್ನು ಅಪ್ಲಿಕೇಶನ್ ಬೆಂಬಲಿಸುವುದಿಲ್ಲ."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"ಸ್ಪ್ಲಿಟ್-ಪರದೆ ಡಿವೈಡರ್"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"ಎಡ ಪೂರ್ಣ ಪರದೆ"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"70% ಎಡಕ್ಕೆ"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"50% ಎಡಕ್ಕೆ"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"30% ಎಡಕ್ಕೆ"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"ಬಲ ಪೂರ್ಣ ಪರದೆ"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"ಮೇಲಿನ ಪೂರ್ಣ ಪರದೆ"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"70% ಮೇಲಕ್ಕೆ"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"50% ಮೇಲಕ್ಕೆ"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"30% ಮೇಲಕ್ಕೆ"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"ಕೆಳಗಿನ ಪೂರ್ಣ ಪರದೆ"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"<xliff:g id="APP_NAME">%1$s</xliff:g> ಬಬಲ್ಸ್ಗಾಗಿ ಸೆಟ್ಟಿಂಗ್ಗಳು"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"ಓವರ್ಫ್ಲೋ"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"ಸ್ಟ್ಯಾಕ್ಗೆ ಪುನಃ ಸೇರಿಸಿ"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="APP_NAME">%2$s</xliff:g> ಆ್ಯಪ್ನ <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="APP_NAME">%2$s</xliff:g> ಮತ್ತು <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> ಹೆಚ್ಚಿನವುಗಳ <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"ಎಡ ಮೇಲ್ಭಾಗಕ್ಕೆ ಸರಿಸಿ"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"ಬಲ ಮೇಲ್ಭಾಗಕ್ಕೆ ಸರಿಸಿ"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"ಸ್ಕ್ರೀನ್ನ ಎಡ ಕೆಳಭಾಗಕ್ಕೆ ಸರಿಸಿ"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"ಕೆಳಗಿನ ಬಲಭಾಗಕ್ಕೆ ಸರಿಸಿ"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> ಸೆಟ್ಟಿಂಗ್ಗಳು"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"ಬಬಲ್ ವಜಾಗೊಳಿಸಿ"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"ಸಂಭಾಷಣೆಯನ್ನು ಬಬಲ್ ಮಾಡಬೇಡಿ"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"ಬಬಲ್ಸ್ ಬಳಸಿ ಚಾಟ್ ಮಾಡಿ"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"ಹೊಸ ಸಂಭಾಷಣೆಗಳು ತೇಲುವ ಐಕಾನ್ಗಳು ಅಥವಾ ಬಬಲ್ಸ್ ಆಗಿ ಗೋಚರಿಸುತ್ತವೆ. ಬಬಲ್ ತೆರೆಯಲು ಟ್ಯಾಪ್ ಮಾಡಿ. ಅದನ್ನು ಡ್ರ್ಯಾಗ್ ಮಾಡಲು ಎಳೆಯಿರಿ."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"ಯಾವುದೇ ಸಮಯದಲ್ಲಿ ಬಬಲ್ಸ್ ಅನ್ನು ನಿಯಂತ್ರಿಸಿ"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"ಈ ಆ್ಯಪ್ನಿಂದ ಬಬಲ್ಸ್ ಅನ್ನು ಆಫ್ ಮಾಡಲು ನಿರ್ವಹಿಸಿ ಟ್ಯಾಪ್ ಮಾಡಿ"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"ಯಾವುದೇ ಇತ್ತೀಚಿನ ಬಬಲ್ಸ್ ಇಲ್ಲ"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"ಇತ್ತೀಚಿನ ಬಬಲ್ಸ್ ಮತ್ತು ವಜಾಗೊಳಿಸಿದ ಬಬಲ್ಸ್ ಇಲ್ಲಿ ಗೋಚರಿಸುತ್ತವೆ"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"ಬಬಲ್"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"ನಿರ್ವಹಿಸಿ"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"ಬಬಲ್ ವಜಾಗೊಳಿಸಲಾಗಿದೆ."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-kn/strings_tv.xml b/libs/WindowManager/Shell/res/values-kn/strings_tv.xml
new file mode 100644
index 0000000..699824a
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-kn/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(ಶೀರ್ಷಿಕೆ ರಹಿತ ಕಾರ್ಯಕ್ರಮ)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"PIP ಮುಚ್ಚಿ"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"ಪೂರ್ಣ ಪರದೆ"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-ko/strings.xml b/libs/WindowManager/Shell/res/values-ko/strings.xml
new file mode 100644
index 0000000..57a2cb1
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-ko/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"닫기"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"펼치기"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"설정"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"메뉴"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g>에서 PIP 사용 중"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"<xliff:g id="NAME">%s</xliff:g>에서 이 기능이 사용되는 것을 원하지 않는 경우 탭하여 설정을 열고 기능을 사용 중지하세요."</string>
+ <string name="pip_play" msgid="3496151081459417097">"재생"</string>
+ <string name="pip_pause" msgid="690688849510295232">"일시중지"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"다음으로 건너뛰기"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"이전으로 건너뛰기"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"크기 조절"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"앱이 화면 분할을 지원하지 않습니다."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"앱이 보조 디스플레이에서 작동하지 않을 수도 있습니다."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"앱이 보조 디스플레이에서의 실행을 지원하지 않습니다."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"화면 분할기"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"왼쪽 화면 전체화면"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"왼쪽 화면 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"왼쪽 화면 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"왼쪽 화면 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"오른쪽 화면 전체화면"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"위쪽 화면 전체화면"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"위쪽 화면 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"위쪽 화면 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"위쪽 화면 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"아래쪽 화면 전체화면"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"<xliff:g id="APP_NAME">%1$s</xliff:g> 대화창 설정"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"더보기"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"스택에 다시 추가"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="APP_NAME">%2$s</xliff:g>의 <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="APP_NAME">%2$s</xliff:g> 외 <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g>개의 <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"왼쪽 상단으로 이동"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"오른쪽 상단으로 이동"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"왼쪽 하단으로 이동"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"오른쪽 하단으로 이동"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> 설정"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"대화창 닫기"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"대화를 대화창으로 표시하지 않기"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"대화창으로 채팅하기"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"새로운 대화가 플로팅 아이콘인 대화창으로 표시됩니다. 대화창을 열려면 탭하세요. 드래그하여 이동할 수 있습니다."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"언제든지 대화창을 제어하세요"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"이 앱에서 대화창을 사용 중지하려면 관리를 탭하세요."</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"최근 대화창 없음"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"최근 대화창과 내가 닫은 대화창이 여기에 표시됩니다."</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"버블"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"관리"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"대화창을 닫았습니다."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-ko/strings_tv.xml b/libs/WindowManager/Shell/res/values-ko/strings_tv.xml
new file mode 100644
index 0000000..827561e
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-ko/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(제목 없는 프로그램)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"PIP 닫기"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"전체화면"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-ky/strings.xml b/libs/WindowManager/Shell/res/values-ky/strings.xml
new file mode 100644
index 0000000..6862aa1
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-ky/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Жабуу"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Жайып көрсөтүү"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Жөндөөлөр"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Меню"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> – сүрөт ичиндеги сүрөт"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Эгер <xliff:g id="NAME">%s</xliff:g> колдонмосу бул функцияны пайдаланбасын десеңиз, жөндөөлөрдү ачып туруп, аны өчүрүп коюңуз."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Ойнотуу"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Тындыруу"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Кийинкисине өткөрүп жиберүү"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Мурункусуна өткөрүп жиберүү"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Өлчөмүн өзгөртүү"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Колдонмодо экран бөлүнбөйт."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Колдонмо кошумча экранда иштебей коюшу мүмкүн."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Колдонмону кошумча экрандарда иштетүүгө болбойт."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Экранды бөлгүч"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Сол жактагы экранды толук экран режимине өткөрүү"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Сол жактагы экранды 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Сол жактагы экранды 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Сол жактагы экранды 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Оң жактагы экранды толук экран режимине өткөрүү"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Үстүнкү экранды толук экран режимине өткөрүү"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Үстүнкү экранды 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Үстүнкү экранды 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Үстүнкү экранды 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Ылдыйкы экранды толук экран режимине өткөрүү"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"<xliff:g id="APP_NAME">%1$s</xliff:g> калкып чыкма билдирмелер жөндөөлөрү"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Кошумча меню"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Кайра топтомго кошуу"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="APP_NAME">%2$s</xliff:g> колдонмосунан <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="APP_NAME">%2$s</xliff:g> жана дагы <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> колдонмодон <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Жогорку сол жакка жылдыруу"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Жогорку оң жакка жылдырыңыз"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Төмөнкү сол жакка жылдыруу"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Төмөнкү оң жакка жылдырыңыз"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> жөндөөлөрү"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Калкып чыкма билдирмени жабуу"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Жазышууда калкып чыкма билдирмелер көрүнбөсүн"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Калкып чыкма билдирмелер аркылуу маектешүү"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Жаңы жазышуулар калкыма сүрөтчөлөр же калкып чыкма билдирмелер түрүндө көрүнөт. Калкып чыкма билдирмелерди ачуу үчүн таптап коюңуз. Жылдыруу үчүн сүйрөңүз."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Калкып чыкма билдирмелерди каалаган убакта көзөмөлдөңүз"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Бул колдонмодогу калкып чыкма билдирмелерди өчүрүү үчүн, \"Башкарууну\" басыңыз"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Азырынча эч нерсе жок"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Акыркы жана жабылган калкып чыкма билдирмелер ушул жерде көрүнөт"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Көбүк"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Башкаруу"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Калкып чыкма билдирме жабылды."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-ky/strings_tv.xml b/libs/WindowManager/Shell/res/values-ky/strings_tv.xml
new file mode 100644
index 0000000..68376b1
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-ky/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Аталышы жок программа)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"PIP\'ти жабуу"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Толук экран"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-lo/strings.xml b/libs/WindowManager/Shell/res/values-lo/strings.xml
new file mode 100644
index 0000000..2973414
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-lo/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"ປິດ"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"ຂະຫຍາຍ"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"ການຕັ້ງຄ່າ"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"ເມນູ"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> ແມ່ນເປັນການສະແດງຜົນຫຼາຍຢ່າງພ້ອມກັນ"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"ຫາກທ່ານບໍ່ຕ້ອງການ <xliff:g id="NAME">%s</xliff:g> ໃຫ້ໃຊ້ຄຸນສົມບັດນີ້, ໃຫ້ແຕະເພື່ອເປີດການຕັ້ງຄ່າ ແລ້ວປິດມັນໄວ້."</string>
+ <string name="pip_play" msgid="3496151081459417097">"ຫຼິ້ນ"</string>
+ <string name="pip_pause" msgid="690688849510295232">"ຢຸດຊົ່ວຄາວ"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"ຂ້າມໄປລາຍການໜ້າ"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"ຂ້າມໄປລາຍການກ່ອນນີ້"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"ປ່ຽນຂະໜາດ"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"ແອັບບໍ່ຮອງຮັບໜ້າຈໍແບບແຍກກັນ."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"ແອັບອາດບໍ່ສາມາດໃຊ້ໄດ້ໃນໜ້າຈໍທີສອງ."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"ແອັບບໍ່ຮອງຮັບການເປີດໃນໜ້າຈໍທີສອງ."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"ຕົວຂັ້ນການແບ່ງໜ້າຈໍ"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"ເຕັມໜ້າຈໍຊ້າຍ"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"ຊ້າຍ 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"ຊ້າຍ 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"ຊ້າຍ 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"ເຕັມໜ້າຈໍຂວາ"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"ເຕັມໜ້າຈໍເທິງສຸດ"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"ເທິງສຸດ 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"ເທິງສຸດ 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"ເທິງສຸດ 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"ເຕັມໜ້າຈໍລຸ່ມສຸດ"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"ການຕັ້ງຄ່າສຳລັບຟອງ <xliff:g id="APP_NAME">%1$s</xliff:g>"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"ລົ້ນ"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"ເພີ່ມກັບໄປຫາການວາງຊ້ອນກັນ"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> ຈາກ <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> ຈາກ <xliff:g id="APP_NAME">%2$s</xliff:g> ແລະ ອີກ <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"ຍ້າຍຊ້າຍເທິງ"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"ຍ້າຍຂວາເທິງ"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"ຍ້າຍຊ້າຍລຸ່ມ"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"ຍ້າຍຂວາລຸ່ມ"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"ການຕັ້ງຄ່າ <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"ປິດຟອງໄວ້"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"ຢ່າໃຊ້ຟອງໃນການສົນທະນາ"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"ສົນທະນາໂດຍໃຊ້ຟອງ"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"ການສົນທະນາໃໝ່ຈະປາກົດເປັນໄອຄອນ ຫຼື ຟອງແບບລອຍ. ແຕະເພື່ອເປີດຟອງ. ລາກເພື່ອຍ້າຍມັນ."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"ຄວບຄຸມຟອງຕອນໃດກໍໄດ້"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"ແຕະຈັດການ ເພື່ອປິດຟອງຈາກແອັບນີ້"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"ບໍ່ມີຟອງຫຼ້າສຸດ"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"ຟອງຫຼ້າສຸດ ແລະ ຟອງທີ່ປິດໄປຈະປາກົດຢູ່ບ່ອນນີ້"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"ຟອງ"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"ຈັດການ"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"ປິດ Bubble ໄສ້ແລ້ວ."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-lo/strings_tv.xml b/libs/WindowManager/Shell/res/values-lo/strings_tv.xml
new file mode 100644
index 0000000..d132256
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-lo/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(ໂປຣແກຣມບໍ່ມີຊື່)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"ປິດ PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"ເຕັມໜ້າຈໍ"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-lt/strings.xml b/libs/WindowManager/Shell/res/values-lt/strings.xml
new file mode 100644
index 0000000..007d069
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-lt/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Uždaryti"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Išskleisti"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Nustatymai"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Meniu"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> rodom. vaizdo vaizde"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Jei nenorite, kad „<xliff:g id="NAME">%s</xliff:g>“ naudotų šią funkciją, palietę atidarykite nustatymus ir išjunkite ją."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Leisti"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Pristabdyti"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Praleisti ir eiti į kitą"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Praleisti ir eiti į ankstesnį"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Pakeisti dydį"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Programoje nepalaikomas skaidytas ekranas."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Programa gali neveikti antriniame ekrane."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Programa nepalaiko paleisties antriniuose ekranuose."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Skaidyto ekrano daliklis"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Kairysis ekranas viso ekrano režimu"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Kairysis ekranas 70 %"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Kairysis ekranas 50 %"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Kairysis ekranas 30 %"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Dešinysis ekranas viso ekrano režimu"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Viršutinis ekranas viso ekrano režimu"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Viršutinis ekranas 70 %"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Viršutinis ekranas 50 %"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Viršutinis ekranas 30 %"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Apatinis ekranas viso ekrano režimu"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"„<xliff:g id="APP_NAME">%1$s</xliff:g>“ burbulų nustatymai"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Perpildymas"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Pridėti atgal į krūvą"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"„<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>“ iš „<xliff:g id="APP_NAME">%2$s</xliff:g>“"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"„<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>“ iš „<xliff:g id="APP_NAME">%2$s</xliff:g>“ ir dar <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Perkelti į viršų kairėje"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Perkelti į viršų dešinėje"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Perkelti į apačią kairėje"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Perkelti į apačią dešinėje"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"„<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>“ nustatymai"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Atsisakyti burbulo"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Nerodyti pokalbio burbule"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Pokalbis naudojant burbulus"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Nauji pokalbiai rodomi kaip slankiosios piktogramos arba burbulai. Palieskite, kad atidarytumėte burbulą. Vilkite, kad perkeltumėte."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Bet kada valdyti burbulus"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Palieskite „Tvarkyti“, kad išjungtumėte burbulus šioje programoje"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Nėra naujausių burbulų"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Naujausi ir atsisakyti burbulai bus rodomi čia"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Debesėlis"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Tvarkyti"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Debesėlio atsisakyta."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-lt/strings_tv.xml b/libs/WindowManager/Shell/res/values-lt/strings_tv.xml
new file mode 100644
index 0000000..189f766
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-lt/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Programa be pavadinimo)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Uždaryti PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Visas ekranas"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-lv/strings.xml b/libs/WindowManager/Shell/res/values-lv/strings.xml
new file mode 100644
index 0000000..a7f9617
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-lv/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Aizvērt"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Izvērst"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Iestatījumi"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Izvēlne"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> ir attēlā attēlā"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Ja nevēlaties lietotnē <xliff:g id="NAME">%s</xliff:g> izmantot šo funkciju, pieskarieties, lai atvērtu iestatījumus un izslēgtu funkciju."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Atskaņot"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Apturēt"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Pāriet uz nākamo"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Pāriet uz iepriekšējo"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Mainīt lielumu"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Lietotnē netiek atbalstīta ekrāna sadalīšana."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Lietotne, iespējams, nedarbosies sekundārajā displejā."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Lietotnē netiek atbalstīta palaišana sekundārajos displejos."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Ekrāna sadalītājs"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Kreisā daļa pa visu ekrānu"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Pa kreisi 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Pa kreisi 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Pa kreisi 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Labā daļa pa visu ekrānu"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Augšdaļa pa visu ekrānu"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Augšdaļa 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Augšdaļa 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Augšdaļa 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Apakšdaļu pa visu ekrānu"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Lietotnes <xliff:g id="APP_NAME">%1$s</xliff:g> burbuļu iestatījumi"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Pārpilde"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Pievienot atpakaļ kopai"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> no: <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> no lietotnes “<xliff:g id="APP_NAME">%2$s</xliff:g>” un vēl <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Pārvietot augšpusē pa kreisi"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Pārvietot augšpusē pa labi"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Pārvietot apakšpusē pa kreisi"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Pārvietot apakšpusē pa labi"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"Lietotnes <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> iestatījumi"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Nerādīt burbuli"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Nerādīt sarunu burbuļos"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Tērzēšana, izmantojot burbuļus"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Jaunas sarunas tiek rādītas kā peldošas ikonas vai burbuļi. Pieskarieties, lai atvērtu burbuli. Velciet, lai to pārvietotu."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Allaž pārvaldīt burbuļus"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Pieskarieties pogai “Pārvaldīt”, lai izslēgtu burbuļus no šīs lietotnes."</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Nav nesen aizvērtu burbuļu"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Šeit būs redzami nesen rādītie burbuļi un aizvērtie burbuļi"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Burbulis"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Pārvaldīt"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Burbulis ir noraidīts."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-lv/strings_tv.xml b/libs/WindowManager/Shell/res/values-lv/strings_tv.xml
new file mode 100644
index 0000000..614104b
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-lv/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Programma bez nosaukuma)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Aizvērt PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Pilnekrāna režīms"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-mk/strings.xml b/libs/WindowManager/Shell/res/values-mk/strings.xml
new file mode 100644
index 0000000..9edb7be
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-mk/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Затвори"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Проширете"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Поставки"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Мени"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> е во слика во слика"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Ако не сакате <xliff:g id="NAME">%s</xliff:g> да ја користи функцијава, допрете за да ги отворите поставките и да ја исклучите."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Пушти"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Паузирај"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Прескокни до следната"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Прескокни до претходната"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Промени големина"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Апликацијата не поддржува поделен екран."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Апликацијата може да не функционира на друг екран."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Апликацијата не поддржува стартување на други екрани."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Разделник на поделен екран"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Левиот на цел екран"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Левиот 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Левиот 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Левиот 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Десниот на цел екран"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Горниот на цел екран"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Горниот 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Горниот 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Горниот 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Долниот на цел екран"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Поставки за балончињата за <xliff:g id="APP_NAME">%1$s</xliff:g>"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Прелевање"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Додајте назад во stack"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> од <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> од <xliff:g id="APP_NAME">%2$s</xliff:g> и уште <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Премести горе лево"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Премести горе десно"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Премести долу лево"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Премести долу десно"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"Поставки за <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Отфрли балонче"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Не прикажувај го разговорот во балончиња"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Разговор во балончиња"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Новите разговори ќе се појавуваат како лебдечки икони или балончиња. Допрете за отворање на балончето. Повлечете за да го преместите."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Контролирајте ги балончињата во секое време"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Допрете „Управувајте“ за да ги исклучите балончињата од апликацијава"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Нема неодамнешни балончиња"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Неодамнешните и отфрлените балончиња ќе се појавуваат тука"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Балонче"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Управувајте"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Балончето е отфрлено."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-mk/strings_tv.xml b/libs/WindowManager/Shell/res/values-mk/strings_tv.xml
new file mode 100644
index 0000000..c279f79
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-mk/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Програма без наслов)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Затвори PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Цел екран"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-ml/strings.xml b/libs/WindowManager/Shell/res/values-ml/strings.xml
new file mode 100644
index 0000000..dfa4b22
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-ml/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"അവസാനിപ്പിക്കുക"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"വികസിപ്പിക്കുക"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"ക്രമീകരണം"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"മെനു"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> ചിത്രത്തിനുള്ളിൽ ചിത്രം രീതിയിലാണ്"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"<xliff:g id="NAME">%s</xliff:g> ഈ ഫീച്ചർ ഉപയോഗിക്കേണ്ടെങ്കിൽ, ടാപ്പ് ചെയ്ത് ക്രമീകരണം തുറന്ന് അത് ഓഫാക്കുക."</string>
+ <string name="pip_play" msgid="3496151081459417097">"പ്ലേ ചെയ്യുക"</string>
+ <string name="pip_pause" msgid="690688849510295232">"താൽക്കാലികമായി നിർത്തുക"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"അടുത്തതിലേക്ക് പോകുക"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"മുമ്പത്തേതിലേക്ക് പോകുക"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"വലുപ്പം മാറ്റുക"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"സ്പ്ലിറ്റ്-സ്ക്രീനിനെ ആപ്പ് പിന്തുണയ്ക്കുന്നില്ല."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"രണ്ടാം ഡിസ്പ്ലേയിൽ ആപ്പ് പ്രവർത്തിച്ചേക്കില്ല."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"രണ്ടാം ഡിസ്പ്ലേകളിൽ സമാരംഭിക്കുന്നതിനെ ആപ്പ് അനുവദിക്കുന്നില്ല."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"സ്പ്ലിറ്റ്-സ്ക്രീൻ ഡിവൈഡർ"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"ഇടത് പൂർണ്ണ സ്ക്രീൻ"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"ഇടത് 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"ഇടത് 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"ഇടത് 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"വലത് പൂർണ്ണ സ്ക്രീൻ"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"മുകളിൽ പൂർണ്ണ സ്ക്രീൻ"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"മുകളിൽ 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"മുകളിൽ 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"മുകളിൽ 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"താഴെ പൂർണ്ണ സ്ക്രീൻ"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"<xliff:g id="APP_NAME">%1$s</xliff:g> ബബിളുകളുടെ ക്രമീകരണം"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"ഓവർഫ്ലോ"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"അടുക്കുകളിലേക്ക് തിരിച്ച് ചേർക്കുക"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="APP_NAME">%2$s</xliff:g>-ൽ നിന്നുള്ള <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="APP_NAME">%2$s</xliff:g> എന്നതിൽ നിന്നുള്ള <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>, <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> കൂടുതലും"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"മുകളിൽ ഇടതുഭാഗത്തേക്ക് നീക്കുക"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"മുകളിൽ വലതുഭാഗത്തേക്ക് നീക്കുക"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"ചുവടെ ഇടതുഭാഗത്തേക്ക് നീക്കുക"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"ചുവടെ വലതുഭാഗത്തേക്ക് നീക്കുക"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> ക്രമീകരണം"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"ബബിൾ ഡിസ്മിസ് ചെയ്യൂ"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"സംഭാഷണം ബബിൾ ചെയ്യരുത്"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"ബബിളുകൾ ഉപയോഗിച്ച് ചാറ്റ് ചെയ്യുക"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"പുതിയ സംഭാഷണങ്ങൾ ഫ്ലോട്ടിംഗ് ഐക്കണുകളോ ബബിളുകളോ ആയി ദൃശ്യമാവുന്നു. ബബിൾ തുറക്കാൻ ടാപ്പ് ചെയ്യൂ. ഇത് നീക്കാൻ വലിച്ചിടുക."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"ബബിളുകൾ ഏതുസമയത്തും നിയന്ത്രിക്കുക"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"ഈ ആപ്പിൽ നിന്നുള്ള ബബിളുകൾ ഓഫാക്കാൻ മാനേജ് ചെയ്യുക ടാപ്പ് ചെയ്യുക"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"അടുത്തിടെയുള്ള ബബിളുകൾ ഒന്നുമില്ല"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"അടുത്തിടെയുള്ള ബബിളുകൾ, ഡിസ്മിസ് ചെയ്ത ബബിളുകൾ എന്നിവ ഇവിടെ ദൃശ്യമാവും"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"ബബ്ൾ"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"മാനേജ് ചെയ്യുക"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"ബബ്ൾ ഡിസ്മിസ് ചെയ്തു."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-ml/strings_tv.xml b/libs/WindowManager/Shell/res/values-ml/strings_tv.xml
new file mode 100644
index 0000000..7aaf79f
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-ml/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(പേരില്ലാത്ത പ്രോഗ്രാം)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"PIP അടയ്ക്കുക"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"പൂര്ണ്ണ സ്ക്രീന്"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-mn/strings.xml b/libs/WindowManager/Shell/res/values-mn/strings.xml
new file mode 100644
index 0000000..071629f
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-mn/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Хаах"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Дэлгэх"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Тохиргоо"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Цэс"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> дэлгэцэн доторх дэлгэцэд байна"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Та <xliff:g id="NAME">%s</xliff:g>-д энэ онцлогийг ашиглуулахыг хүсэхгүй байвал тохиргоог нээгээд, үүнийг унтраана уу."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Тоглуулах"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Түр зогсоох"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Дараагийн медиад очих"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Өмнөх медиад очих"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Хэмжээг өөрчлөх"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Энэ апп нь дэлгэц хуваах тохиргоог дэмждэггүй."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Апп хоёрдогч дэлгэцэд ажиллахгүй."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Аппыг хоёрдогч дэлгэцэд эхлүүлэх боломжгүй."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"\"Дэлгэц хуваах\" хуваагч"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Зүүн талын бүтэн дэлгэц"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Зүүн 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Зүүн 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Зүүн 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Баруун талын бүтэн дэлгэц"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Дээд талын бүтэн дэлгэц"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Дээд 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Дээд 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Дээд 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Доод бүтэн дэлгэц"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"<xliff:g id="APP_NAME">%1$s</xliff:g>-н бөмбөлгүүдийн тохиргоо"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Халих"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Өрөлтөд буцааж нэмэх"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="APP_NAME">%2$s</xliff:g>-н <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="APP_NAME">%2$s</xliff:g>-н <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> болон бусад <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Зүүн дээш зөөх"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Баруун дээш зөөх"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Зүүн доош зөөх"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Баруун доош зөөх"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>-н тохиргоо"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Бөмбөлгийг хаах"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Харилцан яриаг бүү бөмбөлөг болго"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Бөмбөлөг ашиглан чатлаарай"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Шинэ харилцан яриа нь хөвөгч дүрс тэмдэг эсвэл бөмбөлөг хэлбэрээр харагддаг. Бөмбөлгийг нээхийн тулд товшино уу. Түүнийг зөөхийн тулд чирнэ үү."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Дурын үед бөмбөлгийг хянаарай"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Энэ аппын бөмбөлгүүдийг унтраахын тулд Удирдах дээр товшино уу"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Саяхны бөмбөлөг алга байна"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Саяхны бөмбөлгүүд болон үл хэрэгссэн бөмбөлгүүд энд харагдана"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Бөмбөлөг"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Удирдах"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Бөмбөлгийг үл хэрэгссэн."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-mn/strings_tv.xml b/libs/WindowManager/Shell/res/values-mn/strings_tv.xml
new file mode 100644
index 0000000..e4b0262
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-mn/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Гарчиггүй хөтөлбөр)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"PIP-г хаах"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Бүтэн дэлгэц"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-mr/strings.xml b/libs/WindowManager/Shell/res/values-mr/strings.xml
new file mode 100644
index 0000000..bd28756
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-mr/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"बंद करा"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"विस्तृत करा"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"सेटिंग्ज"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"मेनू"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> चित्रामध्ये चित्र मध्ये आहे"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"<xliff:g id="NAME">%s</xliff:g>ने हे वैशिष्ट्य वापरू नये असे तुम्हाला वाटत असल्यास, सेटिंग्ज उघडण्यासाठी टॅप करा आणि ते बंद करा."</string>
+ <string name="pip_play" msgid="3496151081459417097">"प्ले करा"</string>
+ <string name="pip_pause" msgid="690688849510295232">"थांबवा"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"डावलून पुढे जा"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"डावलून मागे जा"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"आकार बदला"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"अॅप स्क्रीन-विभाजनास समर्थन देत नाही."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"दुसऱ्या डिस्प्लेवर अॅप कदाचित चालणार नाही."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"दुसऱ्या डिस्प्लेवर अॅप लाँच होणार नाही."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"विभाजित-स्क्रीन विभाजक"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"डावी फुल स्क्रीन"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"डावी 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"डावी 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"डावी 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"उजवी फुल स्क्रीन"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"शीर्ष फुल स्क्रीन"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"शीर्ष 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"शीर्ष 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"शीर्ष 10"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"तळाशी फुल स्क्रीन"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"<xliff:g id="APP_NAME">%1$s</xliff:g> बबलसाठी सेटिंग्ज"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"ओव्हरफ्लो"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"स्टॅकमध्ये परत जोडा"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="APP_NAME">%2$s</xliff:g> कडून <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="APP_NAME">%2$s</xliff:g> आणि आणखी <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> कडून <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"वर डावीकडे हलवा"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"वर उजवीकडे हलवा"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"तळाशी डावीकडे हलवा"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"तळाशी उजवीकडे हलवा"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> सेटिंग्ज"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"बबल डिसमिस करा"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"संभाषणाला बबल करू नका"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"बबल वापरून चॅट करा"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"नवीन संभाषणे फ्लोटिंग आयकन किंवा बबल म्हणून दिसतात. बबल उघडण्यासाठी टॅप करा. हे हलवण्यासाठी ड्रॅग करा."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"बबल कधीही नियंत्रित करा"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"या अॅपमधून बबल बंद करण्यासाठी व्यवस्थापित करा वर टॅप करा"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"अलीकडील कोणतेही बबल नाहीत"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"अलीकडील बबल आणि डिसमिस केलेले बबल येथे दिसतील"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"बबल"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"व्यवस्थापित करा"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"बबल डिसमिस केला."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-mr/strings_tv.xml b/libs/WindowManager/Shell/res/values-mr/strings_tv.xml
new file mode 100644
index 0000000..d9fc3b1
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-mr/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(शीर्षक नसलेला कार्यक्रम)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"PIP बंद करा"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"फुल स्क्रीन"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-ms/strings.xml b/libs/WindowManager/Shell/res/values-ms/strings.xml
new file mode 100644
index 0000000..267809f
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-ms/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Tutup"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Kembangkan"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Tetapan"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Menu"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> terdapat dalam gambar dalam gambar"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Jika anda tidak mahu <xliff:g id="NAME">%s</xliff:g> menggunakan ciri ini, ketik untuk membuka tetapan dan matikan ciri."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Main"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Jeda"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Langkau ke seterusnya"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Langkau ke sebelumnya"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Ubah saiz"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Apl tidak menyokong skrin pisah."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Apl mungkin tidak berfungsi pada paparan kedua."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Apl tidak menyokong pelancaran pada paparan kedua."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Pembahagi skrin pisah"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Skrin penuh kiri"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Kiri 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Kiri 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Kiri 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Skrin penuh kanan"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Skrin penuh atas"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Atas 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Atas 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Atas 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Skrin penuh bawah"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Tetapan untuk gelembung <xliff:g id="APP_NAME">%1$s</xliff:g>"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Limpahan"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Tambah kembali pada tindanan"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> daripada <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> daripada <xliff:g id="APP_NAME">%2$s</xliff:g> dan <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> lagi"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Alihkan ke atas sebelah kiri"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Alihkan ke atas sebelah kanan"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Alihkan ke bawah sebelah kiri"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Alihkan ke bawah sebelah kanan"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"Tetapan <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Ketepikan gelembung"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Jangan jadikan perbualan dalam bentuk gelembung"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Bersembang menggunakan gelembung"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Perbualan baharu muncul sebagai ikon terapung atau gelembung. Ketik untuk membuka gelembung. Seret untuk mengalihkan gelembung tersebut."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Kawal gelembung pada bila-bila masa"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Ketik Urus untuk mematikan gelembung daripada apl ini"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Tiada gelembung terbaharu"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Gelembung baharu dan gelembung yang diketepikan akan dipaparkan di sini"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Gelembung"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Urus"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Gelembung diketepikan."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-ms/strings_tv.xml b/libs/WindowManager/Shell/res/values-ms/strings_tv.xml
new file mode 100644
index 0000000..9597a79
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-ms/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Program tiada tajuk)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Tutup PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Skrin penuh"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-my/strings.xml b/libs/WindowManager/Shell/res/values-my/strings.xml
new file mode 100644
index 0000000..b913a6b
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-my/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"ပိတ်ရန်"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"ချဲ့ရန်"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"ဆက်တင်များ"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"မီနူး"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> သည် တစ်ခုပေါ် တစ်ခုထပ်၍ ဖွင့်ထားသည်"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"<xliff:g id="NAME">%s</xliff:g> အား ဤဝန်ဆောင်မှုကို အသုံးမပြုစေလိုလျှင် ဆက်တင်ကိုဖွင့်ရန် တို့ပြီး ၎င်းဝန်ဆောင်မှုကို ပိတ်လိုက်ပါ။"</string>
+ <string name="pip_play" msgid="3496151081459417097">"ဖွင့်ရန်"</string>
+ <string name="pip_pause" msgid="690688849510295232">"ခေတ္တရပ်ရန်"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"နောက်တစ်ခုသို့ ကျော်ရန်"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"ယခင်တစ်ခုသို့ ပြန်သွားရန်"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"အရွယ်အစားပြောင်းရန်"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"အက်ပ်သည် မျက်နှာပြင်ခွဲပြရန် ပံ့ပိုးထားခြင်းမရှိပါ။"</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"ဤအက်ပ်အနေဖြင့် ဒုတိယဖန်သားပြင်ပေါ်တွင် အလုပ်လုပ်မည် မဟုတ်ပါ။"</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"ဤအက်ပ်အနေဖြင့် ဖွင့်ရန်စနစ်ကို ဒုတိယဖန်သားပြင်မှ အသုံးပြုရန် ပံ့ပိုးမထားပါ။"</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"မျက်နှာပြင်ခွဲခြမ်း ပိုင်းခြားပေးသည့်စနစ်"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"ဘယ်ဘက် မျက်နှာပြင်အပြည့်"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"ဘယ်ဘက်မျက်နှာပြင် ၇၀%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"ဘယ်ဘက် မျက်နှာပြင် ၅၀%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"ဘယ်ဘက် မျက်နှာပြင် ၃၀%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"ညာဘက် မျက်နှာပြင်အပြည့်"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"အပေါ်ဘက် မျက်နှာပြင်အပြည့်"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"အပေါ်ဘက် မျက်နှာပြင် ၇၀%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"အပေါ်ဘက် မျက်နှာပြင် ၅၀%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"အပေါ်ဘက် မျက်နှာပြင် ၃၀%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"အောက်ခြေ မျက်နှာပြင်အပြည့်"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"<xliff:g id="APP_NAME">%1$s</xliff:g> ပူဖောင်းကွက်အတွက် ဆက်တင်များ"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"အပိုများပြရန်"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"ပူဖေါင်းတန်းသို့ ပြန်ထည့်ရန်"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="APP_NAME">%2$s</xliff:g> မှ <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="APP_NAME">%2$s</xliff:g> နှင့် နောက်ထပ် <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> ခုမှ <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"ဘယ်ဘက်ထိပ်သို့ ရွှေ့ရန်"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"ညာဘက်ထိပ်သို့ ရွှေ့ပါ"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"ဘယ်အောက်ခြေသို့ ရွှေ့ရန်"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"ညာအောက်ခြေသို့ ရွှေ့ပါ"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> ဆက်တင်များ"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"ပူဖောင်းကွက် ပယ်ရန်"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"စကားဝိုင်းကို ပူဖောင်းကွက် မပြုလုပ်ပါနှင့်"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"ပူဖောင်းကွက် သုံး၍ ချတ်လုပ်ခြင်း"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"စကားဝိုင်းအသစ်များကို မျောနေသည့် သင်္ကေတများ သို့မဟုတ် ပူဖောင်းကွက်များအဖြစ် မြင်ရပါမည်။ ပူဖောင်းကွက်ကိုဖွင့်ရန် တို့ပါ။ ရွှေ့ရန် ၎င်းကို ဖိဆွဲပါ။"</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"ပူဖောင်းကွက်ကို အချိန်မရွေး ထိန်းချုပ်ရန်"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"ဤအက်ပ်မှနေ၍ ပူဖောင်းများကို ပိတ်ရန်အတွက် \'စီမံရန်\' ကို တို့ပါ"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"လတ်တလော ပူဖောင်းကွက်များ မရှိပါ"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"လတ်တလော ပူဖောင်းကွက်များနှင့် ပိတ်လိုက်သော ပူဖောင်းကွက်များကို ဤနေရာတွင် မြင်ရပါမည်"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"ပူဖောင်းဖောက်သံ"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"စီမံရန်"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"ပူဖောင်းကွက် ဖယ်လိုက်သည်။"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-my/strings_tv.xml b/libs/WindowManager/Shell/res/values-my/strings_tv.xml
new file mode 100644
index 0000000..6d4d6f0
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-my/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(ခေါင်းစဉ်မဲ့ အစီအစဉ်)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"PIP ကိုပိတ်ပါ"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"မျက်နှာပြင် အပြည့်"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-nb/strings.xml b/libs/WindowManager/Shell/res/values-nb/strings.xml
new file mode 100644
index 0000000..cd601ea
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-nb/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Lukk"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Vis"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Innstillinger"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Meny"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> er i bilde-i-bilde"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Hvis du ikke vil at <xliff:g id="NAME">%s</xliff:g> skal bruke denne funksjonen, kan du trykke for å åpne innstillingene og slå den av."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Spill av"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Sett på pause"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Hopp til neste"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Hopp til forrige"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Endre størrelse"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Appen støtter ikke delt skjerm."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Appen fungerer kanskje ikke på en sekundær skjerm."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Appen kan ikke kjøres på sekundære skjermer."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Skilleelement for delt skjerm"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Utvid den venstre delen av skjermen til hele skjermen"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Sett størrelsen på den venstre delen av skjermen til 70 %"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Sett størrelsen på den venstre delen av skjermen til 50 %"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Sett størrelsen på den venstre delen av skjermen til 30 %"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Utvid den høyre delen av skjermen til hele skjermen"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Utvid den øverste delen av skjermen til hele skjermen"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Sett størrelsen på den øverste delen av skjermen til 70 %"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Sett størrelsen på den øverste delen av skjermen til 50 %"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Sett størrelsen på den øverste delen av skjermen til 30 %"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Utvid den nederste delen av skjermen til hele skjermen"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Innstillinger for <xliff:g id="APP_NAME">%1$s</xliff:g>-bobler"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Overflyt"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Legg tilbake i stabelen"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> fra <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> fra <xliff:g id="APP_NAME">%2$s</xliff:g> og <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> flere"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Flytt til øverst til venstre"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Flytt til øverst til høyre"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Flytt til nederst til venstre"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Flytt til nederst til høyre"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>-innstillinger"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Lukk boblen"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Ikke vis samtaler i bobler"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Chat med bobler"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Nye samtaler vises som flytende ikoner eller bobler. Trykk for å åpne bobler. Dra for å flytte dem."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Kontrollér bobler når som helst"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Trykk på Administrer for å slå av bobler for denne appen"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Ingen nylige bobler"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Nylige bobler og avviste bobler vises her"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Boble"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Administrer"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Boblen er avvist."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-nb/strings_tv.xml b/libs/WindowManager/Shell/res/values-nb/strings_tv.xml
new file mode 100644
index 0000000..849ccda
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-nb/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Program uten tittel)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Lukk PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Fullskjerm"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-ne/strings.xml b/libs/WindowManager/Shell/res/values-ne/strings.xml
new file mode 100644
index 0000000..0c68bab
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-ne/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"बन्द गर्नुहोस्"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"विस्तृत गर्नुहोस्"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"सेटिङहरू"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"मेनु"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> Picture-in-picture मा छ"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"तपाईं <xliff:g id="NAME">%s</xliff:g> ले सुविधा प्रयोग नगरोस् भन्ने चाहनुहुन्छ भने ट्याप गरेर सेटिङहरू खोल्नुहोस् र यसलाई निष्क्रिय पार्नुहोस्।"</string>
+ <string name="pip_play" msgid="3496151081459417097">"प्ले गर्नुहोस्"</string>
+ <string name="pip_pause" msgid="690688849510295232">"पज गर्नुहोस्"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"अर्कोमा जानुहोस्"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"अघिल्लोमा जानुहोस्"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"आकार बदल्नुहोस्"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"अनुप्रयोगले विभाजित-स्क्रिनलाई समर्थन गर्दैन।"</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"यो अनुप्रयोगले सहायक प्रदर्शनमा काम नगर्नसक्छ।"</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"अनुप्रयोगले सहायक प्रदर्शनहरूमा लञ्च सुविधालाई समर्थन गर्दैन।"</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"विभाजित-स्क्रिन छुट्याउने"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"बायाँ भाग फुल स्क्रिन"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"बायाँ भाग ७०%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"बायाँ भाग ५०%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"बायाँ भाग ३०%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"दायाँ भाग फुल स्क्रिन"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"माथिल्लो भाग फुल स्क्रिन"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"माथिल्लो भाग ७०%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"माथिल्लो भाग ५०%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"माथिल्लो भाग ३०%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"तल्लो भाग फुल स्क्रिन"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"<xliff:g id="APP_NAME">%1$s</xliff:g> का बबलसम्बन्धी सेटिङहरू"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"ओभरफ्लो देखाउनुहोस्"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"स्ट्याकमा फेरि थप्नुहोस्"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="APP_NAME">%2$s</xliff:g> को <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="APP_NAME">%2$s</xliff:g> का <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> र थप <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"शीर्ष भागको बायाँतिर सार्नुहोस्"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"सिरानमा दायाँतिर सार्नुहोस्"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"पुछारमा बायाँतिर सार्नुहोस्"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"पुछारमा दायाँतिर सार्नुहोस्"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> का सेटिङहरू"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"बबल खारेज गर्नुहोस्"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"वार्तालाप बबलको रूपमा नदेखाइयोस्"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"बबलहरू प्रयोग गरी कुराकानी गर्नुहोस्"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"नयाँ वार्तालापहरू तैरने आइकन वा बबलका रूपमा देखिन्छन्। बबल खोल्न ट्याप गर्नुहोस्। बबल सार्न सो बबललाई ड्र्याग गर्नुहोस्।"</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"जुनसुकै बेला बबलहरू नियन्त्रण गर्नुहोस्"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"यो एपबाट आएका बबलहरू अफ गर्न \"व्यवस्थापन गर्नुहोस्\" बटनमा ट्याप गर्नुहोस्"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"हालैका बबलहरू छैनन्"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"हालैका बबल र खारेज गरिएका बबलहरू यहाँ देखिने छन्"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"बबल"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"व्यवस्थापन गर्नुहोस्"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"बबल हटाइयो।"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-ne/strings_tv.xml b/libs/WindowManager/Shell/res/values-ne/strings_tv.xml
new file mode 100644
index 0000000..fc0221e
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-ne/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(शीर्षकविहीन कार्यक्रम)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"PIP लाई बन्द गर्नुहोस्"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"फुल स्क्रिन"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-nl/strings.xml b/libs/WindowManager/Shell/res/values-nl/strings.xml
new file mode 100644
index 0000000..2ead586
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-nl/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Sluiten"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Uitvouwen"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Instellingen"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Menu"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> is in scherm-in-scherm"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Als je niet wilt dat <xliff:g id="NAME">%s</xliff:g> deze functie gebruikt, tik je om de instellingen te openen en schakel je de functie uit."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Afspelen"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Onderbreken"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Doorgaan naar volgende"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Teruggaan naar vorige"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Formaat aanpassen"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"App biedt geen ondersteuning voor gesplitst scherm."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"App werkt mogelijk niet op een secundair scherm."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"App kan niet op secundaire displays worden gestart."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Scheiding voor gesplitst scherm"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Linkerscherm op volledig scherm"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Linkerscherm 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Linkerscherm 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Linkerscherm 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Rechterscherm op volledig scherm"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Bovenste scherm op volledig scherm"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Bovenste scherm 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Bovenste scherm 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Bovenste scherm 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Onderste scherm op volledig scherm"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Instellingen voor <xliff:g id="APP_NAME">%1$s</xliff:g>-bubbels"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Overloop"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Weer toevoegen aan stack"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> van <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> van <xliff:g id="APP_NAME">%2$s</xliff:g> en nog <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Naar linksboven verplaatsen"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Naar rechtsboven verplaatsen"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Naar linksonder verplaatsen"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Naar rechtsonder verplaatsen"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"Instellingen voor <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Bubbel sluiten"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Gesprekken niet in bubbels weergeven"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Chatten met bubbels"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Nieuwe gesprekken worden weergegeven als zwevende iconen of \'bubbels\'. Tik om een bubbel te openen. Sleep om de bubbel te verplaatsen."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Beheer bubbels wanneer je wilt"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Tik op Beheren om bubbels van deze app uit te schakelen"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Geen recente bubbels"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Recente bubbels en gesloten bubbels worden hier weergegeven"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Bubbel"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Beheren"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Bubbel gesloten."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-nl/strings_tv.xml b/libs/WindowManager/Shell/res/values-nl/strings_tv.xml
new file mode 100644
index 0000000..281eaf0
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-nl/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Naamloos programma)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"PIP sluiten"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Volledig scherm"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-or/strings.xml b/libs/WindowManager/Shell/res/values-or/strings.xml
new file mode 100644
index 0000000..2b27c99
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-or/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"ବନ୍ଦ କରନ୍ତୁ"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"ବଢ଼ାନ୍ତୁ"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"ସେଟିଂସ୍"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"ମେନୁ"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> \"ଛବି-ଭିତରେ-ଛବି\"ରେ ଅଛି"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"ଏହି ବୈଶିଷ୍ଟ୍ୟ <xliff:g id="NAME">%s</xliff:g> ବ୍ୟବହାର ନକରିବାକୁ ଯଦି ଆପଣ ଚାହାଁନ୍ତି, ସେଟିଙ୍ଗ ଖୋଲିବାକୁ ଟାପ୍ କରନ୍ତୁ ଏବଂ ଏହା ଅଫ୍ କରିଦିଅନ୍ତୁ।"</string>
+ <string name="pip_play" msgid="3496151081459417097">"ପ୍ଲେ କରନ୍ତୁ"</string>
+ <string name="pip_pause" msgid="690688849510295232">"ପଜ୍ କରନ୍ତୁ"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"ପରବର୍ତ୍ତୀକୁ ଯାଆନ୍ତୁ"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"ପୂର୍ବବର୍ତ୍ତୀକୁ ଛାଡ଼ନ୍ତୁ"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"ରିସାଇଜ୍ କରନ୍ତୁ"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"ଆପ୍ ସ୍ପ୍ଲିଟ୍-ସ୍କ୍ରୀନକୁ ସପୋର୍ଟ କରେ ନାହିଁ।"</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"ସେକେଣ୍ଡାରୀ ଡିସପ୍ଲେରେ ଆପ୍ କାମ ନକରିପାରେ।"</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"ସେକେଣ୍ଡାରୀ ଡିସପ୍ଲେରେ ଆପ୍ ଲଞ୍ଚ ସପୋର୍ଟ କରେ ନାହିଁ।"</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"ସ୍ପ୍ଲିଟ୍-ସ୍କ୍ରୀନ ବିଭାଜକ"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"ବାମ ପଟକୁ ପୂର୍ଣ୍ଣ ସ୍କ୍ରୀନ୍ କରନ୍ତୁ"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"ବାମ ପଟକୁ 70% କରନ୍ତୁ"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"ବାମ ପଟକୁ 50% କରନ୍ତୁ"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"ବାମ ପଟେ 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"ଡାହାଣ ପଟକୁ ପୂର୍ଣ୍ଣ ସ୍କ୍ରୀନ୍ କରନ୍ତୁ"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"ଉପର ଆଡ଼କୁ ପୂର୍ଣ୍ଣ ସ୍କ୍ରୀନ୍ କରନ୍ତୁ"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"ଉପର ଆଡ଼କୁ 70% କରନ୍ତୁ"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"ଉପର ଆଡ଼କୁ 50% କରନ୍ତୁ"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"ଉପର ଆଡ଼କୁ 30% କରନ୍ତୁ"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"ତଳ ଅଂଶର ପୂର୍ଣ୍ଣ ସ୍କ୍ରୀନ୍"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"<xliff:g id="APP_NAME">%1$s</xliff:g> ବବଲ୍ଗୁଡ଼ିକ ପାଇଁ ସେଟିଂସ୍"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"ଓଭରଫ୍ଲୋ"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"ଷ୍ଟାକରେ ପୁଣି ଯୋଗ କରନ୍ତୁ"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="APP_NAME">%2$s</xliff:g>ରୁ <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="APP_NAME">%2$s</xliff:g> ଏବଂ ଅଧିକ <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g>ଟିରୁ <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"ଉପର ବାମକୁ ନିଅନ୍ତୁ"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"ଉପର-ଡାହାଣକୁ ନିଅନ୍ତୁ"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"ତଳ ବାମକୁ ନିଅନ୍ତୁ"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"ତଳ ଡାହାଣକୁ ନିଅନ୍ତୁ"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> ସେଟିଂସ୍"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"ବବଲ୍ ଖାରଜ କରନ୍ତୁ"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"ବାର୍ତ୍ତାଳାପକୁ ବବଲ୍ କରନ୍ତୁ ନାହିଁ"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"ବବଲଗୁଡ଼ିକୁ ବ୍ୟବହାର କରି ଚାଟ୍ କରନ୍ତୁ"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"ନୂଆ ବାର୍ତ୍ତାଳାପଗୁଡ଼ିକ ଫ୍ଲୋଟିଂ ଆଇକନ୍ କିମ୍ବା ବବଲ୍ ଭାବେ ଦେଖାଯିବ। ବବଲ୍ ଖୋଲିବାକୁ ଟାପ୍ କରନ୍ତୁ। ଏହାକୁ ମୁଭ୍ କରିବାକୁ ଟାଣନ୍ତୁ।"</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"ଯେ କୌଣସି ସମୟରେ ବବଲଗୁଡ଼ିକ ନିୟନ୍ତ୍ରଣ କରନ୍ତୁ"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"ଏହି ଆପର ବବଲଗୁଡ଼ିକ ବନ୍ଦ କରିବା ପାଇଁ \'ପରିଚାଳନା କରନ୍ତୁ\' ବଟନରେ ଟାପ୍ କରନ୍ତୁ"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"ବର୍ତ୍ତମାନ କୌଣସି ବବଲ୍ ନାହିଁ"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"ବର୍ତ୍ତମାନର ଏବଂ ଖାରଜ କରାଯାଇଥିବା ବବଲଗୁଡ଼ିକ ଏଠାରେ ଦେଖାଯିବ"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"ବବଲ୍"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"ପରିଚାଳନା କରନ୍ତୁ"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"ବବଲ୍ ଖାରଜ କରାଯାଇଛି।"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-or/strings_tv.xml b/libs/WindowManager/Shell/res/values-or/strings_tv.xml
new file mode 100644
index 0000000..b57dd93
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-or/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(କୌଣସି ଟାଇଟଲ୍ ପ୍ରୋଗ୍ରାମ୍ ନାହିଁ)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"PIP ବନ୍ଦ କରନ୍ତୁ"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"ପୂର୍ଣ୍ଣ ସ୍କ୍ରୀନ୍"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-pa/strings.xml b/libs/WindowManager/Shell/res/values-pa/strings.xml
new file mode 100644
index 0000000..b9cb65e
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-pa/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"ਬੰਦ ਕਰੋ"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"ਵਿਸਤਾਰ ਕਰੋ"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"ਸੈਟਿੰਗਾਂ"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"ਮੀਨੂ"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> ਤਸਵੀਰ-ਅੰਦਰ-ਤਸਵੀਰ ਵਿੱਚ ਹੈ"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"ਜੇਕਰ ਤੁਸੀਂ ਨਹੀਂ ਚਾਹੁੰਦੇ ਕਿ <xliff:g id="NAME">%s</xliff:g> ਐਪ ਇਸ ਵਿਸ਼ੇਸ਼ਤਾ ਦੀ ਵਰਤੋਂ ਕਰੇ, ਤਾਂ ਸੈਟਿੰਗਾਂ ਖੋਲ੍ਹਣ ਲਈ ਟੈਪ ਕਰੋ ਅਤੇ ਇਸਨੂੰ ਬੰਦ ਕਰੋ।"</string>
+ <string name="pip_play" msgid="3496151081459417097">"ਚਲਾਓ"</string>
+ <string name="pip_pause" msgid="690688849510295232">"ਵਿਰਾਮ ਦਿਓ"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"ਅਗਲੇ \'ਤੇ ਜਾਓ"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"ਪਿਛਲੇ \'ਤੇ ਜਾਓ"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"ਆਕਾਰ ਬਦਲੋ"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"ਐਪ ਸਪਲਿਟ-ਸਕ੍ਰੀਨ ਨੂੰ ਸਮਰਥਨ ਨਹੀਂ ਕਰਦੀ।"</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"ਹੋ ਸਕਦਾ ਹੈ ਕਿ ਐਪ ਸੈਕੰਡਰੀ ਡਿਸਪਲੇ \'ਤੇ ਕੰਮ ਨਾ ਕਰੇ।"</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"ਐਪ ਸੈਕੰਡਰੀ ਡਿਸਪਲੇਆਂ \'ਤੇ ਲਾਂਚ ਕਰਨ ਦਾ ਸਮਰਥਨ ਨਹੀਂ ਕਰਦੀ"</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"ਸਪਲਿਟ-ਸਕ੍ਰੀਨ ਡਿਵਾਈਡਰ"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"ਖੱਬੇ ਪੂਰੀ ਸਕ੍ਰੀਨ"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"ਖੱਬੇ 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"ਖੱਬੇ 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"ਖੱਬੇ 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"ਸੱਜੇ ਪੂਰੀ ਸਕ੍ਰੀਨ"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"ਉੱਪਰ ਪੂਰੀ ਸਕ੍ਰੀਨ"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"ਉੱਪਰ 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"ਉੱਪਰ 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"ਉੱਪਰ 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"ਹੇਠਾਂ ਪੂਰੀ ਸਕ੍ਰੀਨ"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"<xliff:g id="APP_NAME">%1$s</xliff:g> ਬਬਲ ਲਈ ਸੈਟਿੰਗਾਂ"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"ਓਵਰਫ਼ਲੋ"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"ਸਟੈਕ ਵਿੱਚ ਵਾਪਸ ਸ਼ਾਮਲ ਕਰੋ"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="APP_NAME">%2$s</xliff:g> ਤੋਂ <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="APP_NAME">%2$s</xliff:g> ਅਤੇ <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> ਹੋਰਾਂ ਤੋਂ <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"ਉੱਪਰ ਵੱਲ ਖੱਬੇ ਲਿਜਾਓ"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"ਉੱਪਰ ਵੱਲ ਸੱਜੇ ਲਿਜਾਓ"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"ਹੇਠਾਂ ਵੱਲ ਖੱਬੇ ਲਿਜਾਓ"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"ਹੇਠਾਂ ਵੱਲ ਸੱਜੇ ਲਿਜਾਓ"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> ਸੈਟਿੰਗਾਂ"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"ਬਬਲ ਨੂੰ ਖਾਰਜ ਕਰੋ"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"ਗੱਲਬਾਤ \'ਤੇ ਬਬਲ ਨਾ ਲਾਓ"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"ਬਬਲ ਵਰਤਦੇ ਹੋਏ ਚੈਟ ਕਰੋ"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"ਨਵੀਆਂ ਗੱਲਾਂਬਾਤਾਂ ਫਲੋਟਿੰਗ ਪ੍ਰਤੀਕਾਂ ਜਾਂ ਬਬਲ ਦੇ ਰੂਪ ਵਿੱਚ ਦਿਸਦੀਆਂ ਹਨ। ਬਬਲ ਨੂੰ ਖੋਲ੍ਹਣ ਲਈ ਟੈਪ ਕਰੋ। ਇਸਨੂੰ ਲਿਜਾਣ ਲਈ ਘਸੀਟੋ।"</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"ਬਬਲ ਨੂੰ ਕਿਸੇ ਵੇਲੇ ਵੀ ਕੰਟਰੋਲ ਕਰੋ"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"ਇਸ ਐਪ \'ਤੇ ਬਬਲ ਬੰਦ ਕਰਨ ਲਈ \'ਪ੍ਰਬੰਧਨ ਕਰੋ\' \'ਤੇ ਟੈਪ ਕਰੋ"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"ਕੋਈ ਹਾਲੀਆ ਬਬਲ ਨਹੀਂ"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"ਹਾਲੀਆ ਬਬਲ ਅਤੇ ਖਾਰਜ ਕੀਤੇ ਬਬਲ ਇੱਥੇ ਦਿਸਣਗੇ"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"ਬੁਲਬੁਲਾ"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"ਪ੍ਰਬੰਧਨ ਕਰੋ"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"ਬਬਲ ਨੂੰ ਖਾਰਜ ਕੀਤਾ ਗਿਆ।"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-pa/strings_tv.xml b/libs/WindowManager/Shell/res/values-pa/strings_tv.xml
new file mode 100644
index 0000000..028a0a0
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-pa/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(ਸਿਰਲੇਖ-ਰਹਿਤ ਪ੍ਰੋਗਰਾਮ)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"PIP ਬੰਦ ਕਰੋ"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"ਪੂਰੀ ਸਕ੍ਰੀਨ"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-pl/strings.xml b/libs/WindowManager/Shell/res/values-pl/strings.xml
new file mode 100644
index 0000000..bc473b5
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-pl/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Zamknij"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Rozwiń"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Ustawienia"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Menu"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"Aplikacja <xliff:g id="NAME">%s</xliff:g> działa w trybie obraz w obrazie"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Jeśli nie chcesz, by aplikacja <xliff:g id="NAME">%s</xliff:g> korzystała z tej funkcji, otwórz ustawienia i wyłącz ją."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Odtwórz"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Wstrzymaj"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Dalej"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Wstecz"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Zmień rozmiar"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Aplikacja nie obsługuje dzielonego ekranu."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Aplikacja może nie działać na dodatkowym ekranie."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Aplikacja nie obsługuje uruchamiania na dodatkowych ekranach."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Linia dzielenia ekranu"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Lewa część ekranu na pełnym ekranie"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"70% lewej części ekranu"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"50% lewej części ekranu"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"30% lewej części ekranu"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Prawa część ekranu na pełnym ekranie"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Górna część ekranu na pełnym ekranie"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"70% górnej części ekranu"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"50% górnej części ekranu"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"30% górnej części ekranu"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Dolna część ekranu na pełnym ekranie"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Ustawienia dymków aplikacji <xliff:g id="APP_NAME">%1$s</xliff:g>"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Przepełnienie"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Dodaj ponownie do stosu"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> z aplikacji <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> z aplikacji <xliff:g id="APP_NAME">%2$s</xliff:g> i jeszcze <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Przenieś w lewy górny róg"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Przenieś w prawy górny róg"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Przenieś w lewy dolny róg"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Przenieś w prawy dolny róg"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> – ustawienia"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Zamknij dymek"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Nie wyświetlaj rozmowy jako dymka"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Czatuj, korzystając z dymków"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Nowe rozmowy będą wyświetlane jako pływające ikony lub dymki. Kliknij, by otworzyć dymek. Przeciągnij, by go przenieść."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Zarządzaj dymkami w dowolnym momencie"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Kliknij Zarządzaj, aby wyłączyć dymki z tej aplikacji"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Brak ostatnich dymków"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Tutaj będą pojawiać się ostatnie i odrzucone dymki"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Dymek"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Zarządzaj"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Zamknięto dymek"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-pl/strings_tv.xml b/libs/WindowManager/Shell/res/values-pl/strings_tv.xml
new file mode 100644
index 0000000..4522ea1
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-pl/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Program bez tytułu)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Zamknij PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Pełny ekran"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-pt-rBR/strings.xml b/libs/WindowManager/Shell/res/values-pt-rBR/strings.xml
new file mode 100644
index 0000000..612377d
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-pt-rBR/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Fechar"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Expandir"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Configurações"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Menu"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> está em picture-in-picture"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Se você não quer que o app <xliff:g id="NAME">%s</xliff:g> use este recurso, toque para abrir as configurações e desativá-lo."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Reproduzir"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Pausar"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Pular para a próxima"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Pular para a anterior"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Redimensionar"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"O app não é compatível com a divisão de tela."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"É possível que o app não funcione em uma tela secundária."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"O app não é compatível com a inicialização em telas secundárias."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Divisor de tela"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Lado esquerdo em tela cheia"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Esquerda a 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Esquerda a 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Esquerda a 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Lado direito em tela cheia"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Parte superior em tela cheia"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Parte superior a 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Parte superior a 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Parte superior a 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Parte inferior em tela cheia"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Configurações de balões do <xliff:g id="APP_NAME">%1$s</xliff:g>"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Menu flutuante"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Devolver à pilha"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> de <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> de <xliff:g id="APP_NAME">%2$s</xliff:g> mais <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Mover para canto superior esquerdo"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Mover para canto superior direito"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Mover para canto inferior esquerdo"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Mover para canto inferior direito"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"Configurações de <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Dispensar balão"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Não criar balões de conversa"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Converse usando balões"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Novas conversas aparecerão como ícones flutuantes, ou balões. Toque para abrir o balão. Arraste para movê-lo."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Controle os balões a qualquer momento"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Toque em \"Gerenciar\" para desativar os balões desse app"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Nenhum balão recente"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Os balões recentes e dispensados aparecerão aqui"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Bolha"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Gerenciar"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Balão dispensado."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-pt-rBR/strings_tv.xml b/libs/WindowManager/Shell/res/values-pt-rBR/strings_tv.xml
new file mode 100644
index 0000000..951babe
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-pt-rBR/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(programa sem título)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Fechar PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Tela cheia"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-pt-rPT/strings.xml b/libs/WindowManager/Shell/res/values-pt-rPT/strings.xml
new file mode 100644
index 0000000..bbd233e
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-pt-rPT/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Fechar"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Expandir"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Definições"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Menu"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"A app <xliff:g id="NAME">%s</xliff:g> está no modo de ecrã no ecrã"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Se não pretende que a app <xliff:g id="NAME">%s</xliff:g> utilize esta funcionalidade, toque para abrir as definições e desative-a."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Reproduzir"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Pausar"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Mudar para o seguinte"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Mudar para o anterior"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Redimensionar"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"A app não é compatível com o ecrã dividido."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"A app pode não funcionar num ecrã secundário."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"A app não é compatível com o início em ecrãs secundários."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Divisor do ecrã dividido"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Ecrã esquerdo inteiro"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"70% no ecrã esquerdo"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"50% no ecrã esquerdo"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"30% no ecrã esquerdo"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Ecrã direito inteiro"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Ecrã superior inteiro"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"70% no ecrã superior"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"50% no ecrã superior"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"30% no ecrã superior"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Ecrã inferior inteiro"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Definições dos balões da app <xliff:g id="APP_NAME">%1$s</xliff:g>"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Menu adicional"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Adicionar novamente à pilha"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> de <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> do <xliff:g id="APP_NAME">%2$s</xliff:g> e mais<xliff:g id="BUBBLE_COUNT">%3$d</xliff:g>."</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Mover p/ parte sup. esquerda"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Mover parte superior direita"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Mover p/ parte infer. esquerda"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Mover parte inferior direita"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"Definições de <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Ignorar balão"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Não apresentar a conversa em balões"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Converse no chat através de balões"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"As novas conversas aparecem como ícones flutuantes ou balões. Toque para abrir o balão. Arraste para o mover."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Controle os balões em qualquer altura"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Toque em Gerir para desativar os balões desta app."</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Nenhum balão recente"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Os balões recentes e ignorados vão aparecer aqui."</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Balão"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Gerir"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Balão ignorado."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-pt-rPT/strings_tv.xml b/libs/WindowManager/Shell/res/values-pt-rPT/strings_tv.xml
new file mode 100644
index 0000000..05d976c
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-pt-rPT/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Sem título do programa)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Fechar PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Ecrã inteiro"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-pt/strings.xml b/libs/WindowManager/Shell/res/values-pt/strings.xml
new file mode 100644
index 0000000..612377d
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-pt/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Fechar"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Expandir"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Configurações"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Menu"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> está em picture-in-picture"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Se você não quer que o app <xliff:g id="NAME">%s</xliff:g> use este recurso, toque para abrir as configurações e desativá-lo."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Reproduzir"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Pausar"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Pular para a próxima"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Pular para a anterior"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Redimensionar"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"O app não é compatível com a divisão de tela."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"É possível que o app não funcione em uma tela secundária."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"O app não é compatível com a inicialização em telas secundárias."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Divisor de tela"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Lado esquerdo em tela cheia"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Esquerda a 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Esquerda a 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Esquerda a 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Lado direito em tela cheia"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Parte superior em tela cheia"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Parte superior a 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Parte superior a 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Parte superior a 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Parte inferior em tela cheia"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Configurações de balões do <xliff:g id="APP_NAME">%1$s</xliff:g>"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Menu flutuante"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Devolver à pilha"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> de <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> de <xliff:g id="APP_NAME">%2$s</xliff:g> mais <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Mover para canto superior esquerdo"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Mover para canto superior direito"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Mover para canto inferior esquerdo"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Mover para canto inferior direito"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"Configurações de <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Dispensar balão"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Não criar balões de conversa"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Converse usando balões"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Novas conversas aparecerão como ícones flutuantes, ou balões. Toque para abrir o balão. Arraste para movê-lo."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Controle os balões a qualquer momento"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Toque em \"Gerenciar\" para desativar os balões desse app"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Nenhum balão recente"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Os balões recentes e dispensados aparecerão aqui"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Bolha"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Gerenciar"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Balão dispensado."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-pt/strings_tv.xml b/libs/WindowManager/Shell/res/values-pt/strings_tv.xml
new file mode 100644
index 0000000..951babe
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-pt/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(programa sem título)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Fechar PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Tela cheia"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-ro/strings.xml b/libs/WindowManager/Shell/res/values-ro/strings.xml
new file mode 100644
index 0000000..a31b8a1
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-ro/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Închideți"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Extindeți"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Setări"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Meniu"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> este în modul picture-in-picture"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Dacă nu doriți ca <xliff:g id="NAME">%s</xliff:g> să utilizeze această funcție, atingeți pentru a deschide setările și dezactivați-o."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Redați"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Întrerupeți"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Treceți la următorul"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Treceți la cel anterior"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Redimensionați"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Aplicația nu acceptă ecranul împărțit."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Este posibil ca aplicația să nu funcționeze pe un ecran secundar."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Aplicația nu acceptă lansare pe ecrane secundare."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Separator pentru ecranul împărțit"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Partea stângă pe ecran complet"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Partea stângă: 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Partea stângă: 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Partea stângă: 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Partea dreaptă pe ecran complet"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Partea de sus pe ecran complet"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Partea de sus: 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Partea de sus: 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Partea de sus: 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Partea de jos pe ecran complet"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Setări pentru baloanele <xliff:g id="APP_NAME">%1$s</xliff:g>"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Suplimentar"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Adăugați înapoi în stivă"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> de la <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> de la <xliff:g id="APP_NAME">%2$s</xliff:g> și încă <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Mutați în stânga sus"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Mutați în dreapta sus"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Mutați în stânga jos"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Mutați în dreapta jos"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"Setări <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Închideți balonul"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Nu afișați conversația în balon"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Chat cu baloane"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Conversațiile noi apar ca pictograme flotante sau baloane. Atingeți pentru a deschide balonul. Trageți pentru a-l muta."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Controlați oricând baloanele"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Atingeți Gestionați pentru a dezactiva baloanele din această aplicație"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Nu există baloane recente"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Baloanele recente și baloanele respinse vor apărea aici"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Balon"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Gestionați"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Balonul a fost respins."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-ro/strings_tv.xml b/libs/WindowManager/Shell/res/values-ro/strings_tv.xml
new file mode 100644
index 0000000..0dc28f0
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-ro/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Program fără titlu)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Închideți PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Ecran complet"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-ru/strings.xml b/libs/WindowManager/Shell/res/values-ru/strings.xml
new file mode 100644
index 0000000..849ab28
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-ru/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Закрыть"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Развернуть"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Настройки"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Меню"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> находится в режиме \"Картинка в картинке\""</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Чтобы отключить эту функцию для приложения \"<xliff:g id="NAME">%s</xliff:g>\", перейдите в настройки."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Воспроизвести"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Приостановить"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Перейти к следующему"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Перейти к предыдущему"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Изменить размер"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Приложение не поддерживает разделение экрана."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Приложение может не работать на дополнительном экране"</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Приложение не поддерживает запуск на дополнительных экранах"</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Разделитель экрана"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Левый во весь экран"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Левый на 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Левый на 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Левый на 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Правый во весь экран"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Верхний во весь экран"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Верхний на 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Верхний на 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Верхний на 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Нижний во весь экран"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Настройки всплывающих чатов от приложения \"<xliff:g id="APP_NAME">%1$s</xliff:g>\"."</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Дополнительное меню"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Добавить обратно в стек"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> из приложения \"<xliff:g id="APP_NAME">%2$s</xliff:g>\""</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> от приложения \"<xliff:g id="APP_NAME">%2$s</xliff:g>\" и ещё <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Перенести в левый верхний угол"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Перенести в правый верхний угол"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Перенести в левый нижний угол"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Перенести в правый нижний угол"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>: настройки"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Скрыть всплывающий чат"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Не показывать всплывающий чат для разговора"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Всплывающие чаты"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Новые разговоры будут появляться в виде плавающих значков, или всплывающих чатов. Чтобы открыть чат, нажмите на него, а чтобы переместить – перетащите."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Всплывающие чаты"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Чтобы отключить всплывающие чаты из этого приложения, нажмите \"Настроить\"."</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Нет недавних всплывающих чатов"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Здесь будут появляться недавние и скрытые всплывающие чаты."</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Всплывающая подсказка"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Настроить"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Всплывающий чат закрыт."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-ru/strings_tv.xml b/libs/WindowManager/Shell/res/values-ru/strings_tv.xml
new file mode 100644
index 0000000..238d2d5
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-ru/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Без названия)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"\"Кадр в кадре\" – выйти"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Во весь экран"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-si/strings.xml b/libs/WindowManager/Shell/res/values-si/strings.xml
new file mode 100644
index 0000000..35c8388
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-si/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"වසන්න"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"දිග හරින්න"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"සැකසීම්"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"මෙනුව"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> පින්තූරය-තුළ-පින්තූරය තුළ වේ"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"ඔබට <xliff:g id="NAME">%s</xliff:g> මෙම විශේෂාංගය භාවිත කිරීමට අවශ්ය නැති නම්, සැකසීම් විවෘත කිරීමට තට්ටු කර එය ක්රියාවිරහිත කරන්න."</string>
+ <string name="pip_play" msgid="3496151081459417097">"ධාවනය කරන්න"</string>
+ <string name="pip_pause" msgid="690688849510295232">"විරාම කරන්න"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"ඊළඟ එකට පනින්න"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"පෙර එකට පනින්න"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"ප්රතිප්රමාණ කරන්න"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"යෙදුම බෙදුණු-තිරය සඳහා සහාය නොදක්වයි."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"යෙදුම ද්විතියික සංදර්ශකයක ක්රියා නොකළ හැකිය."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"යෙදුම ද්විතීයික සංදර්ශක මත දියත් කිරීම සඳහා සහාය නොදක්වයි."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"බෙදුම්-තිර වෙන්කරණය"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"වම් පූර්ණ තිරය"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"වම් 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"වම් 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"වම් 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"දකුණු පූර්ණ තිරය"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"ඉහළම පූර්ණ තිරය"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"ඉහළම 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"ඉහළම 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"ඉහළම 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"පහළ පූර්ණ තිරය"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"<xliff:g id="APP_NAME">%1$s</xliff:g> බුබුළු සඳහා සැකසීම්"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"පිටාර යාම"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"අට්ටිය වෙත ආපසු එක් කරන්න"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="APP_NAME">%2$s</xliff:g> වෙතින් <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="APP_NAME">%2$s</xliff:g> වෙතින් <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> සහ තවත් <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> ක්"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"ඉහළ වමට ගෙන යන්න"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"ඉහළ දකුණට ගෙන යන්න"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"පහළ වමට ගෙන යන්න"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"පහළ දකුණට ගෙන යන්න"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> සැකසීම්"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"බුබුලු ඉවත ලන්න"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"සංවාදය බුබුලු නොදමන්න"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"බුබුලු භාවිතයෙන් කතාබහ කරන්න"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"නව සංවාද පාවෙන අයිකන හෝ බුබුලු ලෙස දිස් වේ. බුබුල විවෘත කිරීමට තට්ටු කරන්න. එය ගෙන යාමට අදින්න."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"ඕනෑම වේලාවක බුබුලු පාලනය කරන්න"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"මෙම යෙදුමෙන් බුබුලු ක්රියාවිරහිත කිරීමට කළමනාකරණය කරන්න තට්ටු කරන්න"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"මෑත බුබුලු නැත"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"මෑත බුබුලු සහ ඉවත ලූ බුබුලු මෙහි දිස් වනු ඇත"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"බුබුළු"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"කළමනා කරන්න"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"බුබුල ඉවත දමා ඇත."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-si/strings_tv.xml b/libs/WindowManager/Shell/res/values-si/strings_tv.xml
new file mode 100644
index 0000000..4d8d97f
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-si/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(මාතෘකාවක් නැති වැඩසටහන)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"PIP වසන්න"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"සම්පූර්ණ තිරය"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-sk/strings.xml b/libs/WindowManager/Shell/res/values-sk/strings.xml
new file mode 100644
index 0000000..b358894
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-sk/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Zavrieť"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Rozbaliť"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Nastavenia"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Ponuka"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> je v režime obraz v obraze"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Ak nechcete, aby aplikácia <xliff:g id="NAME">%s</xliff:g> používala túto funkciu, klepnutím otvorte nastavenia a vypnite ju."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Prehrať"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Pozastaviť"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Preskočiť na ďalšie"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Preskočiť na predchádzajúce"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Zmeniť veľkosť"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Aplikácia nepodporuje rozdelenú obrazovku."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Aplikácia nemusí fungovať na sekundárnej obrazovke."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Aplikácia nepodporuje spúšťanie na sekundárnych obrazovkách."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Rozdeľovač obrazovky"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Ľavá – na celú obrazovku"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Ľavá – 70 %"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Ľavá – 50 %"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Ľavá – 30 %"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Pravá– na celú obrazovku"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Horná – na celú obrazovku"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Horná – 70 %"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Horná – 50 %"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Horná – 30 %"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Dolná – na celú obrazovku"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Nastavenia bublín aplikácie <xliff:g id="APP_NAME">%1$s</xliff:g>"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Rozšírená ponuka"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Pridať späť do zásobníka"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> z aplikácie <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> z aplikácie <xliff:g id="APP_NAME">%2$s</xliff:g> a ďalšie (<xliff:g id="BUBBLE_COUNT">%3$d</xliff:g>)"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Presunúť doľava nahor"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Presunúť doprava nahor"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Presunúť doľava nadol"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Presunúť doprava nadol"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"Nastavenia aplikácie <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Zavrieť bublinu"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Nezobrazovať konverzáciu ako bublinu"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Čet pomocou bublín"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Nové konverzácie sa zobrazujú ako plávajúce ikony či bubliny. Bublinu otvoríte klepnutím. Premiestnite ju presunutím."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Nastavenie bublín môžete kedykoľvek zmeniť"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Bubliny pre túto aplikáciu môžete vypnúť klepnutím na Spravovať"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Žiadne nedávne bubliny"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Tu sa budú zobrazovať nedávne a zavreté bubliny"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Bublina"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Spravovať"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Bublina bola zavretá."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-sk/strings_tv.xml b/libs/WindowManager/Shell/res/values-sk/strings_tv.xml
new file mode 100644
index 0000000..1f9ee16
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-sk/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Program bez názvu)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Zavrieť režim PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Celá obrazovka"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-sl/strings.xml b/libs/WindowManager/Shell/res/values-sl/strings.xml
new file mode 100644
index 0000000..d3b2c81
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-sl/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Zapri"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Razširi"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Nastavitve"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Meni"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> je v načinu slika v sliki"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Če ne želite, da aplikacija <xliff:g id="NAME">%s</xliff:g> uporablja to funkcijo, se dotaknite, da odprete nastavitve, in funkcijo izklopite."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Predvajaj"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Začasno ustavi"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Preskoči na naslednjega"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Preskoči na prejšnjega"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Spremeni velikost"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Aplikacija ne podpira načina razdeljenega zaslona."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Aplikacija morda ne bo delovala na sekundarnem zaslonu."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Aplikacija ne podpira zagona na sekundarnih zaslonih."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Razdelilnik zaslonov"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Levi v celozaslonski način"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Levi 70 %"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Levi 50 %"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Levi 30 %"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Desni v celozaslonski način"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Zgornji v celozaslonski način"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Zgornji 70 %"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Zgornji 50 %"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Zgornji 30 %"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Spodnji v celozaslonski način"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Nastavitve za oblačke aplikacije <xliff:g id="APP_NAME">%1$s</xliff:g>"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Prelivanje"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Dodaj nazaj v sklad"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> (<xliff:g id="APP_NAME">%2$s</xliff:g>)"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> iz aplikacije <xliff:g id="APP_NAME">%2$s</xliff:g> in toliko drugih: <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Premakni zgoraj levo"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Premakni zgoraj desno"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Premakni spodaj levo"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Premakni spodaj desno"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"Nastavitve za <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Opusti oblaček"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Pogovora ne prikaži v oblačku"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Klepet z oblački"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Novi pogovori so prikazani kot lebdeče ikone ali oblački. Če želite odpreti oblaček, se ga dotaknite. Če ga želite premakniti, ga povlecite."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Upravljanje oblačkov"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Dotaknite se »Upravljanje«, da izklopite oblačke iz te aplikacije"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Ni nedavnih oblačkov"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Tukaj bodo prikazani tako nedavni kot tudi opuščeni oblački"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Mehurček"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Upravljanje"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Oblaček je bil opuščen."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-sl/strings_tv.xml b/libs/WindowManager/Shell/res/values-sl/strings_tv.xml
new file mode 100644
index 0000000..88639ee
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-sl/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Program brez naslova)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Zapri način PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Celozaslonsko"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-sq/strings.xml b/libs/WindowManager/Shell/res/values-sq/strings.xml
new file mode 100644
index 0000000..61b6c36
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-sq/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Mbyll"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Zgjero"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Cilësimet"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Menyja"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> është në figurë brenda figurës"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Nëse nuk dëshiron që <xliff:g id="NAME">%s</xliff:g> ta përdorë këtë funksion, trokit për të hapur cilësimet dhe për ta çaktivizuar."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Luaj"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Ndërprit"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Kalo te tjetra"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Kalo tek e mëparshmja"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Ndrysho përmasat"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Aplikacioni nuk mbështet ekranin e ndarë."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Aplikacioni mund të mos funksionojë në një ekran dytësor."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Aplikacioni nuk mbështet nisjen në ekrane dytësore."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Ndarësi i ekranit të ndarë"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Ekrani i plotë majtas"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Majtas 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Majtas 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Majtas 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Ekrani i plotë djathtas"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Ekrani i plotë lart"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Lart 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Lart 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Lart 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Ekrani i plotë poshtë"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Cilësimet për flluskat e <xliff:g id="APP_NAME">%1$s</xliff:g>"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Tejkalo"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Shto përsëri te stiva"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> nga <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> nga <xliff:g id="APP_NAME">%2$s</xliff:g> dhe <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> të tjera"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Zhvendos lart majtas"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Lëviz lart djathtas"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Zhvendos poshtë majtas"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Lëvize poshtë djathtas"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"Cilësimet e <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Hiqe flluskën"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Mos e vendos bisedën në flluskë"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Bisedo duke përdorur flluskat"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Bisedat e reja shfaqen si ikona pluskuese ose flluska. Trokit për të hapur flluskën. Zvarrit për ta zhvendosur."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Kontrollo flluskat në çdo moment"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Trokit \"Menaxho\" për të çaktivizuar flluskat nga ky aplikacion"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Nuk ka flluska të fundit"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Flluskat e fundit dhe flluskat e hequra do të shfaqen këtu"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Flluskë"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Menaxho"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Flluska u hoq."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-sq/strings_tv.xml b/libs/WindowManager/Shell/res/values-sq/strings_tv.xml
new file mode 100644
index 0000000..e81275e
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-sq/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Program pa titull)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Mbyll PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Ekrani i plotë"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-sr/strings.xml b/libs/WindowManager/Shell/res/values-sr/strings.xml
new file mode 100644
index 0000000..32de8a3
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-sr/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Затвори"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Прошири"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Подешавања"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Мени"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> је слика у слици"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Ако не желите да <xliff:g id="NAME">%s</xliff:g> користи ову функцију, додирните да бисте отворили подешавања и искључили је."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Пусти"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Паузирај"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Пређи на следеће"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Пређи на претходно"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Промените величину"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Апликација не подржава подељени екран."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Апликација можда неће функционисати на секундарном екрану."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Апликација не подржава покретање на секундарним екранима."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Разделник подељеног екрана"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Режим целог екрана за леви екран"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Леви екран 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Леви екран 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Леви екран 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Режим целог екрана за доњи екран"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Режим целог екрана за горњи екран"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Горњи екран 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Горњи екран 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Горњи екран 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Режим целог екрана за доњи екран"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Подешавања за <xliff:g id="APP_NAME">%1$s</xliff:g> облачиће"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Преклапање"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Додај поново у групу"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> из апликације <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> из апликације <xliff:g id="APP_NAME">%2$s</xliff:g> и још <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Премести горе лево"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Премести горе десно"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Премести доле лево"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Премести доле десно"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"Подешавања за <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Одбаци облачић"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Не користи облачиће за конверзацију"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Ћаскајте у облачићима"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Нове конверзације се приказују као плутајуће иконе или облачићи. Додирните да бисте отворили облачић. Превуците да бисте га преместили."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Контролишите облачиће у било ком тренутку"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Додирните Управљајте да бисте искључили облачиће из ове апликације"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Нема недавних облачића"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Овде се приказују недавни и одбачени облачићи"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Облачић"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Управљајте"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Облачић је одбачен."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-sr/strings_tv.xml b/libs/WindowManager/Shell/res/values-sr/strings_tv.xml
new file mode 100644
index 0000000..a06da11
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-sr/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Програм без наслова)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Затвори PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Цео екран"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-sv/strings.xml b/libs/WindowManager/Shell/res/values-sv/strings.xml
new file mode 100644
index 0000000..2ec7944
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-sv/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Stäng"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Utöka"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Inställningar"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Meny"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> visas i bild-i-bild"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Om du inte vill att den här funktionen används i <xliff:g id="NAME">%s</xliff:g> öppnar du inställningarna genom att trycka. Sedan inaktiverar du funktionen."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Spela upp"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Pausa"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Hoppa till nästa"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Hoppa till föregående"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Ändra storlek"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Appen har inte stöd för delad skärm."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Appen kanske inte fungerar på en sekundär skärm."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Appen kan inte köras på en sekundär skärm."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Avdelare för delad skärm"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Helskärm på vänster skärm"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Vänster 70 %"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Vänster 50 %"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Vänster 30 %"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Helskärm på höger skärm"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Helskärm på övre skärm"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Övre 70 %"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Övre 50 %"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Övre 30 %"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Helskärm på nedre skärm"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Inställningar för <xliff:g id="APP_NAME">%1$s</xliff:g>-bubblor"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Fler menyalternativ"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Lägg tillbaka på stack"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> från <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> från <xliff:g id="APP_NAME">%2$s</xliff:g> och <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> fler"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Flytta högst upp till vänster"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Flytta högst upp till höger"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Flytta längst ned till vänster"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Flytta längst ned till höger"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"Inställningar för <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Stäng bubbla"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Visa inte konversationen i bubblor"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Chatta med bubblor"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Nya konversationer visas som flytande ikoner, så kallade bubblor. Tryck på bubblan om du vill öppna den. Dra den om du vill flytta den."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Styr bubblor när som helst"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Tryck på Hantera för att stänga av bubblor från den här appen"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Inga nya bubblor"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"De senaste bubblorna och ignorerade bubblor visas här"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Bubbla"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Hantera"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Bubblan ignorerades."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-sv/strings_tv.xml b/libs/WindowManager/Shell/res/values-sv/strings_tv.xml
new file mode 100644
index 0000000..da0b121
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-sv/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Namnlöst program)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Stäng PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Helskärm"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-sw/strings.xml b/libs/WindowManager/Shell/res/values-sw/strings.xml
new file mode 100644
index 0000000..5815d5e
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-sw/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Funga"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Panua"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Mipangilio"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Menyu"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> iko katika hali ya picha ndani ya picha nyingine"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Ikiwa hutaki <xliff:g id="NAME">%s</xliff:g> itumie kipengele hiki, gusa ili ufungue mipangilio na uizime."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Cheza"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Sitisha"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Ruka ufikie inayofuata"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Ruka ufikie iliyotangulia"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Badilisha ukubwa"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Programu haiwezi kutumia skrini iliyogawanywa."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Huenda programu isifanye kazi kwenye dirisha lingine."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Programu hii haiwezi kufunguliwa kwenye madirisha mengine."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Kitenganishi cha skrini inayogawanywa"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Skrini nzima ya kushoto"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Kushoto 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Kushoto 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Kushoto 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Skrini nzima ya kulia"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Skrini nzima ya juu"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Juu 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Juu 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Juu 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Skrini nzima ya chini"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Mipangilio ya viputo vya <xliff:g id="APP_NAME">%1$s</xliff:g>"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Vipengee vya ziada"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Rejesha kwenye rafu"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> kutoka kwa <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> kutoka kwa <xliff:g id="APP_NAME">%2$s</xliff:g> na nyingine<xliff:g id="BUBBLE_COUNT">%3$d</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Sogeza juu kushoto"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Sogeza juu kulia"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Sogeza chini kushoto"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Sogeza chini kulia"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"Mipangilio ya <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Ondoa kiputo"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Usiweke viputo kwenye mazungumzo"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Piga gumzo ukitumia viputo"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Mazungumzo mapya huonekena kama aikoni au viputo vinavyoelea. Gusa ili ufungue kiputo. Buruta ili ukisogeze."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Dhibiti viputo wakati wowote"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Gusa Dhibiti ili uzime viputo kwenye programu hii"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Hakuna viputo vya hivi majuzi"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Viputo vya hivi karibuni na vile vilivyoondolewa vitaonekana hapa"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Kiputo"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Dhibiti"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Umeondoa kiputo."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-sw/strings_tv.xml b/libs/WindowManager/Shell/res/values-sw/strings_tv.xml
new file mode 100644
index 0000000..9619523
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-sw/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Programu isiyo na jina)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Funga PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Skrini nzima"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-ta/strings.xml b/libs/WindowManager/Shell/res/values-ta/strings.xml
new file mode 100644
index 0000000..81066ff
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-ta/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"மூடு"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"விரி"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"அமைப்புகள்"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"மெனு"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> தற்போது பிக்ச்சர்-இன்-பிக்ச்சரில் உள்ளது"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"<xliff:g id="NAME">%s</xliff:g> இந்த அம்சத்தைப் பயன்படுத்த வேண்டாம் என நினைத்தால் இங்கு தட்டி அமைப்புகளைத் திறந்து இதை முடக்கவும்."</string>
+ <string name="pip_play" msgid="3496151081459417097">"இயக்கு"</string>
+ <string name="pip_pause" msgid="690688849510295232">"இடைநிறுத்து"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"அடுத்ததற்குச் செல்"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"முந்தையதற்குச் செல்"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"அளவு மாற்று"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"திரையைப் பிரிப்பதைப் ஆப்ஸ் ஆதரிக்கவில்லை."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"இரண்டாம்நிலைத் திரையில் ஆப்ஸ் வேலை செய்யாமல் போகக்கூடும்."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"இரண்டாம்நிலைத் திரைகளில் பயன்பாட்டைத் தொடங்க முடியாது."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"திரையைப் பிரிக்கும் பிரிப்பான்"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"இடது புறம் முழுத் திரை"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"இடது புறம் 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"இடது புறம் 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"இடது புறம் 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"வலது புறம் முழுத் திரை"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"மேற்புறம் முழுத் திரை"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"மேலே 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"மேலே 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"மேலே 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"கீழ்ப்புறம் முழுத் திரை"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"<xliff:g id="APP_NAME">%1$s</xliff:g> குமிழ்களுக்கான அமைப்புகள்"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"ஓவர்ஃப்லோ"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"மீண்டும் ஸ்டேக்கில் சேர்க்கவும்"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="APP_NAME">%2$s</xliff:g> இலிருந்து <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="APP_NAME">%2$s</xliff:g> மற்றும் மேலும் <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> ஆப்ஸிலிருந்து வந்துள்ள அறிவிப்பு: <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"மேலே இடப்புறமாக நகர்த்து"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"மேலே வலப்புறமாக நகர்த்து"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"கீழே இடப்புறமாக நகர்த்து"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"கீழே வலதுபுறமாக நகர்த்து"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> அமைப்புகள்"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"குமிழை அகற்று"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"உரையாடலைக் குமிழாக்காதே"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"குமிழ்களைப் பயன்படுத்தி அரட்டையடியுங்கள்"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"புதிய உரையாடல்கள் மிதக்கும் ஐகான்களாகவோ குமிழ்களாகவோ தோன்றும். குமிழைத் திறக்க தட்டவும். நகர்த்த இழுக்கவும்."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"குமிழ்களை எப்போது வேண்டுமானாலும் கட்டுப்படுத்தலாம்"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"இந்த ஆப்ஸிலிருந்து வரும் குமிழ்களை முடக்க, நிர்வகி என்பதைத் தட்டவும்"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"சமீபத்திய குமிழ்கள் இல்லை"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"சமீபத்திய குமிழ்களும் நிராகரிக்கப்பட்ட குமிழ்களும் இங்கே தோன்றும்"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"பபிள்"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"நிர்வகி"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"குமிழ் நிராகரிக்கப்பட்டது."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-ta/strings_tv.xml b/libs/WindowManager/Shell/res/values-ta/strings_tv.xml
new file mode 100644
index 0000000..f246069
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-ta/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(தலைப்பு இல்லை)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"PIPஐ மூடு"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"முழுத்திரை"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-te/strings.xml b/libs/WindowManager/Shell/res/values-te/strings.xml
new file mode 100644
index 0000000..0d166d8
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-te/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"మూసివేయి"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"విస్తరింపజేయి"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"సెట్టింగ్లు"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"మెనూ"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> చిత్రంలో చిత్రం రూపంలో ఉంది"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"<xliff:g id="NAME">%s</xliff:g> ఈ లక్షణాన్ని ఉపయోగించకూడదు అని మీరు అనుకుంటే, సెట్టింగ్లను తెరవడానికి ట్యాప్ చేసి, దీన్ని ఆఫ్ చేయండి."</string>
+ <string name="pip_play" msgid="3496151081459417097">"ప్లే చేయి"</string>
+ <string name="pip_pause" msgid="690688849510295232">"పాజ్ చేయి"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"దాటవేసి తర్వాత దానికి వెళ్లు"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"దాటవేసి మునుపటి దానికి వెళ్లు"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"పరిమాణం మార్చు"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"అనువర్తనంలో స్క్రీన్ విభజనకు మద్దతు లేదు."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"ప్రత్యామ్నాయ డిస్ప్లేలో యాప్ పని చేయకపోవచ్చు."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"ప్రత్యామ్నాయ డిస్ప్లేల్లో ప్రారంభానికి యాప్ మద్దతు లేదు."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"విభజన స్క్రీన్ విభాగిని"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"ఎడమవైపు పూర్తి స్క్రీన్"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"ఎడమవైపు 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"ఎడమవైపు 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"ఎడమవైపు 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"కుడివైపు పూర్తి స్క్రీన్"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"ఎగువ పూర్తి స్క్రీన్"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"ఎగువ 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"ఎగువ 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"ఎగువ 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"దిగువ పూర్తి స్క్రీన్"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"<xliff:g id="APP_NAME">%1$s</xliff:g> బబుల్స్ సెట్టింగ్లు"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"ఓవర్ఫ్లో"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"స్ట్యాక్కు తిరిగి జోడించండి"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="APP_NAME">%2$s</xliff:g> నుండి <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="APP_NAME">%2$s</xliff:g> నుండి <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> మరియు మరో <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"ఎగువ ఎడమవైపునకు జరుపు"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"ఎగువ కుడివైపునకు జరుపు"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"దిగువ ఎడమవైపునకు తరలించు"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"దిగవు కుడివైపునకు జరుపు"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> సెట్టింగ్లు"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"బబుల్ను విస్మరించు"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"సంభాషణను బబుల్ చేయవద్దు"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"బబుల్స్ను ఉపయోగించి చాట్ చేయండి"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"కొత్త సంభాషణలు తేలియాడే చిహ్నాలుగా లేదా బబుల్స్ లాగా కనిపిస్తాయి. బబుల్ని తెరవడానికి నొక్కండి. తరలించడానికి లాగండి."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"బబుల్స్ను ఎప్పుడైనా నియంత్రించండి"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"ఈ యాప్ నుండి వచ్చే బబుల్స్ను ఆఫ్ చేయడానికి మేనేజ్ బటన్ను ట్యాప్ చేయండి"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"ఇటీవలి బబుల్స్ ఏవీ లేవు"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"ఇటీవలి బబుల్స్ మరియు తీసివేసిన బబుల్స్ ఇక్కడ కనిపిస్తాయి"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"బబుల్"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"మేనేజ్ చేయండి"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"బబుల్ విస్మరించబడింది."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-te/strings_tv.xml b/libs/WindowManager/Shell/res/values-te/strings_tv.xml
new file mode 100644
index 0000000..f3019945
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-te/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(శీర్షిక లేని ప్రోగ్రామ్)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"PIPని మూసివేయి"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"పూర్తి స్క్రీన్"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-th/strings.xml b/libs/WindowManager/Shell/res/values-th/strings.xml
new file mode 100644
index 0000000..442c3ca
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-th/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"ปิด"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"ขยาย"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"การตั้งค่า"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"เมนู"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> ใช้การแสดงภาพซ้อนภาพ"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"หากคุณไม่ต้องการให้ <xliff:g id="NAME">%s</xliff:g> ใช้ฟีเจอร์นี้ ให้แตะเพื่อเปิดการตั้งค่าแล้วปิดฟีเจอร์"</string>
+ <string name="pip_play" msgid="3496151081459417097">"เล่น"</string>
+ <string name="pip_pause" msgid="690688849510295232">"หยุดชั่วคราว"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"ข้ามไปรายการถัดไป"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"ข้ามไปรายการก่อนหน้า"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"ปรับขนาด"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"แอปไม่สนับสนุนการแยกหน้าจอ"</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"แอปอาจไม่ทำงานในจอแสดงผลรอง"</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"แอปไม่รองรับการเรียกใช้ในจอแสดงผลรอง"</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"เส้นแบ่งหน้าจอ"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"เต็มหน้าจอทางซ้าย"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"ซ้าย 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"ซ้าย 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"ซ้าย 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"เต็มหน้าจอทางขวา"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"เต็มหน้าจอด้านบน"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"ด้านบน 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"ด้านบน 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"ด้านบน 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"เต็มหน้าจอด้านล่าง"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"การตั้งค่าบับเบิล <xliff:g id="APP_NAME">%1$s</xliff:g>"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"รายการเพิ่มเติม"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"เพิ่มกลับไปที่สแต็ก"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> จาก <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> จาก <xliff:g id="APP_NAME">%2$s</xliff:g> และอีก <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> รายการ"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"ย้ายไปด้านซ้ายบน"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"ย้ายไปด้านขวาบน"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"ย้ายไปด้านซ้ายล่าง"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"ย้ายไปด้านขาวล่าง"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"การตั้งค่า <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"ปิดบับเบิล"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"ไม่ต้องแสดงการสนทนาเป็นบับเบิล"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"แชทโดยใช้บับเบิล"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"การสนทนาใหม่ๆ จะปรากฏเป็นไอคอนแบบลอยหรือบับเบิล แตะเพื่อเปิดบับเบิล ลากเพื่อย้ายที่"</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"ควบคุมบับเบิลได้ทุกเมื่อ"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"แตะ \"จัดการ\" เพื่อปิดบับเบิลจากแอปนี้"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"ไม่มีบับเบิลเมื่อเร็วๆ นี้"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"บับเบิลที่แสดงและที่ปิดไปเมื่อเร็วๆ นี้จะปรากฏที่นี่"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"บับเบิล"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"จัดการ"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"ปิดบับเบิลแล้ว"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-th/strings_tv.xml b/libs/WindowManager/Shell/res/values-th/strings_tv.xml
new file mode 100644
index 0000000..cd1b612
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-th/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(ไม่มีชื่อรายการ)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"ปิด PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"เต็มหน้าจอ"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-tl/strings.xml b/libs/WindowManager/Shell/res/values-tl/strings.xml
new file mode 100644
index 0000000..1615aaef
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-tl/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Isara"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Palawakin"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Mga Setting"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Menu"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"Nasa picture-in-picture ang <xliff:g id="NAME">%s</xliff:g>"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Kung ayaw mong magamit ni <xliff:g id="NAME">%s</xliff:g> ang feature na ito, i-tap upang buksan ang mga setting at i-off ito."</string>
+ <string name="pip_play" msgid="3496151081459417097">"I-play"</string>
+ <string name="pip_pause" msgid="690688849510295232">"I-pause"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Lumaktaw sa susunod"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Lumaktaw sa nakaraan"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"I-resize"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Hindi sinusuportahan ng app ang split-screen."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Maaaring hindi gumana ang app sa pangalawang display."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Hindi sinusuportahan ng app ang paglulunsad sa mga pangalawang display."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Divider ng split-screen"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"I-full screen ang nasa kaliwa"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Gawing 70% ang nasa kaliwa"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Gawing 50% ang nasa kaliwa"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Gawing 30% ang nasa kaliwa"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"I-full screen ang nasa kanan"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"I-full screen ang nasa itaas"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Gawing 70% ang nasa itaas"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Gawing 50% ang nasa itaas"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Gawing 30% ang nasa itaas"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"I-full screen ang nasa ibaba"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Mga setting para sa mga bubble ng <xliff:g id="APP_NAME">%1$s</xliff:g>"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Overflow"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Idagdag ulit sa stack"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> mula sa <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> mula sa <xliff:g id="APP_NAME">%2$s</xliff:g> at <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> pa"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Ilipat sa kaliwa sa itaas"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Ilipat sa kanan sa itaas"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Ilipat sa kaliwa sa ibaba"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Ilipat sa kanan sa ibaba"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"Mga setting ng <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"I-dismiss ang bubble"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Huwag ipakita sa bubble ang mga pag-uusap"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Mag-chat gamit ang bubbles"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Lumalabas bilang mga nakalutang na icon o bubble ang mga bagong pag-uusap. I-tap para buksan ang bubble. I-drag para ilipat ito."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Kontrolin ang mga bubble anumang oras"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"I-tap ang Pamahalaan para i-off ang mga bubble mula sa app na ito"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Walang kamakailang bubble"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Lalabas dito ang mga kamakailang bubble at na-dismiss na bubble"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Bubble"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Pamahalaan"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Na-dismiss na ang bubble."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-tl/strings_tv.xml b/libs/WindowManager/Shell/res/values-tl/strings_tv.xml
new file mode 100644
index 0000000..d5ebb9e
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-tl/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Walang pamagat na programa)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Isara ang PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Full screen"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-tr/strings.xml b/libs/WindowManager/Shell/res/values-tr/strings.xml
new file mode 100644
index 0000000..3b987e5
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-tr/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Kapat"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Genişlet"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Ayarlar"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Menü"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g>, pencere içinde pencere özelliğini kullanıyor"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"<xliff:g id="NAME">%s</xliff:g> uygulamasının bu özelliği kullanmasını istemiyorsanız dokunarak ayarları açın ve söz konusu özelliği kapatın."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Oynat"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Duraklat"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Sonrakine atla"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Öncekine atla"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Yeniden boyutlandır"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Uygulama bölünmüş ekranı desteklemiyor."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Uygulama ikincil ekranda çalışmayabilir."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Uygulama ikincil ekranlarda başlatılmayı desteklemiyor."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Bölünmüş ekran ayırıcı"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Solda tam ekran"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Solda %70"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Solda %50"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Solda %30"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Sağda tam ekran"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Üstte tam ekran"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Üstte %70"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Üstte %50"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Üstte %30"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Altta tam ekran"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"<xliff:g id="APP_NAME">%1$s</xliff:g> baloncukları için ayarlar"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Taşma"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Yığına geri ekle"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="APP_NAME">%2$s</xliff:g> uygulamasından <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="APP_NAME">%2$s</xliff:g> uygulamasından <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> ve diğer <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Sol üste taşı"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Sağ üste taşı"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Sol alta taşı"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Sağ alta taşı"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> ayarları"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Baloncuğu kapat"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Görüşmeyi baloncuk olarak görüntüleme"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Baloncukları kullanarak sohbet edin"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Yeni görüşmeler kayan simgeler veya baloncuk olarak görünür. Açmak için baloncuğa dokunun. Baloncuğu taşımak için sürükleyin."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Baloncukları istediğiniz zaman kontrol edin"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Bu uygulamanın baloncuklarını kapatmak için Yönet\'e dokunun"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Son kapatılan baloncuk yok"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Son baloncuklar ve kapattığınız baloncuklar burada görünür"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Baloncuk"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Yönet"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Balon kapatıldı."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-tr/strings_tv.xml b/libs/WindowManager/Shell/res/values-tr/strings_tv.xml
new file mode 100644
index 0000000..8feb319
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-tr/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Başlıksız program)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"PIP\'yi kapat"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Tam ekran"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-uk/strings.xml b/libs/WindowManager/Shell/res/values-uk/strings.xml
new file mode 100644
index 0000000..6d012af
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-uk/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Закрити"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Розгорнути"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Налаштування"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Меню"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"У додатку <xliff:g id="NAME">%s</xliff:g> є функція \"Картинка в картинці\""</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Щоб додаток <xliff:g id="NAME">%s</xliff:g> не використовував цю функцію, вимкніть її в налаштуваннях."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Відтворити"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Призупинити"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Перейти далі"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Перейти назад"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Змінити розмір"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Додаток не підтримує розділення екрана."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Додаток може не працювати на додатковому екрані."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Додаток не підтримує запуск на додаткових екранах."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Розділювач екрана"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Ліве вікно на весь екран"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Ліве вікно на 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Ліве вікно на 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Ліве вікно на 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Праве вікно на весь екран"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Верхнє вікно на весь екран"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Верхнє вікно на 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Верхнє вікно на 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Верхнє вікно на 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Нижнє вікно на весь екран"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Налаштування спливаючих чатів від додатка <xliff:g id="APP_NAME">%1$s</xliff:g>"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Додаткове меню"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Додати в список"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"Cповіщення \"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>\" від додатка <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"Сповіщення \"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>\" від додатка <xliff:g id="APP_NAME">%2$s</xliff:g> (і ще <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g>)"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Перемістити ліворуч угору"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Перемістити праворуч угору"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Перемістити ліворуч униз"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Перемістити праворуч униз"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"Налаштування параметра \"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>\""</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Закрити підказку"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Не показувати спливаючі чати для розмов"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Спливаючий чат"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Нові повідомлення чату з\'являються у вигляді спливаючих значків. Щоб відкрити чат, натисніть його, а щоб перемістити – перетягніть."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Контроль спливаючих чатів"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Натисніть \"Налаштувати\", щоб вимкнути спливаючі чати від цього додатка"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Немає нещодавніх спливаючих чатів"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Тут з\'являтимуться нещодавні й закриті спливаючі чати"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Спливаюче сповіщення"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Налаштувати"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Спливаюче сповіщення закрито."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-uk/strings_tv.xml b/libs/WindowManager/Shell/res/values-uk/strings_tv.xml
new file mode 100644
index 0000000..0cc15452
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-uk/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Програма без назви)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Закрити PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"На весь екран"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-ur/strings.xml b/libs/WindowManager/Shell/res/values-ur/strings.xml
new file mode 100644
index 0000000..cd6529f0
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-ur/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"بند کریں"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"پھیلائیں"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"ترتیبات"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"مینو"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> تصویر میں تصویر میں ہے"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"اگر آپ نہیں چاہتے ہیں کہ <xliff:g id="NAME">%s</xliff:g> اس خصوصیت کا استعمال کرے تو ترتیبات کھولنے کے لیے تھپتھپا کر اسے آف کرے۔"</string>
+ <string name="pip_play" msgid="3496151081459417097">"چلائیں"</string>
+ <string name="pip_pause" msgid="690688849510295232">"موقوف کریں"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"نظرانداز کرکے اگلے پر جائیں"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"نظرانداز کرکے پچھلے پر جائیں"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"سائز تبدیل کریں"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"ایپ سپلٹ اسکرین کو سپورٹ نہیں کرتی۔"</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"ممکن ہے ایپ ثانوی ڈسپلے پر کام نہ کرے۔"</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"ایپ ثانوی ڈسپلیز پر شروعات کا تعاون نہیں کرتی۔"</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"سپلٹ اسکرین تقسیم کار"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"بائیں فل اسکرین"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"بائیں %70"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"بائیں %50"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"بائیں %30"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"دائیں فل اسکرین"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"بالائی فل اسکرین"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"اوپر %70"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"اوپر %50"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"اوپر %30"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"نچلی فل اسکرین"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"<xliff:g id="APP_NAME">%1$s</xliff:g> بلبلوں کے لیے ترتیبات"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"اوورفلو"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"انبار میں واپس شامل کریں"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="APP_NAME">%2$s</xliff:g> کی جانب سے <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="APP_NAME">%2$s</xliff:g> اور <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> مزید سے <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"اوپر بائیں جانب لے جائیں"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"اوپر دائیں جانب لے جائيں"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"نیچے بائیں جانب لے جائیں"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"نیچے دائیں جانب لے جائیں"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> ترتیبات"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"بلبلہ برخاست کریں"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"گفتگو بلبلہ نہ کریں"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"بلبلے کے ذریعے چیٹ کریں"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"نئی گفتگوئیں فلوٹنگ آئیکن یا بلبلے کے طور پر ظاہر ہوں گی۔ بلبلہ کھولنے کے لیے تھپتھپائیں۔ اسے منتقل کرنے کے لیے گھسیٹیں۔"</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"کسی بھی وقت بلبلے کو کنٹرول کریں"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"اس ایپ سے بلبلوں کو آف کرنے کے لیے نظم کریں پر تھپتھپائیں"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"کوئی حالیہ بلبلہ نہیں"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"حالیہ بلبلے اور برخاست شدہ بلبلے یہاں ظاہر ہوں گے"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"بلبلہ"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"نظم کریں"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"بلبلہ برخاست کر دیا گیا۔"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-ur/strings_tv.xml b/libs/WindowManager/Shell/res/values-ur/strings_tv.xml
new file mode 100644
index 0000000..64e5db5
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-ur/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(بلا عنوان پروگرام)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"PIP بند کریں"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"فُل اسکرین"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-uz/strings.xml b/libs/WindowManager/Shell/res/values-uz/strings.xml
new file mode 100644
index 0000000..b714f59
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-uz/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Yopish"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Yoyish"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Sozlamalar"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Menyu"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> tasvir ustida tasvir rejimida"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"<xliff:g id="NAME">%s</xliff:g> ilovasi uchun bu funksiyani sozlamalar orqali faolsizlantirish mumkin."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Ijro"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Pauza"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Keyingisiga o‘tish"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Avvalgisiga qaytish"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Oʻlchamini oʻzgartirish"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Bu ilova ekranni bo‘lish xususiyatini qo‘llab-quvvatlamaydi."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Bu ilova qo‘shimcha ekranda ishlamasligi mumkin."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Bu ilova qo‘shimcha ekranlarda ishga tushmaydi."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Ekranni ikkiga bo‘lish chizig‘i"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Chapda to‘liq ekran"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Chapda 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Chapda 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Chapda 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"O‘ngda to‘liq ekran"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Tepada to‘liq ekran"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Tepada 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Tepada 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Tepada 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Pastda to‘liq ekran"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"<xliff:g id="APP_NAME">%1$s</xliff:g> bulutchalari uchun sozlamalar"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Kengaytirilgan"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Yana toʻplamga kiritish"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>, <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="APP_NAME">%2$s</xliff:g> ilovasidan <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> va yana <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> ta bildirishnoma"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Yuqori chapga surish"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Yuqori oʻngga surish"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Quyi chapga surish"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Quyi oʻngga surish"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> sozlamalari"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Bulutchani yopish"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Suhbatlar bulutchalar shaklida chiqmasin"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Bulutchalar yordamida subhatlashish"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Yangi xabarlar qalqib chiquvchi belgilar yoki bulutchalar kabi chiqadi. Xabarni ochish uchun bildirishnoma ustiga bosing. Xabarni qayta joylash uchun bildirishnomani suring."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Bulutchalardagi bildirishnomalar"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Bu ilova bulutchalarini faolsizlantirish uchun Boshqarish tugmasini bosing"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Avvalgi bulutchalar topilmadi"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Bu yerda oxirgi va yopilgan bulutcha shaklidagi bildirishnomalar chiqadi"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Pufaklar"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Boshqarish"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Bulutcha yopildi."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-uz/strings_tv.xml b/libs/WindowManager/Shell/res/values-uz/strings_tv.xml
new file mode 100644
index 0000000..a0abb3d
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-uz/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Nomsiz)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Kadr ichida kadr – chiqish"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Butun ekran"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-vi/strings.xml b/libs/WindowManager/Shell/res/values-vi/strings.xml
new file mode 100644
index 0000000..be6f844
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-vi/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Đóng"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Mở rộng"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Cài đặt"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Menu"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g> đang ở chế độ ảnh trong ảnh"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Nếu bạn không muốn <xliff:g id="NAME">%s</xliff:g> sử dụng tính năng này, hãy nhấn để mở cài đặt và tắt tính năng này."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Phát"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Tạm dừng"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Chuyển tới mục tiếp theo"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Chuyển về mục trước"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Đổi kích thước"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Ứng dụng không hỗ trợ chia đôi màn hình."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Ứng dụng có thể không hoạt động trên màn hình phụ."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Ứng dụng không hỗ trợ khởi chạy trên màn hình phụ."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Bộ chia chia đôi màn hình"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Toàn màn hình bên trái"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Trái 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Trái 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Trái 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Toàn màn hình bên phải"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Toàn màn hình phía trên"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Trên 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Trên 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Trên 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Toàn màn hình phía dưới"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Tùy chọn cài đặt cho bong bóng trò chuyện <xliff:g id="APP_NAME">%1$s</xliff:g>"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Trình đơn mục bổ sung"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Thêm lại vào ngăn xếp"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> của <xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> từ <xliff:g id="APP_NAME">%2$s</xliff:g> và <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> bong bóng khác"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Chuyển lên trên cùng bên trái"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Chuyển lên trên cùng bên phải"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Chuyển tới dưới cùng bên trái"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Chuyển tới dưới cùng bên phải"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"Cài đặt <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Đóng bong bóng"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Dừng sử dụng bong bóng cho cuộc trò chuyện"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Trò chuyện bằng bong bóng trò chuyện"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Các cuộc trò chuyện mới sẽ xuất hiện dưới dạng biểu tượng nổi hoặc bong bóng trò chuyện. Nhấn để mở bong bóng trò chuyện. Kéo để di chuyển bong bóng trò chuyện."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Kiểm soát bong bóng bất cứ lúc nào"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Nhấn vào nút Quản lý để tắt bong bóng trò chuyện từ ứng dụng này"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Không có bong bóng trò chuyện nào gần đây"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Bong bóng trò chuyện đã đóng và bong bóng trò chuyện gần đây sẽ xuất hiện ở đây"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Bong bóng"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Quản lý"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Đã đóng bong bóng."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-vi/strings_tv.xml b/libs/WindowManager/Shell/res/values-vi/strings_tv.xml
new file mode 100644
index 0000000..093ef13
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-vi/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Không có chương trình tiêu đề)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Đóng PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Toàn màn hình"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-zh-rCN/strings.xml b/libs/WindowManager/Shell/res/values-zh-rCN/strings.xml
new file mode 100644
index 0000000..b17e35e
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-zh-rCN/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"关闭"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"展开"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"设置"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"菜单"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"<xliff:g id="NAME">%s</xliff:g>目前位于“画中画”中"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"如果您不想让“<xliff:g id="NAME">%s</xliff:g>”使用此功能,请点按以打开设置,然后关闭此功能。"</string>
+ <string name="pip_play" msgid="3496151081459417097">"播放"</string>
+ <string name="pip_pause" msgid="690688849510295232">"暂停"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"跳到下一个"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"跳到上一个"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"调整大小"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"应用不支持分屏。"</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"应用可能无法在辅显示屏上正常运行。"</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"应用不支持在辅显示屏上启动。"</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"分屏分隔线"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"左侧全屏"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"左侧 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"左侧 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"左侧 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"右侧全屏"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"顶部全屏"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"顶部 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"顶部 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"顶部 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"底部全屏"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"<xliff:g id="APP_NAME">%1$s</xliff:g>对话泡的设置"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"菜单"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"重新加入叠放"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="APP_NAME">%2$s</xliff:g>:<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"<xliff:g id="APP_NAME">%2$s</xliff:g>和另外 <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> 个应用:<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"移至左上角"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"移至右上角"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"移至左下角"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"移至右下角"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>设置"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"关闭对话泡"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"不以对话泡形式显示对话"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"使用对话泡聊天"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"新对话会以浮动图标或对话泡形式显示。点按即可打开对话泡。拖动即可移动对话泡。"</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"随时控制对话泡"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"点按“管理”按钮,可关闭来自此应用的对话泡"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"最近没有对话泡"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"此处会显示最近的对话泡和已关闭的对话泡"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"气泡"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"管理"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"已关闭对话泡。"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-zh-rCN/strings_tv.xml b/libs/WindowManager/Shell/res/values-zh-rCN/strings_tv.xml
new file mode 100644
index 0000000..0b65fd3
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-zh-rCN/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(节目没有标题)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"关闭画中画"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"全屏"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-zh-rHK/strings.xml b/libs/WindowManager/Shell/res/values-zh-rHK/strings.xml
new file mode 100644
index 0000000..88d28df
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-zh-rHK/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"關閉"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"展開"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"設定"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"選單"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"「<xliff:g id="NAME">%s</xliff:g>」目前在畫中畫模式"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"如果您不想「<xliff:g id="NAME">%s</xliff:g>」使用此功能,請輕按以開啟設定,然後停用此功能。"</string>
+ <string name="pip_play" msgid="3496151081459417097">"播放"</string>
+ <string name="pip_pause" msgid="690688849510295232">"暫停"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"跳到下一個"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"跳到上一個"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"調整大小"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"應用程式不支援分割畫面。"</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"應用程式可能無法在次要顯示屏上運作。"</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"應用程式無法在次要顯示屏上啟動。"</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"分割畫面分隔線"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"左邊全螢幕"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"左邊 70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"左邊 50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"左邊 30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"右邊全螢幕"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"頂部全螢幕"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"頂部 70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"頂部 50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"頂部 30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"底部全螢幕"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"「<xliff:g id="APP_NAME">%1$s</xliff:g>」小視窗設定"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"顯示更多"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"加回堆疊"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"來自「<xliff:g id="APP_NAME">%2$s</xliff:g>」的 <xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"來自「<xliff:g id="APP_NAME">%2$s</xliff:g>」及另外 <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> 個應用程式的<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"移去左上角"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"移去右上角"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"移去左下角"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"移去右下角"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"「<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>」設定"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"關閉小視窗氣泡"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"不要透過小視窗顯示對話"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"使用小視窗進行即時通訊"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"新對話會以浮動圖示 (小視窗) 顯示。輕按即可開啟小視窗。拖曳即可移動小視窗。"</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"隨時控制小視窗設定"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"輕按「管理」即可關閉此應用程式的小視窗"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"沒有最近曾使用的小視窗"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"最近使用和關閉的小視窗會在這裡顯示"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"氣泡"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"管理"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"對話氣泡已關閉。"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-zh-rHK/strings_tv.xml b/libs/WindowManager/Shell/res/values-zh-rHK/strings_tv.xml
new file mode 100644
index 0000000..74fc374
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-zh-rHK/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(沒有標題的節目)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"關閉 PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"全螢幕"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-zh-rTW/strings.xml b/libs/WindowManager/Shell/res/values-zh-rTW/strings.xml
new file mode 100644
index 0000000..2530db7
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-zh-rTW/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"關閉"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"展開"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"設定"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"選單"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"「<xliff:g id="NAME">%s</xliff:g>」目前在子母畫面中"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"如果你不想讓「<xliff:g id="NAME">%s</xliff:g>」使用這項功能,請輕觸開啟設定頁面,然後停用此功能。"</string>
+ <string name="pip_play" msgid="3496151081459417097">"播放"</string>
+ <string name="pip_pause" msgid="690688849510295232">"暫停"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"跳到下一個"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"跳到上一個"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"調整大小"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"這個應用程式不支援分割畫面。"</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"應用程式可能無法在次要顯示器上運作。"</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"應用程式無法在次要顯示器上啟動。"</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"分割畫面分隔線"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"以全螢幕顯示左側畫面"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"以 70% 的螢幕空間顯示左側畫面"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"以 50% 的螢幕空間顯示左側畫面"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"以 30% 的螢幕空間顯示左側畫面"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"以全螢幕顯示右側畫面"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"以全螢幕顯示頂端畫面"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"以 70% 的螢幕空間顯示頂端畫面"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"以 50% 的螢幕空間顯示頂端畫面"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"以 30% 的螢幕空間顯示頂端畫面"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"以全螢幕顯示底部畫面"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"「<xliff:g id="APP_NAME">%1$s</xliff:g>」對話框的設定"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"溢位"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"重新加入堆疊"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"<xliff:g id="APP_NAME">%2$s</xliff:g>:<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"「<xliff:g id="APP_NAME">%2$s</xliff:g>」和其他 <xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> 個應用程式:<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"移至左上方"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"移至右上方"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"移至左下方"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"移至右下方"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"「<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g>」設定"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"關閉對話框"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"不要以對話框形式顯示對話"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"透過對話框來聊天"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"新的對話會以浮動圖示或對話框形式顯示。輕觸即可開啟對話框,拖曳則可移動對話框。"</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"你隨時可以控管對話框的各項設定"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"輕觸 [管理] 即可關閉來自這個應用程式的對話框"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"最近沒有任何對話框"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"最近的對話框和已關閉的對話框會顯示在這裡"</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"泡泡"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"管理"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"已關閉泡泡。"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-zh-rTW/strings_tv.xml b/libs/WindowManager/Shell/res/values-zh-rTW/strings_tv.xml
new file mode 100644
index 0000000..e7d1ca98
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-zh-rTW/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(無標題的節目)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"關閉子母畫面"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"全螢幕"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-zu/strings.xml b/libs/WindowManager/Shell/res/values-zu/strings.xml
new file mode 100644
index 0000000..72fdc9c
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-zu/strings.xml
@@ -0,0 +1,78 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <string name="pip_phone_close" msgid="5783752637260411309">"Vala"</string>
+ <string name="pip_phone_expand" msgid="2579292903468287504">"Nweba"</string>
+ <string name="pip_phone_settings" msgid="5468987116750491918">"Izilungiselelo"</string>
+ <string name="pip_menu_title" msgid="5393619322111827096">"Imenyu"</string>
+ <string name="pip_notification_title" msgid="1347104727641353453">"U-<xliff:g id="NAME">%s</xliff:g> ungaphakathi kwesithombe esiphakathi kwesithombe"</string>
+ <string name="pip_notification_message" msgid="8854051911700302620">"Uma ungafuni i-<xliff:g id="NAME">%s</xliff:g> ukuthi isebenzise lesi sici, thepha ukuze uvule izilungiselelo uphinde uyivale."</string>
+ <string name="pip_play" msgid="3496151081459417097">"Dlala"</string>
+ <string name="pip_pause" msgid="690688849510295232">"Misa isikhashana"</string>
+ <string name="pip_skip_to_next" msgid="8403429188794867653">"Yeqela kokulandelayo"</string>
+ <string name="pip_skip_to_prev" msgid="7172158111196394092">"Yeqela kokwangaphambilini"</string>
+ <string name="accessibility_action_pip_resize" msgid="4623966104749543182">"Shintsha usayizi"</string>
+ <!-- no translation found for dock_forced_resizable (1749750436092293116) -->
+ <skip />
+ <string name="dock_non_resizeble_failed_to_dock_text" msgid="7408396418008948957">"Uhlelo lokusebenza alusekeli isikrini esihlukanisiwe."</string>
+ <string name="forced_resizable_secondary_display" msgid="1768046938673582671">"Uhlelo lokusebenza kungenzeka lungasebenzi kusibonisi sesibili."</string>
+ <string name="activity_launch_on_secondary_display_failed_text" msgid="4226485344988071769">"Uhlelo lokusebenza alusekeli ukuqalisa kuzibonisi zesibili."</string>
+ <string name="accessibility_divider" msgid="703810061635792791">"Isihlukanisi sokuhlukanisa isikrini"</string>
+ <string name="accessibility_action_divider_left_full" msgid="1792313656305328536">"Isikrini esigcwele esingakwesokunxele"</string>
+ <string name="accessibility_action_divider_left_70" msgid="8859845045360659250">"Kwesokunxele ngo-70%"</string>
+ <string name="accessibility_action_divider_left_50" msgid="3488317024557521561">"Kwesokunxele ngo-50%"</string>
+ <string name="accessibility_action_divider_left_30" msgid="6023611335723838727">"Kwesokunxele ngo-30%"</string>
+ <string name="accessibility_action_divider_right_full" msgid="3408505054325944903">"Isikrini esigcwele esingakwesokudla"</string>
+ <string name="accessibility_action_divider_top_full" msgid="3495871951082107594">"Isikrini esigcwele esiphezulu"</string>
+ <string name="accessibility_action_divider_top_70" msgid="1779164068887875474">"Okuphezulu okungu-70%"</string>
+ <string name="accessibility_action_divider_top_50" msgid="8649582798829048946">"Okuphezulu okungu-50%"</string>
+ <string name="accessibility_action_divider_top_30" msgid="3572788224908570257">"Okuphezulu okungu-30%"</string>
+ <string name="accessibility_action_divider_bottom_full" msgid="2831868345092314060">"Ngaphansi kwesikrini esigcwele"</string>
+ <!-- no translation found for one_handed_tutorial_title (4583241688067426350) -->
+ <skip />
+ <!-- no translation found for one_handed_tutorial_description (3486582858591353067) -->
+ <skip />
+ <!-- no translation found for accessibility_action_start_one_handed (5070337354072861426) -->
+ <skip />
+ <!-- no translation found for accessibility_action_stop_one_handed (1369940261782179442) -->
+ <skip />
+ <string name="bubbles_settings_button_description" msgid="1301286017420516912">"Izilungiselelo zamabhamuza e-<xliff:g id="APP_NAME">%1$s</xliff:g>"</string>
+ <string name="bubble_overflow_button_content_description" msgid="8160974472718594382">"Ukuphuphuma"</string>
+ <string name="bubble_accessibility_action_add_back" msgid="1830101076853540953">"Engeza emuva kusitaki"</string>
+ <string name="bubble_content_description_single" msgid="8495748092720065813">"I-<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> kusuka ku-<xliff:g id="APP_NAME">%2$s</xliff:g>"</string>
+ <string name="bubble_content_description_stack" msgid="8071515017164630429">"I-<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> kusukela ku-<xliff:g id="APP_NAME">%2$s</xliff:g> nokungu-<xliff:g id="BUBBLE_COUNT">%3$d</xliff:g> ngaphezulu"</string>
+ <string name="bubble_accessibility_action_move_top_left" msgid="2644118920500782758">"Hambisa phezulu kwesokunxele"</string>
+ <string name="bubble_accessibility_action_move_top_right" msgid="5864594920870245525">"Hambisa phezulu ngakwesokudla"</string>
+ <string name="bubble_accessibility_action_move_bottom_left" msgid="850271002773745634">"Hambisa inkinobho ngakwesokunxele"</string>
+ <string name="bubble_accessibility_action_move_bottom_right" msgid="2107626346109206352">"Hambisa inkinobho ngakwesokudla"</string>
+ <string name="bubbles_app_settings" msgid="3617224938701566416">"<xliff:g id="NOTIFICATION_TITLE">%1$s</xliff:g> izilungiselelo"</string>
+ <string name="bubble_dismiss_text" msgid="8816558050659478158">"Cashisa ibhamuza"</string>
+ <string name="bubbles_dont_bubble_conversation" msgid="310000317885712693">"Ungayibhamuzi ingxoxo"</string>
+ <string name="bubbles_user_education_title" msgid="2112319053732691899">"Xoxa usebenzisa amabhamuza"</string>
+ <string name="bubbles_user_education_description" msgid="4215862563054175407">"Izingxoxo ezintsha zivela njengezithonjana ezintantayo, noma amabhamuza. Thepha ukuze uvule ibhamuza. Hudula ukuze ulihambise."</string>
+ <string name="bubbles_user_education_manage_title" msgid="7042699946735628035">"Lawula amabhamuza noma nini"</string>
+ <string name="bubbles_user_education_manage" msgid="3460756219946517198">"Thepha okuthi Phatha ukuvala amabhamuza kusuka kulolu hlelo lokusebenza"</string>
+ <!-- no translation found for bubbles_user_education_got_it (3382046149225428296) -->
+ <skip />
+ <string name="bubble_overflow_empty_title" msgid="2397251267073294968">"Awekho amabhamuza akamuva"</string>
+ <string name="bubble_overflow_empty_subtitle" msgid="2627417924958633713">"Amabhamuza akamuva namabhamuza asusiwe azobonakala lapha."</string>
+ <string name="notification_bubble_title" msgid="6082910224488253378">"Ibhamuza"</string>
+ <string name="manage_bubbles_text" msgid="7730624269650594419">"Phatha"</string>
+ <string name="accessibility_bubble_dismissed" msgid="8367471990421247357">"Ibhamuza licashisiwe."</string>
+</resources>
diff --git a/libs/WindowManager/Shell/res/values-zu/strings_tv.xml b/libs/WindowManager/Shell/res/values-zu/strings_tv.xml
new file mode 100644
index 0000000..62fc4c4
--- /dev/null
+++ b/libs/WindowManager/Shell/res/values-zu/strings_tv.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Copyright (C) 2020 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ -->
+
+<resources xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
+ <!-- no translation found for notification_channel_tv_pip (2576686079160402435) -->
+ <skip />
+ <string name="pip_notification_unknown_title" msgid="2729870284350772311">"(Alukho uhlelo lwesihloko)"</string>
+ <string name="pip_close" msgid="9135220303720555525">"Vala i-PIP"</string>
+ <string name="pip_fullscreen" msgid="7278047353591302554">"Iskrini esigcwele"</string>
+</resources>
diff --git a/libs/WindowManager/Shell/src/com/android/wm/shell/ShellDump.java b/libs/WindowManager/Shell/src/com/android/wm/shell/ShellDump.java
index bb9accd..13089af 100644
--- a/libs/WindowManager/Shell/src/com/android/wm/shell/ShellDump.java
+++ b/libs/WindowManager/Shell/src/com/android/wm/shell/ShellDump.java
@@ -16,6 +16,7 @@
package com.android.wm.shell;
+import com.android.wm.shell.apppairs.AppPairs;
import com.android.wm.shell.hidedisplaycutout.HideDisplayCutout;
import com.android.wm.shell.onehanded.OneHanded;
import com.android.wm.shell.pip.Pip;
@@ -34,17 +35,20 @@
private final Optional<OneHanded> mOneHandedOptional;
private final Optional<HideDisplayCutout> mHideDisplayCutout;
private final ShellTaskOrganizer mShellTaskOrganizer;
+ private final Optional<AppPairs> mAppPairsOptional;
public ShellDump(ShellTaskOrganizer shellTaskOrganizer,
Optional<SplitScreen> splitScreenOptional,
Optional<Pip> pipOptional,
Optional<OneHanded> oneHandedOptional,
- Optional<HideDisplayCutout> hideDisplayCutout) {
+ Optional<HideDisplayCutout> hideDisplayCutout,
+ Optional<AppPairs> appPairsOptional) {
mShellTaskOrganizer = shellTaskOrganizer;
mSplitScreenOptional = splitScreenOptional;
mPipOptional = pipOptional;
mOneHandedOptional = oneHandedOptional;
mHideDisplayCutout = hideDisplayCutout;
+ mAppPairsOptional = appPairsOptional;
}
public void dump(PrintWriter pw) {
@@ -55,5 +59,8 @@
mSplitScreenOptional.ifPresent(splitScreen -> splitScreen.dump(pw));
mOneHandedOptional.ifPresent(oneHanded -> oneHanded.dump(pw));
mHideDisplayCutout.ifPresent(hideDisplayCutout -> hideDisplayCutout.dump(pw));
+ pw.println();
+ pw.println();
+ mAppPairsOptional.ifPresent(appPairs -> appPairs.dump(pw, ""));
}
}
diff --git a/libs/WindowManager/Shell/src/com/android/wm/shell/ShellInit.java b/libs/WindowManager/Shell/src/com/android/wm/shell/ShellInit.java
index 4269a90..d654f8a 100644
--- a/libs/WindowManager/Shell/src/com/android/wm/shell/ShellInit.java
+++ b/libs/WindowManager/Shell/src/com/android/wm/shell/ShellInit.java
@@ -16,6 +16,7 @@
package com.android.wm.shell;
+import com.android.wm.shell.apppairs.AppPairs;
import com.android.wm.shell.common.DisplayImeController;
import com.android.wm.shell.draganddrop.DragAndDropController;
import com.android.wm.shell.splitscreen.SplitScreen;
@@ -31,15 +32,18 @@
private final DragAndDropController mDragAndDropController;
private final ShellTaskOrganizer mShellTaskOrganizer;
private final Optional<SplitScreen> mSplitScreenOptional;
+ private final Optional<AppPairs> mAppPairsOptional;
public ShellInit(DisplayImeController displayImeController,
DragAndDropController dragAndDropController,
ShellTaskOrganizer shellTaskOrganizer,
- Optional<SplitScreen> splitScreenOptional) {
+ Optional<SplitScreen> splitScreenOptional,
+ Optional<AppPairs> appPairsOptional) {
mDisplayImeController = displayImeController;
mDragAndDropController = dragAndDropController;
mShellTaskOrganizer = shellTaskOrganizer;
mSplitScreenOptional = splitScreenOptional;
+ mAppPairsOptional = appPairsOptional;
}
public void init() {
@@ -47,6 +51,7 @@
mDisplayImeController.startMonitorDisplays();
// Register the shell organizer
mShellTaskOrganizer.registerOrganizer();
+ mAppPairsOptional.ifPresent(AppPairs::onOrganizerRegistered);
// Bind the splitscreen impl to the drag drop controller
mDragAndDropController.setSplitScreenController(mSplitScreenOptional);
}
diff --git a/libs/WindowManager/Shell/src/com/android/wm/shell/ShellTaskOrganizer.java b/libs/WindowManager/Shell/src/com/android/wm/shell/ShellTaskOrganizer.java
index ece063c..006fd9d 100644
--- a/libs/WindowManager/Shell/src/com/android/wm/shell/ShellTaskOrganizer.java
+++ b/libs/WindowManager/Shell/src/com/android/wm/shell/ShellTaskOrganizer.java
@@ -26,7 +26,6 @@
import android.annotation.IntDef;
import android.app.ActivityManager.RunningTaskInfo;
-import android.app.WindowConfiguration.WindowingMode;
import android.content.Context;
import android.os.Binder;
import android.os.IBinder;
@@ -39,6 +38,7 @@
import android.window.TaskOrganizer;
import androidx.annotation.NonNull;
+import androidx.annotation.Nullable;
import com.android.internal.annotations.VisibleForTesting;
import com.android.internal.protolog.common.ProtoLog;
@@ -309,6 +309,15 @@
}
}
+ /** Gets running task by taskId. Returns {@code null} if no such task observed. */
+ @Nullable
+ public RunningTaskInfo getRunningTaskInfo(int taskId) {
+ synchronized (mLock) {
+ final TaskAppearedInfo info = mTasks.get(taskId);
+ return info != null ? info.getTaskInfo() : null;
+ }
+ }
+
private boolean updateTaskListenerIfNeeded(RunningTaskInfo taskInfo, SurfaceControl leash,
TaskListener oldListener, TaskListener newListener) {
if (oldListener == newListener) return false;
diff --git a/libs/WindowManager/Shell/src/com/android/wm/shell/apppairs/AppPair.java b/libs/WindowManager/Shell/src/com/android/wm/shell/apppairs/AppPair.java
new file mode 100644
index 0000000..d30acee
--- /dev/null
+++ b/libs/WindowManager/Shell/src/com/android/wm/shell/apppairs/AppPair.java
@@ -0,0 +1,208 @@
+/*
+ * Copyright (C) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package com.android.wm.shell.apppairs;
+
+import static android.app.ActivityTaskManager.INVALID_TASK_ID;
+import static android.app.WindowConfiguration.WINDOWING_MODE_MULTI_WINDOW;
+import static android.app.WindowConfiguration.WINDOWING_MODE_UNDEFINED;
+
+import static com.android.wm.shell.protolog.ShellProtoLogGroup.WM_SHELL_TASK_ORG;
+
+import android.app.ActivityManager;
+import android.graphics.Rect;
+import android.view.SurfaceControl;
+import android.window.WindowContainerToken;
+import android.window.WindowContainerTransaction;
+
+import androidx.annotation.NonNull;
+
+import com.android.internal.protolog.common.ProtoLog;
+import com.android.wm.shell.ShellTaskOrganizer;
+import com.android.wm.shell.common.SyncTransactionQueue;
+
+import java.io.PrintWriter;
+
+/**
+ * An app-pairs consisting of {@link #mRootTaskInfo} that acts as the hierarchy parent of
+ * {@link #mTaskInfo1} and {@link #mTaskInfo2} in the pair.
+ * Also includes all UI for managing the pair like the divider.
+ */
+// TODO: Add divider
+// TODO: Handle display rotation
+class AppPair implements ShellTaskOrganizer.TaskListener {
+ private static final String TAG = AppPair.class.getSimpleName();
+
+ private ActivityManager.RunningTaskInfo mRootTaskInfo;
+ private SurfaceControl mRootTaskLeash;
+ private ActivityManager.RunningTaskInfo mTaskInfo1;
+ private SurfaceControl mTaskLeash1;
+ private ActivityManager.RunningTaskInfo mTaskInfo2;
+ private SurfaceControl mTaskLeash2;
+
+ private final AppPairsController mController;
+ private final SyncTransactionQueue mSyncQueue;
+
+ AppPair(AppPairsController controller) {
+ mController = controller;
+ mSyncQueue = controller.getSyncTransactionQueue();
+ }
+
+ int getRootTaskId() {
+ return mRootTaskInfo != null ? mRootTaskInfo.taskId : INVALID_TASK_ID;
+ }
+
+ private int getTaskId1() {
+ return mTaskInfo1 != null ? mTaskInfo1.taskId : INVALID_TASK_ID;
+ }
+
+ private int getTaskId2() {
+ return mTaskInfo2 != null ? mTaskInfo2.taskId : INVALID_TASK_ID;
+ }
+
+ boolean contains(int taskId) {
+ return taskId == getRootTaskId() || taskId == getTaskId1() || taskId == getTaskId2();
+ }
+
+ boolean pair(ActivityManager.RunningTaskInfo task1, ActivityManager.RunningTaskInfo task2) {
+ ProtoLog.v(WM_SHELL_TASK_ORG, "pair task1=%d task2=%d in AppPair=%s",
+ task1.taskId, task2.taskId, this);
+
+ if (!task1.isResizeable || !task2.isResizeable) {
+ ProtoLog.e(WM_SHELL_TASK_ORG,
+ "Can't pair unresizeable tasks task1.isResizeable=%b task1.isResizeable=%b",
+ task1.isResizeable, task2.isResizeable);
+ return false;
+ }
+
+ mTaskInfo1 = task1;
+ mTaskInfo2 = task2;
+
+ // TODO: properly calculate bounds for pairs.
+ final Rect rootBounds = mRootTaskInfo.configuration.windowConfiguration.getBounds();
+ final Rect bounds1 = new Rect(
+ rootBounds.left, rootBounds.top, rootBounds.right / 2, rootBounds.bottom / 2);
+ final Rect bounds2 = new Rect(
+ bounds1.right, bounds1.bottom, rootBounds.right, rootBounds.bottom);
+ final WindowContainerToken token1 = task1.token;
+ final WindowContainerToken token2 = task2.token;
+ final WindowContainerTransaction wct = new WindowContainerTransaction();
+
+ wct.setHidden(mRootTaskInfo.token, false)
+ .reparent(token1, mRootTaskInfo.token, true /* onTop */)
+ .reparent(token2, mRootTaskInfo.token, true /* onTop */)
+ .setWindowingMode(token1, WINDOWING_MODE_MULTI_WINDOW)
+ .setWindowingMode(token2, WINDOWING_MODE_MULTI_WINDOW)
+ .setBounds(token1, bounds1)
+ .setBounds(token2, bounds2)
+ // Moving the root task to top after the child tasks were repareted , or the root
+ // task cannot be visible and focused.
+ .reorder(mRootTaskInfo.token, true);
+ mController.getTaskOrganizer().applyTransaction(wct);
+ return true;
+ }
+
+ void unpair() {
+ final WindowContainerToken token1 = mTaskInfo1.token;
+ final WindowContainerToken token2 = mTaskInfo2.token;
+ final WindowContainerTransaction wct = new WindowContainerTransaction();
+
+ // Reparent out of this container and reset windowing mode.
+ wct.setHidden(mRootTaskInfo.token, true)
+ .reorder(mRootTaskInfo.token, false)
+ .reparent(token1, null, false /* onTop */)
+ .reparent(token2, null, false /* onTop */)
+ .setWindowingMode(token1, WINDOWING_MODE_UNDEFINED)
+ .setWindowingMode(token2, WINDOWING_MODE_UNDEFINED);
+ mController.getTaskOrganizer().applyTransaction(wct);
+
+ mTaskInfo1 = null;
+ mTaskInfo2 = null;
+ }
+
+ @Override
+ public void onTaskAppeared(ActivityManager.RunningTaskInfo taskInfo, SurfaceControl leash) {
+ if (mRootTaskInfo == null || taskInfo.taskId == mRootTaskInfo.taskId) {
+ mRootTaskInfo = taskInfo;
+ mRootTaskLeash = leash;
+ } else if (taskInfo.taskId == getTaskId1()) {
+ mTaskInfo1 = taskInfo;
+ mTaskLeash1 = leash;
+ } else if (taskInfo.taskId == getTaskId2()) {
+ mTaskInfo2 = taskInfo;
+ mTaskLeash2 = leash;
+ } else {
+ throw new IllegalStateException("Unknown task=" + taskInfo.taskId);
+ }
+
+ if (mTaskLeash1 == null || mTaskLeash2 == null) return;
+
+ // TODO: Is there more we need to do here?
+ mSyncQueue.runInSync(t -> t
+ .setPosition(mTaskLeash1, mTaskInfo1.positionInParent.x,
+ mTaskInfo1.positionInParent.y)
+ .setPosition(mTaskLeash2, mTaskInfo2.positionInParent.x,
+ mTaskInfo2.positionInParent.y)
+ .show(mRootTaskLeash)
+ .show(mTaskLeash1)
+ .show(mTaskLeash2));
+ }
+
+ @Override
+ public void onTaskInfoChanged(ActivityManager.RunningTaskInfo taskInfo) {
+ if (taskInfo.taskId == getRootTaskId()) {
+ mRootTaskInfo = taskInfo;
+ } else if (taskInfo.taskId == getTaskId1()) {
+ mTaskInfo1 = taskInfo;
+ } else if (taskInfo.taskId == getTaskId2()) {
+ mTaskInfo2 = taskInfo;
+ } else {
+ throw new IllegalStateException("Unknown task=" + taskInfo.taskId);
+ }
+ }
+
+ @Override
+ public void onTaskVanished(ActivityManager.RunningTaskInfo taskInfo) {
+ if (taskInfo.taskId == getRootTaskId()) {
+ // We don't want to release this object back to the pool since the root task went away.
+ mController.unpair(mRootTaskInfo.taskId, false /* releaseToPool */);
+ } else if (taskInfo.taskId == getTaskId1() || taskInfo.taskId == getTaskId2()) {
+ mController.unpair(mRootTaskInfo.taskId);
+ }
+ }
+
+ @Override
+ public void dump(@NonNull PrintWriter pw, String prefix) {
+ final String innerPrefix = prefix + " ";
+ final String childPrefix = innerPrefix + " ";
+ pw.println(prefix + this);
+ pw.println(innerPrefix + "Root taskId=" + getRootTaskId()
+ + " winMode=" + mRootTaskInfo.getWindowingMode());
+ if (mTaskInfo1 != null) {
+ pw.println(innerPrefix + "1 taskId=" + mTaskInfo1.taskId
+ + " winMode=" + mTaskInfo1.getWindowingMode());
+ }
+ if (mTaskInfo2 != null) {
+ pw.println(innerPrefix + "2 taskId=" + mTaskInfo2.taskId
+ + " winMode=" + mTaskInfo2.getWindowingMode());
+ }
+ }
+
+ @Override
+ public String toString() {
+ return TAG + "#" + getRootTaskId();
+ }
+}
diff --git a/libs/WindowManager/Shell/src/com/android/wm/shell/apppairs/AppPairs.java b/libs/WindowManager/Shell/src/com/android/wm/shell/apppairs/AppPairs.java
new file mode 100644
index 0000000..ef3e3e0
--- /dev/null
+++ b/libs/WindowManager/Shell/src/com/android/wm/shell/apppairs/AppPairs.java
@@ -0,0 +1,39 @@
+/*
+ * Copyright (C) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package com.android.wm.shell.apppairs;
+
+import android.app.ActivityManager;
+
+import androidx.annotation.NonNull;
+
+import java.io.PrintWriter;
+
+/**
+ * Interface to engage app pairs feature.
+ */
+public interface AppPairs {
+ /** Pairs indicated tasks. */
+ boolean pair(int task1, int task2);
+ /** Pairs indicated tasks. */
+ boolean pair(ActivityManager.RunningTaskInfo task1, ActivityManager.RunningTaskInfo task2);
+ /** Unpairs any app-pair containing this task id. */
+ void unpair(int taskId);
+ /** Dumps current status of app pairs. */
+ void dump(@NonNull PrintWriter pw, String prefix);
+ /** Called when the shell organizer has been registered. */
+ void onOrganizerRegistered();
+}
diff --git a/libs/WindowManager/Shell/src/com/android/wm/shell/apppairs/AppPairsController.java b/libs/WindowManager/Shell/src/com/android/wm/shell/apppairs/AppPairsController.java
new file mode 100644
index 0000000..e0c7ba9
--- /dev/null
+++ b/libs/WindowManager/Shell/src/com/android/wm/shell/apppairs/AppPairsController.java
@@ -0,0 +1,150 @@
+/*
+ * Copyright (C) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package com.android.wm.shell.apppairs;
+
+import static com.android.wm.shell.protolog.ShellProtoLogGroup.WM_SHELL_TASK_ORG;
+
+import android.app.ActivityManager;
+import android.util.SparseArray;
+
+import androidx.annotation.NonNull;
+
+import com.android.internal.annotations.VisibleForTesting;
+import com.android.internal.protolog.common.ProtoLog;
+import com.android.wm.shell.ShellTaskOrganizer;
+import com.android.wm.shell.common.SyncTransactionQueue;
+
+import java.io.PrintWriter;
+
+/**
+ * Class manages app-pairs multitasking mode and implements the main interface {@link AppPairs}.
+ */
+public class AppPairsController implements AppPairs {
+ private static final String TAG = AppPairsController.class.getSimpleName();
+
+ private final ShellTaskOrganizer mTaskOrganizer;
+ private final SyncTransactionQueue mSyncQueue;
+
+ private AppPairsPool mPairsPool;
+ // Active app-pairs mapped by root task id key.
+ private final SparseArray<AppPair> mActiveAppPairs = new SparseArray<>();
+
+ public AppPairsController(ShellTaskOrganizer organizer, SyncTransactionQueue syncQueue) {
+ mTaskOrganizer = organizer;
+ mSyncQueue = syncQueue;
+ }
+
+ @Override
+ public void onOrganizerRegistered() {
+ if (mPairsPool == null) {
+ setPairsPool(new AppPairsPool(this));
+ }
+ }
+
+ @VisibleForTesting
+ void setPairsPool(AppPairsPool pool) {
+ mPairsPool = pool;
+ }
+
+ @Override
+ public boolean pair(int taskId1, int taskId2) {
+ final ActivityManager.RunningTaskInfo task1 = mTaskOrganizer.getRunningTaskInfo(taskId1);
+ final ActivityManager.RunningTaskInfo task2 = mTaskOrganizer.getRunningTaskInfo(taskId2);
+ if (task1 == null || task2 == null) {
+ return false;
+ }
+ return pair(task1, task2);
+ }
+
+ @Override
+ public boolean pair(ActivityManager.RunningTaskInfo task1,
+ ActivityManager.RunningTaskInfo task2) {
+ return pairInner(task1, task2) != null;
+ }
+
+ @VisibleForTesting
+ AppPair pairInner(
+ @NonNull ActivityManager.RunningTaskInfo task1,
+ @NonNull ActivityManager.RunningTaskInfo task2) {
+ final AppPair pair = mPairsPool.acquire();
+ if (!pair.pair(task1, task2)) {
+ mPairsPool.release(pair);
+ return null;
+ }
+
+ mActiveAppPairs.put(pair.getRootTaskId(), pair);
+ return pair;
+ }
+
+ @Override
+ public void unpair(int taskId) {
+ unpair(taskId, true /* releaseToPool */);
+ }
+
+ void unpair(int taskId, boolean releaseToPool) {
+ AppPair pair = mActiveAppPairs.get(taskId);
+ if (pair == null) {
+ for (int i = mActiveAppPairs.size() - 1; i >= 0; --i) {
+ final AppPair candidate = mActiveAppPairs.valueAt(i);
+ if (candidate.contains(taskId)) {
+ pair = candidate;
+ break;
+ }
+ }
+ }
+ if (pair == null) {
+ ProtoLog.v(WM_SHELL_TASK_ORG, "taskId %d isn't isn't in an app-pair.", taskId);
+ return;
+ }
+
+ ProtoLog.v(WM_SHELL_TASK_ORG, "unpair taskId=%d pair=%s", taskId, pair);
+ mActiveAppPairs.remove(pair.getRootTaskId());
+ pair.unpair();
+ if (releaseToPool) {
+ mPairsPool.release(pair);
+ }
+ }
+
+ ShellTaskOrganizer getTaskOrganizer() {
+ return mTaskOrganizer;
+ }
+
+ SyncTransactionQueue getSyncTransactionQueue() {
+ return mSyncQueue;
+ }
+
+ @Override
+ public void dump(@NonNull PrintWriter pw, String prefix) {
+ final String innerPrefix = prefix + " ";
+ final String childPrefix = innerPrefix + " ";
+ pw.println(prefix + this);
+
+ for (int i = mActiveAppPairs.size() - 1; i >= 0; --i) {
+ mActiveAppPairs.valueAt(i).dump(pw, childPrefix);
+ }
+
+ if (mPairsPool != null) {
+ mPairsPool.dump(pw, prefix);
+ }
+ }
+
+ @Override
+ public String toString() {
+ return TAG + "#" + mActiveAppPairs.size();
+ }
+
+}
diff --git a/libs/WindowManager/Shell/src/com/android/wm/shell/apppairs/AppPairsPool.java b/libs/WindowManager/Shell/src/com/android/wm/shell/apppairs/AppPairsPool.java
new file mode 100644
index 0000000..5c6037e
--- /dev/null
+++ b/libs/WindowManager/Shell/src/com/android/wm/shell/apppairs/AppPairsPool.java
@@ -0,0 +1,93 @@
+/*
+ * Copyright (C) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package com.android.wm.shell.apppairs;
+
+import static android.app.WindowConfiguration.WINDOWING_MODE_FULLSCREEN;
+import static android.view.Display.DEFAULT_DISPLAY;
+
+import static com.android.wm.shell.protolog.ShellProtoLogGroup.WM_SHELL_TASK_ORG;
+
+import androidx.annotation.NonNull;
+
+import com.android.internal.annotations.VisibleForTesting;
+import com.android.internal.protolog.common.ProtoLog;
+
+import java.io.PrintWriter;
+import java.util.ArrayList;
+
+/**
+ * Class that manager pool of {@link AppPair} objects. Helps reduce the need to call system_server
+ * to create a root task for the app-pair when needed since we always have one ready to go.
+ */
+class AppPairsPool {
+ private static final String TAG = AppPairsPool.class.getSimpleName();
+
+ @VisibleForTesting
+ final AppPairsController mController;
+ // The pool
+ private final ArrayList<AppPair> mPool = new ArrayList();
+
+ AppPairsPool(AppPairsController controller) {
+ mController = controller;
+ incrementPool();
+ }
+
+ AppPair acquire() {
+ final AppPair entry = mPool.remove(mPool.size() - 1);
+ ProtoLog.v(WM_SHELL_TASK_ORG, "acquire entry.taskId=%s listener=%s size=%d",
+ entry.getRootTaskId(), entry, mPool.size());
+ if (mPool.size() == 0) {
+ incrementPool();
+ }
+ return entry;
+ }
+
+ void release(AppPair entry) {
+ mPool.add(entry);
+ ProtoLog.v(WM_SHELL_TASK_ORG, "release entry.taskId=%s listener=%s size=%d",
+ entry.getRootTaskId(), entry, mPool.size());
+ }
+
+ @VisibleForTesting
+ void incrementPool() {
+ ProtoLog.v(WM_SHELL_TASK_ORG, "incrementPool size=%d", mPool.size());
+ final AppPair entry = new AppPair(mController);
+ // TODO: multi-display...
+ mController.getTaskOrganizer().createRootTask(
+ DEFAULT_DISPLAY, WINDOWING_MODE_FULLSCREEN, entry);
+ mPool.add(entry);
+ }
+
+ @VisibleForTesting
+ int poolSize() {
+ return mPool.size();
+ }
+
+ public void dump(@NonNull PrintWriter pw, String prefix) {
+ final String innerPrefix = prefix + " ";
+ final String childPrefix = innerPrefix + " ";
+ pw.println(prefix + this);
+ for (int i = mPool.size() - 1; i >= 0; --i) {
+ mPool.get(i).dump(pw, childPrefix);
+ }
+ }
+
+ @Override
+ public String toString() {
+ return TAG + "#" + mPool.size();
+ }
+}
diff --git a/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleExpandedView.java b/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleExpandedView.java
index 646e75a..45ffe6b 100644
--- a/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleExpandedView.java
+++ b/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/BubbleExpandedView.java
@@ -29,6 +29,7 @@
import android.annotation.NonNull;
import android.annotation.SuppressLint;
import android.app.ActivityOptions;
+import android.app.ActivityTaskManager;
import android.app.PendingIntent;
import android.content.ComponentName;
import android.content.Context;
@@ -41,6 +42,7 @@
import android.graphics.Rect;
import android.graphics.drawable.ShapeDrawable;
import android.os.Bundle;
+import android.os.RemoteException;
import android.util.AttributeSet;
import android.util.Log;
import android.view.SurfaceControl;
@@ -647,6 +649,13 @@
if (DEBUG_BUBBLE_EXPANDED_VIEW) {
Log.d(TAG, "cleanUpExpandedState: bubble=" + getBubbleKey() + " task=" + mTaskId);
}
+ if (getTaskId() != INVALID_TASK_ID) {
+ try {
+ ActivityTaskManager.getService().removeTask(getTaskId());
+ } catch (RemoteException e) {
+ Log.w(TAG, e.getMessage());
+ }
+ }
if (mTaskView != null) {
mTaskView.release();
}
diff --git a/libs/WindowManager/Shell/src/com/android/wm/shell/pip/PipBoundsHandler.java b/libs/WindowManager/Shell/src/com/android/wm/shell/pip/PipBoundsAlgorithm.java
similarity index 63%
rename from libs/WindowManager/Shell/src/com/android/wm/shell/pip/PipBoundsHandler.java
rename to libs/WindowManager/Shell/src/com/android/wm/shell/pip/PipBoundsAlgorithm.java
index ca16cfc..df6683e 100644
--- a/libs/WindowManager/Shell/src/com/android/wm/shell/pip/PipBoundsHandler.java
+++ b/libs/WindowManager/Shell/src/com/android/wm/shell/pip/PipBoundsAlgorithm.java
@@ -16,37 +16,27 @@
package com.android.wm.shell.pip;
-import static android.app.WindowConfiguration.ACTIVITY_TYPE_UNDEFINED;
-import static android.app.WindowConfiguration.WINDOWING_MODE_PINNED;
import static android.util.TypedValue.COMPLEX_UNIT_DIP;
-import static android.view.Surface.ROTATION_0;
-import static android.view.Surface.ROTATION_180;
import android.annotation.NonNull;
-import android.app.ActivityTaskManager;
-import android.app.ActivityTaskManager.RootTaskInfo;
import android.content.Context;
import android.content.res.Resources;
import android.graphics.Point;
import android.graphics.Rect;
-import android.os.RemoteException;
import android.util.DisplayMetrics;
-import android.util.Log;
import android.util.Size;
import android.util.TypedValue;
import android.view.DisplayInfo;
import android.view.Gravity;
-import android.window.WindowContainerTransaction;
import java.io.PrintWriter;
/**
- * Handles bounds calculation for PIP on Phone and other form factors, it keeps tracking variant
- * state changes originated from Window Manager and is the source of truth for PiP window bounds.
+ * Calculates the default, normal, entry, inset and movement bounds of the PIP.
*/
-public class PipBoundsHandler {
+public class PipBoundsAlgorithm {
- private static final String TAG = PipBoundsHandler.class.getSimpleName();
+ private static final String TAG = PipBoundsAlgorithm.class.getSimpleName();
private static final float INVALID_SNAP_FRACTION = -1f;
private final @NonNull PipBoundsState mPipBoundsState;
@@ -59,7 +49,7 @@
private int mDefaultMinSize;
private Point mScreenEdgeInsets;
- public PipBoundsHandler(Context context, @NonNull PipBoundsState pipBoundsState) {
+ public PipBoundsAlgorithm(Context context, @NonNull PipBoundsState pipBoundsState) {
mPipBoundsState = pipBoundsState;
mSnapAlgorithm = new PipSnapAlgorithm(context);
reloadResources(context);
@@ -96,24 +86,6 @@
}
/**
- * Responds to IPinnedStackListener on movement bounds change.
- * Note that both inset and normal bounds will be calculated here rather than in the caller.
- */
- public void onMovementBoundsChanged(Rect insetBounds, Rect normalBounds,
- Rect animatingBounds) {
- getInsetBounds(insetBounds);
- final Rect defaultBounds = getDefaultBounds(INVALID_SNAP_FRACTION, null);
- normalBounds.set(defaultBounds);
- if (animatingBounds.isEmpty()) {
- animatingBounds.set(defaultBounds);
- }
- if (isValidPictureInPictureAspectRatio(mPipBoundsState.getAspectRatio())) {
- transformBoundsToAspectRatio(normalBounds, mPipBoundsState.getAspectRatio(),
- false /* useCurrentMinEdgeSize */, false /* useCurrentSize */);
- }
- }
-
- /**
* The {@link PipSnapAlgorithm} is couple on display bounds
* @return {@link PipSnapAlgorithm}.
*/
@@ -128,6 +100,19 @@
reloadResources(context);
}
+ /** Returns the normal bounds (i.e. the default entry bounds). */
+ public Rect getNormalBounds() {
+ // The normal bounds are the default bounds adjusted to the current aspect ratio.
+ return transformBoundsToAspectRatioIfValid(getDefaultBounds(),
+ mPipBoundsState.getAspectRatio(), false /* useCurrentMinEdgeSize */,
+ false /* useCurrentSize */);
+ }
+
+ /** Returns the default bounds. */
+ public Rect getDefaultBounds() {
+ return getDefaultBounds(INVALID_SNAP_FRACTION, null /* size */);
+ }
+
/** Returns the destination bounds to place the PIP window on entry. */
public Rect getEntryDestinationBounds() {
final PipBoundsState.PipReentryState reentryState = mPipBoundsState.getReentryState();
@@ -135,23 +120,17 @@
final Rect destinationBounds = shouldRestoreReentryBounds
? getDefaultBounds(reentryState.getSnapFraction(), reentryState.getSize())
- : getDefaultBounds(INVALID_SNAP_FRACTION, null /* size */);
+ : getDefaultBounds();
- if (isValidPictureInPictureAspectRatio(mPipBoundsState.getAspectRatio())) {
- transformBoundsToAspectRatio(destinationBounds, mPipBoundsState.getAspectRatio(),
- false /* useCurrentMinEdgeSize */, shouldRestoreReentryBounds);
- }
- return destinationBounds;
+ return transformBoundsToAspectRatioIfValid(destinationBounds,
+ mPipBoundsState.getAspectRatio(), false /* useCurrentMinEdgeSize */,
+ shouldRestoreReentryBounds);
}
/** Returns the current bounds adjusted to the new aspect ratio, if valid. */
public Rect getAdjustedDestinationBounds(Rect currentBounds, float newAspectRatio) {
- final Rect destinationBounds = new Rect(currentBounds);
- if (isValidPictureInPictureAspectRatio(newAspectRatio)) {
- transformBoundsToAspectRatio(destinationBounds, newAspectRatio,
- true /* useCurrentMinEdgeSize */, false /* isReentryBounds */);
- }
- return destinationBounds;
+ return transformBoundsToAspectRatioIfValid(currentBounds, newAspectRatio,
+ true /* useCurrentMinEdgeSize */, false /* useCurrentSize */);
}
public float getDefaultAspectRatio() {
@@ -159,94 +138,6 @@
}
/**
- * Updatest the display info and display layout on rotation change. This is needed even when we
- * aren't in PIP because the rotation layout is used to calculate the proper insets for the
- * next enter animation into PIP.
- */
- public void onDisplayRotationChangedNotInPip(Context context, int toRotation) {
- // Update the display layout, note that we have to do this on every rotation even if we
- // aren't in PIP since we need to update the display layout to get the right resources
- mPipBoundsState.getDisplayLayout().rotateTo(context.getResources(), toRotation);
-
- // Populate the new {@link #mDisplayInfo}.
- // The {@link DisplayInfo} queried from DisplayManager would be the one before rotation,
- // therefore, the width/height may require a swap first.
- // Moving forward, we should get the new dimensions after rotation from DisplayLayout.
- mPipBoundsState.setDisplayRotation(toRotation);
- updateDisplayInfoIfNeeded();
- }
-
- /**
- * Updates the display info, calculating and returning the new stack and movement bounds in the
- * new orientation of the device if necessary.
- *
- * @return {@code true} if internal {@link DisplayInfo} is rotated, {@code false} otherwise.
- */
- public boolean onDisplayRotationChanged(Context context, Rect outBounds, Rect oldBounds,
- Rect outInsetBounds,
- int displayId, int fromRotation, int toRotation, WindowContainerTransaction t) {
- // Bail early if the event is not sent to current {@link #mDisplayInfo}
- if ((displayId != mPipBoundsState.getDisplayInfo().displayId)
- || (fromRotation == toRotation)) {
- return false;
- }
-
- // Bail early if the pinned task is staled.
- final RootTaskInfo pinnedTaskInfo;
- try {
- pinnedTaskInfo = ActivityTaskManager.getService()
- .getRootTaskInfo(WINDOWING_MODE_PINNED, ACTIVITY_TYPE_UNDEFINED);
- if (pinnedTaskInfo == null) return false;
- } catch (RemoteException e) {
- Log.e(TAG, "Failed to get RootTaskInfo for pinned task", e);
- return false;
- }
-
- // Calculate the snap fraction of the current stack along the old movement bounds
- final Rect postChangeStackBounds = new Rect(oldBounds);
- final float snapFraction = mSnapAlgorithm.getSnapFraction(postChangeStackBounds,
- getMovementBounds(postChangeStackBounds), mPipBoundsState.getStashedState());
-
- // Update the display layout
- mPipBoundsState.getDisplayLayout().rotateTo(context.getResources(), toRotation);
-
- // Populate the new {@link #mDisplayInfo}.
- // The {@link DisplayInfo} queried from DisplayManager would be the one before rotation,
- // therefore, the width/height may require a swap first.
- // Moving forward, we should get the new dimensions after rotation from DisplayLayout.
- mPipBoundsState.getDisplayInfo().rotation = toRotation;
- updateDisplayInfoIfNeeded();
-
- // Calculate the stack bounds in the new orientation based on same fraction along the
- // rotated movement bounds.
- final Rect postChangeMovementBounds = getMovementBounds(postChangeStackBounds,
- false /* adjustForIme */);
- mSnapAlgorithm.applySnapFraction(postChangeStackBounds, postChangeMovementBounds,
- snapFraction, mPipBoundsState.getStashedState(), mPipBoundsState.getStashOffset(),
- mPipBoundsState.getDisplayBounds());
-
- getInsetBounds(outInsetBounds);
- outBounds.set(postChangeStackBounds);
- t.setBounds(pinnedTaskInfo.token, outBounds);
- return true;
- }
-
- private void updateDisplayInfoIfNeeded() {
- final DisplayInfo displayInfo = mPipBoundsState.getDisplayInfo();
- final boolean updateNeeded;
- if ((displayInfo.rotation == ROTATION_0) || (displayInfo.rotation == ROTATION_180)) {
- updateNeeded = (displayInfo.logicalWidth > displayInfo.logicalHeight);
- } else {
- updateNeeded = (displayInfo.logicalWidth < displayInfo.logicalHeight);
- }
- if (updateNeeded) {
- final int newLogicalHeight = displayInfo.logicalWidth;
- displayInfo.logicalWidth = displayInfo.logicalHeight;
- displayInfo.logicalHeight = newLogicalHeight;
- }
- }
-
- /**
* @return whether the given {@param aspectRatio} is valid.
*/
private boolean isValidPictureInPictureAspectRatio(float aspectRatio) {
@@ -254,6 +145,16 @@
&& Float.compare(aspectRatio, mMaxAspectRatio) <= 0;
}
+ private Rect transformBoundsToAspectRatioIfValid(Rect bounds, float aspectRatio,
+ boolean useCurrentMinEdgeSize, boolean useCurrentSize) {
+ final Rect destinationBounds = new Rect(bounds);
+ if (isValidPictureInPictureAspectRatio(aspectRatio)) {
+ transformBoundsToAspectRatio(destinationBounds, aspectRatio,
+ useCurrentMinEdgeSize, useCurrentSize);
+ }
+ return destinationBounds;
+ }
+
/**
* Set the current bounds (or the default bounds if there are no current bounds) with the
* specified aspect ratio.
@@ -343,7 +244,7 @@
/**
* Populates the bounds on the screen that the PIP can be visible in.
*/
- protected void getInsetBounds(Rect outRect) {
+ public void getInsetBounds(Rect outRect) {
final DisplayInfo displayInfo = mPipBoundsState.getDisplayInfo();
Rect insets = mPipBoundsState.getDisplayLayout().stableInsets();
outRect.set(insets.left + mScreenEdgeInsets.x,
@@ -353,18 +254,18 @@
}
/**
- * @return the movement bounds for the given {@param stackBounds} and the current state of the
+ * @return the movement bounds for the given stackBounds and the current state of the
* controller.
*/
- private Rect getMovementBounds(Rect stackBounds) {
+ public Rect getMovementBounds(Rect stackBounds) {
return getMovementBounds(stackBounds, true /* adjustForIme */);
}
/**
- * @return the movement bounds for the given {@param stackBounds} and the current state of the
+ * @return the movement bounds for the given stackBounds and the current state of the
* controller.
*/
- private Rect getMovementBounds(Rect stackBounds, boolean adjustForIme) {
+ public Rect getMovementBounds(Rect stackBounds, boolean adjustForIme) {
final Rect movementBounds = new Rect();
getInsetBounds(movementBounds);
diff --git a/libs/WindowManager/Shell/src/com/android/wm/shell/pip/PipTaskOrganizer.java b/libs/WindowManager/Shell/src/com/android/wm/shell/pip/PipTaskOrganizer.java
index a095fb5..7cc2a41 100644
--- a/libs/WindowManager/Shell/src/com/android/wm/shell/pip/PipTaskOrganizer.java
+++ b/libs/WindowManager/Shell/src/com/android/wm/shell/pip/PipTaskOrganizer.java
@@ -134,7 +134,7 @@
private final Handler mMainHandler;
private final Handler mUpdateHandler;
private final PipBoundsState mPipBoundsState;
- private final PipBoundsHandler mPipBoundsHandler;
+ private final PipBoundsAlgorithm mPipBoundsAlgorithm;
// TODO(b/172286265): Remove dependency on .pip.PHONE.PipMenuActivityController
private final PipMenuActivityController mMenuActivityController;
private final PipAnimationController mPipAnimationController;
@@ -263,7 +263,7 @@
private boolean mShouldIgnoreEnteringPipTransition;
public PipTaskOrganizer(Context context, @NonNull PipBoundsState pipBoundsState,
- @NonNull PipBoundsHandler boundsHandler,
+ @NonNull PipBoundsAlgorithm boundsHandler,
PipMenuActivityController menuActivityController,
@NonNull PipSurfaceTransactionHelper surfaceTransactionHelper,
Optional<SplitScreen> splitScreenOptional,
@@ -273,7 +273,7 @@
mMainHandler = new Handler(Looper.getMainLooper());
mUpdateHandler = new Handler(PipUpdateThread.get().getLooper(), mUpdateCallbacks);
mPipBoundsState = pipBoundsState;
- mPipBoundsHandler = boundsHandler;
+ mPipBoundsAlgorithm = boundsHandler;
mMenuActivityController = menuActivityController;
mEnterExitAnimationDuration = context.getResources()
.getInteger(R.integer.config_pipResizeAnimationDuration);
@@ -340,7 +340,7 @@
mShouldIgnoreEnteringPipTransition = true;
sendOnPipTransitionStarted(componentName, TRANSITION_DIRECTION_TO_PIP);
setBoundsStateForEntry(componentName, pictureInPictureParams, activityInfo);
- return mPipBoundsHandler.getEntryDestinationBounds();
+ return mPipBoundsAlgorithm.getEntryDestinationBounds();
}
/**
@@ -528,7 +528,7 @@
return;
}
- final Rect destinationBounds = mPipBoundsHandler.getEntryDestinationBounds();
+ final Rect destinationBounds = mPipBoundsAlgorithm.getEntryDestinationBounds();
Objects.requireNonNull(destinationBounds, "Missing destination bounds");
final Rect currentBounds = mTaskInfo.configuration.windowConfiguration.getBounds();
@@ -690,7 +690,7 @@
return;
}
// Aspect ratio changed, re-calculate bounds if valid.
- final Rect destinationBounds = mPipBoundsHandler.getAdjustedDestinationBounds(
+ final Rect destinationBounds = mPipBoundsAlgorithm.getAdjustedDestinationBounds(
mPipBoundsState.getBounds(), mPipBoundsState.getAspectRatio());
Objects.requireNonNull(destinationBounds, "Missing destination bounds");
scheduleAnimateResizePip(destinationBounds, mEnterExitAnimationDuration,
@@ -705,7 +705,7 @@
@Override
public void onFixedRotationFinished(int displayId) {
if (mShouldDeferEnteringPip && mState.isInPip()) {
- final Rect destinationBounds = mPipBoundsHandler.getEntryDestinationBounds();
+ final Rect destinationBounds = mPipBoundsAlgorithm.getEntryDestinationBounds();
// schedule a regular animation to ensure all the callbacks are still being sent
enterPipWithAlphaAnimation(destinationBounds, 0 /* durationMs */);
}
@@ -780,7 +780,7 @@
return;
}
- final Rect newDestinationBounds = mPipBoundsHandler.getEntryDestinationBounds();
+ final Rect newDestinationBounds = mPipBoundsAlgorithm.getEntryDestinationBounds();
if (newDestinationBounds.equals(currentDestinationBounds)) return;
if (animator.getAnimationType() == ANIM_TYPE_BOUNDS) {
animator.updateEndValue(newDestinationBounds);
@@ -1106,7 +1106,7 @@
private float getAspectRatioOrDefault(@Nullable PictureInPictureParams params) {
return params == null || !params.hasSetAspectRatio()
- ? mPipBoundsHandler.getDefaultAspectRatio()
+ ? mPipBoundsAlgorithm.getDefaultAspectRatio()
: params.getAspectRatio();
}
diff --git a/libs/WindowManager/Shell/src/com/android/wm/shell/pip/phone/PipController.java b/libs/WindowManager/Shell/src/com/android/wm/shell/pip/phone/PipController.java
index 8e48229..1f67d2c 100644
--- a/libs/WindowManager/Shell/src/com/android/wm/shell/pip/phone/PipController.java
+++ b/libs/WindowManager/Shell/src/com/android/wm/shell/pip/phone/PipController.java
@@ -19,6 +19,8 @@
import static android.app.WindowConfiguration.ACTIVITY_TYPE_UNDEFINED;
import static android.app.WindowConfiguration.WINDOWING_MODE_PINNED;
import static android.content.pm.PackageManager.FEATURE_PICTURE_IN_PICTURE;
+import static android.view.Surface.ROTATION_0;
+import static android.view.Surface.ROTATION_180;
import static android.view.WindowManager.INPUT_CONSUMER_PIP;
import static com.android.wm.shell.pip.PipAnimationController.isOutPipDirection;
@@ -56,9 +58,10 @@
import com.android.wm.shell.common.TaskStackListenerImpl;
import com.android.wm.shell.pip.PinnedStackListenerForwarder;
import com.android.wm.shell.pip.Pip;
-import com.android.wm.shell.pip.PipBoundsHandler;
+import com.android.wm.shell.pip.PipBoundsAlgorithm;
import com.android.wm.shell.pip.PipBoundsState;
import com.android.wm.shell.pip.PipMediaController;
+import com.android.wm.shell.pip.PipSnapAlgorithm;
import com.android.wm.shell.pip.PipTaskOrganizer;
import com.android.wm.shell.pip.PipUtils;
@@ -78,7 +81,7 @@
private WindowManagerShellWrapper mWindowManagerShellWrapper;
private PipAppOpsListener mAppOpsListener;
private PipMediaController mMediaController;
- private PipBoundsHandler mPipBoundsHandler;
+ private PipBoundsAlgorithm mPipBoundsAlgorithm;
private PipBoundsState mPipBoundsState;
private PipTouchHandler mTouchHandler;
@@ -103,14 +106,14 @@
if (!mPipTaskOrganizer.isInPip() || mPipTaskOrganizer.isDeferringEnterPipAnimation()) {
// Skip if we aren't in PIP or haven't actually entered PIP yet. We still need to update
// the display layout in the bounds handler in this case.
- mPipBoundsHandler.onDisplayRotationChangedNotInPip(mContext, toRotation);
+ onDisplayRotationChangedNotInPip(mContext, toRotation);
return;
}
// If there is an animation running (ie. from a shelf offset), then ensure that we calculate
// the bounds for the next orientation using the destination bounds of the animation
// TODO: Technically this should account for movement animation bounds as well
Rect currentBounds = mPipTaskOrganizer.getCurrentOrAnimatingBounds();
- final boolean changed = mPipBoundsHandler.onDisplayRotationChanged(mContext,
+ final boolean changed = onDisplayRotationChanged(mContext,
mTmpNormalBounds, currentBounds, mTmpInsetBounds, displayId, fromRotation,
toRotation, t);
if (changed) {
@@ -204,7 +207,7 @@
@Override
public void onConfigurationChanged() {
mMainExecutor.execute(() -> {
- mPipBoundsHandler.onConfigurationChanged(mContext);
+ mPipBoundsAlgorithm.onConfigurationChanged(mContext);
mTouchHandler.onConfigurationChanged();
mPipBoundsState.onConfigurationChanged();
});
@@ -224,7 +227,7 @@
protected PipController(Context context,
DisplayController displayController,
PipAppOpsListener pipAppOpsListener,
- PipBoundsHandler pipBoundsHandler,
+ PipBoundsAlgorithm pipBoundsAlgorithm,
@NonNull PipBoundsState pipBoundsState,
PipMediaController pipMediaController,
PipMenuActivityController pipMenuActivityController,
@@ -243,7 +246,7 @@
mContext = context;
mWindowManagerShellWrapper = windowManagerShellWrapper;
mDisplayController = displayController;
- mPipBoundsHandler = pipBoundsHandler;
+ mPipBoundsAlgorithm = pipBoundsAlgorithm;
mPipBoundsState = pipBoundsState;
mPipTaskOrganizer = pipTaskOrganizer;
mMainExecutor = mainExecutor;
@@ -437,7 +440,7 @@
PictureInPictureParams pictureInPictureParams,
int launcherRotation, int shelfHeight) {
setShelfHeightLocked(shelfHeight > 0 /* visible */, shelfHeight);
- mPipBoundsHandler.onDisplayRotationChangedNotInPip(mContext, launcherRotation);
+ onDisplayRotationChangedNotInPip(mContext, launcherRotation);
return mPipTaskOrganizer.startSwipePipToHome(componentName, activityInfo,
pictureInPictureParams);
}
@@ -452,7 +455,7 @@
if (isOutPipDirection(direction)) {
// Exiting PIP, save the reentry bounds to restore to when re-entering.
updateReentryBounds(pipBounds);
- final float snapFraction = mPipBoundsHandler.getSnapFraction(mReentryBounds);
+ final float snapFraction = mPipBoundsAlgorithm.getSnapFraction(mReentryBounds);
mPipBoundsState.saveReentryState(mReentryBounds, snapFraction);
}
// Disable touches while the animation is running
@@ -467,8 +470,8 @@
*/
public void updateReentryBounds(Rect bounds) {
final Rect reentryBounds = mTouchHandler.getUserResizeBounds();
- float snapFraction = mPipBoundsHandler.getSnapFraction(bounds);
- mPipBoundsHandler.applySnapFraction(reentryBounds, snapFraction);
+ float snapFraction = mPipBoundsAlgorithm.getSnapFraction(bounds);
+ mPipBoundsAlgorithm.applySnapFraction(reentryBounds, snapFraction);
mReentryBounds.set(reentryBounds);
}
@@ -506,8 +509,13 @@
// passing to mTouchHandler/mPipTaskOrganizer
final Rect outBounds = new Rect(toBounds);
mTmpDisplayInfo.copyFrom(mPipBoundsState.getDisplayInfo());
- mPipBoundsHandler.onMovementBoundsChanged(mTmpInsetBounds, mTmpNormalBounds,
- outBounds);
+
+ mPipBoundsAlgorithm.getInsetBounds(mTmpInsetBounds);
+ mTmpNormalBounds.set(mPipBoundsAlgorithm.getNormalBounds());
+ if (outBounds.isEmpty()) {
+ outBounds.set(mPipBoundsAlgorithm.getDefaultBounds());
+ }
+
// mTouchHandler would rely on the bounds populated from mPipTaskOrganizer
mPipTaskOrganizer.onMovementBoundsChanged(outBounds, fromRotation, fromImeAdjustment,
fromShelfAdjustment, wct);
@@ -516,13 +524,103 @@
mTmpDisplayInfo.rotation);
}
+ /**
+ * Updates the display info and display layout on rotation change. This is needed even when we
+ * aren't in PIP because the rotation layout is used to calculate the proper insets for the
+ * next enter animation into PIP.
+ */
+ private void onDisplayRotationChangedNotInPip(Context context, int toRotation) {
+ // Update the display layout, note that we have to do this on every rotation even if we
+ // aren't in PIP since we need to update the display layout to get the right resources
+ mPipBoundsState.getDisplayLayout().rotateTo(context.getResources(), toRotation);
+
+ // Populate the new {@link #mDisplayInfo}.
+ // The {@link DisplayInfo} queried from DisplayManager would be the one before rotation,
+ // therefore, the width/height may require a swap first.
+ // Moving forward, we should get the new dimensions after rotation from DisplayLayout.
+ mPipBoundsState.setDisplayRotation(toRotation);
+ updateDisplayInfoIfNeeded();
+ }
+
+ /**
+ * Updates the display info, calculating and returning the new stack and movement bounds in the
+ * new orientation of the device if necessary.
+ *
+ * @return {@code true} if internal {@link DisplayInfo} is rotated, {@code false} otherwise.
+ */
+ public boolean onDisplayRotationChanged(Context context, Rect outBounds, Rect oldBounds,
+ Rect outInsetBounds,
+ int displayId, int fromRotation, int toRotation, WindowContainerTransaction t) {
+ // Bail early if the event is not sent to current {@link #mDisplayInfo}
+ if ((displayId != mPipBoundsState.getDisplayInfo().displayId)
+ || (fromRotation == toRotation)) {
+ return false;
+ }
+
+ // Bail early if the pinned task is staled.
+ final ActivityTaskManager.RootTaskInfo pinnedTaskInfo;
+ try {
+ pinnedTaskInfo = ActivityTaskManager.getService()
+ .getRootTaskInfo(WINDOWING_MODE_PINNED, ACTIVITY_TYPE_UNDEFINED);
+ if (pinnedTaskInfo == null) return false;
+ } catch (RemoteException e) {
+ Log.e(TAG, "Failed to get RootTaskInfo for pinned task", e);
+ return false;
+ }
+ final PipSnapAlgorithm pipSnapAlgorithm = mPipBoundsAlgorithm.getSnapAlgorithm();
+
+ // Calculate the snap fraction of the current stack along the old movement bounds
+ final Rect postChangeStackBounds = new Rect(oldBounds);
+ final float snapFraction = pipSnapAlgorithm.getSnapFraction(postChangeStackBounds,
+ mPipBoundsAlgorithm.getMovementBounds(postChangeStackBounds),
+ mPipBoundsState.getStashedState());
+
+ // Update the display layout
+ mPipBoundsState.getDisplayLayout().rotateTo(context.getResources(), toRotation);
+
+ // Populate the new {@link #mDisplayInfo}.
+ // The {@link DisplayInfo} queried from DisplayManager would be the one before rotation,
+ // therefore, the width/height may require a swap first.
+ // Moving forward, we should get the new dimensions after rotation from DisplayLayout.
+ mPipBoundsState.getDisplayInfo().rotation = toRotation;
+ updateDisplayInfoIfNeeded();
+
+ // Calculate the stack bounds in the new orientation based on same fraction along the
+ // rotated movement bounds.
+ final Rect postChangeMovementBounds = mPipBoundsAlgorithm.getMovementBounds(
+ postChangeStackBounds, false /* adjustForIme */);
+ pipSnapAlgorithm.applySnapFraction(postChangeStackBounds, postChangeMovementBounds,
+ snapFraction, mPipBoundsState.getStashedState(), mPipBoundsState.getStashOffset(),
+ mPipBoundsState.getDisplayBounds());
+
+ mPipBoundsAlgorithm.getInsetBounds(outInsetBounds);
+ outBounds.set(postChangeStackBounds);
+ t.setBounds(pinnedTaskInfo.token, outBounds);
+ return true;
+ }
+
+ private void updateDisplayInfoIfNeeded() {
+ final DisplayInfo displayInfo = mPipBoundsState.getDisplayInfo();
+ final boolean updateNeeded;
+ if ((displayInfo.rotation == ROTATION_0) || (displayInfo.rotation == ROTATION_180)) {
+ updateNeeded = (displayInfo.logicalWidth > displayInfo.logicalHeight);
+ } else {
+ updateNeeded = (displayInfo.logicalWidth < displayInfo.logicalHeight);
+ }
+ if (updateNeeded) {
+ final int newLogicalHeight = displayInfo.logicalWidth;
+ displayInfo.logicalWidth = displayInfo.logicalHeight;
+ displayInfo.logicalHeight = newLogicalHeight;
+ }
+ }
+
@Override
public void dump(PrintWriter pw) {
final String innerPrefix = " ";
pw.println(TAG);
mMenuController.dump(pw, innerPrefix);
mTouchHandler.dump(pw, innerPrefix);
- mPipBoundsHandler.dump(pw, innerPrefix);
+ mPipBoundsAlgorithm.dump(pw, innerPrefix);
mPipTaskOrganizer.dump(pw, innerPrefix);
mPipBoundsState.dump(pw, innerPrefix);
mPipInputConsumer.dump(pw, innerPrefix);
@@ -533,7 +631,7 @@
*/
@Nullable
public static PipController create(Context context, DisplayController displayController,
- PipAppOpsListener pipAppOpsListener, PipBoundsHandler pipBoundsHandler,
+ PipAppOpsListener pipAppOpsListener, PipBoundsAlgorithm pipBoundsAlgorithm,
PipBoundsState pipBoundsState, PipMediaController pipMediaController,
PipMenuActivityController pipMenuActivityController, PipTaskOrganizer pipTaskOrganizer,
PipTouchHandler pipTouchHandler, WindowManagerShellWrapper windowManagerShellWrapper,
@@ -543,7 +641,7 @@
return null;
}
- return new PipController(context, displayController, pipAppOpsListener, pipBoundsHandler,
+ return new PipController(context, displayController, pipAppOpsListener, pipBoundsAlgorithm,
pipBoundsState, pipMediaController, pipMenuActivityController, pipTaskOrganizer,
pipTouchHandler, windowManagerShellWrapper, taskStackListener, mainExecutor);
}
diff --git a/libs/WindowManager/Shell/src/com/android/wm/shell/pip/phone/PipResizeGestureHandler.java b/libs/WindowManager/Shell/src/com/android/wm/shell/pip/phone/PipResizeGestureHandler.java
index 124683e..4849e0d 100644
--- a/libs/WindowManager/Shell/src/com/android/wm/shell/pip/phone/PipResizeGestureHandler.java
+++ b/libs/WindowManager/Shell/src/com/android/wm/shell/pip/phone/PipResizeGestureHandler.java
@@ -46,7 +46,7 @@
import com.android.internal.policy.TaskResizingAlgorithm;
import com.android.wm.shell.R;
-import com.android.wm.shell.pip.PipBoundsHandler;
+import com.android.wm.shell.pip.PipBoundsAlgorithm;
import com.android.wm.shell.pip.PipBoundsState;
import com.android.wm.shell.pip.PipTaskOrganizer;
import com.android.wm.shell.pip.PipUiEventLogger;
@@ -66,7 +66,7 @@
private static final float STARTING_SCALE_FACTOR = 1.0f;
private final Context mContext;
- private final PipBoundsHandler mPipBoundsHandler;
+ private final PipBoundsAlgorithm mPipBoundsAlgorithm;
private final PipMotionHelper mMotionHelper;
private final PipBoundsState mPipBoundsState;
private final int mDisplayId;
@@ -108,7 +108,7 @@
private int mCtrlType;
- public PipResizeGestureHandler(Context context, PipBoundsHandler pipBoundsHandler,
+ public PipResizeGestureHandler(Context context, PipBoundsAlgorithm pipBoundsAlgorithm,
PipBoundsState pipBoundsState, PipMotionHelper motionHelper,
PipTaskOrganizer pipTaskOrganizer, Function<Rect, Rect> movementBoundsSupplier,
Runnable updateMovementBoundsRunnable, PipUiEventLogger pipUiEventLogger,
@@ -116,7 +116,7 @@
mContext = context;
mDisplayId = context.getDisplayId();
mMainExecutor = context.getMainExecutor();
- mPipBoundsHandler = pipBoundsHandler;
+ mPipBoundsAlgorithm = pipBoundsAlgorithm;
mPipBoundsState = pipBoundsState;
mMotionHelper = motionHelper;
mPipTaskOrganizer = pipTaskOrganizer;
@@ -451,7 +451,7 @@
mDownPoint.x, mDownPoint.y, currentPipBounds, mCtrlType, mMinSize.x,
mMinSize.y, mMaxSize, true,
mLastDownBounds.width() > mLastDownBounds.height()));
- mPipBoundsHandler.transformBoundsToAspectRatio(mLastResizeBounds,
+ mPipBoundsAlgorithm.transformBoundsToAspectRatio(mLastResizeBounds,
mPipBoundsState.getAspectRatio(), false /* useCurrentMinEdgeSize */,
true /* useCurrentSize */);
mPipTaskOrganizer.scheduleUserResizePip(mLastDownBounds, mLastResizeBounds,
diff --git a/libs/WindowManager/Shell/src/com/android/wm/shell/pip/phone/PipTouchHandler.java b/libs/WindowManager/Shell/src/com/android/wm/shell/pip/phone/PipTouchHandler.java
index 36d2768..4cc41d9 100644
--- a/libs/WindowManager/Shell/src/com/android/wm/shell/pip/phone/PipTouchHandler.java
+++ b/libs/WindowManager/Shell/src/com/android/wm/shell/pip/phone/PipTouchHandler.java
@@ -48,7 +48,7 @@
import com.android.wm.shell.R;
import com.android.wm.shell.common.FloatingContentCoordinator;
import com.android.wm.shell.pip.PipAnimationController;
-import com.android.wm.shell.pip.PipBoundsHandler;
+import com.android.wm.shell.pip.PipBoundsAlgorithm;
import com.android.wm.shell.pip.PipBoundsState;
import com.android.wm.shell.pip.PipTaskOrganizer;
import com.android.wm.shell.pip.PipUiEventLogger;
@@ -69,7 +69,7 @@
// Allow PIP to resize to a slightly bigger state upon touch
private final boolean mEnableResize;
private final Context mContext;
- private final PipBoundsHandler mPipBoundsHandler;
+ private final PipBoundsAlgorithm mPipBoundsAlgorithm;
private final @NonNull PipBoundsState mPipBoundsState;
private final PipUiEventLogger mPipUiEventLogger;
private final PipDismissTargetHandler mPipDismissTargetHandler;
@@ -161,7 +161,7 @@
@SuppressLint("InflateParams")
public PipTouchHandler(Context context,
PipMenuActivityController menuController,
- PipBoundsHandler pipBoundsHandler,
+ PipBoundsAlgorithm pipBoundsAlgorithm,
@NonNull PipBoundsState pipBoundsState,
PipTaskOrganizer pipTaskOrganizer,
FloatingContentCoordinator floatingContentCoordinator,
@@ -169,15 +169,16 @@
// Initialize the Pip input consumer
mContext = context;
mAccessibilityManager = context.getSystemService(AccessibilityManager.class);
- mPipBoundsHandler = pipBoundsHandler;
+ mPipBoundsAlgorithm = pipBoundsAlgorithm;
mPipBoundsState = pipBoundsState;
mMenuController = menuController;
mMenuController.addListener(new PipMenuListener());
mGesture = new DefaultPipTouchGesture();
mMotionHelper = new PipMotionHelper(mContext, pipBoundsState, pipTaskOrganizer,
- mMenuController, mPipBoundsHandler.getSnapAlgorithm(), floatingContentCoordinator);
+ mMenuController, mPipBoundsAlgorithm.getSnapAlgorithm(),
+ floatingContentCoordinator);
mPipResizeGestureHandler =
- new PipResizeGestureHandler(context, pipBoundsHandler, pipBoundsState,
+ new PipResizeGestureHandler(context, pipBoundsAlgorithm, pipBoundsState,
mMotionHelper, pipTaskOrganizer, this::getMovementBounds,
this::updateMovementBounds, pipUiEventLogger, menuController);
mPipDismissTargetHandler = new PipDismissTargetHandler(context, pipUiEventLogger,
@@ -193,7 +194,7 @@
mFloatingContentCoordinator = floatingContentCoordinator;
mConnection = new PipAccessibilityInteractionConnection(mContext, pipBoundsState,
- mMotionHelper, pipTaskOrganizer, mPipBoundsHandler.getSnapAlgorithm(),
+ mMotionHelper, pipTaskOrganizer, mPipBoundsAlgorithm.getSnapAlgorithm(),
this::onAccessibilityShowMenu, this::updateMovementBounds, mHandler);
mPipUiEventLogger = pipUiEventLogger;
@@ -313,7 +314,7 @@
public void adjustBoundsForRotation(Rect outBounds, Rect curBounds, Rect insetBounds) {
final Rect toMovementBounds = new Rect();
- mPipBoundsHandler.getSnapAlgorithm().getMovementBounds(outBounds, insetBounds,
+ mPipBoundsAlgorithm.getSnapAlgorithm().getMovementBounds(outBounds, insetBounds,
toMovementBounds, 0);
final int prevBottom = mMovementBounds.bottom - mMovementBoundsExtraOffsets;
if ((prevBottom - mBottomOffsetBufferPx) <= curBounds.top) {
@@ -345,13 +346,13 @@
// Re-calculate the expanded bounds
mNormalBounds.set(normalBounds);
Rect normalMovementBounds = new Rect();
- mPipBoundsHandler.getSnapAlgorithm().getMovementBounds(mNormalBounds, insetBounds,
+ mPipBoundsAlgorithm.getSnapAlgorithm().getMovementBounds(mNormalBounds, insetBounds,
normalMovementBounds, bottomOffset);
if (mMovementBounds.isEmpty()) {
// mMovementBounds is not initialized yet and a clean movement bounds without
// bottom offset shall be used later in this function.
- mPipBoundsHandler.getSnapAlgorithm().getMovementBounds(curBounds, insetBounds,
+ mPipBoundsAlgorithm.getSnapAlgorithm().getMovementBounds(curBounds, insetBounds,
mMovementBounds, 0 /* bottomOffset */);
}
@@ -359,11 +360,11 @@
float aspectRatio = (float) normalBounds.width() / normalBounds.height();
Point displaySize = new Point();
mContext.getDisplay().getRealSize(displaySize);
- Size expandedSize = mPipBoundsHandler.getSnapAlgorithm().getSizeForAspectRatio(aspectRatio,
- mExpandedShortestEdgeSize, displaySize.x, displaySize.y);
+ Size expandedSize = mPipBoundsAlgorithm.getSnapAlgorithm().getSizeForAspectRatio(
+ aspectRatio, mExpandedShortestEdgeSize, displaySize.x, displaySize.y);
mExpandedBounds.set(0, 0, expandedSize.getWidth(), expandedSize.getHeight());
Rect expandedMovementBounds = new Rect();
- mPipBoundsHandler.getSnapAlgorithm().getMovementBounds(mExpandedBounds, insetBounds,
+ mPipBoundsAlgorithm.getSnapAlgorithm().getMovementBounds(mExpandedBounds, insetBounds,
expandedMovementBounds, bottomOffset);
mPipResizeGestureHandler.updateMinSize(mNormalBounds.width(), mNormalBounds.height());
@@ -384,7 +385,7 @@
} else {
final boolean isExpanded = mMenuState == MENU_STATE_FULL && willResizeMenu();
final Rect toMovementBounds = new Rect();
- mPipBoundsHandler.getSnapAlgorithm().getMovementBounds(curBounds, insetBounds,
+ mPipBoundsAlgorithm.getSnapAlgorithm().getMovementBounds(curBounds, insetBounds,
toMovementBounds, mIsImeShowing ? mImeHeight : 0);
final int prevBottom = mMovementBounds.bottom - mMovementBoundsExtraOffsets;
// This is to handle landscape fullscreen IMEs, don't apply the extra offset in this
@@ -395,7 +396,7 @@
if (isExpanded) {
curBounds.set(mExpandedBounds);
- mPipBoundsHandler.getSnapAlgorithm().applySnapFraction(curBounds,
+ mPipBoundsAlgorithm.getSnapAlgorithm().applySnapFraction(curBounds,
toMovementBounds, mSavedSnapFraction);
}
@@ -658,7 +659,7 @@
private void animateToUnexpandedState(Rect restoreBounds) {
Rect restoredMovementBounds = new Rect();
- mPipBoundsHandler.getSnapAlgorithm().getMovementBounds(restoreBounds,
+ mPipBoundsAlgorithm.getSnapAlgorithm().getMovementBounds(restoreBounds,
mInsetBounds, restoredMovementBounds, mIsImeShowing ? mImeHeight : 0);
mMotionHelper.animateToUnexpandedState(restoreBounds, mSavedSnapFraction,
restoredMovementBounds, mMovementBounds, false /* immediate */);
@@ -718,7 +719,7 @@
mStartPosition.set(bounds.left, bounds.top);
mMovementWithinDismiss = touchState.getDownTouchPosition().y >= mMovementBounds.bottom;
mMotionHelper.setSpringingToTouch(false);
- mDownSavedFraction = mPipBoundsHandler.getSnapFraction(mPipBoundsState.getBounds());
+ mDownSavedFraction = mPipBoundsAlgorithm.getSnapFraction(mPipBoundsState.getBounds());
// If the menu is still visible then just poke the menu
// so that it will timeout after the user stops touching it
@@ -868,19 +869,19 @@
* resized.
*/
private void updateMovementBounds() {
- mPipBoundsHandler.getSnapAlgorithm().getMovementBounds(mMotionHelper.getBounds(),
+ mPipBoundsAlgorithm.getSnapAlgorithm().getMovementBounds(mMotionHelper.getBounds(),
mInsetBounds, mMovementBounds, mIsImeShowing ? mImeHeight : 0);
mMotionHelper.setCurrentMovementBounds(mMovementBounds);
boolean isMenuExpanded = mMenuState == MENU_STATE_FULL;
mPipBoundsState.setMinEdgeSize(
isMenuExpanded && willResizeMenu() ? mExpandedShortestEdgeSize
- : mPipBoundsHandler.getDefaultMinSize());
+ : mPipBoundsAlgorithm.getDefaultMinSize());
}
private Rect getMovementBounds(Rect curBounds) {
Rect movementBounds = new Rect();
- mPipBoundsHandler.getSnapAlgorithm().getMovementBounds(curBounds, mInsetBounds,
+ mPipBoundsAlgorithm.getSnapAlgorithm().getMovementBounds(curBounds, mInsetBounds,
movementBounds, mIsImeShowing ? mImeHeight : 0);
return movementBounds;
}
@@ -921,7 +922,7 @@
pw.println(innerPrefix + "mShelfHeight=" + mShelfHeight);
pw.println(innerPrefix + "mSavedSnapFraction=" + mSavedSnapFraction);
pw.println(innerPrefix + "mMovementBoundsExtraOffsets=" + mMovementBoundsExtraOffsets);
- mPipBoundsHandler.dump(pw, innerPrefix);
+ mPipBoundsAlgorithm.dump(pw, innerPrefix);
mTouchState.dump(pw, innerPrefix);
if (mPipResizeGestureHandler != null) {
mPipResizeGestureHandler.dump(pw, innerPrefix);
diff --git a/libs/WindowManager/Shell/src/com/android/wm/shell/pip/tv/PipController.java b/libs/WindowManager/Shell/src/com/android/wm/shell/pip/tv/PipController.java
index c23bc1d..56e97b9 100644
--- a/libs/WindowManager/Shell/src/com/android/wm/shell/pip/tv/PipController.java
+++ b/libs/WindowManager/Shell/src/com/android/wm/shell/pip/tv/PipController.java
@@ -52,7 +52,7 @@
import com.android.wm.shell.common.TaskStackListenerImpl;
import com.android.wm.shell.pip.PinnedStackListenerForwarder;
import com.android.wm.shell.pip.Pip;
-import com.android.wm.shell.pip.PipBoundsHandler;
+import com.android.wm.shell.pip.PipBoundsAlgorithm;
import com.android.wm.shell.pip.PipBoundsState;
import com.android.wm.shell.pip.PipMediaController;
import com.android.wm.shell.pip.PipTaskOrganizer;
@@ -108,7 +108,7 @@
private final Context mContext;
private final PipBoundsState mPipBoundsState;
- private final PipBoundsHandler mPipBoundsHandler;
+ private final PipBoundsAlgorithm mPipBoundsAlgorithm;
private final PipTaskOrganizer mPipTaskOrganizer;
private final PipMediaController mPipMediaController;
@@ -204,9 +204,12 @@
public void onMovementBoundsChanged(boolean fromImeAdjustment) {
mHandler.post(() -> {
mTmpDisplayInfo.copyFrom(mPipBoundsState.getDisplayInfo());
- // Populate the inset / normal bounds from mPipBoundsHandler first.
- mPipBoundsHandler.onMovementBoundsChanged(mTmpInsetBounds, mPipBounds,
- mDefaultPipBounds);
+
+ mPipBoundsAlgorithm.getInsetBounds(mTmpInsetBounds);
+ mPipBounds.set(mPipBoundsAlgorithm.getNormalBounds());
+ if (mDefaultPipBounds.isEmpty()) {
+ mDefaultPipBounds.set(mPipBoundsAlgorithm.getDefaultBounds());
+ }
});
}
@@ -223,7 +226,7 @@
public PipController(Context context,
PipBoundsState pipBoundsState,
- PipBoundsHandler pipBoundsHandler,
+ PipBoundsAlgorithm pipBoundsAlgorithm,
PipTaskOrganizer pipTaskOrganizer,
PipMediaController pipMediaController,
PipNotification pipNotification,
@@ -232,7 +235,7 @@
mContext = context;
mPipBoundsState = pipBoundsState;
mPipNotification = pipNotification;
- mPipBoundsHandler = pipBoundsHandler;
+ mPipBoundsAlgorithm = pipBoundsAlgorithm;
mPipMediaController = pipMediaController;
// Ensure that we have the display info in case we get calls to update the bounds
// before the listener calls back
diff --git a/libs/WindowManager/Shell/tests/flicker/src/com/android/wm/shell/flicker/pip/tv/TvPipTestBase.kt b/libs/WindowManager/Shell/tests/flicker/src/com/android/wm/shell/flicker/pip/tv/TvPipTestBase.kt
index 05f4b0b..d4acae5 100644
--- a/libs/WindowManager/Shell/tests/flicker/src/com/android/wm/shell/flicker/pip/tv/TvPipTestBase.kt
+++ b/libs/WindowManager/Shell/tests/flicker/src/com/android/wm/shell/flicker/pip/tv/TvPipTestBase.kt
@@ -16,13 +16,19 @@
package com.android.wm.shell.flicker.pip.tv
+import android.app.ActivityManager
+import android.app.IActivityManager
+import android.app.IProcessObserver
import android.content.pm.PackageManager.FEATURE_LEANBACK
import android.content.pm.PackageManager.FEATURE_LEANBACK_ONLY
+import android.os.SystemClock
import android.view.Surface.ROTATION_0
import android.view.Surface.rotationToString
import com.android.server.wm.flicker.helpers.wakeUpAndGoToHomeScreen
+import com.android.wm.shell.flicker.SYSTEM_UI_PACKAGE_NAME
import com.android.wm.shell.flicker.pip.PipTestBase
import org.junit.After
+import org.junit.Assert.assertFalse
import org.junit.Assume
import org.junit.Before
@@ -33,21 +39,61 @@
get() = packageManager.run {
hasSystemFeature(FEATURE_LEANBACK) || hasSystemFeature(FEATURE_LEANBACK_ONLY)
}
+ private val systemUiProcessObserver = SystemUiProcessObserver()
@Before
open fun setUp() {
Assume.assumeTrue(isTelevision)
+
+ systemUiProcessObserver.start()
+
uiDevice.wakeUpAndGoToHomeScreen()
}
@After
open fun tearDown() {
+ if (!isTelevision) return
+
testApp.forceStop()
+
+ // Wait for 1 second, and check if the SystemUI has been alive and well since the start.
+ SystemClock.sleep(AFTER_TEXT_PROCESS_CHECK_DELAY)
+ systemUiProcessObserver.stop()
+ assertFalse("SystemUI has died during test execution", systemUiProcessObserver.hasDied)
}
protected fun fail(message: String): Nothing = throw AssertionError(message)
+ inner class SystemUiProcessObserver : IProcessObserver.Stub() {
+ private val activityManager: IActivityManager = ActivityManager.getService()
+ private val uiAutomation = instrumentation.uiAutomation
+ private val systemUiUid = packageManager.getPackageUid(SYSTEM_UI_PACKAGE_NAME, 0)
+ var hasDied: Boolean = false
+
+ fun start() {
+ hasDied = false
+ uiAutomation.adoptShellPermissionIdentity(
+ android.Manifest.permission.SET_ACTIVITY_WATCHER)
+ activityManager.registerProcessObserver(this)
+ }
+
+ fun stop() {
+ activityManager.unregisterProcessObserver(this)
+ uiAutomation.dropShellPermissionIdentity()
+ }
+
+ override fun onForegroundActivitiesChanged(pid: Int, uid: Int, foreground: Boolean) {}
+
+ override fun onForegroundServicesChanged(pid: Int, uid: Int, serviceTypes: Int) {}
+
+ override fun onProcessDied(pid: Int, uid: Int) {
+ if (uid == systemUiUid) hasDied = true
+ }
+ }
+
companion object {
+ private const val AFTER_TEXT_PROCESS_CHECK_DELAY = 1_000L // 1 sec
+
@JvmStatic
protected val rotationParams: Collection<Array<Any>> =
listOf(arrayOf(rotationToString(ROTATION_0), ROTATION_0))
diff --git a/libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/apppairs/AppPairTests.java b/libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/apppairs/AppPairTests.java
new file mode 100644
index 0000000..9ab0f89
--- /dev/null
+++ b/libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/apppairs/AppPairTests.java
@@ -0,0 +1,81 @@
+/*
+ * Copyright (C) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package com.android.wm.shell.apppairs;
+
+import static com.google.common.truth.Truth.assertThat;
+
+import android.app.ActivityManager;
+
+import androidx.test.ext.junit.runners.AndroidJUnit4;
+import androidx.test.filters.SmallTest;
+
+import com.android.wm.shell.ShellTaskOrganizer;
+import com.android.wm.shell.common.SyncTransactionQueue;
+
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+import org.mockito.Mock;
+import org.mockito.MockitoAnnotations;
+
+/** Tests for {@link AppPair} */
+@SmallTest
+@RunWith(AndroidJUnit4.class)
+public class AppPairTests {
+
+ private AppPairsController mController;
+ @Mock private SyncTransactionQueue mSyncQueue;
+ @Mock private ShellTaskOrganizer mTaskOrganizer;
+
+ @Before
+ public void setUp() {
+ MockitoAnnotations.initMocks(this);
+ mController = new TestAppPairsController(mTaskOrganizer, mSyncQueue);
+ }
+
+ @After
+ public void tearDown() {}
+
+ @Test
+ public void testContains() {
+ final ActivityManager.RunningTaskInfo task1 = new TestRunningTaskInfoBuilder().build();
+ final ActivityManager.RunningTaskInfo task2 = new TestRunningTaskInfoBuilder().build();
+
+ final AppPair pair = mController.pairInner(task1, task2);
+ assertThat(pair.contains(task1.taskId)).isTrue();
+ assertThat(pair.contains(task2.taskId)).isTrue();
+
+ pair.unpair();
+ assertThat(pair.contains(task1.taskId)).isFalse();
+ assertThat(pair.contains(task2.taskId)).isFalse();
+ }
+
+ @Test
+ public void testVanishUnpairs() {
+ final ActivityManager.RunningTaskInfo task1 = new TestRunningTaskInfoBuilder().build();
+ final ActivityManager.RunningTaskInfo task2 = new TestRunningTaskInfoBuilder().build();
+
+ final AppPair pair = mController.pairInner(task1, task2);
+ assertThat(pair.contains(task1.taskId)).isTrue();
+ assertThat(pair.contains(task2.taskId)).isTrue();
+
+ pair.onTaskVanished(task1);
+ assertThat(pair.contains(task1.taskId)).isFalse();
+ assertThat(pair.contains(task2.taskId)).isFalse();
+ }
+}
diff --git a/libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/apppairs/AppPairsControllerTests.java b/libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/apppairs/AppPairsControllerTests.java
new file mode 100644
index 0000000..ed85b67
--- /dev/null
+++ b/libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/apppairs/AppPairsControllerTests.java
@@ -0,0 +1,85 @@
+/*
+ * Copyright (C) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package com.android.wm.shell.apppairs;
+
+import static com.google.common.truth.Truth.assertThat;
+
+import android.app.ActivityManager;
+
+import androidx.test.ext.junit.runners.AndroidJUnit4;
+import androidx.test.filters.SmallTest;
+
+import com.android.wm.shell.ShellTaskOrganizer;
+import com.android.wm.shell.common.SyncTransactionQueue;
+
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+import org.mockito.Mock;
+import org.mockito.MockitoAnnotations;
+
+/** Tests for {@link AppPairsController} */
+@SmallTest
+@RunWith(AndroidJUnit4.class)
+public class AppPairsControllerTests {
+ private TestAppPairsController mController;
+ private TestAppPairsPool mPool;
+ @Mock private SyncTransactionQueue mSyncQueue;
+ @Mock private ShellTaskOrganizer mTaskOrganizer;
+
+ @Before
+ public void setUp() {
+ MockitoAnnotations.initMocks(this);
+ mController = new TestAppPairsController(mTaskOrganizer, mSyncQueue);
+ mPool = mController.getPool();
+ }
+
+ @After
+ public void tearDown() {}
+
+ @Test
+ public void testPairUnpair() {
+ final ActivityManager.RunningTaskInfo task1 = new TestRunningTaskInfoBuilder().build();
+ final ActivityManager.RunningTaskInfo task2 = new TestRunningTaskInfoBuilder().build();
+
+ final AppPair pair = mController.pairInner(task1, task2);
+ assertThat(pair.contains(task1.taskId)).isTrue();
+ assertThat(pair.contains(task2.taskId)).isTrue();
+ assertThat(mPool.poolSize()).isGreaterThan(0);
+
+ mController.unpair(task2.taskId);
+ assertThat(pair.contains(task1.taskId)).isFalse();
+ assertThat(pair.contains(task2.taskId)).isFalse();
+ assertThat(mPool.poolSize()).isGreaterThan(1);
+ }
+
+ @Test
+ public void testUnpair_DontReleaseToPool() {
+ final ActivityManager.RunningTaskInfo task1 = new TestRunningTaskInfoBuilder().build();
+ final ActivityManager.RunningTaskInfo task2 = new TestRunningTaskInfoBuilder().build();
+
+ final AppPair pair = mController.pairInner(task1, task2);
+ assertThat(pair.contains(task1.taskId)).isTrue();
+ assertThat(pair.contains(task2.taskId)).isTrue();
+
+ mController.unpair(task2.taskId, false /* releaseToPool */);
+ assertThat(pair.contains(task1.taskId)).isFalse();
+ assertThat(pair.contains(task2.taskId)).isFalse();
+ assertThat(mPool.poolSize()).isEqualTo(1);
+ }
+}
diff --git a/libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/apppairs/AppPairsPoolTests.java b/libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/apppairs/AppPairsPoolTests.java
new file mode 100644
index 0000000..4a0fe0f
--- /dev/null
+++ b/libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/apppairs/AppPairsPoolTests.java
@@ -0,0 +1,67 @@
+/*
+ * Copyright (C) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package com.android.wm.shell.apppairs;
+
+import static com.google.common.truth.Truth.assertThat;
+
+import androidx.test.ext.junit.runners.AndroidJUnit4;
+import androidx.test.filters.SmallTest;
+
+import com.android.wm.shell.ShellTaskOrganizer;
+import com.android.wm.shell.common.SyncTransactionQueue;
+
+import org.junit.After;
+import org.junit.Before;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+import org.mockito.Mock;
+import org.mockito.MockitoAnnotations;
+
+/** Tests for {@link AppPairsPool} */
+@SmallTest
+@RunWith(AndroidJUnit4.class)
+public class AppPairsPoolTests {
+ private TestAppPairsController mController;
+ private TestAppPairsPool mPool;
+ @Mock private SyncTransactionQueue mSyncQueue;
+ @Mock private ShellTaskOrganizer mTaskOrganizer;
+
+ @Before
+ public void setUp() {
+ MockitoAnnotations.initMocks(this);
+ mController = new TestAppPairsController(mTaskOrganizer, mSyncQueue);
+ mPool = mController.getPool();
+ }
+
+ @After
+ public void tearDown() {}
+
+ @Test
+ public void testInitialState() {
+ // Pool should always start off with at least 1 entry.
+ assertThat(mPool.poolSize()).isGreaterThan(0);
+ }
+
+ @Test
+ public void testAcquireRelease() {
+ assertThat(mPool.poolSize()).isGreaterThan(0);
+ final AppPair appPair = mPool.acquire();
+ assertThat(mPool.poolSize()).isGreaterThan(0);
+ mPool.release(appPair);
+ assertThat(mPool.poolSize()).isGreaterThan(1);
+ }
+}
diff --git a/libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/apppairs/TestAppPairsController.java b/libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/apppairs/TestAppPairsController.java
new file mode 100644
index 0000000..7ea5a1b
--- /dev/null
+++ b/libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/apppairs/TestAppPairsController.java
@@ -0,0 +1,34 @@
+/*
+ * Copyright (C) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package com.android.wm.shell.apppairs;
+
+import com.android.wm.shell.ShellTaskOrganizer;
+import com.android.wm.shell.common.SyncTransactionQueue;
+
+public class TestAppPairsController extends AppPairsController {
+ TestAppPairsPool mPool;
+
+ public TestAppPairsController(ShellTaskOrganizer organizer, SyncTransactionQueue syncQueue) {
+ super(organizer, syncQueue);
+ mPool = new TestAppPairsPool(this);
+ setPairsPool(mPool);
+ }
+
+ TestAppPairsPool getPool() {
+ return mPool;
+ }
+}
diff --git a/libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/apppairs/TestAppPairsPool.java b/libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/apppairs/TestAppPairsPool.java
new file mode 100644
index 0000000..080f207
--- /dev/null
+++ b/libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/apppairs/TestAppPairsPool.java
@@ -0,0 +1,34 @@
+/*
+ * Copyright (C) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package com.android.wm.shell.apppairs;
+
+import android.app.ActivityManager;
+
+public class TestAppPairsPool extends AppPairsPool{
+ TestAppPairsPool(AppPairsController controller) {
+ super(controller);
+ }
+
+ @Override
+ void incrementPool() {
+ final AppPair entry = new AppPair(mController);
+ final ActivityManager.RunningTaskInfo info =
+ new TestRunningTaskInfoBuilder().build();
+ entry.onTaskAppeared(info, null /* leash */);
+ release(entry);
+ }
+}
diff --git a/libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/apppairs/TestRunningTaskInfoBuilder.java b/libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/apppairs/TestRunningTaskInfoBuilder.java
new file mode 100644
index 0000000..76d3a6a
--- /dev/null
+++ b/libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/apppairs/TestRunningTaskInfoBuilder.java
@@ -0,0 +1,43 @@
+/*
+ * Copyright (C) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package com.android.wm.shell.apppairs;
+
+import android.app.ActivityManager;
+import android.graphics.Rect;
+import android.window.IWindowContainerToken;
+import android.window.WindowContainerToken;
+
+public class TestRunningTaskInfoBuilder {
+ static int sNextTaskId = 500;
+ private Rect mBounds = new Rect(0, 0, 100, 100);
+ private WindowContainerToken mToken =
+ new WindowContainerToken(new IWindowContainerToken.Default());
+
+ TestRunningTaskInfoBuilder setBounds(Rect bounds) {
+ mBounds.set(bounds);
+ return this;
+ }
+
+ ActivityManager.RunningTaskInfo build() {
+ final ActivityManager.RunningTaskInfo info = new ActivityManager.RunningTaskInfo();
+ info.taskId = sNextTaskId++;
+ info.configuration.windowConfiguration.setBounds(mBounds);
+ info.token = mToken;
+ info.isResizeable = true;
+ return info;
+ }
+}
diff --git a/libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/pip/PipBoundsHandlerTest.java b/libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/pip/PipBoundsAlgorithmTest.java
similarity index 83%
rename from libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/pip/PipBoundsHandlerTest.java
rename to libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/pip/PipBoundsAlgorithmTest.java
index ba60d3d..7a6e0c1 100644
--- a/libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/pip/PipBoundsHandlerTest.java
+++ b/libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/pip/PipBoundsAlgorithmTest.java
@@ -36,7 +36,7 @@
import org.junit.runner.RunWith;
/**
- * Unit tests against {@link PipBoundsHandler}, including but not limited to:
+ * Unit tests against {@link PipBoundsAlgorithm}, including but not limited to:
* - default/movement bounds
* - save/restore PiP position on application lifecycle
* - save/restore PiP position on screen rotation
@@ -44,14 +44,14 @@
@RunWith(AndroidTestingRunner.class)
@SmallTest
@TestableLooper.RunWithLooper(setAsMainLooper = true)
-public class PipBoundsHandlerTest extends ShellTestCase {
+public class PipBoundsAlgorithmTest extends ShellTestCase {
private static final int ROUNDING_ERROR_MARGIN = 16;
private static final float ASPECT_RATIO_ERROR_MARGIN = 0.01f;
private static final float DEFAULT_ASPECT_RATIO = 1f;
private static final float MIN_ASPECT_RATIO = 0.5f;
private static final float MAX_ASPECT_RATIO = 2f;
- private PipBoundsHandler mPipBoundsHandler;
+ private PipBoundsAlgorithm mPipBoundsAlgorithm;
private DisplayInfo mDefaultDisplayInfo;
private PipBoundsState mPipBoundsState;
@@ -59,7 +59,7 @@
public void setUp() throws Exception {
initializeMockResources();
mPipBoundsState = new PipBoundsState(mContext);
- mPipBoundsHandler = new PipBoundsHandler(mContext, mPipBoundsState);
+ mPipBoundsAlgorithm = new PipBoundsAlgorithm(mContext, mPipBoundsState);
mPipBoundsState.setDisplayInfo(mDefaultDisplayInfo);
}
@@ -93,7 +93,7 @@
@Test
public void getDefaultAspectRatio() {
assertEquals("Default aspect ratio matches resources",
- DEFAULT_ASPECT_RATIO, mPipBoundsHandler.getDefaultAspectRatio(),
+ DEFAULT_ASPECT_RATIO, mPipBoundsAlgorithm.getDefaultAspectRatio(),
ASPECT_RATIO_ERROR_MARGIN);
}
@@ -104,10 +104,10 @@
res.addOverride(com.android.internal.R.dimen.config_pictureInPictureDefaultAspectRatio,
newDefaultAspectRatio);
- mPipBoundsHandler.onConfigurationChanged(mContext);
+ mPipBoundsAlgorithm.onConfigurationChanged(mContext);
assertEquals("Default aspect ratio should be reloaded",
- mPipBoundsHandler.getDefaultAspectRatio(), newDefaultAspectRatio,
+ mPipBoundsAlgorithm.getDefaultAspectRatio(), newDefaultAspectRatio,
ASPECT_RATIO_ERROR_MARGIN);
}
@@ -120,7 +120,7 @@
};
for (float aspectRatio : aspectRatios) {
mPipBoundsState.setAspectRatio(aspectRatio);
- final Rect destinationBounds = mPipBoundsHandler.getEntryDestinationBounds();
+ final Rect destinationBounds = mPipBoundsAlgorithm.getEntryDestinationBounds();
final float actualAspectRatio =
destinationBounds.width() / (destinationBounds.height() * 1f);
assertEquals("Destination bounds matches the given aspect ratio",
@@ -136,11 +136,11 @@
};
for (float aspectRatio : invalidAspectRatios) {
mPipBoundsState.setAspectRatio(aspectRatio);
- final Rect destinationBounds = mPipBoundsHandler.getEntryDestinationBounds();
+ final Rect destinationBounds = mPipBoundsAlgorithm.getEntryDestinationBounds();
final float actualAspectRatio =
destinationBounds.width() / (destinationBounds.height() * 1f);
assertEquals("Destination bounds fallbacks to default aspect ratio",
- mPipBoundsHandler.getDefaultAspectRatio(), actualAspectRatio,
+ mPipBoundsAlgorithm.getDefaultAspectRatio(), actualAspectRatio,
ASPECT_RATIO_ERROR_MARGIN);
}
}
@@ -152,7 +152,7 @@
currentBounds.right = (int) (currentBounds.height() * aspectRatio) + currentBounds.left;
mPipBoundsState.setAspectRatio(aspectRatio);
- final Rect destinationBounds = mPipBoundsHandler.getAdjustedDestinationBounds(
+ final Rect destinationBounds = mPipBoundsAlgorithm.getAdjustedDestinationBounds(
currentBounds, aspectRatio);
final float actualAspectRatio =
@@ -178,7 +178,7 @@
final Size minimalSize = minimalSizes[i];
mPipBoundsState.setAspectRatio(aspectRatio);
mPipBoundsState.setOverrideMinSize(minimalSize);
- final Rect destinationBounds = mPipBoundsHandler.getEntryDestinationBounds();
+ final Rect destinationBounds = mPipBoundsAlgorithm.getEntryDestinationBounds();
assertTrue("Destination bounds is no smaller than minimal requirement",
(destinationBounds.width() == minimalSize.getWidth()
&& destinationBounds.height() >= minimalSize.getHeight())
@@ -200,7 +200,7 @@
mPipBoundsState.setAspectRatio(aspectRatio);
mPipBoundsState.setOverrideMinSize(minSize);
- final Rect destinationBounds = mPipBoundsHandler.getAdjustedDestinationBounds(
+ final Rect destinationBounds = mPipBoundsAlgorithm.getAdjustedDestinationBounds(
currentBounds, aspectRatio);
assertTrue("Destination bounds ignores minimal size",
@@ -211,12 +211,12 @@
@Test
public void getEntryDestinationBounds_reentryStateExists_restoreLastSize() {
mPipBoundsState.setAspectRatio(DEFAULT_ASPECT_RATIO);
- final Rect reentryBounds = mPipBoundsHandler.getEntryDestinationBounds();
+ final Rect reentryBounds = mPipBoundsAlgorithm.getEntryDestinationBounds();
reentryBounds.scale(1.25f);
- final float reentrySnapFraction = mPipBoundsHandler.getSnapFraction(reentryBounds);
+ final float reentrySnapFraction = mPipBoundsAlgorithm.getSnapFraction(reentryBounds);
mPipBoundsState.saveReentryState(reentryBounds, reentrySnapFraction);
- final Rect destinationBounds = mPipBoundsHandler.getEntryDestinationBounds();
+ final Rect destinationBounds = mPipBoundsAlgorithm.getEntryDestinationBounds();
assertEquals(reentryBounds.width(), destinationBounds.width());
assertEquals(reentryBounds.height(), destinationBounds.height());
@@ -225,13 +225,13 @@
@Test
public void getEntryDestinationBounds_reentryStateExists_restoreLastPosition() {
mPipBoundsState.setAspectRatio(DEFAULT_ASPECT_RATIO);
- final Rect reentryBounds = mPipBoundsHandler.getEntryDestinationBounds();
+ final Rect reentryBounds = mPipBoundsAlgorithm.getEntryDestinationBounds();
reentryBounds.offset(0, -100);
- final float reentrySnapFraction = mPipBoundsHandler.getSnapFraction(reentryBounds);
+ final float reentrySnapFraction = mPipBoundsAlgorithm.getSnapFraction(reentryBounds);
mPipBoundsState.saveReentryState(reentryBounds, reentrySnapFraction);
- final Rect destinationBounds = mPipBoundsHandler.getEntryDestinationBounds();
+ final Rect destinationBounds = mPipBoundsAlgorithm.getEntryDestinationBounds();
assertBoundsInclusionWithMargin("restoreLastPosition", reentryBounds, destinationBounds);
}
@@ -240,10 +240,10 @@
public void setShelfHeight_offsetBounds() {
final int shelfHeight = 100;
mPipBoundsState.setAspectRatio(DEFAULT_ASPECT_RATIO);
- final Rect oldPosition = mPipBoundsHandler.getEntryDestinationBounds();
+ final Rect oldPosition = mPipBoundsAlgorithm.getEntryDestinationBounds();
mPipBoundsState.setShelfVisibility(true, shelfHeight);
- final Rect newPosition = mPipBoundsHandler.getEntryDestinationBounds();
+ final Rect newPosition = mPipBoundsAlgorithm.getEntryDestinationBounds();
oldPosition.offset(0, -shelfHeight);
assertBoundsInclusionWithMargin("offsetBounds by shelf", oldPosition, newPosition);
@@ -253,10 +253,10 @@
public void onImeVisibilityChanged_offsetBounds() {
final int imeHeight = 100;
mPipBoundsState.setAspectRatio(DEFAULT_ASPECT_RATIO);
- final Rect oldPosition = mPipBoundsHandler.getEntryDestinationBounds();
+ final Rect oldPosition = mPipBoundsAlgorithm.getEntryDestinationBounds();
mPipBoundsState.setImeVisibility(true, imeHeight);
- final Rect newPosition = mPipBoundsHandler.getEntryDestinationBounds();
+ final Rect newPosition = mPipBoundsAlgorithm.getEntryDestinationBounds();
oldPosition.offset(0, -imeHeight);
assertBoundsInclusionWithMargin("offsetBounds by IME", oldPosition, newPosition);
@@ -265,11 +265,11 @@
@Test
public void getEntryDestinationBounds_noReentryState_useDefaultBounds() {
mPipBoundsState.setAspectRatio(DEFAULT_ASPECT_RATIO);
- final Rect defaultBounds = mPipBoundsHandler.getEntryDestinationBounds();
+ final Rect defaultBounds = mPipBoundsAlgorithm.getEntryDestinationBounds();
mPipBoundsState.clearReentryState();
- final Rect actualBounds = mPipBoundsHandler.getEntryDestinationBounds();
+ final Rect actualBounds = mPipBoundsAlgorithm.getEntryDestinationBounds();
assertBoundsInclusionWithMargin("useDefaultBounds", defaultBounds, actualBounds);
}
diff --git a/libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/pip/PipTaskOrganizerTest.java b/libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/pip/PipTaskOrganizerTest.java
index 08841bd..8d3774c 100644
--- a/libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/pip/PipTaskOrganizerTest.java
+++ b/libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/pip/PipTaskOrganizerTest.java
@@ -65,7 +65,7 @@
private PipTaskOrganizer mSpiedPipTaskOrganizer;
@Mock private DisplayController mMockdDisplayController;
- @Mock private PipBoundsHandler mMockPipBoundsHandler;
+ @Mock private PipBoundsAlgorithm mMockPipBoundsAlgorithm;
@Mock private PipMenuActivityController mMenuActivityController;
@Mock private PipSurfaceTransactionHelper mMockPipSurfaceTransactionHelper;
@Mock private PipUiEventLogger mMockPipUiEventLogger;
@@ -83,7 +83,7 @@
mComponent2 = new ComponentName(mContext, "component2");
mPipBoundsState = new PipBoundsState(mContext);
mSpiedPipTaskOrganizer = spy(new PipTaskOrganizer(mContext, mPipBoundsState,
- mMockPipBoundsHandler, mMenuActivityController, mMockPipSurfaceTransactionHelper,
+ mMockPipBoundsAlgorithm, mMenuActivityController, mMockPipSurfaceTransactionHelper,
mMockOptionalSplitScreen, mMockdDisplayController, mMockPipUiEventLogger,
mMockShellTaskOrganizer));
preparePipTaskOrg();
@@ -192,8 +192,8 @@
private void preparePipTaskOrg() {
final DisplayInfo info = new DisplayInfo();
mPipBoundsState.setDisplayInfo(info);
- when(mMockPipBoundsHandler.getEntryDestinationBounds()).thenReturn(new Rect());
- when(mMockPipBoundsHandler.getAdjustedDestinationBounds(any(), anyFloat()))
+ when(mMockPipBoundsAlgorithm.getEntryDestinationBounds()).thenReturn(new Rect());
+ when(mMockPipBoundsAlgorithm.getAdjustedDestinationBounds(any(), anyFloat()))
.thenReturn(new Rect());
mPipBoundsState.setDisplayInfo(info);
mSpiedPipTaskOrganizer.setOneShotAnimationType(PipAnimationController.ANIM_TYPE_ALPHA);
diff --git a/libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/pip/phone/PipControllerTest.java b/libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/pip/phone/PipControllerTest.java
index 745d188..88c8eb9 100644
--- a/libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/pip/phone/PipControllerTest.java
+++ b/libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/pip/phone/PipControllerTest.java
@@ -40,7 +40,7 @@
import com.android.wm.shell.common.DisplayController;
import com.android.wm.shell.common.ShellExecutor;
import com.android.wm.shell.common.TaskStackListenerImpl;
-import com.android.wm.shell.pip.PipBoundsHandler;
+import com.android.wm.shell.pip.PipBoundsAlgorithm;
import com.android.wm.shell.pip.PipBoundsState;
import com.android.wm.shell.pip.PipMediaController;
import com.android.wm.shell.pip.PipTaskOrganizer;
@@ -63,7 +63,7 @@
@Mock private DisplayController mMockDisplayController;
@Mock private PipMenuActivityController mMockPipMenuActivityController;
@Mock private PipAppOpsListener mMockPipAppOpsListener;
- @Mock private PipBoundsHandler mMockPipBoundsHandler;
+ @Mock private PipBoundsAlgorithm mMockPipBoundsAlgorithm;
@Mock private PipMediaController mMockPipMediaController;
@Mock private PipTaskOrganizer mMockPipTaskOrganizer;
@Mock private PipTouchHandler mMockPipTouchHandler;
@@ -76,7 +76,7 @@
public void setUp() throws RemoteException {
MockitoAnnotations.initMocks(this);
mPipController = new PipController(mContext, mMockDisplayController,
- mMockPipAppOpsListener, mMockPipBoundsHandler, mMockPipBoundsState,
+ mMockPipAppOpsListener, mMockPipBoundsAlgorithm, mMockPipBoundsState,
mMockPipMediaController, mMockPipMenuActivityController, mMockPipTaskOrganizer,
mMockPipTouchHandler, mMockWindowManagerShellWrapper, mMockTaskStackListener,
mMockExecutor);
@@ -109,7 +109,7 @@
when(spyContext.getPackageManager()).thenReturn(mockPackageManager);
assertNull(PipController.create(spyContext, mMockDisplayController,
- mMockPipAppOpsListener, mMockPipBoundsHandler, mMockPipBoundsState,
+ mMockPipAppOpsListener, mMockPipBoundsAlgorithm, mMockPipBoundsState,
mMockPipMediaController, mMockPipMenuActivityController, mMockPipTaskOrganizer,
mMockPipTouchHandler, mMockWindowManagerShellWrapper, mMockTaskStackListener,
mMockExecutor));
diff --git a/libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/pip/phone/PipTouchHandlerTest.java b/libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/pip/phone/PipTouchHandlerTest.java
index 94f3051..ec02331 100644
--- a/libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/pip/phone/PipTouchHandlerTest.java
+++ b/libs/WindowManager/Shell/tests/unittest/src/com/android/wm/shell/pip/phone/PipTouchHandlerTest.java
@@ -33,7 +33,7 @@
import com.android.wm.shell.R;
import com.android.wm.shell.ShellTestCase;
import com.android.wm.shell.common.FloatingContentCoordinator;
-import com.android.wm.shell.pip.PipBoundsHandler;
+import com.android.wm.shell.pip.PipBoundsAlgorithm;
import com.android.wm.shell.pip.PipBoundsState;
import com.android.wm.shell.pip.PipSnapAlgorithm;
import com.android.wm.shell.pip.PipTaskOrganizer;
@@ -72,7 +72,7 @@
private PipUiEventLogger mPipUiEventLogger;
private PipBoundsState mPipBoundsState;
- private PipBoundsHandler mPipBoundsHandler;
+ private PipBoundsAlgorithm mPipBoundsAlgorithm;
private PipSnapAlgorithm mPipSnapAlgorithm;
private PipMotionHelper mMotionHelper;
private PipResizeGestureHandler mPipResizeGestureHandler;
@@ -89,12 +89,12 @@
public void setUp() throws Exception {
MockitoAnnotations.initMocks(this);
mPipBoundsState = new PipBoundsState(mContext);
- mPipBoundsHandler = new PipBoundsHandler(mContext, mPipBoundsState);
- mPipSnapAlgorithm = mPipBoundsHandler.getSnapAlgorithm();
+ mPipBoundsAlgorithm = new PipBoundsAlgorithm(mContext, mPipBoundsState);
+ mPipSnapAlgorithm = mPipBoundsAlgorithm.getSnapAlgorithm();
mPipSnapAlgorithm = new PipSnapAlgorithm(mContext);
mPipTouchHandler = new PipTouchHandler(mContext, mPipMenuActivityController,
- mPipBoundsHandler, mPipBoundsState, mPipTaskOrganizer, mFloatingContentCoordinator,
- mPipUiEventLogger);
+ mPipBoundsAlgorithm, mPipBoundsState, mPipTaskOrganizer,
+ mFloatingContentCoordinator, mPipUiEventLogger);
mMotionHelper = Mockito.spy(mPipTouchHandler.getMotionHelper());
mPipResizeGestureHandler = Mockito.spy(mPipTouchHandler.getPipResizeGestureHandler());
mPipTouchHandler.setPipMotionHelper(mMotionHelper);
diff --git a/libs/androidfw/Android.bp b/libs/androidfw/Android.bp
index a3fcf90..8330363 100644
--- a/libs/androidfw/Android.bp
+++ b/libs/androidfw/Android.bp
@@ -61,6 +61,9 @@
],
export_include_dirs: ["include"],
export_shared_lib_headers: ["libz"],
+ static_libs: ["libincfs-utils"],
+ whole_static_libs: ["libincfs-utils"],
+ export_static_lib_headers: ["libincfs-utils"],
target: {
android: {
srcs: [
@@ -69,13 +72,14 @@
"CursorWindow.cpp",
],
shared_libs: [
- "libziparchive",
"libbase",
"libbinder",
"liblog",
"libcutils",
+ "libincfs",
"libutils",
"libz",
+ "libziparchive",
],
static: {
enabled: false,
@@ -86,11 +90,11 @@
enabled: false,
},
static_libs: [
- "libziparchive",
"libbase",
- "liblog",
"libcutils",
+ "liblog",
"libutils",
+ "libziparchive",
],
shared_libs: [
"libz",
diff --git a/libs/androidfw/ApkAssets.cpp b/libs/androidfw/ApkAssets.cpp
index e15b42d..cb56a51 100755
--- a/libs/androidfw/ApkAssets.cpp
+++ b/libs/androidfw/ApkAssets.cpp
@@ -25,13 +25,11 @@
#include "android-base/unique_fd.h"
#include "android-base/utf8.h"
#include "utils/Compat.h"
-#include "utils/FileMap.h"
#include "ziparchive/zip_archive.h"
#include "androidfw/Asset.h"
#include "androidfw/Idmap.h"
#include "androidfw/misc.h"
-#include "androidfw/ResourceTypes.h"
#include "androidfw/Util.h"
namespace android {
@@ -161,50 +159,46 @@
}
const int fd = ::GetFileDescriptor(zip_handle_.get());
- const off64_t fd_offset = ::GetFileDescriptorOffset(zip_handle_.get());
+ const off64_t fd_offset = ::GetFileDescriptorOffset(zip_handle_.get());
+ incfs::IncFsFileMap asset_map;
if (entry.method == kCompressDeflated) {
- std::unique_ptr<FileMap> map = util::make_unique<FileMap>();
- if (!map->create(GetPath(), fd, entry.offset + fd_offset, entry.compressed_length,
- true /*readOnly*/)) {
+ if (!asset_map.Create(fd, entry.offset + fd_offset, entry.compressed_length, GetPath())) {
LOG(ERROR) << "Failed to mmap file '" << path << "' in APK '" << friendly_name_ << "'";
return {};
}
std::unique_ptr<Asset> asset =
- Asset::createFromCompressedMap(std::move(map), entry.uncompressed_length, mode);
+ Asset::createFromCompressedMap(std::move(asset_map), entry.uncompressed_length, mode);
if (asset == nullptr) {
LOG(ERROR) << "Failed to decompress '" << path << "' in APK '" << friendly_name_ << "'";
return {};
}
return asset;
- } else {
- std::unique_ptr<FileMap> map = util::make_unique<FileMap>();
- if (!map->create(GetPath(), fd, entry.offset + fd_offset, entry.uncompressed_length,
- true /*readOnly*/)) {
- LOG(ERROR) << "Failed to mmap file '" << path << "' in APK '" << friendly_name_ << "'";
- return {};
- }
-
- unique_fd ufd;
- if (!GetPath()) {
- // If the `path` is not set, create a new `fd` for the new Asset to own in order to create
- // new file descriptors using Asset::openFileDescriptor. If the path is set, it will be used
- // to create new file descriptors.
- ufd = unique_fd(dup(fd));
- if (!ufd.ok()) {
- LOG(ERROR) << "Unable to dup fd '" << path << "' in APK '" << friendly_name_ << "'";
- return {};
- }
- }
-
- std::unique_ptr<Asset> asset = Asset::createFromUncompressedMap(std::move(map),
- std::move(ufd), mode);
- if (asset == nullptr) {
- LOG(ERROR) << "Failed to mmap file '" << path << "' in APK '" << friendly_name_ << "'";
- return {};
- }
- return asset;
}
+
+ if (!asset_map.Create(fd, entry.offset + fd_offset, entry.uncompressed_length, GetPath())) {
+ LOG(ERROR) << "Failed to mmap file '" << path << "' in APK '" << friendly_name_ << "'";
+ return {};
+ }
+
+ unique_fd ufd;
+ if (!GetPath()) {
+ // If the `path` is not set, create a new `fd` for the new Asset to own in order to create
+ // new file descriptors using Asset::openFileDescriptor. If the path is set, it will be used
+ // to create new file descriptors.
+ ufd = unique_fd(dup(fd));
+ if (!ufd.ok()) {
+ LOG(ERROR) << "Unable to dup fd '" << path << "' in APK '" << friendly_name_ << "'";
+ return {};
+ }
+ }
+
+ auto asset = Asset::createFromUncompressedMap(std::move(asset_map), mode, std::move(ufd));
+ if (asset == nullptr) {
+ LOG(ERROR) << "Failed to mmap file '" << path << "' in APK '" << friendly_name_ << "'";
+ return {};
+ }
+ return asset;
}
private:
@@ -446,8 +440,8 @@
}
}
- std::unique_ptr<FileMap> file_map = util::make_unique<FileMap>();
- if (!file_map->create(path, fd, offset, static_cast<size_t>(length), true /*readOnly*/)) {
+ incfs::IncFsFileMap file_map;
+ if (!file_map.Create(fd, offset, static_cast<size_t>(length), path)) {
LOG(ERROR) << "Failed to mmap file '" << ((path) ? path : "anon") << "': "
<< SystemErrorCodeToString(errno);
return {};
@@ -456,8 +450,8 @@
// If `path` is set, do not pass ownership of the `fd` to the new Asset since
// Asset::openFileDescriptor can use `path` to create new file descriptors.
return Asset::createFromUncompressedMap(std::move(file_map),
- (path) ? base::unique_fd(-1) : std::move(fd),
- Asset::AccessMode::ACCESS_RANDOM);
+ Asset::AccessMode::ACCESS_RANDOM,
+ (path) ? base::unique_fd(-1) : std::move(fd));
}
std::unique_ptr<const ApkAssets> ApkAssets::LoadImpl(
@@ -493,15 +487,14 @@
loaded_apk->idmap_asset_ = std::move(idmap_asset);
loaded_apk->loaded_idmap_ = std::move(idmap);
- const StringPiece data(
- reinterpret_cast<const char*>(loaded_apk->resources_asset_->getBuffer(true /*wordAligned*/)),
- loaded_apk->resources_asset_->getLength());
- if (data.data() == nullptr || data.empty()) {
+ const auto data = loaded_apk->resources_asset_->getIncFsBuffer(true /* aligned */);
+ const size_t length = loaded_apk->resources_asset_->getLength();
+ if (!data || length == 0) {
LOG(ERROR) << "Failed to read '" << kResourcesArsc << "' data in APK '" << path << "'.";
return {};
}
- loaded_apk->loaded_arsc_ = LoadedArsc::Load(data, loaded_apk->loaded_idmap_.get(),
+ loaded_apk->loaded_arsc_ = LoadedArsc::Load(data, length, loaded_apk->loaded_idmap_.get(),
property_flags);
if (!loaded_apk->loaded_arsc_) {
LOG(ERROR) << "Failed to load '" << kResourcesArsc << "' in APK '" << path << "'.";
@@ -525,15 +518,15 @@
new ApkAssets(std::move(assets), path, last_mod_time, property_flags));
loaded_apk->resources_asset_ = std::move(resources_asset);
- const StringPiece data(
- reinterpret_cast<const char*>(loaded_apk->resources_asset_->getBuffer(true /*wordAligned*/)),
- loaded_apk->resources_asset_->getLength());
- if (data.data() == nullptr || data.empty()) {
+ const auto data = loaded_apk->resources_asset_->getIncFsBuffer(true /* aligned */);
+ const size_t length = loaded_apk->resources_asset_->getLength();
+ if (!data || length == 0) {
LOG(ERROR) << "Failed to read resources table data in '" << path << "'.";
return {};
}
- loaded_apk->loaded_arsc_ = LoadedArsc::Load(data, nullptr, property_flags);
+ loaded_apk->loaded_arsc_ = LoadedArsc::Load(data, length, nullptr /* loaded_idmap */,
+ property_flags);
if (loaded_apk->loaded_arsc_ == nullptr) {
LOG(ERROR) << "Failed to read resources table in '" << path << "'.";
return {};
@@ -550,7 +543,6 @@
}
return (!loaded_idmap_ || loaded_idmap_->IsUpToDate()) &&
last_mod_time_ == getFileModDate(path_.c_str());
-
}
} // namespace android
diff --git a/libs/androidfw/Asset.cpp b/libs/androidfw/Asset.cpp
index cd30c18..4fbe4a3 100644
--- a/libs/androidfw/Asset.cpp
+++ b/libs/androidfw/Asset.cpp
@@ -298,34 +298,18 @@
/*
* Create a new Asset from a memory mapping.
*/
-/*static*/ Asset* Asset::createFromUncompressedMap(FileMap* dataMap, AccessMode mode)
+/*static*/ std::unique_ptr<Asset> Asset::createFromUncompressedMap(incfs::IncFsFileMap&& dataMap,
+ AccessMode mode,
+ base::unique_fd fd)
{
- _FileAsset* pAsset;
- status_t result;
+ auto pAsset = util::make_unique<_FileAsset>();
- pAsset = new _FileAsset;
- result = pAsset->openChunk(dataMap, base::unique_fd(-1));
- if (result != NO_ERROR) {
- delete pAsset;
- return NULL;
- }
-
- pAsset->mAccessMode = mode;
- return pAsset;
-}
-
-/*static*/ std::unique_ptr<Asset> Asset::createFromUncompressedMap(std::unique_ptr<FileMap> dataMap,
- base::unique_fd fd, AccessMode mode)
-{
- std::unique_ptr<_FileAsset> pAsset = util::make_unique<_FileAsset>();
-
- status_t result = pAsset->openChunk(dataMap.get(), std::move(fd));
+ status_t result = pAsset->openChunk(std::move(dataMap), std::move(fd));
if (result != NO_ERROR) {
return NULL;
}
// We succeeded, so relinquish control of dataMap
- (void) dataMap.release();
pAsset->mAccessMode = mode;
return std::move(pAsset);
}
@@ -333,35 +317,18 @@
/*
* Create a new Asset from compressed data in a memory mapping.
*/
-/*static*/ Asset* Asset::createFromCompressedMap(FileMap* dataMap,
- size_t uncompressedLen, AccessMode mode)
+/*static*/ std::unique_ptr<Asset> Asset::createFromCompressedMap(incfs::IncFsFileMap&& dataMap,
+ size_t uncompressedLen,
+ AccessMode mode)
{
- _CompressedAsset* pAsset;
- status_t result;
+ auto pAsset = util::make_unique<_CompressedAsset>();
- pAsset = new _CompressedAsset;
- result = pAsset->openChunk(dataMap, uncompressedLen);
- if (result != NO_ERROR) {
- delete pAsset;
- return NULL;
- }
-
- pAsset->mAccessMode = mode;
- return pAsset;
-}
-
-/*static*/ std::unique_ptr<Asset> Asset::createFromCompressedMap(std::unique_ptr<FileMap> dataMap,
- size_t uncompressedLen, AccessMode mode)
-{
- std::unique_ptr<_CompressedAsset> pAsset = util::make_unique<_CompressedAsset>();
-
- status_t result = pAsset->openChunk(dataMap.get(), uncompressedLen);
+ status_t result = pAsset->openChunk(std::move(dataMap), uncompressedLen);
if (result != NO_ERROR) {
return NULL;
}
// We succeeded, so relinquish control of dataMap
- (void) dataMap.release();
pAsset->mAccessMode = mode;
return std::move(pAsset);
}
@@ -414,7 +381,7 @@
* Constructor.
*/
_FileAsset::_FileAsset(void)
- : mStart(0), mLength(0), mOffset(0), mFp(NULL), mFileName(NULL), mFd(-1), mMap(NULL), mBuf(NULL)
+ : mStart(0), mLength(0), mOffset(0), mFp(NULL), mFileName(NULL), mFd(-1), mBuf(NULL)
{
// Register the Asset with the global list here after it is fully constructed and its
// vtable pointer points to this concrete type. b/31113965
@@ -441,7 +408,7 @@
status_t _FileAsset::openChunk(const char* fileName, int fd, off64_t offset, size_t length)
{
assert(mFp == NULL); // no reopen
- assert(mMap == NULL);
+ assert(!mMap.has_value());
assert(fd >= 0);
assert(offset >= 0);
@@ -484,15 +451,15 @@
/*
* Create the chunk from the map.
*/
-status_t _FileAsset::openChunk(FileMap* dataMap, base::unique_fd fd)
+status_t _FileAsset::openChunk(incfs::IncFsFileMap&& dataMap, base::unique_fd fd)
{
assert(mFp == NULL); // no reopen
- assert(mMap == NULL);
+ assert(!mMap.has_value());
assert(dataMap != NULL);
- mMap = dataMap;
+ mMap = std::move(dataMap);
mStart = -1; // not used
- mLength = dataMap->getDataLength();
+ mLength = mMap->length();
mFd = std::move(fd);
assert(mOffset == 0);
@@ -528,10 +495,15 @@
if (!count)
return 0;
- if (mMap != NULL) {
+ if (mMap.has_value()) {
/* copy from mapped area */
//printf("map read\n");
- memcpy(buf, (char*)mMap->getDataPtr() + mOffset, count);
+ const auto readPos = mMap->data().offset(mOffset).convert<char>();
+ if (!readPos.verify(count)) {
+ return -1;
+ }
+
+ memcpy(buf, readPos.unsafe_ptr(), count);
actual = count;
} else if (mBuf != NULL) {
/* copy from buffer */
@@ -594,10 +566,6 @@
*/
void _FileAsset::close(void)
{
- if (mMap != NULL) {
- delete mMap;
- mMap = NULL;
- }
if (mBuf != NULL) {
delete[] mBuf;
mBuf = NULL;
@@ -624,16 +592,21 @@
* level and we'd be using a different object, but we didn't, so we
* deal with it here.
*/
-const void* _FileAsset::getBuffer(bool wordAligned)
+const void* _FileAsset::getBuffer(bool aligned)
+{
+ return getIncFsBuffer(aligned).unsafe_ptr();
+}
+
+incfs::map_ptr<void> _FileAsset::getIncFsBuffer(bool aligned)
{
/* subsequent requests just use what we did previously */
if (mBuf != NULL)
return mBuf;
- if (mMap != NULL) {
- if (!wordAligned) {
- return mMap->getDataPtr();
+ if (mMap.has_value()) {
+ if (!aligned) {
+ return mMap->data();
}
- return ensureAlignment(mMap);
+ return ensureAlignment(*mMap);
}
assert(mFp != NULL);
@@ -671,47 +644,44 @@
mBuf = buf;
return mBuf;
} else {
- FileMap* map;
-
- map = new FileMap;
- if (!map->create(NULL, fileno(mFp), mStart, mLength, true)) {
- delete map;
+ incfs::IncFsFileMap map;
+ if (!map.Create(fileno(mFp), mStart, mLength, NULL /* file_name */ )) {
return NULL;
}
ALOGV(" getBuffer: mapped\n");
- mMap = map;
- if (!wordAligned) {
- return mMap->getDataPtr();
+ mMap = std::move(map);
+ if (!aligned) {
+ return mMap->data();
}
- return ensureAlignment(mMap);
+ return ensureAlignment(*mMap);
}
}
int _FileAsset::openFileDescriptor(off64_t* outStart, off64_t* outLength) const
{
- if (mMap != NULL) {
+ if (mMap.has_value()) {
if (mFd.ok()) {
- *outStart = mMap->getDataOffset();
- *outLength = mMap->getDataLength();
- const int fd = dup(mFd);
- if (fd < 0) {
- ALOGE("Unable to dup fd (%d).", mFd.get());
- return -1;
- }
- lseek64(fd, 0, SEEK_SET);
- return fd;
+ *outStart = mMap->offset();
+ *outLength = mMap->length();
+ const int fd = dup(mFd);
+ if (fd < 0) {
+ ALOGE("Unable to dup fd (%d).", mFd.get());
+ return -1;
+ }
+ lseek64(fd, 0, SEEK_SET);
+ return fd;
}
- const char* fname = mMap->getFileName();
+ const char* fname = mMap->file_name();
if (fname == NULL) {
fname = mFileName;
}
if (fname == NULL) {
return -1;
}
- *outStart = mMap->getDataOffset();
- *outLength = mMap->getDataLength();
+ *outStart = mMap->offset();
+ *outLength = mMap->length();
return open(fname, O_RDONLY | O_BINARY);
}
if (mFileName == NULL) {
@@ -722,16 +692,21 @@
return open(mFileName, O_RDONLY | O_BINARY);
}
-const void* _FileAsset::ensureAlignment(FileMap* map)
+incfs::map_ptr<void> _FileAsset::ensureAlignment(const incfs::IncFsFileMap& map)
{
- void* data = map->getDataPtr();
- if ((((size_t)data)&0x3) == 0) {
+ const auto data = map.data();
+ if (util::IsFourByteAligned(data)) {
// We can return this directly if it is aligned on a word
// boundary.
ALOGV("Returning aligned FileAsset %p (%s).", this,
getAssetSource());
return data;
}
+
+ if (!data.convert<uint8_t>().verify(mLength)) {
+ return NULL;
+ }
+
// If not aligned on a word boundary, then we need to copy it into
// our own buffer.
ALOGV("Copying FileAsset %p (%s) to buffer size %d to make it aligned.", this,
@@ -741,7 +716,8 @@
ALOGE("alloc of %ld bytes failed\n", (long) mLength);
return NULL;
}
- memcpy(buf, data, mLength);
+
+ memcpy(buf, data.unsafe_ptr(), mLength);
mBuf = buf;
return buf;
}
@@ -757,7 +733,7 @@
*/
_CompressedAsset::_CompressedAsset(void)
: mStart(0), mCompressedLen(0), mUncompressedLen(0), mOffset(0),
- mMap(NULL), mFd(-1), mZipInflater(NULL), mBuf(NULL)
+ mFd(-1), mZipInflater(NULL), mBuf(NULL)
{
// Register the Asset with the global list here after it is fully constructed and its
// vtable pointer points to this concrete type. b/31113965
@@ -786,7 +762,7 @@
int compressionMethod, size_t uncompressedLen, size_t compressedLen)
{
assert(mFd < 0); // no re-open
- assert(mMap == NULL);
+ assert(!mMap.has_value());
assert(fd >= 0);
assert(offset >= 0);
assert(compressedLen > 0);
@@ -815,20 +791,20 @@
*
* Nothing is expanded until the first read call.
*/
-status_t _CompressedAsset::openChunk(FileMap* dataMap, size_t uncompressedLen)
+status_t _CompressedAsset::openChunk(incfs::IncFsFileMap&& dataMap, size_t uncompressedLen)
{
assert(mFd < 0); // no re-open
- assert(mMap == NULL);
+ assert(!mMap.has_value());
assert(dataMap != NULL);
- mMap = dataMap;
+ mMap = std::move(dataMap);
mStart = -1; // not used
- mCompressedLen = dataMap->getDataLength();
+ mCompressedLen = mMap->length();
mUncompressedLen = uncompressedLen;
assert(mOffset == 0);
if (uncompressedLen > StreamingZipInflater::OUTPUT_CHUNK_SIZE) {
- mZipInflater = new StreamingZipInflater(dataMap, uncompressedLen);
+ mZipInflater = new StreamingZipInflater(&(*mMap), uncompressedLen);
}
return NO_ERROR;
}
@@ -901,11 +877,6 @@
*/
void _CompressedAsset::close(void)
{
- if (mMap != NULL) {
- delete mMap;
- mMap = NULL;
- }
-
delete[] mBuf;
mBuf = NULL;
@@ -940,8 +911,8 @@
goto bail;
}
- if (mMap != NULL) {
- if (!ZipUtils::inflateToBuffer(mMap->getDataPtr(), buf,
+ if (mMap.has_value()) {
+ if (!ZipUtils::inflateToBuffer(mMap->data(), buf,
mUncompressedLen, mCompressedLen))
goto bail;
} else {
@@ -976,3 +947,6 @@
return mBuf;
}
+incfs::map_ptr<void> _CompressedAsset::getIncFsBuffer(bool aligned) {
+ return incfs::map_ptr<void>(getBuffer(aligned));
+}
diff --git a/libs/androidfw/AssetManager.cpp b/libs/androidfw/AssetManager.cpp
index f7c8337..fb2b571 100644
--- a/libs/androidfw/AssetManager.cpp
+++ b/libs/androidfw/AssetManager.cpp
@@ -917,7 +917,7 @@
Asset* AssetManager::openAssetFromZipLocked(const ZipFileRO* pZipFile,
const ZipEntryRO entry, AccessMode mode, const String8& entryName)
{
- Asset* pAsset = NULL;
+ std::unique_ptr<Asset> pAsset;
// TODO: look for previously-created shared memory slice?
uint16_t method;
@@ -932,28 +932,28 @@
return NULL;
}
- FileMap* dataMap = pZipFile->createEntryFileMap(entry);
- if (dataMap == NULL) {
+ std::optional<incfs::IncFsFileMap> dataMap = pZipFile->createEntryIncFsFileMap(entry);
+ if (!dataMap.has_value()) {
ALOGW("create map from entry failed\n");
return NULL;
}
if (method == ZipFileRO::kCompressStored) {
- pAsset = Asset::createFromUncompressedMap(dataMap, mode);
+ pAsset = Asset::createFromUncompressedMap(std::move(*dataMap), mode);
ALOGV("Opened uncompressed entry %s in zip %s mode %d: %p", entryName.string(),
- dataMap->getFileName(), mode, pAsset);
+ dataMap->file_name(), mode, pAsset.get());
} else {
- pAsset = Asset::createFromCompressedMap(dataMap,
+ pAsset = Asset::createFromCompressedMap(std::move(*dataMap),
static_cast<size_t>(uncompressedLen), mode);
ALOGV("Opened compressed entry %s in zip %s mode %d: %p", entryName.string(),
- dataMap->getFileName(), mode, pAsset);
+ dataMap->file_name(), mode, pAsset.get());
}
if (pAsset == NULL) {
/* unexpected */
ALOGW("create from segment failed\n");
}
- return pAsset;
+ return pAsset.release();
}
/*
diff --git a/libs/androidfw/AssetManager2.cpp b/libs/androidfw/AssetManager2.cpp
index 99dd313..c49dc28 100644
--- a/libs/androidfw/AssetManager2.cpp
+++ b/libs/androidfw/AssetManager2.cpp
@@ -38,9 +38,43 @@
namespace android {
+namespace {
+
+using EntryValue = std::variant<Res_value, incfs::verified_map_ptr<ResTable_map_entry>>;
+
+base::expected<EntryValue, IOError> GetEntryValue(
+ incfs::verified_map_ptr<ResTable_entry> table_entry) {
+ const uint16_t entry_size = dtohs(table_entry->size);
+
+ // Check if the entry represents a bag value.
+ if (entry_size >= sizeof(ResTable_map_entry) &&
+ (dtohs(table_entry->flags) & ResTable_entry::FLAG_COMPLEX)) {
+ const auto map_entry = table_entry.convert<ResTable_map_entry>();
+ if (!map_entry) {
+ return base::unexpected(IOError::PAGES_MISSING);
+ }
+ return map_entry.verified();
+ }
+
+ // The entry represents a non-bag value.
+ const auto entry_value = table_entry.offset(entry_size).convert<Res_value>();
+ if (!entry_value) {
+ return base::unexpected(IOError::PAGES_MISSING);
+ }
+ Res_value value;
+ value.copyFrom_dtoh(entry_value.value());
+ return value;
+}
+
+} // namespace
+
struct FindEntryResult {
- // A pointer to the value of the resource table entry.
- std::variant<Res_value, const ResTable_map_entry*> entry;
+ // The cookie representing the ApkAssets in which the value resides.
+ ApkAssetsCookie cookie;
+
+ // The value of the resource table entry. Either an android::Res_value for non-bag types or an
+ // incfs::verified_map_ptr<ResTable_map_entry> for bag types.
+ EntryValue entry;
// The configuration for which the resulting entry was defined. This is already swapped to host
// endianness.
@@ -265,7 +299,7 @@
}
const PackageGroup& package_group = package_groups_[idx];
- if (package_group.packages_.size() == 0) {
+ if (package_group.packages_.empty()) {
return nullptr;
}
@@ -310,14 +344,14 @@
for (auto it = loaded_package->begin(); it != loaded_package->end(); it++) {
const OverlayableInfo* info = loaded_package->GetOverlayableInfo(*it);
if (info != nullptr) {
- ResourceName res_name;
- if (!GetResourceName(*it, &res_name)) {
+ auto res_name = GetResourceName(*it);
+ if (!res_name.has_value()) {
ANDROID_LOG(ERROR) << base::StringPrintf(
"Unable to retrieve name of overlayable resource 0x%08x", *it);
return false;
}
- const std::string name = ToFormattedResourceString(&res_name);
+ const std::string name = ToFormattedResourceString(*res_name);
output.append(base::StringPrintf(
"resource='%s' overlayable='%s' actor='%s' policy='0x%08x'\n",
name.c_str(), info->name.c_str(), info->actor.c_str(), info->policy_flags));
@@ -365,8 +399,8 @@
return non_system_overlays;
}
-std::set<ResTable_config> AssetManager2::GetResourceConfigurations(bool exclude_system,
- bool exclude_mipmap) const {
+base::expected<std::set<ResTable_config>, IOError> AssetManager2::GetResourceConfigurations(
+ bool exclude_system, bool exclude_mipmap) const {
ATRACE_NAME("AssetManager::GetResourceConfigurations");
const auto non_system_overlays =
(exclude_system) ? GetNonSystemOverlayPaths() : std::set<std::string>();
@@ -386,7 +420,10 @@
continue;
}
- package.loaded_package_->CollectConfigurations(exclude_mipmap, &configurations);
+ auto result = package.loaded_package_->CollectConfigurations(exclude_mipmap, &configurations);
+ if (UNLIKELY(!result.has_value())) {
+ return base::unexpected(result.error());
+ }
}
}
return configurations;
@@ -501,11 +538,11 @@
return apk_assets_[cookie]->GetAssetsProvider()->Open(filename, mode);
}
-ApkAssetsCookie AssetManager2::FindEntry(uint32_t resid, uint16_t density_override,
- bool /*stop_at_first_match*/,
- bool ignore_configuration,
- FindEntryResult* out_entry) const {
- if (resource_resolution_logging_enabled_) {
+base::expected<FindEntryResult, NullOrIOError> AssetManager2::FindEntry(
+ uint32_t resid, uint16_t density_override, bool stop_at_first_match,
+ bool ignore_configuration) const {
+ const bool logging_enabled = resource_resolution_logging_enabled_;
+ if (UNLIKELY(logging_enabled)) {
// Clear the last logged resource resolution.
ResetResourceResolution();
last_resolution_.resid = resid;
@@ -523,94 +560,96 @@
}
// Retrieve the package group from the package id of the resource id.
- if (!is_valid_resid(resid)) {
+ if (UNLIKELY(!is_valid_resid(resid))) {
LOG(ERROR) << base::StringPrintf("Invalid ID 0x%08x.", resid);
- return kInvalidCookie;
+ return base::unexpected(std::nullopt);
}
const uint32_t package_id = get_package_id(resid);
const uint8_t type_idx = get_type_id(resid) - 1;
const uint16_t entry_idx = get_entry_id(resid);
uint8_t package_idx = package_ids_[package_id];
- if (package_idx == 0xff) {
+ if (UNLIKELY(package_idx == 0xff)) {
ANDROID_LOG(ERROR) << base::StringPrintf("No package ID %02x found for ID 0x%08x.",
package_id, resid);
- return kInvalidCookie;
+ return base::unexpected(std::nullopt);
}
const PackageGroup& package_group = package_groups_[package_idx];
- ApkAssetsCookie cookie = FindEntryInternal(package_group, type_idx, entry_idx, *desired_config,
- false /* stop_at_first_match */,
- ignore_configuration, out_entry);
- if (UNLIKELY(cookie == kInvalidCookie)) {
- return kInvalidCookie;
+ auto result = FindEntryInternal(package_group, type_idx, entry_idx, *desired_config,
+ stop_at_first_match, ignore_configuration);
+ if (UNLIKELY(!result.has_value())) {
+ return base::unexpected(result.error());
}
- if (!apk_assets_[cookie]->IsLoader()) {
+ if (!stop_at_first_match && !ignore_configuration && !apk_assets_[result->cookie]->IsLoader()) {
for (const auto& id_map : package_group.overlays_) {
auto overlay_entry = id_map.overlay_res_maps_.Lookup(resid);
if (!overlay_entry) {
// No id map entry exists for this target resource.
continue;
- } else if (overlay_entry.IsInlineValue()) {
+ }
+ if (overlay_entry.IsInlineValue()) {
// The target resource is overlaid by an inline value not represented by a resource.
- out_entry->entry = overlay_entry.GetInlineValue();
- out_entry->dynamic_ref_table = id_map.overlay_res_maps_.GetOverlayDynamicRefTable();
- cookie = id_map.cookie;
+ result->entry = overlay_entry.GetInlineValue();
+ result->dynamic_ref_table = id_map.overlay_res_maps_.GetOverlayDynamicRefTable();
+ result->cookie = id_map.cookie;
continue;
}
- FindEntryResult overlay_result;
- ApkAssetsCookie overlay_cookie = FindEntry(overlay_entry.GetResourceId(), density_override,
- false /* stop_at_first_match */,
- ignore_configuration, &overlay_result);
- if (UNLIKELY(overlay_cookie == kInvalidCookie)) {
+ auto overlay_result = FindEntry(overlay_entry.GetResourceId(), density_override,
+ false /* stop_at_first_match */,
+ false /* ignore_configuration */);
+ if (UNLIKELY(IsIOError(overlay_result))) {
+ return base::unexpected(overlay_result.error());
+ }
+ if (!overlay_result.has_value()) {
continue;
}
- if (!overlay_result.config.isBetterThan(out_entry->config, desired_config)
- && overlay_result.config.compare(out_entry->config) != 0) {
+ if (!overlay_result->config.isBetterThan(result->config, desired_config)
+ && overlay_result->config.compare(result->config) != 0) {
// The configuration of the entry for the overlay must be equal to or better than the target
// configuration to be chosen as the better value.
continue;
}
- cookie = overlay_cookie;
- out_entry->entry = overlay_result.entry;
- out_entry->config = overlay_result.config;
- out_entry->dynamic_ref_table = id_map.overlay_res_maps_.GetOverlayDynamicRefTable();
- if (resource_resolution_logging_enabled_) {
+ result->cookie = overlay_result->cookie;
+ result->entry = overlay_result->entry;
+ result->config = overlay_result->config;
+ result->dynamic_ref_table = id_map.overlay_res_maps_.GetOverlayDynamicRefTable();
+
+ if (UNLIKELY(logging_enabled)) {
last_resolution_.steps.push_back(
- Resolution::Step{Resolution::Step::Type::OVERLAID, overlay_result.config.toString(),
- overlay_result.package_name});
+ Resolution::Step{Resolution::Step::Type::OVERLAID, overlay_result->config.toString(),
+ overlay_result->package_name});
}
}
}
- if (resource_resolution_logging_enabled_) {
- last_resolution_.cookie = cookie;
- last_resolution_.type_string_ref = out_entry->type_string_ref;
- last_resolution_.entry_string_ref = out_entry->entry_string_ref;
+ if (UNLIKELY(logging_enabled)) {
+ last_resolution_.cookie = result->cookie;
+ last_resolution_.type_string_ref = result->type_string_ref;
+ last_resolution_.entry_string_ref = result->entry_string_ref;
}
- return cookie;
+ return result;
}
-ApkAssetsCookie AssetManager2::FindEntryInternal(const PackageGroup& package_group,
- uint8_t type_idx, uint16_t entry_idx,
- const ResTable_config& desired_config,
- bool /*stop_at_first_match*/,
- bool ignore_configuration,
- FindEntryResult* out_entry) const {
+base::expected<FindEntryResult, NullOrIOError> AssetManager2::FindEntryInternal(
+ const PackageGroup& package_group, uint8_t type_idx, uint16_t entry_idx,
+ const ResTable_config& desired_config, bool stop_at_first_match,
+ bool ignore_configuration) const {
+ const bool logging_enabled = resource_resolution_logging_enabled_;
ApkAssetsCookie best_cookie = kInvalidCookie;
const LoadedPackage* best_package = nullptr;
- const ResTable_type* best_type = nullptr;
+ incfs::verified_map_ptr<ResTable_type> best_type;
const ResTable_config* best_config = nullptr;
ResTable_config best_config_copy;
- uint32_t best_offset = 0u;
- uint32_t type_flags = 0u;
+ uint32_t best_offset = 0U;
+ uint32_t type_flags = 0U;
- Resolution::Step::Type resolution_type = Resolution::Step::Type::NO_ENTRY;
+ auto resolution_type = Resolution::Step::Type::NO_ENTRY;
std::vector<Resolution::Step> resolution_steps;
// If desired_config is the same as the set configuration, then we can use our filtered list
@@ -630,17 +669,20 @@
continue;
}
+ auto entry_flags = type_spec->GetFlagsForEntryIndex(entry_idx);
+ if (UNLIKELY(!entry_flags)) {
+ return base::unexpected(entry_flags.error());
+ }
+ type_flags |= entry_flags.value();
+
// If the package is an overlay or custom loader,
// then even configurations that are the same MUST be chosen.
const bool package_is_loader = loaded_package->IsCustomLoader();
- type_flags |= type_spec->GetFlagsForEntryIndex(entry_idx);
if (use_fast_path) {
const FilteredConfigGroup& filtered_group = loaded_package_impl.filtered_configs_[type_idx];
- const std::vector<ResTable_config>& candidate_configs = filtered_group.configurations;
- const size_t type_count = candidate_configs.size();
- for (uint32_t i = 0; i < type_count; i++) {
- const ResTable_config& this_config = candidate_configs[i];
+ for (const auto& type_config : filtered_group.type_configs) {
+ const ResTable_config& this_config = type_config.config;
// We can skip calling ResTable_config::match() because we know that all candidate
// configurations that do NOT match have been filtered-out.
@@ -652,7 +694,7 @@
} else if (package_is_loader && this_config.compare(*best_config) == 0) {
resolution_type = Resolution::Step::Type::OVERLAID_LOADER;
} else {
- if (resource_resolution_logging_enabled_) {
+ if (UNLIKELY(logging_enabled)) {
resolution_type = (package_is_loader) ? Resolution::Step::Type::SKIPPED_LOADER
: Resolution::Step::Type::SKIPPED;
resolution_steps.push_back(Resolution::Step{resolution_type,
@@ -664,10 +706,13 @@
// The configuration matches and is better than the previous selection.
// Find the entry value if it exists for this configuration.
- const ResTable_type* type = filtered_group.types[i];
- const uint32_t offset = LoadedPackage::GetEntryOffset(type, entry_idx);
- if (offset == ResTable_type::NO_ENTRY) {
- if (resource_resolution_logging_enabled_) {
+ const auto& type = type_config.type;
+ const auto offset = LoadedPackage::GetEntryOffset(type, entry_idx);
+ if (UNLIKELY(IsIOError(offset))) {
+ return base::unexpected(offset.error());
+ }
+ if (!offset.has_value()) {
+ if (UNLIKELY(logging_enabled)) {
if (package_is_loader) {
resolution_type = Resolution::Step::Type::NO_ENTRY_LOADER;
} else {
@@ -684,9 +729,9 @@
best_package = loaded_package;
best_type = type;
best_config = &this_config;
- best_offset = offset;
+ best_offset = offset.value();
- if (resource_resolution_logging_enabled_) {
+ if (UNLIKELY(logging_enabled)) {
last_resolution_.steps.push_back(Resolution::Step{resolution_type,
this_config.toString(),
&loaded_package->GetPackageName()});
@@ -700,10 +745,11 @@
// ResTable_config, we must copy it.
const auto iter_end = type_spec->types + type_spec->type_count;
for (auto iter = type_spec->types; iter != iter_end; ++iter) {
- ResTable_config this_config{};
+ const incfs::verified_map_ptr<ResTable_type>& type = *iter;
+ ResTable_config this_config{};
if (!ignore_configuration) {
- this_config.copyFromDtoH((*iter)->config);
+ this_config.copyFromDtoH(type->config);
if (!this_config.match(desired_config)) {
continue;
}
@@ -722,24 +768,27 @@
// The configuration matches and is better than the previous selection.
// Find the entry value if it exists for this configuration.
- const uint32_t offset = LoadedPackage::GetEntryOffset(*iter, entry_idx);
- if (offset == ResTable_type::NO_ENTRY) {
+ const auto offset = LoadedPackage::GetEntryOffset(type, entry_idx);
+ if (UNLIKELY(IsIOError(offset))) {
+ return base::unexpected(offset.error());
+ }
+ if (!offset.has_value()) {
continue;
}
best_cookie = cookie;
best_package = loaded_package;
- best_type = *iter;
+ best_type = type;
best_config_copy = this_config;
best_config = &best_config_copy;
- best_offset = offset;
+ best_offset = offset.value();
- if (ignore_configuration) {
+ if (stop_at_first_match) {
// Any configuration will suffice, so break.
break;
}
- if (resource_resolution_logging_enabled_) {
+ if (UNLIKELY(logging_enabled)) {
last_resolution_.steps.push_back(Resolution::Step{resolution_type,
this_config.toString(),
&loaded_package->GetPackageName()});
@@ -749,36 +798,35 @@
}
if (UNLIKELY(best_cookie == kInvalidCookie)) {
- return kInvalidCookie;
+ return base::unexpected(std::nullopt);
}
- const ResTable_entry* best_entry = LoadedPackage::GetEntryFromOffset(best_type, best_offset);
- if (UNLIKELY(best_entry == nullptr)) {
- return kInvalidCookie;
+ auto best_entry_result = LoadedPackage::GetEntryFromOffset(best_type, best_offset);
+ if (!best_entry_result.has_value()) {
+ return base::unexpected(best_entry_result.error());
}
- const uint16_t entry_size = dtohs(best_entry->size);
- if (entry_size >= sizeof(ResTable_map_entry) &&
- (dtohs(best_entry->flags) & ResTable_entry::FLAG_COMPLEX)) {
- // The entry represents a bag/map.
- out_entry->entry = reinterpret_cast<const ResTable_map_entry*>(best_entry);
- } else {
- // The entry represents a value.
- Res_value value;
- value.copyFrom_dtoh(*reinterpret_cast<const Res_value*>(
- reinterpret_cast<const uint8_t*>(best_entry) + entry_size));
- out_entry->entry = value;
+ const incfs::map_ptr<ResTable_entry> best_entry = *best_entry_result;
+ if (!best_entry) {
+ return base::unexpected(IOError::PAGES_MISSING);
}
- out_entry->config = *best_config;
- out_entry->type_flags = type_flags;
- out_entry->package_name = &best_package->GetPackageName();
- out_entry->type_string_ref = StringPoolRef(best_package->GetTypeStringPool(), best_type->id - 1);
- out_entry->entry_string_ref =
- StringPoolRef(best_package->GetKeyStringPool(), best_entry->key.index);
- out_entry->dynamic_ref_table = package_group.dynamic_ref_table.get();
+ const auto entry = GetEntryValue(best_entry.verified());
+ if (!entry.has_value()) {
+ return base::unexpected(entry.error());
+ }
- return best_cookie;
+ return FindEntryResult{
+ .cookie = best_cookie,
+ .entry = *entry,
+ .config = *best_config,
+ .type_flags = type_flags,
+ .package_name = &best_package->GetPackageName(),
+ .type_string_ref = StringPoolRef(best_package->GetTypeStringPool(), best_type->id - 1),
+ .entry_string_ref = StringPoolRef(best_package->GetKeyStringPool(),
+ best_entry->key.index),
+ .dynamic_ref_table = package_group.dynamic_ref_table.get(),
+ };
}
void AssetManager2::ResetResourceResolution() const {
@@ -799,30 +847,28 @@
std::string AssetManager2::GetLastResourceResolution() const {
if (!resource_resolution_logging_enabled_) {
LOG(ERROR) << "Must enable resource resolution logging before getting path.";
- return std::string();
+ return {};
}
auto cookie = last_resolution_.cookie;
if (cookie == kInvalidCookie) {
LOG(ERROR) << "AssetManager hasn't resolved a resource to read resolution path.";
- return std::string();
+ return {};
}
uint32_t resid = last_resolution_.resid;
std::vector<Resolution::Step>& steps = last_resolution_.steps;
-
- ResourceName resource_name;
std::string resource_name_string;
const LoadedPackage* package =
apk_assets_[cookie]->GetLoadedArsc()->GetPackageById(get_package_id(resid));
if (package != nullptr) {
- ToResourceName(last_resolution_.type_string_ref,
- last_resolution_.entry_string_ref,
- package->GetPackageName(),
- &resource_name);
- resource_name_string = ToFormattedResourceString(&resource_name);
+ auto resource_name = ToResourceName(last_resolution_.type_string_ref,
+ last_resolution_.entry_string_ref,
+ package->GetPackageName());
+ resource_name_string = resource_name.has_value() ?
+ ToFormattedResourceString(resource_name.value()) : "<unknown>";
}
std::stringstream log_stream;
@@ -875,200 +921,201 @@
return log_stream.str();
}
-bool AssetManager2::GetResourceName(uint32_t resid, ResourceName* out_name) const {
- FindEntryResult entry;
- ApkAssetsCookie cookie = FindEntry(resid, 0u /* density_override */,
- true /* stop_at_first_match */,
- true /* ignore_configuration */, &entry);
- if (cookie == kInvalidCookie) {
- return false;
+base::expected<AssetManager2::ResourceName, NullOrIOError> AssetManager2::GetResourceName(
+ uint32_t resid) const {
+ auto result = FindEntry(resid, 0u /* density_override */, true /* stop_at_first_match */,
+ true /* ignore_configuration */);
+ if (!result.has_value()) {
+ return base::unexpected(result.error());
}
- return ToResourceName(entry.type_string_ref,
- entry.entry_string_ref,
- *entry.package_name,
- out_name);
+ return ToResourceName(result->type_string_ref,
+ result->entry_string_ref,
+ *result->package_name);
}
-bool AssetManager2::GetResourceFlags(uint32_t resid, uint32_t* out_flags) const {
- FindEntryResult entry;
- ApkAssetsCookie cookie = FindEntry(resid, 0u /* density_override */,
- false /* stop_at_first_match */,
- true /* ignore_configuration */, &entry);
- if (cookie != kInvalidCookie) {
- *out_flags = entry.type_flags;
- return true;
- }
- return false;
-}
-
-ApkAssetsCookie AssetManager2::GetResource(uint32_t resid, bool may_be_bag,
- uint16_t density_override, Res_value* out_value,
- ResTable_config* out_selected_config,
- uint32_t* out_flags) const {
- FindEntryResult entry;
- ApkAssetsCookie cookie = FindEntry(resid, density_override, false /* stop_at_first_match */,
- false /* ignore_configuration */, &entry);
- if (cookie == kInvalidCookie) {
- return kInvalidCookie;
+base::expected<AssetManager2::SelectedValue, NullOrIOError> AssetManager2::GetResource(
+ uint32_t resid, bool may_be_bag, uint16_t density_override) const {
+ auto result = FindEntry(resid, density_override, false /* stop_at_first_match */,
+ false /* ignore_configuration */);
+ if (!result.has_value()) {
+ return base::unexpected(result.error());
}
- auto result_map_entry = std::get_if<const ResTable_map_entry*>(&entry.entry);
+ auto result_map_entry = std::get_if<incfs::verified_map_ptr<ResTable_map_entry>>(&result->entry);
if (result_map_entry != nullptr) {
if (!may_be_bag) {
LOG(ERROR) << base::StringPrintf("Resource %08x is a complex map type.", resid);
- return kInvalidCookie;
+ return base::unexpected(std::nullopt);
}
// Create a reference since we can't represent this complex type as a Res_value.
- out_value->dataType = Res_value::TYPE_REFERENCE;
- out_value->data = resid;
- *out_selected_config = entry.config;
- *out_flags = entry.type_flags;
- return cookie;
+ return SelectedValue(Res_value::TYPE_REFERENCE, resid, result->cookie, result->type_flags,
+ resid, result->config);
}
// Convert the package ID to the runtime assigned package ID.
- *out_value = std::get<Res_value>(entry.entry);
- entry.dynamic_ref_table->lookupResourceValue(out_value);
+ Res_value value = std::get<Res_value>(result->entry);
+ result->dynamic_ref_table->lookupResourceValue(&value);
- *out_selected_config = entry.config;
- *out_flags = entry.type_flags;
- return cookie;
+ return SelectedValue(value.dataType, value.data, result->cookie, result->type_flags,
+ resid, result->config);
}
-ApkAssetsCookie AssetManager2::ResolveReference(ApkAssetsCookie cookie, Res_value* in_out_value,
- ResTable_config* in_out_selected_config,
- uint32_t* in_out_flags,
- uint32_t* out_last_reference) const {
- constexpr const int kMaxIterations = 20;
+base::expected<std::monostate, NullOrIOError> AssetManager2::ResolveReference(
+ AssetManager2::SelectedValue& value, bool cache_value) const {
+ if (value.type != Res_value::TYPE_REFERENCE || value.data == 0U) {
+ // Not a reference. Nothing to do.
+ return {};
+ }
- for (size_t iteration = 0u; in_out_value->dataType == Res_value::TYPE_REFERENCE &&
- in_out_value->data != 0u && iteration < kMaxIterations;
- iteration++) {
- *out_last_reference = in_out_value->data;
- uint32_t new_flags = 0u;
- cookie = GetResource(in_out_value->data, true /*may_be_bag*/, 0u /*density_override*/,
- in_out_value, in_out_selected_config, &new_flags);
- if (cookie == kInvalidCookie) {
- return kInvalidCookie;
- }
- if (in_out_flags != nullptr) {
- *in_out_flags |= new_flags;
- }
- if (*out_last_reference == in_out_value->data) {
- // This reference can't be resolved, so exit now and let the caller deal with it.
- return cookie;
+ const uint32_t original_flags = value.flags;
+ const uint32_t original_resid = value.data;
+ if (cache_value) {
+ auto cached_value = cached_resolved_values_.find(value.data);
+ if (cached_value != cached_resolved_values_.end()) {
+ value = cached_value->second;
+ value.flags |= original_flags;
+ return {};
}
}
- return cookie;
+
+ uint32_t combined_flags = 0U;
+ uint32_t resolve_resid = original_resid;
+ constexpr const uint32_t kMaxIterations = 20;
+ for (uint32_t i = 0U;; i++) {
+ auto result = GetResource(resolve_resid, true /*may_be_bag*/);
+ if (!result.has_value()) {
+ return base::unexpected(result.error());
+ }
+
+ if (result->type != Res_value::TYPE_REFERENCE ||
+ result->data == Res_value::DATA_NULL_UNDEFINED ||
+ result->data == resolve_resid || i == kMaxIterations) {
+ result->flags |= combined_flags;
+ if (cache_value) {
+ cached_resolved_values_[original_resid] = *result;
+ }
+
+ // Add the original flags after caching the result so queries with a different set of original
+ // flags do not include these original flags.
+ value = *result;
+ value.flags |= original_flags;
+ return {};
+ }
+
+ combined_flags |= result->flags;
+ resolve_resid = result->data;
+ }
}
-const std::vector<uint32_t> AssetManager2::GetBagResIdStack(uint32_t resid) {
+const std::vector<uint32_t> AssetManager2::GetBagResIdStack(uint32_t resid) const {
auto cached_iter = cached_bag_resid_stacks_.find(resid);
if (cached_iter != cached_bag_resid_stacks_.end()) {
return cached_iter->second;
- } else {
- auto found_resids = std::vector<uint32_t>();
- GetBag(resid, found_resids);
- // Cache style stacks if they are not already cached.
- cached_bag_resid_stacks_[resid] = found_resids;
- return found_resids;
}
+
+ std::vector<uint32_t> found_resids;
+ GetBag(resid, found_resids);
+ cached_bag_resid_stacks_.emplace(resid, found_resids);
+ return found_resids;
}
-const ResolvedBag* AssetManager2::GetBag(uint32_t resid) {
- auto found_resids = std::vector<uint32_t>();
- auto bag = GetBag(resid, found_resids);
+base::expected<const ResolvedBag*, NullOrIOError> AssetManager2::ResolveBag(
+ AssetManager2::SelectedValue& value) const {
+ if (UNLIKELY(value.type != Res_value::TYPE_REFERENCE)) {
+ return base::unexpected(std::nullopt);
+ }
- // Cache style stacks if they are not already cached.
- auto cached_iter = cached_bag_resid_stacks_.find(resid);
- if (cached_iter == cached_bag_resid_stacks_.end()) {
- cached_bag_resid_stacks_[resid] = found_resids;
+ auto bag = GetBag(value.data);
+ if (bag.has_value()) {
+ value.flags |= (*bag)->type_spec_flags;
}
return bag;
}
-static bool compare_bag_entries(const ResolvedBag::Entry& entry1,
- const ResolvedBag::Entry& entry2) {
- return entry1.key < entry2.key;
+base::expected<const ResolvedBag*, NullOrIOError> AssetManager2::GetBag(uint32_t resid) const {
+ std::vector<uint32_t> found_resids;
+ return GetBag(resid, found_resids);
}
-const ResolvedBag* AssetManager2::GetBag(uint32_t resid, std::vector<uint32_t>& child_resids) {
- auto cached_iter = cached_bags_.find(resid);
- if (cached_iter != cached_bags_.end()) {
+base::expected<const ResolvedBag*, NullOrIOError> AssetManager2::GetBag(
+ uint32_t resid, std::vector<uint32_t>& child_resids) const {
+ if (auto cached_iter = cached_bags_.find(resid); cached_iter != cached_bags_.end()) {
return cached_iter->second.get();
}
- FindEntryResult entry;
- ApkAssetsCookie cookie = FindEntry(resid, 0u /* density_override */,
- false /* stop_at_first_match */,
- false /* ignore_configuration */,
- &entry);
- if (cookie == kInvalidCookie) {
- return nullptr;
+ auto entry = FindEntry(resid, 0u /* density_override */, false /* stop_at_first_match */,
+ false /* ignore_configuration */);
+ if (!entry.has_value()) {
+ return base::unexpected(entry.error());
}
- auto result_map_entry = std::get_if<const ResTable_map_entry*>(&entry.entry);
- if (result_map_entry == nullptr) {
+ auto entry_map = std::get_if<incfs::verified_map_ptr<ResTable_map_entry>>(&entry->entry);
+ if (entry_map == nullptr) {
// Not a bag, nothing to do.
- return nullptr;
+ return base::unexpected(std::nullopt);
}
- auto map = reinterpret_cast<const ResTable_map_entry*>(*result_map_entry);
- auto map_entry = reinterpret_cast<const ResTable_map*>(
- reinterpret_cast<const uint8_t*>(map) + map->size);
- const ResTable_map* const map_entry_end = map_entry + dtohl(map->count);
+ auto map = *entry_map;
+ auto map_entry = map.offset(dtohs(map->size)).convert<ResTable_map>();
+ const auto map_entry_end = map_entry + dtohl(map->count);
// Keep track of ids that have already been seen to prevent infinite loops caused by circular
- // dependencies between bags
+ // dependencies between bags.
child_resids.push_back(resid);
uint32_t parent_resid = dtohl(map->parent.ident);
- if (parent_resid == 0U || std::find(child_resids.begin(), child_resids.end(), parent_resid)
- != child_resids.end()) {
- // There is no parent or a circular dependency exist, meaning there is nothing to inherit and
- // we can do a simple copy of the entries in the map.
+ if (parent_resid == 0U ||
+ std::find(child_resids.begin(), child_resids.end(), parent_resid) != child_resids.end()) {
+ // There is no parent or a circular parental dependency exist, meaning there is nothing to
+ // inherit and we can do a simple copy of the entries in the map.
const size_t entry_count = map_entry_end - map_entry;
util::unique_cptr<ResolvedBag> new_bag{reinterpret_cast<ResolvedBag*>(
malloc(sizeof(ResolvedBag) + (entry_count * sizeof(ResolvedBag::Entry))))};
bool sort_entries = false;
- ResolvedBag::Entry* new_entry = new_bag->entries;
- for (; map_entry != map_entry_end; ++map_entry) {
+ for (auto new_entry = new_bag->entries; map_entry != map_entry_end; ++map_entry) {
+ if (UNLIKELY(!map_entry)) {
+ return base::unexpected(IOError::PAGES_MISSING);
+ }
+
uint32_t new_key = dtohl(map_entry->name.ident);
if (!is_internal_resid(new_key)) {
// Attributes, arrays, etc don't have a resource id as the name. They specify
// other data, which would be wrong to change via a lookup.
- if (entry.dynamic_ref_table->lookupResourceId(&new_key) != NO_ERROR) {
+ if (UNLIKELY(entry->dynamic_ref_table->lookupResourceId(&new_key) != NO_ERROR)) {
LOG(ERROR) << base::StringPrintf("Failed to resolve key 0x%08x in bag 0x%08x.", new_key,
resid);
- return nullptr;
+ return base::unexpected(std::nullopt);
}
}
- new_entry->cookie = cookie;
+
+ new_entry->cookie = entry->cookie;
new_entry->key = new_key;
new_entry->key_pool = nullptr;
new_entry->type_pool = nullptr;
new_entry->style = resid;
new_entry->value.copyFrom_dtoh(map_entry->value);
- status_t err = entry.dynamic_ref_table->lookupResourceValue(&new_entry->value);
- if (err != NO_ERROR) {
+ status_t err = entry->dynamic_ref_table->lookupResourceValue(&new_entry->value);
+ if (UNLIKELY(err != NO_ERROR)) {
LOG(ERROR) << base::StringPrintf(
"Failed to resolve value t=0x%02x d=0x%08x for key 0x%08x.", new_entry->value.dataType,
new_entry->value.data, new_key);
- return nullptr;
+ return base::unexpected(std::nullopt);
}
+
sort_entries = sort_entries ||
(new_entry != new_bag->entries && (new_entry->key < (new_entry - 1U)->key));
++new_entry;
}
if (sort_entries) {
- std::sort(new_bag->entries, new_bag->entries + entry_count, compare_bag_entries);
+ std::sort(new_bag->entries, new_bag->entries + entry_count,
+ [](auto&& lhs, auto&& rhs) { return lhs.key < rhs.key; });
}
- new_bag->type_spec_flags = entry.type_flags;
+ new_bag->type_spec_flags = entry->type_flags;
new_bag->entry_count = static_cast<uint32_t>(entry_count);
ResolvedBag* result = new_bag.get();
cached_bags_[resid] = std::move(new_bag);
@@ -1076,54 +1123,58 @@
}
// In case the parent is a dynamic reference, resolve it.
- entry.dynamic_ref_table->lookupResourceId(&parent_resid);
+ entry->dynamic_ref_table->lookupResourceId(&parent_resid);
// Get the parent and do a merge of the keys.
- const ResolvedBag* parent_bag = GetBag(parent_resid, child_resids);
- if (parent_bag == nullptr) {
+ const auto parent_bag = GetBag(parent_resid, child_resids);
+ if (UNLIKELY(!parent_bag.has_value())) {
// Failed to get the parent that should exist.
LOG(ERROR) << base::StringPrintf("Failed to find parent 0x%08x of bag 0x%08x.", parent_resid,
resid);
- return nullptr;
+ return base::unexpected(parent_bag.error());
}
// Create the max possible entries we can make. Once we construct the bag,
// we will realloc to fit to size.
- const size_t max_count = parent_bag->entry_count + dtohl(map->count);
+ const size_t max_count = (*parent_bag)->entry_count + dtohl(map->count);
util::unique_cptr<ResolvedBag> new_bag{reinterpret_cast<ResolvedBag*>(
malloc(sizeof(ResolvedBag) + (max_count * sizeof(ResolvedBag::Entry))))};
ResolvedBag::Entry* new_entry = new_bag->entries;
- const ResolvedBag::Entry* parent_entry = parent_bag->entries;
- const ResolvedBag::Entry* const parent_entry_end = parent_entry + parent_bag->entry_count;
+ const ResolvedBag::Entry* parent_entry = (*parent_bag)->entries;
+ const ResolvedBag::Entry* const parent_entry_end = parent_entry + (*parent_bag)->entry_count;
// The keys are expected to be in sorted order. Merge the two bags.
bool sort_entries = false;
while (map_entry != map_entry_end && parent_entry != parent_entry_end) {
+ if (UNLIKELY(!map_entry)) {
+ return base::unexpected(IOError::PAGES_MISSING);
+ }
+
uint32_t child_key = dtohl(map_entry->name.ident);
if (!is_internal_resid(child_key)) {
- if (entry.dynamic_ref_table->lookupResourceId(&child_key) != NO_ERROR) {
+ if (UNLIKELY(entry->dynamic_ref_table->lookupResourceId(&child_key) != NO_ERROR)) {
LOG(ERROR) << base::StringPrintf("Failed to resolve key 0x%08x in bag 0x%08x.", child_key,
resid);
- return nullptr;
+ return base::unexpected(std::nullopt);
}
}
if (child_key <= parent_entry->key) {
// Use the child key if it comes before the parent
// or is equal to the parent (overrides).
- new_entry->cookie = cookie;
+ new_entry->cookie = entry->cookie;
new_entry->key = child_key;
new_entry->key_pool = nullptr;
new_entry->type_pool = nullptr;
new_entry->value.copyFrom_dtoh(map_entry->value);
new_entry->style = resid;
- status_t err = entry.dynamic_ref_table->lookupResourceValue(&new_entry->value);
- if (err != NO_ERROR) {
+ status_t err = entry->dynamic_ref_table->lookupResourceValue(&new_entry->value);
+ if (UNLIKELY(err != NO_ERROR)) {
LOG(ERROR) << base::StringPrintf(
"Failed to resolve value t=0x%02x d=0x%08x for key 0x%08x.", new_entry->value.dataType,
new_entry->value.data, child_key);
- return nullptr;
+ return base::unexpected(std::nullopt);
}
++map_entry;
} else {
@@ -1143,25 +1194,29 @@
// Finish the child entries if they exist.
while (map_entry != map_entry_end) {
+ if (UNLIKELY(!map_entry)) {
+ return base::unexpected(IOError::PAGES_MISSING);
+ }
+
uint32_t new_key = dtohl(map_entry->name.ident);
if (!is_internal_resid(new_key)) {
- if (entry.dynamic_ref_table->lookupResourceId(&new_key) != NO_ERROR) {
+ if (UNLIKELY(entry->dynamic_ref_table->lookupResourceId(&new_key) != NO_ERROR)) {
LOG(ERROR) << base::StringPrintf("Failed to resolve key 0x%08x in bag 0x%08x.", new_key,
resid);
- return nullptr;
+ return base::unexpected(std::nullopt);
}
}
- new_entry->cookie = cookie;
+ new_entry->cookie = entry->cookie;
new_entry->key = new_key;
new_entry->key_pool = nullptr;
new_entry->type_pool = nullptr;
new_entry->value.copyFrom_dtoh(map_entry->value);
new_entry->style = resid;
- status_t err = entry.dynamic_ref_table->lookupResourceValue(&new_entry->value);
- if (err != NO_ERROR) {
+ status_t err = entry->dynamic_ref_table->lookupResourceValue(&new_entry->value);
+ if (UNLIKELY(err != NO_ERROR)) {
LOG(ERROR) << base::StringPrintf("Failed to resolve value t=0x%02x d=0x%08x for key 0x%08x.",
new_entry->value.dataType, new_entry->value.data, new_key);
- return nullptr;
+ return base::unexpected(std::nullopt);
}
sort_entries = sort_entries ||
(new_entry != new_bag->entries && (new_entry->key < (new_entry - 1U)->key));
@@ -1185,11 +1240,12 @@
}
if (sort_entries) {
- std::sort(new_bag->entries, new_bag->entries + actual_count, compare_bag_entries);
+ std::sort(new_bag->entries, new_bag->entries + actual_count,
+ [](auto&& lhs, auto&& rhs) { return lhs.key < rhs.key; });
}
// Combine flags from the parent and our own bag.
- new_bag->type_spec_flags = entry.type_flags | parent_bag->type_spec_flags;
+ new_bag->type_spec_flags = entry->type_flags | (*parent_bag)->type_spec_flags;
new_bag->entry_count = static_cast<uint32_t>(actual_count);
ResolvedBag* result = new_bag.get();
cached_bags_[resid] = std::move(new_bag);
@@ -1208,16 +1264,16 @@
return true;
}
-uint32_t AssetManager2::GetResourceId(const std::string& resource_name,
- const std::string& fallback_type,
- const std::string& fallback_package) const {
+base::expected<uint32_t, NullOrIOError> AssetManager2::GetResourceId(
+ const std::string& resource_name, const std::string& fallback_type,
+ const std::string& fallback_package) const {
StringPiece package_name, type, entry;
if (!ExtractResourceName(resource_name, &package_name, &type, &entry)) {
- return 0u;
+ return base::unexpected(std::nullopt);
}
if (entry.empty()) {
- return 0u;
+ return base::unexpected(std::nullopt);
}
if (package_name.empty()) {
@@ -1230,12 +1286,12 @@
std::u16string type16;
if (!Utf8ToUtf16(type, &type16)) {
- return 0u;
+ return base::unexpected(std::nullopt);
}
std::u16string entry16;
if (!Utf8ToUtf16(entry, &entry16)) {
- return 0u;
+ return base::unexpected(std::nullopt);
}
const StringPiece16 kAttr16 = u"attr";
@@ -1249,20 +1305,24 @@
break;
}
- uint32_t resid = package->FindEntryByName(type16, entry16);
- if (resid == 0u && kAttr16 == type16) {
+ base::expected<uint32_t, NullOrIOError> resid = package->FindEntryByName(type16, entry16);
+ if (UNLIKELY(IsIOError(resid))) {
+ return base::unexpected(resid.error());
+ }
+
+ if (!resid.has_value() && kAttr16 == type16) {
// Private attributes in libraries (such as the framework) are sometimes encoded
// under the type '^attr-private' in order to leave the ID space of public 'attr'
// free for future additions. Check '^attr-private' for the same name.
resid = package->FindEntryByName(kAttrPrivate16, entry16);
}
- if (resid != 0u) {
- return fix_package_id(resid, package_group.dynamic_ref_table->mAssignedPackageId);
+ if (resid.has_value()) {
+ return fix_package_id(*resid, package_group.dynamic_ref_table->mAssignedPackageId);
}
}
}
- return 0u;
+ return base::unexpected(std::nullopt);
}
void AssetManager2::RebuildFilterList(bool filter_incompatible_configs) {
@@ -1282,8 +1342,7 @@
ResTable_config this_config;
this_config.copyFromDtoH((*iter)->config);
if (!filter_incompatible_configs || this_config.match(configuration_)) {
- group.configurations.push_back(this_config);
- group.types.push_back(*iter);
+ group.type_configs.push_back(TypeConfig{*iter, this_config});
}
}
});
@@ -1309,6 +1368,8 @@
++iter;
}
}
+
+ cached_resolved_values_.clear();
}
uint8_t AssetManager2::GetAssignedPackageId(const LoadedPackage* package) const {
@@ -1354,16 +1415,16 @@
std::array<util::unique_cptr<ThemeType>, kTypeCount> types;
};
-bool Theme::ApplyStyle(uint32_t resid, bool force) {
+base::expected<std::monostate, NullOrIOError> Theme::ApplyStyle(uint32_t resid, bool force) {
ATRACE_NAME("Theme::ApplyStyle");
- const ResolvedBag* bag = asset_manager_->GetBag(resid);
- if (bag == nullptr) {
- return false;
+ auto bag = asset_manager_->GetBag(resid);
+ if (!bag.has_value()) {
+ return base::unexpected(bag.error());
}
// Merge the flags from this style.
- type_spec_flags_ |= bag->type_spec_flags;
+ type_spec_flags_ |= (*bag)->type_spec_flags;
int last_type_idx = -1;
int last_package_idx = -1;
@@ -1373,14 +1434,14 @@
// Iterate backwards, because each bag is sorted in ascending key ID order, meaning we will only
// need to perform one resize per type.
using reverse_bag_iterator = std::reverse_iterator<const ResolvedBag::Entry*>;
- const auto bag_iter_end = reverse_bag_iterator(begin(bag));
- for (auto bag_iter = reverse_bag_iterator(end(bag)); bag_iter != bag_iter_end; ++bag_iter) {
- const uint32_t attr_resid = bag_iter->key;
+ const auto rbegin = reverse_bag_iterator(begin(*bag));
+ for (auto it = reverse_bag_iterator(end(*bag)); it != rbegin; ++it) {
+ const uint32_t attr_resid = it->key;
// If the resource ID passed in is not a style, the key can be some other identifier that is not
// a resource ID. We should fail fast instead of operating with strange resource IDs.
if (!is_valid_resid(attr_resid)) {
- return false;
+ return base::unexpected(std::nullopt);
}
// We don't use the 0-based index for the type so that we can avoid doing ID validation
@@ -1428,20 +1489,18 @@
ThemeEntry& entry = last_type->entries[entry_idx];
if (force || (entry.value.dataType == Res_value::TYPE_NULL &&
entry.value.data != Res_value::DATA_NULL_EMPTY)) {
- entry.cookie = bag_iter->cookie;
- entry.type_spec_flags |= bag->type_spec_flags;
- entry.value = bag_iter->value;
+ entry.cookie = it->cookie;
+ entry.type_spec_flags |= (*bag)->type_spec_flags;
+ entry.value = it->value;
}
}
- return true;
+ return {};
}
-ApkAssetsCookie Theme::GetAttribute(uint32_t resid, Res_value* out_value,
- uint32_t* out_flags) const {
+std::optional<AssetManager2::SelectedValue> Theme::GetAttribute(uint32_t resid) const {
+
int cnt = 20;
-
uint32_t type_spec_flags = 0u;
-
do {
const int package_idx = get_package_id(resid);
const Package* package = packages_[package_idx].get();
@@ -1461,43 +1520,42 @@
resid = entry.value.data;
continue;
}
- return kInvalidCookie;
+ return std::nullopt;
}
// @null is different than @empty.
if (entry.value.dataType == Res_value::TYPE_NULL &&
entry.value.data != Res_value::DATA_NULL_EMPTY) {
- return kInvalidCookie;
+ return std::nullopt;
}
- *out_value = entry.value;
- *out_flags = type_spec_flags;
- return entry.cookie;
+ return AssetManager2::SelectedValue(entry.value.dataType, entry.value.data, entry.cookie,
+ type_spec_flags, 0U /* resid */, {} /* config */);
}
}
}
break;
} while (true);
- return kInvalidCookie;
+ return std::nullopt;
}
-ApkAssetsCookie Theme::ResolveAttributeReference(ApkAssetsCookie cookie, Res_value* in_out_value,
- ResTable_config* in_out_selected_config,
- uint32_t* in_out_type_spec_flags,
- uint32_t* out_last_ref) const {
- if (in_out_value->dataType == Res_value::TYPE_ATTRIBUTE) {
- uint32_t new_flags;
- cookie = GetAttribute(in_out_value->data, in_out_value, &new_flags);
- if (cookie == kInvalidCookie) {
- return kInvalidCookie;
- }
-
- if (in_out_type_spec_flags != nullptr) {
- *in_out_type_spec_flags |= new_flags;
- }
+base::expected<std::monostate, NullOrIOError> Theme::ResolveAttributeReference(
+ AssetManager2::SelectedValue& value) const {
+ if (value.type != Res_value::TYPE_ATTRIBUTE) {
+ return asset_manager_->ResolveReference(value);
}
- return asset_manager_->ResolveReference(cookie, in_out_value, in_out_selected_config,
- in_out_type_spec_flags, out_last_ref);
+
+ std::optional<AssetManager2::SelectedValue> result = GetAttribute(value.data);
+ if (!result.has_value()) {
+ return base::unexpected(std::nullopt);
+ }
+
+ auto resolve_result = asset_manager_->ResolveReference(*result, true /* cache_value */);
+ if (resolve_result.has_value()) {
+ result->flags |= value.flags;
+ value = *result;
+ }
+ return resolve_result;
}
void Theme::Clear() {
@@ -1507,9 +1565,9 @@
}
}
-void Theme::SetTo(const Theme& o) {
+base::expected<std::monostate, IOError> Theme::SetTo(const Theme& o) {
if (this == &o) {
- return;
+ return {};
}
type_spec_flags_ = o.type_spec_flags_;
@@ -1560,10 +1618,8 @@
// Map the runtime package of the source apk asset to the destination apk asset.
if (src_asset->GetPath() == dest_asset->GetPath()) {
- const std::vector<std::unique_ptr<const LoadedPackage>>& src_packages =
- src_asset->GetLoadedArsc()->GetPackages();
- const std::vector<std::unique_ptr<const LoadedPackage>>& dest_packages =
- dest_asset->GetLoadedArsc()->GetPackages();
+ const auto& src_packages = src_asset->GetLoadedArsc()->GetPackages();
+ const auto& dest_packages = dest_asset->GetLoadedArsc()->GetPackages();
SourceToDestinationRuntimePackageMap package_map;
@@ -1660,15 +1716,20 @@
int attribute_dest_package_id = p;
if (attribute_dest_package_id != 0x01) {
// Find the cookie of the attribute resource id in the source AssetManager
- FindEntryResult attribute_entry_result;
- ApkAssetsCookie attribute_cookie =
+ base::expected<FindEntryResult, NullOrIOError> attribute_entry_result =
o.asset_manager_->FindEntry(make_resid(p, t, e), 0 /* density_override */ ,
true /* stop_at_first_match */,
- true /* ignore_configuration */,
- &attribute_entry_result);
+ true /* ignore_configuration */);
+ if (UNLIKELY(IsIOError(attribute_entry_result))) {
+ return base::unexpected(GetIOError(attribute_entry_result.error()));
+ }
+ if (!attribute_entry_result.has_value()) {
+ continue;
+ }
// Determine the package id of the attribute in the destination AssetManager.
- auto attribute_package_map = src_asset_cookie_id_map.find(attribute_cookie);
+ auto attribute_package_map = src_asset_cookie_id_map.find(
+ attribute_entry_result->cookie);
if (attribute_package_map == src_asset_cookie_id_map.end()) {
continue;
}
@@ -1712,6 +1773,7 @@
}
}
}
+ return {};
}
void Theme::Dump() const {
diff --git a/libs/androidfw/AttributeResolution.cpp b/libs/androidfw/AttributeResolution.cpp
index e62fb61..347b4ec 100644
--- a/libs/androidfw/AttributeResolution.cpp
+++ b/libs/androidfw/AttributeResolution.cpp
@@ -24,9 +24,12 @@
#include "androidfw/AttributeFinder.h"
constexpr bool kDebugStyles = false;
+#define DEBUG_LOG(...) do { if (kDebugStyles) { ALOGI(__VA_ARGS__); } } while(0)
namespace android {
+namespace {
+
// Java asset cookies have 0 as an invalid cookie, but TypedArray expects < 0.
static uint32_t ApkAssetsCookieToJavaCookie(ApkAssetsCookie cookie) {
return cookie != kInvalidCookie ? static_cast<uint32_t>(cookie + 1) : static_cast<uint32_t>(-1);
@@ -36,8 +39,7 @@
: public BackTrackingAttributeFinder<XmlAttributeFinder, size_t> {
public:
explicit XmlAttributeFinder(const ResXMLParser* parser)
- : BackTrackingAttributeFinder(
- 0, parser != nullptr ? parser->getAttributeCount() : 0),
+ : BackTrackingAttributeFinder(0, parser != nullptr ? parser->getAttributeCount() : 0),
parser_(parser) {}
inline uint32_t GetAttribute(size_t index) const {
@@ -61,136 +63,149 @@
}
};
-bool ResolveAttrs(Theme* theme, uint32_t def_style_attr, uint32_t def_style_res,
- uint32_t* src_values, size_t src_values_length, uint32_t* attrs,
- size_t attrs_length, uint32_t* out_values, uint32_t* out_indices) {
- if (kDebugStyles) {
- ALOGI("APPLY STYLE: theme=0x%p defStyleAttr=0x%x defStyleRes=0x%x", theme,
- def_style_attr, def_style_res);
- }
-
- AssetManager2* assetmanager = theme->GetAssetManager();
- ResTable_config config;
- Res_value value;
-
- int indices_idx = 0;
-
- // Load default style from attribute, if specified...
- uint32_t def_style_flags = 0u;
- if (def_style_attr != 0) {
- Res_value value;
- if (theme->GetAttribute(def_style_attr, &value, &def_style_flags) != kInvalidCookie) {
- if (value.dataType == Res_value::TYPE_REFERENCE) {
- def_style_res = value.data;
+base::expected<const ResolvedBag*, NullOrIOError> GetStyleBag(Theme* theme,
+ uint32_t theme_attribute_resid,
+ uint32_t fallback_resid,
+ uint32_t* out_theme_flags) {
+ // Load the style from the attribute if specified.
+ if (theme_attribute_resid != 0U) {
+ std::optional<AssetManager2::SelectedValue> value = theme->GetAttribute(theme_attribute_resid);
+ if (value.has_value()) {
+ *out_theme_flags |= value->flags;
+ auto result = theme->GetAssetManager()->ResolveBag(*value);
+ if (result.has_value() || IsIOError(result)) {
+ return result;
}
}
}
- // Retrieve the default style bag, if requested.
- const ResolvedBag* default_style_bag = nullptr;
- if (def_style_res != 0) {
- default_style_bag = assetmanager->GetBag(def_style_res);
- if (default_style_bag != nullptr) {
- def_style_flags |= default_style_bag->type_spec_flags;
+ // Fallback to loading the style from the resource id if specified.
+ if (fallback_resid != 0U) {
+ return theme->GetAssetManager()->GetBag(fallback_resid);
+ }
+
+ return base::unexpected(std::nullopt);
+}
+
+base::expected<const ResolvedBag*, NullOrIOError> GetXmlStyleBag(Theme* theme,
+ ResXMLParser* xml_parser,
+ uint32_t* out_theme_flags) {
+ if (xml_parser == nullptr) {
+ return base::unexpected(std::nullopt);
+ }
+
+ // Retrieve the style resource ID associated with the current XML tag's style attribute.
+ Res_value value;
+ const ssize_t idx = xml_parser->indexOfStyle();
+ if (idx < 0 || xml_parser->getAttributeValue(idx, &value) < 0) {
+ return base::unexpected(std::nullopt);
+ }
+
+ if (value.dataType == Res_value::TYPE_ATTRIBUTE) {
+ // Resolve the attribute with out theme.
+ if (std::optional<AssetManager2::SelectedValue> result = theme->GetAttribute(value.data)) {
+ *out_theme_flags |= result->flags;
+ return theme->GetAssetManager()->ResolveBag(*result);
}
}
- BagAttributeFinder def_style_attr_finder(default_style_bag);
+ if (value.dataType == Res_value::TYPE_REFERENCE) {
+ return theme->GetAssetManager()->GetBag(value.data);
+ }
+
+ return base::unexpected(std::nullopt);
+}
+
+} // namespace
+
+base::expected<std::monostate, IOError> ResolveAttrs(Theme* theme, uint32_t def_style_attr,
+ uint32_t def_style_res, uint32_t* src_values,
+ size_t src_values_length, uint32_t* attrs,
+ size_t attrs_length, uint32_t* out_values,
+ uint32_t* out_indices) {
+ DEBUG_LOG("APPLY STYLE: theme=0x%p defStyleAttr=0x%x defStyleRes=0x%x", theme, def_style_attr,
+ def_style_res);
+
+ int indices_idx = 0;
+ const AssetManager2* assetmanager = theme->GetAssetManager();
+
+ // Load default style from attribute or resource id, if specified...
+ uint32_t def_style_theme_flags = 0U;
+ const auto default_style_bag = GetStyleBag(theme, def_style_attr, def_style_res,
+ &def_style_theme_flags);
+ if (UNLIKELY(IsIOError(default_style_bag))) {
+ return base::unexpected(GetIOError(default_style_bag.error()));
+ }
+
+ BagAttributeFinder def_style_attr_finder(default_style_bag.value_or(nullptr));
// Now iterate through all of the attributes that the client has requested,
// filling in each with whatever data we can find.
for (size_t ii = 0; ii < attrs_length; ii++) {
const uint32_t cur_ident = attrs[ii];
-
- if (kDebugStyles) {
- ALOGI("RETRIEVING ATTR 0x%08x...", cur_ident);
- }
-
- ApkAssetsCookie cookie = kInvalidCookie;
- uint32_t type_set_flags = 0;
-
- value.dataType = Res_value::TYPE_NULL;
- value.data = Res_value::DATA_NULL_UNDEFINED;
- config.density = 0;
+ DEBUG_LOG("RETRIEVING ATTR 0x%08x...", cur_ident);
// Try to find a value for this attribute... we prioritize values
// coming from, first XML attributes, then XML style, then default
// style, and finally the theme.
// Retrieve the current input value if available.
+ AssetManager2::SelectedValue value{};
if (src_values_length > 0 && src_values[ii] != 0) {
- value.dataType = Res_value::TYPE_ATTRIBUTE;
+ value.type = Res_value::TYPE_ATTRIBUTE;
value.data = src_values[ii];
- if (kDebugStyles) {
- ALOGI("-> From values: type=0x%x, data=0x%08x", value.dataType, value.data);
- }
+ DEBUG_LOG("-> From values: type=0x%x, data=0x%08x", value.type, value.data);
} else {
const ResolvedBag::Entry* const entry = def_style_attr_finder.Find(cur_ident);
if (entry != def_style_attr_finder.end()) {
- cookie = entry->cookie;
- type_set_flags = def_style_flags;
- value = entry->value;
- if (kDebugStyles) {
- ALOGI("-> From def style: type=0x%x, data=0x%08x", value.dataType, value.data);
- }
+ value = AssetManager2::SelectedValue(*default_style_bag, *entry);
+ value.flags |= def_style_theme_flags;
+ DEBUG_LOG("-> From def style: type=0x%x, data=0x%08x", value.type, value.data);
}
}
- uint32_t resid = 0;
- if (value.dataType != Res_value::TYPE_NULL) {
+ if (value.type != Res_value::TYPE_NULL) {
// Take care of resolving the found resource to its final value.
- ApkAssetsCookie new_cookie =
- theme->ResolveAttributeReference(cookie, &value, &config, &type_set_flags, &resid);
- if (new_cookie != kInvalidCookie) {
- cookie = new_cookie;
+ const auto result = theme->ResolveAttributeReference(value);
+ if (UNLIKELY(IsIOError(result))) {
+ return base::unexpected(GetIOError(result.error()));
}
- if (kDebugStyles) {
- ALOGI("-> Resolved attr: type=0x%x, data=0x%08x", value.dataType, value.data);
- }
+ DEBUG_LOG("-> Resolved attr: type=0x%x, data=0x%08x", value.type, value.data);
} else if (value.data != Res_value::DATA_NULL_EMPTY) {
// If we still don't have a value for this attribute, try to find it in the theme!
- ApkAssetsCookie new_cookie = theme->GetAttribute(cur_ident, &value, &type_set_flags);
- if (new_cookie != kInvalidCookie) {
- if (kDebugStyles) {
- ALOGI("-> From theme: type=0x%x, data=0x%08x", value.dataType, value.data);
+ if (auto attr_value = theme->GetAttribute(cur_ident)) {
+ value = *attr_value;
+ DEBUG_LOG("-> From theme: type=0x%x, data=0x%08x", value.type, value.data);
+
+ const auto result = assetmanager->ResolveReference(value, true /* cache_value */);
+ if (UNLIKELY(IsIOError(result))) {
+ return base::unexpected(GetIOError(result.error()));
}
- new_cookie =
- assetmanager->ResolveReference(new_cookie, &value, &config, &type_set_flags, &resid);
- if (new_cookie != kInvalidCookie) {
- cookie = new_cookie;
- }
- if (kDebugStyles) {
- ALOGI("-> Resolved theme: type=0x%x, data=0x%08x", value.dataType, value.data);
- }
+ DEBUG_LOG("-> Resolved theme: type=0x%x, data=0x%08x", value.type, value.data);
}
}
// Deal with the special @null value -- it turns back to TYPE_NULL.
- if (value.dataType == Res_value::TYPE_REFERENCE && value.data == 0) {
- if (kDebugStyles) {
- ALOGI("-> Setting to @null!");
- }
- value.dataType = Res_value::TYPE_NULL;
+ if (value.type == Res_value::TYPE_REFERENCE && value.data == 0) {
+ DEBUG_LOG("-> Setting to @null!");
+ value.type = Res_value::TYPE_NULL;
value.data = Res_value::DATA_NULL_UNDEFINED;
- cookie = kInvalidCookie;
+ value.cookie = kInvalidCookie;
}
- if (kDebugStyles) {
- ALOGI("Attribute 0x%08x: type=0x%x, data=0x%08x", cur_ident, value.dataType, value.data);
- }
+ DEBUG_LOG("Attribute 0x%08x: type=0x%x, data=0x%08x", cur_ident, value.type, value.data);
// Write the final value back to Java.
- out_values[STYLE_TYPE] = value.dataType;
+ out_values[STYLE_TYPE] = value.type;
out_values[STYLE_DATA] = value.data;
- out_values[STYLE_ASSET_COOKIE] = ApkAssetsCookieToJavaCookie(cookie);
- out_values[STYLE_RESOURCE_ID] = resid;
- out_values[STYLE_CHANGING_CONFIGURATIONS] = type_set_flags;
- out_values[STYLE_DENSITY] = config.density;
+ out_values[STYLE_ASSET_COOKIE] = ApkAssetsCookieToJavaCookie(value.cookie);
+ out_values[STYLE_RESOURCE_ID] = value.resid;
+ out_values[STYLE_CHANGING_CONFIGURATIONS] = value.flags;
+ out_values[STYLE_DENSITY] = value.config.density;
if (out_indices != nullptr &&
- (value.dataType != Res_value::TYPE_NULL || value.data == Res_value::DATA_NULL_EMPTY)) {
- indices_idx++;
- out_indices[indices_idx] = ii;
+ (value.type != Res_value::TYPE_NULL || value.data == Res_value::DATA_NULL_EMPTY)) {
+ out_indices[++indices_idx] = ii;
}
out_values += STYLE_NUM_ENTRIES;
@@ -199,93 +214,46 @@
if (out_indices != nullptr) {
out_indices[0] = indices_idx;
}
- return true;
+ return {};
}
-void ApplyStyle(Theme* theme, ResXMLParser* xml_parser, uint32_t def_style_attr,
- uint32_t def_style_resid, const uint32_t* attrs, size_t attrs_length,
- uint32_t* out_values, uint32_t* out_indices) {
- if (kDebugStyles) {
- ALOGI("APPLY STYLE: theme=0x%p defStyleAttr=0x%x defStyleRes=0x%x xml=0x%p", theme,
- def_style_attr, def_style_resid, xml_parser);
- }
-
- AssetManager2* assetmanager = theme->GetAssetManager();
- ResTable_config config;
- Res_value value;
+base::expected<std::monostate, IOError> ApplyStyle(Theme* theme, ResXMLParser* xml_parser,
+ uint32_t def_style_attr,
+ uint32_t def_style_resid,
+ const uint32_t* attrs, size_t attrs_length,
+ uint32_t* out_values, uint32_t* out_indices) {
+ DEBUG_LOG("APPLY STYLE: theme=0x%p defStyleAttr=0x%x defStyleRes=0x%x xml=0x%p", theme,
+ def_style_attr, def_style_resid, xml_parser);
int indices_idx = 0;
+ const AssetManager2* assetmanager = theme->GetAssetManager();
// Load default style from attribute, if specified...
- uint32_t def_style_flags = 0u;
- if (def_style_attr != 0) {
- Res_value value;
- if (theme->GetAttribute(def_style_attr, &value, &def_style_flags) != kInvalidCookie) {
- if (value.dataType == Res_value::TYPE_REFERENCE) {
- def_style_resid = value.data;
- }
- }
+ uint32_t def_style_theme_flags = 0U;
+ const auto default_style_bag = GetStyleBag(theme, def_style_attr, def_style_resid,
+ &def_style_theme_flags);
+ if (IsIOError(default_style_bag)) {
+ return base::unexpected(GetIOError(default_style_bag.error()));
}
// Retrieve the style resource ID associated with the current XML tag's style attribute.
- uint32_t style_resid = 0u;
- uint32_t style_flags = 0u;
- if (xml_parser != nullptr) {
- ssize_t idx = xml_parser->indexOfStyle();
- if (idx >= 0 && xml_parser->getAttributeValue(idx, &value) >= 0) {
- if (value.dataType == value.TYPE_ATTRIBUTE) {
- // Resolve the attribute with out theme.
- if (theme->GetAttribute(value.data, &value, &style_flags) == kInvalidCookie) {
- value.dataType = Res_value::TYPE_NULL;
- }
- }
-
- if (value.dataType == value.TYPE_REFERENCE) {
- style_resid = value.data;
- }
- }
+ uint32_t xml_style_theme_flags = 0U;
+ const auto xml_style_bag = GetXmlStyleBag(theme, xml_parser, &def_style_theme_flags);
+ if (IsIOError(xml_style_bag)) {
+ return base::unexpected(GetIOError(xml_style_bag.error()));
}
- // Retrieve the default style bag, if requested.
- const ResolvedBag* default_style_bag = nullptr;
- if (def_style_resid != 0) {
- default_style_bag = assetmanager->GetBag(def_style_resid);
- if (default_style_bag != nullptr) {
- def_style_flags |= default_style_bag->type_spec_flags;
- }
- }
-
- BagAttributeFinder def_style_attr_finder(default_style_bag);
-
- // Retrieve the style class bag, if requested.
- const ResolvedBag* xml_style_bag = nullptr;
- if (style_resid != 0) {
- xml_style_bag = assetmanager->GetBag(style_resid);
- if (xml_style_bag != nullptr) {
- style_flags |= xml_style_bag->type_spec_flags;
- }
- }
-
- BagAttributeFinder xml_style_attr_finder(xml_style_bag);
-
- // Retrieve the XML attributes, if requested.
+ BagAttributeFinder def_style_attr_finder(default_style_bag.value_or(nullptr));
+ BagAttributeFinder xml_style_attr_finder(xml_style_bag.value_or(nullptr));
XmlAttributeFinder xml_attr_finder(xml_parser);
// Now iterate through all of the attributes that the client has requested,
// filling in each with whatever data we can find.
for (size_t ii = 0; ii < attrs_length; ii++) {
const uint32_t cur_ident = attrs[ii];
+ DEBUG_LOG("RETRIEVING ATTR 0x%08x...", cur_ident);
- if (kDebugStyles) {
- ALOGI("RETRIEVING ATTR 0x%08x...", cur_ident);
- }
-
- ApkAssetsCookie cookie = kInvalidCookie;
- uint32_t type_set_flags = 0u;
-
- value.dataType = Res_value::TYPE_NULL;
- value.data = Res_value::DATA_NULL_UNDEFINED;
- config.density = 0;
+ AssetManager2::SelectedValue value{};
uint32_t value_source_resid = 0;
// Try to find a value for this attribute... we prioritize values
@@ -296,178 +264,152 @@
const size_t xml_attr_idx = xml_attr_finder.Find(cur_ident);
if (xml_attr_idx != xml_attr_finder.end()) {
// We found the attribute we were looking for.
- xml_parser->getAttributeValue(xml_attr_idx, &value);
- if (kDebugStyles) {
- ALOGI("-> From XML: type=0x%x, data=0x%08x", value.dataType, value.data);
- }
+ Res_value attribute_value;
+ xml_parser->getAttributeValue(xml_attr_idx, &attribute_value);
+ value.type = attribute_value.dataType;
+ value.data = attribute_value.data;
value_source_resid = xml_parser->getSourceResourceId();
+ DEBUG_LOG("-> From XML: type=0x%x, data=0x%08x", value.type, value.data);
}
- if (value.dataType == Res_value::TYPE_NULL && value.data != Res_value::DATA_NULL_EMPTY) {
+ if (value.type == Res_value::TYPE_NULL && value.data != Res_value::DATA_NULL_EMPTY) {
// Walk through the style class values looking for the requested attribute.
const ResolvedBag::Entry* entry = xml_style_attr_finder.Find(cur_ident);
if (entry != xml_style_attr_finder.end()) {
- // We found the attribute we were looking for.
- cookie = entry->cookie;
- type_set_flags = style_flags;
- value = entry->value;
+ value = AssetManager2::SelectedValue(*xml_style_bag, *entry);
+ value.flags |= xml_style_theme_flags;
value_source_resid = entry->style;
- if (kDebugStyles) {
- ALOGI("-> From style: type=0x%x, data=0x%08x, style=0x%08x", value.dataType, value.data,
- entry->style);
- }
+ DEBUG_LOG("-> From style: type=0x%x, data=0x%08x, style=0x%08x", value.type, value.data,
+ value_source_resid);
}
}
- if (value.dataType == Res_value::TYPE_NULL && value.data != Res_value::DATA_NULL_EMPTY) {
+ if (value.type == Res_value::TYPE_NULL && value.data != Res_value::DATA_NULL_EMPTY) {
// Walk through the default style values looking for the requested attribute.
const ResolvedBag::Entry* entry = def_style_attr_finder.Find(cur_ident);
if (entry != def_style_attr_finder.end()) {
- // We found the attribute we were looking for.
- cookie = entry->cookie;
- type_set_flags = def_style_flags;
- value = entry->value;
- if (kDebugStyles) {
- ALOGI("-> From def style: type=0x%x, data=0x%08x, style=0x%08x", value.dataType, value.data,
- entry->style);
- }
+ value = AssetManager2::SelectedValue(*default_style_bag, *entry);
+ value.flags |= def_style_theme_flags;
value_source_resid = entry->style;
+ DEBUG_LOG("-> From def style: type=0x%x, data=0x%08x, style=0x%08x", value.type, value.data,
+ entry->style);
}
}
- uint32_t resid = 0u;
- if (value.dataType != Res_value::TYPE_NULL) {
+ if (value.type != Res_value::TYPE_NULL) {
// Take care of resolving the found resource to its final value.
- ApkAssetsCookie new_cookie =
- theme->ResolveAttributeReference(cookie, &value, &config, &type_set_flags, &resid);
- if (new_cookie != kInvalidCookie) {
- cookie = new_cookie;
+ auto result = theme->ResolveAttributeReference(value);
+ if (UNLIKELY(IsIOError(result))) {
+ return base::unexpected(GetIOError(result.error()));
}
-
- if (kDebugStyles) {
- ALOGI("-> Resolved attr: type=0x%x, data=0x%08x", value.dataType, value.data);
- }
+ DEBUG_LOG("-> Resolved attr: type=0x%x, data=0x%08x", value.type, value.data);
} else if (value.data != Res_value::DATA_NULL_EMPTY) {
// If we still don't have a value for this attribute, try to find it in the theme!
- ApkAssetsCookie new_cookie = theme->GetAttribute(cur_ident, &value, &type_set_flags);
- // TODO: set value_source_resid for the style in the theme that was used.
- if (new_cookie != kInvalidCookie) {
- if (kDebugStyles) {
- ALOGI("-> From theme: type=0x%x, data=0x%08x", value.dataType, value.data);
- }
- new_cookie =
- assetmanager->ResolveReference(new_cookie, &value, &config, &type_set_flags, &resid);
- if (new_cookie != kInvalidCookie) {
- cookie = new_cookie;
- }
+ if (auto attr_value = theme->GetAttribute(cur_ident)) {
+ value = *attr_value;
+ DEBUG_LOG("-> From theme: type=0x%x, data=0x%08x", value.type, value.data);
- if (kDebugStyles) {
- ALOGI("-> Resolved theme: type=0x%x, data=0x%08x", value.dataType, value.data);
+ auto result = assetmanager->ResolveReference(value, true /* cache_value */);
+ if (UNLIKELY(IsIOError(result))) {
+ return base::unexpected(GetIOError(result.error()));
}
+ DEBUG_LOG("-> Resolved theme: type=0x%x, data=0x%08x", value.type, value.data);
+ // TODO: set value_source_resid for the style in the theme that was used.
}
}
// Deal with the special @null value -- it turns back to TYPE_NULL.
- if (value.dataType == Res_value::TYPE_REFERENCE && value.data == 0) {
- if (kDebugStyles) {
- ALOGI("-> Setting to @null!");
- }
- value.dataType = Res_value::TYPE_NULL;
+ if (value.type == Res_value::TYPE_REFERENCE && value.data == 0U) {
+ DEBUG_LOG("-> Setting to @null!");
+ value.type = Res_value::TYPE_NULL;
value.data = Res_value::DATA_NULL_UNDEFINED;
- cookie = kInvalidCookie;
+ value.cookie = kInvalidCookie;
}
- if (kDebugStyles) {
- ALOGI("Attribute 0x%08x: type=0x%x, data=0x%08x", cur_ident, value.dataType, value.data);
- }
+ DEBUG_LOG("Attribute 0x%08x: type=0x%x, data=0x%08x", cur_ident, value.type, value.data);
// Write the final value back to Java.
- out_values[STYLE_TYPE] = value.dataType;
+ out_values[STYLE_TYPE] = value.type;
out_values[STYLE_DATA] = value.data;
- out_values[STYLE_ASSET_COOKIE] = ApkAssetsCookieToJavaCookie(cookie);
- out_values[STYLE_RESOURCE_ID] = resid;
- out_values[STYLE_CHANGING_CONFIGURATIONS] = type_set_flags;
- out_values[STYLE_DENSITY] = config.density;
+ out_values[STYLE_ASSET_COOKIE] = ApkAssetsCookieToJavaCookie(value.cookie);
+ out_values[STYLE_RESOURCE_ID] = value.resid;
+ out_values[STYLE_CHANGING_CONFIGURATIONS] = value.flags;
+ out_values[STYLE_DENSITY] = value.config.density;
out_values[STYLE_SOURCE_RESOURCE_ID] = value_source_resid;
- if (value.dataType != Res_value::TYPE_NULL || value.data == Res_value::DATA_NULL_EMPTY) {
- indices_idx++;
-
+ if (value.type != Res_value::TYPE_NULL || value.data == Res_value::DATA_NULL_EMPTY) {
// out_indices must NOT be nullptr.
- out_indices[indices_idx] = ii;
+ out_indices[++indices_idx] = ii;
}
out_values += STYLE_NUM_ENTRIES;
}
// out_indices must NOT be nullptr.
out_indices[0] = indices_idx;
+ return {};
}
-bool RetrieveAttributes(AssetManager2* assetmanager, ResXMLParser* xml_parser, uint32_t* attrs,
- size_t attrs_length, uint32_t* out_values, uint32_t* out_indices) {
- ResTable_config config;
- Res_value value;
-
+base::expected<std::monostate, IOError> RetrieveAttributes(AssetManager2* assetmanager,
+ ResXMLParser* xml_parser,
+ uint32_t* attrs,
+ size_t attrs_length,
+ uint32_t* out_values,
+ uint32_t* out_indices) {
int indices_idx = 0;
// Retrieve the XML attributes, if requested.
- const size_t xml_attr_count = xml_parser->getAttributeCount();
size_t ix = 0;
+ const size_t xml_attr_count = xml_parser->getAttributeCount();
uint32_t cur_xml_attr = xml_parser->getAttributeNameResID(ix);
// Now iterate through all of the attributes that the client has requested,
// filling in each with whatever data we can find.
for (size_t ii = 0; ii < attrs_length; ii++) {
const uint32_t cur_ident = attrs[ii];
- ApkAssetsCookie cookie = kInvalidCookie;
- uint32_t type_set_flags = 0u;
-
- value.dataType = Res_value::TYPE_NULL;
- value.data = Res_value::DATA_NULL_UNDEFINED;
- config.density = 0;
+ AssetManager2::SelectedValue value{};
// Try to find a value for this attribute...
// Skip through XML attributes until the end or the next possible match.
while (ix < xml_attr_count && cur_ident > cur_xml_attr) {
- ix++;
- cur_xml_attr = xml_parser->getAttributeNameResID(ix);
- }
- // Retrieve the current XML attribute if it matches, and step to next.
- if (ix < xml_attr_count && cur_ident == cur_xml_attr) {
- xml_parser->getAttributeValue(ix, &value);
- ix++;
- cur_xml_attr = xml_parser->getAttributeNameResID(ix);
+ cur_xml_attr = xml_parser->getAttributeNameResID(++ix);
}
- uint32_t resid = 0u;
- if (value.dataType != Res_value::TYPE_NULL) {
+ // Retrieve the current XML attribute if it matches, and step to next.
+ if (ix < xml_attr_count && cur_ident == cur_xml_attr) {
+ Res_value attribute_value;
+ xml_parser->getAttributeValue(ix, &attribute_value);
+ value.type = attribute_value.dataType;
+ value.data = attribute_value.data;
+ cur_xml_attr = xml_parser->getAttributeNameResID(++ix);
+ }
+
+ if (value.type != Res_value::TYPE_NULL) {
// Take care of resolving the found resource to its final value.
- ApkAssetsCookie new_cookie =
- assetmanager->ResolveReference(cookie, &value, &config, &type_set_flags, &resid);
- if (new_cookie != kInvalidCookie) {
- cookie = new_cookie;
+ auto result = assetmanager->ResolveReference(value);
+ if (UNLIKELY(IsIOError(result))) {
+ return base::unexpected(GetIOError(result.error()));
}
}
// Deal with the special @null value -- it turns back to TYPE_NULL.
- if (value.dataType == Res_value::TYPE_REFERENCE && value.data == 0) {
- value.dataType = Res_value::TYPE_NULL;
+ if (value.type == Res_value::TYPE_REFERENCE && value.data == 0U) {
+ value.type = Res_value::TYPE_NULL;
value.data = Res_value::DATA_NULL_UNDEFINED;
- cookie = kInvalidCookie;
+ value.cookie = kInvalidCookie;
}
// Write the final value back to Java.
- out_values[STYLE_TYPE] = value.dataType;
+ out_values[STYLE_TYPE] = value.type;
out_values[STYLE_DATA] = value.data;
- out_values[STYLE_ASSET_COOKIE] = ApkAssetsCookieToJavaCookie(cookie);
- out_values[STYLE_RESOURCE_ID] = resid;
- out_values[STYLE_CHANGING_CONFIGURATIONS] = type_set_flags;
- out_values[STYLE_DENSITY] = config.density;
+ out_values[STYLE_ASSET_COOKIE] = ApkAssetsCookieToJavaCookie(value.cookie);
+ out_values[STYLE_RESOURCE_ID] = value.resid;
+ out_values[STYLE_CHANGING_CONFIGURATIONS] = value.flags;
+ out_values[STYLE_DENSITY] = value.config.density;
if (out_indices != nullptr &&
- (value.dataType != Res_value::TYPE_NULL || value.data == Res_value::DATA_NULL_EMPTY)) {
- indices_idx++;
- out_indices[indices_idx] = ii;
+ (value.type != Res_value::TYPE_NULL ||
+ value.data == Res_value::DATA_NULL_EMPTY)) {
+ out_indices[++indices_idx] = ii;
}
out_values += STYLE_NUM_ENTRIES;
@@ -476,7 +418,7 @@
if (out_indices != nullptr) {
out_indices[0] = indices_idx;
}
- return true;
+ return {};
}
} // namespace android
diff --git a/libs/androidfw/ChunkIterator.cpp b/libs/androidfw/ChunkIterator.cpp
index 8fc3219..25c8aa6 100644
--- a/libs/androidfw/ChunkIterator.cpp
+++ b/libs/androidfw/ChunkIterator.cpp
@@ -15,6 +15,7 @@
*/
#include "androidfw/Chunk.h"
+#include "androidfw/Util.h"
#include "android-base/logging.h"
@@ -23,11 +24,11 @@
Chunk ChunkIterator::Next() {
CHECK(len_ != 0) << "called Next() after last chunk";
- const ResChunk_header* this_chunk = next_chunk_;
+ const incfs::map_ptr<ResChunk_header> this_chunk = next_chunk_;
+ CHECK((bool) this_chunk) << "Next() called without verifying next chunk";
// We've already checked the values of this_chunk, so safely increment.
- next_chunk_ = reinterpret_cast<const ResChunk_header*>(
- reinterpret_cast<const uint8_t*>(this_chunk) + dtohl(this_chunk->size));
+ next_chunk_ = this_chunk.offset(dtohl(this_chunk->size)).convert<ResChunk_header>();
len_ -= dtohl(this_chunk->size);
if (len_ != 0) {
@@ -36,7 +37,7 @@
VerifyNextChunk();
}
}
- return Chunk(this_chunk);
+ return Chunk(this_chunk.verified());
}
// TODO(b/111401637) remove this and have full resource file verification
@@ -47,6 +48,13 @@
last_error_was_fatal_ = false;
return false;
}
+
+ if (!next_chunk_) {
+ last_error_ = "failed to read chunk from data";
+ last_error_was_fatal_ = false;
+ return false;
+ }
+
const size_t size = dtohl(next_chunk_->size);
if (size > len_) {
last_error_ = "chunk size is bigger than given data";
@@ -58,12 +66,10 @@
// Returns false if there was an error.
bool ChunkIterator::VerifyNextChunk() {
- const uintptr_t header_start = reinterpret_cast<uintptr_t>(next_chunk_);
-
// This data must be 4-byte aligned, since we directly
// access 32-bit words, which must be aligned on
// certain architectures.
- if (header_start & 0x03) {
+ if (!util::IsFourByteAligned(next_chunk_)) {
last_error_ = "header not aligned on 4-byte boundary";
return false;
}
@@ -73,6 +79,11 @@
return false;
}
+ if (!next_chunk_) {
+ last_error_ = "failed to read chunk from data";
+ return false;
+ }
+
const size_t header_size = dtohs(next_chunk_->headerSize);
const size_t size = dtohl(next_chunk_->size);
if (header_size < sizeof(ResChunk_header)) {
@@ -90,7 +101,7 @@
return false;
}
- if ((size | header_size) & 0x03) {
+ if ((size | header_size) & 0x03U) {
last_error_ = "header sizes are not aligned on 4-byte boundary";
return false;
}
diff --git a/libs/androidfw/Idmap.cpp b/libs/androidfw/Idmap.cpp
index 4e03ce5..a613095 100644
--- a/libs/androidfw/Idmap.cpp
+++ b/libs/androidfw/Idmap.cpp
@@ -52,22 +52,22 @@
uninit();
}
-const char16_t* OverlayStringPool::stringAt(size_t idx, size_t* outLen) const {
+base::expected<StringPiece16, NullOrIOError> OverlayStringPool::stringAt(size_t idx) const {
const size_t offset = dtohl(data_header_->string_pool_index_offset);
if (idmap_string_pool_ != nullptr && idx >= ResStringPool::size() && idx >= offset) {
- return idmap_string_pool_->stringAt(idx - offset, outLen);
+ return idmap_string_pool_->stringAt(idx - offset);
}
- return ResStringPool::stringAt(idx, outLen);
+ return ResStringPool::stringAt(idx);
}
-const char* OverlayStringPool::string8At(size_t idx, size_t* outLen) const {
+base::expected<StringPiece, NullOrIOError> OverlayStringPool::string8At(size_t idx) const {
const size_t offset = dtohl(data_header_->string_pool_index_offset);
if (idmap_string_pool_ != nullptr && idx >= ResStringPool::size() && idx >= offset) {
- return idmap_string_pool_->string8At(idx - offset, outLen);
+ return idmap_string_pool_->string8At(idx - offset);
}
- return ResStringPool::string8At(idx, outLen);
+ return ResStringPool::string8At(idx);
}
size_t OverlayStringPool::size() const {
diff --git a/libs/androidfw/LoadedArsc.cpp b/libs/androidfw/LoadedArsc.cpp
index 70bb441..2fc3b05 100644
--- a/libs/androidfw/LoadedArsc.cpp
+++ b/libs/androidfw/LoadedArsc.cpp
@@ -38,7 +38,7 @@
#include "androidfw/ResourceUtils.h"
#include "androidfw/Util.h"
-using ::android::base::StringPrintf;
+using android::base::StringPrintf;
namespace android {
@@ -51,17 +51,17 @@
// the Type structs.
class TypeSpecPtrBuilder {
public:
- explicit TypeSpecPtrBuilder(const ResTable_typeSpec* header)
+ explicit TypeSpecPtrBuilder(incfs::verified_map_ptr<ResTable_typeSpec> header)
: header_(header) {
}
- void AddType(const ResTable_type* type) {
+ void AddType(incfs::verified_map_ptr<ResTable_type> type) {
types_.push_back(type);
}
TypeSpecPtr Build() {
// Check for overflow.
- using ElementType = const ResTable_type*;
+ using ElementType = incfs::verified_map_ptr<ResTable_type>;
if ((std::numeric_limits<size_t>::max() - sizeof(TypeSpec)) / sizeof(ElementType) <
types_.size()) {
return {};
@@ -77,8 +77,8 @@
private:
DISALLOW_COPY_AND_ASSIGN(TypeSpecPtrBuilder);
- const ResTable_typeSpec* header_;
- std::vector<const ResTable_type*> types_;
+ incfs::verified_map_ptr<ResTable_typeSpec> header_;
+ std::vector<incfs::verified_map_ptr<ResTable_type>> types_;
};
} // namespace
@@ -88,7 +88,7 @@
// Precondition: The header passed in has already been verified, so reading any fields and trusting
// the ResChunk_header is safe.
-static bool VerifyResTableType(const ResTable_type* header) {
+static bool VerifyResTableType(incfs::map_ptr<ResTable_type> header) {
if (header->id == 0) {
LOG(ERROR) << "RES_TABLE_TYPE_TYPE has invalid ID 0.";
return false;
@@ -115,89 +115,99 @@
return false;
}
- if (entries_offset & 0x03) {
+ if (entries_offset & 0x03U) {
LOG(ERROR) << "RES_TABLE_TYPE_TYPE entries start at unaligned address.";
return false;
}
return true;
}
-static bool VerifyResTableEntry(const ResTable_type* type, uint32_t entry_offset) {
+static base::expected<std::monostate, NullOrIOError> VerifyResTableEntry(
+ incfs::verified_map_ptr<ResTable_type> type, uint32_t entry_offset) {
// Check that the offset is aligned.
- if (entry_offset & 0x03) {
+ if (UNLIKELY(entry_offset & 0x03U)) {
LOG(ERROR) << "Entry at offset " << entry_offset << " is not 4-byte aligned.";
- return false;
+ return base::unexpected(std::nullopt);
}
// Check that the offset doesn't overflow.
- if (entry_offset > std::numeric_limits<uint32_t>::max() - dtohl(type->entriesStart)) {
+ if (UNLIKELY(entry_offset > std::numeric_limits<uint32_t>::max() - dtohl(type->entriesStart))) {
// Overflow in offset.
LOG(ERROR) << "Entry at offset " << entry_offset << " is too large.";
- return false;
+ return base::unexpected(std::nullopt);
}
const size_t chunk_size = dtohl(type->header.size);
entry_offset += dtohl(type->entriesStart);
- if (entry_offset > chunk_size - sizeof(ResTable_entry)) {
+ if (UNLIKELY(entry_offset > chunk_size - sizeof(ResTable_entry))) {
LOG(ERROR) << "Entry at offset " << entry_offset
<< " is too large. No room for ResTable_entry.";
- return false;
+ return base::unexpected(std::nullopt);
}
- const ResTable_entry* entry = reinterpret_cast<const ResTable_entry*>(
- reinterpret_cast<const uint8_t*>(type) + entry_offset);
+ auto entry = type.offset(entry_offset).convert<ResTable_entry>();
+ if (UNLIKELY(!entry)) {
+ return base::unexpected(IOError::PAGES_MISSING);
+ }
const size_t entry_size = dtohs(entry->size);
- if (entry_size < sizeof(*entry)) {
+ if (UNLIKELY(entry_size < sizeof(entry.value()))) {
LOG(ERROR) << "ResTable_entry size " << entry_size << " at offset " << entry_offset
<< " is too small.";
- return false;
+ return base::unexpected(std::nullopt);
}
- if (entry_size > chunk_size || entry_offset > chunk_size - entry_size) {
+ if (UNLIKELY(entry_size > chunk_size || entry_offset > chunk_size - entry_size)) {
LOG(ERROR) << "ResTable_entry size " << entry_size << " at offset " << entry_offset
<< " is too large.";
- return false;
+ return base::unexpected(std::nullopt);
}
if (entry_size < sizeof(ResTable_map_entry)) {
// There needs to be room for one Res_value struct.
- if (entry_offset + entry_size > chunk_size - sizeof(Res_value)) {
+ if (UNLIKELY(entry_offset + entry_size > chunk_size - sizeof(Res_value))) {
LOG(ERROR) << "No room for Res_value after ResTable_entry at offset " << entry_offset
<< " for type " << (int)type->id << ".";
- return false;
+ return base::unexpected(std::nullopt);
}
- const Res_value* value =
- reinterpret_cast<const Res_value*>(reinterpret_cast<const uint8_t*>(entry) + entry_size);
+ auto value = entry.offset(entry_size).convert<Res_value>();
+ if (UNLIKELY(!value)) {
+ return base::unexpected(IOError::PAGES_MISSING);
+ }
+
const size_t value_size = dtohs(value->size);
- if (value_size < sizeof(Res_value)) {
+ if (UNLIKELY(value_size < sizeof(Res_value))) {
LOG(ERROR) << "Res_value at offset " << entry_offset << " is too small.";
- return false;
+ return base::unexpected(std::nullopt);
}
- if (value_size > chunk_size || entry_offset + entry_size > chunk_size - value_size) {
+ if (UNLIKELY(value_size > chunk_size || entry_offset + entry_size > chunk_size - value_size)) {
LOG(ERROR) << "Res_value size " << value_size << " at offset " << entry_offset
<< " is too large.";
- return false;
+ return base::unexpected(std::nullopt);
}
} else {
- const ResTable_map_entry* map = reinterpret_cast<const ResTable_map_entry*>(entry);
+ auto map = entry.convert<ResTable_map_entry>();
+ if (UNLIKELY(!map)) {
+ return base::unexpected(IOError::PAGES_MISSING);
+ }
+
const size_t map_entry_count = dtohl(map->count);
size_t map_entries_start = entry_offset + entry_size;
- if (map_entries_start & 0x03) {
+ if (UNLIKELY(map_entries_start & 0x03U)) {
LOG(ERROR) << "Map entries at offset " << entry_offset << " start at unaligned offset.";
- return false;
+ return base::unexpected(std::nullopt);
}
// Each entry is sizeof(ResTable_map) big.
- if (map_entry_count > ((chunk_size - map_entries_start) / sizeof(ResTable_map))) {
+ if (UNLIKELY(map_entry_count > ((chunk_size - map_entries_start) / sizeof(ResTable_map)))) {
LOG(ERROR) << "Too many map entries in ResTable_map_entry at offset " << entry_offset << ".";
- return false;
+ return base::unexpected(std::nullopt);
}
}
- return true;
+ return {};
}
LoadedPackage::iterator::iterator(const LoadedPackage* lp, size_t ti, size_t ei)
@@ -233,99 +243,125 @@
entryIndex_);
}
-const ResTable_entry* LoadedPackage::GetEntry(const ResTable_type* type_chunk,
- uint16_t entry_index) {
- uint32_t entry_offset = GetEntryOffset(type_chunk, entry_index);
- if (entry_offset == ResTable_type::NO_ENTRY) {
- return nullptr;
+base::expected<incfs::map_ptr<ResTable_entry>, NullOrIOError> LoadedPackage::GetEntry(
+ incfs::verified_map_ptr<ResTable_type> type_chunk, uint16_t entry_index) {
+ base::expected<uint32_t, NullOrIOError> entry_offset = GetEntryOffset(type_chunk, entry_index);
+ if (UNLIKELY(!entry_offset.has_value())) {
+ return base::unexpected(entry_offset.error());
}
- return GetEntryFromOffset(type_chunk, entry_offset);
+ return GetEntryFromOffset(type_chunk, entry_offset.value());
}
-uint32_t LoadedPackage::GetEntryOffset(const ResTable_type* type_chunk, uint16_t entry_index) {
+base::expected<uint32_t, NullOrIOError> LoadedPackage::GetEntryOffset(
+ incfs::verified_map_ptr<ResTable_type> type_chunk, uint16_t entry_index) {
// The configuration matches and is better than the previous selection.
// Find the entry value if it exists for this configuration.
const size_t entry_count = dtohl(type_chunk->entryCount);
const size_t offsets_offset = dtohs(type_chunk->header.headerSize);
// Check if there is the desired entry in this type.
-
if (type_chunk->flags & ResTable_type::FLAG_SPARSE) {
// This is encoded as a sparse map, so perform a binary search.
- const ResTable_sparseTypeEntry* sparse_indices =
- reinterpret_cast<const ResTable_sparseTypeEntry*>(
- reinterpret_cast<const uint8_t*>(type_chunk) + offsets_offset);
- const ResTable_sparseTypeEntry* sparse_indices_end = sparse_indices + entry_count;
- const ResTable_sparseTypeEntry* result =
- std::lower_bound(sparse_indices, sparse_indices_end, entry_index,
- [](const ResTable_sparseTypeEntry& entry, uint16_t entry_idx) {
- return dtohs(entry.idx) < entry_idx;
- });
+ bool error = false;
+ auto sparse_indices = type_chunk.offset(offsets_offset)
+ .convert<ResTable_sparseTypeEntry>().iterator();
+ auto sparse_indices_end = sparse_indices + entry_count;
+ auto result = std::lower_bound(sparse_indices, sparse_indices_end, entry_index,
+ [&error](const incfs::map_ptr<ResTable_sparseTypeEntry>& entry,
+ uint16_t entry_idx) {
+ if (UNLIKELY(!entry)) {
+ return error = true;
+ }
+ return dtohs(entry->idx) < entry_idx;
+ });
- if (result == sparse_indices_end || dtohs(result->idx) != entry_index) {
+ if (result == sparse_indices_end) {
// No entry found.
- return ResTable_type::NO_ENTRY;
+ return base::unexpected(std::nullopt);
+ }
+
+ const incfs::verified_map_ptr<ResTable_sparseTypeEntry> entry = (*result).verified();
+ if (dtohs(entry->idx) != entry_index) {
+ if (error) {
+ return base::unexpected(IOError::PAGES_MISSING);
+ }
+ return base::unexpected(std::nullopt);
}
// Extract the offset from the entry. Each offset must be a multiple of 4 so we store it as
// the real offset divided by 4.
- return uint32_t{dtohs(result->offset)} * 4u;
+ return uint32_t{dtohs(entry->offset)} * 4u;
}
// This type is encoded as a dense array.
if (entry_index >= entry_count) {
// This entry cannot be here.
- return ResTable_type::NO_ENTRY;
+ return base::unexpected(std::nullopt);
}
- const uint32_t* entry_offsets = reinterpret_cast<const uint32_t*>(
- reinterpret_cast<const uint8_t*>(type_chunk) + offsets_offset);
- return dtohl(entry_offsets[entry_index]);
-}
-
-const ResTable_entry* LoadedPackage::GetEntryFromOffset(const ResTable_type* type_chunk,
- uint32_t offset) {
- if (UNLIKELY(!VerifyResTableEntry(type_chunk, offset))) {
- return nullptr;
+ const auto entry_offset_ptr = type_chunk.offset(offsets_offset).convert<uint32_t>() + entry_index;
+ if (UNLIKELY(!entry_offset_ptr)) {
+ return base::unexpected(IOError::PAGES_MISSING);
}
- return reinterpret_cast<const ResTable_entry*>(reinterpret_cast<const uint8_t*>(type_chunk) +
- offset + dtohl(type_chunk->entriesStart));
+
+ const uint32_t value = dtohl(entry_offset_ptr.value());
+ if (value == ResTable_type::NO_ENTRY) {
+ return base::unexpected(std::nullopt);
+ }
+
+ return value;
}
-void LoadedPackage::CollectConfigurations(bool exclude_mipmap,
- std::set<ResTable_config>* out_configs) const {
- const static std::u16string kMipMap = u"mipmap";
+base::expected<incfs::map_ptr<ResTable_entry>, NullOrIOError> LoadedPackage::GetEntryFromOffset(
+ incfs::verified_map_ptr<ResTable_type> type_chunk, uint32_t offset) {
+ auto valid = VerifyResTableEntry(type_chunk, offset);
+ if (UNLIKELY(!valid.has_value())) {
+ return base::unexpected(valid.error());
+ }
+ return type_chunk.offset(offset + dtohl(type_chunk->entriesStart)).convert<ResTable_entry>();
+}
+
+base::expected<std::monostate, IOError> LoadedPackage::CollectConfigurations(
+ bool exclude_mipmap, std::set<ResTable_config>* out_configs) const {
const size_t type_count = type_specs_.size();
for (size_t i = 0; i < type_count; i++) {
const TypeSpecPtr& type_spec = type_specs_[i];
- if (type_spec != nullptr) {
- if (exclude_mipmap) {
- const int type_idx = type_spec->type_spec->id - 1;
- size_t type_name_len;
- const char16_t* type_name16 = type_string_pool_.stringAt(type_idx, &type_name_len);
- if (type_name16 != nullptr) {
- if (kMipMap.compare(0, std::u16string::npos, type_name16, type_name_len) == 0) {
- // This is a mipmap type, skip collection.
- continue;
- }
- }
- const char* type_name = type_string_pool_.string8At(type_idx, &type_name_len);
- if (type_name != nullptr) {
- if (strncmp(type_name, "mipmap", type_name_len) == 0) {
- // This is a mipmap type, skip collection.
- continue;
- }
+ if (type_spec == nullptr) {
+ continue;
+ }
+ if (exclude_mipmap) {
+ const int type_idx = type_spec->type_spec->id - 1;
+ const auto type_name16 = type_string_pool_.stringAt(type_idx);
+ if (UNLIKELY(IsIOError(type_name16))) {
+ return base::unexpected(GetIOError(type_name16.error()));
+ }
+ if (type_name16.has_value()) {
+ if (strncmp16(type_name16->data(), u"mipmap", type_name16->size()) == 0) {
+ // This is a mipmap type, skip collection.
+ continue;
}
}
- const auto iter_end = type_spec->types + type_spec->type_count;
- for (auto iter = type_spec->types; iter != iter_end; ++iter) {
- ResTable_config config;
- config.copyFromDtoH((*iter)->config);
- out_configs->insert(config);
+ const auto type_name = type_string_pool_.string8At(type_idx);
+ if (UNLIKELY(IsIOError(type_name))) {
+ return base::unexpected(GetIOError(type_name.error()));
+ }
+ if (type_name.has_value()) {
+ if (strncmp(type_name->data(), "mipmap", type_name->size()) == 0) {
+ // This is a mipmap type, skip collection.
+ continue;
+ }
}
}
+
+ const auto iter_end = type_spec->types + type_spec->type_count;
+ for (auto iter = type_spec->types; iter != iter_end; ++iter) {
+ ResTable_config config;
+ config.copyFromDtoH((*iter)->config);
+ out_configs->insert(config);
+ }
}
+ return {};
}
void LoadedPackage::CollectLocales(bool canonicalize, std::set<std::string>* out_locales) const {
@@ -348,43 +384,53 @@
}
}
-uint32_t LoadedPackage::FindEntryByName(const std::u16string& type_name,
- const std::u16string& entry_name) const {
- ssize_t type_idx = type_string_pool_.indexOfString(type_name.data(), type_name.size());
- if (type_idx < 0) {
- return 0u;
+base::expected<uint32_t, NullOrIOError> LoadedPackage::FindEntryByName(
+ const std::u16string& type_name, const std::u16string& entry_name) const {
+ const base::expected<size_t, NullOrIOError> type_idx = type_string_pool_.indexOfString(
+ type_name.data(), type_name.size());
+ if (!type_idx.has_value()) {
+ return base::unexpected(type_idx.error());
}
- ssize_t key_idx = key_string_pool_.indexOfString(entry_name.data(), entry_name.size());
- if (key_idx < 0) {
- return 0u;
+ const base::expected<size_t, NullOrIOError> key_idx = key_string_pool_.indexOfString(
+ entry_name.data(), entry_name.size());
+ if (!key_idx.has_value()) {
+ return base::unexpected(key_idx.error());
}
- const TypeSpec* type_spec = type_specs_[type_idx].get();
+ const TypeSpec* type_spec = type_specs_[*type_idx].get();
if (type_spec == nullptr) {
- return 0u;
+ return base::unexpected(std::nullopt);
}
const auto iter_end = type_spec->types + type_spec->type_count;
for (auto iter = type_spec->types; iter != iter_end; ++iter) {
- const ResTable_type* type = *iter;
+ const incfs::verified_map_ptr<ResTable_type>& type = *iter;
+
size_t entry_count = dtohl(type->entryCount);
for (size_t entry_idx = 0; entry_idx < entry_count; entry_idx++) {
- const uint32_t* entry_offsets = reinterpret_cast<const uint32_t*>(
- reinterpret_cast<const uint8_t*>(type) + dtohs(type->header.headerSize));
- const uint32_t offset = dtohl(entry_offsets[entry_idx]);
+ auto entry_offset_ptr = type.offset(dtohs(type->header.headerSize)).convert<uint32_t>() +
+ entry_idx;
+ if (!entry_offset_ptr) {
+ return base::unexpected(IOError::PAGES_MISSING);
+ }
+
+ auto offset = dtohl(entry_offset_ptr.value());
if (offset != ResTable_type::NO_ENTRY) {
- const ResTable_entry* entry = reinterpret_cast<const ResTable_entry*>(
- reinterpret_cast<const uint8_t*>(type) + dtohl(type->entriesStart) + offset);
- if (dtohl(entry->key.index) == static_cast<uint32_t>(key_idx)) {
+ auto entry = type.offset(dtohl(type->entriesStart) + offset).convert<ResTable_entry>();
+ if (!entry) {
+ return base::unexpected(IOError::PAGES_MISSING);
+ }
+
+ if (dtohl(entry->key.index) == static_cast<uint32_t>(*key_idx)) {
// The package ID will be overridden by the caller (due to runtime assignment of package
// IDs for shared libraries).
- return make_resid(0x00, type_idx + type_id_offset_ + 1, entry_idx);
+ return make_resid(0x00, *type_idx + type_id_offset_ + 1, entry_idx);
}
}
}
}
- return 0u;
+ return base::unexpected(std::nullopt);
}
const LoadedPackage* LoadedArsc::GetPackageById(uint8_t package_id) const {
@@ -405,8 +451,8 @@
// was added.
constexpr size_t kMinPackageSize =
sizeof(ResTable_package) - sizeof(ResTable_package::typeIdOffset);
- const ResTable_package* header = chunk.header<ResTable_package, kMinPackageSize>();
- if (header == nullptr) {
+ const incfs::map_ptr<ResTable_package> header = chunk.header<ResTable_package, kMinPackageSize>();
+ if (!header) {
LOG(ERROR) << "RES_TABLE_PACKAGE_TYPE too small.";
return {};
}
@@ -453,10 +499,13 @@
const Chunk child_chunk = iter.Next();
switch (child_chunk.type()) {
case RES_STRING_POOL_TYPE: {
- const uintptr_t pool_address =
- reinterpret_cast<uintptr_t>(child_chunk.header<ResChunk_header>());
- const uintptr_t header_address = reinterpret_cast<uintptr_t>(header);
- if (pool_address == header_address + dtohl(header->typeStrings)) {
+ const auto pool_address = child_chunk.header<ResChunk_header>();
+ if (!pool_address) {
+ LOG(ERROR) << "RES_STRING_POOL_TYPE is incomplete due to incremental installation.";
+ return {};
+ }
+
+ if (pool_address == header.offset(dtohl(header->typeStrings)).convert<ResChunk_header>()) {
// This string pool is the type string pool.
status_t err = loaded_package->type_string_pool_.setTo(
child_chunk.header<ResStringPool_header>(), child_chunk.size());
@@ -464,7 +513,8 @@
LOG(ERROR) << "RES_STRING_POOL_TYPE for types corrupt.";
return {};
}
- } else if (pool_address == header_address + dtohl(header->keyStrings)) {
+ } else if (pool_address == header.offset(dtohl(header->keyStrings))
+ .convert<ResChunk_header>()) {
// This string pool is the key string pool.
status_t err = loaded_package->key_string_pool_.setTo(
child_chunk.header<ResStringPool_header>(), child_chunk.size());
@@ -478,8 +528,8 @@
} break;
case RES_TABLE_TYPE_SPEC_TYPE: {
- const ResTable_typeSpec* type_spec = child_chunk.header<ResTable_typeSpec>();
- if (type_spec == nullptr) {
+ const auto type_spec = child_chunk.header<ResTable_typeSpec>();
+ if (!type_spec) {
LOG(ERROR) << "RES_TABLE_TYPE_SPEC_TYPE too small.";
return {};
}
@@ -514,7 +564,7 @@
std::unique_ptr<TypeSpecPtrBuilder>& builder_ptr = type_builder_map[type_spec->id - 1];
if (builder_ptr == nullptr) {
- builder_ptr = util::make_unique<TypeSpecPtrBuilder>(type_spec);
+ builder_ptr = util::make_unique<TypeSpecPtrBuilder>(type_spec.verified());
loaded_package->resource_ids_.set(type_spec->id, entry_count);
} else {
LOG(WARNING) << StringPrintf("RES_TABLE_TYPE_SPEC_TYPE already defined for ID %02x",
@@ -523,8 +573,8 @@
} break;
case RES_TABLE_TYPE_TYPE: {
- const ResTable_type* type = child_chunk.header<ResTable_type, kResTableTypeMinSize>();
- if (type == nullptr) {
+ const auto type = child_chunk.header<ResTable_type, kResTableTypeMinSize>();
+ if (!type) {
LOG(ERROR) << "RES_TABLE_TYPE_TYPE too small.";
return {};
}
@@ -536,7 +586,7 @@
// Type chunks must be preceded by their TypeSpec chunks.
std::unique_ptr<TypeSpecPtrBuilder>& builder_ptr = type_builder_map[type->id - 1];
if (builder_ptr != nullptr) {
- builder_ptr->AddType(type);
+ builder_ptr->AddType(type.verified());
} else {
LOG(ERROR) << StringPrintf(
"RES_TABLE_TYPE_TYPE with ID %02x found without preceding RES_TABLE_TYPE_SPEC_TYPE.",
@@ -546,8 +596,8 @@
} break;
case RES_TABLE_LIBRARY_TYPE: {
- const ResTable_lib_header* lib = child_chunk.header<ResTable_lib_header>();
- if (lib == nullptr) {
+ const auto lib = child_chunk.header<ResTable_lib_header>();
+ if (!lib) {
LOG(ERROR) << "RES_TABLE_LIBRARY_TYPE too small.";
return {};
}
@@ -559,10 +609,13 @@
loaded_package->dynamic_package_map_.reserve(dtohl(lib->count));
- const ResTable_lib_entry* const entry_begin =
- reinterpret_cast<const ResTable_lib_entry*>(child_chunk.data_ptr());
- const ResTable_lib_entry* const entry_end = entry_begin + dtohl(lib->count);
+ const auto entry_begin = child_chunk.data_ptr().convert<ResTable_lib_entry>();
+ const auto entry_end = entry_begin + dtohl(lib->count);
for (auto entry_iter = entry_begin; entry_iter != entry_end; ++entry_iter) {
+ if (!entry_iter) {
+ return {};
+ }
+
std::string package_name;
util::ReadUtf16StringFromDevice(entry_iter->packageName,
arraysize(entry_iter->packageName), &package_name);
@@ -580,17 +633,16 @@
} break;
case RES_TABLE_OVERLAYABLE_TYPE: {
- const ResTable_overlayable_header* header =
- child_chunk.header<ResTable_overlayable_header>();
- if (header == nullptr) {
+ const auto overlayable = child_chunk.header<ResTable_overlayable_header>();
+ if (!overlayable) {
LOG(ERROR) << "RES_TABLE_OVERLAYABLE_TYPE too small.";
return {};
}
std::string name;
- util::ReadUtf16StringFromDevice(header->name, arraysize(header->name), &name);
+ util::ReadUtf16StringFromDevice(overlayable->name, arraysize(overlayable->name), &name);
std::string actor;
- util::ReadUtf16StringFromDevice(header->actor, arraysize(header->actor), &actor);
+ util::ReadUtf16StringFromDevice(overlayable->actor, arraysize(overlayable->actor), &actor);
if (loaded_package->overlayable_map_.find(name) !=
loaded_package->overlayable_map_.end()) {
@@ -606,9 +658,9 @@
switch (overlayable_child_chunk.type()) {
case RES_TABLE_OVERLAYABLE_POLICY_TYPE: {
- const ResTable_overlayable_policy_header* policy_header =
+ const auto policy_header =
overlayable_child_chunk.header<ResTable_overlayable_policy_header>();
- if (policy_header == nullptr) {
+ if (!policy_header) {
LOG(ERROR) << "RES_TABLE_OVERLAYABLE_POLICY_TYPE too small.";
return {};
}
@@ -621,10 +673,12 @@
// Retrieve all the resource ids belonging to this policy chunk
std::unordered_set<uint32_t> ids;
- const auto ids_begin =
- reinterpret_cast<const ResTable_ref*>(overlayable_child_chunk.data_ptr());
+ const auto ids_begin = overlayable_child_chunk.data_ptr().convert<ResTable_ref>();
const auto ids_end = ids_begin + dtohl(policy_header->entry_count);
for (auto id_iter = ids_begin; id_iter != ids_end; ++id_iter) {
+ if (!id_iter) {
+ return {};
+ }
ids.insert(dtohl(id_iter->ident));
}
@@ -633,7 +687,7 @@
overlayable_info.name = name;
overlayable_info.actor = actor;
overlayable_info.policy_flags = policy_header->policy_flags;
- loaded_package->overlayable_infos_.push_back(std::make_pair(overlayable_info, ids));
+ loaded_package->overlayable_infos_.emplace_back(overlayable_info, ids);
loaded_package->defines_overlayable_ = true;
break;
}
@@ -683,8 +737,8 @@
bool LoadedArsc::LoadTable(const Chunk& chunk, const LoadedIdmap* loaded_idmap,
package_property_t property_flags) {
- const ResTable_header* header = chunk.header<ResTable_header>();
- if (header == nullptr) {
+ incfs::map_ptr<ResTable_header> header = chunk.header<ResTable_header>();
+ if (!header) {
LOG(ERROR) << "RES_TABLE_TYPE too small.";
return false;
}
@@ -747,7 +801,8 @@
return true;
}
-std::unique_ptr<const LoadedArsc> LoadedArsc::Load(const StringPiece& data,
+std::unique_ptr<const LoadedArsc> LoadedArsc::Load(incfs::map_ptr<void> data,
+ const size_t length,
const LoadedIdmap* loaded_idmap,
const package_property_t property_flags) {
ATRACE_NAME("LoadedArsc::Load");
@@ -755,7 +810,7 @@
// Not using make_unique because the constructor is private.
std::unique_ptr<LoadedArsc> loaded_arsc(new LoadedArsc());
- ChunkIterator iter(data.data(), data.size());
+ ChunkIterator iter(data, length);
while (iter.HasNext()) {
const Chunk chunk = iter.Next();
switch (chunk.type()) {
diff --git a/libs/androidfw/ResourceTypes.cpp b/libs/androidfw/ResourceTypes.cpp
index dfb4009..4010e4e 100644
--- a/libs/androidfw/ResourceTypes.cpp
+++ b/libs/androidfw/ResourceTypes.cpp
@@ -104,22 +104,26 @@
*dst = 0;
}
-static status_t validate_chunk(const ResChunk_header* chunk,
+static status_t validate_chunk(const incfs::map_ptr<ResChunk_header>& chunk,
size_t minSize,
- const uint8_t* dataEnd,
+ const incfs::map_ptr<uint8_t> dataEnd,
const char* name)
{
+ if (!chunk) {
+ return BAD_TYPE;
+ }
+
const uint16_t headerSize = dtohs(chunk->headerSize);
const uint32_t size = dtohl(chunk->size);
if (headerSize >= minSize) {
if (headerSize <= size) {
if (((headerSize|size)&0x3) == 0) {
- if ((size_t)size <= (size_t)(dataEnd-((const uint8_t*)chunk))) {
+ if ((size_t)size <= (size_t)(dataEnd-chunk.convert<uint8_t>())) {
return NO_ERROR;
}
ALOGW("%s data size 0x%x extends beyond resource end %p.",
- name, size, (void*)(dataEnd-((const uint8_t*)chunk)));
+ name, size, (void*)(dataEnd-chunk.convert<uint8_t>()));
return BAD_TYPE;
}
ALOGW("%s size 0x%x or headerSize 0x%x is not on an integer boundary.",
@@ -450,7 +454,7 @@
mHeader = (const ResStringPool_header*) header;
}
-status_t ResStringPool::setTo(const void* data, size_t size, bool copyData)
+status_t ResStringPool::setTo(incfs::map_ptr<void> data, size_t size, bool copyData)
{
if (!data || !size) {
return (mError=BAD_TYPE);
@@ -467,8 +471,8 @@
// The data is at least as big as a ResChunk_header, so we can safely validate the other
// header fields.
// `data + size` is safe because the source of `size` comes from the kernel/filesystem.
- if (validate_chunk(reinterpret_cast<const ResChunk_header*>(data), sizeof(ResStringPool_header),
- reinterpret_cast<const uint8_t*>(data) + size,
+ const auto chunk_header = data.convert<ResChunk_header>();
+ if (validate_chunk(chunk_header, sizeof(ResStringPool_header), data.convert<uint8_t>() + size,
"ResStringPool_header") != NO_ERROR) {
ALOGW("Bad string block: malformed block dimensions");
return (mError=BAD_TYPE);
@@ -481,16 +485,25 @@
if (mOwnedData == NULL) {
return (mError=NO_MEMORY);
}
- memcpy(mOwnedData, data, size);
+
+ if (!data.convert<uint8_t>().verify(size)) {
+ return (mError=NO_MEMORY);
+ }
+
+ memcpy(mOwnedData, data.unsafe_ptr(), size);
data = mOwnedData;
}
// The size has been checked, so it is safe to read the data in the ResStringPool_header
// data structure.
- mHeader = (const ResStringPool_header*)data;
+ const auto header = data.convert<ResStringPool_header>();
+ if (!header) {
+ return (mError=BAD_TYPE);
+ }
+ mHeader = header.verified();
if (notDeviceEndian) {
- ResStringPool_header* h = const_cast<ResStringPool_header*>(mHeader);
+ ResStringPool_header* h = const_cast<ResStringPool_header*>(mHeader.unsafe_ptr());
h->header.headerSize = dtohs(mHeader->header.headerSize);
h->header.type = dtohs(mHeader->header.type);
h->header.size = dtohl(mHeader->header.size);
@@ -508,8 +521,7 @@
return (mError=BAD_TYPE);
}
mSize = mHeader->header.size;
- mEntries = (const uint32_t*)
- (((const uint8_t*)data)+mHeader->header.headerSize);
+ mEntries = data.offset(mHeader->header.headerSize).convert<uint32_t>();
if (mHeader->stringCount > 0) {
if ((mHeader->stringCount*sizeof(uint32_t) < mHeader->stringCount) // uint32 overflow?
@@ -536,9 +548,7 @@
return (mError=BAD_TYPE);
}
- mStrings = (const void*)
- (((const uint8_t*)data) + mHeader->stringsStart);
-
+ mStrings = data.offset(mHeader->stringsStart).convert<void>();
if (mHeader->styleCount == 0) {
mStringPoolSize = (mSize - mHeader->stringsStart) / charSize;
} else {
@@ -560,31 +570,37 @@
// check invariant: stringCount > 0 requires a string pool to exist
if (mStringPoolSize == 0) {
- ALOGW("Bad string block: stringCount is %d but pool size is 0\n", (int)mHeader->stringCount);
+ ALOGW("Bad string block: stringCount is %d but pool size is 0\n",
+ (int)mHeader->stringCount);
return (mError=BAD_TYPE);
}
if (notDeviceEndian) {
size_t i;
- uint32_t* e = const_cast<uint32_t*>(mEntries);
+ auto e = const_cast<uint32_t*>(mEntries.unsafe_ptr());
for (i=0; i<mHeader->stringCount; i++) {
- e[i] = dtohl(mEntries[i]);
+ e[i] = dtohl(e[i]);
}
if (!(mHeader->flags&ResStringPool_header::UTF8_FLAG)) {
- const uint16_t* strings = (const uint16_t*)mStrings;
- uint16_t* s = const_cast<uint16_t*>(strings);
+ uint16_t* s = const_cast<uint16_t*>(mStrings.convert<uint16_t>().unsafe_ptr());
for (i=0; i<mStringPoolSize; i++) {
- s[i] = dtohs(strings[i]);
+ s[i] = dtohs(s[i]);
}
}
}
- if ((mHeader->flags&ResStringPool_header::UTF8_FLAG &&
- ((uint8_t*)mStrings)[mStringPoolSize-1] != 0) ||
- (!(mHeader->flags&ResStringPool_header::UTF8_FLAG) &&
- ((uint16_t*)mStrings)[mStringPoolSize-1] != 0)) {
- ALOGW("Bad string block: last string is not 0-terminated\n");
- return (mError=BAD_TYPE);
+ if (mHeader->flags&ResStringPool_header::UTF8_FLAG) {
+ auto end = mStrings.convert<uint8_t>() + (mStringPoolSize-1);
+ if (!end || end.value() != 0) {
+ ALOGW("Bad string block: last string is not 0-terminated\n");
+ return (mError=BAD_TYPE);
+ }
+ } else {
+ auto end = mStrings.convert<uint16_t>() + (mStringPoolSize-1);
+ if (!end || end.value() != 0) {
+ ALOGW("Bad string block: last string is not 0-terminated\n");
+ return (mError=BAD_TYPE);
+ }
}
} else {
mStrings = NULL;
@@ -599,14 +615,13 @@
return (mError=BAD_TYPE);
}
- if (((const uint8_t*)mEntryStyles-(const uint8_t*)mHeader) > (int)size) {
+ if ((mEntryStyles.convert<uint8_t>() - mHeader.convert<uint8_t>()) > (int)size) {
ALOGW("Bad string block: entry of %d styles extends past data size %d\n",
- (int)((const uint8_t*)mEntryStyles-(const uint8_t*)mHeader),
+ (int)(mEntryStyles.convert<uint8_t>()-mHeader.convert<uint8_t>()),
(int)size);
return (mError=BAD_TYPE);
}
- mStyles = (const uint32_t*)
- (((const uint8_t*)data)+mHeader->stylesStart);
+ mStyles = data.offset(mHeader->stylesStart).convert<uint32_t>();
if (mHeader->stylesStart >= mHeader->header.size) {
ALOGW("Bad string block: style pool starts %d, after total size %d\n",
(int)mHeader->stylesStart, (int)mHeader->header.size);
@@ -617,13 +632,13 @@
if (notDeviceEndian) {
size_t i;
- uint32_t* e = const_cast<uint32_t*>(mEntryStyles);
+ uint32_t* e = const_cast<uint32_t*>(mEntryStyles.unsafe_ptr());
for (i=0; i<mHeader->styleCount; i++) {
- e[i] = dtohl(mEntryStyles[i]);
+ e[i] = dtohl(e[i]);
}
- uint32_t* s = const_cast<uint32_t*>(mStyles);
+ uint32_t* s = const_cast<uint32_t*>(mStyles.unsafe_ptr());
for (i=0; i<mStylePoolSize; i++) {
- s[i] = dtohl(mStyles[i]);
+ s[i] = dtohl(s[i]);
}
}
@@ -631,8 +646,9 @@
{ htodl(ResStringPool_span::END) },
htodl(ResStringPool_span::END), htodl(ResStringPool_span::END)
};
- if (memcmp(&mStyles[mStylePoolSize-(sizeof(endSpan)/sizeof(uint32_t))],
- &endSpan, sizeof(endSpan)) != 0) {
+
+ auto stylesEnd = mStyles + (mStylePoolSize-(sizeof(endSpan)/sizeof(uint32_t)));
+ if (!stylesEnd || memcmp(stylesEnd.unsafe_ptr(), &endSpan, sizeof(endSpan)) != 0) {
ALOGW("Bad string block: last style is not 0xFFFFFFFF-terminated\n");
return (mError=BAD_TYPE);
}
@@ -653,7 +669,7 @@
void ResStringPool::uninit()
{
mError = NO_INIT;
- if (mHeader != NULL && mCache != NULL) {
+ if (mHeader && mCache != NULL) {
for (size_t x = 0; x < mHeader->stringCount; x++) {
if (mCache[x] != NULL) {
free(mCache[x]);
@@ -679,15 +695,21 @@
* data encoded. In that case, drop the high bit of the first character and
* add it together with the next character.
*/
-static inline size_t
-decodeLength(const uint16_t** str)
+static inline base::expected<size_t, IOError> decodeLength(incfs::map_ptr<uint16_t>* str)
{
- size_t len = **str;
- if ((len & 0x8000) != 0) {
- (*str)++;
- len = ((len & 0x7FFF) << 16) | **str;
+ if (UNLIKELY(!*str)) {
+ return base::unexpected(IOError::PAGES_MISSING);
}
- (*str)++;
+
+ size_t len = str->value();
+ if ((len & 0x8000U) != 0) {
+ ++(*str);
+ if (UNLIKELY(!*str)) {
+ return base::unexpected(IOError::PAGES_MISSING);
+ }
+ len = ((len & 0x7FFFU) << 16U) | str->value();
+ }
+ ++(*str);
return len;
}
@@ -701,82 +723,119 @@
* data encoded. In that case, drop the high bit of the first character and
* add it together with the next character.
*/
-static inline size_t
-decodeLength(const uint8_t** str)
+static inline base::expected<size_t, IOError> decodeLength(incfs::map_ptr<uint8_t>* str)
{
- size_t len = **str;
- if ((len & 0x80) != 0) {
- (*str)++;
- len = ((len & 0x7F) << 8) | **str;
+ if (UNLIKELY(!*str)) {
+ return base::unexpected(IOError::PAGES_MISSING);
}
- (*str)++;
+
+ size_t len = str->value();
+ if ((len & 0x80U) != 0) {
+ ++(*str);
+ if (UNLIKELY(!*str)) {
+ return base::unexpected(IOError::PAGES_MISSING);
+ }
+ len = ((len & 0x7FU) << 8U) | str->value();
+ }
+ ++(*str);
return len;
}
-const char16_t* ResStringPool::stringAt(size_t idx, size_t* u16len) const
+base::expected<StringPiece16, NullOrIOError> ResStringPool::stringAt(size_t idx) const
{
if (mError == NO_ERROR && idx < mHeader->stringCount) {
const bool isUTF8 = (mHeader->flags&ResStringPool_header::UTF8_FLAG) != 0;
- const uint32_t off = mEntries[idx]/(isUTF8?sizeof(uint8_t):sizeof(uint16_t));
+ auto offPtr = mEntries + idx;
+ if (UNLIKELY(!offPtr)) {
+ return base::unexpected(IOError::PAGES_MISSING);
+ }
+
+ const uint32_t off = (offPtr.value())/(isUTF8?sizeof(uint8_t):sizeof(uint16_t));
if (off < (mStringPoolSize-1)) {
if (!isUTF8) {
- const uint16_t* strings = (uint16_t*)mStrings;
- const uint16_t* str = strings+off;
+ auto strings = mStrings.convert<uint16_t>();
+ auto str = strings+off;
- *u16len = decodeLength(&str);
+ const base::expected<size_t, IOError> u16len = decodeLength(&str);
+ if (UNLIKELY(!u16len.has_value())) {
+ return base::unexpected(u16len.error());
+ }
+
if ((uint32_t)(str+*u16len-strings) < mStringPoolSize) {
// Reject malformed (non null-terminated) strings
- if (str[*u16len] != 0x0000) {
- ALOGW("Bad string block: string #%d is not null-terminated",
- (int)idx);
- return NULL;
+ const auto nullAddress = str + (*u16len);
+ if (UNLIKELY(!nullAddress)) {
+ return base::unexpected(IOError::PAGES_MISSING);
}
- return reinterpret_cast<const char16_t*>(str);
+
+ if (nullAddress.value() != 0x0000) {
+ ALOGW("Bad string block: string #%d is not null-terminated", (int)idx);
+ return base::unexpected(std::nullopt);
+ }
+
+ if (UNLIKELY(!str.verify(*u16len + 1U))) {
+ return base::unexpected(IOError::PAGES_MISSING);
+ }
+
+ return StringPiece16(reinterpret_cast<const char16_t*>(str.unsafe_ptr()),
+ *u16len);
} else {
ALOGW("Bad string block: string #%d extends to %d, past end at %d\n",
(int)idx, (int)(str+*u16len-strings), (int)mStringPoolSize);
}
} else {
- const uint8_t* strings = (uint8_t*)mStrings;
- const uint8_t* u8str = strings+off;
+ auto strings = mStrings.convert<uint8_t>();
+ auto u8str = strings+off;
- *u16len = decodeLength(&u8str);
- size_t u8len = decodeLength(&u8str);
+ base::expected<size_t, IOError> u16len = decodeLength(&u8str);
+ if (UNLIKELY(!u16len.has_value())) {
+ return base::unexpected(u16len.error());
+ }
+
+ const base::expected<size_t, IOError> u8len = decodeLength(&u8str);
+ if (UNLIKELY(!u8len.has_value())) {
+ return base::unexpected(u8len.error());
+ }
// encLen must be less than 0x7FFF due to encoding.
- if ((uint32_t)(u8str+u8len-strings) < mStringPoolSize) {
+ if ((uint32_t)(u8str+*u8len-strings) < mStringPoolSize) {
AutoMutex lock(mDecodeLock);
if (mCache != NULL && mCache[idx] != NULL) {
- return mCache[idx];
+ return StringPiece16(mCache[idx], *u16len);
}
// Retrieve the actual length of the utf8 string if the
// encoded length was truncated
- if (stringDecodeAt(idx, u8str, u8len, &u8len) == NULL) {
- return NULL;
+ auto decodedString = stringDecodeAt(idx, u8str, *u8len);
+ if (!decodedString.has_value()) {
+ return base::unexpected(decodedString.error());
}
// Since AAPT truncated lengths longer than 0x7FFF, check
// that the bits that remain after truncation at least match
// the bits of the actual length
- ssize_t actualLen = utf8_to_utf16_length(u8str, u8len);
- if (actualLen < 0 || ((size_t)actualLen & 0x7FFF) != *u16len) {
+ ssize_t actualLen = utf8_to_utf16_length(
+ reinterpret_cast<const uint8_t*>(decodedString->data()),
+ decodedString->size());
+
+ if (actualLen < 0 || ((size_t)actualLen & 0x7FFFU) != *u16len) {
ALOGW("Bad string block: string #%lld decoded length is not correct "
"%lld vs %llu\n",
(long long)idx, (long long)actualLen, (long long)*u16len);
- return NULL;
+ return base::unexpected(std::nullopt);
}
- *u16len = (size_t) actualLen;
- char16_t *u16str = (char16_t *)calloc(*u16len+1, sizeof(char16_t));
+ u16len = (size_t) actualLen;
+ auto u16str = (char16_t *)calloc(*u16len+1, sizeof(char16_t));
if (!u16str) {
ALOGW("No memory when trying to allocate decode cache for string #%d\n",
(int)idx);
- return NULL;
+ return base::unexpected(std::nullopt);
}
- utf8_to_utf16(u8str, u8len, u16str, *u16len + 1);
+ utf8_to_utf16(reinterpret_cast<const uint8_t*>(decodedString->data()),
+ decodedString->size(), u16str, *u16len + 1);
if (mCache == NULL) {
#ifndef __ANDROID__
@@ -793,19 +852,19 @@
if (mCache == NULL) {
ALOGW("No memory trying to allocate decode cache table of %d bytes\n",
(int)(mHeader->stringCount*sizeof(char16_t**)));
- return NULL;
+ return base::unexpected(std::nullopt);
}
}
if (kDebugStringPoolNoisy) {
- ALOGI("Caching UTF8 string: %s", u8str);
+ ALOGI("Caching UTF8 string: %s", u8str.unsafe_ptr());
}
mCache[idx] = u16str;
- return u16str;
+ return StringPiece16(u16str, *u16len);
} else {
ALOGW("Bad string block: string #%lld extends to %lld, past end at %lld\n",
- (long long)idx, (long long)(u8str+u8len-strings),
+ (long long)idx, (long long)(u8str+*u8len-strings),
(long long)mStringPoolSize);
}
}
@@ -815,33 +874,43 @@
(int)(mStringPoolSize*sizeof(uint16_t)));
}
}
- return NULL;
+ return base::unexpected(std::nullopt);
}
-const char* ResStringPool::string8At(size_t idx, size_t* outLen) const
+base::expected<StringPiece, NullOrIOError> ResStringPool::string8At(size_t idx) const
{
if (mError == NO_ERROR && idx < mHeader->stringCount) {
if ((mHeader->flags&ResStringPool_header::UTF8_FLAG) == 0) {
- return NULL;
+ return base::unexpected(std::nullopt);
}
- const uint32_t off = mEntries[idx]/sizeof(char);
+
+ auto offPtr = mEntries + idx;
+ if (UNLIKELY(!offPtr)) {
+ return base::unexpected(IOError::PAGES_MISSING);
+ }
+
+ const uint32_t off = (offPtr.value())/sizeof(char);
if (off < (mStringPoolSize-1)) {
- const uint8_t* strings = (uint8_t*)mStrings;
- const uint8_t* str = strings+off;
+ auto strings = mStrings.convert<uint8_t>();
+ auto str = strings+off;
// Decode the UTF-16 length. This is not used if we're not
// converting to UTF-16 from UTF-8.
- decodeLength(&str);
+ const base::expected<size_t, IOError> u16len = decodeLength(&str);
+ if (UNLIKELY(!u16len)) {
+ return base::unexpected(u16len.error());
+ }
- const size_t encLen = decodeLength(&str);
- *outLen = encLen;
+ const base::expected<size_t, IOError> u8len = decodeLength(&str);
+ if (UNLIKELY(!u8len)) {
+ return base::unexpected(u8len.error());
+ }
- if ((uint32_t)(str+encLen-strings) < mStringPoolSize) {
- return stringDecodeAt(idx, str, encLen, outLen);
-
+ if ((uint32_t)(str+*u8len-strings) < mStringPoolSize) {
+ return stringDecodeAt(idx, str, *u8len);
} else {
ALOGW("Bad string block: string #%d extends to %d, past end at %d\n",
- (int)idx, (int)(str+encLen-strings), (int)mStringPoolSize);
+ (int)idx, (int)(str+*u8len-strings), (int)mStringPoolSize);
}
} else {
ALOGW("Bad string block: string #%d entry is at %d, past end at %d\n",
@@ -849,7 +918,7 @@
(int)(mStringPoolSize*sizeof(uint16_t)));
}
}
- return NULL;
+ return base::unexpected(std::nullopt);
}
/**
@@ -859,74 +928,93 @@
* bits. Strings that exceed the maximum encode length are not placed into
* StringPools in AAPT2.
**/
-const char* ResStringPool::stringDecodeAt(size_t idx, const uint8_t* str,
- const size_t encLen, size_t* outLen) const {
- const uint8_t* strings = (uint8_t*)mStrings;
-
+base::expected<StringPiece, NullOrIOError> ResStringPool::stringDecodeAt(
+ size_t idx, incfs::map_ptr<uint8_t> str, size_t encLen) const
+{
+ const auto strings = mStrings.convert<uint8_t>();
size_t i = 0, end = encLen;
while ((uint32_t)(str+end-strings) < mStringPoolSize) {
- if (str[end] == 0x00) {
+ const auto nullAddress = str + end;
+ if (UNLIKELY(!nullAddress)) {
+ return base::unexpected(IOError::PAGES_MISSING);
+ }
+
+ if (nullAddress.value() == 0x00) {
if (i != 0) {
ALOGW("Bad string block: string #%d is truncated (actual length is %d)",
(int)idx, (int)end);
}
- *outLen = end;
- return (const char*)str;
+ if (UNLIKELY(!str.verify(end + 1U))) {
+ return base::unexpected(IOError::PAGES_MISSING);
+ }
+
+ return StringPiece((const char*) str.unsafe_ptr(), end);
}
end = (++i << (sizeof(uint8_t) * 8 * 2 - 1)) | encLen;
}
// Reject malformed (non null-terminated) strings
- ALOGW("Bad string block: string #%d is not null-terminated",
- (int)idx);
- return NULL;
+ ALOGW("Bad string block: string #%d is not null-terminated", (int)idx);
+ return base::unexpected(std::nullopt);
}
-const String8 ResStringPool::string8ObjectAt(size_t idx) const
+base::expected<String8, IOError> ResStringPool::string8ObjectAt(size_t idx) const
{
- size_t len;
- const char *str = string8At(idx, &len);
- if (str != NULL) {
- return String8(str, len);
+ const base::expected<StringPiece, NullOrIOError> str = string8At(idx);
+ if (UNLIKELY(IsIOError(str))) {
+ return base::unexpected(GetIOError(str.error()));
+ }
+ if (str.has_value()) {
+ return String8(str->data(), str->size());
}
- const char16_t *str16 = stringAt(idx, &len);
- if (str16 != NULL) {
- return String8(str16, len);
+ const base::expected<StringPiece16, NullOrIOError> str16 = stringAt(idx);
+ if (UNLIKELY(IsIOError(str16))) {
+ return base::unexpected(GetIOError(str16.error()));
}
+ if (str16.has_value()) {
+ return String8(str16->data(), str16->size());
+ }
+
return String8();
}
-const ResStringPool_span* ResStringPool::styleAt(const ResStringPool_ref& ref) const
+base::expected<incfs::map_ptr<ResStringPool_span>, NullOrIOError> ResStringPool::styleAt(
+ const ResStringPool_ref& ref) const
{
return styleAt(ref.index);
}
-const ResStringPool_span* ResStringPool::styleAt(size_t idx) const
+base::expected<incfs::map_ptr<ResStringPool_span>, NullOrIOError> ResStringPool::styleAt(
+ size_t idx) const
{
if (mError == NO_ERROR && idx < mHeader->styleCount) {
- const uint32_t off = (mEntryStyles[idx]/sizeof(uint32_t));
+ auto offPtr = mEntryStyles + idx;
+ if (UNLIKELY(!offPtr)) {
+ return base::unexpected(IOError::PAGES_MISSING);
+ }
+
+ const uint32_t off = ((offPtr.value())/sizeof(uint32_t));
if (off < mStylePoolSize) {
- return (const ResStringPool_span*)(mStyles+off);
+ return (mStyles+off).convert<ResStringPool_span>();
} else {
ALOGW("Bad string block: style #%d entry is at %d, past end at %d\n",
(int)idx, (int)(off*sizeof(uint32_t)),
(int)(mStylePoolSize*sizeof(uint32_t)));
}
}
- return NULL;
+ return base::unexpected(std::nullopt);
}
-ssize_t ResStringPool::indexOfString(const char16_t* str, size_t strLen) const
+base::expected<size_t, NullOrIOError> ResStringPool::indexOfString(const char16_t* str,
+ size_t strLen) const
{
if (mError != NO_ERROR) {
- return mError;
+ return base::unexpected(std::nullopt);
}
- size_t len;
-
if ((mHeader->flags&ResStringPool_header::UTF8_FLAG) != 0) {
if (kDebugStringPoolNoisy) {
ALOGI("indexOfString UTF-8: %s", String8(str, strLen).string());
@@ -948,17 +1036,19 @@
ssize_t mid;
while (l <= h) {
mid = l + (h - l)/2;
- const uint8_t* s = (const uint8_t*)string8At(mid, &len);
- int c;
- if (s != NULL) {
- char16_t* end = utf8_to_utf16(s, len, convBuffer, convBufferLen);
+ int c = -1;
+ const base::expected<StringPiece, NullOrIOError> s = string8At(mid);
+ if (UNLIKELY(IsIOError(s))) {
+ return base::unexpected(s.error());
+ }
+ if (s.has_value()) {
+ char16_t* end = utf8_to_utf16(reinterpret_cast<const uint8_t*>(s->data()),
+ s->size(), convBuffer, convBufferLen);
c = strzcmp16(convBuffer, end-convBuffer, str, strLen);
- } else {
- c = -1;
}
if (kDebugStringPoolNoisy) {
ALOGI("Looking at %s, cmp=%d, l/mid/h=%d/%d/%d\n",
- (const char*)s, c, (int)l, (int)mid, (int)h);
+ s->data(), c, (int)l, (int)mid, (int)h);
}
if (c == 0) {
if (kDebugStringPoolNoisy) {
@@ -981,15 +1071,21 @@
String8 str8(str, strLen);
const size_t str8Len = str8.size();
for (int i=mHeader->stringCount-1; i>=0; i--) {
- const char* s = string8At(i, &len);
- if (kDebugStringPoolNoisy) {
- ALOGI("Looking at %s, i=%d\n", String8(s).string(), i);
+ const base::expected<StringPiece, NullOrIOError> s = string8At(i);
+ if (UNLIKELY(IsIOError(s))) {
+ return base::unexpected(s.error());
}
- if (s && str8Len == len && memcmp(s, str8.string(), str8Len) == 0) {
+ if (s.has_value()) {
if (kDebugStringPoolNoisy) {
- ALOGI("MATCH!");
+ ALOGI("Looking at %s, i=%d\n", s->data(), i);
}
- return i;
+ if (str8Len == s->size()
+ && memcmp(s->data(), str8.string(), str8Len) == 0) {
+ if (kDebugStringPoolNoisy) {
+ ALOGI("MATCH!");
+ }
+ return i;
+ }
}
}
}
@@ -1007,11 +1103,14 @@
ssize_t mid;
while (l <= h) {
mid = l + (h - l)/2;
- const char16_t* s = stringAt(mid, &len);
- int c = s ? strzcmp16(s, len, str, strLen) : -1;
+ const base::expected<StringPiece16, NullOrIOError> s = stringAt(mid);
+ if (UNLIKELY(IsIOError(s))) {
+ return base::unexpected(s.error());
+ }
+ int c = s.has_value() ? strzcmp16(s->data(), s->size(), str, strLen) : -1;
if (kDebugStringPoolNoisy) {
ALOGI("Looking at %s, cmp=%d, l/mid/h=%d/%d/%d\n",
- String8(s).string(), c, (int)l, (int)mid, (int)h);
+ String8(s->data(), s->size()).string(), c, (int)l, (int)mid, (int)h);
}
if (c == 0) {
if (kDebugStringPoolNoisy) {
@@ -1030,11 +1129,15 @@
// span tags; since those always appear at the end of the string
// block, start searching at the back.
for (int i=mHeader->stringCount-1; i>=0; i--) {
- const char16_t* s = stringAt(i, &len);
- if (kDebugStringPoolNoisy) {
- ALOGI("Looking at %s, i=%d\n", String8(s).string(), i);
+ const base::expected<StringPiece16, NullOrIOError> s = stringAt(i);
+ if (UNLIKELY(IsIOError(s))) {
+ return base::unexpected(s.error());
}
- if (s && strLen == len && strzcmp16(s, len, str, strLen) == 0) {
+ if (kDebugStringPoolNoisy) {
+ ALOGI("Looking at %s, i=%d\n", String8(s->data(), s->size()).string(), i);
+ }
+ if (s.has_value() && strLen == s->size() &&
+ strzcmp16(s->data(), s->size(), str, strLen) == 0) {
if (kDebugStringPoolNoisy) {
ALOGI("MATCH!");
}
@@ -1043,8 +1146,7 @@
}
}
}
-
- return NAME_NOT_FOUND;
+ return base::unexpected(std::nullopt);
}
size_t ResStringPool::size() const
@@ -1062,9 +1164,10 @@
return (mError == NO_ERROR) ? mHeader->header.size : 0;
}
-const void* ResStringPool::data() const
+incfs::map_ptr<void> ResStringPool::data() const
{
- return mHeader;
+
+ return mHeader.unsafe_ptr();
}
bool ResStringPool::isSorted() const
@@ -1121,7 +1224,7 @@
const char16_t* ResXMLParser::getComment(size_t* outLen) const
{
int32_t id = getCommentID();
- return id >= 0 ? mTree.mStrings.stringAt(id, outLen) : NULL;
+ return id >= 0 ? UnpackOptionalString(mTree.mStrings.stringAt(id), outLen) : NULL;
}
uint32_t ResXMLParser::getLineNumber() const
@@ -1140,7 +1243,7 @@
const char16_t* ResXMLParser::getText(size_t* outLen) const
{
int32_t id = getTextID();
- return id >= 0 ? mTree.mStrings.stringAt(id, outLen) : NULL;
+ return id >= 0 ? UnpackOptionalString(mTree.mStrings.stringAt(id), outLen) : NULL;
}
ssize_t ResXMLParser::getTextValue(Res_value* outValue) const
@@ -1164,7 +1267,7 @@
{
int32_t id = getNamespacePrefixID();
//printf("prefix=%d event=%p\n", id, mEventCode);
- return id >= 0 ? mTree.mStrings.stringAt(id, outLen) : NULL;
+ return id >= 0 ? UnpackOptionalString(mTree.mStrings.stringAt(id), outLen) : NULL;
}
int32_t ResXMLParser::getNamespaceUriID() const
@@ -1179,7 +1282,7 @@
{
int32_t id = getNamespaceUriID();
//printf("uri=%d event=%p\n", id, mEventCode);
- return id >= 0 ? mTree.mStrings.stringAt(id, outLen) : NULL;
+ return id >= 0 ? UnpackOptionalString(mTree.mStrings.stringAt(id), outLen) : NULL;
}
int32_t ResXMLParser::getElementNamespaceID() const
@@ -1196,7 +1299,7 @@
const char16_t* ResXMLParser::getElementNamespace(size_t* outLen) const
{
int32_t id = getElementNamespaceID();
- return id >= 0 ? mTree.mStrings.stringAt(id, outLen) : NULL;
+ return id >= 0 ? UnpackOptionalString(mTree.mStrings.stringAt(id), outLen) : NULL;
}
int32_t ResXMLParser::getElementNameID() const
@@ -1213,7 +1316,7 @@
const char16_t* ResXMLParser::getElementName(size_t* outLen) const
{
int32_t id = getElementNameID();
- return id >= 0 ? mTree.mStrings.stringAt(id, outLen) : NULL;
+ return id >= 0 ? UnpackOptionalString(mTree.mStrings.stringAt(id), outLen) : NULL;
}
size_t ResXMLParser::getAttributeCount() const
@@ -1246,7 +1349,7 @@
if (kDebugXMLNoisy) {
printf("getAttributeNamespace 0x%zx=0x%x\n", idx, id);
}
- return id >= 0 ? mTree.mStrings.stringAt(id, outLen) : NULL;
+ return id >= 0 ? UnpackOptionalString(mTree.mStrings.stringAt(id), outLen) : NULL;
}
const char* ResXMLParser::getAttributeNamespace8(size_t idx, size_t* outLen) const
@@ -1256,7 +1359,7 @@
if (kDebugXMLNoisy) {
printf("getAttributeNamespace 0x%zx=0x%x\n", idx, id);
}
- return id >= 0 ? mTree.mStrings.string8At(id, outLen) : NULL;
+ return id >= 0 ? UnpackOptionalString(mTree.mStrings.string8At(id), outLen) : NULL;
}
int32_t ResXMLParser::getAttributeNameID(size_t idx) const
@@ -1281,7 +1384,7 @@
if (kDebugXMLNoisy) {
printf("getAttributeName 0x%zx=0x%x\n", idx, id);
}
- return id >= 0 ? mTree.mStrings.stringAt(id, outLen) : NULL;
+ return id >= 0 ? UnpackOptionalString(mTree.mStrings.stringAt(id), outLen) : NULL;
}
const char* ResXMLParser::getAttributeName8(size_t idx, size_t* outLen) const
@@ -1291,7 +1394,7 @@
if (kDebugXMLNoisy) {
printf("getAttributeName 0x%zx=0x%x\n", idx, id);
}
- return id >= 0 ? mTree.mStrings.string8At(id, outLen) : NULL;
+ return id >= 0 ? UnpackOptionalString(mTree.mStrings.string8At(id), outLen) : NULL;
}
uint32_t ResXMLParser::getAttributeNameResID(size_t idx) const
@@ -1328,7 +1431,7 @@
if (kDebugXMLNoisy) {
printf("getAttributeValue 0x%zx=0x%x\n", idx, id);
}
- return id >= 0 ? mTree.mStrings.stringAt(id, outLen) : NULL;
+ return id >= 0 ? UnpackOptionalString(mTree.mStrings.stringAt(id), outLen) : NULL;
}
int32_t ResXMLParser::getAttributeDataType(size_t idx) const
@@ -3596,9 +3699,10 @@
ssize_t findType16(const char16_t* type, size_t len) const {
const size_t N = packages.size();
for (size_t i = 0; i < N; i++) {
- ssize_t index = packages[i]->typeStrings.indexOfString(type, len);
- if (index >= 0) {
- return index + packages[i]->typeIdOffset;
+ const base::expected<size_t, NullOrIOError> index =
+ packages[i]->typeStrings.indexOfString(type, len);
+ if (index.has_value()) {
+ return *index + packages[i]->typeIdOffset;
}
}
return -1;
@@ -4304,21 +4408,21 @@
outName->package = grp->name.string();
outName->packageLen = grp->name.size();
if (allowUtf8) {
- outName->type8 = entry.typeStr.string8(&outName->typeLen);
- outName->name8 = entry.keyStr.string8(&outName->nameLen);
+ outName->type8 = UnpackOptionalString(entry.typeStr.string8(), &outName->typeLen);
+ outName->name8 = UnpackOptionalString(entry.keyStr.string8(), &outName->nameLen);
} else {
outName->type8 = NULL;
outName->name8 = NULL;
}
if (outName->type8 == NULL) {
- outName->type = entry.typeStr.string16(&outName->typeLen);
+ outName->type = UnpackOptionalString(entry.typeStr.string16(), &outName->typeLen);
// If we have a bad index for some reason, we should abort.
if (outName->type == NULL) {
return false;
}
}
if (outName->name8 == NULL) {
- outName->name = entry.keyStr.string16(&outName->nameLen);
+ outName->name = UnpackOptionalString(entry.keyStr.string16(), &outName->nameLen);
// If we have a bad index for some reason, we should abort.
if (outName->name == NULL) {
return false;
@@ -4406,7 +4510,8 @@
entry.package->header->index,
outValue->dataType,
outValue->dataType == Res_value::TYPE_STRING ?
- String8(entry.package->header->values.stringAt(outValue->data, &len)).string() :
+ String8(UnpackOptionalString(
+ entry.package->header->values.stringAt(outValue->data), &len)).string() :
"",
outValue->data);
}
@@ -4462,7 +4567,8 @@
return NULL;
}
if (value->dataType == value->TYPE_STRING) {
- return getTableStringBlock(stringBlock)->stringAt(value->data, outLen);
+ return UnpackOptionalString(getTableStringBlock(stringBlock)->stringAt(value->data),
+ outLen);
}
// XXX do int to string conversions.
return NULL;
@@ -4978,15 +5084,13 @@
size_t targetTypeLen = typeLen;
do {
- ssize_t ti = group->packages[pi]->typeStrings.indexOfString(
- targetType, targetTypeLen);
- if (ti < 0) {
+ auto ti = group->packages[pi]->typeStrings.indexOfString(targetType, targetTypeLen);
+ if (!ti.has_value()) {
continue;
}
- ti += group->packages[pi]->typeIdOffset;
-
- const uint32_t identifier = findEntry(group, ti, name, nameLen,
+ *ti += group->packages[pi]->typeIdOffset;
+ const uint32_t identifier = findEntry(group, *ti, name, nameLen,
outTypeSpecFlags);
if (identifier != 0) {
if (fakePublic && outTypeSpecFlags) {
@@ -5009,8 +5113,9 @@
const size_t typeCount = typeList.size();
for (size_t i = 0; i < typeCount; i++) {
const Type* t = typeList[i];
- const ssize_t ei = t->package->keyStrings.indexOfString(name, nameLen);
- if (ei < 0) {
+ const base::expected<size_t, NullOrIOError> ei =
+ t->package->keyStrings.indexOfString(name, nameLen);
+ if (!ei.has_value()) {
continue;
}
@@ -5025,7 +5130,7 @@
continue;
}
- if (dtohl(entry->key.index) == (size_t) ei) {
+ if (dtohl(entry->key.index) == (size_t) *ei) {
uint32_t resId = Res_MAKEID(group->id - 1, typeIndex, iter.index());
if (outTypeSpecFlags) {
Entry result;
@@ -6187,8 +6292,9 @@
for (size_t k = 0; k < numTypes; k++) {
const Type* type = typeList[k];
const ResStringPool& typeStrings = type->package->typeStrings;
- if (ignoreMipmap && typeStrings.string8ObjectAt(
- type->typeSpec->id - 1) == "mipmap") {
+ const base::expected<String8, NullOrIOError> typeStr = typeStrings.string8ObjectAt(
+ type->typeSpec->id - 1);
+ if (ignoreMipmap && typeStr.has_value() && *typeStr == "mipmap") {
continue;
}
@@ -6244,24 +6350,18 @@
StringPoolRef::StringPoolRef(const ResStringPool* pool, uint32_t index)
: mPool(pool), mIndex(index) {}
-const char* StringPoolRef::string8(size_t* outLen) const {
- if (mPool != NULL) {
- return mPool->string8At(mIndex, outLen);
+base::expected<StringPiece, NullOrIOError> StringPoolRef::string8() const {
+ if (LIKELY(mPool != NULL)) {
+ return mPool->string8At(mIndex);
}
- if (outLen != NULL) {
- *outLen = 0;
- }
- return NULL;
+ return base::unexpected(std::nullopt);
}
-const char16_t* StringPoolRef::string16(size_t* outLen) const {
- if (mPool != NULL) {
- return mPool->stringAt(mIndex, outLen);
+base::expected<StringPiece16, NullOrIOError> StringPoolRef::string16() const {
+ if (LIKELY(mPool != NULL)) {
+ return mPool->stringAt(mIndex);
}
- if (outLen != NULL) {
- *outLen = 0;
- }
- return NULL;
+ return base::unexpected(std::nullopt);
}
bool ResTable::getResourceFlags(uint32_t resID, uint32_t* outFlags) const {
@@ -7380,13 +7480,13 @@
printf("(dynamic attribute) 0x%08x\n", value.data);
} else if (value.dataType == Res_value::TYPE_STRING) {
size_t len;
- const char* str8 = pkg->header->values.string8At(
- value.data, &len);
+ const char* str8 = UnpackOptionalString(pkg->header->values.string8At(
+ value.data), &len);
if (str8 != NULL) {
printf("(string8) \"%s\"\n", normalizeForOutput(str8).string());
} else {
- const char16_t* str16 = pkg->header->values.stringAt(
- value.data, &len);
+ const char16_t* str16 = UnpackOptionalString(pkg->header->values.stringAt(
+ value.data), &len);
if (str16 != NULL) {
printf("(string16) \"%s\"\n",
normalizeForOutput(String8(str16, len).string()).string());
diff --git a/libs/androidfw/ResourceUtils.cpp b/libs/androidfw/ResourceUtils.cpp
index c63dff8..a34aa72 100644
--- a/libs/androidfw/ResourceUtils.cpp
+++ b/libs/androidfw/ResourceUtils.cpp
@@ -48,61 +48,76 @@
!(has_type_separator && out_type->empty());
}
-bool ToResourceName(const StringPoolRef& type_string_ref,
- const StringPoolRef& entry_string_ref,
- const StringPiece& package_name,
- AssetManager2::ResourceName* out_name) {
- out_name->package = package_name.data();
- out_name->package_len = package_name.size();
+base::expected<AssetManager2::ResourceName, NullOrIOError> ToResourceName(
+ const StringPoolRef& type_string_ref, const StringPoolRef& entry_string_ref,
+ const StringPiece& package_name) {
+ AssetManager2::ResourceName name{
+ .package = package_name.data(),
+ .package_len = package_name.size(),
+ };
- out_name->type = type_string_ref.string8(&out_name->type_len);
- out_name->type16 = nullptr;
- if (out_name->type == nullptr) {
- out_name->type16 = type_string_ref.string16(&out_name->type_len);
- if (out_name->type16 == nullptr) {
- return false;
+ if (base::expected<StringPiece, NullOrIOError> type_str = type_string_ref.string8()) {
+ name.type = type_str->data();
+ name.type_len = type_str->size();
+ } else if (UNLIKELY(IsIOError(type_str))) {
+ return base::unexpected(type_str.error());
+ }
+
+ if (name.type == nullptr) {
+ if (base::expected<StringPiece16, NullOrIOError> type16_str = type_string_ref.string16()) {
+ name.type16 = type16_str->data();
+ name.type_len = type16_str->size();
+ } else if (!type16_str.has_value()) {
+ return base::unexpected(type16_str.error());
}
}
- out_name->entry = entry_string_ref.string8(&out_name->entry_len);
- out_name->entry16 = nullptr;
- if (out_name->entry == nullptr) {
- out_name->entry16 = entry_string_ref.string16(&out_name->entry_len);
- if (out_name->entry16 == nullptr) {
- return false;
+ if (base::expected<StringPiece, NullOrIOError> entry_str = entry_string_ref.string8()) {
+ name.entry = entry_str->data();
+ name.entry_len = entry_str->size();
+ } else if (UNLIKELY(IsIOError(entry_str))) {
+ return base::unexpected(entry_str.error());
+ }
+
+ if (name.entry == nullptr) {
+ if (base::expected<StringPiece16, NullOrIOError> entry16_str = entry_string_ref.string16()) {
+ name.entry16 = entry16_str->data();
+ name.entry_len = entry16_str->size();
+ } else if (!entry16_str.has_value()) {
+ return base::unexpected(entry16_str.error());
}
}
- return true;
+ return name;
}
-std::string ToFormattedResourceString(AssetManager2::ResourceName* resource_name) {
+std::string ToFormattedResourceString(const AssetManager2::ResourceName& resource_name) {
std::string result;
- if (resource_name->package != nullptr) {
- result.append(resource_name->package, resource_name->package_len);
+ if (resource_name.package != nullptr) {
+ result.append(resource_name.package, resource_name.package_len);
}
- if (resource_name->type != nullptr || resource_name->type16 != nullptr) {
+ if (resource_name.type != nullptr || resource_name.type16 != nullptr) {
if (!result.empty()) {
result += ":";
}
- if (resource_name->type != nullptr) {
- result.append(resource_name->type, resource_name->type_len);
+ if (resource_name.type != nullptr) {
+ result.append(resource_name.type, resource_name.type_len);
} else {
- result += util::Utf16ToUtf8(StringPiece16(resource_name->type16, resource_name->type_len));
+ result += util::Utf16ToUtf8(StringPiece16(resource_name.type16, resource_name.type_len));
}
}
- if (resource_name->entry != nullptr || resource_name->entry16 != nullptr) {
+ if (resource_name.entry != nullptr || resource_name.entry16 != nullptr) {
if (!result.empty()) {
result += "/";
}
- if (resource_name->entry != nullptr) {
- result.append(resource_name->entry, resource_name->entry_len);
+ if (resource_name.entry != nullptr) {
+ result.append(resource_name.entry, resource_name.entry_len);
} else {
- result += util::Utf16ToUtf8(StringPiece16(resource_name->entry16, resource_name->entry_len));
+ result += util::Utf16ToUtf8(StringPiece16(resource_name.entry16, resource_name.entry_len));
}
}
diff --git a/libs/androidfw/StreamingZipInflater.cpp b/libs/androidfw/StreamingZipInflater.cpp
index b39b5f0..1c5e5d4 100644
--- a/libs/androidfw/StreamingZipInflater.cpp
+++ b/libs/androidfw/StreamingZipInflater.cpp
@@ -70,13 +70,13 @@
/*
* Streaming access to compressed data held in an mmapped region of memory
*/
-StreamingZipInflater::StreamingZipInflater(FileMap* dataMap, size_t uncompSize) {
+StreamingZipInflater::StreamingZipInflater(const incfs::IncFsFileMap* dataMap, size_t uncompSize) {
mFd = -1;
mDataMap = dataMap;
mOutTotalSize = uncompSize;
- mInTotalSize = dataMap->getDataLength();
+ mInTotalSize = dataMap->length();
- mInBuf = (uint8_t*) dataMap->getDataPtr();
+ mInBuf = (uint8_t*) dataMap->unsafe_data(); // IncFs safety handled in zlib.
mInBufSize = mInTotalSize;
mOutBufSize = StreamingZipInflater::OUTPUT_CHUNK_SIZE;
diff --git a/libs/androidfw/ZipFileRO.cpp b/libs/androidfw/ZipFileRO.cpp
index e77ac3d..52e7a70 100644
--- a/libs/androidfw/ZipFileRO.cpp
+++ b/libs/androidfw/ZipFileRO.cpp
@@ -233,6 +233,29 @@
}
/*
+ * Create a new incfs::IncFsFileMap object that spans the data in "entry".
+ */
+std::optional<incfs::IncFsFileMap> ZipFileRO::createEntryIncFsFileMap(ZipEntryRO entry) const
+{
+ const _ZipEntryRO *zipEntry = reinterpret_cast<_ZipEntryRO*>(entry);
+ const ZipEntry& ze = zipEntry->entry;
+ int fd = GetFileDescriptor(mHandle);
+ size_t actualLen = 0;
+
+ if (ze.method == kCompressStored) {
+ actualLen = ze.uncompressed_length;
+ } else {
+ actualLen = ze.compressed_length;
+ }
+
+ incfs::IncFsFileMap newMap;
+ if (!newMap.Create(fd, ze.offset, actualLen, mFileName)) {
+ return std::nullopt;
+ }
+ return std::move(newMap);
+}
+
+/*
* Uncompress an entry, in its entirety, into the provided output buffer.
*
* This doesn't verify the data's CRC, which might be useful for
diff --git a/libs/androidfw/ZipUtils.cpp b/libs/androidfw/ZipUtils.cpp
index 568e3b6..58fc5bb 100644
--- a/libs/androidfw/ZipUtils.cpp
+++ b/libs/androidfw/ZipUtils.cpp
@@ -40,7 +40,7 @@
explicit FileReader(FILE* fp) : Reader(), mFp(fp), mCurrentOffset(0) {
}
- bool ReadAtOffset(uint8_t* buf, size_t len, off64_t offset) const {
+ bool ReadAtOffset(uint8_t* buf, size_t len, off64_t offset) const override {
// Data is usually requested sequentially, so this helps avoid pointless
// fseeks every time we perform a read. There's an impedence mismatch
// here because the original API was designed around pread and pwrite.
@@ -71,7 +71,7 @@
explicit FdReader(int fd) : mFd(fd) {
}
- bool ReadAtOffset(uint8_t* buf, size_t len, off64_t offset) const {
+ bool ReadAtOffset(uint8_t* buf, size_t len, off64_t offset) const override {
return android::base::ReadFullyAtOffset(mFd, buf, len, offset);
}
@@ -81,22 +81,27 @@
class BufferReader : public zip_archive::Reader {
public:
- BufferReader(const void* input, size_t inputSize) : Reader(),
- mInput(reinterpret_cast<const uint8_t*>(input)),
+ BufferReader(incfs::map_ptr<void> input, size_t inputSize) : Reader(),
+ mInput(input.convert<uint8_t>()),
mInputSize(inputSize) {
}
- bool ReadAtOffset(uint8_t* buf, size_t len, off64_t offset) const {
+ bool ReadAtOffset(uint8_t* buf, size_t len, off64_t offset) const override {
if (mInputSize < len || offset > mInputSize - len) {
return false;
}
- memcpy(buf, mInput + offset, len);
+ const incfs::map_ptr<uint8_t> pos = mInput.offset(offset);
+ if (!pos.verify(len)) {
+ return false;
+ }
+
+ memcpy(buf, pos.unsafe_ptr(), len);
return true;
}
private:
- const uint8_t* mInput;
+ const incfs::map_ptr<uint8_t> mInput;
const size_t mInputSize;
};
@@ -138,7 +143,7 @@
return (zip_archive::Inflate(reader, compressedLen, uncompressedLen, &writer, nullptr) == 0);
}
-/*static*/ bool ZipUtils::inflateToBuffer(const void* in, void* buf,
+/*static*/ bool ZipUtils::inflateToBuffer(incfs::map_ptr<void> in, void* buf,
long uncompressedLen, long compressedLen)
{
BufferReader reader(in, compressedLen);
diff --git a/libs/androidfw/fuzz/resourcefile_fuzzer/resourcefile_fuzzer.cpp b/libs/androidfw/fuzz/resourcefile_fuzzer/resourcefile_fuzzer.cpp
index 96d44ab..5309ab2 100644
--- a/libs/androidfw/fuzz/resourcefile_fuzzer/resourcefile_fuzzer.cpp
+++ b/libs/androidfw/fuzz/resourcefile_fuzzer/resourcefile_fuzzer.cpp
@@ -31,9 +31,6 @@
using android::StringPiece;
extern "C" int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size) {
-
- std::unique_ptr<const LoadedArsc> loaded_arsc =
- LoadedArsc::Load(StringPiece(reinterpret_cast<const char*>(data), size));
-
+ std::unique_ptr<const LoadedArsc> loaded_arsc = LoadedArsc::Load(data, size);
return 0;
}
\ No newline at end of file
diff --git a/libs/androidfw/include/androidfw/Asset.h b/libs/androidfw/include/androidfw/Asset.h
index 298509e..80bae20 100644
--- a/libs/androidfw/include/androidfw/Asset.h
+++ b/libs/androidfw/include/androidfw/Asset.h
@@ -23,18 +23,18 @@
#include <stdio.h>
#include <sys/types.h>
-
#include <memory>
+#include <optional>
#include <android-base/unique_fd.h>
+#include <util/map_ptr.h>
+
#include <utils/Compat.h>
#include <utils/Errors.h>
#include <utils/String8.h>
namespace android {
-class FileMap;
-
/*
* Instances of this class provide read-only operations on a byte stream.
*
@@ -49,6 +49,8 @@
class Asset {
public:
virtual ~Asset(void) = default;
+ Asset(const Asset& src) = delete;
+ Asset& operator=(const Asset& src) = delete;
static int32_t getGlobalCount();
static String8 getAssetAllocations();
@@ -87,8 +89,19 @@
/*
* Get a pointer to a buffer with the entire contents of the file.
+ * If `aligned` is true, the buffer data will be aligned to a 4-byte boundary.
+ *
+ * Use this function if the asset can never reside on IncFs.
*/
- virtual const void* getBuffer(bool wordAligned) = 0;
+ virtual const void* getBuffer(bool aligned) = 0;
+
+ /*
+ * Get a incfs::map_ptr<void> to a buffer with the entire contents of the file.
+ * If `aligned` is true, the buffer data will be aligned to a 4-byte boundary.
+ *
+ * Use this function if the asset can potentially reside on IncFs.
+ */
+ virtual incfs::map_ptr<void> getIncFsBuffer(bool aligned) = 0;
/*
* Get the total amount of data that can be read.
@@ -152,10 +165,6 @@
AccessMode getAccessMode(void) const { return mAccessMode; }
private:
- /* these operations are not implemented */
- Asset(const Asset& src);
- Asset& operator=(const Asset& src);
-
/* AssetManager needs access to our "create" functions */
friend class AssetManager;
friend class ApkAssets;
@@ -169,8 +178,7 @@
/*
* Create the asset from a named, compressed file on disk (e.g. ".gz").
*/
- static Asset* createFromCompressedFile(const char* fileName,
- AccessMode mode);
+ static Asset* createFromCompressedFile(const char* fileName, AccessMode mode);
#if 0
/*
@@ -200,31 +208,21 @@
/*
* Create the asset from a memory-mapped file segment.
*
- * The asset takes ownership of the FileMap.
+ * The asset takes ownership of the incfs::IncFsFileMap and the file descriptor "fd". The
+ * file descriptor is used to request new file descriptors using "openFileDescriptor".
*/
- static Asset* createFromUncompressedMap(FileMap* dataMap, AccessMode mode);
-
- /*
- * Create the asset from a memory-mapped file segment.
- *
- * The asset takes ownership of the FileMap and the file descriptor "fd". The file descriptor is
- * used to request new file descriptors using "openFileDescriptor".
- */
- static std::unique_ptr<Asset> createFromUncompressedMap(std::unique_ptr<FileMap> dataMap,
- base::unique_fd fd, AccessMode mode);
+ static std::unique_ptr<Asset> createFromUncompressedMap(incfs::IncFsFileMap&& dataMap,
+ AccessMode mode,
+ base::unique_fd fd = {});
/*
* Create the asset from a memory-mapped file segment with compressed
* data.
*
- * The asset takes ownership of the FileMap.
+ * The asset takes ownership of the incfs::IncFsFileMap.
*/
- static Asset* createFromCompressedMap(FileMap* dataMap,
- size_t uncompressedLen, AccessMode mode);
-
- static std::unique_ptr<Asset> createFromCompressedMap(std::unique_ptr<FileMap> dataMap,
- size_t uncompressedLen, AccessMode mode);
-
+ static std::unique_ptr<Asset> createFromCompressedMap(incfs::IncFsFileMap&& dataMap,
+ size_t uncompressedLen, AccessMode mode);
/*
* Create from a reference-counted chunk of shared memory.
@@ -252,7 +250,7 @@
class _FileAsset : public Asset {
public:
_FileAsset(void);
- virtual ~_FileAsset(void);
+ ~_FileAsset(void) override;
/*
* Use a piece of an already-open file.
@@ -266,21 +264,24 @@
*
* On success, the object takes ownership of "dataMap" and "fd".
*/
- status_t openChunk(FileMap* dataMap, base::unique_fd fd);
+ status_t openChunk(incfs::IncFsFileMap&& dataMap, base::unique_fd fd);
/*
* Standard Asset interfaces.
*/
- virtual ssize_t read(void* buf, size_t count);
- virtual off64_t seek(off64_t offset, int whence);
- virtual void close(void);
- virtual const void* getBuffer(bool wordAligned);
- virtual off64_t getLength(void) const { return mLength; }
- virtual off64_t getRemainingLength(void) const { return mLength-mOffset; }
- virtual int openFileDescriptor(off64_t* outStart, off64_t* outLength) const;
- virtual bool isAllocated(void) const { return mBuf != NULL; }
+ ssize_t read(void* buf, size_t count) override;
+ off64_t seek(off64_t offset, int whence) override;
+ void close(void) override;
+ const void* getBuffer(bool aligned) override;
+ incfs::map_ptr<void> getIncFsBuffer(bool aligned) override;
+ off64_t getLength(void) const override { return mLength; }
+ off64_t getRemainingLength(void) const override { return mLength-mOffset; }
+ int openFileDescriptor(off64_t* outStart, off64_t* outLength) const override;
+ bool isAllocated(void) const override { return mBuf != NULL; }
private:
+ incfs::map_ptr<void> ensureAlignment(const incfs::IncFsFileMap& map);
+
off64_t mStart; // absolute file offset of start of chunk
off64_t mLength; // length of the chunk
off64_t mOffset; // current local offset, 0 == mStart
@@ -295,10 +296,8 @@
*/
enum { kReadVsMapThreshold = 4096 };
- FileMap* mMap; // for memory map
- unsigned char* mBuf; // for read
-
- const void* ensureAlignment(FileMap* map);
+ unsigned char* mBuf; // for read
+ std::optional<incfs::IncFsFileMap> mMap; // for memory map
};
@@ -323,7 +322,7 @@
*
* On success, the object takes ownership of "fd".
*/
- status_t openChunk(FileMap* dataMap, size_t uncompressedLen);
+ status_t openChunk(incfs::IncFsFileMap&& dataMap, size_t uncompressedLen);
/*
* Standard Asset interfaces.
@@ -331,24 +330,23 @@
virtual ssize_t read(void* buf, size_t count);
virtual off64_t seek(off64_t offset, int whence);
virtual void close(void);
- virtual const void* getBuffer(bool wordAligned);
+ virtual const void* getBuffer(bool aligned);
+ virtual incfs::map_ptr<void> getIncFsBuffer(bool aligned);
virtual off64_t getLength(void) const { return mUncompressedLen; }
virtual off64_t getRemainingLength(void) const { return mUncompressedLen-mOffset; }
virtual int openFileDescriptor(off64_t* /* outStart */, off64_t* /* outLength */) const { return -1; }
virtual bool isAllocated(void) const { return mBuf != NULL; }
private:
- off64_t mStart; // offset to start of compressed data
- off64_t mCompressedLen; // length of the compressed data
- off64_t mUncompressedLen; // length of the uncompressed data
- off64_t mOffset; // current offset, 0 == start of uncomp data
+ off64_t mStart; // offset to start of compressed data
+ off64_t mCompressedLen; // length of the compressed data
+ off64_t mUncompressedLen; // length of the uncompressed data
+ off64_t mOffset; // current offset, 0 == start of uncomp data
+ int mFd; // for file input
- FileMap* mMap; // for memory-mapped input
- int mFd; // for file input
-
- class StreamingZipInflater* mZipInflater; // for streaming large compressed assets
-
- unsigned char* mBuf; // for getBuffer()
+ class StreamingZipInflater* mZipInflater; // for streaming large compressed assets
+ unsigned char* mBuf; // for getBuffer()
+ std::optional<incfs::IncFsFileMap> mMap; // for memory-mapped input
};
// need: shared mmap version?
diff --git a/libs/androidfw/include/androidfw/AssetManager2.h b/libs/androidfw/include/androidfw/AssetManager2.h
index 30ef25c..a92694c 100644
--- a/libs/androidfw/include/androidfw/AssetManager2.h
+++ b/libs/androidfw/include/androidfw/AssetManager2.h
@@ -131,8 +131,8 @@
bool GetOverlayablesToString(const android::StringPiece& package_name,
std::string* out) const;
- const std::unordered_map<std::string, std::string>*
- GetOverlayableMapForPackage(uint32_t package_id) const;
+ const std::unordered_map<std::string, std::string>* GetOverlayableMapForPackage(
+ uint32_t package_id) const;
// Returns whether the resources.arsc of any loaded apk assets is allocated in RAM (not mmapped).
bool ContainsAllocatedTable() const;
@@ -145,14 +145,16 @@
return configuration_;
}
- // Returns all configurations for which there are resources defined. This includes resource
- // configurations in all the ApkAssets set for this AssetManager.
+ // Returns all configurations for which there are resources defined, or an I/O error if reading
+ // resource data failed.
+ //
+ // This includes resource configurations in all the ApkAssets set for this AssetManager.
// If `exclude_system` is set to true, resource configurations from system APKs
// ('android' package, other libraries) will be excluded from the list.
// If `exclude_mipmap` is set to true, resource configurations defined for resource type 'mipmap'
// will be excluded from the list.
- std::set<ResTable_config> GetResourceConfigurations(bool exclude_system = false,
- bool exclude_mipmap = false) const;
+ base::expected<std::set<ResTable_config>, IOError> GetResourceConfigurations(
+ bool exclude_system = false, bool exclude_mipmap = false) const;
// Returns all the locales for which there are resources defined. This includes resource
// locales in all the ApkAssets set for this AssetManager.
@@ -194,53 +196,109 @@
std::unique_ptr<Asset> OpenNonAsset(const std::string& filename, ApkAssetsCookie cookie,
Asset::AccessMode mode) const;
- // Populates the `out_name` parameter with resource name information.
- // Utf8 strings are preferred, and only if they are unavailable are
- // the Utf16 variants populated.
- // Returns false if the resource was not found or the name was missing/corrupt.
- bool GetResourceName(uint32_t resid, ResourceName* out_name) const;
-
- // Populates `out_flags` with the bitmask of configuration axis that this resource varies with.
- // See ResTable_config for the list of configuration axis.
- // Returns false if the resource was not found.
- bool GetResourceFlags(uint32_t resid, uint32_t* out_flags) const;
+ // Returns the resource name of the specified resource ID.
+ //
+ // Utf8 strings are preferred, and only if they are unavailable are the Utf16 variants populated.
+ //
+ // Returns a null error if the name is missing/corrupt, or an I/O error if reading resource data
+ // failed.
+ base::expected<ResourceName, NullOrIOError> GetResourceName(uint32_t resid) const;
// Finds the resource ID assigned to `resource_name`.
+ //
// `resource_name` must be of the form '[package:][type/]entry'.
// If no package is specified in `resource_name`, then `fallback_package` is used as the package.
// If no type is specified in `resource_name`, then `fallback_type` is used as the type.
- // Returns 0x0 if no resource by that name was found.
- uint32_t GetResourceId(const std::string& resource_name, const std::string& fallback_type = {},
- const std::string& fallback_package = {}) const;
-
- // Retrieves the best matching resource with ID `resid`. The resource value is filled into
- // `out_value` and the configuration for the selected value is populated in `out_selected_config`.
- // `out_flags` holds the same flags as retrieved with GetResourceFlags().
- // If `density_override` is non-zero, the configuration to match against is overridden with that
- // density.
//
- // Returns a valid cookie if the resource was found. If the resource was not found, or if the
- // resource was a map/bag type, then kInvalidCookie is returned. If `may_be_bag` is false,
- // this function logs if the resource was a map/bag type before returning kInvalidCookie.
- ApkAssetsCookie GetResource(uint32_t resid, bool may_be_bag, uint16_t density_override,
- Res_value* out_value, ResTable_config* out_selected_config,
- uint32_t* out_flags) const;
+ // Returns a null error if no resource by that name was found, or an I/O error if reading resource
+ // data failed.
+ base::expected<uint32_t, NullOrIOError> GetResourceId(
+ const std::string& resource_name, const std::string& fallback_type = {},
+ const std::string& fallback_package = {}) const;
- // Resolves the resource reference in `in_out_value` if the data type is
- // Res_value::TYPE_REFERENCE.
- // `cookie` is the ApkAssetsCookie of the reference in `in_out_value`.
- // `in_out_value` is the reference to resolve. The result is placed back into this object.
- // `in_out_flags` is the type spec flags returned from calls to GetResource() or
- // GetResourceFlags(). Configuration flags of the values pointed to by the reference
- // are OR'd together with `in_out_flags`.
- // `in_out_config` is populated with the configuration for which the resolved value was defined.
- // `out_last_reference` is populated with the last reference ID before resolving to an actual
- // value. This is only initialized if the passed in `in_out_value` is a reference.
- // Returns the cookie of the APK the resolved resource was defined in, or kInvalidCookie if
- // it was not found.
- ApkAssetsCookie ResolveReference(ApkAssetsCookie cookie, Res_value* in_out_value,
- ResTable_config* in_out_selected_config, uint32_t* in_out_flags,
- uint32_t* out_last_reference) const;
+ struct SelectedValue {
+ friend AssetManager2;
+ friend Theme;
+ SelectedValue() = default;
+ SelectedValue(const ResolvedBag* bag, const ResolvedBag::Entry& entry) :
+ cookie(entry.cookie), data(entry.value.data), type(entry.value.dataType),
+ flags(bag->type_spec_flags), resid(0U), config({}) {};
+
+ // The cookie representing the ApkAssets in which the value resides.
+ ApkAssetsCookie cookie = kInvalidCookie;
+
+ // The data for this value, as interpreted according to `type`.
+ Res_value::data_type data;
+
+ // Type of the data value.
+ uint8_t type;
+
+ // The bitmask of configuration axis that this resource varies with.
+ // See ResTable_config::CONFIG_*.
+ uint32_t flags;
+
+ // The resource ID from which this value was resolved.
+ uint32_t resid;
+
+ // The configuration for which the resolved value was defined.
+ ResTable_config config;
+
+ private:
+ SelectedValue(uint8_t value_type, Res_value::data_type value_data, ApkAssetsCookie cookie,
+ uint32_t type_flags, uint32_t resid, const ResTable_config& config) :
+ cookie(cookie), data(value_data), type(value_type), flags(type_flags),
+ resid(resid), config(config) {};
+ };
+
+ // Retrieves the best matching resource value with ID `resid`.
+ //
+ // If `may_be_bag` is false, this function logs if the resource was a map/bag type and returns a
+ // null result. If `density_override` is non-zero, the configuration to match against is
+ // overridden with that density.
+ //
+ // Returns a null error if a best match could not be found, or an I/O error if reading resource
+ // data failed.
+ base::expected<SelectedValue, NullOrIOError> GetResource(uint32_t resid, bool may_be_bag = false,
+ uint16_t density_override = 0U) const;
+
+ // Resolves the resource referenced in `value` if the type is Res_value::TYPE_REFERENCE.
+ //
+ // If the data type is not Res_value::TYPE_REFERENCE, no work is done. Configuration flags of the
+ // values pointed to by the reference are OR'd into `value.flags`. If `cache_value` is true, then
+ // the resolved value will be cached and used when attempting to resolve the resource id specified
+ // in `value`.
+ //
+ // Returns a null error if the resource could not be resolved, or an I/O error if reading
+ // resource data failed.
+ base::expected<std::monostate, NullOrIOError> ResolveReference(SelectedValue& value,
+ bool cache_value = false) const;
+
+ // Retrieves the best matching bag/map resource with ID `resid`.
+ //
+ // This method will resolve all parent references for this bag and merge keys with the child.
+ // To iterate over the keys, use the following idiom:
+ //
+ // base::expected<const ResolvedBag*, NullOrIOError> bag = asset_manager->GetBag(id);
+ // if (bag.has_value()) {
+ // for (auto iter = begin(*bag); iter != end(*bag); ++iter) {
+ // ...
+ // }
+ // }
+ //
+ // Returns a null error if a best match could not be found, or an I/O error if reading resource
+ // data failed.
+ base::expected<const ResolvedBag*, NullOrIOError> GetBag(uint32_t resid) const;
+
+ // Retrieves the best matching bag/map resource of the resource referenced in `value`.
+ //
+ // If `value.type` is not Res_value::TYPE_REFERENCE, a null result is returned.
+ // Configuration flags of the bag pointed to by the reference are OR'd into `value.flags`.
+ //
+ // Returns a null error if a best match could not be found, or an I/O error if reading resource
+ // data failed.
+ base::expected<const ResolvedBag*, NullOrIOError> ResolveBag(SelectedValue& value) const;
+
+ const std::vector<uint32_t> GetBagResIdStack(uint32_t resid) const;
// Resets the resource resolution structures in preparation for the next resource retrieval.
void ResetResourceResolution() const;
@@ -252,20 +310,6 @@
// resolved yet.
std::string GetLastResourceResolution() const;
- const std::vector<uint32_t> GetBagResIdStack(uint32_t resid);
-
- // Retrieves the best matching bag/map resource with ID `resid`.
- // This method will resolve all parent references for this bag and merge keys with the child.
- // To iterate over the keys, use the following idiom:
- //
- // const AssetManager2::ResolvedBag* bag = asset_manager->GetBag(id);
- // if (bag != nullptr) {
- // for (auto iter = begin(bag); iter != end(bag); ++iter) {
- // ...
- // }
- // }
- const ResolvedBag* GetBag(uint32_t resid);
-
// Creates a new Theme from this AssetManager.
std::unique_ptr<Theme> NewTheme();
@@ -286,11 +330,15 @@
private:
DISALLOW_COPY_AND_ASSIGN(AssetManager2);
+ struct TypeConfig {
+ incfs::verified_map_ptr<ResTable_type> type;
+ ResTable_config config;
+ };
+
// A collection of configurations and their associated ResTable_type that match the current
// AssetManager configuration.
struct FilteredConfigGroup {
- std::vector<ResTable_config> configurations;
- std::vector<const ResTable_type*> types;
+ std::vector<TypeConfig> type_configs;
};
// Represents an single package.
@@ -331,9 +379,7 @@
};
// Finds the best entry for `resid` from the set of ApkAssets. The entry can be a simple
- // Res_value, or a complex map/bag type. If successful, it is available in `out_entry`.
- // Returns kInvalidCookie on failure. Otherwise, the return value is the cookie associated with
- // the ApkAssets in which the entry was found.
+ // Res_value, or a complex map/bag type. Returns a null result if a best entry cannot be found.
//
// `density_override` overrides the density of the current configuration when doing a search.
//
@@ -347,13 +393,15 @@
//
// NOTE: FindEntry takes care of ensuring that structs within FindEntryResult have been properly
// bounds-checked. Callers of FindEntry are free to trust the data if this method succeeds.
- ApkAssetsCookie FindEntry(uint32_t resid, uint16_t density_override, bool stop_at_first_match,
- bool ignore_configuration, FindEntryResult* out_entry) const;
+ base::expected<FindEntryResult, NullOrIOError> FindEntry(uint32_t resid,
+ uint16_t density_override,
+ bool stop_at_first_match,
+ bool ignore_configuration) const;
- ApkAssetsCookie FindEntryInternal(const PackageGroup& package_group, uint8_t type_idx,
- uint16_t entry_idx, const ResTable_config& desired_config,
- bool /*stop_at_first_match*/,
- bool ignore_configuration, FindEntryResult* out_entry) const;
+ base::expected<FindEntryResult, NullOrIOError> FindEntryInternal(
+ const PackageGroup& package_group, uint8_t type_idx, uint16_t entry_idx,
+ const ResTable_config& desired_config, bool stop_at_first_match,
+ bool ignore_configuration) const;
// Assigns package IDs to all shared library ApkAssets.
// Should be called whenever the ApkAssets are changed.
@@ -372,7 +420,8 @@
// AssetManager2::GetBag(resid) wraps this function to track which resource ids have already
// been seen while traversing bag parents.
- const ResolvedBag* GetBag(uint32_t resid, std::vector<uint32_t>& child_resids);
+ base::expected<const ResolvedBag*, NullOrIOError> GetBag(
+ uint32_t resid, std::vector<uint32_t>& child_resids) const;
// The ordered list of ApkAssets to search. These are not owned by the AssetManager, and must
// have a longer lifetime.
@@ -394,19 +443,20 @@
// Cached set of bags. These are cached because they can inherit keys from parent bags,
// which involves some calculation.
- std::unordered_map<uint32_t, util::unique_cptr<ResolvedBag>> cached_bags_;
+ mutable std::unordered_map<uint32_t, util::unique_cptr<ResolvedBag>> cached_bags_;
// Cached set of bag resid stacks for each bag. These are cached because they might be requested
// a number of times for each view during View inspection.
- std::unordered_map<uint32_t, std::vector<uint32_t>> cached_bag_resid_stacks_;
+ mutable std::unordered_map<uint32_t, std::vector<uint32_t>> cached_bag_resid_stacks_;
+
+ // Cached set of resolved resource values.
+ mutable std::unordered_map<uint32_t, SelectedValue> cached_resolved_values_;
// Whether or not to save resource resolution steps
bool resource_resolution_logging_enabled_ = false;
struct Resolution {
-
struct Step {
-
enum class Type {
INITIAL,
BETTER_MATCH,
@@ -455,55 +505,53 @@
public:
~Theme();
- // Applies the style identified by `resid` to this theme. This can be called
- // multiple times with different styles. By default, any theme attributes that
- // are already defined before this call are not overridden. If `force` is set
- // to true, this behavior is changed and all theme attributes from the style at
- // `resid` are applied.
- // Returns false if the style failed to apply.
- bool ApplyStyle(uint32_t resid, bool force = false);
+ // Applies the style identified by `resid` to this theme.
+ //
+ // This can be called multiple times with different styles. By default, any theme attributes that
+ // are already defined before this call are not overridden. If `force` is set to true, this
+ // behavior is changed and all theme attributes from the style at `resid` are applied.
+ //
+ // Returns a null error if the style could not be applied, or an I/O error if reading resource
+ // data failed.
+ base::expected<std::monostate, NullOrIOError> ApplyStyle(uint32_t resid, bool force = false);
- // Sets this Theme to be a copy of `o` if `o` has the same AssetManager as this Theme.
- // If `o` does not have the same AssetManager as this theme, only attributes from ApkAssets loaded
- // into both AssetManagers will be copied to this theme.
- void SetTo(const Theme& o);
+ // Sets this Theme to be a copy of `other` if `other` has the same AssetManager as this Theme.
+ //
+ // If `other` does not have the same AssetManager as this theme, only attributes from ApkAssets
+ // loaded into both AssetManagers will be copied to this theme.
+ //
+ // Returns an I/O error if reading resource data failed.
+ base::expected<std::monostate, IOError> SetTo(const Theme& other);
void Clear();
- void Dump() const;
+ // Retrieves the value of attribute ID `resid` in the theme.
+ //
+ // NOTE: This function does not do reference traversal. If you want to follow references to other
+ // resources to get the "real" value to use, you need to call ResolveReference() after this
+ // function.
+ std::optional<AssetManager2::SelectedValue> GetAttribute(uint32_t resid) const;
- inline const AssetManager2* GetAssetManager() const {
+ // This is like AssetManager2::ResolveReference(), but also takes care of resolving attribute
+ // references to the theme.
+ base::expected<std::monostate, NullOrIOError> ResolveAttributeReference(
+ AssetManager2::SelectedValue& value) const;
+
+ AssetManager2* GetAssetManager() {
return asset_manager_;
}
- inline AssetManager2* GetAssetManager() {
+ const AssetManager2* GetAssetManager() const {
return asset_manager_;
}
// Returns a bit mask of configuration changes that will impact this
// theme (and thus require completely reloading it).
- inline uint32_t GetChangingConfigurations() const {
+ uint32_t GetChangingConfigurations() const {
return type_spec_flags_;
}
- // Retrieve a value in the theme. If the theme defines this value, returns an asset cookie
- // indicating which ApkAssets it came from and populates `out_value` with the value.
- // `out_flags` is populated with a bitmask of the configuration axis with which the resource
- // varies.
- //
- // If the attribute is not found, returns kInvalidCookie.
- //
- // NOTE: This function does not do reference traversal. If you want to follow references to other
- // resources to get the "real" value to use, you need to call ResolveReference() after this
- // function.
- ApkAssetsCookie GetAttribute(uint32_t resid, Res_value* out_value, uint32_t* out_flags) const;
-
- // This is like AssetManager2::ResolveReference(), but also takes
- // care of resolving attribute references to the theme.
- ApkAssetsCookie ResolveAttributeReference(ApkAssetsCookie cookie, Res_value* in_out_value,
- ResTable_config* in_out_selected_config = nullptr,
- uint32_t* in_out_type_spec_flags = nullptr,
- uint32_t* out_last_ref = nullptr) const;
+ void Dump() const;
private:
DISALLOW_COPY_AND_ASSIGN(Theme);
diff --git a/libs/androidfw/include/androidfw/AttributeResolution.h b/libs/androidfw/include/androidfw/AttributeResolution.h
index d71aad2..1a69a30 100644
--- a/libs/androidfw/include/androidfw/AttributeResolution.h
+++ b/libs/androidfw/include/androidfw/AttributeResolution.h
@@ -45,20 +45,28 @@
// `out_values` must NOT be nullptr.
// `out_indices` may be nullptr.
-bool ResolveAttrs(Theme* theme, uint32_t def_style_attr, uint32_t def_style_resid,
- uint32_t* src_values, size_t src_values_length, uint32_t* attrs,
- size_t attrs_length, uint32_t* out_values, uint32_t* out_indices);
+base::expected<std::monostate, IOError> ResolveAttrs(Theme* theme, uint32_t def_style_attr,
+ uint32_t def_style_resid, uint32_t* src_values,
+ size_t src_values_length, uint32_t* attrs,
+ size_t attrs_length, uint32_t* out_values,
+ uint32_t* out_indices);
// `out_values` must NOT be nullptr.
// `out_indices` is NOT optional and must NOT be nullptr.
-void ApplyStyle(Theme* theme, ResXMLParser* xml_parser, uint32_t def_style_attr,
- uint32_t def_style_resid, const uint32_t* attrs, size_t attrs_length,
- uint32_t* out_values, uint32_t* out_indices);
+base::expected<std::monostate, IOError> ApplyStyle(Theme* theme, ResXMLParser* xml_parser,
+ uint32_t def_style_attr,
+ uint32_t def_style_resid,
+ const uint32_t* attrs, size_t attrs_length,
+ uint32_t* out_values, uint32_t* out_indices);
// `out_values` must NOT be nullptr.
// `out_indices` may be nullptr.
-bool RetrieveAttributes(AssetManager2* assetmanager, ResXMLParser* xml_parser, uint32_t* attrs,
- size_t attrs_length, uint32_t* out_values, uint32_t* out_indices);
+base::expected<std::monostate, IOError> RetrieveAttributes(AssetManager2* assetmanager,
+ ResXMLParser* xml_parser,
+ uint32_t* attrs,
+ size_t attrs_length,
+ uint32_t* out_values,
+ uint32_t* out_indices);
} // namespace android
diff --git a/libs/androidfw/include/androidfw/Chunk.h b/libs/androidfw/include/androidfw/Chunk.h
index a0f2343..f1c43b2 100644
--- a/libs/androidfw/include/androidfw/Chunk.h
+++ b/libs/androidfw/include/androidfw/Chunk.h
@@ -36,7 +36,7 @@
// of the chunk.
class Chunk {
public:
- explicit Chunk(const ResChunk_header* chunk) : device_chunk_(chunk) {}
+ explicit Chunk(incfs::verified_map_ptr<ResChunk_header> chunk) : device_chunk_(chunk) {}
// Returns the type of the chunk. Caller need not worry about endianness.
inline int type() const { return dtohs(device_chunk_->type); }
@@ -49,21 +49,18 @@
inline size_t header_size() const { return dtohs(device_chunk_->headerSize); }
template <typename T, size_t MinSize = sizeof(T)>
- inline const T* header() const {
- if (header_size() >= MinSize) {
- return reinterpret_cast<const T*>(device_chunk_);
- }
- return nullptr;
+ inline incfs::map_ptr<T> header() const {
+ return (header_size() >= MinSize) ? device_chunk_.convert<T>() : nullptr;
}
- inline const void* data_ptr() const {
- return reinterpret_cast<const uint8_t*>(device_chunk_) + header_size();
+ inline incfs::map_ptr<void> data_ptr() const {
+ return device_chunk_.offset(header_size());
}
inline size_t data_size() const { return size() - header_size(); }
private:
- const ResChunk_header* device_chunk_;
+ const incfs::verified_map_ptr<ResChunk_header> device_chunk_;
};
// Provides a Java style iterator over an array of ResChunk_header's.
@@ -84,11 +81,11 @@
//
class ChunkIterator {
public:
- ChunkIterator(const void* data, size_t len)
- : next_chunk_(reinterpret_cast<const ResChunk_header*>(data)),
+ ChunkIterator(incfs::map_ptr<void> data, size_t len)
+ : next_chunk_(data.convert<ResChunk_header>()),
len_(len),
last_error_(nullptr) {
- CHECK(next_chunk_ != nullptr) << "data can't be nullptr";
+ CHECK((bool) next_chunk_) << "data can't be null";
if (len_ != 0) {
VerifyNextChunk();
}
@@ -113,7 +110,7 @@
// Returns false if there was an error. For legacy purposes.
bool VerifyNextChunkNonFatal();
- const ResChunk_header* next_chunk_;
+ incfs::map_ptr<ResChunk_header> next_chunk_;
size_t len_;
const char* last_error_;
bool last_error_was_fatal_ = true;
diff --git a/libs/androidfw/include/androidfw/Errors.h b/libs/androidfw/include/androidfw/Errors.h
new file mode 100644
index 0000000..948162d
--- /dev/null
+++ b/libs/androidfw/include/androidfw/Errors.h
@@ -0,0 +1,47 @@
+/*
+ * Copyright (C) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef ANDROIDFW_ERRORS_H_
+#define ANDROIDFW_ERRORS_H_
+
+#include <optional>
+#include <variant>
+
+#include <android-base/result.h>
+
+namespace android {
+
+enum class IOError {
+ // Used when reading a file residing on an IncFs file-system times out.
+ PAGES_MISSING = -1,
+};
+
+// Represents an absent result or an I/O error.
+using NullOrIOError = std::variant<std::nullopt_t, IOError>;
+
+// Checks whether the result holds an unexpected I/O error.
+template <typename T>
+static inline bool IsIOError(const base::expected<T, NullOrIOError> result) {
+ return !result.has_value() && std::holds_alternative<IOError>(result.error());
+}
+
+static inline IOError GetIOError(const NullOrIOError& error) {
+ return std::get<IOError>(error);
+}
+
+} // namespace android
+
+#endif //ANDROIDFW_ERRORS_H_
diff --git a/libs/androidfw/include/androidfw/Idmap.h b/libs/androidfw/include/androidfw/Idmap.h
index ab0f47f..fdab03b 100644
--- a/libs/androidfw/include/androidfw/Idmap.h
+++ b/libs/androidfw/include/androidfw/Idmap.h
@@ -40,8 +40,8 @@
class OverlayStringPool : public ResStringPool {
public:
virtual ~OverlayStringPool();
- const char16_t* stringAt(size_t idx, size_t* outLen) const override;
- const char* string8At(size_t idx, size_t* outLen) const override;
+ base::expected<StringPiece16, NullOrIOError> stringAt(size_t idx) const override;
+ base::expected<StringPiece, NullOrIOError> string8At(size_t idx) const override;
size_t size() const override;
explicit OverlayStringPool(const LoadedIdmap* loaded_idmap);
diff --git a/libs/androidfw/include/androidfw/LoadedArsc.h b/libs/androidfw/include/androidfw/LoadedArsc.h
index 89ff9f5..17d97a2 100644
--- a/libs/androidfw/include/androidfw/LoadedArsc.h
+++ b/libs/androidfw/include/androidfw/LoadedArsc.h
@@ -23,7 +23,8 @@
#include <unordered_map>
#include <unordered_set>
-#include "android-base/macros.h"
+#include <android-base/macros.h>
+#include <android-base/result.h>
#include "androidfw/ByteBucketArray.h"
#include "androidfw/Chunk.h"
@@ -49,7 +50,7 @@
// Pointer to the mmapped data where flags are kept.
// Flags denote whether the resource entry is public
// and under which configurations it varies.
- const ResTable_typeSpec* type_spec;
+ incfs::verified_map_ptr<ResTable_typeSpec> type_spec;
// The number of types that follow this struct.
// There is a type for each configuration that entries are defined for.
@@ -57,15 +58,17 @@
// Trick to easily access a variable number of Type structs
// proceeding this struct, and to ensure their alignment.
- const ResTable_type* types[0];
+ incfs::verified_map_ptr<ResTable_type> types[0];
- inline uint32_t GetFlagsForEntryIndex(uint16_t entry_index) const {
+ base::expected<uint32_t, NullOrIOError> GetFlagsForEntryIndex(uint16_t entry_index) const {
if (entry_index >= dtohl(type_spec->entryCount)) {
- return 0u;
+ return 0U;
}
-
- const uint32_t* flags = reinterpret_cast<const uint32_t*>(type_spec + 1);
- return flags[entry_index];
+ const auto entry_flags_ptr = ((type_spec + 1).convert<uint32_t>() + entry_index);
+ if (!entry_flags_ptr) {
+ return base::unexpected(IOError::PAGES_MISSING);
+ }
+ return entry_flags_ptr.value();
}
};
@@ -161,13 +164,17 @@
// the default policy in AAPT2 is to build UTF-8 string pools, this needs to change.
// Returns a partial resource ID, with the package ID left as 0x00. The caller is responsible
// for patching the correct package ID to the resource ID.
- uint32_t FindEntryByName(const std::u16string& type_name, const std::u16string& entry_name) const;
+ base::expected<uint32_t, NullOrIOError> FindEntryByName(const std::u16string& type_name,
+ const std::u16string& entry_name) const;
- static const ResTable_entry* GetEntry(const ResTable_type* type_chunk, uint16_t entry_index);
+ static base::expected<incfs::map_ptr<ResTable_entry>, NullOrIOError> GetEntry(
+ incfs::verified_map_ptr<ResTable_type> type_chunk, uint16_t entry_index);
- static uint32_t GetEntryOffset(const ResTable_type* type_chunk, uint16_t entry_index);
+ static base::expected<uint32_t, NullOrIOError> GetEntryOffset(
+ incfs::verified_map_ptr<ResTable_type> type_chunk, uint16_t entry_index);
- static const ResTable_entry* GetEntryFromOffset(const ResTable_type* type_chunk, uint32_t offset);
+ static base::expected<incfs::map_ptr<ResTable_entry>, NullOrIOError> GetEntryFromOffset(
+ incfs::verified_map_ptr<ResTable_type> type_chunk, uint32_t offset);
// Returns the string pool where type names are stored.
inline const ResStringPool* GetTypeStringPool() const {
@@ -220,7 +227,8 @@
// Populates a set of ResTable_config structs, possibly excluding configurations defined for
// the mipmap type.
- void CollectConfigurations(bool exclude_mipmap, std::set<ResTable_config>* out_configs) const;
+ base::expected<std::monostate, IOError> CollectConfigurations(
+ bool exclude_mipmap, std::set<ResTable_config>* out_configs) const;
// Populates a set of strings representing locales.
// If `canonicalize` is set to true, each locale is transformed into its canonical format
@@ -300,7 +308,8 @@
// If `load_as_shared_library` is set to true, the application package (0x7f) is treated
// as a shared library (0x00). When loaded into an AssetManager, the package will be assigned an
// ID.
- static std::unique_ptr<const LoadedArsc> Load(const StringPiece& data,
+ static std::unique_ptr<const LoadedArsc> Load(incfs::map_ptr<void> data,
+ size_t length,
const LoadedIdmap* loaded_idmap = nullptr,
package_property_t property_flags = 0U);
diff --git a/libs/androidfw/include/androidfw/ResourceTypes.h b/libs/androidfw/include/androidfw/ResourceTypes.h
index 04ba78b..fb5f864 100644
--- a/libs/androidfw/include/androidfw/ResourceTypes.h
+++ b/libs/androidfw/include/androidfw/ResourceTypes.h
@@ -20,7 +20,10 @@
#ifndef _LIBS_UTILS_RESOURCE_TYPES_H
#define _LIBS_UTILS_RESOURCE_TYPES_H
+#include <android-base/expected.h>
+
#include <androidfw/Asset.h>
+#include <androidfw/Errors.h>
#include <androidfw/LocaleData.h>
#include <androidfw/StringPiece.h>
#include <utils/Errors.h>
@@ -497,7 +500,7 @@
virtual ~ResStringPool();
void setToEmpty();
- status_t setTo(const void* data, size_t size, bool copyData=false);
+ status_t setTo(incfs::map_ptr<void> data, size_t size, bool copyData=false);
status_t getError() const;
@@ -505,48 +508,49 @@
// Return string entry as UTF16; if the pool is UTF8, the string will
// be converted before returning.
- inline const char16_t* stringAt(const ResStringPool_ref& ref, size_t* outLen) const {
- return stringAt(ref.index, outLen);
+ inline base::expected<StringPiece16, NullOrIOError> stringAt(
+ const ResStringPool_ref& ref) const {
+ return stringAt(ref.index);
}
- virtual const char16_t* stringAt(size_t idx, size_t* outLen) const;
+ virtual base::expected<StringPiece16, NullOrIOError> stringAt(size_t idx) const;
// Note: returns null if the string pool is not UTF8.
- virtual const char* string8At(size_t idx, size_t* outLen) const;
+ virtual base::expected<StringPiece, NullOrIOError> string8At(size_t idx) const;
// Return string whether the pool is UTF8 or UTF16. Does not allow you
// to distinguish null.
- const String8 string8ObjectAt(size_t idx) const;
+ base::expected<String8, IOError> string8ObjectAt(size_t idx) const;
- const ResStringPool_span* styleAt(const ResStringPool_ref& ref) const;
- const ResStringPool_span* styleAt(size_t idx) const;
+ base::expected<incfs::map_ptr<ResStringPool_span>, NullOrIOError> styleAt(
+ const ResStringPool_ref& ref) const;
+ base::expected<incfs::map_ptr<ResStringPool_span>, NullOrIOError> styleAt(size_t idx) const;
- ssize_t indexOfString(const char16_t* str, size_t strLen) const;
+ base::expected<size_t, NullOrIOError> indexOfString(const char16_t* str, size_t strLen) const;
virtual size_t size() const;
size_t styleCount() const;
size_t bytes() const;
- const void* data() const;
-
+ incfs::map_ptr<void> data() const;
bool isSorted() const;
bool isUTF8() const;
private:
- status_t mError;
- void* mOwnedData;
- const ResStringPool_header* mHeader;
- size_t mSize;
- mutable Mutex mDecodeLock;
- const uint32_t* mEntries;
- const uint32_t* mEntryStyles;
- const void* mStrings;
- char16_t mutable** mCache;
- uint32_t mStringPoolSize; // number of uint16_t
- const uint32_t* mStyles;
- uint32_t mStylePoolSize; // number of uint32_t
+ status_t mError;
+ void* mOwnedData;
+ incfs::verified_map_ptr<ResStringPool_header> mHeader;
+ size_t mSize;
+ mutable Mutex mDecodeLock;
+ incfs::map_ptr<uint32_t> mEntries;
+ incfs::map_ptr<uint32_t> mEntryStyles;
+ incfs::map_ptr<void> mStrings;
+ char16_t mutable** mCache;
+ uint32_t mStringPoolSize; // number of uint16_t
+ incfs::map_ptr<uint32_t> mStyles;
+ uint32_t mStylePoolSize; // number of uint32_t
- const char* stringDecodeAt(size_t idx, const uint8_t* str, const size_t encLen,
- size_t* outLen) const;
+ base::expected<StringPiece, NullOrIOError> stringDecodeAt(
+ size_t idx, incfs::map_ptr<uint8_t> str, size_t encLen) const;
};
/**
@@ -558,8 +562,8 @@
StringPoolRef() = default;
StringPoolRef(const ResStringPool* pool, uint32_t index);
- const char* string8(size_t* outLen) const;
- const char16_t* string16(size_t* outLen) const;
+ base::expected<StringPiece, NullOrIOError> string8() const;
+ base::expected<StringPiece16, NullOrIOError> string16() const;
private:
const ResStringPool* mPool = nullptr;
@@ -1797,6 +1801,16 @@
bool U16StringToInt(const char16_t* s, size_t len, Res_value* outValue);
+template<typename TChar, typename E>
+static const TChar* UnpackOptionalString(base::expected<BasicStringPiece<TChar>, E>&& result,
+ size_t* outLen) {
+ if (result.has_value()) {
+ *outLen = result->size();
+ return result->data();
+ }
+ return NULL;
+}
+
/**
* Convenience class for accessing data in a ResTable resource.
*/
diff --git a/libs/androidfw/include/androidfw/ResourceUtils.h b/libs/androidfw/include/androidfw/ResourceUtils.h
index e649940..bd1c440 100644
--- a/libs/androidfw/include/androidfw/ResourceUtils.h
+++ b/libs/androidfw/include/androidfw/ResourceUtils.h
@@ -30,13 +30,12 @@
// Convert a type_string_ref, entry_string_ref, and package to AssetManager2::ResourceName.
// Useful for getting resource name without re-running AssetManager2::FindEntry searches.
-bool ToResourceName(const StringPoolRef& type_string_ref,
- const StringPoolRef& entry_string_ref,
- const StringPiece& package_name,
- AssetManager2::ResourceName* out_name);
+base::expected<AssetManager2::ResourceName, NullOrIOError> ToResourceName(
+ const StringPoolRef& type_string_ref, const StringPoolRef& entry_string_ref,
+ const StringPiece& package_name);
// Formats a ResourceName to "package:type/entry_name".
-std::string ToFormattedResourceString(AssetManager2::ResourceName* resource_name);
+std::string ToFormattedResourceString(const AssetManager2::ResourceName& resource_name);
inline uint32_t fix_package_id(uint32_t resid, uint8_t package_id) {
return (resid & 0x00ffffffu) | (static_cast<uint32_t>(package_id) << 24);
diff --git a/libs/androidfw/include/androidfw/StreamingZipInflater.h b/libs/androidfw/include/androidfw/StreamingZipInflater.h
index 3ace5d5..472b794b 100644
--- a/libs/androidfw/include/androidfw/StreamingZipInflater.h
+++ b/libs/androidfw/include/androidfw/StreamingZipInflater.h
@@ -19,6 +19,8 @@
#include <unistd.h>
#include <inttypes.h>
+
+#include <util/map_ptr.h>
#include <zlib.h>
#include <utils/Compat.h>
@@ -34,7 +36,7 @@
StreamingZipInflater(int fd, off64_t compDataStart, size_t uncompSize, size_t compSize);
// Flavor that gets the compressed data from an in-memory buffer
- StreamingZipInflater(class FileMap* dataMap, size_t uncompSize);
+ StreamingZipInflater(const incfs::IncFsFileMap* dataMap, size_t uncompSize);
~StreamingZipInflater();
@@ -54,7 +56,7 @@
// where to find the uncompressed data
int mFd;
off64_t mInFileStart; // where the compressed data lives in the file
- class FileMap* mDataMap;
+ const incfs::IncFsFileMap* mDataMap;
z_stream mInflateState;
bool mStreamNeedsInit;
diff --git a/libs/androidfw/include/androidfw/Util.h b/libs/androidfw/include/androidfw/Util.h
index 9a3646b..aceeecc 100644
--- a/libs/androidfw/include/androidfw/Util.h
+++ b/libs/androidfw/include/androidfw/Util.h
@@ -22,7 +22,8 @@
#include <sstream>
#include <vector>
-#include "android-base/macros.h"
+#include <android-base/macros.h>
+#include <util/map_ptr.h>
#include "androidfw/StringPiece.h"
@@ -126,6 +127,11 @@
std::vector<std::string> SplitAndLowercase(const android::StringPiece& str, char sep);
+template <typename T>
+bool IsFourByteAligned(const incfs::map_ptr<T>& data) {
+ return ((size_t)data.unsafe_ptr() & 0x3U) == 0;
+}
+
} // namespace util
} // namespace android
diff --git a/libs/androidfw/include/androidfw/ZipFileRO.h b/libs/androidfw/include/androidfw/ZipFileRO.h
index c221e3b..10f6d06 100644
--- a/libs/androidfw/include/androidfw/ZipFileRO.h
+++ b/libs/androidfw/include/androidfw/ZipFileRO.h
@@ -30,17 +30,20 @@
#ifndef __LIBS_ZIPFILERO_H
#define __LIBS_ZIPFILERO_H
-#include <utils/Compat.h>
-#include <utils/Errors.h>
-#include <utils/FileMap.h>
-#include <utils/threads.h>
-
+#include <optional>
#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <time.h>
+#include <util/map_ptr.h>
+
+#include <utils/Compat.h>
+#include <utils/Errors.h>
+#include <utils/FileMap.h>
+#include <utils/threads.h>
+
struct ZipArchive;
typedef ZipArchive* ZipArchiveHandle;
@@ -136,14 +139,26 @@
uint32_t* pCrc32) const;
/*
- * Create a new FileMap object that maps a subset of the archive. For
+ * Create a new FileMap object that maps a subset of the archive. For
* an uncompressed entry this effectively provides a pointer to the
* actual data, for a compressed entry this provides the input buffer
* for inflate().
+ *
+ * Use this function if the archive can never reside on IncFs.
*/
FileMap* createEntryFileMap(ZipEntryRO entry) const;
/*
+ * Create a new incfs::IncFsFileMap object that maps a subset of the archive. For
+ * an uncompressed entry this effectively provides a pointer to the
+ * actual data, for a compressed entry this provides the input buffer
+ * for inflate().
+ *
+ * Use this function if the archive can potentially reside on IncFs.
+ */
+ std::optional<incfs::IncFsFileMap> createEntryIncFsFileMap(ZipEntryRO entry) const;
+
+ /*
* Uncompress the data into a buffer. Depending on the compression
* format, this is either an "inflate" operation or a memcpy.
*
diff --git a/libs/androidfw/include/androidfw/ZipUtils.h b/libs/androidfw/include/androidfw/ZipUtils.h
index 4d35e99..dbfec34 100644
--- a/libs/androidfw/include/androidfw/ZipUtils.h
+++ b/libs/androidfw/include/androidfw/ZipUtils.h
@@ -25,6 +25,8 @@
#include <stdio.h>
#include <time.h>
+#include "util/map_ptr.h"
+
namespace android {
/*
@@ -40,8 +42,8 @@
long compressedLen);
static bool inflateToBuffer(int fd, void* buf, long uncompressedLen,
long compressedLen);
- static bool inflateToBuffer(const void *in, void* buf, long uncompressedLen,
- long compressedLen);
+ static bool inflateToBuffer(incfs::map_ptr<void> in, void* buf,
+ long uncompressedLen, long compressedLen);
/*
* Someday we might want to make this generic and handle bzip2 ".bz2"
diff --git a/libs/androidfw/tests/AssetManager2_bench.cpp b/libs/androidfw/tests/AssetManager2_bench.cpp
index 437e147..c7ae618 100644
--- a/libs/androidfw/tests/AssetManager2_bench.cpp
+++ b/libs/androidfw/tests/AssetManager2_bench.cpp
@@ -139,9 +139,13 @@
assets.SetApkAssets({apk.get()});
while (state.KeepRunning()) {
- const ResolvedBag* bag = assets.GetBag(app::R::style::StyleTwo);
- const auto bag_end = end(bag);
- for (auto iter = begin(bag); iter != bag_end; ++iter) {
+ auto bag = assets.GetBag(app::R::style::StyleTwo);
+ if (!bag.has_value()) {
+ state.SkipWithError("Failed to load get bag");
+ return;
+ }
+ const auto bag_end = end(*bag);
+ for (auto iter = begin(*bag); iter != bag_end; ++iter) {
uint32_t key = iter->key;
Res_value value = iter->value;
benchmark::DoNotOptimize(key);
diff --git a/libs/androidfw/tests/AssetManager2_test.cpp b/libs/androidfw/tests/AssetManager2_test.cpp
index 8c255d1..3638ce1 100644
--- a/libs/androidfw/tests/AssetManager2_test.cpp
+++ b/libs/androidfw/tests/AssetManager2_test.cpp
@@ -108,24 +108,18 @@
assetmanager.SetConfiguration(desired_config);
assetmanager.SetApkAssets({basic_assets_.get()});
- Res_value value;
- ResTable_config selected_config;
- uint32_t flags;
-
- ApkAssetsCookie cookie =
- assetmanager.GetResource(basic::R::string::test1, false /*may_be_bag*/,
- 0 /*density_override*/, &value, &selected_config, &flags);
- ASSERT_NE(kInvalidCookie, cookie);
+ auto value = assetmanager.GetResource(basic::R::string::test1);
+ ASSERT_TRUE(value.has_value());
// Came from our ApkAssets.
- EXPECT_EQ(0, cookie);
+ EXPECT_EQ(0, value->cookie);
// It is the default config.
- EXPECT_EQ(0, selected_config.language[0]);
- EXPECT_EQ(0, selected_config.language[1]);
+ EXPECT_EQ(0, value->config.language[0]);
+ EXPECT_EQ(0, value->config.language[1]);
// It is a string.
- EXPECT_EQ(Res_value::TYPE_STRING, value.dataType);
+ EXPECT_EQ(Res_value::TYPE_STRING, value->type);
}
TEST_F(AssetManager2Test, FindsResourceFromMultipleApkAssets) {
@@ -138,24 +132,18 @@
assetmanager.SetConfiguration(desired_config);
assetmanager.SetApkAssets({basic_assets_.get(), basic_de_fr_assets_.get()});
- Res_value value;
- ResTable_config selected_config;
- uint32_t flags;
-
- ApkAssetsCookie cookie =
- assetmanager.GetResource(basic::R::string::test1, false /*may_be_bag*/,
- 0 /*density_override*/, &value, &selected_config, &flags);
- ASSERT_NE(kInvalidCookie, cookie);
+ auto value = assetmanager.GetResource(basic::R::string::test1);
+ ASSERT_TRUE(value.has_value());
// Came from our de_fr ApkAssets.
- EXPECT_EQ(1, cookie);
+ EXPECT_EQ(1, value->cookie);
// The configuration is German.
- EXPECT_EQ('d', selected_config.language[0]);
- EXPECT_EQ('e', selected_config.language[1]);
+ EXPECT_EQ('d', value->config.language[0]);
+ EXPECT_EQ('e', value->config.language[1]);
// It is a string.
- EXPECT_EQ(Res_value::TYPE_STRING, value.dataType);
+ EXPECT_EQ(Res_value::TYPE_STRING, value->type);
}
TEST_F(AssetManager2Test, FindsResourceFromSharedLibrary) {
@@ -166,44 +154,35 @@
assetmanager.SetApkAssets(
{lib_two_assets_.get(), lib_one_assets_.get(), libclient_assets_.get()});
- Res_value value;
- ResTable_config selected_config;
- uint32_t flags;
-
- ApkAssetsCookie cookie =
- assetmanager.GetResource(libclient::R::string::foo_one, false /*may_be_bag*/,
- 0 /*density_override*/, &value, &selected_config, &flags);
- ASSERT_NE(kInvalidCookie, cookie);
+ auto value = assetmanager.GetResource(libclient::R::string::foo_one);
+ ASSERT_TRUE(value.has_value());
// Reference comes from libclient.
- EXPECT_EQ(2, cookie);
- EXPECT_EQ(Res_value::TYPE_REFERENCE, value.dataType);
+ EXPECT_EQ(2, value->cookie);
+ EXPECT_EQ(Res_value::TYPE_REFERENCE, value->type);
// Lookup the reference.
- cookie = assetmanager.GetResource(value.data, false /* may_be_bag */, 0 /* density_override*/,
- &value, &selected_config, &flags);
- ASSERT_NE(kInvalidCookie, cookie);
- EXPECT_EQ(1, cookie);
- EXPECT_EQ(Res_value::TYPE_STRING, value.dataType);
+ value = assetmanager.GetResource(value->data);
+ ASSERT_TRUE(value.has_value());
+ EXPECT_EQ(1, value->cookie);
+ EXPECT_EQ(Res_value::TYPE_STRING, value->type);
EXPECT_EQ(std::string("Foo from lib_one"),
- GetStringFromPool(assetmanager.GetStringPoolForCookie(cookie), value.data));
+ GetStringFromPool(assetmanager.GetStringPoolForCookie(value->cookie), value->data));
- cookie = assetmanager.GetResource(libclient::R::string::foo_two, false /*may_be_bag*/,
- 0 /*density_override*/, &value, &selected_config, &flags);
- ASSERT_NE(kInvalidCookie, cookie);
+ value = assetmanager.GetResource(libclient::R::string::foo_two);
+ ASSERT_TRUE(value.has_value());
// Reference comes from libclient.
- EXPECT_EQ(2, cookie);
- EXPECT_EQ(Res_value::TYPE_REFERENCE, value.dataType);
+ EXPECT_EQ(2, value->cookie);
+ EXPECT_EQ(Res_value::TYPE_REFERENCE, value->type);
// Lookup the reference.
- cookie = assetmanager.GetResource(value.data, false /* may_be_bag */, 0 /* density_override*/,
- &value, &selected_config, &flags);
- ASSERT_NE(kInvalidCookie, cookie);
- EXPECT_EQ(0, cookie);
- EXPECT_EQ(Res_value::TYPE_STRING, value.dataType);
+ value = assetmanager.GetResource(value->data);
+ ASSERT_TRUE(value.has_value());
+ EXPECT_EQ(0, value->cookie);
+ EXPECT_EQ(Res_value::TYPE_STRING, value->type);
EXPECT_EQ(std::string("Foo from lib_two"),
- GetStringFromPool(assetmanager.GetStringPoolForCookie(cookie), value.data));
+ GetStringFromPool(assetmanager.GetStringPoolForCookie(value->cookie), value->data));
}
TEST_F(AssetManager2Test, FindsResourceFromAppLoadedAsSharedLibrary) {
@@ -211,16 +190,10 @@
assetmanager.SetApkAssets({appaslib_assets_.get()});
// The appaslib package will have been assigned the package ID 0x02.
-
- Res_value value;
- ResTable_config selected_config;
- uint32_t flags;
- ApkAssetsCookie cookie = assetmanager.GetResource(
- fix_package_id(appaslib::R::integer::number1, 0x02), false /*may_be_bag*/,
- 0u /*density_override*/, &value, &selected_config, &flags);
- ASSERT_NE(kInvalidCookie, cookie);
- EXPECT_EQ(Res_value::TYPE_REFERENCE, value.dataType);
- EXPECT_EQ(fix_package_id(appaslib::R::array::integerArray1, 0x02), value.data);
+ auto value = assetmanager.GetResource(fix_package_id(appaslib::R::integer::number1, 0x02));
+ ASSERT_TRUE(value.has_value());
+ EXPECT_EQ(Res_value::TYPE_REFERENCE, value->type);
+ EXPECT_EQ(fix_package_id(appaslib::R::array::integerArray1, 0x02), value->data);
}
TEST_F(AssetManager2Test, AssignsOverlayPackageIdLast) {
@@ -238,40 +211,40 @@
return assetmanager.GetAssignedPackageId(apkAssets->GetLoadedArsc()->GetPackages()[0].get());
};
- ASSERT_EQ(get_first_package_id(overlayable_assets_.get()), 0x7f);
- ASSERT_EQ(get_first_package_id(overlay_assets_.get()), 0x03);
- ASSERT_EQ(get_first_package_id(lib_one_assets_.get()), 0x02);
+ ASSERT_EQ(0x7f, get_first_package_id(overlayable_assets_.get()));
+ ASSERT_EQ(0x03, get_first_package_id(overlay_assets_.get()));
+ ASSERT_EQ(0x02, get_first_package_id(lib_one_assets_.get()));
}
TEST_F(AssetManager2Test, GetSharedLibraryResourceName) {
AssetManager2 assetmanager;
assetmanager.SetApkAssets({lib_one_assets_.get()});
- AssetManager2::ResourceName name;
- ASSERT_TRUE(assetmanager.GetResourceName(lib_one::R::string::foo, &name));
- std::string formatted_name = ToFormattedResourceString(&name);
- ASSERT_EQ(formatted_name, "com.android.lib_one:string/foo");
+ auto name = assetmanager.GetResourceName(lib_one::R::string::foo);
+ ASSERT_TRUE(name.has_value());
+ ASSERT_EQ("com.android.lib_one:string/foo", ToFormattedResourceString(*name));
}
TEST_F(AssetManager2Test, FindsBagResourceFromSingleApkAssets) {
AssetManager2 assetmanager;
assetmanager.SetApkAssets({basic_assets_.get()});
- const ResolvedBag* bag = assetmanager.GetBag(basic::R::array::integerArray1);
- ASSERT_NE(nullptr, bag);
- ASSERT_EQ(3u, bag->entry_count);
+ auto bag = assetmanager.GetBag(basic::R::array::integerArray1);
+ ASSERT_TRUE(bag.has_value());
- EXPECT_EQ(static_cast<uint8_t>(Res_value::TYPE_INT_DEC), bag->entries[0].value.dataType);
- EXPECT_EQ(1u, bag->entries[0].value.data);
- EXPECT_EQ(0, bag->entries[0].cookie);
+ ASSERT_EQ(3u, (*bag)->entry_count);
- EXPECT_EQ(static_cast<uint8_t>(Res_value::TYPE_INT_DEC), bag->entries[1].value.dataType);
- EXPECT_EQ(2u, bag->entries[1].value.data);
- EXPECT_EQ(0, bag->entries[1].cookie);
+ EXPECT_EQ(static_cast<uint8_t>(Res_value::TYPE_INT_DEC), (*bag)->entries[0].value.dataType);
+ EXPECT_EQ(1u, (*bag)->entries[0].value.data);
+ EXPECT_EQ(0, (*bag)->entries[0].cookie);
- EXPECT_EQ(static_cast<uint8_t>(Res_value::TYPE_INT_DEC), bag->entries[2].value.dataType);
- EXPECT_EQ(3u, bag->entries[2].value.data);
- EXPECT_EQ(0, bag->entries[2].cookie);
+ EXPECT_EQ(static_cast<uint8_t>(Res_value::TYPE_INT_DEC), (*bag)->entries[1].value.dataType);
+ EXPECT_EQ(2u, (*bag)->entries[1].value.data);
+ EXPECT_EQ(0, (*bag)->entries[1].cookie);
+
+ EXPECT_EQ(static_cast<uint8_t>(Res_value::TYPE_INT_DEC), (*bag)->entries[2].value.dataType);
+ EXPECT_EQ(3u, (*bag)->entries[2].value.data);
+ EXPECT_EQ(0, (*bag)->entries[2].cookie);
}
TEST_F(AssetManager2Test, FindsBagResourceFromMultipleApkAssets) {}
@@ -284,15 +257,16 @@
assetmanager.SetApkAssets(
{lib_two_assets_.get(), lib_one_assets_.get(), libclient_assets_.get()});
- const ResolvedBag* bag = assetmanager.GetBag(fix_package_id(lib_one::R::style::Theme, 0x03));
- ASSERT_NE(nullptr, bag);
- ASSERT_GE(bag->entry_count, 2u);
+ auto bag = assetmanager.GetBag(fix_package_id(lib_one::R::style::Theme, 0x03));
+ ASSERT_TRUE(bag.has_value());
+
+ ASSERT_GE((*bag)->entry_count, 2u);
// First two attributes come from lib_one.
- EXPECT_EQ(1, bag->entries[0].cookie);
- EXPECT_EQ(0x03, get_package_id(bag->entries[0].key));
- EXPECT_EQ(1, bag->entries[1].cookie);
- EXPECT_EQ(0x03, get_package_id(bag->entries[1].key));
+ EXPECT_EQ(1, (*bag)->entries[0].cookie);
+ EXPECT_EQ(0x03, get_package_id((*bag)->entries[0].key));
+ EXPECT_EQ(1, (*bag)->entries[1].cookie);
+ EXPECT_EQ(0x03, get_package_id((*bag)->entries[1].key));
}
TEST_F(AssetManager2Test, FindsBagResourceFromMultipleSharedLibraries) {
@@ -303,17 +277,17 @@
assetmanager.SetApkAssets(
{lib_two_assets_.get(), lib_one_assets_.get(), libclient_assets_.get()});
- const ResolvedBag* bag = assetmanager.GetBag(libclient::R::style::ThemeMultiLib);
- ASSERT_NE(nullptr, bag);
- ASSERT_EQ(bag->entry_count, 2u);
+ auto bag = assetmanager.GetBag(libclient::R::style::ThemeMultiLib);
+ ASSERT_TRUE(bag.has_value());
+ ASSERT_EQ((*bag)->entry_count, 2u);
// First attribute comes from lib_two.
- EXPECT_EQ(2, bag->entries[0].cookie);
- EXPECT_EQ(0x02, get_package_id(bag->entries[0].key));
+ EXPECT_EQ(2, (*bag)->entries[0].cookie);
+ EXPECT_EQ(0x02, get_package_id((*bag)->entries[0].key));
// The next two attributes come from lib_one.
- EXPECT_EQ(2, bag->entries[1].cookie);
- EXPECT_EQ(0x03, get_package_id(bag->entries[1].key));
+ EXPECT_EQ(2, (*bag)->entries[1].cookie);
+ EXPECT_EQ(0x03, get_package_id((*bag)->entries[1].key));
}
TEST_F(AssetManager2Test, FindsStyleResourceWithParentFromSharedLibrary) {
@@ -324,79 +298,79 @@
assetmanager.SetApkAssets(
{lib_two_assets_.get(), lib_one_assets_.get(), libclient_assets_.get()});
- const ResolvedBag* bag = assetmanager.GetBag(libclient::R::style::Theme);
- ASSERT_NE(nullptr, bag);
- ASSERT_GE(bag->entry_count, 2u);
+ auto bag = assetmanager.GetBag(libclient::R::style::Theme);
+ ASSERT_TRUE(bag.has_value());
+ ASSERT_GE((*bag)->entry_count, 2u);
// First two attributes come from lib_one.
- EXPECT_EQ(1, bag->entries[0].cookie);
- EXPECT_EQ(0x03, get_package_id(bag->entries[0].key));
- EXPECT_EQ(1, bag->entries[1].cookie);
- EXPECT_EQ(0x03, get_package_id(bag->entries[1].key));
+ EXPECT_EQ(1, (*bag)->entries[0].cookie);
+ EXPECT_EQ(0x03, get_package_id((*bag)->entries[0].key));
+ EXPECT_EQ(1, (*bag)->entries[1].cookie);
+ EXPECT_EQ(0x03, get_package_id((*bag)->entries[1].key));
}
TEST_F(AssetManager2Test, MergesStylesWithParentFromSingleApkAssets) {
AssetManager2 assetmanager;
assetmanager.SetApkAssets({style_assets_.get()});
- const ResolvedBag* bag_one = assetmanager.GetBag(app::R::style::StyleOne);
- ASSERT_NE(nullptr, bag_one);
- ASSERT_EQ(2u, bag_one->entry_count);
+ auto bag_one = assetmanager.GetBag(app::R::style::StyleOne);
+ ASSERT_TRUE(bag_one.has_value());
+ ASSERT_EQ(2u, (*bag_one)->entry_count);
- EXPECT_EQ(app::R::attr::attr_one, bag_one->entries[0].key);
- EXPECT_EQ(Res_value::TYPE_INT_DEC, bag_one->entries[0].value.dataType);
- EXPECT_EQ(1u, bag_one->entries[0].value.data);
- EXPECT_EQ(0, bag_one->entries[0].cookie);
+ EXPECT_EQ(app::R::attr::attr_one, (*bag_one)->entries[0].key);
+ EXPECT_EQ(Res_value::TYPE_INT_DEC, (*bag_one)->entries[0].value.dataType);
+ EXPECT_EQ(1u, (*bag_one)->entries[0].value.data);
+ EXPECT_EQ(0, (*bag_one)->entries[0].cookie);
- EXPECT_EQ(app::R::attr::attr_two, bag_one->entries[1].key);
- EXPECT_EQ(Res_value::TYPE_INT_DEC, bag_one->entries[1].value.dataType);
- EXPECT_EQ(2u, bag_one->entries[1].value.data);
- EXPECT_EQ(0, bag_one->entries[1].cookie);
+ EXPECT_EQ(app::R::attr::attr_two, (*bag_one)->entries[1].key);
+ EXPECT_EQ(Res_value::TYPE_INT_DEC, (*bag_one)->entries[1].value.dataType);
+ EXPECT_EQ(2u, (*bag_one)->entries[1].value.data);
+ EXPECT_EQ(0, (*bag_one)->entries[1].cookie);
- const ResolvedBag* bag_two = assetmanager.GetBag(app::R::style::StyleTwo);
- ASSERT_NE(nullptr, bag_two);
- ASSERT_EQ(6u, bag_two->entry_count);
+ auto bag_two = assetmanager.GetBag(app::R::style::StyleTwo);
+ ASSERT_TRUE(bag_two.has_value());
+ ASSERT_EQ(6u, (*bag_two)->entry_count);
// attr_one is inherited from StyleOne.
- EXPECT_EQ(app::R::attr::attr_one, bag_two->entries[0].key);
- EXPECT_EQ(Res_value::TYPE_INT_DEC, bag_two->entries[0].value.dataType);
- EXPECT_EQ(1u, bag_two->entries[0].value.data);
- EXPECT_EQ(0, bag_two->entries[0].cookie);
- EXPECT_EQ(app::R::style::StyleOne, bag_two->entries[0].style);
+ EXPECT_EQ(app::R::attr::attr_one, (*bag_two)->entries[0].key);
+ EXPECT_EQ(Res_value::TYPE_INT_DEC, (*bag_two)->entries[0].value.dataType);
+ EXPECT_EQ(1u, (*bag_two)->entries[0].value.data);
+ EXPECT_EQ(0, (*bag_two)->entries[0].cookie);
+ EXPECT_EQ(app::R::style::StyleOne, (*bag_two)->entries[0].style);
// attr_two should be overridden from StyleOne by StyleTwo.
- EXPECT_EQ(app::R::attr::attr_two, bag_two->entries[1].key);
- EXPECT_EQ(Res_value::TYPE_STRING, bag_two->entries[1].value.dataType);
- EXPECT_EQ(0, bag_two->entries[1].cookie);
- EXPECT_EQ(app::R::style::StyleTwo, bag_two->entries[1].style);
+ EXPECT_EQ(app::R::attr::attr_two, (*bag_two)->entries[1].key);
+ EXPECT_EQ(Res_value::TYPE_STRING, (*bag_two)->entries[1].value.dataType);
+ EXPECT_EQ(0, (*bag_two)->entries[1].cookie);
+ EXPECT_EQ(app::R::style::StyleTwo, (*bag_two)->entries[1].style);
EXPECT_EQ(std::string("string"), GetStringFromPool(assetmanager.GetStringPoolForCookie(0),
- bag_two->entries[1].value.data));
+ (*bag_two)->entries[1].value.data));
// The rest are new attributes.
- EXPECT_EQ(app::R::attr::attr_three, bag_two->entries[2].key);
- EXPECT_EQ(Res_value::TYPE_ATTRIBUTE, bag_two->entries[2].value.dataType);
- EXPECT_EQ(app::R::attr::attr_indirect, bag_two->entries[2].value.data);
- EXPECT_EQ(0, bag_two->entries[2].cookie);
- EXPECT_EQ(app::R::style::StyleTwo, bag_two->entries[2].style);
+ EXPECT_EQ(app::R::attr::attr_three, (*bag_two)->entries[2].key);
+ EXPECT_EQ(Res_value::TYPE_ATTRIBUTE, (*bag_two)->entries[2].value.dataType);
+ EXPECT_EQ(app::R::attr::attr_indirect, (*bag_two)->entries[2].value.data);
+ EXPECT_EQ(0, (*bag_two)->entries[2].cookie);
+ EXPECT_EQ(app::R::style::StyleTwo, (*bag_two)->entries[2].style);
- EXPECT_EQ(app::R::attr::attr_five, bag_two->entries[3].key);
- EXPECT_EQ(Res_value::TYPE_REFERENCE, bag_two->entries[3].value.dataType);
- EXPECT_EQ(app::R::string::string_one, bag_two->entries[3].value.data);
- EXPECT_EQ(0, bag_two->entries[3].cookie);
- EXPECT_EQ(app::R::style::StyleTwo, bag_two->entries[3].style);
+ EXPECT_EQ(app::R::attr::attr_five, (*bag_two)->entries[3].key);
+ EXPECT_EQ(Res_value::TYPE_REFERENCE, (*bag_two)->entries[3].value.dataType);
+ EXPECT_EQ(app::R::string::string_one, (*bag_two)->entries[3].value.data);
+ EXPECT_EQ(0, (*bag_two)->entries[3].cookie);
+ EXPECT_EQ(app::R::style::StyleTwo, (*bag_two)->entries[3].style);
- EXPECT_EQ(app::R::attr::attr_indirect, bag_two->entries[4].key);
- EXPECT_EQ(Res_value::TYPE_INT_DEC, bag_two->entries[4].value.dataType);
- EXPECT_EQ(3u, bag_two->entries[4].value.data);
- EXPECT_EQ(0, bag_two->entries[4].cookie);
- EXPECT_EQ(app::R::style::StyleTwo, bag_two->entries[4].style);
+ EXPECT_EQ(app::R::attr::attr_indirect, (*bag_two)->entries[4].key);
+ EXPECT_EQ(Res_value::TYPE_INT_DEC, (*bag_two)->entries[4].value.dataType);
+ EXPECT_EQ(3u, (*bag_two)->entries[4].value.data);
+ EXPECT_EQ(0, (*bag_two)->entries[4].cookie);
+ EXPECT_EQ(app::R::style::StyleTwo, (*bag_two)->entries[4].style);
- EXPECT_EQ(app::R::attr::attr_empty, bag_two->entries[5].key);
- EXPECT_EQ(Res_value::TYPE_NULL, bag_two->entries[5].value.dataType);
- EXPECT_EQ(Res_value::DATA_NULL_EMPTY, bag_two->entries[5].value.data);
- EXPECT_EQ(0, bag_two->entries[5].cookie);
- EXPECT_EQ(app::R::style::StyleTwo, bag_two->entries[5].style);
+ EXPECT_EQ(app::R::attr::attr_empty, (*bag_two)->entries[5].key);
+ EXPECT_EQ(Res_value::TYPE_NULL, (*bag_two)->entries[5].value.dataType);
+ EXPECT_EQ(Res_value::DATA_NULL_EMPTY, (*bag_two)->entries[5].value.data);
+ EXPECT_EQ(0, (*bag_two)->entries[5].cookie);
+ EXPECT_EQ(app::R::style::StyleTwo, (*bag_two)->entries[5].style);
}
TEST_F(AssetManager2Test, MergeStylesCircularDependency) {
@@ -405,55 +379,41 @@
// GetBag should stop traversing the parents of styles when a circular
// dependency is detected
- const ResolvedBag* bag_one = assetmanager.GetBag(app::R::style::StyleFour);
- ASSERT_NE(nullptr, bag_one);
- ASSERT_EQ(3u, bag_one->entry_count);
+ auto bag = assetmanager.GetBag(app::R::style::StyleFour);
+ ASSERT_TRUE(bag.has_value());
+ ASSERT_EQ(3u, (*bag)->entry_count);
}
TEST_F(AssetManager2Test, ResolveReferenceToResource) {
AssetManager2 assetmanager;
assetmanager.SetApkAssets({basic_assets_.get()});
- Res_value value;
- ResTable_config selected_config;
- uint32_t flags;
- ApkAssetsCookie cookie =
- assetmanager.GetResource(basic::R::integer::ref1, false /*may_be_bag*/,
- 0u /*density_override*/, &value, &selected_config, &flags);
- ASSERT_NE(kInvalidCookie, cookie);
+ auto value = assetmanager.GetResource(basic::R::integer::ref1);
+ ASSERT_TRUE(value.has_value());
+ EXPECT_EQ(Res_value::TYPE_REFERENCE, value->type);
+ EXPECT_EQ(basic::R::integer::ref2, value->data);
- EXPECT_EQ(Res_value::TYPE_REFERENCE, value.dataType);
- EXPECT_EQ(basic::R::integer::ref2, value.data);
-
- uint32_t last_ref = 0u;
- cookie = assetmanager.ResolveReference(cookie, &value, &selected_config, &flags, &last_ref);
- ASSERT_NE(kInvalidCookie, cookie);
- EXPECT_EQ(Res_value::TYPE_INT_DEC, value.dataType);
- EXPECT_EQ(12000u, value.data);
- EXPECT_EQ(basic::R::integer::ref2, last_ref);
+ auto result = assetmanager.ResolveReference(*value);
+ ASSERT_TRUE(result.has_value());
+ EXPECT_EQ(Res_value::TYPE_INT_DEC, value->type);
+ EXPECT_EQ(12000u, value->data);
+ EXPECT_EQ(basic::R::integer::ref2, value->resid);
}
TEST_F(AssetManager2Test, ResolveReferenceToBag) {
AssetManager2 assetmanager;
assetmanager.SetApkAssets({basic_assets_.get()});
- Res_value value;
- ResTable_config selected_config;
- uint32_t flags;
- ApkAssetsCookie cookie =
- assetmanager.GetResource(basic::R::integer::number2, true /*may_be_bag*/,
- 0u /*density_override*/, &value, &selected_config, &flags);
- ASSERT_NE(kInvalidCookie, cookie);
+ auto value = assetmanager.GetResource(basic::R::integer::number2, true /*may_be_bag*/);
+ ASSERT_TRUE(value.has_value());
+ EXPECT_EQ(Res_value::TYPE_REFERENCE, value->type);
+ EXPECT_EQ(basic::R::array::integerArray1, value->data);
- EXPECT_EQ(Res_value::TYPE_REFERENCE, value.dataType);
- EXPECT_EQ(basic::R::array::integerArray1, value.data);
-
- uint32_t last_ref = 0u;
- cookie = assetmanager.ResolveReference(cookie, &value, &selected_config, &flags, &last_ref);
- ASSERT_NE(kInvalidCookie, cookie);
- EXPECT_EQ(Res_value::TYPE_REFERENCE, value.dataType);
- EXPECT_EQ(basic::R::array::integerArray1, value.data);
- EXPECT_EQ(basic::R::array::integerArray1, last_ref);
+ auto result = assetmanager.ResolveReference(*value);
+ ASSERT_TRUE(result.has_value());
+ EXPECT_EQ(Res_value::TYPE_REFERENCE, value->type);
+ EXPECT_EQ(basic::R::array::integerArray1, value->data);
+ EXPECT_EQ(basic::R::array::integerArray1, value->resid);
}
TEST_F(AssetManager2Test, ResolveDeepIdReference) {
@@ -461,31 +421,25 @@
assetmanager.SetApkAssets({basic_assets_.get()});
// Set up the resource ids
- const uint32_t high_ref = assetmanager
- .GetResourceId("@id/high_ref", "values", "com.android.basic");
- ASSERT_NE(high_ref, 0u);
- const uint32_t middle_ref = assetmanager
- .GetResourceId("@id/middle_ref", "values", "com.android.basic");
- ASSERT_NE(middle_ref, 0u);
- const uint32_t low_ref = assetmanager
- .GetResourceId("@id/low_ref", "values", "com.android.basic");
- ASSERT_NE(low_ref, 0u);
+ auto high_ref = assetmanager.GetResourceId("@id/high_ref", "values", "com.android.basic");
+ ASSERT_TRUE(high_ref.has_value());
+
+ auto middle_ref = assetmanager.GetResourceId("@id/middle_ref", "values", "com.android.basic");
+ ASSERT_TRUE(middle_ref.has_value());
+
+ auto low_ref = assetmanager.GetResourceId("@id/low_ref", "values", "com.android.basic");
+ ASSERT_TRUE(low_ref.has_value());
// Retrieve the most shallow resource
- Res_value value;
- ResTable_config config;
- uint32_t flags;
- ApkAssetsCookie cookie = assetmanager.GetResource(high_ref, false /*may_be_bag*/,
- 0 /*density_override*/,
- &value, &config, &flags);
- ASSERT_NE(kInvalidCookie, cookie);
- EXPECT_EQ(Res_value::TYPE_REFERENCE, value.dataType);
- EXPECT_EQ(middle_ref, value.data);
+ auto value = assetmanager.GetResource(*high_ref);
+ ASSERT_TRUE(value.has_value());
+ EXPECT_EQ(Res_value::TYPE_REFERENCE, value->type);
+ EXPECT_EQ(*middle_ref, value->data);;
// Check that resolving the reference resolves to the deepest id
- uint32_t last_ref = high_ref;
- assetmanager.ResolveReference(cookie, &value, &config, &flags, &last_ref);
- EXPECT_EQ(last_ref, low_ref);
+ auto result = assetmanager.ResolveReference(*value);
+ ASSERT_TRUE(result.has_value());
+ EXPECT_EQ(*low_ref, value->resid);
}
TEST_F(AssetManager2Test, KeepLastReferenceIdUnmodifiedIfNoReferenceIsResolved) {
@@ -495,16 +449,16 @@
ResTable_config selected_config;
memset(&selected_config, 0, sizeof(selected_config));
- uint32_t flags = 0u;
+ // Create some kind of value that is NOT a reference.
+ AssetManager2::SelectedValue value{};
+ value.cookie = 1;
+ value.type = Res_value::TYPE_STRING;
+ value.resid = basic::R::string::test1;
- // Create some kind of Res_value that is NOT a reference.
- Res_value value;
- value.dataType = Res_value::TYPE_STRING;
- value.data = 0;
-
- uint32_t last_ref = basic::R::string::test1;
- EXPECT_EQ(1, assetmanager.ResolveReference(1, &value, &selected_config, &flags, &last_ref));
- EXPECT_EQ(basic::R::string::test1, last_ref);
+ auto result = assetmanager.ResolveReference(value);
+ ASSERT_TRUE(result.has_value());
+ EXPECT_EQ(1, value.cookie);
+ EXPECT_EQ(basic::R::string::test1, value.resid);
}
static bool IsConfigurationPresent(const std::set<ResTable_config>& configurations,
@@ -516,43 +470,45 @@
AssetManager2 assetmanager;
assetmanager.SetApkAssets({system_assets_.get(), basic_de_fr_assets_.get()});
- std::set<ResTable_config> configurations = assetmanager.GetResourceConfigurations();
+ auto configurations = assetmanager.GetResourceConfigurations();
+ ASSERT_TRUE(configurations.has_value());
// We expect the locale sv from the system assets, and de and fr from basic_de_fr assets.
// And one extra for the default configuration.
- EXPECT_EQ(4u, configurations.size());
+ EXPECT_EQ(4u, configurations->size());
ResTable_config expected_config;
memset(&expected_config, 0, sizeof(expected_config));
expected_config.language[0] = 's';
expected_config.language[1] = 'v';
- EXPECT_TRUE(IsConfigurationPresent(configurations, expected_config));
+ EXPECT_TRUE(IsConfigurationPresent(*configurations, expected_config));
expected_config.language[0] = 'd';
expected_config.language[1] = 'e';
- EXPECT_TRUE(IsConfigurationPresent(configurations, expected_config));
+ EXPECT_TRUE(IsConfigurationPresent(*configurations, expected_config));
expected_config.language[0] = 'f';
expected_config.language[1] = 'r';
- EXPECT_TRUE(IsConfigurationPresent(configurations, expected_config));
+ EXPECT_TRUE(IsConfigurationPresent(*configurations, expected_config));
// Take out the system assets.
configurations = assetmanager.GetResourceConfigurations(true /* exclude_system */);
+ ASSERT_TRUE(configurations.has_value());
// We expect de and fr from basic_de_fr assets.
- EXPECT_EQ(2u, configurations.size());
+ EXPECT_EQ(2u, configurations->size());
expected_config.language[0] = 's';
expected_config.language[1] = 'v';
- EXPECT_FALSE(IsConfigurationPresent(configurations, expected_config));
+ EXPECT_FALSE(IsConfigurationPresent(*configurations, expected_config));
expected_config.language[0] = 'd';
expected_config.language[1] = 'e';
- EXPECT_TRUE(IsConfigurationPresent(configurations, expected_config));
+ EXPECT_TRUE(IsConfigurationPresent(*configurations, expected_config));
expected_config.language[0] = 'f';
expected_config.language[1] = 'r';
- EXPECT_TRUE(IsConfigurationPresent(configurations, expected_config));
+ EXPECT_TRUE(IsConfigurationPresent(*configurations, expected_config));
}
TEST_F(AssetManager2Test, GetResourceLocales) {
@@ -578,12 +534,17 @@
AssetManager2 assetmanager;
assetmanager.SetApkAssets({basic_assets_.get()});
- EXPECT_EQ(basic::R::layout::main,
- assetmanager.GetResourceId("com.android.basic:layout/main", "", ""));
- EXPECT_EQ(basic::R::layout::main,
- assetmanager.GetResourceId("layout/main", "", "com.android.basic"));
- EXPECT_EQ(basic::R::layout::main,
- assetmanager.GetResourceId("main", "layout", "com.android.basic"));
+ auto resid = assetmanager.GetResourceId("com.android.basic:layout/main", "", "");
+ ASSERT_TRUE(resid.has_value());
+ EXPECT_EQ(basic::R::layout::main, *resid);
+
+ resid = assetmanager.GetResourceId("layout/main", "", "com.android.basic");
+ ASSERT_TRUE(resid.has_value());
+ EXPECT_EQ(basic::R::layout::main, *resid);
+
+ resid = assetmanager.GetResourceId("main", "layout", "com.android.basic");
+ ASSERT_TRUE(resid.has_value());
+ EXPECT_EQ(basic::R::layout::main, *resid);
}
TEST_F(AssetManager2Test, OpensFileFromSingleApkAssets) {
@@ -658,14 +619,8 @@
assetmanager.SetApkAssets({basic_assets_.get()});
assetmanager.SetResourceResolutionLoggingEnabled(false);
- Res_value value;
- ResTable_config selected_config;
- uint32_t flags;
-
- ApkAssetsCookie cookie =
- assetmanager.GetResource(basic::R::string::test1, false /*may_be_bag*/,
- 0 /*density_override*/, &value, &selected_config, &flags);
- ASSERT_NE(kInvalidCookie, cookie);
+ auto value = assetmanager.GetResource(basic::R::string::test1);
+ ASSERT_TRUE(value.has_value());
auto result = assetmanager.GetLastResourceResolution();
EXPECT_EQ("", result);
@@ -693,17 +648,12 @@
assetmanager.SetConfiguration(desired_config);
assetmanager.SetApkAssets({basic_assets_.get()});
- Res_value value;
- ResTable_config selected_config;
- uint32_t flags;
-
- ApkAssetsCookie cookie =
- assetmanager.GetResource(basic::R::string::test1, false /*may_be_bag*/,
- 0 /*density_override*/, &value, &selected_config, &flags);
- ASSERT_NE(kInvalidCookie, cookie);
+ auto value = assetmanager.GetResource(basic::R::string::test1);
+ ASSERT_TRUE(value.has_value());
auto result = assetmanager.GetLastResourceResolution();
- EXPECT_EQ("Resolution for 0x7f030000 com.android.basic:string/test1\n\tFor config -de\n\tFound initial: com.android.basic", result);
+ EXPECT_EQ("Resolution for 0x7f030000 com.android.basic:string/test1\n"
+ "\tFor config -de\n\tFound initial: com.android.basic", result);
}
TEST_F(AssetManager2Test, GetLastPathWithMultipleApkAssets) {
@@ -717,17 +667,14 @@
assetmanager.SetConfiguration(desired_config);
assetmanager.SetApkAssets({basic_assets_.get(), basic_de_fr_assets_.get()});
- Res_value value = Res_value();
- ResTable_config selected_config;
- uint32_t flags;
-
- ApkAssetsCookie cookie =
- assetmanager.GetResource(basic::R::string::test1, false /*may_be_bag*/,
- 0 /*density_override*/, &value, &selected_config, &flags);
- ASSERT_NE(kInvalidCookie, cookie);
+ auto value = assetmanager.GetResource(basic::R::string::test1);
+ ASSERT_TRUE(value.has_value());
auto result = assetmanager.GetLastResourceResolution();
- EXPECT_EQ("Resolution for 0x7f030000 com.android.basic:string/test1\n\tFor config -de\n\tFound initial: com.android.basic\n\tFound better: com.android.basic -de", result);
+ EXPECT_EQ("Resolution for 0x7f030000 com.android.basic:string/test1\n"
+ "\tFor config -de\n"
+ "\tFound initial: com.android.basic\n"
+ "\tFound better: com.android.basic -de", result);
}
TEST_F(AssetManager2Test, GetLastPathAfterDisablingReturnsEmpty) {
@@ -739,14 +686,8 @@
assetmanager.SetConfiguration(desired_config);
assetmanager.SetApkAssets({basic_assets_.get()});
- Res_value value = Res_value();
- ResTable_config selected_config;
- uint32_t flags;
-
- ApkAssetsCookie cookie =
- assetmanager.GetResource(basic::R::string::test1, false /*may_be_bag*/,
- 0 /*density_override*/, &value, &selected_config, &flags);
- ASSERT_NE(kInvalidCookie, cookie);
+ auto value = assetmanager.GetResource(basic::R::string::test1);
+ ASSERT_TRUE(value.has_value());
auto resultEnabled = assetmanager.GetLastResourceResolution();
ASSERT_NE("", resultEnabled);
diff --git a/libs/androidfw/tests/AttributeResolution_bench.cpp b/libs/androidfw/tests/AttributeResolution_bench.cpp
index fa300c5..ddd8ab8 100644
--- a/libs/androidfw/tests/AttributeResolution_bench.cpp
+++ b/libs/androidfw/tests/AttributeResolution_bench.cpp
@@ -108,27 +108,20 @@
device_config.screenHeightDp = 1024;
device_config.sdkVersion = 27;
- Res_value value;
- ResTable_config config;
- uint32_t flags = 0u;
- ApkAssetsCookie cookie =
- assetmanager.GetResource(basic::R::layout::layoutt, false /*may_be_bag*/,
- 0u /*density_override*/, &value, &config, &flags);
- if (cookie == kInvalidCookie) {
+ auto value = assetmanager.GetResource(basic::R::layout::layoutt);
+ if (!value.has_value()) {
state.SkipWithError("failed to find R.layout.layout");
return;
}
- size_t len = 0u;
- const char* layout_path =
- assetmanager.GetStringPoolForCookie(cookie)->string8At(value.data, &len);
- if (layout_path == nullptr || len == 0u) {
+ auto layout_path = assetmanager.GetStringPoolForCookie(value->cookie)->string8At(value->data);
+ if (!layout_path.has_value()) {
state.SkipWithError("failed to lookup layout path");
return;
}
- std::unique_ptr<Asset> asset = assetmanager.OpenNonAsset(
- StringPiece(layout_path, len).to_string(), cookie, Asset::ACCESS_BUFFER);
+ std::unique_ptr<Asset> asset = assetmanager.OpenNonAsset(layout_path->to_string(), value->cookie,
+ Asset::ACCESS_BUFFER);
if (asset == nullptr) {
state.SkipWithError("failed to load layout");
return;
diff --git a/libs/androidfw/tests/AttributeResolution_test.cpp b/libs/androidfw/tests/AttributeResolution_test.cpp
index 24361b5..bb9129a 100644
--- a/libs/androidfw/tests/AttributeResolution_test.cpp
+++ b/libs/androidfw/tests/AttributeResolution_test.cpp
@@ -77,9 +77,9 @@
{fix_package_id(R::attr::attr_one, 0x02), fix_package_id(R::attr::attr_two, 0x02)}};
std::array<uint32_t, attrs.size() * STYLE_NUM_ENTRIES> values;
std::array<uint32_t, attrs.size() + 1> indices;
- ApplyStyle(theme.get(), nullptr /*xml_parser*/, 0u /*def_style_attr*/,
- fix_package_id(R::style::StyleOne, 0x02), attrs.data(), attrs.size(), values.data(),
- indices.data());
+ ASSERT_TRUE(ApplyStyle(theme.get(), nullptr /*xml_parser*/, 0u /*def_style_attr*/,
+ fix_package_id(R::style::StyleOne, 0x02), attrs.data(), attrs.size(),
+ values.data(), indices.data()).has_value());
const uint32_t public_flag = ResTable_typeSpec::SPEC_PUBLIC;
@@ -102,7 +102,7 @@
TEST_F(AttributeResolutionTest, Theme) {
std::unique_ptr<Theme> theme = assetmanager_.NewTheme();
- ASSERT_TRUE(theme->ApplyStyle(R::style::StyleTwo));
+ ASSERT_TRUE(theme->ApplyStyle(R::style::StyleTwo).has_value());
std::array<uint32_t, 5> attrs{{R::attr::attr_one, R::attr::attr_two, R::attr::attr_three,
R::attr::attr_four, R::attr::attr_empty}};
@@ -110,7 +110,7 @@
ASSERT_TRUE(ResolveAttrs(theme.get(), 0u /*def_style_attr*/, 0u /*def_style_res*/,
nullptr /*src_values*/, 0 /*src_values_length*/, attrs.data(),
- attrs.size(), values.data(), nullptr /*out_indices*/));
+ attrs.size(), values.data(), nullptr /*out_indices*/).has_value());
const uint32_t public_flag = ResTable_typeSpec::SPEC_PUBLIC;
@@ -162,7 +162,7 @@
std::array<uint32_t, attrs.size() * STYLE_NUM_ENTRIES> values;
ASSERT_TRUE(RetrieveAttributes(&assetmanager_, &xml_parser_, attrs.data(), attrs.size(),
- values.data(), nullptr /*out_indices*/));
+ values.data(), nullptr /*out_indices*/).has_value());
uint32_t* values_cursor = values.data();
EXPECT_EQ(Res_value::TYPE_NULL, values_cursor[STYLE_TYPE]);
@@ -207,15 +207,15 @@
TEST_F(AttributeResolutionXmlTest, ThemeAndXmlParser) {
std::unique_ptr<Theme> theme = assetmanager_.NewTheme();
- ASSERT_TRUE(theme->ApplyStyle(R::style::StyleTwo));
+ ASSERT_TRUE(theme->ApplyStyle(R::style::StyleTwo).has_value());
std::array<uint32_t, 6> attrs{{R::attr::attr_one, R::attr::attr_two, R::attr::attr_three,
R::attr::attr_four, R::attr::attr_five, R::attr::attr_empty}};
std::array<uint32_t, attrs.size() * STYLE_NUM_ENTRIES> values;
std::array<uint32_t, attrs.size() + 1> indices;
- ApplyStyle(theme.get(), &xml_parser_, 0u /*def_style_attr*/, 0u /*def_style_res*/, attrs.data(),
- attrs.size(), values.data(), indices.data());
+ ASSERT_TRUE(ApplyStyle(theme.get(), &xml_parser_, 0u /*def_style_attr*/, 0u /*def_style_res*/,
+ attrs.data(), attrs.size(), values.data(), indices.data()).has_value());
const uint32_t public_flag = ResTable_typeSpec::SPEC_PUBLIC;
diff --git a/libs/androidfw/tests/BenchmarkHelpers.cpp b/libs/androidfw/tests/BenchmarkHelpers.cpp
index faddfe5..0fa0573 100644
--- a/libs/androidfw/tests/BenchmarkHelpers.cpp
+++ b/libs/androidfw/tests/BenchmarkHelpers.cpp
@@ -71,15 +71,9 @@
assetmanager.SetConfiguration(*config);
}
- Res_value value;
- ResTable_config selected_config;
- uint32_t flags;
- uint32_t last_id = 0u;
-
while (state.KeepRunning()) {
- ApkAssetsCookie cookie = assetmanager.GetResource(
- resid, false /* may_be_bag */, 0u /* density_override */, &value, &selected_config, &flags);
- assetmanager.ResolveReference(cookie, &value, &selected_config, &flags, &last_id);
+ auto value = assetmanager.GetResource(resid);
+ assetmanager.ResolveReference(*value);
}
}
diff --git a/libs/androidfw/tests/CommonHelpers.cpp b/libs/androidfw/tests/CommonHelpers.cpp
index faa5350..3396729 100644
--- a/libs/androidfw/tests/CommonHelpers.cpp
+++ b/libs/androidfw/tests/CommonHelpers.cpp
@@ -58,8 +58,9 @@
}
std::string GetStringFromPool(const ResStringPool* pool, uint32_t idx) {
- String8 str = pool->string8ObjectAt(idx);
- return std::string(str.string(), str.length());
+ auto str = pool->string8ObjectAt(idx);
+ CHECK(str.has_value()) << "failed to find string entry";
+ return std::string(str->string(), str->length());
}
} // namespace android
diff --git a/libs/androidfw/tests/Idmap_test.cpp b/libs/androidfw/tests/Idmap_test.cpp
index 7aa0dbb..3f0c7cb 100644
--- a/libs/androidfw/tests/Idmap_test.cpp
+++ b/libs/androidfw/tests/Idmap_test.cpp
@@ -62,10 +62,10 @@
std::unique_ptr<const ApkAssets> overlayable_assets_;
};
-std::string GetStringFromApkAssets(const AssetManager2& asset_manager, const Res_value& value,
- ApkAssetsCookie cookie) {
+std::string GetStringFromApkAssets(const AssetManager2& asset_manager,
+ const AssetManager2::SelectedValue& value) {
auto assets = asset_manager.GetApkAssets();
- const ResStringPool* string_pool = assets[cookie]->GetLoadedArsc()->GetStringPool();
+ const ResStringPool* string_pool = assets[value.cookie]->GetLoadedArsc()->GetStringPool();
return GetStringFromPool(string_pool, value.data);
}
@@ -75,117 +75,88 @@
AssetManager2 asset_manager;
asset_manager.SetApkAssets({system_assets_.get(), overlayable_assets_.get(),
overlay_assets_.get()});
- Res_value val;
- ResTable_config config;
- uint32_t flags;
- ApkAssetsCookie cookie = asset_manager.GetResource(overlayable::R::string::overlayable5,
- false /* may_be_bag */,
- 0 /* density_override */, &val, &config,
- &flags);
- ASSERT_EQ(cookie, 2U);
- ASSERT_EQ(val.dataType, Res_value::TYPE_STRING);
- ASSERT_EQ(GetStringFromApkAssets(asset_manager, val, cookie), "Overlay One");
+
+ auto value = asset_manager.GetResource(overlayable::R::string::overlayable5);
+ ASSERT_TRUE(value.has_value());
+ ASSERT_EQ(value->cookie, 2U);
+ ASSERT_EQ(value->type, Res_value::TYPE_STRING);
+ ASSERT_EQ("Overlay One", GetStringFromApkAssets(asset_manager, *value));
}
TEST_F(IdmapTest, OverlayOverridesResourceValueUsingDifferentPackage) {
AssetManager2 asset_manager;
asset_manager.SetApkAssets({system_assets_.get(), overlayable_assets_.get(),
overlay_assets_.get()});
- Res_value val;
- ResTable_config config;
- uint32_t flags;
- ApkAssetsCookie cookie = asset_manager.GetResource(overlayable::R::string::overlayable10,
- false /* may_be_bag */,
- 0 /* density_override */, &val, &config,
- &flags);
- ASSERT_EQ(cookie, 0U);
- ASSERT_EQ(val.dataType, Res_value::TYPE_STRING);
- ASSERT_EQ(GetStringFromApkAssets(asset_manager, val, cookie), "yes");
+
+ auto value = asset_manager.GetResource(overlayable::R::string::overlayable10);
+ ASSERT_TRUE(value.has_value());
+ ASSERT_EQ(value->cookie, 0U);
+ ASSERT_EQ(value->type, Res_value::TYPE_STRING);
+ ASSERT_EQ("yes", GetStringFromApkAssets(asset_manager, *value));
}
TEST_F(IdmapTest, OverlayOverridesResourceValueUsingInternalResource) {
AssetManager2 asset_manager;
asset_manager.SetApkAssets({system_assets_.get(), overlayable_assets_.get(),
overlay_assets_.get()});
- Res_value val;
- ResTable_config config;
- uint32_t flags;
- ApkAssetsCookie cookie = asset_manager.GetResource(overlayable::R::string::overlayable8,
- false /* may_be_bag */,
- 0 /* density_override */, &val, &config,
- &flags);
- ASSERT_EQ(cookie, 2U);
- ASSERT_EQ(val.dataType, Res_value::TYPE_REFERENCE);
- ASSERT_EQ(val.data, (overlay::R::string::internal & 0x00ffffff) | (0x02 << 24));
+
+ auto value = asset_manager.GetResource(overlayable::R::string::overlayable8);
+ ASSERT_TRUE(value.has_value());
+ ASSERT_EQ(value->cookie, 2U);
+ ASSERT_EQ(value->type, Res_value::TYPE_REFERENCE);
+ ASSERT_EQ(value->data, (overlay::R::string::internal & 0x00ffffffU) | (0x02U << 24));
}
TEST_F(IdmapTest, OverlayOverridesResourceValueUsingInlineInteger) {
AssetManager2 asset_manager;
asset_manager.SetApkAssets({system_assets_.get(), overlayable_assets_.get(),
overlay_assets_.get()});
- Res_value val;
- ResTable_config config;
- uint32_t flags;
- ApkAssetsCookie cookie = asset_manager.GetResource(overlayable::R::integer::config_integer,
- false /* may_be_bag */,
- 0 /* density_override */, &val, &config,
- &flags);
- ASSERT_EQ(cookie, 2U);
- ASSERT_EQ(val.dataType, Res_value::TYPE_INT_DEC);
- ASSERT_EQ(val.data, 42);
+
+ auto value = asset_manager.GetResource(overlayable::R::integer::config_integer);
+ ASSERT_TRUE(value.has_value());
+ ASSERT_EQ(value->cookie, 2U);
+ ASSERT_EQ(value->type, Res_value::TYPE_INT_DEC);
+ ASSERT_EQ(value->data, 42);
}
TEST_F(IdmapTest, OverlayOverridesResourceValueUsingInlineString) {
AssetManager2 asset_manager;
asset_manager.SetApkAssets({system_assets_.get(), overlayable_assets_.get(),
overlay_assets_.get()});
- Res_value val;
- ResTable_config config;
- uint32_t flags;
- ApkAssetsCookie cookie = asset_manager.GetResource(overlayable::R::string::overlayable11,
- false /* may_be_bag */,
- 0 /* density_override */, &val, &config,
- &flags);
- ASSERT_EQ(cookie, 2U);
- ASSERT_EQ(val.dataType, Res_value::TYPE_STRING);
- ASSERT_EQ(GetStringFromApkAssets(asset_manager, val, cookie), "Hardcoded string");
+ auto value = asset_manager.GetResource(overlayable::R::string::overlayable11);
+ ASSERT_TRUE(value.has_value());
+ ASSERT_EQ(value->cookie, 2U);
+ ASSERT_EQ(value->type, Res_value::TYPE_STRING);
+ ASSERT_EQ("Hardcoded string", GetStringFromApkAssets(asset_manager, *value));
}
TEST_F(IdmapTest, OverlayOverridesResourceValueUsingOverlayingResource) {
AssetManager2 asset_manager;
asset_manager.SetApkAssets({system_assets_.get(), overlayable_assets_.get(),
overlay_assets_.get()});
- Res_value val;
- ResTable_config config;
- uint32_t flags;
- ApkAssetsCookie cookie = asset_manager.GetResource(overlayable::R::string::overlayable9,
- false /* may_be_bag */,
- 0 /* density_override */, &val, &config,
- &flags);
- ASSERT_EQ(cookie, 2U);
- ASSERT_EQ(val.dataType, Res_value::TYPE_REFERENCE);
- ASSERT_EQ(val.data, overlayable::R::string::overlayable7);
+
+ auto value = asset_manager.GetResource(overlayable::R::string::overlayable9);
+ ASSERT_TRUE(value.has_value());
+ ASSERT_EQ(value->cookie, 2U);
+ ASSERT_EQ(value->type, Res_value::TYPE_REFERENCE);
+ ASSERT_EQ(value->data, overlayable::R::string::overlayable7);
}
TEST_F(IdmapTest, OverlayOverridesXmlParser) {
AssetManager2 asset_manager;
asset_manager.SetApkAssets({system_assets_.get(), overlayable_assets_.get(),
overlay_assets_.get()});
- Res_value val;
- ResTable_config config;
- uint32_t flags;
- ApkAssetsCookie cookie = asset_manager.GetResource(overlayable::R::layout::hello_view,
- false /* may_be_bag */,
- 0 /* density_override */, &val, &config,
- &flags);
- ASSERT_EQ(cookie, 2U);
- ASSERT_EQ(val.dataType, Res_value::TYPE_STRING);
- ASSERT_EQ(GetStringFromApkAssets(asset_manager, val, cookie), "res/layout/hello_view.xml");
- auto asset = asset_manager.OpenNonAsset("res/layout/hello_view.xml", cookie,
+ auto value = asset_manager.GetResource(overlayable::R::layout::hello_view);
+ ASSERT_TRUE(value.has_value());
+ ASSERT_EQ(value->cookie, 2U);
+ ASSERT_EQ(value->type, Res_value::TYPE_STRING);
+ ASSERT_EQ("res/layout/hello_view.xml", GetStringFromApkAssets(asset_manager, *value));
+
+ auto asset = asset_manager.OpenNonAsset("res/layout/hello_view.xml", value->cookie,
Asset::ACCESS_RANDOM);
- auto dynamic_ref_table = asset_manager.GetDynamicRefTableForCookie(cookie);
+ auto dynamic_ref_table = asset_manager.GetDynamicRefTableForCookie(value->cookie);
auto xml_tree = util::make_unique<ResXMLTree>(std::move(dynamic_ref_table));
status_t err = xml_tree->setTo(asset->getBuffer(true), asset->getLength(), false);
ASSERT_EQ(err, NO_ERROR);
@@ -216,32 +187,24 @@
asset_manager.SetApkAssets({system_assets_.get(), overlayable_assets_.get(),
overlay_assets_.get()});
- AssetManager2::ResourceName name;
- ASSERT_TRUE(asset_manager.GetResourceName(overlayable::R::string::overlayable9, &name));
- ASSERT_EQ(std::string(name.package), "com.android.overlayable");
- ASSERT_EQ(String16(name.type16), u"string");
- ASSERT_EQ(std::string(name.entry), "overlayable9");
+ auto name = asset_manager.GetResourceName(overlayable::R::string::overlayable9);
+ ASSERT_TRUE(name.has_value());
+ ASSERT_EQ("com.android.overlayable", std::string(name->package));
+ ASSERT_EQ(std::u16string(u"string"), std::u16string(name->type16));
+ ASSERT_EQ("overlayable9", std::string(name->entry));
}
TEST_F(IdmapTest, OverlayLoaderInterop) {
- std::string contents;
auto loader_assets = ApkAssets::LoadTable("loader/resources.arsc", PROPERTY_LOADER);
-
AssetManager2 asset_manager;
asset_manager.SetApkAssets({overlayable_assets_.get(), loader_assets.get(),
overlay_assets_.get()});
- Res_value val;
- ResTable_config config;
- uint32_t flags;
- ApkAssetsCookie cookie = asset_manager.GetResource(overlayable::R::string::overlayable11,
- false /* may_be_bag */,
- 0 /* density_override */, &val, &config,
- &flags);
- std::cout << asset_manager.GetLastResourceResolution();
- ASSERT_EQ(cookie, 1U);
- ASSERT_EQ(val.dataType, Res_value::TYPE_STRING);
- ASSERT_EQ(GetStringFromApkAssets(asset_manager, val, cookie), "loader");
+ auto value = asset_manager.GetResource(overlayable::R::string::overlayable11);
+ ASSERT_TRUE(value.has_value());
+ ASSERT_EQ(1U, value->cookie);
+ ASSERT_EQ(Res_value::TYPE_STRING, value->type);
+ ASSERT_EQ("loader", GetStringFromApkAssets(asset_manager, *value));
}
TEST_F(IdmapTest, OverlayAssetsIsUpToDate) {
diff --git a/libs/androidfw/tests/LoadedArsc_test.cpp b/libs/androidfw/tests/LoadedArsc_test.cpp
index 2d69dfe..6357411 100644
--- a/libs/androidfw/tests/LoadedArsc_test.cpp
+++ b/libs/androidfw/tests/LoadedArsc_test.cpp
@@ -50,7 +50,8 @@
ASSERT_TRUE(ReadFileFromZipToString(GetTestDataPath() + "/styles/styles.apk", "resources.arsc",
&contents));
- std::unique_ptr<const LoadedArsc> loaded_arsc = LoadedArsc::Load(StringPiece(contents));
+ auto loaded_arsc = LoadedArsc::Load(reinterpret_cast<const void*>(contents.data()),
+ contents.length());
ASSERT_THAT(loaded_arsc, NotNull());
const LoadedPackage* package =
@@ -66,9 +67,8 @@
ASSERT_THAT(type_spec, NotNull());
ASSERT_THAT(type_spec->type_count, Ge(1u));
- const ResTable_type* type = type_spec->types[0];
- ASSERT_THAT(type, NotNull());
- ASSERT_THAT(LoadedPackage::GetEntry(type, entry_index), NotNull());
+ auto type = type_spec->types[0];
+ ASSERT_TRUE(LoadedPackage::GetEntry(type, entry_index).has_value());
}
TEST(LoadedArscTest, LoadSparseEntryApp) {
@@ -76,7 +76,8 @@
ASSERT_TRUE(ReadFileFromZipToString(GetTestDataPath() + "/sparse/sparse.apk", "resources.arsc",
&contents));
- std::unique_ptr<const LoadedArsc> loaded_arsc = LoadedArsc::Load(StringPiece(contents));
+ std::unique_ptr<const LoadedArsc> loaded_arsc = LoadedArsc::Load(contents.data(),
+ contents.length());
ASSERT_THAT(loaded_arsc, NotNull());
const LoadedPackage* package =
@@ -90,9 +91,8 @@
ASSERT_THAT(type_spec, NotNull());
ASSERT_THAT(type_spec->type_count, Ge(1u));
- const ResTable_type* type = type_spec->types[0];
- ASSERT_THAT(type, NotNull());
- ASSERT_THAT(LoadedPackage::GetEntry(type, entry_index), NotNull());
+ auto type = type_spec->types[0];
+ ASSERT_TRUE(LoadedPackage::GetEntry(type, entry_index).has_value());
}
TEST(LoadedArscTest, LoadSharedLibrary) {
@@ -100,7 +100,8 @@
ASSERT_TRUE(ReadFileFromZipToString(GetTestDataPath() + "/lib_one/lib_one.apk", "resources.arsc",
&contents));
- std::unique_ptr<const LoadedArsc> loaded_arsc = LoadedArsc::Load(StringPiece(contents));
+ std::unique_ptr<const LoadedArsc> loaded_arsc = LoadedArsc::Load(contents.data(),
+ contents.length());
ASSERT_THAT(loaded_arsc, NotNull());
const auto& packages = loaded_arsc->GetPackages();
@@ -120,7 +121,8 @@
ASSERT_TRUE(ReadFileFromZipToString(GetTestDataPath() + "/libclient/libclient.apk",
"resources.arsc", &contents));
- std::unique_ptr<const LoadedArsc> loaded_arsc = LoadedArsc::Load(StringPiece(contents));
+ std::unique_ptr<const LoadedArsc> loaded_arsc = LoadedArsc::Load(contents.data(),
+ contents.length());
ASSERT_THAT(loaded_arsc, NotNull());
const auto& packages = loaded_arsc->GetPackages();
@@ -145,8 +147,10 @@
ASSERT_TRUE(ReadFileFromZipToString(GetTestDataPath() + "/appaslib/appaslib.apk",
"resources.arsc", &contents));
- std::unique_ptr<const LoadedArsc> loaded_arsc =
- LoadedArsc::Load(StringPiece(contents), nullptr /* loaded_idmap */, PROPERTY_DYNAMIC);
+ std::unique_ptr<const LoadedArsc> loaded_arsc = LoadedArsc::Load(contents.data(),
+ contents.length(),
+ nullptr /* loaded_idmap */,
+ PROPERTY_DYNAMIC);
ASSERT_THAT(loaded_arsc, NotNull());
const auto& packages = loaded_arsc->GetPackages();
@@ -159,7 +163,8 @@
std::string contents;
ASSERT_TRUE(ReadFileFromZipToString(GetTestDataPath() + "/feature/feature.apk", "resources.arsc",
&contents));
- std::unique_ptr<const LoadedArsc> loaded_arsc = LoadedArsc::Load(StringPiece(contents));
+ std::unique_ptr<const LoadedArsc> loaded_arsc = LoadedArsc::Load(contents.data(),
+ contents.length());
ASSERT_THAT(loaded_arsc, NotNull());
const LoadedPackage* package =
@@ -172,15 +177,12 @@
const TypeSpec* type_spec = package->GetTypeSpecByTypeIndex(type_index);
ASSERT_THAT(type_spec, NotNull());
ASSERT_THAT(type_spec->type_count, Ge(1u));
- ASSERT_THAT(type_spec->types[0], NotNull());
- size_t len;
- const char16_t* type_name16 =
- package->GetTypeStringPool()->stringAt(type_spec->type_spec->id - 1, &len);
- ASSERT_THAT(type_name16, NotNull());
- EXPECT_THAT(util::Utf16ToUtf8(StringPiece16(type_name16, len)), StrEq("string"));
+ auto type_name16 = package->GetTypeStringPool()->stringAt(type_spec->type_spec->id - 1);
+ ASSERT_TRUE(type_name16.has_value());
+ EXPECT_THAT(util::Utf16ToUtf8(*type_name16), StrEq("string"));
- ASSERT_THAT(LoadedPackage::GetEntry(type_spec->types[0], entry_index), NotNull());
+ ASSERT_TRUE(LoadedPackage::GetEntry(type_spec->types[0], entry_index).has_value());
}
// AAPT(2) generates resource tables with chunks in a certain order. The rule is that
@@ -205,7 +207,8 @@
ReadFileFromZipToString(GetTestDataPath() + "/out_of_order_types/out_of_order_types.apk",
"resources.arsc", &contents));
- std::unique_ptr<const LoadedArsc> loaded_arsc = LoadedArsc::Load(StringPiece(contents));
+ std::unique_ptr<const LoadedArsc> loaded_arsc = LoadedArsc::Load(contents.data(),
+ contents.length());
ASSERT_THAT(loaded_arsc, NotNull());
ASSERT_THAT(loaded_arsc->GetPackages(), SizeIs(1u));
@@ -215,12 +218,10 @@
const TypeSpec* type_spec = package->GetTypeSpecByTypeIndex(0);
ASSERT_THAT(type_spec, NotNull());
ASSERT_THAT(type_spec->type_count, Ge(1u));
- ASSERT_THAT(type_spec->types[0], NotNull());
type_spec = package->GetTypeSpecByTypeIndex(1);
ASSERT_THAT(type_spec, NotNull());
ASSERT_THAT(type_spec->type_count, Ge(1u));
- ASSERT_THAT(type_spec->types[0], NotNull());
}
TEST(LoadedArscTest, LoadOverlayable) {
@@ -228,7 +229,8 @@
ASSERT_TRUE(ReadFileFromZipToString(GetTestDataPath() + "/overlayable/overlayable.apk",
"resources.arsc", &contents));
- std::unique_ptr<const LoadedArsc> loaded_arsc = LoadedArsc::Load(StringPiece(contents));
+ std::unique_ptr<const LoadedArsc> loaded_arsc = LoadedArsc::Load(contents.data(),
+ contents.length());
ASSERT_THAT(loaded_arsc, NotNull());
const LoadedPackage* package = loaded_arsc->GetPackageById(
@@ -272,7 +274,8 @@
ASSERT_TRUE(
ReadFileFromZipToString(GetTestDataPath() + "/basic/basic.apk", "resources.arsc", &contents));
- std::unique_ptr<const LoadedArsc> loaded_arsc = LoadedArsc::Load(StringPiece(contents));
+ std::unique_ptr<const LoadedArsc> loaded_arsc = LoadedArsc::Load(contents.data(),
+ contents.length());
ASSERT_NE(nullptr, loaded_arsc);
const std::vector<std::unique_ptr<const LoadedPackage>>& packages = loaded_arsc->GetPackages();
@@ -320,7 +323,8 @@
ASSERT_TRUE(ReadFileFromZipToString(GetTestDataPath() + "/overlayable/overlayable.apk",
"resources.arsc", &contents));
- std::unique_ptr<const LoadedArsc> loaded_arsc = LoadedArsc::Load(StringPiece(contents));
+ std::unique_ptr<const LoadedArsc> loaded_arsc = LoadedArsc::Load(contents.data(),
+ contents.length());
ASSERT_NE(nullptr, loaded_arsc);
const std::vector<std::unique_ptr<const LoadedPackage>>& packages = loaded_arsc->GetPackages();
@@ -345,7 +349,7 @@
asset->getLength());
std::unique_ptr<const LoadedArsc> loaded_arsc =
- LoadedArsc::Load(data, nullptr, PROPERTY_LOADER);
+ LoadedArsc::Load(data.data(), data.length(), nullptr, PROPERTY_LOADER);
ASSERT_THAT(loaded_arsc, NotNull());
const LoadedPackage* package =
@@ -361,9 +365,8 @@
ASSERT_THAT(type_spec, NotNull());
ASSERT_THAT(type_spec->type_count, Ge(1u));
- const ResTable_type* type = type_spec->types[0];
- ASSERT_THAT(type, NotNull());
- ASSERT_THAT(LoadedPackage::GetEntry(type, entry_index), NotNull());
+ auto type = type_spec->types[0];
+ ASSERT_TRUE(LoadedPackage::GetEntry(type, entry_index).has_value());
}
// structs with size fields (like Res_value, ResTable_entry) should be
diff --git a/libs/androidfw/tests/ResTable_test.cpp b/libs/androidfw/tests/ResTable_test.cpp
index 326474e..9aeb00c 100644
--- a/libs/androidfw/tests/ResTable_test.cpp
+++ b/libs/androidfw/tests/ResTable_test.cpp
@@ -442,22 +442,22 @@
ASSERT_LT(val.data, pool->size());
// Make sure a string with a truncated length is read to its correct length
- size_t str_len;
- const char* target_str8 = pool->string8At(val.data, &str_len);
- ASSERT_TRUE(target_str8 != NULL);
- ASSERT_EQ(size_t(40076), String8(target_str8, str_len).size());
- ASSERT_EQ(target_str8[40075], ']');
+ auto target_str8 = pool->string8At(val.data);
+ ASSERT_TRUE(target_str8.has_value());
+ ASSERT_EQ(size_t(40076), String8(target_str8->data(), target_str8->size()).size());
+ ASSERT_EQ(target_str8->data()[40075], ']');
- const char16_t* target_str16 = pool->stringAt(val.data, &str_len);
- ASSERT_TRUE(target_str16 != NULL);
- ASSERT_EQ(size_t(40076), String16(target_str16, str_len).size());
- ASSERT_EQ(target_str8[40075], (char16_t) ']');
+ auto target_str16 = pool->stringAt(val.data);
+ ASSERT_TRUE(target_str16.has_value());
+ ASSERT_EQ(size_t(40076), String16(target_str16->data(), target_str16->size()).size());
+ ASSERT_EQ(target_str8->data()[40075], (char16_t) ']');
// Load an edited apk with the null terminator removed from the end of the
// string
std::string invalid_contents;
- ASSERT_TRUE(ReadFileFromZipToString(GetTestDataPath() + "/length_decode/length_decode_invalid.apk",
- "resources.arsc", &invalid_contents));
+ ASSERT_TRUE(ReadFileFromZipToString(
+ GetTestDataPath() + "/length_decode/length_decode_invalid.apk", "resources.arsc",
+ &invalid_contents));
ResTable invalid_table;
ASSERT_EQ(NO_ERROR, invalid_table.add(invalid_contents.data(), invalid_contents.size()));
@@ -472,8 +472,8 @@
// Make sure a string with a truncated length that is not null terminated errors
// and does not return the string
- ASSERT_TRUE(invalid_pool->string8At(invalid_val.data, &str_len) == NULL);
- ASSERT_TRUE(invalid_pool->stringAt(invalid_val.data, &str_len) == NULL);
+ ASSERT_FALSE(invalid_pool->string8At(invalid_val.data).has_value());
+ ASSERT_FALSE(invalid_pool->stringAt(invalid_val.data).has_value());
}
} // namespace android
diff --git a/libs/androidfw/tests/TestHelpers.cpp b/libs/androidfw/tests/TestHelpers.cpp
index a81bb6f..10c0a4f 100644
--- a/libs/androidfw/tests/TestHelpers.cpp
+++ b/libs/androidfw/tests/TestHelpers.cpp
@@ -73,11 +73,15 @@
return AssertionFailure() << "table has no string pool for block " << block;
}
- const String8 actual_str = pool->string8ObjectAt(val.data);
- if (String8(expected_str) != actual_str) {
- return AssertionFailure() << actual_str.string();
+ auto actual_str = pool->string8ObjectAt(val.data);
+ if (!actual_str.has_value()) {
+ return AssertionFailure() << "could not find string entry";
}
- return AssertionSuccess() << actual_str.string();
+
+ if (String8(expected_str) != *actual_str) {
+ return AssertionFailure() << actual_str->string();
+ }
+ return AssertionSuccess() << actual_str->string();
}
} // namespace android
diff --git a/libs/androidfw/tests/Theme_bench.cpp b/libs/androidfw/tests/Theme_bench.cpp
index 594c39e..f3d60bb 100644
--- a/libs/androidfw/tests/Theme_bench.cpp
+++ b/libs/androidfw/tests/Theme_bench.cpp
@@ -70,11 +70,8 @@
auto theme = assets.NewTheme();
theme->ApplyStyle(kStyleId, false /* force */);
- Res_value value;
- uint32_t flags;
-
while (state.KeepRunning()) {
- theme->GetAttribute(kAttrId, &value, &flags);
+ theme->GetAttribute(kAttrId);
}
}
BENCHMARK(BM_ThemeGetAttribute);
diff --git a/libs/androidfw/tests/Theme_test.cpp b/libs/androidfw/tests/Theme_test.cpp
index 16b9c75..f658735 100644
--- a/libs/androidfw/tests/Theme_test.cpp
+++ b/libs/androidfw/tests/Theme_test.cpp
@@ -67,10 +67,7 @@
std::unique_ptr<Theme> theme = assetmanager.NewTheme();
EXPECT_EQ(0u, theme->GetChangingConfigurations());
EXPECT_EQ(&assetmanager, theme->GetAssetManager());
-
- Res_value value;
- uint32_t flags;
- EXPECT_EQ(kInvalidCookie, theme->GetAttribute(app::R::attr::attr_one, &value, &flags));
+ EXPECT_FALSE(theme->GetAttribute(app::R::attr::attr_one).has_value());
}
TEST_F(ThemeTest, SingleThemeNoParent) {
@@ -78,23 +75,19 @@
assetmanager.SetApkAssets({style_assets_.get()});
std::unique_ptr<Theme> theme = assetmanager.NewTheme();
- ASSERT_TRUE(theme->ApplyStyle(app::R::style::StyleOne));
+ ASSERT_TRUE(theme->ApplyStyle(app::R::style::StyleOne).has_value());
- Res_value value;
- uint32_t flags;
- ApkAssetsCookie cookie;
+ auto value = theme->GetAttribute(app::R::attr::attr_one);
+ ASSERT_TRUE(value);
+ EXPECT_EQ(Res_value::TYPE_INT_DEC, value->type);
+ EXPECT_EQ(1u, value->data);
+ EXPECT_EQ(static_cast<uint32_t>(ResTable_typeSpec::SPEC_PUBLIC), value->flags);
- cookie = theme->GetAttribute(app::R::attr::attr_one, &value, &flags);
- ASSERT_NE(kInvalidCookie, cookie);
- EXPECT_EQ(Res_value::TYPE_INT_DEC, value.dataType);
- EXPECT_EQ(1u, value.data);
- EXPECT_EQ(static_cast<uint32_t>(ResTable_typeSpec::SPEC_PUBLIC), flags);
-
- cookie = theme->GetAttribute(app::R::attr::attr_two, &value, &flags);
- ASSERT_NE(kInvalidCookie, cookie);
- EXPECT_EQ(Res_value::TYPE_INT_DEC, value.dataType);
- EXPECT_EQ(2u, value.data);
- EXPECT_EQ(static_cast<uint32_t>(ResTable_typeSpec::SPEC_PUBLIC), flags);
+ value = theme->GetAttribute(app::R::attr::attr_two);
+ ASSERT_TRUE(value);
+ EXPECT_EQ(Res_value::TYPE_INT_DEC, value->type);
+ EXPECT_EQ(2u, value->data);
+ EXPECT_EQ(static_cast<uint32_t>(ResTable_typeSpec::SPEC_PUBLIC), value->flags);
}
TEST_F(ThemeTest, SingleThemeWithParent) {
@@ -102,32 +95,28 @@
assetmanager.SetApkAssets({style_assets_.get()});
std::unique_ptr<Theme> theme = assetmanager.NewTheme();
- ASSERT_TRUE(theme->ApplyStyle(app::R::style::StyleTwo));
+ ASSERT_TRUE(theme->ApplyStyle(app::R::style::StyleTwo).has_value());
- Res_value value;
- uint32_t flags;
- ApkAssetsCookie cookie;
+ auto value = theme->GetAttribute(app::R::attr::attr_one);
+ ASSERT_TRUE(value);
+ EXPECT_EQ(Res_value::TYPE_INT_DEC, value->type);
+ EXPECT_EQ(1u, value->data);
+ EXPECT_EQ(static_cast<uint32_t>(ResTable_typeSpec::SPEC_PUBLIC), value->flags);
- cookie = theme->GetAttribute(app::R::attr::attr_one, &value, &flags);
- ASSERT_NE(kInvalidCookie, cookie);
- EXPECT_EQ(Res_value::TYPE_INT_DEC, value.dataType);
- EXPECT_EQ(1u, value.data);
- EXPECT_EQ(static_cast<uint32_t>(ResTable_typeSpec::SPEC_PUBLIC), flags);
-
- cookie = theme->GetAttribute(app::R::attr::attr_two, &value, &flags);
- ASSERT_NE(kInvalidCookie, cookie);
- EXPECT_EQ(Res_value::TYPE_STRING, value.dataType);
- EXPECT_EQ(0, cookie);
+ value = theme->GetAttribute(app::R::attr::attr_two);
+ ASSERT_TRUE(value);
+ EXPECT_EQ(Res_value::TYPE_STRING, value->type);
+ EXPECT_EQ(0, value->cookie);
EXPECT_EQ(std::string("string"),
- GetStringFromPool(assetmanager.GetStringPoolForCookie(0), value.data));
- EXPECT_EQ(static_cast<uint32_t>(ResTable_typeSpec::SPEC_PUBLIC), flags);
+ GetStringFromPool(assetmanager.GetStringPoolForCookie(0), value->data));
+ EXPECT_EQ(static_cast<uint32_t>(ResTable_typeSpec::SPEC_PUBLIC), value->flags);
// This attribute should point to an attr_indirect, so the result should be 3.
- cookie = theme->GetAttribute(app::R::attr::attr_three, &value, &flags);
- ASSERT_NE(kInvalidCookie, cookie);
- EXPECT_EQ(Res_value::TYPE_INT_DEC, value.dataType);
- EXPECT_EQ(3u, value.data);
- EXPECT_EQ(static_cast<uint32_t>(ResTable_typeSpec::SPEC_PUBLIC), flags);
+ value = theme->GetAttribute(app::R::attr::attr_three);
+ ASSERT_TRUE(value);
+ EXPECT_EQ(Res_value::TYPE_INT_DEC, value->type);
+ EXPECT_EQ(3u, value->data);
+ EXPECT_EQ(static_cast<uint32_t>(ResTable_typeSpec::SPEC_PUBLIC), value->flags);
}
TEST_F(ThemeTest, TryToUseBadResourceId) {
@@ -135,11 +124,8 @@
assetmanager.SetApkAssets({style_assets_.get()});
std::unique_ptr<Theme> theme = assetmanager.NewTheme();
- ASSERT_TRUE(theme->ApplyStyle(app::R::style::StyleTwo));
-
- Res_value value;
- uint32_t flags;
- ASSERT_EQ(kInvalidCookie, theme->GetAttribute(0x7f000001, &value, &flags));
+ ASSERT_TRUE(theme->ApplyStyle(app::R::style::StyleTwo).has_value());
+ ASSERT_FALSE(theme->GetAttribute(0x7f000001));
}
TEST_F(ThemeTest, MultipleThemesOverlaidNotForce) {
@@ -147,33 +133,29 @@
assetmanager.SetApkAssets({style_assets_.get()});
std::unique_ptr<Theme> theme = assetmanager.NewTheme();
- ASSERT_TRUE(theme->ApplyStyle(app::R::style::StyleTwo));
- ASSERT_TRUE(theme->ApplyStyle(app::R::style::StyleThree));
-
- Res_value value;
- uint32_t flags;
- ApkAssetsCookie cookie;
+ ASSERT_TRUE(theme->ApplyStyle(app::R::style::StyleTwo).has_value());
+ ASSERT_TRUE(theme->ApplyStyle(app::R::style::StyleThree).has_value());
// attr_one is still here from the base.
- cookie = theme->GetAttribute(app::R::attr::attr_one, &value, &flags);
- ASSERT_NE(kInvalidCookie, cookie);
- EXPECT_EQ(Res_value::TYPE_INT_DEC, value.dataType);
- EXPECT_EQ(1u, value.data);
- EXPECT_EQ(static_cast<uint32_t>(ResTable_typeSpec::SPEC_PUBLIC), flags);
+ auto value = theme->GetAttribute(app::R::attr::attr_one);
+ ASSERT_TRUE(value);
+ EXPECT_EQ(Res_value::TYPE_INT_DEC, value->type);
+ EXPECT_EQ(1u, value->data);
+ EXPECT_EQ(static_cast<uint32_t>(ResTable_typeSpec::SPEC_PUBLIC), value->flags);
// check for the new attr_six
- cookie = theme->GetAttribute(app::R::attr::attr_six, &value, &flags);
- ASSERT_NE(kInvalidCookie, cookie);
- EXPECT_EQ(Res_value::TYPE_INT_DEC, value.dataType);
- EXPECT_EQ(6u, value.data);
- EXPECT_EQ(static_cast<uint32_t>(ResTable_typeSpec::SPEC_PUBLIC), flags);
+ value = theme->GetAttribute(app::R::attr::attr_six);
+ ASSERT_TRUE(value);
+ EXPECT_EQ(Res_value::TYPE_INT_DEC, value->type);
+ EXPECT_EQ(6u, value->data);
+ EXPECT_EQ(static_cast<uint32_t>(ResTable_typeSpec::SPEC_PUBLIC), value->flags);
// check for the old attr_five (force=true was not used).
- cookie = theme->GetAttribute(app::R::attr::attr_five, &value, &flags);
- ASSERT_NE(kInvalidCookie, cookie);
- EXPECT_EQ(Res_value::TYPE_REFERENCE, value.dataType);
- EXPECT_EQ(app::R::string::string_one, value.data);
- EXPECT_EQ(static_cast<uint32_t>(ResTable_typeSpec::SPEC_PUBLIC), flags);
+ value = theme->GetAttribute(app::R::attr::attr_five);
+ ASSERT_TRUE(value);
+ EXPECT_EQ(Res_value::TYPE_REFERENCE, value->type);
+ EXPECT_EQ(app::R::string::string_one, value->data);
+ EXPECT_EQ(static_cast<uint32_t>(ResTable_typeSpec::SPEC_PUBLIC), value->flags);
}
TEST_F(ThemeTest, MultipleThemesOverlaidForced) {
@@ -181,33 +163,29 @@
assetmanager.SetApkAssets({style_assets_.get()});
std::unique_ptr<Theme> theme = assetmanager.NewTheme();
- ASSERT_TRUE(theme->ApplyStyle(app::R::style::StyleTwo));
- ASSERT_TRUE(theme->ApplyStyle(app::R::style::StyleThree, true /* force */));
-
- Res_value value;
- uint32_t flags;
- ApkAssetsCookie cookie;
+ ASSERT_TRUE(theme->ApplyStyle(app::R::style::StyleTwo).has_value());
+ ASSERT_TRUE(theme->ApplyStyle(app::R::style::StyleThree, true /* force */).has_value());
// attr_one is still here from the base.
- cookie = theme->GetAttribute(app::R::attr::attr_one, &value, &flags);
- ASSERT_NE(kInvalidCookie, cookie);
- EXPECT_EQ(Res_value::TYPE_INT_DEC, value.dataType);
- EXPECT_EQ(1u, value.data);
- EXPECT_EQ(static_cast<uint32_t>(ResTable_typeSpec::SPEC_PUBLIC), flags);
+ auto value = theme->GetAttribute(app::R::attr::attr_one);
+ ASSERT_TRUE(value);
+ EXPECT_EQ(Res_value::TYPE_INT_DEC, value->type);
+ EXPECT_EQ(1u, value->data);
+ EXPECT_EQ(static_cast<uint32_t>(ResTable_typeSpec::SPEC_PUBLIC), value->flags);
// check for the new attr_six
- cookie = theme->GetAttribute(app::R::attr::attr_six, &value, &flags);
- ASSERT_NE(kInvalidCookie, cookie);
- EXPECT_EQ(Res_value::TYPE_INT_DEC, value.dataType);
- EXPECT_EQ(6u, value.data);
- EXPECT_EQ(static_cast<uint32_t>(ResTable_typeSpec::SPEC_PUBLIC), flags);
+ value = theme->GetAttribute(app::R::attr::attr_six);
+ ASSERT_TRUE(value);
+ EXPECT_EQ(Res_value::TYPE_INT_DEC, value->type);
+ EXPECT_EQ(6u, value->data);
+ EXPECT_EQ(static_cast<uint32_t>(ResTable_typeSpec::SPEC_PUBLIC), value->flags);
// check for the new attr_five (force=true was used).
- cookie = theme->GetAttribute(app::R::attr::attr_five, &value, &flags);
- ASSERT_NE(kInvalidCookie, cookie);
- EXPECT_EQ(Res_value::TYPE_INT_DEC, value.dataType);
- EXPECT_EQ(5u, value.data);
- EXPECT_EQ(static_cast<uint32_t>(ResTable_typeSpec::SPEC_PUBLIC), flags);
+ value = theme->GetAttribute(app::R::attr::attr_five);
+ ASSERT_TRUE(value);
+ EXPECT_EQ(Res_value::TYPE_INT_DEC, value->type);
+ EXPECT_EQ(5u, value->data);
+ EXPECT_EQ(static_cast<uint32_t>(ResTable_typeSpec::SPEC_PUBLIC), value->flags);
}
TEST_F(ThemeTest, ResolveDynamicAttributesAndReferencesToSharedLibrary) {
@@ -216,28 +194,24 @@
{lib_two_assets_.get(), lib_one_assets_.get(), libclient_assets_.get()});
std::unique_ptr<Theme> theme = assetmanager.NewTheme();
- ASSERT_TRUE(theme->ApplyStyle(libclient::R::style::Theme, false /*force*/));
-
- Res_value value;
- uint32_t flags;
- ApkAssetsCookie cookie;
+ ASSERT_TRUE(theme->ApplyStyle(libclient::R::style::Theme, false /*force*/).has_value());
// The attribute should be resolved to the final value.
- cookie = theme->GetAttribute(libclient::R::attr::foo, &value, &flags);
- ASSERT_NE(kInvalidCookie, cookie);
- EXPECT_EQ(Res_value::TYPE_INT_DEC, value.dataType);
- EXPECT_EQ(700u, value.data);
- EXPECT_EQ(static_cast<uint32_t>(ResTable_typeSpec::SPEC_PUBLIC), flags);
+ auto value = theme->GetAttribute(libclient::R::attr::foo);
+ ASSERT_TRUE(value);
+ EXPECT_EQ(Res_value::TYPE_INT_DEC, value->type);
+ EXPECT_EQ(700u, value->data);
+ EXPECT_EQ(static_cast<uint32_t>(ResTable_typeSpec::SPEC_PUBLIC), value->flags);
// The reference should be resolved to a TYPE_REFERENCE.
- cookie = theme->GetAttribute(libclient::R::attr::bar, &value, &flags);
- ASSERT_NE(kInvalidCookie, cookie);
- EXPECT_EQ(Res_value::TYPE_REFERENCE, value.dataType);
+ value = theme->GetAttribute(libclient::R::attr::bar);
+ ASSERT_TRUE(value);
+ EXPECT_EQ(Res_value::TYPE_REFERENCE, value->type);
// lib_one is assigned package ID 0x03.
- EXPECT_EQ(3u, get_package_id(value.data));
- EXPECT_EQ(get_type_id(lib_one::R::string::foo), get_type_id(value.data));
- EXPECT_EQ(get_entry_id(lib_one::R::string::foo), get_entry_id(value.data));
+ EXPECT_EQ(3u, get_package_id(value->data));
+ EXPECT_EQ(get_type_id(lib_one::R::string::foo), get_type_id(value->data));
+ EXPECT_EQ(get_entry_id(lib_one::R::string::foo), get_entry_id(value->data));
}
TEST_F(ThemeTest, CopyThemeSameAssetManager) {
@@ -245,24 +219,20 @@
assetmanager.SetApkAssets({style_assets_.get()});
std::unique_ptr<Theme> theme_one = assetmanager.NewTheme();
- ASSERT_TRUE(theme_one->ApplyStyle(app::R::style::StyleOne));
-
- Res_value value;
- uint32_t flags;
- ApkAssetsCookie cookie;
+ ASSERT_TRUE(theme_one->ApplyStyle(app::R::style::StyleOne).has_value());
// attr_one is still here from the base.
- cookie = theme_one->GetAttribute(app::R::attr::attr_one, &value, &flags);
- ASSERT_NE(kInvalidCookie, cookie);
- EXPECT_EQ(Res_value::TYPE_INT_DEC, value.dataType);
- EXPECT_EQ(1u, value.data);
- EXPECT_EQ(static_cast<uint32_t>(ResTable_typeSpec::SPEC_PUBLIC), flags);
+ auto value = theme_one->GetAttribute(app::R::attr::attr_one);
+ ASSERT_TRUE(value);
+ EXPECT_EQ(Res_value::TYPE_INT_DEC, value->type);
+ EXPECT_EQ(1u, value->data);
+ EXPECT_EQ(static_cast<uint32_t>(ResTable_typeSpec::SPEC_PUBLIC), value->flags);
// attr_six is not here.
- EXPECT_EQ(kInvalidCookie, theme_one->GetAttribute(app::R::attr::attr_six, &value, &flags));
+ ASSERT_FALSE(theme_one->GetAttribute(app::R::attr::attr_six).has_value());
std::unique_ptr<Theme> theme_two = assetmanager.NewTheme();
- ASSERT_TRUE(theme_two->ApplyStyle(app::R::style::StyleThree));
+ ASSERT_TRUE(theme_two->ApplyStyle(app::R::style::StyleThree).has_value());
// Copy the theme to theme_one.
theme_one->SetTo(*theme_two);
@@ -271,14 +241,14 @@
theme_two->Clear();
// attr_one is now not here.
- EXPECT_EQ(kInvalidCookie, theme_one->GetAttribute(app::R::attr::attr_one, &value, &flags));
+ ASSERT_FALSE(theme_one->GetAttribute(app::R::attr::attr_one).has_value());
// attr_six is now here because it was copied.
- cookie = theme_one->GetAttribute(app::R::attr::attr_six, &value, &flags);
- ASSERT_NE(kInvalidCookie, cookie);
- EXPECT_EQ(Res_value::TYPE_INT_DEC, value.dataType);
- EXPECT_EQ(6u, value.data);
- EXPECT_EQ(static_cast<uint32_t>(ResTable_typeSpec::SPEC_PUBLIC), flags);
+ value = theme_one->GetAttribute(app::R::attr::attr_six);
+ ASSERT_TRUE(value);
+ EXPECT_EQ(Res_value::TYPE_INT_DEC, value->type);
+ EXPECT_EQ(6u, value->data);
+ EXPECT_EQ(static_cast<uint32_t>(ResTable_typeSpec::SPEC_PUBLIC), value->flags);
}
TEST_F(ThemeTest, OnlyCopySameAssetsThemeWhenAssetManagersDiffer) {
@@ -291,39 +261,43 @@
style_assets_.get()});
auto theme_dst = assetmanager_dst.NewTheme();
- ASSERT_TRUE(theme_dst->ApplyStyle(app::R::style::StyleOne));
+ ASSERT_TRUE(theme_dst->ApplyStyle(app::R::style::StyleOne).has_value());
auto theme_src = assetmanager_src.NewTheme();
- ASSERT_TRUE(theme_src->ApplyStyle(R::style::Theme_One));
- ASSERT_TRUE(theme_src->ApplyStyle(app::R::style::StyleTwo));
+ ASSERT_TRUE(theme_src->ApplyStyle(R::style::Theme_One).has_value());
+ ASSERT_TRUE(theme_src->ApplyStyle(app::R::style::StyleTwo).has_value());
ASSERT_TRUE(theme_src->ApplyStyle(fix_package_id(lib_one::R::style::Theme, 0x03),
- false /*force*/));
+ false /*force*/).has_value());
ASSERT_TRUE(theme_src->ApplyStyle(fix_package_id(lib_two::R::style::Theme, 0x02),
- false /*force*/));
+ false /*force*/).has_value());
theme_dst->SetTo(*theme_src);
- Res_value value;
- uint32_t flags;
-
// System resources (present in destination asset manager).
- EXPECT_EQ(0, theme_dst->GetAttribute(R::attr::foreground, &value, &flags));
+ auto value = theme_dst->GetAttribute(R::attr::foreground);
+ ASSERT_TRUE(value.has_value());
+ EXPECT_EQ(0, value->cookie);
// The cookie of the style asset is 3 in the source and 2 in the destination.
// Check that the cookie has been rewritten to the destination values.
- EXPECT_EQ(2, theme_dst->GetAttribute(app::R::attr::attr_one, &value, &flags));
+ value = theme_dst->GetAttribute(app::R::attr::attr_one);
+ ASSERT_TRUE(value.has_value());
+ EXPECT_EQ(2, value->cookie);
// The cookie of the lib_one asset is 2 in the source and 1 in the destination.
// The package id of the lib_one package is 0x03 in the source and 0x02 in the destination
// Check that the cookie and packages have been rewritten to the destination values.
- EXPECT_EQ(1, theme_dst->GetAttribute(fix_package_id(lib_one::R::attr::attr1, 0x02), &value,
- &flags));
- EXPECT_EQ(1, theme_dst->GetAttribute(fix_package_id(lib_one::R::attr::attr2, 0x02), &value,
- &flags));
+ value = theme_dst->GetAttribute(fix_package_id(lib_one::R::attr::attr1, 0x02));
+ ASSERT_TRUE(value.has_value());
+ EXPECT_EQ(1, value->cookie);
+
+ value = theme_dst->GetAttribute(fix_package_id(lib_one::R::attr::attr2, 0x02));
+ ASSERT_TRUE(value.has_value());
+ EXPECT_EQ(1, value->cookie);
// attr2 references an attribute in lib_one. Check that the resolution of the attribute value is
// correct after the value of attr2 had its package id rewritten to the destination package id.
- EXPECT_EQ(700, value.data);
+ EXPECT_EQ(700, value->data);
}
TEST_F(ThemeTest, CopyNonReferencesWhenPackagesDiffer) {
@@ -335,28 +309,32 @@
auto theme_dst = assetmanager_dst.NewTheme();
auto theme_src = assetmanager_src.NewTheme();
- ASSERT_TRUE(theme_src->ApplyStyle(app::R::style::StyleSeven));
+ ASSERT_TRUE(theme_src->ApplyStyle(app::R::style::StyleSeven).has_value());
theme_dst->SetTo(*theme_src);
- Res_value value;
- uint32_t flags;
-
// Allow inline resource values to be copied even if the source apk asset is not present in the
// destination.
- EXPECT_EQ(0, theme_dst->GetAttribute(0x0101021b /* android:versionCode */, &value, &flags));
+ auto value = theme_dst->GetAttribute(0x0101021b /* android:versionCode */);
+ ASSERT_TRUE(value.has_value());
+ EXPECT_EQ(0, value->cookie);
// Do not copy strings since the data is an index into the values string pool of the source apk
// asset.
- EXPECT_EQ(-1, theme_dst->GetAttribute(0x01010001 /* android:label */, &value, &flags));
+ EXPECT_FALSE(theme_dst->GetAttribute(0x01010001 /* android:label */).has_value());
// Do not copy values that reference another resource if the resource is not present in the
// destination.
- EXPECT_EQ(-1, theme_dst->GetAttribute(0x01010002 /* android:icon */, &value, &flags));
- EXPECT_EQ(-1, theme_dst->GetAttribute(0x010100d1 /* android:tag */, &value, &flags));
+ EXPECT_FALSE(theme_dst->GetAttribute(0x01010002 /* android:icon */).has_value());
+ EXPECT_FALSE(theme_dst->GetAttribute(0x010100d1 /* android:tag */).has_value());
// Allow @empty to and @null to be copied.
- EXPECT_EQ(0, theme_dst->GetAttribute(0x010100d0 /* android:id */, &value, &flags));
- EXPECT_EQ(0, theme_dst->GetAttribute(0x01010000 /* android:theme */, &value, &flags));
+ value = theme_dst->GetAttribute(0x010100d0 /* android:id */);
+ ASSERT_TRUE(value.has_value());
+ EXPECT_EQ(0, value->cookie);
+
+ value = theme_dst->GetAttribute(0x01010000 /* android:theme */);
+ ASSERT_TRUE(value.has_value());
+ EXPECT_EQ(0, value->cookie);
}
} // namespace android
diff --git a/libs/hwui/canvas/CanvasOpBuffer.h b/libs/hwui/canvas/CanvasOpBuffer.h
index b80faeb..07e079a 100644
--- a/libs/hwui/canvas/CanvasOpBuffer.h
+++ b/libs/hwui/canvas/CanvasOpBuffer.h
@@ -46,6 +46,10 @@
const SkMatrix& transform() const { return mTransform; }
CanvasOp<T>* operator->() noexcept { return &mImpl; }
+ const CanvasOp<T>* operator->() const noexcept { return &mImpl; }
+
+ CanvasOp<T>& op() noexcept { return mImpl; }
+ const CanvasOp<T>& op() const noexcept { return mImpl; }
};
extern template class OpBuffer<CanvasOpType, CanvasOpContainer>;
diff --git a/libs/hwui/canvas/CanvasOpRasterizer.cpp b/libs/hwui/canvas/CanvasOpRasterizer.cpp
index 97c418a..25129f6 100644
--- a/libs/hwui/canvas/CanvasOpRasterizer.cpp
+++ b/libs/hwui/canvas/CanvasOpRasterizer.cpp
@@ -32,7 +32,7 @@
std::vector<SkMatrix> globalMatrixStack;
SkMatrix& currentGlobalTransform = globalMatrixStack.emplace_back(SkMatrix::I());
- source.for_each([&]<CanvasOpType T>(CanvasOpContainer<T> * op) {
+ source.for_each([&]<CanvasOpType T>(const CanvasOpContainer<T> * op) {
if constexpr (T == CanvasOpType::BeginZ || T == CanvasOpType::EndZ) {
// Do beginZ or endZ
LOG_ALWAYS_FATAL("TODO");
diff --git a/libs/hwui/canvas/CanvasOpTypes.h b/libs/hwui/canvas/CanvasOpTypes.h
index efcb373..f9df2f7 100644
--- a/libs/hwui/canvas/CanvasOpTypes.h
+++ b/libs/hwui/canvas/CanvasOpTypes.h
@@ -50,7 +50,11 @@
DrawPath,
DrawLine,
DrawVertices,
-
+ DrawImage,
+ DrawImageRect,
+ // DrawImageLattice also used to draw 9 patches
+ DrawImageLattice,
+ DrawPicture,
// TODO: Rest
diff --git a/libs/hwui/canvas/CanvasOps.h b/libs/hwui/canvas/CanvasOps.h
index 6a76539..8c7113d 100644
--- a/libs/hwui/canvas/CanvasOps.h
+++ b/libs/hwui/canvas/CanvasOps.h
@@ -21,12 +21,16 @@
#include <SkPath.h>
#include <SkRegion.h>
#include <SkVertices.h>
+#include <SkImage.h>
+#include <SkPicture.h>
+#include <hwui/Bitmap.h>
#include <log/log.h>
#include "CanvasProperty.h"
#include "CanvasOpTypes.h"
#include <experimental/type_traits>
+#include <utility>
namespace android::uirenderer {
@@ -269,6 +273,97 @@
ASSERT_DRAWABLE()
};
+template<>
+struct CanvasOp<CanvasOpType::DrawImage> {
+
+ CanvasOp<CanvasOpType::DrawImageRect>(
+ const sk_sp<Bitmap>& bitmap,
+ float left,
+ float top,
+ SkPaint paint
+ ) : left(left),
+ top(top),
+ paint(std::move(paint)),
+ bitmap(bitmap),
+ image(bitmap->makeImage()) { }
+
+ float left;
+ float top;
+ SkPaint paint;
+ sk_sp<Bitmap> bitmap;
+ sk_sp<SkImage> image;
+
+ void draw(SkCanvas* canvas) const {
+ canvas->drawImage(image, left, top, &paint);
+ }
+ ASSERT_DRAWABLE()
+};
+
+template<>
+struct CanvasOp<CanvasOpType::DrawImageRect> {
+
+ CanvasOp<CanvasOpType::DrawImageRect>(
+ const sk_sp<Bitmap>& bitmap,
+ SkRect src,
+ SkRect dst,
+ SkPaint paint
+ ) : src(src),
+ dst(dst),
+ paint(std::move(paint)),
+ bitmap(bitmap),
+ image(bitmap->makeImage()) { }
+
+ SkRect src;
+ SkRect dst;
+ SkPaint paint;
+ sk_sp<Bitmap> bitmap;
+ sk_sp<SkImage> image;
+
+ void draw(SkCanvas* canvas) const {
+ canvas->drawImageRect(image,
+ src,
+ dst,
+ &paint,
+ SkCanvas::kFast_SrcRectConstraint
+ );
+ }
+ ASSERT_DRAWABLE()
+};
+
+template<>
+struct CanvasOp<CanvasOpType::DrawImageLattice> {
+
+ CanvasOp<CanvasOpType::DrawImageLattice>(
+ const sk_sp<Bitmap>& bitmap,
+ SkRect dst,
+ SkCanvas::Lattice lattice,
+ SkPaint paint
+ ): dst(dst),
+ lattice(lattice),
+ bitmap(bitmap),
+ image(bitmap->makeImage()),
+ paint(std::move(paint)) {}
+
+ SkRect dst;
+ SkCanvas::Lattice lattice;
+ const sk_sp<Bitmap> bitmap;
+ const sk_sp<SkImage> image;
+
+ SkPaint paint;
+ void draw(SkCanvas* canvas) const {
+ canvas->drawImageLattice(image.get(), lattice, dst, &paint);
+ }
+ ASSERT_DRAWABLE()
+};
+
+template<>
+struct CanvasOp<CanvasOpType::DrawPicture> {
+ sk_sp<SkPicture> picture;
+ void draw(SkCanvas* canvas) const {
+ picture->playback(canvas);
+ }
+};
+
// cleanup our macros
#undef ASSERT_DRAWABLE
diff --git a/libs/hwui/canvas/OpBuffer.h b/libs/hwui/canvas/OpBuffer.h
index 398e090..98e385f 100644
--- a/libs/hwui/canvas/OpBuffer.h
+++ b/libs/hwui/canvas/OpBuffer.h
@@ -156,7 +156,7 @@
using F_PTR = decltype(&f);
using THUNK = void (*)(F_PTR, void*);
static constexpr auto jump = std::array<THUNK, sizeof...(I)>{[](F_PTR fp, void* t) {
- (*fp)(reinterpret_cast<ItemContainer<static_cast<ItemTypes>(I)>*>(t));
+ (*fp)(reinterpret_cast<const ItemContainer<static_cast<ItemTypes>(I)>*>(t));
}...};
// Do the actual iteration of each item
diff --git a/libs/hwui/tests/unit/CanvasOpTests.cpp b/libs/hwui/tests/unit/CanvasOpTests.cpp
index 60c8628..b15c322 100644
--- a/libs/hwui/tests/unit/CanvasOpTests.cpp
+++ b/libs/hwui/tests/unit/CanvasOpTests.cpp
@@ -22,7 +22,9 @@
#include <tests/common/CallCountingCanvas.h>
+#include "SkPictureRecorder.h"
#include "SkColor.h"
+#include "SkLatticeIter.h"
#include "pipeline/skia/AnimatedDrawables.h"
using namespace android;
@@ -141,6 +143,20 @@
EXPECT_EQ(tracker.alive(), 0);
}
+TEST(CanvasOp, verifyConst) {
+ CanvasOpBuffer buffer;
+ buffer.push<Op::DrawColor>({
+ .color = SkColors::kBlack,
+ .mode = SkBlendMode::kSrcOver,
+ });
+ buffer.for_each([](auto op) {
+ static_assert(std::is_const_v<std::remove_reference_t<decltype(*op)>>,
+ "Expected container to be const");
+ static_assert(std::is_const_v<std::remove_reference_t<decltype(op->op())>>,
+ "Expected op to be const");
+ });
+}
+
TEST(CanvasOp, simplePush) {
CanvasOpBuffer buffer;
EXPECT_EQ(buffer.size(), 0);
@@ -184,7 +200,7 @@
TEST(CanvasOp, simpleDrawPaint) {
CanvasOpBuffer buffer;
EXPECT_EQ(buffer.size(), 0);
- buffer.push(CanvasOp<Op::DrawColor> {
+ buffer.push<Op::DrawColor> ({
.color = SkColor4f{1, 1, 1, 1},
.mode = SkBlendMode::kSrcIn
});
@@ -199,7 +215,7 @@
TEST(CanvasOp, simpleDrawPoint) {
CanvasOpBuffer buffer;
EXPECT_EQ(buffer.size(), 0);
- buffer.push(CanvasOp<Op::DrawPoint> {
+ buffer.push<Op::DrawPoint> ({
.x = 12,
.y = 42,
.paint = SkPaint{}
@@ -215,7 +231,7 @@
TEST(CanvasOp, simpleDrawLine) {
CanvasOpBuffer buffer;
EXPECT_EQ(buffer.size(), 0);
- buffer.push(CanvasOp<Op::DrawLine> {
+ buffer.push<Op::DrawLine> ({
.startX = 16,
.startY = 28,
.endX = 12,
@@ -233,7 +249,7 @@
TEST(CanvasOp, simpleDrawRect) {
CanvasOpBuffer buffer;
EXPECT_EQ(buffer.size(), 0);
- buffer.push(CanvasOp<Op::DrawRect> {
+ buffer.push<Op::DrawRect> ({
.paint = SkPaint{},
.rect = SkRect::MakeEmpty()
});
@@ -250,7 +266,7 @@
EXPECT_EQ(buffer.size(), 0);
SkRegion region;
region.setRect(SkIRect::MakeWH(12, 50));
- buffer.push(CanvasOp<Op::DrawRegion> {
+ buffer.push<Op::DrawRegion> ({
.paint = SkPaint{},
.region = region
});
@@ -272,7 +288,7 @@
clip.setRect(SkIRect::MakeWH(100, 100));
SkRegion region;
region.setPath(path, clip);
- buffer.push(CanvasOp<Op::DrawRegion> {
+ buffer.push<Op::DrawRegion> ({
.paint = SkPaint{},
.region = region
});
@@ -287,7 +303,7 @@
TEST(CanvasOp, simpleDrawRoundRect) {
CanvasOpBuffer buffer;
EXPECT_EQ(buffer.size(), 0);
- buffer.push(CanvasOp<Op::DrawRoundRect> {
+ buffer.push<Op::DrawRoundRect> ({
.paint = SkPaint{},
.rect = SkRect::MakeEmpty(),
.rx = 10,
@@ -326,7 +342,7 @@
innerPts[3].set(10, 10);
innerRRect.setRectRadii(inner, innerPts.get());
- buffer.push(CanvasOp<Op::DrawDoubleRoundRect> {
+ buffer.push<Op::DrawDoubleRoundRect> ({
.outer = outerRRect,
.inner = innerRRect,
.paint = SkPaint{}
@@ -342,7 +358,7 @@
TEST(CanvasOp, simpleDrawCircle) {
CanvasOpBuffer buffer;
EXPECT_EQ(buffer.size(), 0);
- buffer.push(CanvasOp<Op::DrawCircle> {
+ buffer.push<Op::DrawCircle>({
.cx = 5,
.cy = 7,
.radius = 10,
@@ -359,7 +375,7 @@
TEST(CanvasOp, simpleDrawOval) {
CanvasOpBuffer buffer;
EXPECT_EQ(buffer.size(), 0);
- buffer.push(CanvasOp<Op::DrawOval> {
+ buffer.push<Op::DrawOval> ({
.oval = SkRect::MakeEmpty(),
.paint = SkPaint{}
});
@@ -374,7 +390,7 @@
TEST(CanvasOp, simpleDrawArc) {
CanvasOpBuffer buffer;
EXPECT_EQ(buffer.size(), 0);
- buffer.push(CanvasOp<Op::DrawArc> {
+ buffer.push<Op::DrawArc>({
.oval = SkRect::MakeWH(100, 100),
.startAngle = 120,
.sweepAngle = 70,
@@ -394,7 +410,7 @@
EXPECT_EQ(buffer.size(), 0);
SkPath path;
path.addCircle(50, 50, 30);
- buffer.push(CanvasOp<Op::DrawPath> {
+ buffer.push<Op::DrawPath> ({
.path = path,
.paint = SkPaint{}
});
@@ -419,7 +435,7 @@
auto propertyPaint =
sp<uirenderer::CanvasPropertyPaint>(new uirenderer::CanvasPropertyPaint(SkPaint{}));
- buffer.push(CanvasOp<Op::DrawRoundRectProperty> {
+ buffer.push<Op::DrawRoundRectProperty> ({
.left = left,
.top = top,
.right = right,
@@ -446,7 +462,7 @@
auto propertyPaint =
sp<uirenderer::CanvasPropertyPaint>(new uirenderer::CanvasPropertyPaint(SkPaint{}));
- buffer.push(CanvasOp<Op::DrawCircleProperty> {
+ buffer.push<Op::DrawCircleProperty> ({
.x = x,
.y = y,
.radius = radius,
@@ -468,7 +484,7 @@
SkColor colors[3] = {SK_ColorRED, SK_ColorBLUE, SK_ColorGREEN};
sk_sp<SkVertices> vertices = SkVertices::MakeCopy(SkVertices::kTriangles_VertexMode, 3, pts,
nullptr, colors);
- buffer.push(CanvasOp<Op::DrawVertices> {
+ buffer.push<Op::DrawVertices> ({
.vertices = vertices,
.mode = SkBlendMode::kSrcOver,
.paint = SkPaint{}
@@ -481,6 +497,110 @@
EXPECT_EQ(1, canvas.sumTotalDrawCalls());
}
+TEST(CanvasOp, simpleDrawImage) {
+ CanvasOpBuffer buffer;
+ EXPECT_EQ(buffer.size(), 0);
+
+ SkImageInfo info =SkImageInfo::Make(5, 1,
+ kGray_8_SkColorType, kOpaque_SkAlphaType);
+ sk_sp<Bitmap> bitmap = Bitmap::allocateHeapBitmap(info);
+ buffer.push<Op::DrawImage> ({
+ bitmap,
+ 7,
+ 19,
+ SkPaint{}
+ }
+ );
+
+ CallCountingCanvas canvas;
+ EXPECT_EQ(0, canvas.sumTotalDrawCalls());
+ rasterizeCanvasBuffer(buffer, &canvas);
+ EXPECT_EQ(1, canvas.drawImageCount);
+ EXPECT_EQ(1, canvas.sumTotalDrawCalls());
+}
+
+TEST(CanvasOp, simpleDrawImageRect) {
+ CanvasOpBuffer buffer;
+ EXPECT_EQ(buffer.size(), 0);
+
+ SkImageInfo info = SkImageInfo::Make(5, 1,
+ kGray_8_SkColorType, kOpaque_SkAlphaType);
+
+ sk_sp<Bitmap> bitmap = Bitmap::allocateHeapBitmap(info);
+ buffer.push<Op::DrawImageRect> ({
+ bitmap, SkRect::MakeWH(100, 100),
+ SkRect::MakeLTRB(120, 110, 220, 210),
+ SkPaint{}
+ }
+ );
+
+ CallCountingCanvas canvas;
+ EXPECT_EQ(0, canvas.sumTotalDrawCalls());
+ rasterizeCanvasBuffer(buffer, &canvas);
+ EXPECT_EQ(1, canvas.drawImageRectCount);
+ EXPECT_EQ(1, canvas.sumTotalDrawCalls());
+}
+
+TEST(CanvasOp, simpleDrawImageLattice) {
+ CanvasOpBuffer buffer;
+ EXPECT_EQ(buffer.size(), 0);
+
+ SkBitmap skBitmap;
+ skBitmap.allocPixels(SkImageInfo::MakeN32Premul(60, 60));
+
+ const int xDivs[] = { 20, 50 };
+ const int yDivs[] = { 10, 40 };
+ SkCanvas::Lattice::RectType fillTypes[3][3];
+ memset(fillTypes, 0, sizeof(fillTypes));
+ fillTypes[1][1] = SkCanvas::Lattice::kTransparent;
+ SkColor colors[9];
+ SkCanvas::Lattice lattice = { xDivs, yDivs, fillTypes[0], 2,
+ 2, nullptr, colors };
+ sk_sp<Bitmap> bitmap = Bitmap::allocateHeapBitmap(&skBitmap);
+ buffer.push<Op::DrawImageLattice>(
+ {
+ bitmap,
+ SkRect::MakeWH(5, 1),
+ lattice,
+ SkPaint{}
+ }
+ );
+
+ CallCountingCanvas canvas;
+ EXPECT_EQ(0, canvas.sumTotalDrawCalls());
+ rasterizeCanvasBuffer(buffer, &canvas);
+ EXPECT_EQ(1, canvas.drawImageLatticeCount);
+ EXPECT_EQ(1, canvas.sumTotalDrawCalls());
+}
+
+TEST(CanvasOp, simpleDrawPicture) {
+ CanvasOpBuffer buffer;
+ EXPECT_EQ(buffer.size(), 0);
+
+ SkPictureRecorder recorder;
+ SkCanvas* pictureCanvas = recorder.beginRecording({64, 64, 192, 192});
+ SkPaint paint;
+ pictureCanvas->drawRect(SkRect::MakeWH(200, 200), paint);
+ paint.setColor(SK_ColorWHITE);
+ pictureCanvas->drawRect(SkRect::MakeLTRB(20, 20, 180, 180), paint);
+ sk_sp<SkPicture> picture = recorder.finishRecordingAsPicture();
+ buffer.push<Op::DrawPicture> ({
+ .picture = picture
+ });
+
+ CallCountingCanvas canvas;
+ EXPECT_EQ(0, canvas.sumTotalDrawCalls());
+ rasterizeCanvasBuffer(buffer, &canvas);
+ // Note because we are explicitly issuing 2 drawRect calls
+ // in the picture recorder above, when it is played back into
+ // CallCountingCanvas we will see 2 calls to drawRect instead of 1
+ // call to drawPicture.
+ // This is because SkiaCanvas::drawPicture uses picture.playback(canvas)
+ // instead of canvas->drawPicture.
+ EXPECT_EQ(2, canvas.drawRectCount);
+ EXPECT_EQ(2, canvas.sumTotalDrawCalls());
+}
+
TEST(CanvasOp, immediateRendering) {
auto canvas = std::make_shared<CallCountingCanvas>();
diff --git a/media/java/android/media/AudioDeviceInfo.java b/media/java/android/media/AudioDeviceInfo.java
index 477519c..b67851a 100644
--- a/media/java/android/media/AudioDeviceInfo.java
+++ b/media/java/android/media/AudioDeviceInfo.java
@@ -22,6 +22,7 @@
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
+import java.util.Arrays;
import java.util.Objects;
import java.util.TreeSet;
@@ -468,9 +469,32 @@
* @see AudioFormat
*
* Note: an empty array indicates that the device supports arbitrary encodings.
+ * For forward compatibility, applications should ignore entries it does not recognize.
*/
public @NonNull int[] getEncodings() {
- return AudioFormat.filterPublicFormats(mPort.formats());
+ final int[] encodings = AudioFormat.filterPublicFormats(mPort.formats());
+ boolean hasFloat = false;
+ boolean hasExtendedIntegerPrecision = false;
+
+ for (int encoding : encodings) {
+ if (AudioFormat.isEncodingLinearPcm(encoding)) {
+ if (encoding == AudioFormat.ENCODING_PCM_FLOAT) {
+ hasFloat = true;
+ } else if (AudioFormat.getBytesPerSample(encoding) > 2) {
+ hasExtendedIntegerPrecision = true;
+ }
+ }
+ }
+ if (hasExtendedIntegerPrecision && !hasFloat) {
+ // R and earlier compatibility - add ENCODING_PCM_FLOAT to the end
+ // (replacing the zero pad). This ensures pre-S apps that look
+ // for ENCODING_PCM_FLOAT continue to see that encoding if the device supports
+ // extended precision integers.
+ int[] encodingsPlusFloat = Arrays.copyOf(encodings, encodings.length + 1);
+ encodingsPlusFloat[encodings.length] = AudioFormat.ENCODING_PCM_FLOAT;
+ return encodingsPlusFloat;
+ }
+ return encodings;
}
/**
diff --git a/media/java/android/media/AudioFormat.java b/media/java/android/media/AudioFormat.java
index a2861c2..255c15c 100644
--- a/media/java/android/media/AudioFormat.java
+++ b/media/java/android/media/AudioFormat.java
@@ -110,6 +110,24 @@
* <code>AudioTrack</code> as of API {@link android.os.Build.VERSION_CODES#LOLLIPOP}
* support <code>ENCODING_PCM_FLOAT</code>.
* </li>
+ * <li> {@link #ENCODING_PCM_24BIT_PACKED}: Introduced in
+ * API {@link android.os.Build.VERSION_CODES#S},
+ * this encoding specifies the audio sample is an
+ * extended precision 24 bit signed integer
+ * stored as a 3 Java bytes in a {@code ByteBuffer} or byte array in native endian
+ * (see {@link java.nio.ByteOrder#nativeOrder()}).
+ * Each sample has full range from [-8388608, 8388607],
+ * and can be interpreted as fixed point Q.23 data.
+ * </li>
+ * <li> {@link #ENCODING_PCM_32BIT}: Introduced in
+ * API {@link android.os.Build.VERSION_CODES#S},
+ * this encoding specifies the audio sample is an
+ * extended precision 32 bit signed integer
+ * stored as a 4 Java bytes in a {@code ByteBuffer} or byte array in native endian
+ * (see {@link java.nio.ByteOrder#nativeOrder()}).
+ * Each sample has full range from [-2147483648, 2147483647],
+ * and can be interpreted as fixed point Q.31 data.
+ * </li>
* </ul>
* <p>For compressed audio, the encoding specifies the method of compression,
* for example {@link #ENCODING_AC3} and {@link #ENCODING_DTS}. The compressed
@@ -285,6 +303,19 @@
/** Audio data format: OPUS compressed. */
public static final int ENCODING_OPUS = 20;
+ /** @hide
+ * We do not permit legacy short array reads or writes for encodings
+ * introduced after this threshold.
+ */
+ public static final int ENCODING_LEGACY_SHORT_ARRAY_THRESHOLD = ENCODING_OPUS;
+
+ /** Audio data format: PCM 24 bit per sample packed as 3 bytes.
+ * Not guaranteed to be supported by devices, may be emulated if not supported. */
+ public static final int ENCODING_PCM_24BIT_PACKED = 21;
+ /** Audio data format: PCM 32 bit per sample.
+ * Not guaranteed to be supported by devices, may be emulated if not supported. */
+ public static final int ENCODING_PCM_32BIT = 22;
+
/** @hide */
public static String toLogFriendlyEncoding(int enc) {
switch(enc) {
@@ -328,6 +359,10 @@
return "ENCODING_DOLBY_MAT";
case ENCODING_OPUS:
return "ENCODING_OPUS";
+ case ENCODING_PCM_24BIT_PACKED:
+ return "ENCODING_PCM_24BIT_PACKED";
+ case ENCODING_PCM_32BIT:
+ return "ENCODING_PCM_32BIT";
default :
return "invalid encoding " + enc;
}
@@ -517,17 +552,20 @@
public static int getBytesPerSample(int audioFormat)
{
switch (audioFormat) {
- case ENCODING_PCM_8BIT:
- return 1;
- case ENCODING_PCM_16BIT:
- case ENCODING_IEC61937:
- case ENCODING_DEFAULT:
- return 2;
- case ENCODING_PCM_FLOAT:
- return 4;
- case ENCODING_INVALID:
- default:
- throw new IllegalArgumentException("Bad audio format " + audioFormat);
+ case ENCODING_PCM_8BIT:
+ return 1;
+ case ENCODING_PCM_16BIT:
+ case ENCODING_IEC61937:
+ case ENCODING_DEFAULT:
+ return 2;
+ case ENCODING_PCM_24BIT_PACKED:
+ return 3;
+ case ENCODING_PCM_FLOAT:
+ case ENCODING_PCM_32BIT:
+ return 4;
+ case ENCODING_INVALID:
+ default:
+ throw new IllegalArgumentException("Bad audio format " + audioFormat);
}
}
@@ -554,6 +592,8 @@
case ENCODING_E_AC3_JOC:
case ENCODING_DOLBY_MAT:
case ENCODING_OPUS:
+ case ENCODING_PCM_24BIT_PACKED:
+ case ENCODING_PCM_32BIT:
return true;
default:
return false;
@@ -583,6 +623,8 @@
case ENCODING_E_AC3_JOC:
case ENCODING_DOLBY_MAT:
case ENCODING_OPUS:
+ case ENCODING_PCM_24BIT_PACKED:
+ case ENCODING_PCM_32BIT:
return true;
default:
return false;
@@ -597,6 +639,8 @@
case ENCODING_PCM_16BIT:
case ENCODING_PCM_8BIT:
case ENCODING_PCM_FLOAT:
+ case ENCODING_PCM_24BIT_PACKED:
+ case ENCODING_PCM_32BIT:
case ENCODING_DEFAULT:
return true;
case ENCODING_AC3:
@@ -630,6 +674,8 @@
case ENCODING_PCM_8BIT:
case ENCODING_PCM_FLOAT:
case ENCODING_IEC61937: // same size as stereo PCM
+ case ENCODING_PCM_24BIT_PACKED:
+ case ENCODING_PCM_32BIT:
case ENCODING_DEFAULT:
return true;
case ENCODING_AC3:
@@ -927,6 +973,8 @@
case ENCODING_E_AC3_JOC:
case ENCODING_DOLBY_MAT:
case ENCODING_OPUS:
+ case ENCODING_PCM_24BIT_PACKED:
+ case ENCODING_PCM_32BIT:
mEncoding = encoding;
break;
case ENCODING_INVALID:
@@ -1147,7 +1195,9 @@
ENCODING_AC4,
ENCODING_E_AC3_JOC,
ENCODING_DOLBY_MAT,
- ENCODING_OPUS }
+ ENCODING_OPUS,
+ ENCODING_PCM_24BIT_PACKED,
+ ENCODING_PCM_32BIT }
)
@Retention(RetentionPolicy.SOURCE)
public @interface Encoding {}
diff --git a/media/java/android/media/AudioManager.java b/media/java/android/media/AudioManager.java
index 2947736..4578883 100644
--- a/media/java/android/media/AudioManager.java
+++ b/media/java/android/media/AudioManager.java
@@ -4009,8 +4009,8 @@
* @deprecated use {@link #abandonAudioFocusRequest(AudioFocusRequest)}
*/
@SystemApi
- @SuppressLint("Doclava125") // no permission enforcement, but only "undoes" what would have been
- // done by a matching requestAudioFocus
+ @SuppressLint("RequiresPermission") // no permission enforcement, but only "undoes" what would
+ // have been done by a matching requestAudioFocus
public int abandonAudioFocus(OnAudioFocusChangeListener l, AudioAttributes aa) {
int status = AUDIOFOCUS_REQUEST_FAILED;
unregisterAudioFocusRequest(l);
@@ -5602,7 +5602,7 @@
* @hide
*/
@SystemApi
- @SuppressLint("Doclava125") // FIXME is this still used?
+ @SuppressLint("RequiresPermission") // FIXME is this still used?
public boolean isHdmiSystemAudioSupported() {
try {
return getService().isHdmiSystemAudioSupported();
diff --git a/media/java/android/media/AudioRecord.java b/media/java/android/media/AudioRecord.java
index 07c8ee5..65e6fea 100644
--- a/media/java/android/media/AudioRecord.java
+++ b/media/java/android/media/AudioRecord.java
@@ -850,17 +850,21 @@
//--------------
// audio format
switch (audioFormat) {
- case AudioFormat.ENCODING_DEFAULT:
- mAudioFormat = AudioFormat.ENCODING_PCM_16BIT;
- break;
- case AudioFormat.ENCODING_PCM_FLOAT:
- case AudioFormat.ENCODING_PCM_16BIT:
- case AudioFormat.ENCODING_PCM_8BIT:
- mAudioFormat = audioFormat;
- break;
- default:
- throw new IllegalArgumentException("Unsupported sample encoding " + audioFormat
- + ". Should be ENCODING_PCM_8BIT, ENCODING_PCM_16BIT, or ENCODING_PCM_FLOAT.");
+ case AudioFormat.ENCODING_DEFAULT:
+ mAudioFormat = AudioFormat.ENCODING_PCM_16BIT;
+ break;
+ case AudioFormat.ENCODING_PCM_24BIT_PACKED:
+ case AudioFormat.ENCODING_PCM_32BIT:
+ case AudioFormat.ENCODING_PCM_FLOAT:
+ case AudioFormat.ENCODING_PCM_16BIT:
+ case AudioFormat.ENCODING_PCM_8BIT:
+ mAudioFormat = audioFormat;
+ break;
+ default:
+ throw new IllegalArgumentException("Unsupported sample encoding " + audioFormat
+ + ". Should be ENCODING_PCM_8BIT, ENCODING_PCM_16BIT,"
+ + " ENCODING_PCM_24BIT_PACKED, ENCODING_PCM_32BIT,"
+ + " or ENCODING_PCM_FLOAT.");
}
}
@@ -1267,6 +1271,7 @@
*/
public int read(@NonNull byte[] audioData, int offsetInBytes, int sizeInBytes,
@ReadMode int readMode) {
+ // Note: we allow reads of extended integers into a byte array.
if (mState != STATE_INITIALIZED || mAudioFormat == AudioFormat.ENCODING_PCM_FLOAT) {
return ERROR_INVALID_OPERATION;
}
@@ -1339,7 +1344,10 @@
*/
public int read(@NonNull short[] audioData, int offsetInShorts, int sizeInShorts,
@ReadMode int readMode) {
- if (mState != STATE_INITIALIZED || mAudioFormat == AudioFormat.ENCODING_PCM_FLOAT) {
+ if (mState != STATE_INITIALIZED
+ || mAudioFormat == AudioFormat.ENCODING_PCM_FLOAT
+ // use ByteBuffer instead for later encodings
+ || mAudioFormat > AudioFormat.ENCODING_LEGACY_SHORT_ARRAY_THRESHOLD) {
return ERROR_INVALID_OPERATION;
}
diff --git a/media/java/android/media/AudioTrack.java b/media/java/android/media/AudioTrack.java
index b2c2c4b..e8c6206 100644
--- a/media/java/android/media/AudioTrack.java
+++ b/media/java/android/media/AudioTrack.java
@@ -2892,7 +2892,7 @@
*/
public int write(@NonNull byte[] audioData, int offsetInBytes, int sizeInBytes,
@WriteMode int writeMode) {
-
+ // Note: we allow writes of extended integers and compressed formats from a byte array.
if (mState == STATE_UNINITIALIZED || mAudioFormat == AudioFormat.ENCODING_PCM_FLOAT) {
return ERROR_INVALID_OPERATION;
}
@@ -3006,7 +3006,10 @@
public int write(@NonNull short[] audioData, int offsetInShorts, int sizeInShorts,
@WriteMode int writeMode) {
- if (mState == STATE_UNINITIALIZED || mAudioFormat == AudioFormat.ENCODING_PCM_FLOAT) {
+ if (mState == STATE_UNINITIALIZED
+ || mAudioFormat == AudioFormat.ENCODING_PCM_FLOAT
+ // use ByteBuffer or byte[] instead for later encodings
+ || mAudioFormat > AudioFormat.ENCODING_LEGACY_SHORT_ARRAY_THRESHOLD) {
return ERROR_INVALID_OPERATION;
}
diff --git a/media/java/android/media/ExifInterface.java b/media/java/android/media/ExifInterface.java
index f216c8c..de885f49 100644
--- a/media/java/android/media/ExifInterface.java
+++ b/media/java/android/media/ExifInterface.java
@@ -32,7 +32,6 @@
import android.graphics.Bitmap;
import android.graphics.BitmapFactory;
import android.os.FileUtils;
-import android.os.SystemProperties;
import android.system.ErrnoException;
import android.system.Os;
import android.system.OsConstants;
@@ -1528,8 +1527,7 @@
if (fileDescriptor == null) {
throw new NullPointerException("fileDescriptor cannot be null");
}
- boolean optimize = SystemProperties.getBoolean("fuse.sys.transcode_exif_optimize", false);
- FileDescriptor modernFd = optimize ? FileUtils.convertToModernFd(fileDescriptor) : null;
+ FileDescriptor modernFd = FileUtils.convertToModernFd(fileDescriptor);
if (modernFd != null) {
fileDescriptor = modernFd;
}
@@ -2549,9 +2547,7 @@
mIsInputStream = false;
try {
in = new FileInputStream(filename);
- boolean optimize = SystemProperties.getBoolean("fuse.sys.transcode_exif_optimize",
- false);
- FileDescriptor modernFd = optimize ? FileUtils.convertToModernFd(in.getFD()) : null;
+ FileDescriptor modernFd = FileUtils.convertToModernFd(in.getFD());
if (modernFd != null) {
legacyInputStream = in;
in = new FileInputStream(modernFd);
diff --git a/media/java/android/media/Image.java b/media/java/android/media/Image.java
index 610bffe..0ef4b94 100644
--- a/media/java/android/media/Image.java
+++ b/media/java/android/media/Image.java
@@ -200,6 +200,7 @@
* @return The window transformation that needs to be applied for this frame.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
public abstract int getTransform();
/**
@@ -207,6 +208,7 @@
* @return The scaling mode that needs to be applied for this frame.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
public abstract int getScalingMode();
/**
diff --git a/media/java/android/media/MediaMetadataRetriever.java b/media/java/android/media/MediaMetadataRetriever.java
index ca8b9b9..86d1d15 100644
--- a/media/java/android/media/MediaMetadataRetriever.java
+++ b/media/java/android/media/MediaMetadataRetriever.java
@@ -300,9 +300,7 @@
*/
public void setDataSource(FileDescriptor fd, long offset, long length)
throws IllegalArgumentException {
- boolean optimize = SystemProperties.getBoolean("fuse.sys.transcode_retriever_optimize",
- false);
- FileDescriptor modernFd = optimize ? FileUtils.convertToModernFd(fd) : null;
+ FileDescriptor modernFd = FileUtils.convertToModernFd(fd);
if (modernFd == null) {
_setDataSource(fd, offset, length);
} else {
diff --git a/media/java/android/media/MediaPlayer.java b/media/java/android/media/MediaPlayer.java
index 6554544..973c2a8 100644
--- a/media/java/android/media/MediaPlayer.java
+++ b/media/java/android/media/MediaPlayer.java
@@ -1258,8 +1258,7 @@
*/
public void setDataSource(FileDescriptor fd, long offset, long length)
throws IOException, IllegalArgumentException, IllegalStateException {
- boolean optimize = SystemProperties.getBoolean("fuse.sys.transcode_player_optimize", false);
- FileDescriptor modernFd = optimize ? FileUtils.convertToModernFd(fd) : null;
+ FileDescriptor modernFd = FileUtils.convertToModernFd(fd);
if (modernFd == null) {
_setDataSource(fd, offset, length);
} else {
diff --git a/packages/CompanionDeviceManager/src/com/android/companiondevicemanager/DeviceDiscoveryService.java b/packages/CompanionDeviceManager/src/com/android/companiondevicemanager/DeviceDiscoveryService.java
index c653c73..a7e397e 100644
--- a/packages/CompanionDeviceManager/src/com/android/companiondevicemanager/DeviceDiscoveryService.java
+++ b/packages/CompanionDeviceManager/src/com/android/companiondevicemanager/DeviceDiscoveryService.java
@@ -32,6 +32,7 @@
import android.bluetooth.BluetoothAdapter;
import android.bluetooth.BluetoothDevice;
import android.bluetooth.BluetoothManager;
+import android.bluetooth.BluetoothProfile;
import android.bluetooth.le.BluetoothLeScanner;
import android.bluetooth.le.ScanCallback;
import android.bluetooth.le.ScanFilter;
@@ -84,6 +85,7 @@
static DeviceDiscoveryService sInstance;
+ private BluetoothManager mBluetoothManager;
private BluetoothAdapter mBluetoothAdapter;
private WifiManager mWifiManager;
@Nullable private BluetoothLeScanner mBLEScanner;
@@ -143,7 +145,8 @@
if (DEBUG) Log.i(LOG_TAG, "onCreate()");
- mBluetoothAdapter = getSystemService(BluetoothManager.class).getAdapter();
+ mBluetoothManager = getSystemService(BluetoothManager.class);
+ mBluetoothAdapter = mBluetoothManager.getAdapter();
mBLEScanner = mBluetoothAdapter.getBluetoothLeScanner();
mWifiManager = getSystemService(WifiManager.class);
@@ -188,6 +191,14 @@
for (BluetoothDevice dev : emptyIfNull(mBluetoothAdapter.getBondedDevices())) {
onDeviceFound(DeviceFilterPair.findMatch(dev, mBluetoothFilters));
}
+ for (BluetoothDevice dev : emptyIfNull(
+ mBluetoothManager.getConnectedDevices(BluetoothProfile.GATT))) {
+ onDeviceFound(DeviceFilterPair.findMatch(dev, mBluetoothFilters));
+ }
+ for (BluetoothDevice dev : emptyIfNull(
+ mBluetoothManager.getConnectedDevices(BluetoothProfile.GATT_SERVER))) {
+ onDeviceFound(DeviceFilterPair.findMatch(dev, mBluetoothFilters));
+ }
}
if (shouldScan(mBluetoothFilters)) {
diff --git a/packages/Shell/src/com/android/shell/HeapDumpReceiver.java b/packages/Shell/src/com/android/shell/HeapDumpReceiver.java
index 858c521..7433c3e 100644
--- a/packages/Shell/src/com/android/shell/HeapDumpReceiver.java
+++ b/packages/Shell/src/com/android/shell/HeapDumpReceiver.java
@@ -180,7 +180,7 @@
.setContentText(context.getText(
com.android.internal.R.string.dump_heap_notification_detail))
.setContentIntent(PendingIntent.getActivity(context, 2, shareIntent,
- PendingIntent.FLAG_UPDATE_CURRENT));
+ PendingIntent.FLAG_UPDATE_CURRENT | PendingIntent.FLAG_IMMUTABLE));
Log.v(TAG, "Creating share heap dump notification");
NotificationManager.from(context).notify(NOTIFICATION_ID, builder.build());
diff --git a/packages/SystemUI/plugin/src/com/android/systemui/plugins/NotificationListenerController.java b/packages/SystemUI/plugin/src/com/android/systemui/plugins/NotificationListenerController.java
index fac9e98..6799450 100644
--- a/packages/SystemUI/plugin/src/com/android/systemui/plugins/NotificationListenerController.java
+++ b/packages/SystemUI/plugin/src/com/android/systemui/plugins/NotificationListenerController.java
@@ -14,6 +14,8 @@
package com.android.systemui.plugins;
+import android.app.NotificationChannel;
+import android.os.UserHandle;
import android.service.notification.NotificationListenerService.RankingMap;
import android.service.notification.StatusBarNotification;
@@ -30,13 +32,32 @@
void onListenerConnected(NotificationProvider provider);
+ /**
+ * @return whether plugin wants to skip the default callbacks.
+ */
default boolean onNotificationPosted(StatusBarNotification sbn, RankingMap rankingMap) {
return false;
}
+
+ /**
+ * @return whether plugin wants to skip the default callbacks.
+ */
default boolean onNotificationRemoved(StatusBarNotification sbn, RankingMap rankingMap) {
return false;
}
+ /**
+ * Called when a notification channel is modified.
+ * @param modificationType One of {@link #NOTIFICATION_CHANNEL_OR_GROUP_ADDED},
+ * {@link #NOTIFICATION_CHANNEL_OR_GROUP_UPDATED},
+ * {@link #NOTIFICATION_CHANNEL_OR_GROUP_DELETED}.
+ * @return whether a plugin wants to skip the default callbacks.
+ */
+ default boolean onNotificationChannelModified(
+ String pkgName, UserHandle user, NotificationChannel channel, int modificationType) {
+ return false;
+ }
+
default StatusBarNotification[] getActiveNotifications(
StatusBarNotification[] activeNotifications) {
return activeNotifications;
diff --git a/packages/SystemUI/res/layout/quick_settings_brightness_dialog.xml b/packages/SystemUI/res/layout/quick_settings_brightness_dialog.xml
index 11814a1..9cc09aa 100644
--- a/packages/SystemUI/res/layout/quick_settings_brightness_dialog.xml
+++ b/packages/SystemUI/res/layout/quick_settings_brightness_dialog.xml
@@ -23,7 +23,7 @@
<com.android.systemui.settings.brightness.BrightnessSliderView
android:id="@+id/brightness_slider"
android:layout_width="0dp"
- android:layout_height="48dp"
+ android:layout_height="@dimen/brightness_mirror_height"
android:layout_gravity="center_vertical"
android:layout_weight="1"
android:contentDescription="@string/accessibility_brightness"
diff --git a/packages/SystemUI/res/values-bn/strings.xml b/packages/SystemUI/res/values-bn/strings.xml
index 31a6e1e..92e0c1d 100644
--- a/packages/SystemUI/res/values-bn/strings.xml
+++ b/packages/SystemUI/res/values-bn/strings.xml
@@ -86,16 +86,11 @@
<string name="screenshot_failed_to_save_unknown_text" msgid="1506621600548684129">"আবার স্ক্রিনশট নেওয়ার চেষ্টা করুন"</string>
<string name="screenshot_failed_to_save_text" msgid="8344173457344027501">"বেশি জায়গা নেই তাই স্ক্রিনশটটি সেভ করা যাবে না৷"</string>
<string name="screenshot_failed_to_capture_text" msgid="7818288545874407451">"এই অ্যাপ বা আপনার প্রতিষ্ঠান স্ক্রিনশট নেওয়ার অনুমতি দেয়নি"</string>
- <!-- no translation found for screenshot_edit_label (8754981973544133050) -->
- <skip />
- <!-- no translation found for screenshot_edit_description (3333092254706788906) -->
- <skip />
- <!-- no translation found for screenshot_scroll_label (7682877978685434621) -->
- <skip />
- <!-- no translation found for screenshot_scroll_description (7855773867093272175) -->
- <skip />
- <!-- no translation found for screenshot_dismiss_description (4702341245899508786) -->
- <skip />
+ <string name="screenshot_edit_label" msgid="8754981973544133050">"এডিট করুন"</string>
+ <string name="screenshot_edit_description" msgid="3333092254706788906">"স্ক্রিনশট এডিট করুন"</string>
+ <string name="screenshot_scroll_label" msgid="7682877978685434621">"স্ক্রল করুন"</string>
+ <string name="screenshot_scroll_description" msgid="7855773867093272175">"স্ক্রিনশট স্ক্রল করুন"</string>
+ <string name="screenshot_dismiss_description" msgid="4702341245899508786">"স্ক্রিনশট বাতিল করুন"</string>
<string name="screenshot_preview_description" msgid="7606510140714080474">"স্ক্রিনশটের প্রিভিউ"</string>
<string name="screenrecord_name" msgid="2596401223859996572">"স্ক্রিন রেকর্ডার"</string>
<string name="screenrecord_background_processing_label" msgid="7244617554884238898">"স্ক্রিন রেকর্ডিং প্রসেস হচ্ছে"</string>
diff --git a/packages/SystemUI/res/values-es/strings.xml b/packages/SystemUI/res/values-es/strings.xml
index d9b805b..2ce2718 100644
--- a/packages/SystemUI/res/values-es/strings.xml
+++ b/packages/SystemUI/res/values-es/strings.xml
@@ -88,8 +88,8 @@
<string name="screenshot_failed_to_capture_text" msgid="7818288545874407451">"La aplicación o tu organización no permiten realizar capturas de pantalla"</string>
<string name="screenshot_edit_label" msgid="8754981973544133050">"Editar"</string>
<string name="screenshot_edit_description" msgid="3333092254706788906">"Editar captura de pantalla"</string>
- <string name="screenshot_scroll_label" msgid="7682877978685434621">"Desplazarse"</string>
- <string name="screenshot_scroll_description" msgid="7855773867093272175">"Desplazarse por la captura de pantalla"</string>
+ <string name="screenshot_scroll_label" msgid="7682877978685434621">"Pantalla continua"</string>
+ <string name="screenshot_scroll_description" msgid="7855773867093272175">"Hacer captura de pantalla continua"</string>
<string name="screenshot_dismiss_description" msgid="4702341245899508786">"Cerrar captura de pantalla"</string>
<string name="screenshot_preview_description" msgid="7606510140714080474">"Vista previa de captura de pantalla"</string>
<string name="screenrecord_name" msgid="2596401223859996572">"Grabación de pantalla"</string>
diff --git a/packages/SystemUI/res/values-eu/strings.xml b/packages/SystemUI/res/values-eu/strings.xml
index 453d32e..835449f 100644
--- a/packages/SystemUI/res/values-eu/strings.xml
+++ b/packages/SystemUI/res/values-eu/strings.xml
@@ -89,7 +89,7 @@
<string name="screenshot_edit_label" msgid="8754981973544133050">"Editatu"</string>
<string name="screenshot_edit_description" msgid="3333092254706788906">"Editatu pantaila-argazkia"</string>
<string name="screenshot_scroll_label" msgid="7682877978685434621">"Egin gora eta behera"</string>
- <string name="screenshot_scroll_description" msgid="7855773867093272175">"Pantaila-kaptura etengabea"</string>
+ <string name="screenshot_scroll_description" msgid="7855773867093272175">"Pantaila-argazki etengabea"</string>
<string name="screenshot_dismiss_description" msgid="4702341245899508786">"Baztertu pantaila-argazkia"</string>
<string name="screenshot_preview_description" msgid="7606510140714080474">"Pantaila-argazkiaren aurrebista"</string>
<string name="screenrecord_name" msgid="2596401223859996572">"Pantaila-grabagailua"</string>
diff --git a/packages/SystemUI/res/values-land/config.xml b/packages/SystemUI/res/values-land/config.xml
index 2f7fbaf..46ec23c 100644
--- a/packages/SystemUI/res/values-land/config.xml
+++ b/packages/SystemUI/res/values-land/config.xml
@@ -20,6 +20,9 @@
<!-- These resources are around just to allow their values to be customized
for different hardware and product builds. -->
<resources>
+ <!-- The maximum number of tiles in the QuickQSPanel -->
+ <integer name="quick_qs_panel_max_columns">6</integer>
+
<!-- The maximum number of rows in the QuickSettings -->
<integer name="quick_settings_max_rows">2</integer>
diff --git a/packages/SystemUI/res/values-mr/strings.xml b/packages/SystemUI/res/values-mr/strings.xml
index ff67a40..a487a63 100644
--- a/packages/SystemUI/res/values-mr/strings.xml
+++ b/packages/SystemUI/res/values-mr/strings.xml
@@ -86,16 +86,11 @@
<string name="screenshot_failed_to_save_unknown_text" msgid="1506621600548684129">"स्क्रीनशॉट पुन्हा घेण्याचा प्रयत्न करा"</string>
<string name="screenshot_failed_to_save_text" msgid="8344173457344027501">"मर्यादित स्टोरेज जागेमुळे स्क्रीनशॉट सेव्ह करू शकत नाही"</string>
<string name="screenshot_failed_to_capture_text" msgid="7818288545874407451">"अॅप किंवा आपल्या संस्थेद्वारे स्क्रीनशॉट घेण्याची अनुमती नाही"</string>
- <!-- no translation found for screenshot_edit_label (8754981973544133050) -->
- <skip />
- <!-- no translation found for screenshot_edit_description (3333092254706788906) -->
- <skip />
- <!-- no translation found for screenshot_scroll_label (7682877978685434621) -->
- <skip />
- <!-- no translation found for screenshot_scroll_description (7855773867093272175) -->
- <skip />
- <!-- no translation found for screenshot_dismiss_description (4702341245899508786) -->
- <skip />
+ <string name="screenshot_edit_label" msgid="8754981973544133050">"संपादित करा"</string>
+ <string name="screenshot_edit_description" msgid="3333092254706788906">"स्क्रीनशॉट संपादित करा"</string>
+ <string name="screenshot_scroll_label" msgid="7682877978685434621">"स्क्रोल करा"</string>
+ <string name="screenshot_scroll_description" msgid="7855773867093272175">"स्क्रीनशॉटवर स्क्रोल करा"</string>
+ <string name="screenshot_dismiss_description" msgid="4702341245899508786">"स्क्रीनशॉट डिसमिस करा"</string>
<string name="screenshot_preview_description" msgid="7606510140714080474">"स्क्रीनशॉटचे पूर्वावलोकन"</string>
<string name="screenrecord_name" msgid="2596401223859996572">"स्क्रीन रेकॉर्डर"</string>
<string name="screenrecord_background_processing_label" msgid="7244617554884238898">"स्क्रीन रेकॉर्डिंग प्रोसेस सुरू"</string>
diff --git a/packages/SystemUI/res/values-ne/strings.xml b/packages/SystemUI/res/values-ne/strings.xml
index 560fd0b..eca79cb 100644
--- a/packages/SystemUI/res/values-ne/strings.xml
+++ b/packages/SystemUI/res/values-ne/strings.xml
@@ -86,16 +86,11 @@
<string name="screenshot_failed_to_save_unknown_text" msgid="1506621600548684129">"स्क्रिनसट फेरि लिएर हेर्नुहोस्"</string>
<string name="screenshot_failed_to_save_text" msgid="8344173457344027501">"भण्डारण ठाउँ सीमित भएका कारण स्क्रिनसट सुरक्षित गर्न सकिएन"</string>
<string name="screenshot_failed_to_capture_text" msgid="7818288545874407451">"उक्त एप वा तपाईंको संगठनले स्क्रिनसटहरू लिन दिँदैन"</string>
- <!-- no translation found for screenshot_edit_label (8754981973544133050) -->
- <skip />
- <!-- no translation found for screenshot_edit_description (3333092254706788906) -->
- <skip />
- <!-- no translation found for screenshot_scroll_label (7682877978685434621) -->
- <skip />
- <!-- no translation found for screenshot_scroll_description (7855773867093272175) -->
- <skip />
- <!-- no translation found for screenshot_dismiss_description (4702341245899508786) -->
- <skip />
+ <string name="screenshot_edit_label" msgid="8754981973544133050">"सम्पादन गर्नुहोस्"</string>
+ <string name="screenshot_edit_description" msgid="3333092254706788906">"स्क्रिनसट सम्पादन गर्नुहोस्"</string>
+ <string name="screenshot_scroll_label" msgid="7682877978685434621">"स्क्रोल गर्नुहोस्"</string>
+ <string name="screenshot_scroll_description" msgid="7855773867093272175">"स्क्रिनसट स्क्रोल गर्नुहोस्"</string>
+ <string name="screenshot_dismiss_description" msgid="4702341245899508786">"स्क्रिनसट हटाउनुहोस्"</string>
<string name="screenshot_preview_description" msgid="7606510140714080474">"स्क्रिनसटको पूर्वावलोकन"</string>
<string name="screenrecord_name" msgid="2596401223859996572">"स्क्रिन रेकर्डर"</string>
<string name="screenrecord_background_processing_label" msgid="7244617554884238898">"स्क्रिन रेकर्डिङको प्रक्रिया अघि बढाइँदै"</string>
diff --git a/packages/SystemUI/res/values-sq/strings.xml b/packages/SystemUI/res/values-sq/strings.xml
index d3ebe52..297ebc6 100644
--- a/packages/SystemUI/res/values-sq/strings.xml
+++ b/packages/SystemUI/res/values-sq/strings.xml
@@ -86,16 +86,11 @@
<string name="screenshot_failed_to_save_unknown_text" msgid="1506621600548684129">"Provo ta nxjerrësh përsëri pamjen e ekranit"</string>
<string name="screenshot_failed_to_save_text" msgid="8344173457344027501">"Pamja e ekranit nuk mund të ruhet për shkak të hapësirës ruajtëse të kufizuar"</string>
<string name="screenshot_failed_to_capture_text" msgid="7818288545874407451">"Nxjerrja e pamjeve të ekranit nuk lejohet nga aplikacioni ose organizata jote."</string>
- <!-- no translation found for screenshot_edit_label (8754981973544133050) -->
- <skip />
- <!-- no translation found for screenshot_edit_description (3333092254706788906) -->
- <skip />
- <!-- no translation found for screenshot_scroll_label (7682877978685434621) -->
- <skip />
- <!-- no translation found for screenshot_scroll_description (7855773867093272175) -->
- <skip />
- <!-- no translation found for screenshot_dismiss_description (4702341245899508786) -->
- <skip />
+ <string name="screenshot_edit_label" msgid="8754981973544133050">"Modifiko"</string>
+ <string name="screenshot_edit_description" msgid="3333092254706788906">"Modifiko pamjen e ekranit"</string>
+ <string name="screenshot_scroll_label" msgid="7682877978685434621">"Lëviz"</string>
+ <string name="screenshot_scroll_description" msgid="7855773867093272175">"Lëviz në pamjen e ekranit"</string>
+ <string name="screenshot_dismiss_description" msgid="4702341245899508786">"Hiq pamjen e ekranit"</string>
<string name="screenshot_preview_description" msgid="7606510140714080474">"Pamja paraprake e imazhit"</string>
<string name="screenrecord_name" msgid="2596401223859996572">"Regjistruesi i ekranit"</string>
<string name="screenrecord_background_processing_label" msgid="7244617554884238898">"Regjistrimi i ekranit po përpunohet"</string>
diff --git a/packages/SystemUI/res/values-te/strings.xml b/packages/SystemUI/res/values-te/strings.xml
index 578f62b..5fed052 100644
--- a/packages/SystemUI/res/values-te/strings.xml
+++ b/packages/SystemUI/res/values-te/strings.xml
@@ -86,16 +86,11 @@
<string name="screenshot_failed_to_save_unknown_text" msgid="1506621600548684129">"స్క్రీన్షాట్ తీయడానికి మళ్లీ ప్రయత్నించండి"</string>
<string name="screenshot_failed_to_save_text" msgid="8344173457344027501">"నిల్వ స్థలం పరిమితంగా ఉన్న కారణంగా స్క్రీన్షాట్ను సేవ్ చేయడం సాధ్యపడదు"</string>
<string name="screenshot_failed_to_capture_text" msgid="7818288545874407451">"స్క్రీన్షాట్లు తీయడానికి యాప్ లేదా మీ సంస్థ అనుమతించలేదు"</string>
- <!-- no translation found for screenshot_edit_label (8754981973544133050) -->
- <skip />
- <!-- no translation found for screenshot_edit_description (3333092254706788906) -->
- <skip />
- <!-- no translation found for screenshot_scroll_label (7682877978685434621) -->
- <skip />
- <!-- no translation found for screenshot_scroll_description (7855773867093272175) -->
- <skip />
- <!-- no translation found for screenshot_dismiss_description (4702341245899508786) -->
- <skip />
+ <string name="screenshot_edit_label" msgid="8754981973544133050">"ఎడిట్ చేయండి"</string>
+ <string name="screenshot_edit_description" msgid="3333092254706788906">"స్క్రీన్షాట్ను ఎడిట్ చేయండి"</string>
+ <string name="screenshot_scroll_label" msgid="7682877978685434621">"స్క్రోల్ చేయి"</string>
+ <string name="screenshot_scroll_description" msgid="7855773867093272175">"స్క్రీన్షాట్కు స్క్రోల్ చేయండి"</string>
+ <string name="screenshot_dismiss_description" msgid="4702341245899508786">"స్క్రీన్షాట్ను విస్మరించు"</string>
<string name="screenshot_preview_description" msgid="7606510140714080474">"స్క్రీన్షాట్ ప్రివ్యూ"</string>
<string name="screenrecord_name" msgid="2596401223859996572">"స్క్రీన్ రికార్డర్"</string>
<string name="screenrecord_background_processing_label" msgid="7244617554884238898">"స్క్రీన్ రికార్డింగ్ అవుతోంది"</string>
@@ -128,7 +123,7 @@
<string name="installer_cd_button_title" msgid="5499998592841984743">"Macకు Android ఫైల్ బదిలీ యాప్ ఇన్స్టాల్ చేయండి"</string>
<string name="accessibility_back" msgid="6530104400086152611">"వెనుకకు"</string>
<string name="accessibility_home" msgid="5430449841237966217">"హోమ్"</string>
- <string name="accessibility_menu" msgid="2701163794470513040">"మెను"</string>
+ <string name="accessibility_menu" msgid="2701163794470513040">"మెనూ"</string>
<string name="accessibility_accessibility_button" msgid="4089042473497107709">"యాక్సెస్ సామర్థ్యం"</string>
<string name="accessibility_rotate_button" msgid="1238584767612362586">"స్క్రీన్ను తిప్పండి"</string>
<string name="accessibility_recent" msgid="901641734769533575">"ఓవర్వ్యూ"</string>
@@ -932,7 +927,7 @@
<string name="tuner_minus" msgid="5258518368944598545">"తీసివేత చిహ్నం"</string>
<string name="tuner_left" msgid="5758862558405684490">"ఎడమ"</string>
<string name="tuner_right" msgid="8247571132790812149">"కుడి"</string>
- <string name="tuner_menu" msgid="363690665924769420">"మెను"</string>
+ <string name="tuner_menu" msgid="363690665924769420">"మెనూ"</string>
<string name="tuner_app" msgid="6949280415826686972">"<xliff:g id="APP">%1$s</xliff:g> అనురవర్తనం"</string>
<string name="notification_channel_alerts" msgid="3385787053375150046">"హెచ్చరికలు"</string>
<string name="notification_channel_battery" msgid="9219995638046695106">"బ్యాటరీ"</string>
diff --git a/packages/SystemUI/res/values/config.xml b/packages/SystemUI/res/values/config.xml
index 4707537..4407d8f 100644
--- a/packages/SystemUI/res/values/config.xml
+++ b/packages/SystemUI/res/values/config.xml
@@ -93,10 +93,10 @@
<bool name="config_navigation_bar_enable_auto_dim_no_visible_wallpaper">true</bool>
<!-- The maximum number of tiles in the QuickQSPanel -->
- <integer name="quick_qs_panel_max_columns">6</integer>
+ <integer name="quick_qs_panel_max_columns">4</integer>
<!-- The number of columns in the QuickSettings -->
- <integer name="quick_settings_num_columns">3</integer>
+ <integer name="quick_settings_num_columns">4</integer>
<!-- The number of rows in the QuickSettings -->
<integer name="quick_settings_max_rows">3</integer>
diff --git a/packages/SystemUI/src/com/android/keyguard/KeyguardUpdateMonitor.java b/packages/SystemUI/src/com/android/keyguard/KeyguardUpdateMonitor.java
index 31b0701..42680e6 100644
--- a/packages/SystemUI/src/com/android/keyguard/KeyguardUpdateMonitor.java
+++ b/packages/SystemUI/src/com/android/keyguard/KeyguardUpdateMonitor.java
@@ -238,6 +238,16 @@
private final boolean mIsAutomotive;
private final AuthController mAuthController;
private final StatusBarStateController mStatusBarStateController;
+ private int mStatusBarState;
+ private final StatusBarStateController.StateListener mStatusBarStateControllerListener =
+ new StatusBarStateController.StateListener() {
+ @Override
+ public void onStateChanged(int newState) {
+ mStatusBarState = newState;
+ updateBiometricListeningState();
+ }
+ };
+
HashMap<Integer, SimData> mSimDatas = new HashMap<>();
HashMap<Integer, ServiceState> mServiceStates = new HashMap<Integer, ServiceState>();
@@ -247,7 +257,7 @@
private boolean mCredentialAttempted;
private boolean mKeyguardGoingAway;
private boolean mGoingToSleep;
- private boolean mBouncer;
+ private boolean mBouncer; // true if bouncerIsOrWillBeShowing
private boolean mAuthInterruptActive;
private boolean mNeedsSlowUnlockTransition;
private boolean mHasLockscreenWallpaper;
@@ -1595,6 +1605,8 @@
mBroadcastDispatcher = broadcastDispatcher;
mRingerModeTracker = ringerModeTracker;
mStatusBarStateController = statusBarStateController;
+ mStatusBarStateController.addCallback(mStatusBarStateControllerListener);
+ mStatusBarState = mStatusBarStateController.getState();
mLockPatternUtils = lockPatternUtils;
mAuthController = authController;
dumpManager.registerDumpable(getClass().getName(), this);
@@ -1905,7 +1917,8 @@
return;
}
- boolean shouldListenForFingerprint = shouldListenForFingerprint();
+ boolean shouldListenForFingerprint =
+ isUdfpsEnrolled() ? shouldListenForUdfps() : shouldListenForFingerprint();
boolean runningOrRestarting = mFingerprintRunningState == BIOMETRIC_STATE_RUNNING
|| mFingerprintRunningState == BIOMETRIC_STATE_CANCELLING_RESTARTING;
if (runningOrRestarting && !shouldListenForFingerprint) {
@@ -2002,12 +2015,20 @@
return shouldListen;
}
+ @VisibleForTesting
+ boolean shouldListenForUdfps() {
+ return shouldListenForFingerprint()
+ && !mBouncer
+ && mStatusBarState != StatusBarState.SHADE_LOCKED
+ && mStatusBarState != StatusBarState.FULLSCREEN_USER_SWITCHER
+ && mStrongAuthTracker.hasUserAuthenticatedSinceBoot();
+ }
+
/**
* If face auth is allows to scan on this exact moment.
*/
public boolean shouldListenForFace() {
- final boolean statusBarShadeLocked =
- mStatusBarStateController.getState() == StatusBarState.SHADE_LOCKED;
+ final boolean statusBarShadeLocked = mStatusBarState == StatusBarState.SHADE_LOCKED;
final boolean awakeKeyguard = mKeyguardIsVisible && mDeviceInteractive && !mGoingToSleep
&& !statusBarShadeLocked;
final int user = getCurrentUser();
@@ -2593,13 +2614,12 @@
*
* @see #sendKeyguardBouncerChanged(boolean)
*/
- private void handleKeyguardBouncerChanged(int bouncer) {
+ private void handleKeyguardBouncerChanged(int bouncerVisible) {
Assert.isMainThread();
- if (DEBUG) Log.d(TAG, "handleKeyguardBouncerChanged(" + bouncer + ")");
- boolean isBouncer = (bouncer == 1);
- mBouncer = isBouncer;
+ if (DEBUG) Log.d(TAG, "handleKeyguardBouncerChanged(" + bouncerVisible + ")");
+ mBouncer = bouncerVisible == 1;
- if (isBouncer) {
+ if (mBouncer) {
// If the bouncer is shown, always clear this flag. This can happen in the following
// situations: 1) Default camera with SHOW_WHEN_LOCKED is not chosen yet. 2) Secure
// camera requests dismiss keyguard (tapping on photos for example). When these happen,
@@ -2612,7 +2632,7 @@
for (int i = 0; i < mCallbacks.size(); i++) {
KeyguardUpdateMonitorCallback cb = mCallbacks.get(i).get();
if (cb != null) {
- cb.onKeyguardBouncerChanged(isBouncer);
+ cb.onKeyguardBouncerChanged(mBouncer);
}
}
updateBiometricListeningState();
@@ -2745,10 +2765,10 @@
/**
* @see #handleKeyguardBouncerChanged(int)
*/
- public void sendKeyguardBouncerChanged(boolean showingBouncer) {
- if (DEBUG) Log.d(TAG, "sendKeyguardBouncerChanged(" + showingBouncer + ")");
+ public void sendKeyguardBouncerChanged(boolean bouncerIsOrWillBeShowing) {
+ if (DEBUG) Log.d(TAG, "sendKeyguardBouncerChanged(" + bouncerIsOrWillBeShowing + ")");
Message message = mHandler.obtainMessage(MSG_KEYGUARD_BOUNCER_CHANGED);
- message.arg1 = showingBouncer ? 1 : 0;
+ message.arg1 = bouncerIsOrWillBeShowing ? 1 : 0;
message.sendToTarget();
}
@@ -3081,6 +3101,12 @@
pw.println(" strongAuthFlags=" + Integer.toHexString(strongAuthFlags));
pw.println(" trustManaged=" + getUserTrustIsManaged(userId));
pw.println(" udfpsEnrolled=" + isUdfpsEnrolled());
+ if (isUdfpsEnrolled()) {
+ pw.println(" shouldListenForUdfps=" + shouldListenForUdfps());
+ pw.println(" bouncerVisible=" + mBouncer);
+ pw.println(" mStatusBarState="
+ + StatusBarState.toShortString(mStatusBarState));
+ }
}
if (mFaceManager != null && mFaceManager.isHardwareDetected()) {
final int userId = ActivityManager.getCurrentUser();
diff --git a/packages/SystemUI/src/com/android/keyguard/KeyguardUpdateMonitorCallback.java b/packages/SystemUI/src/com/android/keyguard/KeyguardUpdateMonitorCallback.java
index 3c5eceb..b722dea 100644
--- a/packages/SystemUI/src/com/android/keyguard/KeyguardUpdateMonitorCallback.java
+++ b/packages/SystemUI/src/com/android/keyguard/KeyguardUpdateMonitorCallback.java
@@ -94,7 +94,8 @@
/**
* Called when the keyguard enters or leaves bouncer mode.
- * @param bouncer if true, keyguard is now in bouncer mode.
+ * @param bouncer if true, keyguard is showing the bouncer or transitioning from/to bouncer
+ * mode.
*/
public void onKeyguardBouncerChanged(boolean bouncer) { }
diff --git a/packages/SystemUI/src/com/android/systemui/SystemUIFactory.java b/packages/SystemUI/src/com/android/systemui/SystemUIFactory.java
index 7e48edf..11180d1 100644
--- a/packages/SystemUI/src/com/android/systemui/SystemUIFactory.java
+++ b/packages/SystemUI/src/com/android/systemui/SystemUIFactory.java
@@ -110,7 +110,8 @@
.setOneHanded(mWMComponent.getOneHanded())
.setBubbles(mWMComponent.getBubbles())
.setHideDisplayCutout(mWMComponent.getHideDisplayCutout())
- .setShellDump(mWMComponent.getShellDump());
+ .setShellDump(mWMComponent.getShellDump())
+ .setAppPairs(mWMComponent.getAppPairs());
} else {
// TODO: Call on prepareSysUIComponentBuilder but not with real components.
builder = builder.setPip(Optional.ofNullable(null))
@@ -118,7 +119,8 @@
.setOneHanded(Optional.ofNullable(null))
.setBubbles(Optional.ofNullable(null))
.setHideDisplayCutout(Optional.ofNullable(null))
- .setShellDump(Optional.ofNullable(null));
+ .setShellDump(Optional.ofNullable(null))
+ .setAppPairs(Optional.ofNullable(null));
}
mSysUIComponent = builder.build();
if (initializeComponents) {
diff --git a/packages/SystemUI/src/com/android/systemui/accessibility/WindowMagnification.java b/packages/SystemUI/src/com/android/systemui/accessibility/WindowMagnification.java
index 724d197ba..c71bb5b 100644
--- a/packages/SystemUI/src/com/android/systemui/accessibility/WindowMagnification.java
+++ b/packages/SystemUI/src/com/android/systemui/accessibility/WindowMagnification.java
@@ -17,20 +17,16 @@
package com.android.systemui.accessibility;
import android.annotation.MainThread;
-import android.annotation.NonNull;
import android.annotation.Nullable;
import android.content.Context;
import android.content.pm.ActivityInfo;
import android.content.res.Configuration;
import android.graphics.Rect;
import android.os.Handler;
-import android.os.RemoteException;
-import android.util.Log;
import android.view.SurfaceControl;
import android.view.accessibility.AccessibilityManager;
import android.view.accessibility.IRemoteMagnificationAnimationCallback;
import android.view.accessibility.IWindowMagnificationConnection;
-import android.view.accessibility.IWindowMagnificationConnectionCallback;
import com.android.internal.annotations.VisibleForTesting;
import com.android.internal.graphics.SfVsyncFrameCallbackProvider;
@@ -174,95 +170,4 @@
mAccessibilityManager.setWindowMagnificationConnection(null);
//TODO: destroy controllers.
}
-
- private static class WindowMagnificationConnectionImpl extends
- IWindowMagnificationConnection.Stub {
-
- private static final String TAG = "WindowMagnificationConnectionImpl";
-
- private IWindowMagnificationConnectionCallback mConnectionCallback;
- private final WindowMagnification mWindowMagnification;
- private final Handler mHandler;
- private final ModeSwitchesController mModeSwitchesController;
-
- WindowMagnificationConnectionImpl(@NonNull WindowMagnification windowMagnification,
- @Main Handler mainHandler, ModeSwitchesController modeSwitchesController) {
- mWindowMagnification = windowMagnification;
- mHandler = mainHandler;
- mModeSwitchesController = modeSwitchesController;
- }
-
- @Override
- public void enableWindowMagnification(int displayId, float scale, float centerX,
- float centerY, IRemoteMagnificationAnimationCallback callback) {
- mHandler.post(
- () -> mWindowMagnification.enableWindowMagnification(displayId, scale, centerX,
- centerY, callback));
- }
-
- @Override
- public void setScale(int displayId, float scale) {
- mHandler.post(() -> mWindowMagnification.setScale(displayId, scale));
- }
-
- @Override
- public void disableWindowMagnification(int displayId,
- IRemoteMagnificationAnimationCallback callback) {
- mHandler.post(() -> mWindowMagnification.disableWindowMagnification(displayId,
- callback));
- }
-
- @Override
- public void moveWindowMagnifier(int displayId, float offsetX, float offsetY) {
- mHandler.post(
- () -> mWindowMagnification.moveWindowMagnifier(displayId, offsetX, offsetY));
- }
-
- @Override
- public void showMagnificationButton(int displayId, int magnificationMode) {
- mHandler.post(
- () -> mModeSwitchesController.showButton(displayId, magnificationMode));
- }
-
- @Override
- public void removeMagnificationButton(int displayId) {
- mHandler.post(
- () -> mModeSwitchesController.removeButton(displayId));
- }
-
- @Override
- public void setConnectionCallback(IWindowMagnificationConnectionCallback callback) {
- mConnectionCallback = callback;
- }
-
- void onWindowMagnifierBoundsChanged(int displayId, Rect frame) {
- if (mConnectionCallback != null) {
- try {
- mConnectionCallback.onWindowMagnifierBoundsChanged(displayId, frame);
- } catch (RemoteException e) {
- Log.e(TAG, "Failed to inform bounds changed", e);
- }
- }
- }
-
- void onSourceBoundsChanged(int displayId, Rect sourceBounds) {
- if (mConnectionCallback != null) {
- try {
- mConnectionCallback.onSourceBoundsChanged(displayId, sourceBounds);
- } catch (RemoteException e) {
- Log.e(TAG, "Failed to inform source bounds changed", e);
- }
- }
- }
-
- void onPerformScaleAction(int displayId, float scale) {
- if (mConnectionCallback != null) {
- try {
- mConnectionCallback.onPerformScaleAction(displayId, scale);
- } catch (RemoteException e) {
- Log.e(TAG, "Failed to inform performing scale action", e);
- }
- }
- }
- }
}
diff --git a/packages/SystemUI/src/com/android/systemui/accessibility/WindowMagnificationConnectionImpl.java b/packages/SystemUI/src/com/android/systemui/accessibility/WindowMagnificationConnectionImpl.java
new file mode 100644
index 0000000..be7d757
--- /dev/null
+++ b/packages/SystemUI/src/com/android/systemui/accessibility/WindowMagnificationConnectionImpl.java
@@ -0,0 +1,123 @@
+/*
+ * Copyright (C) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package com.android.systemui.accessibility;
+
+import android.annotation.NonNull;
+import android.graphics.Rect;
+import android.os.Handler;
+import android.os.RemoteException;
+import android.util.Log;
+import android.view.accessibility.IRemoteMagnificationAnimationCallback;
+import android.view.accessibility.IWindowMagnificationConnection;
+import android.view.accessibility.IWindowMagnificationConnectionCallback;
+
+import com.android.systemui.dagger.qualifiers.Main;
+
+/**
+ * Implementation of window magnification connection.
+ *
+ * @see IWindowMagnificationConnection
+ */
+class WindowMagnificationConnectionImpl extends IWindowMagnificationConnection.Stub {
+
+ private static final String TAG = "WindowMagnificationConnectionImpl";
+
+ private IWindowMagnificationConnectionCallback mConnectionCallback;
+ private final WindowMagnification mWindowMagnification;
+ private final Handler mHandler;
+ private final ModeSwitchesController mModeSwitchesController;
+
+ WindowMagnificationConnectionImpl(@NonNull WindowMagnification windowMagnification,
+ @Main Handler mainHandler, ModeSwitchesController modeSwitchesController) {
+ mWindowMagnification = windowMagnification;
+ mHandler = mainHandler;
+ mModeSwitchesController = modeSwitchesController;
+ }
+
+ @Override
+ public void enableWindowMagnification(int displayId, float scale, float centerX,
+ float centerY, IRemoteMagnificationAnimationCallback callback) {
+ mHandler.post(
+ () -> mWindowMagnification.enableWindowMagnification(displayId, scale, centerX,
+ centerY, callback));
+ }
+
+ @Override
+ public void setScale(int displayId, float scale) {
+ mHandler.post(() -> mWindowMagnification.setScale(displayId, scale));
+ }
+
+ @Override
+ public void disableWindowMagnification(int displayId,
+ IRemoteMagnificationAnimationCallback callback) {
+ mHandler.post(() -> mWindowMagnification.disableWindowMagnification(displayId,
+ callback));
+ }
+
+ @Override
+ public void moveWindowMagnifier(int displayId, float offsetX, float offsetY) {
+ mHandler.post(
+ () -> mWindowMagnification.moveWindowMagnifier(displayId, offsetX, offsetY));
+ }
+
+ @Override
+ public void showMagnificationButton(int displayId, int magnificationMode) {
+ mHandler.post(
+ () -> mModeSwitchesController.showButton(displayId, magnificationMode));
+ }
+
+ @Override
+ public void removeMagnificationButton(int displayId) {
+ mHandler.post(
+ () -> mModeSwitchesController.removeButton(displayId));
+ }
+
+ @Override
+ public void setConnectionCallback(IWindowMagnificationConnectionCallback callback) {
+ mConnectionCallback = callback;
+ }
+
+ void onWindowMagnifierBoundsChanged(int displayId, Rect frame) {
+ if (mConnectionCallback != null) {
+ try {
+ mConnectionCallback.onWindowMagnifierBoundsChanged(displayId, frame);
+ } catch (RemoteException e) {
+ Log.e(TAG, "Failed to inform bounds changed", e);
+ }
+ }
+ }
+
+ void onSourceBoundsChanged(int displayId, Rect sourceBounds) {
+ if (mConnectionCallback != null) {
+ try {
+ mConnectionCallback.onSourceBoundsChanged(displayId, sourceBounds);
+ } catch (RemoteException e) {
+ Log.e(TAG, "Failed to inform source bounds changed", e);
+ }
+ }
+ }
+
+ void onPerformScaleAction(int displayId, float scale) {
+ if (mConnectionCallback != null) {
+ try {
+ mConnectionCallback.onPerformScaleAction(displayId, scale);
+ } catch (RemoteException e) {
+ Log.e(TAG, "Failed to inform performing scale action", e);
+ }
+ }
+ }
+}
diff --git a/packages/SystemUI/src/com/android/systemui/biometrics/AuthController.java b/packages/SystemUI/src/com/android/systemui/biometrics/AuthController.java
index a6b1b90..3f66c08 100644
--- a/packages/SystemUI/src/com/android/systemui/biometrics/AuthController.java
+++ b/packages/SystemUI/src/com/android/systemui/biometrics/AuthController.java
@@ -54,7 +54,6 @@
import com.android.systemui.doze.DozeReceiver;
import com.android.systemui.plugins.statusbar.StatusBarStateController;
import com.android.systemui.statusbar.CommandQueue;
-import com.android.systemui.statusbar.phone.KeyguardBouncer;
import java.util.ArrayList;
import java.util.List;
@@ -68,7 +67,7 @@
*/
@SysUISingleton
public class AuthController extends SystemUI implements CommandQueue.Callbacks,
- AuthDialogCallback, DozeReceiver, KeyguardBouncer.BouncerExpansionCallback {
+ AuthDialogCallback, DozeReceiver {
private static final String TAG = "AuthController";
private static final boolean DEBUG = true;
@@ -460,35 +459,6 @@
mCurrentDialog = null;
}
- /** See {@link KeyguardBouncer.BouncerExpansionCallback#onFullyShown}. */
- @Override
- public void onFullyShown() {
- if (mUdfpsController != null) {
- mUdfpsController.setBouncerVisibility(true);
- }
- }
-
- /** See {@link KeyguardBouncer.BouncerExpansionCallback#onStartingToHide}. */
- @Override
- public void onStartingToHide() {
- }
-
- /** See {@link KeyguardBouncer.BouncerExpansionCallback#onStartingToShow}. */
- @Override
- public void onStartingToShow() {
- if (mUdfpsController != null) {
- mUdfpsController.setBouncerVisibility(true);
- }
- }
-
- /** See {@link KeyguardBouncer.BouncerExpansionCallback#onFullyHidden}. */
- @Override
- public void onFullyHidden() {
- if (mUdfpsController != null) {
- mUdfpsController.setBouncerVisibility(false);
- }
- }
-
/**
* Whether the passed userId has enrolled UDFPS.
*/
diff --git a/packages/SystemUI/src/com/android/systemui/biometrics/UdfpsController.java b/packages/SystemUI/src/com/android/systemui/biometrics/UdfpsController.java
index a4b407d..e437740 100644
--- a/packages/SystemUI/src/com/android/systemui/biometrics/UdfpsController.java
+++ b/packages/SystemUI/src/com/android/systemui/biometrics/UdfpsController.java
@@ -107,8 +107,6 @@
private boolean mIsOverlayShowing;
// Indicates whether the overlay has been requested.
private boolean mIsOverlayRequested;
- // Indicates whether the bouncer is showing. When it is showing, the overlay needs to be hidden.
- private boolean mIsBouncerShowing;
// The fingerprint AOD trigger doesn't provide an ACTION_UP/ACTION_CANCEL event to tell us when
// to turn off high brightness mode. To get around this limitation, the state of the AOD
@@ -260,21 +258,8 @@
updateOverlay();
}
- /**
- * Call when the visibility of the bouncer changes.
- *
- * @param isShowing Whether or not the bouncer is showing
- */
- void setBouncerVisibility(boolean isShowing) {
- if (isShowing == mIsBouncerShowing) {
- return;
- }
- mIsBouncerShowing = isShowing;
- updateOverlay();
- }
-
private void updateOverlay() {
- if (mIsOverlayRequested && !mIsBouncerShowing) {
+ if (mIsOverlayRequested) {
showUdfpsOverlay();
} else {
hideUdfpsOverlay();
diff --git a/packages/SystemUI/src/com/android/systemui/dagger/SysUIComponent.java b/packages/SystemUI/src/com/android/systemui/dagger/SysUIComponent.java
index 02c3c2f..68a28ba 100644
--- a/packages/SystemUI/src/com/android/systemui/dagger/SysUIComponent.java
+++ b/packages/SystemUI/src/com/android/systemui/dagger/SysUIComponent.java
@@ -25,6 +25,7 @@
import com.android.systemui.statusbar.policy.ConfigurationController;
import com.android.systemui.util.InjectionInflationController;
import com.android.wm.shell.ShellDump;
+import com.android.wm.shell.apppairs.AppPairs;
import com.android.wm.shell.bubbles.Bubbles;
import com.android.wm.shell.hidedisplaycutout.HideDisplayCutout;
import com.android.wm.shell.onehanded.OneHanded;
@@ -61,6 +62,9 @@
Builder setSplitScreen(Optional<SplitScreen> s);
@BindsInstance
+ Builder setAppPairs(Optional<AppPairs> s);
+
+ @BindsInstance
Builder setOneHanded(Optional<OneHanded> o);
@BindsInstance
diff --git a/packages/SystemUI/src/com/android/systemui/dagger/WMComponent.java b/packages/SystemUI/src/com/android/systemui/dagger/WMComponent.java
index b3e62e52..e634529 100644
--- a/packages/SystemUI/src/com/android/systemui/dagger/WMComponent.java
+++ b/packages/SystemUI/src/com/android/systemui/dagger/WMComponent.java
@@ -19,6 +19,7 @@
import com.android.systemui.wmshell.WMShellModule;
import com.android.wm.shell.ShellDump;
import com.android.wm.shell.ShellInit;
+import com.android.wm.shell.apppairs.AppPairs;
import com.android.wm.shell.bubbles.Bubbles;
import com.android.wm.shell.hidedisplaycutout.HideDisplayCutout;
import com.android.wm.shell.onehanded.OneHanded;
@@ -71,6 +72,9 @@
Optional<SplitScreen> getSplitScreen();
@WMSingleton
+ Optional<AppPairs> getAppPairs();
+
+ @WMSingleton
Optional<Bubbles> getBubbles();
@WMSingleton
diff --git a/packages/SystemUI/src/com/android/systemui/people/widget/PeopleSpaceWidgetManager.java b/packages/SystemUI/src/com/android/systemui/people/widget/PeopleSpaceWidgetManager.java
index 8415368..9b7cf6e 100644
--- a/packages/SystemUI/src/com/android/systemui/people/widget/PeopleSpaceWidgetManager.java
+++ b/packages/SystemUI/src/com/android/systemui/people/widget/PeopleSpaceWidgetManager.java
@@ -16,9 +16,11 @@
package com.android.systemui.people.widget;
+import android.app.NotificationChannel;
import android.content.ComponentName;
import android.content.Context;
import android.os.ServiceManager;
+import android.os.UserHandle;
import android.service.notification.NotificationListenerService;
import android.service.notification.StatusBarNotification;
import android.util.Log;
@@ -130,6 +132,18 @@
if (DEBUG) Log.d(TAG, "onNotificationsInitialized");
updateWidgets();
}
+
+ @Override
+ public void onNotificationChannelModified(
+ String pkgName,
+ UserHandle user,
+ NotificationChannel channel,
+ int modificationType) {
+ if (DEBUG) Log.d(TAG, "onNotificationChannelModified");
+ if (channel.isConversation()) {
+ updateWidgets();
+ }
+ }
};
}
diff --git a/packages/SystemUI/src/com/android/systemui/qs/PagedTileLayout.java b/packages/SystemUI/src/com/android/systemui/qs/PagedTileLayout.java
index 3062a77..8c7d459 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/PagedTileLayout.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/PagedTileLayout.java
@@ -63,7 +63,6 @@
private int mPageToRestore = -1;
private int mLayoutOrientation;
private int mLayoutDirection;
- private int mHorizontalClipBound;
private final Rect mClippingRect;
private final UiEventLogger mUiEventLogger = QSEvents.INSTANCE.getQsUiEventsLogger();
private int mExcessHeight;
@@ -333,7 +332,6 @@
// Update bottom padding, useful for removing extra space once the panel page indicator is
// hidden.
Resources res = getContext().getResources();
- mHorizontalClipBound = res.getDimensionPixelSize(R.dimen.notification_side_paddings);
setPadding(0, 0, 0,
getContext().getResources().getDimensionPixelSize(
R.dimen.qs_paged_tile_layout_padding_bottom));
@@ -351,7 +349,8 @@
@Override
protected void onLayout(boolean changed, int l, int t, int r, int b) {
super.onLayout(changed, l, t, r, b);
- mClippingRect.set(mHorizontalClipBound, 0, (r - l) - mHorizontalClipBound, b - t);
+ // Clip to margins
+ mClippingRect.set(0, 0, (r - l), b - t);
setClipBounds(mClippingRect);
}
diff --git a/packages/SystemUI/src/com/android/systemui/qs/QSAnimator.java b/packages/SystemUI/src/com/android/systemui/qs/QSAnimator.java
index c52b8ca..e9207f1 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/QSAnimator.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/QSAnimator.java
@@ -200,8 +200,6 @@
int count = 0;
int[] loc1 = new int[2];
int[] loc2 = new int[2];
- int lastXDiff = 0;
- int lastX = 0;
clearAnimationState();
mAllViews.clear();
@@ -231,12 +229,11 @@
QSTileView quickTileView = mQuickQSPanelController.getTileView(tile);
if (quickTileView == null) continue;
- lastX = loc1[0];
getRelativePosition(loc1, quickTileView.getIcon().getIconView(), view);
getRelativePosition(loc2, tileIcon, view);
final int xDiff = loc2[0] - loc1[0];
final int yDiff = loc2[1] - loc1[1];
- lastXDiff = loc1[0] - lastX;
+
if (count < tileLayout.getNumVisibleTiles()) {
// Move the quick tile right from its location to the new one.
@@ -267,19 +264,8 @@
mAllViews.add(tileView.getIcon());
mAllViews.add(quickTileView);
} else if (mFullRows && isIconInAnimatedRow(count)) {
- // TODO: Refactor some of this, it shares a lot with the above block.
- // Move the last tile position over by the last difference between quick tiles.
- // This makes the extra icons seems as if they are coming from positions in the
- // quick panel.
- loc1[0] += lastXDiff;
- getRelativePosition(loc2, tileIcon, view);
- final int xDiff = loc2[0] - loc1[0];
- final int yDiff = loc2[1] - loc1[1];
- firstPageBuilder.addFloat(tileView, "translationY", heightDiff, 0);
- translationXBuilder.addFloat(tileView, "translationX", -xDiff, 0);
- translationYBuilder.addFloat(tileView, "translationY", -yDiff, 0);
- translationYBuilder.addFloat(tileIcon, "translationY", -yDiff, 0);
+ firstPageBuilder.addFloat(tileView, "translationY", -heightDiff, 0);
mAllViews.add(tileIcon);
} else {
diff --git a/packages/SystemUI/src/com/android/systemui/qs/QSFragment.java b/packages/SystemUI/src/com/android/systemui/qs/QSFragment.java
index 0fe018e..043f5f1 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/QSFragment.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/QSFragment.java
@@ -16,6 +16,9 @@
import static android.app.StatusBarManager.DISABLE2_QUICK_SETTINGS;
+import static com.android.systemui.media.dagger.MediaModule.QS_PANEL;
+import static com.android.systemui.media.dagger.MediaModule.QUICK_QS_PANEL;
+
import android.animation.Animator;
import android.animation.AnimatorListenerAdapter;
import android.content.res.Configuration;
@@ -50,6 +53,7 @@
import com.android.systemui.util.Utils;
import javax.inject.Inject;
+import javax.inject.Named;
public class QSFragment extends LifecycleFragment implements QS, CommandQueue.Callbacks,
StatusBarStateController.StateListener {
@@ -82,6 +86,8 @@
private final InjectionInflationController mInjectionInflater;
private final CommandQueue mCommandQueue;
private final QSDetailDisplayer mQsDetailDisplayer;
+ private final MediaHost mQsMediaHost;
+ private final MediaHost mQqsMediaHost;
private final QSFragmentComponent.Factory mQsComponentFactory;
private final QSTileHost mHost;
private boolean mShowCollapsedOnKeyguard;
@@ -104,12 +110,15 @@
public QSFragment(RemoteInputQuickSettingsDisabler remoteInputQsDisabler,
InjectionInflationController injectionInflater, QSTileHost qsTileHost,
StatusBarStateController statusBarStateController, CommandQueue commandQueue,
- QSDetailDisplayer qsDetailDisplayer,
+ QSDetailDisplayer qsDetailDisplayer, @Named(QS_PANEL) MediaHost qsMediaHost,
+ @Named(QUICK_QS_PANEL) MediaHost qqsMediaHost,
QSFragmentComponent.Factory qsComponentFactory) {
mRemoteInputQuickSettingsDisabler = remoteInputQsDisabler;
mInjectionInflater = injectionInflater;
mCommandQueue = commandQueue;
mQsDetailDisplayer = qsDetailDisplayer;
+ mQsMediaHost = qsMediaHost;
+ mQqsMediaHost = qqsMediaHost;
mQsComponentFactory = qsComponentFactory;
commandQueue.observe(getLifecycle(), this);
mHost = qsTileHost;
@@ -261,7 +270,6 @@
}
public void setHost(QSTileHost qsh) {
- mHeader.setQSPanel(mQSPanelController.getView());
mQSDetail.setHost(qsh);
}
@@ -455,11 +463,9 @@
float expandedMediaPosition = absoluteBottomPosition - mQSPanelScrollView.getScrollY()
+ mQSPanelScrollView.getScrollRange();
// The expanded media host should never move below the laid out position
- pinToBottom(
- expandedMediaPosition, mQSPanelController.getMediaHost(), true /* expanded */);
+ pinToBottom(expandedMediaPosition, mQsMediaHost, true /* expanded */);
// The expanded media host should never move above the laid out position
- pinToBottom(absoluteBottomPosition, mHeader.getHeaderQsPanel().getMediaHost(),
- false /* expanded */);
+ pinToBottom(absoluteBottomPosition, mQqsMediaHost, false /* expanded */);
}
}
diff --git a/packages/SystemUI/src/com/android/systemui/qs/QSPanel.java b/packages/SystemUI/src/com/android/systemui/qs/QSPanel.java
index 08f38a8..8955a7e 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/QSPanel.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/QSPanel.java
@@ -550,6 +550,7 @@
}
boolean horizontal = shouldUseHorizontalLayout();
ViewGroup host = mMediaHost.getHostView();
+
ViewGroup newParent = horizontal ? mHorizontalLinearLayout : this;
ViewGroup currentParent = (ViewGroup) host.getParent();
if (currentParent != newParent) {
@@ -865,10 +866,6 @@
}
}
- public MediaHost getMediaHost() {
- return mMediaHost;
- }
-
/**
* Set the header container of quick settings.
*/
diff --git a/packages/SystemUI/src/com/android/systemui/qs/QSPanelController.java b/packages/SystemUI/src/com/android/systemui/qs/QSPanelController.java
index addaf7e..32c81af 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/QSPanelController.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/QSPanelController.java
@@ -16,6 +16,7 @@
package com.android.systemui.qs;
+import static com.android.systemui.media.dagger.MediaModule.QS_PANEL;
import static com.android.systemui.qs.QSPanel.QS_SHOW_BRIGHTNESS;
import android.annotation.NonNull;
@@ -40,6 +41,7 @@
import java.util.function.Consumer;
import javax.inject.Inject;
+import javax.inject.Named;
/**
* Controller for {@link QSPanel}.
@@ -49,6 +51,7 @@
private final QSSecurityFooter mQsSecurityFooter;
private final TunerService mTunerService;
private final QSCustomizerController mQsCustomizerController;
+ private final QSTileRevealController.Factory mQsTileRevealControllerFactory;
private final BrightnessController mBrightnessController;
private final BrightnessSlider.Factory mBrightnessSliderFactory;
private final BrightnessSlider mBrightnessSlider;
@@ -73,15 +76,17 @@
@Inject
QSPanelController(QSPanel view, QSSecurityFooter qsSecurityFooter, TunerService tunerService,
QSTileHost qstileHost, QSCustomizerController qsCustomizerController,
+ @Named(QS_PANEL) MediaHost mediaHost,
QSTileRevealController.Factory qsTileRevealControllerFactory,
DumpManager dumpManager, MetricsLogger metricsLogger, UiEventLogger uiEventLogger,
BrightnessController.Factory brightnessControllerFactory,
BrightnessSlider.Factory brightnessSliderFactory) {
- super(view, qstileHost, qsCustomizerController, qsTileRevealControllerFactory,
- metricsLogger, uiEventLogger, dumpManager);
+ super(view, qstileHost, qsCustomizerController, mediaHost, metricsLogger, uiEventLogger,
+ dumpManager);
mQsSecurityFooter = qsSecurityFooter;
mTunerService = tunerService;
mQsCustomizerController = qsCustomizerController;
+ mQsTileRevealControllerFactory = qsTileRevealControllerFactory;
mQsSecurityFooter.setHostEnvironment(qstileHost);
mBrightnessSliderFactory = brightnessSliderFactory;
@@ -93,6 +98,7 @@
@Override
public void onInit() {
+ super.onInit();
mQsCustomizerController.init();
mBrightnessSlider.init();
}
@@ -114,6 +120,12 @@
}
@Override
+ protected QSTileRevealController createTileRevealController() {
+ return mQsTileRevealControllerFactory.create(
+ this, (PagedTileLayout) mView.createRegularTileLayout());
+ }
+
+ @Override
protected void onViewDetached() {
mTunerService.removeTunable(mView);
mView.removeOnConfigurationChangedListener(mOnConfigurationChangedListener);
@@ -159,11 +171,6 @@
}
/** */
- public MediaHost getMediaHost() {
- return mView.getMediaHost();
- }
-
- /** */
public void setBrightnessMirror(BrightnessMirrorController brightnessMirrorController) {
mBrightnessMirrorController = brightnessMirrorController;
if (mBrightnessMirrorController != null) {
@@ -280,5 +287,10 @@
public void setFooterPageIndicator(PageIndicator pageIndicator) {
mView.setFooterPageIndicator(pageIndicator);
}
+
+ /** */
+ public boolean isExpanded() {
+ return mView.isExpanded();
+ }
}
diff --git a/packages/SystemUI/src/com/android/systemui/qs/QSPanelControllerBase.java b/packages/SystemUI/src/com/android/systemui/qs/QSPanelControllerBase.java
index a3daf0e..06bf9ac 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/QSPanelControllerBase.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/QSPanelControllerBase.java
@@ -48,7 +48,6 @@
implements Dumpable{
protected final QSTileHost mHost;
private final QSCustomizerController mQsCustomizerController;
- private final QSTileRevealController.Factory mQsTileRevealControllerFactory;
private final MediaHost mMediaHost;
private final MetricsLogger mMetricsLogger;
private final UiEventLogger mUiEventLogger;
@@ -74,14 +73,12 @@
};
protected QSPanelControllerBase(T view, QSTileHost host,
- QSCustomizerController qsCustomizerController,
- QSTileRevealController.Factory qsTileRevealControllerFactory,
+ QSCustomizerController qsCustomizerController, MediaHost mediaHost,
MetricsLogger metricsLogger, UiEventLogger uiEventLogger, DumpManager dumpManager) {
super(view);
mHost = host;
mQsCustomizerController = qsCustomizerController;
- mQsTileRevealControllerFactory = qsTileRevealControllerFactory;
- mMediaHost = mView.getMediaHost();
+ mMediaHost = mediaHost;
mMetricsLogger = metricsLogger;
mUiEventLogger = uiEventLogger;
mDumpManager = dumpManager;
@@ -89,10 +86,8 @@
@Override
protected void onViewAttached() {
- QSPanel.QSTileLayout regularTileLayout = mView.createRegularTileLayout();
- if (regularTileLayout instanceof PagedTileLayout) {
- mQsTileRevealController = mQsTileRevealControllerFactory.create(
- (PagedTileLayout) regularTileLayout);
+ mQsTileRevealController = createTileRevealController();
+ if (mQsTileRevealController != null) {
mQsTileRevealController.setExpansion(mRevealExpansion);
}
@@ -119,6 +114,10 @@
mDumpManager.unregisterDumpable(mView.getDumpableTag());
}
+ protected QSTileRevealController createTileRevealController() {
+ return null;
+ }
+
/** */
public void setTiles() {
setTiles(mHost.getTiles(), false);
@@ -126,9 +125,11 @@
/** */
public void setTiles(Collection<QSTile> tiles, boolean collapsedView) {
- if (!collapsedView) {
+ // TODO(b/168904199): move this logic into QSPanelController.
+ if (!collapsedView && mQsTileRevealController != null) {
mQsTileRevealController.updateRevealedTiles(tiles);
}
+
for (QSPanelControllerBase.TileRecord record : mRecords) {
mView.removeTile(record);
record.tile.removeCallback(record.callback);
@@ -192,7 +193,6 @@
.collect(Collectors.joining(","));
}
-
/** */
public void setExpanded(boolean expanded) {
mView.setExpanded(expanded);
@@ -234,7 +234,6 @@
boolean switchTileLayout(boolean force) {
if (mView.switchTileLayout(force, mRecords)) {
setTiles();
- mView.reSetLayoutListening();
return true;
}
return false;
diff --git a/packages/SystemUI/src/com/android/systemui/qs/QSSecurityFooter.java b/packages/SystemUI/src/com/android/systemui/qs/QSSecurityFooter.java
index 270fcbf..4789239 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/QSSecurityFooter.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/QSSecurityFooter.java
@@ -15,6 +15,8 @@
*/
package com.android.systemui.qs;
+import static com.android.systemui.qs.dagger.QSFragmentModule.QS_SECURITY_FOOTER_VIEW;
+
import android.app.AlertDialog;
import android.app.admin.DeviceAdminInfo;
import android.app.admin.DevicePolicyEventLogger;
@@ -44,9 +46,10 @@
import androidx.annotation.VisibleForTesting;
import com.android.internal.util.FrameworkStatsLog;
-import com.android.systemui.Dependency;
import com.android.systemui.FontSizeUtils;
import com.android.systemui.R;
+import com.android.systemui.dagger.qualifiers.Background;
+import com.android.systemui.dagger.qualifiers.Main;
import com.android.systemui.plugins.ActivityStarter;
import com.android.systemui.qs.dagger.QSScope;
import com.android.systemui.settings.UserTracker;
@@ -54,6 +57,7 @@
import com.android.systemui.statusbar.policy.SecurityController;
import javax.inject.Inject;
+import javax.inject.Named;
@QSScope
class QSSecurityFooter implements OnClickListener, DialogInterface.OnClickListener {
@@ -81,18 +85,19 @@
private int mFooterIconId;
@Inject
- public QSSecurityFooter(QSPanel qsPanel, Context context, UserTracker userTracker) {
- mRootView = LayoutInflater.from(context)
- .inflate(R.layout.quick_settings_footer, qsPanel, false);
+ QSSecurityFooter(@Named(QS_SECURITY_FOOTER_VIEW) View rootView, Context context,
+ UserTracker userTracker, @Main Handler mainHandler, ActivityStarter activityStarter,
+ SecurityController securityController, @Background Looper bgLooper) {
+ mRootView = rootView;
mRootView.setOnClickListener(this);
mFooterText = mRootView.findViewById(R.id.footer_text);
mFooterIcon = mRootView.findViewById(R.id.footer_icon);
mFooterIconId = R.drawable.ic_info_outline;
mContext = context;
- mMainHandler = new Handler(Looper.myLooper());
- mActivityStarter = Dependency.get(ActivityStarter.class);
- mSecurityController = Dependency.get(SecurityController.class);
- mHandler = new H(Dependency.get(Dependency.BG_LOOPER));
+ mMainHandler = mainHandler;
+ mActivityStarter = activityStarter;
+ mSecurityController = securityController;
+ mHandler = new H(bgLooper);
mUserTracker = userTracker;
}
diff --git a/packages/SystemUI/src/com/android/systemui/qs/QSTileRevealController.java b/packages/SystemUI/src/com/android/systemui/qs/QSTileRevealController.java
index 9414d0e..3f93108 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/QSTileRevealController.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/QSTileRevealController.java
@@ -22,7 +22,7 @@
private static final long QS_REVEAL_TILES_DELAY = 500L;
private final Context mContext;
- private final QSPanel mQSPanel;
+ private final QSPanelController mQSPanelController;
private final PagedTileLayout mPagedTileLayout;
private final QSCustomizerController mQsCustomizerController;
private final ArraySet<String> mTilesToReveal = new ArraySet<>();
@@ -32,17 +32,17 @@
@Override
public void run() {
mPagedTileLayout.startTileReveal(mTilesToReveal, () -> {
- if (mQSPanel.isExpanded()) {
+ if (mQSPanelController.isExpanded()) {
addTileSpecsToRevealed(mTilesToReveal);
mTilesToReveal.clear();
}
});
}
};
- QSTileRevealController(Context context, QSPanel qsPanel, PagedTileLayout pagedTileLayout,
- QSCustomizerController qsCustomizerController) {
+ QSTileRevealController(Context context, QSPanelController qsPanelController,
+ PagedTileLayout pagedTileLayout, QSCustomizerController qsCustomizerController) {
mContext = context;
- mQSPanel = qsPanel;
+ mQSPanelController = qsPanelController;
mPagedTileLayout = pagedTileLayout;
mQsCustomizerController = qsCustomizerController;
}
@@ -85,18 +85,17 @@
@QSScope
static class Factory {
private final Context mContext;
- private final QSPanel mQsPanel;
private final QSCustomizerController mQsCustomizerController;
@Inject
- Factory(Context context, QSPanel qsPanel, QSCustomizerController qsCustomizerController) {
+ Factory(Context context, QSCustomizerController qsCustomizerController) {
mContext = context;
- mQsPanel = qsPanel;
mQsCustomizerController = qsCustomizerController;
}
- QSTileRevealController create(PagedTileLayout pagedTileLayout) {
- return new QSTileRevealController(mContext, mQsPanel, pagedTileLayout,
+ QSTileRevealController create(QSPanelController qsPanelController,
+ PagedTileLayout pagedTileLayout) {
+ return new QSTileRevealController(mContext, qsPanelController, pagedTileLayout,
mQsCustomizerController);
}
}
diff --git a/packages/SystemUI/src/com/android/systemui/qs/QuickQSPanel.java b/packages/SystemUI/src/com/android/systemui/qs/QuickQSPanel.java
index dde9a1f..06e8634 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/QuickQSPanel.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/QuickQSPanel.java
@@ -47,11 +47,10 @@
public static final String NUM_QUICK_TILES = "sysui_qqs_count";
private static final String TAG = "QuickQSPanel";
// A default value so that we never return 0.
- private static int sDefaultMaxTiles = 6;
+ public static final int DEFAULT_MAX_TILES = 6;
private boolean mDisabledByPolicy;
private int mMaxTiles;
- protected QSPanel mFullPanel;
@Inject
@@ -62,8 +61,8 @@
@Named(QUICK_QS_PANEL) MediaHost mediaHost,
UiEventLogger uiEventLogger) {
super(context, attrs, qsLogger, mediaHost, uiEventLogger);
- sDefaultMaxTiles = getResources().getInteger(R.integer.quick_qs_panel_max_columns);
- mMaxTiles = sDefaultMaxTiles;
+ mMaxTiles = Math.min(DEFAULT_MAX_TILES,
+ getResources().getInteger(R.integer.quick_qs_panel_max_columns));
applyBottomMargin((View) mRegularTileLayout);
}
@@ -118,10 +117,6 @@
return TAG;
}
- public void setQSPanelAndHeader(QSPanel fullPanel, View header) {
- mFullPanel = fullPanel;
- }
-
@Override
protected boolean shouldShowDetail() {
return !mExpanded;
@@ -141,7 +136,7 @@
}
public void setMaxTiles(int maxTiles) {
- mMaxTiles = maxTiles;
+ mMaxTiles = Math.min(maxTiles, DEFAULT_MAX_TILES);
}
@Override
@@ -167,7 +162,7 @@
return Integer.parseInt(numTilesValue);
} catch (NumberFormatException e) {
// Couldn't read an int from the new setting value. Use default.
- return sDefaultMaxTiles;
+ return DEFAULT_MAX_TILES;
}
}
diff --git a/packages/SystemUI/src/com/android/systemui/qs/QuickQSPanelController.java b/packages/SystemUI/src/com/android/systemui/qs/QuickQSPanelController.java
index fa6289f..7f50eef 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/QuickQSPanelController.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/QuickQSPanelController.java
@@ -16,52 +16,57 @@
package com.android.systemui.qs;
-import static com.android.systemui.qs.QuickQSPanel.NUM_QUICK_TILES;
-import static com.android.systemui.qs.QuickQSPanel.parseNumTiles;
+import static com.android.systemui.media.dagger.MediaModule.QUICK_QS_PANEL;
import com.android.internal.logging.MetricsLogger;
import com.android.internal.logging.UiEventLogger;
+import com.android.systemui.R;
import com.android.systemui.dump.DumpManager;
+import com.android.systemui.media.MediaHost;
import com.android.systemui.plugins.qs.QSTile;
import com.android.systemui.qs.customize.QSCustomizerController;
import com.android.systemui.qs.dagger.QSScope;
-import com.android.systemui.tuner.TunerService;
-import com.android.systemui.tuner.TunerService.Tunable;
import java.util.ArrayList;
+import java.util.List;
import javax.inject.Inject;
+import javax.inject.Named;
/** Controller for {@link QuickQSPanel}. */
@QSScope
public class QuickQSPanelController extends QSPanelControllerBase<QuickQSPanel> {
- private final Tunable mNumTiles =
- (key, newValue) -> setMaxTiles(parseNumTiles(newValue));
- private final TunerService mTunerService;
+ private List<QSTile> mAllTiles = new ArrayList<>();
+
+ private final QSPanel.OnConfigurationChangedListener mOnConfigurationChangedListener =
+ newConfig -> {
+ int newMaxTiles = getResources().getInteger(R.integer.quick_qs_panel_max_columns);
+ if (newMaxTiles != mView.getNumQuickTiles()) {
+ setMaxTiles(newMaxTiles);
+ }
+ };
@Inject
- QuickQSPanelController(QuickQSPanel view, TunerService tunerService, QSTileHost qsTileHost,
+ QuickQSPanelController(QuickQSPanel view, QSTileHost qsTileHost,
QSCustomizerController qsCustomizerController,
- QSTileRevealController.Factory qsTileRevealControllerFactory,
+ @Named(QUICK_QS_PANEL) MediaHost mediaHost,
MetricsLogger metricsLogger, UiEventLogger uiEventLogger,
DumpManager dumpManager) {
- super(view, qsTileHost, qsCustomizerController, qsTileRevealControllerFactory,
- metricsLogger, uiEventLogger, dumpManager);
- mTunerService = tunerService;
+ super(view, qsTileHost, qsCustomizerController, mediaHost, metricsLogger, uiEventLogger,
+ dumpManager);
}
@Override
protected void onViewAttached() {
super.onViewAttached();
- mTunerService.addTunable(mNumTiles, NUM_QUICK_TILES);
-
+ mView.addOnConfigurationChangedListener(mOnConfigurationChangedListener);
}
@Override
protected void onViewDetached() {
super.onViewDetached();
- mTunerService.removeTunable(mNumTiles);
+ mView.removeOnConfigurationChangedListener(mOnConfigurationChangedListener);
}
public boolean isListening() {
@@ -75,14 +80,14 @@
@Override
public void setTiles() {
- ArrayList<QSTile> quickTiles = new ArrayList<>();
+ mAllTiles.clear();
for (QSTile tile : mHost.getTiles()) {
- quickTiles.add(tile);
- if (quickTiles.size() == mView.getNumQuickTiles()) {
+ mAllTiles.add(tile);
+ if (mAllTiles.size() == QuickQSPanel.DEFAULT_MAX_TILES) {
break;
}
}
- super.setTiles(quickTiles, true);
+ super.setTiles(mAllTiles.subList(0, mView.getNumQuickTiles()), true);
}
public int getNumQuickTiles() {
diff --git a/packages/SystemUI/src/com/android/systemui/qs/QuickStatusBarHeader.java b/packages/SystemUI/src/com/android/systemui/qs/QuickStatusBarHeader.java
index 5757602..e2748fc 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/QuickStatusBarHeader.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/QuickStatusBarHeader.java
@@ -153,6 +153,12 @@
mBatteryRemainingIcon.setPercentShowMode(BatteryMeterView.MODE_ESTIMATE);
mRingerModeTextView.setSelected(true);
mNextAlarmTextView.setSelected(true);
+
+ int colorForeground = Utils.getColorAttrDefaultColor(getContext(),
+ android.R.attr.colorForeground);
+ float intensity = getColorIntensity(colorForeground);
+ int fillColor = mDualToneHandler.getSingleColor(intensity);
+ mBatteryRemainingIcon.onDarkChanged(tintArea, intensity, fillColor);
}
void onAttach(TintedIconManager iconManager) {
@@ -439,18 +445,6 @@
post(() -> setClickable(!mExpanded));
}
- public void setQSPanel(final QSPanel qsPanel) {
- //host.setHeaderView(mExpandIndicator);
- mHeaderQsPanel.setQSPanelAndHeader(qsPanel, this);
-
- Rect tintArea = new Rect(0, 0, 0, 0);
- int colorForeground = Utils.getColorAttrDefaultColor(getContext(),
- android.R.attr.colorForeground);
- float intensity = getColorIntensity(colorForeground);
- int fillColor = mDualToneHandler.getSingleColor(intensity);
- mBatteryRemainingIcon.onDarkChanged(tintArea, intensity, fillColor);
- }
-
public void setCallback(Callback qsPanelCallback) {
mHeaderQsPanel.setCallback(qsPanelCallback);
}
@@ -475,6 +469,7 @@
return mLifecycle;
}
+ /** */
public void setContentMargins(int marginStart, int marginEnd) {
mContentMarginStart = marginStart;
mContentMarginEnd = marginEnd;
diff --git a/packages/SystemUI/src/com/android/systemui/qs/QuickStatusBarHeaderController.java b/packages/SystemUI/src/com/android/systemui/qs/QuickStatusBarHeaderController.java
index 32904a2..cb744f7 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/QuickStatusBarHeaderController.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/QuickStatusBarHeaderController.java
@@ -366,7 +366,6 @@
mZenModeController.getConsolidatedPolicy());
}
-
private static class ClockDemoModeReceiver implements DemoMode {
private Clock mClockView;
diff --git a/packages/SystemUI/src/com/android/systemui/qs/customize/QSCustomizerController.java b/packages/SystemUI/src/com/android/systemui/qs/customize/QSCustomizerController.java
index 9f4c58b..7ba51e5 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/customize/QSCustomizerController.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/customize/QSCustomizerController.java
@@ -125,7 +125,7 @@
RecyclerView recyclerView = mView.getRecyclerView();
recyclerView.setAdapter(mTileAdapter);
mTileAdapter.getItemTouchHelper().attachToRecyclerView(recyclerView);
- GridLayoutManager layout = new GridLayoutManager(getContext(), 3) {
+ GridLayoutManager layout = new GridLayoutManager(getContext(), TileAdapter.NUM_COLUMNS) {
@Override
public void onInitializeAccessibilityNodeInfoForItem(RecyclerView.Recycler recycler,
RecyclerView.State state, View host, AccessibilityNodeInfoCompat info) {
diff --git a/packages/SystemUI/src/com/android/systemui/qs/customize/TileAdapter.java b/packages/SystemUI/src/com/android/systemui/qs/customize/TileAdapter.java
index dfc771b..036fa86 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/customize/TileAdapter.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/customize/TileAdapter.java
@@ -61,6 +61,7 @@
private static final long DRAG_LENGTH = 100;
private static final float DRAG_SCALE = 1.2f;
public static final long MOVE_DURATION = 150;
+ public static final int NUM_COLUMNS = 4;
private static final int TYPE_TILE = 0;
private static final int TYPE_EDIT = 1;
@@ -600,7 +601,11 @@
@Override
public int getSpanSize(int position) {
final int type = getItemViewType(position);
- return type == TYPE_EDIT || type == TYPE_DIVIDER || type == TYPE_HEADER ? 3 : 1;
+ if (type == TYPE_EDIT || type == TYPE_DIVIDER || type == TYPE_HEADER) {
+ return NUM_COLUMNS;
+ } else {
+ return 1;
+ }
}
};
diff --git a/packages/SystemUI/src/com/android/systemui/qs/dagger/QSFragmentModule.java b/packages/SystemUI/src/com/android/systemui/qs/dagger/QSFragmentModule.java
index 354b2c9..f3bf306 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/dagger/QSFragmentModule.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/dagger/QSFragmentModule.java
@@ -16,6 +16,7 @@
package com.android.systemui.qs.dagger;
+import android.view.LayoutInflater;
import android.view.View;
import com.android.systemui.R;
@@ -31,6 +32,8 @@
import com.android.systemui.qs.QuickStatusBarHeader;
import com.android.systemui.qs.customize.QSCustomizer;
+import javax.inject.Named;
+
import dagger.Binds;
import dagger.Module;
import dagger.Provides;
@@ -40,6 +43,8 @@
*/
@Module
public interface QSFragmentModule {
+ String QS_SECURITY_FOOTER_VIEW = "qs_security_footer";
+
/** */
@Provides
@RootView
@@ -95,4 +100,12 @@
static QSCustomizer providesQSCutomizer(@RootView View view) {
return view.findViewById(R.id.qs_customize);
}
-}
+
+ /** */
+ @Provides
+ @QSScope
+ @Named(QS_SECURITY_FOOTER_VIEW)
+ static View providesQSSecurityFooterView(LayoutInflater layoutInflater, QSPanel qsPanel) {
+ return layoutInflater.inflate(R.layout.quick_settings_footer, qsPanel, false);
+ }
+}
\ No newline at end of file
diff --git a/packages/SystemUI/src/com/android/systemui/qs/tiles/ColorInversionTile.java b/packages/SystemUI/src/com/android/systemui/qs/tiles/ColorInversionTile.java
index 3995248..a6d9604 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/tiles/ColorInversionTile.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/tiles/ColorInversionTile.java
@@ -70,7 +70,7 @@
super(host, backgroundLooper, mainHandler, metricsLogger, statusBarStateController,
activityStarter, qsLogger);
- mSetting = new SecureSetting(secureSettings, mainHandler,
+ mSetting = new SecureSetting(secureSettings, mHandler,
Secure.ACCESSIBILITY_DISPLAY_INVERSION_ENABLED, userTracker.getUserId()) {
@Override
protected void handleValueChanged(int value, boolean observedChange) {
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/NotificationListener.java b/packages/SystemUI/src/com/android/systemui/statusbar/NotificationListener.java
index f9d2d31..7f31fdd 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/NotificationListener.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/NotificationListener.java
@@ -22,6 +22,7 @@
import android.annotation.NonNull;
import android.annotation.SuppressLint;
+import android.app.NotificationChannel;
import android.app.NotificationManager;
import android.content.ComponentName;
import android.content.Context;
@@ -159,6 +160,19 @@
}
@Override
+ public void onNotificationChannelModified(
+ String pkgName, UserHandle user, NotificationChannel channel, int modificationType) {
+ if (DEBUG) Log.d(TAG, "onNotificationChannelModified");
+ if (!onPluginNotificationChannelModified(pkgName, user, channel, modificationType)) {
+ mMainHandler.post(() -> {
+ for (NotificationHandler handler : mNotificationHandlers) {
+ handler.onNotificationChannelModified(pkgName, user, channel, modificationType);
+ }
+ });
+ }
+ }
+
+ @Override
public void onSilentStatusBarIconsVisibilityChanged(boolean hideSilentStatusIcons) {
for (NotificationSettingsListener listener : mSettingsListeners) {
listener.onStatusBarIconsBehaviorChanged(hideSilentStatusIcons);
@@ -229,6 +243,14 @@
void onNotificationRemoved(StatusBarNotification sbn, RankingMap rankingMap, int reason);
void onNotificationRankingUpdate(RankingMap rankingMap);
+ /** Called after a notification channel is modified. */
+ default void onNotificationChannelModified(
+ String pkgName,
+ UserHandle user,
+ NotificationChannel channel,
+ int modificationType) {
+ }
+
/**
* Called after the listener has connected to NoMan and posted any current notifications.
*/
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/notification/collection/coalescer/GroupCoalescer.java b/packages/SystemUI/src/com/android/systemui/statusbar/notification/collection/coalescer/GroupCoalescer.java
index 1710daa..09ae7eb 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/notification/collection/coalescer/GroupCoalescer.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/notification/collection/coalescer/GroupCoalescer.java
@@ -19,6 +19,8 @@
import static java.util.Objects.requireNonNull;
import android.annotation.MainThread;
+import android.app.NotificationChannel;
+import android.os.UserHandle;
import android.service.notification.NotificationListenerService.Ranking;
import android.service.notification.NotificationListenerService.RankingMap;
import android.service.notification.StatusBarNotification;
@@ -158,6 +160,15 @@
public void onNotificationsInitialized() {
mHandler.onNotificationsInitialized();
}
+
+ @Override
+ public void onNotificationChannelModified(
+ String pkgName,
+ UserHandle user,
+ NotificationChannel channel,
+ int modificationType) {
+ mHandler.onNotificationChannelModified(pkgName, user, channel, modificationType);
+ }
};
private void maybeEmitBatch(StatusBarNotification sbn) {
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/notification/stack/NotificationStackScrollLayoutController.java b/packages/SystemUI/src/com/android/systemui/statusbar/notification/stack/NotificationStackScrollLayoutController.java
index 7698133..7cee365 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/notification/stack/NotificationStackScrollLayoutController.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/notification/stack/NotificationStackScrollLayoutController.java
@@ -48,6 +48,7 @@
import android.widget.FrameLayout;
import com.android.internal.annotations.VisibleForTesting;
+import com.android.internal.colorextraction.ColorExtractor;
import com.android.internal.jank.InteractionJankMonitor;
import com.android.internal.logging.MetricsLogger;
import com.android.internal.logging.UiEvent;
@@ -177,6 +178,8 @@
private final NotificationListContainerImpl mNotificationListContainer =
new NotificationListContainerImpl();
+ private ColorExtractor.OnColorsChangedListener mOnColorsChangedListener;
+
@VisibleForTesting
final View.OnAttachStateChangeListener mOnAttachStateChangeListener =
new View.OnAttachStateChangeListener() {
@@ -703,10 +706,11 @@
Settings.Secure.NOTIFICATION_DISMISS_RTL,
Settings.Secure.NOTIFICATION_HISTORY_ENABLED);
- mColorExtractor.addOnColorsChangedListener((colorExtractor, which) -> {
+ mOnColorsChangedListener = (colorExtractor, which) -> {
final boolean useDarkText = mColorExtractor.getNeutralColors().supportsDarkText();
mView.updateDecorViews(useDarkText);
- });
+ };
+ mColorExtractor.addOnColorsChangedListener(mOnColorsChangedListener);
mKeyguardMediaController.setVisibilityChangedListener(visible -> {
mView.setKeyguardMediaControllorVisible(visible);
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/KeyguardBouncer.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/KeyguardBouncer.java
index 2767b7e..80cb289 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/KeyguardBouncer.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/KeyguardBouncer.java
@@ -39,7 +39,6 @@
import com.android.keyguard.ViewMediatorCallback;
import com.android.keyguard.dagger.KeyguardBouncerComponent;
import com.android.systemui.DejankUtils;
-import com.android.systemui.biometrics.AuthController;
import com.android.systemui.dagger.qualifiers.RootView;
import com.android.systemui.keyguard.DismissCallbackRegistry;
import com.android.systemui.plugins.FalsingManager;
@@ -70,7 +69,6 @@
private final DismissCallbackRegistry mDismissCallbackRegistry;
private final Handler mHandler;
private final List<BouncerExpansionCallback> mExpansionCallbacks = new ArrayList<>();
- private final AuthController mAuthController;
private final KeyguardUpdateMonitor mKeyguardUpdateMonitor;
private final KeyguardStateController mKeyguardStateController;
private final KeyguardSecurityModel mKeyguardSecurityModel;
@@ -104,7 +102,6 @@
ViewGroup container,
DismissCallbackRegistry dismissCallbackRegistry, FalsingManager falsingManager,
BouncerExpansionCallback expansionCallback,
- AuthController authController,
KeyguardStateController keyguardStateController,
KeyguardUpdateMonitor keyguardUpdateMonitor,
KeyguardBypassController keyguardBypassController, Handler handler,
@@ -123,8 +120,6 @@
mKeyguardUpdateMonitor.registerCallback(mUpdateMonitorCallback);
mKeyguardBypassController = keyguardBypassController;
mExpansionCallbacks.add(expansionCallback);
- mExpansionCallbacks.add(authController);
- mAuthController = authController;
}
public void show(boolean resetSecuritySelection) {
@@ -297,11 +292,6 @@
mIsScrimmed = false;
mFalsingManager.onBouncerHidden();
mCallback.onBouncerVisiblityChanged(false /* shown */);
- // TODO(b/165257355): `mAuthController.onFullyHidden` should be `dispatchFullyHidden()`
- // But, it is causing the UDFPS icon to disappear after SystemUI restarts. I guess the
- // ExpansionCallback from StatusBarKeyguardViewManager can't handle the call to
- // onFullyHidden after a restart.
- mAuthController.onFullyHidden();
cancelShowRunnable();
if (mKeyguardViewController != null) {
mKeyguardViewController.cancelDismissAction();
@@ -552,7 +542,6 @@
private final ViewMediatorCallback mCallback;
private final DismissCallbackRegistry mDismissCallbackRegistry;
private final FalsingManager mFalsingManager;
- private final AuthController mAuthController;
private final KeyguardStateController mKeyguardStateController;
private final KeyguardUpdateMonitor mKeyguardUpdateMonitor;
private final KeyguardBypassController mKeyguardBypassController;
@@ -563,7 +552,6 @@
@Inject
public Factory(Context context, ViewMediatorCallback callback,
DismissCallbackRegistry dismissCallbackRegistry, FalsingManager falsingManager,
- AuthController authController,
KeyguardStateController keyguardStateController,
KeyguardUpdateMonitor keyguardUpdateMonitor,
KeyguardBypassController keyguardBypassController, Handler handler,
@@ -573,7 +561,6 @@
mCallback = callback;
mDismissCallbackRegistry = dismissCallbackRegistry;
mFalsingManager = falsingManager;
- mAuthController = authController;
mKeyguardStateController = keyguardStateController;
mKeyguardUpdateMonitor = keyguardUpdateMonitor;
mKeyguardBypassController = keyguardBypassController;
@@ -586,7 +573,7 @@
BouncerExpansionCallback expansionCallback) {
return new KeyguardBouncer(mContext, mCallback, container,
mDismissCallbackRegistry, mFalsingManager, expansionCallback,
- mAuthController, mKeyguardStateController, mKeyguardUpdateMonitor,
+ mKeyguardStateController, mKeyguardUpdateMonitor,
mKeyguardBypassController, mHandler, mKeyguardSecurityModel,
mKeyguardBouncerComponentFactory);
}
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationListenerWithPlugins.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationListenerWithPlugins.java
index 9e561d1..4651e8446 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationListenerWithPlugins.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationListenerWithPlugins.java
@@ -14,9 +14,11 @@
package com.android.systemui.statusbar.phone;
+import android.app.NotificationChannel;
import android.content.ComponentName;
import android.content.Context;
import android.os.RemoteException;
+import android.os.UserHandle;
import android.service.notification.NotificationListenerService;
import android.service.notification.StatusBarNotification;
@@ -78,7 +80,7 @@
/**
* Called when listener receives a onNotificationPosted.
- * Returns true to indicate this callback should be skipped.
+ * Returns true if there's a plugin determining to skip the default callbacks.
*/
public boolean onPluginNotificationPosted(StatusBarNotification sbn,
final RankingMap rankingMap) {
@@ -92,7 +94,7 @@
/**
* Called when listener receives a onNotificationRemoved.
- * Returns true to indicate this callback should be skipped.
+ * Returns true if there's a plugin determining to skip the default callbacks.
*/
public boolean onPluginNotificationRemoved(StatusBarNotification sbn,
final RankingMap rankingMap) {
@@ -104,6 +106,20 @@
return false;
}
+ /**
+ * Called when listener receives a onNotificationChannelModified.
+ * Returns true if there's a plugin determining to skip the default callbacks.
+ */
+ public boolean onPluginNotificationChannelModified(
+ String pkgName, UserHandle user, NotificationChannel channel, int modificationType) {
+ for (NotificationListenerController plugin : mPlugins) {
+ if (plugin.onNotificationChannelModified(pkgName, user, channel, modificationType)) {
+ return true;
+ }
+ }
+ return false;
+ }
+
public RankingMap onPluginRankingUpdate(RankingMap rankingMap) {
return getCurrentRanking();
}
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBarKeyguardViewManager.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBarKeyguardViewManager.java
index 9e2e57e..f9dfd7a 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBarKeyguardViewManager.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBarKeyguardViewManager.java
@@ -117,6 +117,7 @@
@Override
public void onStartingToShow() {
+ updateStates();
updateLockIcon();
}
@@ -164,6 +165,7 @@
protected boolean mLastShowing;
protected boolean mLastOccluded;
private boolean mLastBouncerShowing;
+ private boolean mLastBouncerIsOrWillBeShowing;
private boolean mLastBouncerDismissible;
protected boolean mLastRemoteInputActive;
private boolean mLastDozing;
@@ -811,6 +813,7 @@
boolean showing = mShowing;
boolean occluded = mOccluded;
boolean bouncerShowing = mBouncer.isShowing();
+ boolean bouncerIsOrWillBeShowing = bouncerIsOrWillBeShowing();
boolean bouncerDismissible = !mBouncer.isFullscreenBouncer();
boolean remoteInputActive = mRemoteInputActive;
@@ -839,8 +842,8 @@
if ((showing && !occluded) != (mLastShowing && !mLastOccluded) || mFirstUpdate) {
mKeyguardUpdateManager.onKeyguardVisibilityChanged(showing && !occluded);
}
- if (bouncerShowing != mLastBouncerShowing || mFirstUpdate) {
- mKeyguardUpdateManager.sendKeyguardBouncerChanged(bouncerShowing);
+ if (bouncerIsOrWillBeShowing != mLastBouncerIsOrWillBeShowing || mFirstUpdate) {
+ mKeyguardUpdateManager.sendKeyguardBouncerChanged(bouncerIsOrWillBeShowing);
}
mFirstUpdate = false;
@@ -848,6 +851,7 @@
mLastGlobalActionsVisible = mGlobalActionsVisible;
mLastOccluded = occluded;
mLastBouncerShowing = bouncerShowing;
+ mLastBouncerIsOrWillBeShowing = bouncerIsOrWillBeShowing;
mLastBouncerDismissible = bouncerDismissible;
mLastRemoteInputActive = remoteInputActive;
mLastDozing = mDozing;
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/policy/RemoteInputView.java b/packages/SystemUI/src/com/android/systemui/statusbar/policy/RemoteInputView.java
index 4552026..79f0915 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/policy/RemoteInputView.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/policy/RemoteInputView.java
@@ -45,7 +45,7 @@
import android.view.KeyEvent;
import android.view.LayoutInflater;
import android.view.MotionEvent;
-import android.view.OnReceiveContentCallback;
+import android.view.OnReceiveContentListener;
import android.view.View;
import android.view.ViewAnimationUtils;
import android.view.ViewGroup;
@@ -74,6 +74,7 @@
import com.android.systemui.statusbar.phone.LightBarController;
import java.util.HashMap;
+import java.util.Map;
import java.util.function.Consumer;
/**
@@ -585,27 +586,32 @@
protected void onFinishInflate() {
super.onFinishInflate();
if (mSupportedMimeTypes != null && mSupportedMimeTypes.length > 0) {
- setOnReceiveContentCallback(mSupportedMimeTypes,
- new OnReceiveContentCallback<View>() {
+ setOnReceiveContentListener(mSupportedMimeTypes,
+ new OnReceiveContentListener() {
@Override
- public boolean onReceiveContent(@NonNull View view,
+ @Nullable
+ public Payload onReceiveContent(@NonNull View view,
@NonNull Payload payload) {
- ClipData clip = payload.getClip();
- if (clip.getItemCount() == 0) {
- return false;
- }
- Uri contentUri = clip.getItemAt(0).getUri();
- ClipDescription description = clip.getDescription();
- String mimeType = null;
- if (description.getMimeTypeCount() > 0) {
- mimeType = description.getMimeType(0);
- }
- if (mimeType != null) {
+ Map<Boolean, Payload> split = payload.partition(
+ item -> item.getUri() != null);
+ Payload uriItems = split.get(true);
+ Payload remainingItems = split.get(false);
+ if (uriItems != null) {
+ ClipData clip = uriItems.getClip();
+ ClipDescription description = clip.getDescription();
+ if (clip.getItemCount() > 1
+ || description.getMimeTypeCount() < 1
+ || remainingItems != null) {
+ // TODO(b/172363500): Update to loop over all the items
+ return payload;
+ }
+ Uri contentUri = clip.getItemAt(0).getUri();
+ String mimeType = description.getMimeType(0);
Intent dataIntent = mRemoteInputView
.prepareRemoteInputFromData(mimeType, contentUri);
mRemoteInputView.sendRemoteInput(dataIntent);
}
- return true;
+ return remainingItems;
}
});
}
diff --git a/packages/SystemUI/src/com/android/systemui/wmshell/TvPipModule.java b/packages/SystemUI/src/com/android/systemui/wmshell/TvPipModule.java
index 694b4a0..86ba5f1f 100644
--- a/packages/SystemUI/src/com/android/systemui/wmshell/TvPipModule.java
+++ b/packages/SystemUI/src/com/android/systemui/wmshell/TvPipModule.java
@@ -24,7 +24,7 @@
import com.android.wm.shell.common.DisplayController;
import com.android.wm.shell.common.TaskStackListenerImpl;
import com.android.wm.shell.pip.Pip;
-import com.android.wm.shell.pip.PipBoundsHandler;
+import com.android.wm.shell.pip.PipBoundsAlgorithm;
import com.android.wm.shell.pip.PipBoundsState;
import com.android.wm.shell.pip.PipMediaController;
import com.android.wm.shell.pip.PipSurfaceTransactionHelper;
@@ -51,7 +51,7 @@
static Optional<Pip> providePip(
Context context,
PipBoundsState pipBoundsState,
- PipBoundsHandler pipBoundsHandler,
+ PipBoundsAlgorithm pipBoundsAlgorithm,
PipTaskOrganizer pipTaskOrganizer,
PipMediaController pipMediaController,
PipNotification pipNotification,
@@ -61,7 +61,7 @@
new PipController(
context,
pipBoundsState,
- pipBoundsHandler,
+ pipBoundsAlgorithm,
pipTaskOrganizer,
pipMediaController,
pipNotification,
@@ -91,9 +91,9 @@
@WMSingleton
@Provides
- static PipBoundsHandler providePipBoundsHandler(Context context,
+ static PipBoundsAlgorithm providePipBoundsHandler(Context context,
PipBoundsState pipBoundsState) {
- return new PipBoundsHandler(context, pipBoundsState);
+ return new PipBoundsAlgorithm(context, pipBoundsState);
}
@WMSingleton
@@ -106,11 +106,11 @@
@Provides
static PipTaskOrganizer providePipTaskOrganizer(Context context,
PipBoundsState pipBoundsState,
- PipBoundsHandler pipBoundsHandler,
+ PipBoundsAlgorithm pipBoundsAlgorithm,
PipSurfaceTransactionHelper pipSurfaceTransactionHelper,
Optional<SplitScreen> splitScreenOptional, DisplayController displayController,
PipUiEventLogger pipUiEventLogger, ShellTaskOrganizer shellTaskOrganizer) {
- return new PipTaskOrganizer(context, pipBoundsState, pipBoundsHandler,
+ return new PipTaskOrganizer(context, pipBoundsState, pipBoundsAlgorithm,
null /* menuActivityController */, pipSurfaceTransactionHelper, splitScreenOptional,
displayController, pipUiEventLogger, shellTaskOrganizer);
}
diff --git a/packages/SystemUI/src/com/android/systemui/wmshell/WMShell.java b/packages/SystemUI/src/com/android/systemui/wmshell/WMShell.java
index 04f1f86..c36acf5 100644
--- a/packages/SystemUI/src/com/android/systemui/wmshell/WMShell.java
+++ b/packages/SystemUI/src/com/android/systemui/wmshell/WMShell.java
@@ -53,6 +53,7 @@
import com.android.systemui.tracing.ProtoTracer;
import com.android.systemui.tracing.nano.SystemUiTraceProto;
import com.android.wm.shell.ShellDump;
+import com.android.wm.shell.apppairs.AppPairs;
import com.android.wm.shell.hidedisplaycutout.HideDisplayCutout;
import com.android.wm.shell.nano.WmShellTraceProto;
import com.android.wm.shell.onehanded.OneHanded;
@@ -98,6 +99,7 @@
private final Optional<HideDisplayCutout> mHideDisplayCutoutOptional;
private final ProtoTracer mProtoTracer;
private final Optional<ShellDump> mShellDump;
+ private final Optional<AppPairs> mAppPairsOptional;
private boolean mIsSysUiStateValid;
private KeyguardUpdateMonitorCallback mSplitScreenKeyguardCallback;
@@ -116,7 +118,8 @@
Optional<OneHanded> oneHandedOptional,
Optional<HideDisplayCutout> hideDisplayCutoutOptional,
ProtoTracer protoTracer,
- Optional<ShellDump> shellDump) {
+ Optional<ShellDump> shellDump,
+ Optional<AppPairs> appPairsOptional) {
super(context);
mCommandQueue = commandQueue;
mConfigurationController = configurationController;
@@ -131,6 +134,7 @@
mProtoTracer = protoTracer;
mProtoTracer.add(this);
mShellDump = shellDump;
+ mAppPairsOptional = appPairsOptional;
}
@Override
@@ -335,6 +339,21 @@
}
return true;
}
+
+ case "pair": {
+ String[] groups = Arrays.copyOfRange(args, i + 1, args.length);
+ final int taskId1 = new Integer(groups[0]);
+ final int taskId2 = new Integer(groups[1]);
+ mAppPairsOptional.ifPresent(appPairs -> appPairs.pair(taskId1, taskId2));
+ return true;
+ }
+
+ case "unpair": {
+ String[] groups = Arrays.copyOfRange(args, i + 1, args.length);
+ final int taskId = new Integer(groups[0]);
+ mAppPairsOptional.ifPresent(appPairs -> appPairs.unpair(taskId));
+ return true;
+ }
}
}
return false;
diff --git a/packages/SystemUI/src/com/android/systemui/wmshell/WMShellBaseModule.java b/packages/SystemUI/src/com/android/systemui/wmshell/WMShellBaseModule.java
index 8c2980f..74aa1a7 100644
--- a/packages/SystemUI/src/com/android/systemui/wmshell/WMShellBaseModule.java
+++ b/packages/SystemUI/src/com/android/systemui/wmshell/WMShellBaseModule.java
@@ -32,6 +32,7 @@
import com.android.wm.shell.ShellInit;
import com.android.wm.shell.ShellTaskOrganizer;
import com.android.wm.shell.WindowManagerShellWrapper;
+import com.android.wm.shell.apppairs.AppPairs;
import com.android.wm.shell.bubbles.BubbleController;
import com.android.wm.shell.bubbles.Bubbles;
import com.android.wm.shell.common.AnimationThread;
@@ -75,11 +76,13 @@
static ShellInit provideShellInit(DisplayImeController displayImeController,
DragAndDropController dragAndDropController,
ShellTaskOrganizer shellTaskOrganizer,
- Optional<SplitScreen> splitScreenOptional) {
+ Optional<SplitScreen> splitScreenOptional,
+ Optional<AppPairs> appPairsOptional) {
return new ShellInit(displayImeController,
dragAndDropController,
shellTaskOrganizer,
- splitScreenOptional);
+ splitScreenOptional,
+ appPairsOptional);
}
/**
@@ -92,9 +95,10 @@
Optional<SplitScreen> splitScreenOptional,
Optional<Pip> pipOptional,
Optional<OneHanded> oneHandedOptional,
- Optional<HideDisplayCutout> hideDisplayCutout) {
+ Optional<HideDisplayCutout> hideDisplayCutout,
+ Optional<AppPairs> appPairsOptional) {
return Optional.of(new ShellDump(shellTaskOrganizer, splitScreenOptional, pipOptional,
- oneHandedOptional, hideDisplayCutout));
+ oneHandedOptional, hideDisplayCutout, appPairsOptional));
}
@WMSingleton
@@ -187,6 +191,9 @@
@BindsOptionalOf
abstract SplitScreen optionalSplitScreen();
+ @BindsOptionalOf
+ abstract AppPairs optionalAppPairs();
+
@WMSingleton
@Provides
static Optional<Bubbles> provideBubbles(Context context,
diff --git a/packages/SystemUI/src/com/android/systemui/wmshell/WMShellModule.java b/packages/SystemUI/src/com/android/systemui/wmshell/WMShellModule.java
index 1cdec27..ef8a08c 100644
--- a/packages/SystemUI/src/com/android/systemui/wmshell/WMShellModule.java
+++ b/packages/SystemUI/src/com/android/systemui/wmshell/WMShellModule.java
@@ -24,6 +24,8 @@
import com.android.systemui.dagger.qualifiers.Main;
import com.android.wm.shell.ShellTaskOrganizer;
import com.android.wm.shell.WindowManagerShellWrapper;
+import com.android.wm.shell.apppairs.AppPairs;
+import com.android.wm.shell.apppairs.AppPairsController;
import com.android.wm.shell.common.DisplayController;
import com.android.wm.shell.common.DisplayImeController;
import com.android.wm.shell.common.FloatingContentCoordinator;
@@ -33,7 +35,7 @@
import com.android.wm.shell.common.TaskStackListenerImpl;
import com.android.wm.shell.common.TransactionPool;
import com.android.wm.shell.pip.Pip;
-import com.android.wm.shell.pip.PipBoundsHandler;
+import com.android.wm.shell.pip.PipBoundsAlgorithm;
import com.android.wm.shell.pip.PipBoundsState;
import com.android.wm.shell.pip.PipMediaController;
import com.android.wm.shell.pip.PipSurfaceTransactionHelper;
@@ -81,14 +83,21 @@
@WMSingleton
@Provides
+ static AppPairs provideAppPairs(ShellTaskOrganizer shellTaskOrganizer,
+ SyncTransactionQueue syncQueue) {
+ return new AppPairsController(shellTaskOrganizer, syncQueue);
+ }
+
+ @WMSingleton
+ @Provides
static Optional<Pip> providePip(Context context, DisplayController displayController,
- PipAppOpsListener pipAppOpsListener, PipBoundsHandler pipBoundsHandler,
+ PipAppOpsListener pipAppOpsListener, PipBoundsAlgorithm pipBoundsAlgorithm,
PipBoundsState pipBoundsState, PipMediaController pipMediaController,
PipMenuActivityController pipMenuActivityController, PipTaskOrganizer pipTaskOrganizer,
PipTouchHandler pipTouchHandler, WindowManagerShellWrapper windowManagerShellWrapper,
TaskStackListenerImpl taskStackListener, ShellExecutor mainExecutor) {
return Optional.ofNullable(PipController.create(context, displayController,
- pipAppOpsListener, pipBoundsHandler, pipBoundsState, pipMediaController,
+ pipAppOpsListener, pipBoundsAlgorithm, pipBoundsState, pipMediaController,
pipMenuActivityController, pipTaskOrganizer, pipTouchHandler,
windowManagerShellWrapper, taskStackListener, mainExecutor));
}
@@ -101,9 +110,9 @@
@WMSingleton
@Provides
- static PipBoundsHandler providesPipBoundsHandler(Context context,
+ static PipBoundsAlgorithm providesPipBoundsHandler(Context context,
PipBoundsState pipBoundsState) {
- return new PipBoundsHandler(context, pipBoundsState);
+ return new PipBoundsAlgorithm(context, pipBoundsState);
}
@WMSingleton
@@ -116,12 +125,12 @@
@WMSingleton
@Provides
static PipTouchHandler providePipTouchHandler(Context context,
- PipMenuActivityController menuActivityController, PipBoundsHandler pipBoundsHandler,
+ PipMenuActivityController menuActivityController, PipBoundsAlgorithm pipBoundsAlgorithm,
PipBoundsState pipBoundsState,
PipTaskOrganizer pipTaskOrganizer,
FloatingContentCoordinator floatingContentCoordinator,
PipUiEventLogger pipUiEventLogger) {
- return new PipTouchHandler(context, menuActivityController, pipBoundsHandler,
+ return new PipTouchHandler(context, menuActivityController, pipBoundsAlgorithm,
pipBoundsState, pipTaskOrganizer, floatingContentCoordinator, pipUiEventLogger);
}
@@ -129,12 +138,12 @@
@Provides
static PipTaskOrganizer providePipTaskOrganizer(Context context,
PipBoundsState pipBoundsState,
- PipBoundsHandler pipBoundsHandler,
+ PipBoundsAlgorithm pipBoundsAlgorithm,
PipMenuActivityController menuActivityController,
PipSurfaceTransactionHelper pipSurfaceTransactionHelper,
Optional<SplitScreen> splitScreenOptional, DisplayController displayController,
PipUiEventLogger pipUiEventLogger, ShellTaskOrganizer shellTaskOrganizer) {
- return new PipTaskOrganizer(context, pipBoundsState, pipBoundsHandler,
+ return new PipTaskOrganizer(context, pipBoundsState, pipBoundsAlgorithm,
menuActivityController, pipSurfaceTransactionHelper, splitScreenOptional,
displayController, pipUiEventLogger, shellTaskOrganizer);
}
diff --git a/packages/SystemUI/tests/src/com/android/keyguard/KeyguardUpdateMonitorTest.java b/packages/SystemUI/tests/src/com/android/keyguard/KeyguardUpdateMonitorTest.java
index d78090a..51cbff8 100644
--- a/packages/SystemUI/tests/src/com/android/keyguard/KeyguardUpdateMonitorTest.java
+++ b/packages/SystemUI/tests/src/com/android/keyguard/KeyguardUpdateMonitorTest.java
@@ -93,6 +93,7 @@
import org.junit.Test;
import org.junit.runner.RunWith;
import org.mockito.ArgumentCaptor;
+import org.mockito.Captor;
import org.mockito.InOrder;
import org.mockito.Mock;
import org.mockito.MockitoAnnotations;
@@ -102,7 +103,6 @@
import java.util.List;
import java.util.concurrent.Executor;
import java.util.concurrent.atomic.AtomicBoolean;
-
@SmallTest
@RunWith(AndroidTestingRunner.class)
@TestableLooper.RunWithLooper
@@ -159,12 +159,15 @@
private StatusBarStateController mStatusBarStateController;
@Mock
private AuthController mAuthController;
+ @Captor
+ private ArgumentCaptor<StatusBarStateController.StateListener> mStatusBarStateListenerCaptor;
// Direct executor
private Executor mBackgroundExecutor = Runnable::run;
private TestableLooper mTestableLooper;
private TestableKeyguardUpdateMonitor mKeyguardUpdateMonitor;
private TestableContext mSpiedContext;
private MockitoSession mMockitoSession;
+ private StatusBarStateController.StateListener mStatusBarStateListener;
@Before
public void setup() {
@@ -221,6 +224,9 @@
mTestableLooper = TestableLooper.get(this);
allowTestableLooperAsMainThread();
mKeyguardUpdateMonitor = new TestableKeyguardUpdateMonitor(mSpiedContext);
+
+ verify(mStatusBarStateController).addCallback(mStatusBarStateListenerCaptor.capture());
+ mStatusBarStateListener = mStatusBarStateListenerCaptor.getValue();
}
@After
@@ -475,8 +481,7 @@
@Test
public void testTriesToAuthenticate_whenBouncer() {
- mKeyguardUpdateMonitor.sendKeyguardBouncerChanged(true);
- mTestableLooper.processAllMessages();
+ setKeyguardBouncerVisibility(true);
verify(mFaceManager).authenticate(any(), any(), any(), any(), anyInt());
verify(mFaceManager).isHardwareDetected();
@@ -493,10 +498,10 @@
@Test
public void skipsAuthentication_whenStatusBarShadeLocked() {
- when(mStatusBarStateController.getState()).thenReturn(StatusBarState.SHADE_LOCKED);
-
+ mStatusBarStateListener.onStateChanged(StatusBarState.SHADE_LOCKED);
mKeyguardUpdateMonitor.dispatchStartedWakingUp();
mTestableLooper.processAllMessages();
+
mKeyguardUpdateMonitor.onKeyguardVisibilityChanged(true);
verify(mFaceManager, never()).authenticate(any(), any(), any(), any(), anyInt());
}
@@ -536,8 +541,7 @@
verify(mFaceManager).authenticate(any(), any(), any(), any(), anyInt());
// Stop scanning when bouncer becomes visible
- mKeyguardUpdateMonitor.sendKeyguardBouncerChanged(true /* showingBouncer */);
- mTestableLooper.processAllMessages();
+ setKeyguardBouncerVisibility(true);
clearInvocations(mFaceManager);
mKeyguardUpdateMonitor.requestFaceAuth();
verify(mFaceManager, never()).authenticate(any(), any(), any(), any(), anyInt());
@@ -768,6 +772,85 @@
orderVerify.verify(callback).onRingerModeChanged(AudioManager.RINGER_MODE_VIBRATE);
}
+ @Test
+ public void testStartUdfpsServiceBeginsOnKeyguard() {
+ // GIVEN
+ // - bouncer isn't showing
+ // - status bar state is on the keyguard
+ // - user has authenticated since boot
+ setKeyguardBouncerVisibility(false /* isVisible */);
+ mStatusBarStateListener.onStateChanged(StatusBarState.KEYGUARD);
+ when(mStrongAuthTracker.hasUserAuthenticatedSinceBoot()).thenReturn(true);
+
+ // THEN we should listen for udfps
+ assertThat(mKeyguardUpdateMonitor.shouldListenForUdfps()).isEqualTo(true);
+ }
+
+ @Test
+ public void testStartUdfpsServiceOnShadeLocked() {
+ // GIVEN
+ // - bouncer isn't showing
+ // - user has authenticated since boot
+ setKeyguardBouncerVisibility(false /* isVisible */);
+ when(mStrongAuthTracker.hasUserAuthenticatedSinceBoot()).thenReturn(true);
+
+ // WHEN the status bar state changes to SHADE_LOCKED
+ mStatusBarStateListener.onStateChanged(StatusBarState.SHADE_LOCKED);
+
+ // THEN we shouldn't listen for udfps
+ assertThat(mKeyguardUpdateMonitor.shouldListenForUdfps()).isEqualTo(false);
+ }
+
+ @Test
+ public void testStartUdfpsServiceOnFullscreenUserSwitcher() {
+ // GIVEN
+ // - bouncer isn't showing
+ // - user has authenticated since boot
+ setKeyguardBouncerVisibility(false /* isVisible */);
+ when(mStrongAuthTracker.hasUserAuthenticatedSinceBoot()).thenReturn(true);
+
+ // WHEN the status bar state changes to FULLSCREEN_USER_SWITCHER
+ mStatusBarStateListener.onStateChanged(StatusBarState.FULLSCREEN_USER_SWITCHER);
+
+ // THEN we shouldn't listen for udfps
+ assertThat(mKeyguardUpdateMonitor.shouldListenForUdfps()).isEqualTo(false);
+ }
+
+ @Test
+ public void testStartUdfpsServiceNoAuthenticationSinceLastBoot() {
+ // GIVEN
+ // - bouncer isn't showing
+ // - status bar state is on the keyguard
+ setKeyguardBouncerVisibility(false /* isVisible */);
+ mStatusBarStateListener.onStateChanged(StatusBarState.KEYGUARD);
+
+ // WHEN user hasn't authenticated since last boot
+ when(mStrongAuthTracker.hasUserAuthenticatedSinceBoot()).thenReturn(false);
+
+ // THEN we shouldn't listen for udfps
+ assertThat(mKeyguardUpdateMonitor.shouldListenForUdfps()).isEqualTo(false);
+ }
+
+ @Test
+ public void testStartUdfpsServiceOnBouncerNotVisible() {
+ // GIVEN
+ // - status bar state is on the keyguard
+ // - user has authenticated since boot
+ mStatusBarStateListener.onStateChanged(StatusBarState.KEYGUARD);
+ when(mStrongAuthTracker.hasUserAuthenticatedSinceBoot()).thenReturn(true);
+
+ // WHEN the bouncer is showing
+ setKeyguardBouncerVisibility(true /* isVisible */);
+
+ // THEN we shouldn't listen for udfps
+ assertThat(mKeyguardUpdateMonitor.shouldListenForUdfps()).isEqualTo(false);
+ }
+
+ private void setKeyguardBouncerVisibility(boolean isVisible) {
+ mKeyguardUpdateMonitor.sendKeyguardBouncerChanged(isVisible);
+ mTestableLooper.processAllMessages();
+ }
+
private void setBroadcastReceiverPendingResult(BroadcastReceiver receiver) {
BroadcastReceiver.PendingResult pendingResult =
new BroadcastReceiver.PendingResult(Activity.RESULT_OK,
diff --git a/packages/SystemUI/tests/src/com/android/systemui/biometrics/AuthControllerTest.java b/packages/SystemUI/tests/src/com/android/systemui/biometrics/AuthControllerTest.java
index 42bb005..ec0aa4c 100644
--- a/packages/SystemUI/tests/src/com/android/systemui/biometrics/AuthControllerTest.java
+++ b/packages/SystemUI/tests/src/com/android/systemui/biometrics/AuthControllerTest.java
@@ -22,7 +22,6 @@
import static junit.framework.Assert.assertNull;
import static org.mockito.ArgumentMatchers.any;
-import static org.mockito.ArgumentMatchers.anyBoolean;
import static org.mockito.ArgumentMatchers.anyInt;
import static org.mockito.ArgumentMatchers.anyString;
import static org.mockito.ArgumentMatchers.eq;
@@ -513,30 +512,6 @@
verify(mUdfpsController).onCancelAodInterrupt();
}
- @Test
- public void testOnFullyShown_DelegatesToUdfpsController() {
- mAuthController.onFullyShown();
- verify(mUdfpsController).setBouncerVisibility(eq(true));
- }
-
- @Test
- public void testOnFullyHidden_DelegatesToUdfpsController() {
- mAuthController.onFullyHidden();
- verify(mUdfpsController).setBouncerVisibility(eq(false));
- }
-
- @Test
- public void testOnStartingToShow_NeverDelegatesToUdfpsController() {
- mAuthController.onStartingToShow();
- verify(mUdfpsController).setBouncerVisibility(eq(true));
- }
-
- @Test
- public void testOnStartingToHide_NeverDelegatesToUdfpsController() {
- mAuthController.onStartingToHide();
- verify(mUdfpsController, never()).setBouncerVisibility(anyBoolean());
- }
-
// Helpers
private void showDialog(int[] sensorIds, boolean credentialAllowed) {
diff --git a/packages/SystemUI/tests/src/com/android/systemui/biometrics/UdfpsControllerTest.java b/packages/SystemUI/tests/src/com/android/systemui/biometrics/UdfpsControllerTest.java
index 82ffd46..648c319 100644
--- a/packages/SystemUI/tests/src/com/android/systemui/biometrics/UdfpsControllerTest.java
+++ b/packages/SystemUI/tests/src/com/android/systemui/biometrics/UdfpsControllerTest.java
@@ -21,7 +21,6 @@
import static org.mockito.ArgumentMatchers.any;
import static org.mockito.ArgumentMatchers.anyFloat;
import static org.mockito.ArgumentMatchers.eq;
-import static org.mockito.Mockito.never;
import static org.mockito.Mockito.verify;
import static org.mockito.Mockito.when;
@@ -90,6 +89,7 @@
private WindowManager mWindowManager;
@Mock
private StatusBarStateController mStatusBarStateController;
+
private FakeSettings mSystemSettings;
private FakeExecutor mFgExecutor;
@@ -173,41 +173,6 @@
}
@Test
- public void showUdfpsOverlay_bouncerShowing() throws RemoteException {
- // GIVEN that the bouncer is showing
- mUdfpsController.setBouncerVisibility(/* isShowing */ true);
- // WHEN a request to show the overlay is received
- mOverlayController.showUdfpsOverlay(TEST_UDFPS_SENSOR_ID);
- mFgExecutor.runAllReady();
- // THEN the overlay is not attached
- verify(mWindowManager, never()).addView(eq(mUdfpsView), any());
- }
-
- @Test
- public void setBouncerVisibility_overlayDetached() throws RemoteException {
- // GIVEN that the overlay has been requested
- mOverlayController.showUdfpsOverlay(TEST_UDFPS_SENSOR_ID);
- // WHEN the bouncer becomes visible
- mUdfpsController.setBouncerVisibility(/* isShowing */ true);
- mFgExecutor.runAllReady();
- // THEN the overlay is detached
- verify(mWindowManager).removeView(eq(mUdfpsView));
- }
-
- @Test
- public void setBouncerVisibility_overlayAttached() throws RemoteException {
- // GIVEN that the bouncer is visible
- mUdfpsController.setBouncerVisibility(/* isShowing */ true);
- // AND the overlay has been requested
- mOverlayController.showUdfpsOverlay(TEST_UDFPS_SENSOR_ID);
- // WHEN the bouncer is closed
- mUdfpsController.setBouncerVisibility(/* isShowing */ false);
- mFgExecutor.runAllReady();
- // THEN the overlay is attached
- verify(mWindowManager).addView(eq(mUdfpsView), any());
- }
-
- @Test
public void fingerDown() throws RemoteException {
// Configure UdfpsView to accept the ACTION_DOWN event
when(mUdfpsView.isScrimShowing()).thenReturn(false);
diff --git a/packages/SystemUI/tests/src/com/android/systemui/people/widget/PeopleSpaceWidgetManagerTest.java b/packages/SystemUI/tests/src/com/android/systemui/people/widget/PeopleSpaceWidgetManagerTest.java
index 8ceebeb..3e44fa4 100644
--- a/packages/SystemUI/tests/src/com/android/systemui/people/widget/PeopleSpaceWidgetManagerTest.java
+++ b/packages/SystemUI/tests/src/com/android/systemui/people/widget/PeopleSpaceWidgetManagerTest.java
@@ -16,6 +16,8 @@
package com.android.systemui.people.widget;
+import static android.app.NotificationManager.IMPORTANCE_HIGH;
+
import static org.mockito.ArgumentMatchers.any;
import static org.mockito.ArgumentMatchers.anyInt;
import static org.mockito.ArgumentMatchers.eq;
@@ -26,8 +28,10 @@
import static java.util.Objects.requireNonNull;
+import android.app.NotificationChannel;
import android.content.Context;
import android.os.RemoteException;
+import android.os.UserHandle;
import android.testing.AndroidTestingRunner;
import androidx.test.filters.SmallTest;
@@ -56,6 +60,10 @@
private static final String TEST_PACKAGE_A = "com.test.package_a";
private static final String TEST_PACKAGE_B = "com.test.package_b";
+ private static final String TEST_CHANNEL_ID = "channel_id";
+ private static final String TEST_CHANNEL_NAME = "channel_name";
+ private static final String TEST_PARENT_CHANNEL_ID = "parent_channel_id";
+ private static final String TEST_CONVERSATION_ID = "conversation_id";
private PeopleSpaceWidgetManager mManager;
@@ -100,7 +108,7 @@
}
@Test
- public void testNotifyAppWidgetIfWidgets() throws RemoteException {
+ public void testNotifyAppWidgetIfNotificationPosted() throws RemoteException {
int[] widgetIdsArray = {1};
when(mIAppWidgetService.getAppWidgetIds(any())).thenReturn(widgetIdsArray);
@@ -117,7 +125,7 @@
}
@Test
- public void testNotifyAppWidgetTwiceIfTwoNotifications() throws RemoteException {
+ public void testNotifyAppWidgetTwiceIfTwoNotificationsPosted() throws RemoteException {
int[] widgetIdsArray = {1, 2};
when(mIAppWidgetService.getAppWidgetIds(any())).thenReturn(widgetIdsArray);
@@ -149,4 +157,40 @@
verify(mIAppWidgetService, times(2))
.notifyAppWidgetViewDataChanged(any(), eq(widgetIdsArray), anyInt());
}
+
+ @Test
+ public void testDoNotNotifyAppWidgetIfNonConversationChannelModified() throws RemoteException {
+ int[] widgetIdsArray = {1};
+ when(mIAppWidgetService.getAppWidgetIds(any())).thenReturn(widgetIdsArray);
+
+ NotificationChannel channel =
+ mNoMan.createNotificationChannel(TEST_CHANNEL_ID, TEST_CHANNEL_NAME);
+
+ mNoMan.issueChannelModification(TEST_PACKAGE_A,
+ UserHandle.getUserHandleForUid(0), channel, IMPORTANCE_HIGH);
+ mClock.advanceTime(MIN_LINGER_DURATION);
+
+ verify(mIAppWidgetService, never()).getAppWidgetIds(any());
+ verify(mIAppWidgetService, never()).notifyAppWidgetViewDataChanged(any(), any(), anyInt());
+
+ }
+
+ @Test
+ public void testNotifyAppWidgetIfConversationChannelModified() throws RemoteException {
+ int[] widgetIdsArray = {1};
+ when(mIAppWidgetService.getAppWidgetIds(any())).thenReturn(widgetIdsArray);
+
+ NotificationChannel channel =
+ mNoMan.createNotificationChannel(TEST_CHANNEL_ID, TEST_CHANNEL_NAME);
+ channel.setConversationId(TEST_PARENT_CHANNEL_ID, TEST_CONVERSATION_ID);
+
+ mNoMan.issueChannelModification(TEST_PACKAGE_A,
+ UserHandle.getUserHandleForUid(0), channel, IMPORTANCE_HIGH);
+ mClock.advanceTime(MIN_LINGER_DURATION);
+
+ verify(mIAppWidgetService, times(1)).getAppWidgetIds(any());
+ verify(mIAppWidgetService, times(1))
+ .notifyAppWidgetViewDataChanged(any(), eq(widgetIdsArray), anyInt());
+
+ }
}
diff --git a/packages/SystemUI/tests/src/com/android/systemui/qs/QSFragmentTest.java b/packages/SystemUI/tests/src/com/android/systemui/qs/QSFragmentTest.java
index 858ecdc..a6b0330 100644
--- a/packages/SystemUI/tests/src/com/android/systemui/qs/QSFragmentTest.java
+++ b/packages/SystemUI/tests/src/com/android/systemui/qs/QSFragmentTest.java
@@ -43,6 +43,7 @@
import com.android.systemui.SysuiBaseFragmentTest;
import com.android.systemui.broadcast.BroadcastDispatcher;
import com.android.systemui.dump.DumpManager;
+import com.android.systemui.media.MediaHost;
import com.android.systemui.plugins.statusbar.StatusBarStateController;
import com.android.systemui.qs.dagger.QSFragmentComponent;
import com.android.systemui.qs.logging.QSLogger;
@@ -82,6 +83,10 @@
private QSFragmentComponent mQsFragmentComponent;
@Mock
private QSPanelController mQSPanelController;
+ @Mock
+ private MediaHost mQSMediaHost;
+ @Mock
+ private MediaHost mQQSMediaHost;
public QSFragmentTest() {
super(QSFragment.class);
@@ -168,6 +173,8 @@
mock(StatusBarStateController.class),
commandQueue,
new QSDetailDisplayer(),
+ mQSMediaHost,
+ mQQSMediaHost,
mQsComponentFactory);
}
}
diff --git a/packages/SystemUI/tests/src/com/android/systemui/qs/QSPanelControllerBaseTest.java b/packages/SystemUI/tests/src/com/android/systemui/qs/QSPanelControllerBaseTest.java
index 9421cd0..0fe44ad 100644
--- a/packages/SystemUI/tests/src/com/android/systemui/qs/QSPanelControllerBaseTest.java
+++ b/packages/SystemUI/tests/src/com/android/systemui/qs/QSPanelControllerBaseTest.java
@@ -86,13 +86,17 @@
private QSPanelControllerBase<QSPanel> mController;
/** Implementation needed to ensure we have a reflectively-available class name. */
- private static class TestableQSPanelControllerBase extends QSPanelControllerBase<QSPanel> {
+ private class TestableQSPanelControllerBase extends QSPanelControllerBase<QSPanel> {
protected TestableQSPanelControllerBase(QSPanel view, QSTileHost host,
- QSCustomizerController qsCustomizerController,
- QSTileRevealController.Factory qsTileRevealControllerFactory,
+ QSCustomizerController qsCustomizerController, MediaHost mediaHost,
MetricsLogger metricsLogger, UiEventLogger uiEventLogger, DumpManager dumpManager) {
- super(view, host, qsCustomizerController, qsTileRevealControllerFactory, metricsLogger,
- uiEventLogger, dumpManager);
+ super(view, host, qsCustomizerController, mediaHost,
+ metricsLogger, uiEventLogger, dumpManager);
+ }
+
+ @Override
+ protected QSTileRevealController createTileRevealController() {
+ return mQSTileRevealController;
}
}
@@ -100,7 +104,6 @@
public void setup() throws Exception {
MockitoAnnotations.initMocks(this);
- when(mQSPanel.getMediaHost()).thenReturn(mMediaHost);
when(mQSPanel.isAttachedToWindow()).thenReturn(true);
when(mQSPanel.getDumpableTag()).thenReturn("QSPanel");
when(mQSPanel.openPanelEvent()).thenReturn(QSEvent.QS_PANEL_EXPANDED);
@@ -108,11 +111,11 @@
when(mQSPanel.createRegularTileLayout()).thenReturn(mPagedTileLayout);
when(mQSTileHost.getTiles()).thenReturn(Collections.singleton(mQSTile));
when(mQSTileHost.createTileView(eq(mQSTile), anyBoolean())).thenReturn(mQSTileView);
- when(mQSTileRevealControllerFactory.create(any())).thenReturn(mQSTileRevealController);
+ when(mQSTileRevealControllerFactory.create(any(), any()))
+ .thenReturn(mQSTileRevealController);
mController = new TestableQSPanelControllerBase(mQSPanel, mQSTileHost,
- mQSCustomizerController, mQSTileRevealControllerFactory, mMetricsLogger,
- mUiEventLogger, mDumpManager);
+ mQSCustomizerController, mMediaHost, mMetricsLogger, mUiEventLogger, mDumpManager);
mController.init();
reset(mQSTileRevealController);
@@ -122,9 +125,14 @@
public void testSetRevealExpansion_preAttach() {
mController.onViewDetached();
- QSPanelControllerBase<QSPanel> controller = new TestableQSPanelControllerBase(mQSPanel,
- mQSTileHost, mQSCustomizerController, mQSTileRevealControllerFactory,
- mMetricsLogger, mUiEventLogger, mDumpManager);
+ QSPanelControllerBase<QSPanel> controller = new QSPanelControllerBase<QSPanel>(
+ mQSPanel, mQSTileHost, mQSCustomizerController, mMediaHost, mMetricsLogger,
+ mUiEventLogger, mDumpManager) {
+ @Override
+ protected QSTileRevealController createTileRevealController() {
+ return mQSTileRevealController;
+ }
+ };
// Nothing happens until attached
controller.setRevealExpansion(0);
diff --git a/packages/SystemUI/tests/src/com/android/systemui/qs/QSPanelControllerTest.java b/packages/SystemUI/tests/src/com/android/systemui/qs/QSPanelControllerTest.java
index f57e3c2..9090b9b 100644
--- a/packages/SystemUI/tests/src/com/android/systemui/qs/QSPanelControllerTest.java
+++ b/packages/SystemUI/tests/src/com/android/systemui/qs/QSPanelControllerTest.java
@@ -41,6 +41,7 @@
import com.android.systemui.settings.brightness.BrightnessSlider;
import com.android.systemui.settings.brightness.ToggleSlider;
import com.android.systemui.tuner.TunerService;
+import com.android.systemui.util.animation.DisappearParameters;
import org.junit.Before;
import org.junit.Test;
@@ -97,7 +98,6 @@
public void setup() throws Exception {
MockitoAnnotations.initMocks(this);
- when(mQSPanel.getMediaHost()).thenReturn(mMediaHost);
when(mQSPanel.isAttachedToWindow()).thenReturn(true);
when(mQSPanel.getDumpableTag()).thenReturn("QSPanel");
when(mQSPanel.createRegularTileLayout()).thenReturn(mPagedTileLayout);
@@ -107,11 +107,13 @@
.thenReturn(mBrightnessSlider);
when(mBrightnessControllerFactory.create(any(ToggleSlider.class)))
.thenReturn(mBrightnessController);
- when(mQSTileRevealControllerFactory.create(any())).thenReturn(mQSTileRevealController);
+ when(mQSTileRevealControllerFactory.create(any(), any()))
+ .thenReturn(mQSTileRevealController);
+ when(mMediaHost.getDisappearParameters()).thenReturn(new DisappearParameters());
mController = new QSPanelController(mQSPanel, mQSSecurityFooter, mTunerService,
- mQSTileHost, mQSCustomizerController, mQSTileRevealControllerFactory, mDumpManager,
- mMetricsLogger, mUiEventLogger, mBrightnessControllerFactory,
+ mQSTileHost, mQSCustomizerController, mMediaHost, mQSTileRevealControllerFactory,
+ mDumpManager, mMetricsLogger, mUiEventLogger, mBrightnessControllerFactory,
mToggleSliderViewControllerFactory);
mController.init();
diff --git a/packages/SystemUI/tests/src/com/android/systemui/qs/QSSecurityFooterTest.java b/packages/SystemUI/tests/src/com/android/systemui/qs/QSSecurityFooterTest.java
index c82aee4..6fa6f31 100644
--- a/packages/SystemUI/tests/src/com/android/systemui/qs/QSSecurityFooterTest.java
+++ b/packages/SystemUI/tests/src/com/android/systemui/qs/QSSecurityFooterTest.java
@@ -23,8 +23,9 @@
import static org.mockito.Mockito.verify;
import static org.mockito.Mockito.when;
-import android.content.Context;
import android.content.pm.UserInfo;
+import android.os.Handler;
+import android.os.Looper;
import android.provider.Settings;
import android.test.suitebuilder.annotation.SmallTest;
import android.testing.AndroidTestingRunner;
@@ -38,16 +39,18 @@
import android.view.ViewGroup;
import android.widget.TextView;
-import com.android.systemui.Dependency;
import com.android.systemui.R;
import com.android.systemui.SysuiTestCase;
+import com.android.systemui.plugins.ActivityStarter;
import com.android.systemui.settings.UserTracker;
import com.android.systemui.statusbar.policy.SecurityController;
import org.junit.Before;
import org.junit.Test;
import org.junit.runner.RunWith;
+import org.mockito.Mock;
import org.mockito.Mockito;
+import org.mockito.MockitoAnnotations;
/*
* Compile and run the whole SystemUI test suite:
@@ -73,22 +76,23 @@
private TextView mFooterText;
private TestableImageView mFooterIcon;
private QSSecurityFooter mFooter;
- private SecurityController mSecurityController = mock(SecurityController.class);
+ @Mock
+ private SecurityController mSecurityController;
+ @Mock
private UserTracker mUserTracker;
+ @Mock
+ private ActivityStarter mActivityStarter;
@Before
public void setUp() {
- mDependency.injectTestDependency(SecurityController.class, mSecurityController);
- mDependency.injectTestDependency(Dependency.BG_LOOPER,
- TestableLooper.get(this).getLooper());
- mUserTracker = mock(UserTracker.class);
+ MockitoAnnotations.initMocks(this);
+ Looper looper = TestableLooper.get(this).getLooper();
when(mUserTracker.getUserInfo()).thenReturn(mock(UserInfo.class));
- mContext.addMockSystemService(Context.LAYOUT_INFLATER_SERVICE,
- new LayoutInflaterBuilder(mContext)
- .replace("ImageView", TestableImageView.class)
- .build());
- mFooter = new QSSecurityFooter(null, mContext, mUserTracker);
- mRootView = (ViewGroup) mFooter.getView();
+ mRootView = (ViewGroup) new LayoutInflaterBuilder(mContext)
+ .replace("ImageView", TestableImageView.class)
+ .build().inflate(R.layout.quick_settings_footer, null, false);
+ mFooter = new QSSecurityFooter(mRootView, mContext, mUserTracker, new Handler(looper),
+ mActivityStarter, mSecurityController, looper);
mFooterText = mRootView.findViewById(R.id.footer_text);
mFooterIcon = mRootView.findViewById(R.id.footer_icon);
mFooter.setHostEnvironment(null);
diff --git a/packages/SystemUI/tests/src/com/android/systemui/statusbar/notification/collection/NoManSimulator.java b/packages/SystemUI/tests/src/com/android/systemui/statusbar/notification/collection/NoManSimulator.java
index c113df0b..1bfe10c5 100644
--- a/packages/SystemUI/tests/src/com/android/systemui/statusbar/notification/collection/NoManSimulator.java
+++ b/packages/SystemUI/tests/src/com/android/systemui/statusbar/notification/collection/NoManSimulator.java
@@ -16,8 +16,12 @@
package com.android.systemui.statusbar.notification.collection;
+import static android.app.NotificationManager.IMPORTANCE_DEFAULT;
+
import static org.junit.Assert.assertNotNull;
+import android.app.NotificationChannel;
+import android.os.UserHandle;
import android.service.notification.NotificationListenerService.Ranking;
import android.service.notification.NotificationListenerService.RankingMap;
import android.service.notification.StatusBarNotification;
@@ -72,6 +76,17 @@
}
}
+ public NotificationChannel createNotificationChannel(String id, String name) {
+ return new NotificationChannel(id, name, IMPORTANCE_DEFAULT);
+ }
+
+ public void issueChannelModification(
+ String pkg, UserHandle user, NotificationChannel channel, int modificationType) {
+ for (NotificationHandler listener : mListeners) {
+ listener.onNotificationChannelModified(pkg, user, channel, modificationType);
+ }
+ }
+
public void setRanking(String key, Ranking ranking) {
mRankings.put(key, ranking);
}
diff --git a/packages/SystemUI/tests/src/com/android/systemui/statusbar/phone/KeyguardBouncerTest.java b/packages/SystemUI/tests/src/com/android/systemui/statusbar/phone/KeyguardBouncerTest.java
index 4fb45ec..1b05ad7 100644
--- a/packages/SystemUI/tests/src/com/android/systemui/statusbar/phone/KeyguardBouncerTest.java
+++ b/packages/SystemUI/tests/src/com/android/systemui/statusbar/phone/KeyguardBouncerTest.java
@@ -50,7 +50,6 @@
import com.android.keyguard.dagger.KeyguardBouncerComponent;
import com.android.systemui.DejankUtils;
import com.android.systemui.SysuiTestCase;
-import com.android.systemui.biometrics.AuthController;
import com.android.systemui.keyguard.DismissCallbackRegistry;
import com.android.systemui.plugins.ActivityStarter.OnDismissAction;
import com.android.systemui.plugins.FalsingManager;
@@ -79,8 +78,6 @@
@Mock
private DismissCallbackRegistry mDismissCallbackRegistry;
@Mock
- private AuthController mAuthController;
- @Mock
private KeyguardHostViewController mKeyguardHostViewController;
@Mock
private KeyguardBouncer.BouncerExpansionCallback mExpansionCallback;
@@ -131,7 +128,7 @@
final ViewGroup container = new FrameLayout(getContext());
mBouncer = new KeyguardBouncer.Factory(getContext(), mViewMediatorCallback,
- mDismissCallbackRegistry, mFalsingManager, mAuthController,
+ mDismissCallbackRegistry, mFalsingManager,
mKeyguardStateController, mKeyguardUpdateMonitor,
mKeyguardBypassController, mHandler, mKeyguardSecurityModel,
mKeyguardBouncerComponentFactory)
@@ -210,12 +207,6 @@
}
@Test
- public void testShow_notifiesAuthControllerStartingToShow() {
- mBouncer.show(/* resetSecuritySelection */ false);
- verify(mAuthController).onStartingToShow();
- }
-
- @Test
public void testSetExpansion_notifiesFalsingManager() {
mBouncer.ensureView();
mBouncer.setExpansion(0.5f);
@@ -246,38 +237,6 @@
}
@Test
- public void testSetExpansion_notifiesAuthControllerFullyShown() {
- mBouncer.ensureView();
- mBouncer.setExpansion(0.1f);
- mBouncer.setExpansion(0f);
- verify(mAuthController).onFullyShown();
- }
-
- @Test
- public void testSetExpansion_notifiesAuthControllerStartingToHide() {
- mBouncer.ensureView();
- mBouncer.setExpansion(0f);
- mBouncer.setExpansion(0.1f);
- verify(mAuthController).onStartingToHide();
- }
-
- @Test
- public void testSetExpansion_notifiesAuthControllerFullyHidden() {
- mBouncer.ensureView();
- mBouncer.setExpansion(0.9f);
- mBouncer.setExpansion(1f);
- verify(mAuthController).onFullyHidden();
- }
-
- @Test
- public void testSetExpansion_negativeAuthControllerStartingToShow() {
- mBouncer.ensureView();
- mBouncer.setExpansion(1f);
- mBouncer.setExpansion(0.9f);
- verify(mAuthController, never()).onStartingToShow();
- }
-
- @Test
public void testHide_notifiesFalsingManager() {
mBouncer.hide(false);
verify(mFalsingManager).onBouncerHidden();
diff --git a/packages/SystemUI/tests/src/com/android/systemui/wmshell/WMShellTest.java b/packages/SystemUI/tests/src/com/android/systemui/wmshell/WMShellTest.java
index 34889ff..a658469 100644
--- a/packages/SystemUI/tests/src/com/android/systemui/wmshell/WMShellTest.java
+++ b/packages/SystemUI/tests/src/com/android/systemui/wmshell/WMShellTest.java
@@ -34,6 +34,7 @@
import com.android.systemui.statusbar.policy.ConfigurationController;
import com.android.systemui.tracing.ProtoTracer;
import com.android.wm.shell.ShellDump;
+import com.android.wm.shell.apppairs.AppPairs;
import com.android.wm.shell.hidedisplaycutout.HideDisplayCutout;
import com.android.wm.shell.onehanded.OneHanded;
import com.android.wm.shell.onehanded.OneHandedGestureHandler;
@@ -68,6 +69,7 @@
@Mock HideDisplayCutout mHideDisplayCutout;
@Mock ProtoTracer mProtoTracer;
@Mock ShellDump mShellDump;
+ @Mock AppPairs mAppPairs;
@Before
public void setUp() {
@@ -77,7 +79,7 @@
mKeyguardUpdateMonitor, mNavigationModeController,
mScreenLifecycle, mSysUiState, Optional.of(mPip), Optional.of(mSplitScreen),
Optional.of(mOneHanded), Optional.of(mHideDisplayCutout), mProtoTracer,
- Optional.of(mShellDump));
+ Optional.of(mShellDump), Optional.of(mAppPairs));
when(mPip.getPipTouchHandler()).thenReturn(mPipTouchHandler);
}
diff --git a/services/accessibility/java/com/android/server/accessibility/gestures/TouchState.java b/services/accessibility/java/com/android/server/accessibility/gestures/TouchState.java
index dae16b2..6dabe76 100644
--- a/services/accessibility/java/com/android/server/accessibility/gestures/TouchState.java
+++ b/services/accessibility/java/com/android/server/accessibility/gestures/TouchState.java
@@ -207,6 +207,11 @@
case AccessibilityEvent.TYPE_GESTURE_DETECTION_START:
startGestureDetecting();
break;
+ case AccessibilityEvent.TYPE_GESTURE_DETECTION_END:
+ // Clear to make sure that we don't accidentally execute passthrough, and that we
+ // are ready for the next interaction.
+ clear();
+ break;
default:
break;
}
diff --git a/services/core/java/com/android/server/ConnectivityService.java b/services/core/java/com/android/server/ConnectivityService.java
index 1eba37d..d586f00 100644
--- a/services/core/java/com/android/server/ConnectivityService.java
+++ b/services/core/java/com/android/server/ConnectivityService.java
@@ -137,6 +137,7 @@
import android.net.shared.PrivateDnsConfig;
import android.net.util.MultinetworkPolicyTracker;
import android.net.util.NetdService;
+import android.os.BasicShellCommandHandler;
import android.os.Binder;
import android.os.Build;
import android.os.Bundle;
@@ -189,7 +190,6 @@
import com.android.internal.util.LocationPermissionChecker;
import com.android.internal.util.MessageUtils;
import com.android.internal.util.XmlUtils;
-import com.android.modules.utils.BasicShellCommandHandler;
import com.android.net.module.util.LinkPropertiesUtils.CompareOrUpdateResult;
import com.android.net.module.util.LinkPropertiesUtils.CompareResult;
import com.android.server.am.BatteryStatsService;
diff --git a/services/core/java/com/android/server/adb/AdbShellCommand.java b/services/core/java/com/android/server/adb/AdbShellCommand.java
index d7e95df..7691852 100644
--- a/services/core/java/com/android/server/adb/AdbShellCommand.java
+++ b/services/core/java/com/android/server/adb/AdbShellCommand.java
@@ -16,7 +16,7 @@
package com.android.server.adb;
-import com.android.modules.utils.BasicShellCommandHandler;
+import android.os.BasicShellCommandHandler;
import java.io.PrintWriter;
import java.util.Objects;
diff --git a/services/core/java/com/android/server/am/ActiveInstrumentation.java b/services/core/java/com/android/server/am/ActiveInstrumentation.java
index db63638..43474d5 100644
--- a/services/core/java/com/android/server/am/ActiveInstrumentation.java
+++ b/services/core/java/com/android/server/am/ActiveInstrumentation.java
@@ -70,6 +70,9 @@
// The uid of the process who started this instrumentation.
int mSourceUid;
+ // True if instrumentation should take place without restarting the target process.
+ boolean mNoRestart;
+
ActiveInstrumentation(ActivityManagerService service) {
mService = service;
}
diff --git a/services/core/java/com/android/server/am/ActivityManagerService.java b/services/core/java/com/android/server/am/ActivityManagerService.java
index 796ea0e..4ca1358 100644
--- a/services/core/java/com/android/server/am/ActivityManagerService.java
+++ b/services/core/java/com/android/server/am/ActivityManagerService.java
@@ -25,6 +25,7 @@
import static android.app.ActivityManager.INSTR_FLAG_DISABLE_HIDDEN_API_CHECKS;
import static android.app.ActivityManager.INSTR_FLAG_DISABLE_ISOLATED_STORAGE;
import static android.app.ActivityManager.INSTR_FLAG_DISABLE_TEST_API_CHECKS;
+import static android.app.ActivityManager.INSTR_FLAG_NO_RESTART;
import static android.app.ActivityManager.PROCESS_STATE_NONEXISTENT;
import static android.app.ActivityManager.PROCESS_STATE_TOP;
import static android.app.ActivityManagerInternal.ALLOW_FULL_ONLY;
@@ -14218,9 +14219,12 @@
synchronized(this) {
InstrumentationInfo ii = null;
ApplicationInfo ai = null;
+
+ boolean noRestart = (flags & INSTR_FLAG_NO_RESTART) != 0;
+
try {
ii = mContext.getPackageManager().getInstrumentationInfo(
- className, STOCK_PM_FLAGS);
+ className, STOCK_PM_FLAGS);
ai = AppGlobals.getPackageManager().getApplicationInfo(
ii.targetPackage, STOCK_PM_FLAGS, userId);
} catch (PackageManager.NameNotFoundException e) {
@@ -14236,24 +14240,33 @@
"Unable to find instrumentation target package: " + ii.targetPackage);
return false;
}
- if (!ai.hasCode()) {
+
+ if (ii.targetPackage.equals("android")) {
+ if (!noRestart) {
+ reportStartInstrumentationFailureLocked(watcher, className,
+ "Cannot instrument system server without 'no-restart'");
+ return false;
+ }
+ } else if (!ai.hasCode()) {
reportStartInstrumentationFailureLocked(watcher, className,
"Instrumentation target has no code: " + ii.targetPackage);
return false;
}
- int match = mContext.getPackageManager().checkSignatures(
- ii.targetPackage, ii.packageName);
- if (match < 0 && match != PackageManager.SIGNATURE_FIRST_NOT_SIGNED) {
- String msg = "Permission Denial: starting instrumentation "
- + className + " from pid="
- + Binder.getCallingPid()
- + ", uid=" + Binder.getCallingPid()
- + " not allowed because package " + ii.packageName
- + " does not have a signature matching the target "
- + ii.targetPackage;
- reportStartInstrumentationFailureLocked(watcher, className, msg);
- throw new SecurityException(msg);
+ if (!Build.IS_DEBUGGABLE) {
+ int match = mContext.getPackageManager().checkSignatures(
+ ii.targetPackage, ii.packageName);
+ if (match < 0 && match != PackageManager.SIGNATURE_FIRST_NOT_SIGNED) {
+ String msg = "Permission Denial: starting instrumentation "
+ + className + " from pid="
+ + Binder.getCallingPid()
+ + ", uid=" + Binder.getCallingPid()
+ + " not allowed because package " + ii.packageName
+ + " does not have a signature matching the target "
+ + ii.targetPackage;
+ reportStartInstrumentationFailureLocked(watcher, className, msg);
+ throw new SecurityException(msg);
+ }
}
ActiveInstrumentation activeInstr = new ActiveInstrumentation(this);
@@ -14276,6 +14289,7 @@
activeInstr.mHasBackgroundActivityStartsPermission = checkPermission(
START_ACTIVITIES_FROM_BACKGROUND, callingPid, callingUid)
== PackageManager.PERMISSION_GRANTED;
+ activeInstr.mNoRestart = noRestart;
boolean disableHiddenApiChecks = ai.usesNonSdkApi()
|| (flags & INSTR_FLAG_DISABLE_HIDDEN_API_CHECKS) != 0;
@@ -14291,18 +14305,25 @@
&& (flags & INSTR_FLAG_DISABLE_ISOLATED_STORAGE) != 0;
final long origId = Binder.clearCallingIdentity();
- // Instrumentation can kill and relaunch even persistent processes
- forceStopPackageLocked(ii.targetPackage, -1, true, false, true, true, false, userId,
- "start instr");
- // Inform usage stats to make the target package active
- if (mUsageStatsService != null) {
- mUsageStatsService.reportEvent(ii.targetPackage, userId,
- UsageEvents.Event.SYSTEM_INTERACTION);
+
+ ProcessRecord app;
+ if (noRestart) {
+ app = getProcessRecordLocked(ai.processName, ai.uid, true);
+ } else {
+ // Instrumentation can kill and relaunch even persistent processes
+ forceStopPackageLocked(ii.targetPackage, -1, true, false, true, true, false, userId,
+ "start instr");
+ // Inform usage stats to make the target package active
+ if (mUsageStatsService != null) {
+ mUsageStatsService.reportEvent(ii.targetPackage, userId,
+ UsageEvents.Event.SYSTEM_INTERACTION);
+ }
+ app = addAppLocked(ai, defProcess, false, disableHiddenApiChecks,
+ disableTestApiChecks, mountExtStorageFull, abiOverride,
+ ZYGOTE_POLICY_FLAG_EMPTY);
}
- ProcessRecord app = addAppLocked(ai, defProcess, false, disableHiddenApiChecks,
- disableTestApiChecks, mountExtStorageFull, abiOverride,
- ZYGOTE_POLICY_FLAG_EMPTY);
+
app.setActiveInstrumentation(activeInstr);
activeInstr.mFinished = false;
activeInstr.mSourceUid = callingUid;
@@ -14318,11 +14339,34 @@
ii.packageName, AppOpsManager.MODE_ALLOWED);
}
Binder.restoreCallingIdentity(origId);
+
+ if (noRestart) {
+ instrumentWithoutRestart(activeInstr, ai);
+ }
}
return true;
}
+ private void instrumentWithoutRestart(ActiveInstrumentation activeInstr,
+ ApplicationInfo targetInfo) {
+ ProcessRecord pr;
+ synchronized (this) {
+ pr = getProcessRecordLocked(targetInfo.processName, targetInfo.uid, true);
+ }
+
+ try {
+ pr.thread.instrumentWithoutRestart(
+ activeInstr.mClass,
+ activeInstr.mArguments,
+ activeInstr.mWatcher,
+ activeInstr.mUiAutomationConnection,
+ targetInfo);
+ } catch (RemoteException e) {
+ Slog.i(TAG, "RemoteException from instrumentWithoutRestart", e);
+ }
+ }
+
private boolean isCallerShell() {
final int callingUid = Binder.getCallingUid();
return callingUid == SHELL_UID || callingUid == ROOT_UID;
@@ -14421,8 +14465,11 @@
instr.removeProcess(app);
app.setActiveInstrumentation(null);
- forceStopPackageLocked(app.info.packageName, -1, false, false, true, true, false, app.userId,
- "finished inst");
+ if (!instr.mNoRestart) {
+ forceStopPackageLocked(app.info.packageName, -1, false, false, true, true, false,
+ app.userId,
+ "finished inst");
+ }
}
public void finishInstrumentation(IApplicationThread target,
diff --git a/services/core/java/com/android/server/appop/AppOpsService.java b/services/core/java/com/android/server/appop/AppOpsService.java
index d434783..0b2628d 100644
--- a/services/core/java/com/android/server/appop/AppOpsService.java
+++ b/services/core/java/com/android/server/appop/AppOpsService.java
@@ -3065,7 +3065,7 @@
final int proxyMode = noteOperationUnchecked(code, proxyUid, resolveProxyPackageName,
proxyAttributionTag, Process.INVALID_UID, null, null, proxyFlags,
!isProxyTrusted, "proxy " + message, shouldCollectMessage);
- if (proxyMode != AppOpsManager.MODE_ALLOWED || Binder.getCallingUid() == proxiedUid) {
+ if (proxyMode != AppOpsManager.MODE_ALLOWED) {
return proxyMode;
}
@@ -3550,8 +3550,7 @@
resolvedProxyPackageName, proxyAttributionTag, Process.INVALID_UID, null, null,
proxyFlags, startIfModeDefault, !isProxyTrusted, "proxy " + message,
shouldCollectMessage, false);
- if (!shouldStartForMode(proxyMode, startIfModeDefault)
- || Binder.getCallingUid() == proxiedUid) {
+ if (!shouldStartForMode(proxyMode, startIfModeDefault)) {
return proxyMode;
}
diff --git a/services/core/java/com/android/server/display/DisplayManagerService.java b/services/core/java/com/android/server/display/DisplayManagerService.java
index 3ac2185..004e481 100644
--- a/services/core/java/com/android/server/display/DisplayManagerService.java
+++ b/services/core/java/com/android/server/display/DisplayManagerService.java
@@ -89,6 +89,7 @@
import android.util.Pair;
import android.util.Slog;
import android.util.SparseArray;
+import android.util.SparseIntArray;
import android.util.Spline;
import android.view.Display;
import android.view.DisplayInfo;
@@ -96,6 +97,7 @@
import android.view.Surface;
import android.view.SurfaceControl;
+import com.android.internal.BrightnessSynchronizer;
import com.android.internal.annotations.GuardedBy;
import com.android.internal.annotations.VisibleForTesting;
import com.android.internal.util.DumpUtils;
@@ -112,7 +114,6 @@
import java.io.FileDescriptor;
import java.io.PrintWriter;
import java.util.ArrayList;
-import java.util.List;
import java.util.Optional;
import java.util.concurrent.CopyOnWriteArrayList;
import java.util.function.Consumer;
@@ -235,15 +236,28 @@
private final DisplayBlanker mDisplayBlanker = new DisplayBlanker() {
@Override
public void requestDisplayState(int displayId, int state, float brightness) {
+ // TODO (b/168210494): Stop applying default display state to all displays.
+ if (displayId != Display.DEFAULT_DISPLAY) {
+ return;
+ }
+ final int[] displayIds;
+ synchronized (mSyncRoot) {
+ displayIds = mLogicalDisplayMapper.getDisplayIdsLocked();
+ }
+
// The order of operations is important for legacy reasons.
if (state == Display.STATE_OFF) {
- requestGlobalDisplayStateInternal(state, brightness);
+ for (int id : displayIds) {
+ requestDisplayStateInternal(id, state, brightness);
+ }
}
mDisplayPowerCallbacks.onDisplayStateChange(state);
if (state != Display.STATE_OFF) {
- requestGlobalDisplayStateInternal(state, brightness);
+ for (int id : displayIds) {
+ requestDisplayStateInternal(id, state, brightness);
+ }
}
}
};
@@ -257,13 +271,16 @@
/** The {@link Handler} used by all {@link DisplayPowerController}s. */
private Handler mPowerHandler;
- // The overall display state, independent of changes that might influence one
- // display or another in particular.
- private int mGlobalDisplayState = Display.STATE_ON;
+ // A map from LogicalDisplay ID to display power state.
+ @GuardedBy("mSyncRoot")
+ private final SparseIntArray mDisplayStates = new SparseIntArray();
- // The overall display brightness.
- // For now, this only applies to the default display but we may split it up eventually.
- private float mGlobalDisplayBrightness;
+ // A map from LogicalDisplay ID to display brightness.
+ @GuardedBy("mSyncRoot")
+ private final SparseArray<Float> mDisplayBrightnesses = new SparseArray<>();
+
+ // The default brightness.
+ private final float mDisplayDefaultBrightness;
// Set to true when there are pending display changes that have yet to be applied
// to the surface flinger state.
@@ -317,11 +334,6 @@
// DisplayDeviceInfo.FLAG_DEFAULT_DISPLAY flag set.
private final int mDefaultDisplayDefaultColorMode;
- // Temporary list of deferred work to perform when setting the display state.
- // Only used by requestDisplayState. The field is self-synchronized and only
- // intended for use inside of the requestGlobalDisplayStateInternal function.
- private final ArrayList<Runnable> mTempDisplayStateWorkQueue = new ArrayList<Runnable>();
-
// Lists of UIDs that are present on the displays. Maps displayId -> array of UIDs.
private final SparseArray<IntArray> mDisplayAccessUIDs = new SparseArray<>();
@@ -372,7 +384,7 @@
mMinimumBrightnessSpline = Spline.createSpline(lux, nits);
PowerManager pm = mContext.getSystemService(PowerManager.class);
- mGlobalDisplayBrightness = pm.getBrightnessConstraint(
+ mDisplayDefaultBrightness = pm.getBrightnessConstraint(
PowerManager.BRIGHTNESS_CONSTRAINT_TYPE_DEFAULT);
mCurrentUserId = UserHandle.USER_SYSTEM;
ColorSpace[] colorSpaces = SurfaceControl.getCompositionColorSpaces();
@@ -589,7 +601,7 @@
}
}
- private void requestGlobalDisplayStateInternal(int state, float brightnessState) {
+ private void requestDisplayStateInternal(int displayId, int state, float brightnessState) {
if (state == Display.STATE_UNKNOWN) {
state = Display.STATE_ON;
}
@@ -602,38 +614,40 @@
brightnessState = PowerManager.BRIGHTNESS_MAX;
}
- synchronized (mTempDisplayStateWorkQueue) {
- try {
- // Update the display state within the lock.
- // Note that we do not need to schedule traversals here although it
- // may happen as a side-effect of displays changing state.
- synchronized (mSyncRoot) {
- if (mGlobalDisplayState == state
- && mGlobalDisplayBrightness == brightnessState) {
- return; // no change
- }
+ // Update the display state within the lock.
+ // Note that we do not need to schedule traversals here although it
+ // may happen as a side-effect of displays changing state.
+ final Runnable runnable;
+ final String traceMessage;
+ synchronized (mSyncRoot) {
+ final int index = mDisplayStates.indexOfKey(displayId);
- Trace.traceBegin(Trace.TRACE_TAG_POWER, "requestGlobalDisplayState("
- + Display.stateToString(state)
- + ", brightness=" + brightnessState + ")");
-
- mGlobalDisplayState = state;
- mGlobalDisplayBrightness = brightnessState;
- applyGlobalDisplayStateLocked(mTempDisplayStateWorkQueue);
- }
-
- // Setting the display power state can take hundreds of milliseconds
- // to complete so we defer the most expensive part of the work until
- // after we have exited the critical section to avoid blocking other
- // threads for a long time.
- for (int i = 0; i < mTempDisplayStateWorkQueue.size(); i++) {
- mTempDisplayStateWorkQueue.get(i).run();
- }
- Trace.traceEnd(Trace.TRACE_TAG_POWER);
- } finally {
- mTempDisplayStateWorkQueue.clear();
+ if (index < 0 || (mDisplayStates.valueAt(index) == state
+ && BrightnessSynchronizer.floatEquals(mDisplayBrightnesses.valueAt(index),
+ brightnessState))) {
+ return; // Display no longer exists or no change.
}
+
+ traceMessage = "requestDisplayStateInternal("
+ + displayId + ", "
+ + Display.stateToString(state)
+ + ", brightness=" + brightnessState + ")";
+ Trace.asyncTraceBegin(Trace.TRACE_TAG_POWER, traceMessage, displayId);
+
+ mDisplayStates.setValueAt(index, state);
+ mDisplayBrightnesses.setValueAt(index, brightnessState);
+ runnable = updateDisplayStateLocked(
+ mLogicalDisplayMapper.getLocked(displayId).getPrimaryDisplayDeviceLocked());
}
+
+ // Setting the display power state can take hundreds of milliseconds
+ // to complete so we defer the most expensive part of the work until
+ // after we have exited the critical section to avoid blocking other
+ // threads for a long time.
+ if (runnable != null) {
+ runnable.run();
+ }
+ Trace.asyncTraceEnd(Trace.TRACE_TAG_POWER, traceMessage, displayId);
}
private class SettingsObserver extends ContentObserver {
@@ -987,6 +1001,8 @@
recordTopInsetLocked(display);
}
addDisplayPowerControllerLocked(displayId);
+ mDisplayStates.append(displayId, Display.STATE_OFF);
+ mDisplayBrightnesses.append(displayId, mDisplayDefaultBrightness);
DisplayManagerGlobal.invalidateLocalDisplayInfoCaches();
@@ -1021,6 +1037,8 @@
private void handleLogicalDisplayRemovedLocked(@NonNull LogicalDisplay display) {
final int displayId = display.getDisplayIdLocked();
mDisplayPowerControllers.delete(displayId);
+ mDisplayStates.delete(displayId);
+ mDisplayBrightnesses.delete(displayId);
DisplayManagerGlobal.invalidateLocalDisplayInfoCaches();
sendDisplayEventLocked(displayId, DisplayManagerGlobal.EVENT_DISPLAY_REMOVED);
scheduleTraversalLocked(false);
@@ -1035,15 +1053,6 @@
handleLogicalDisplayChangedLocked(display);
}
- private void applyGlobalDisplayStateLocked(List<Runnable> workQueue) {
- mDisplayDeviceRepo.forEachLocked((DisplayDevice device) -> {
- Runnable runnable = updateDisplayStateLocked(device);
- if (runnable != null) {
- workQueue.add(runnable);
- }
- });
- }
-
private Runnable updateDisplayStateLocked(DisplayDevice device) {
// Blank or unblank the display immediately to match the state requested
// by the display power controller (if known).
@@ -1052,12 +1061,16 @@
// TODO - b/170498827 The rules regarding what display state to apply to each
// display will depend on the configuration/mapping of logical displays.
// Clean up LogicalDisplay.isEnabled() mechanism once this is fixed.
- int state = mGlobalDisplayState;
final LogicalDisplay display = mLogicalDisplayMapper.getLocked(device);
- if (display != null && !display.isEnabled()) {
+ final int state;
+ final int displayId = display.getDisplayIdLocked();
+ if (display.isEnabled()) {
+ state = mDisplayStates.get(displayId);
+ } else {
state = Display.STATE_OFF;
}
- return device.requestDisplayStateLocked(state, mGlobalDisplayBrightness);
+ final float brightness = mDisplayBrightnesses.get(displayId);
+ return device.requestDisplayStateLocked(state, brightness);
}
return null;
}
@@ -1587,13 +1600,24 @@
pw.println(" mOnlyCode=" + mOnlyCore);
pw.println(" mSafeMode=" + mSafeMode);
pw.println(" mPendingTraversal=" + mPendingTraversal);
- pw.println(" mGlobalDisplayState=" + Display.stateToString(mGlobalDisplayState));
pw.println(" mViewports=" + mViewports);
pw.println(" mDefaultDisplayDefaultColorMode=" + mDefaultDisplayDefaultColorMode);
pw.println(" mWifiDisplayScanRequestCount=" + mWifiDisplayScanRequestCount);
pw.println(" mStableDisplaySize=" + mStableDisplaySize);
pw.println(" mMinimumBrightnessCurve=" + mMinimumBrightnessCurve);
+ pw.println();
+ final int displayStateCount = mDisplayStates.size();
+ pw.println("Display States: size=" + displayStateCount);
+ for (int i = 0; i < displayStateCount; i++) {
+ final int displayId = mDisplayStates.keyAt(i);
+ final int displayState = mDisplayStates.valueAt(i);
+ final float brightness = mDisplayBrightnesses.valueAt(i);
+ pw.println(" Display Id=" + displayId);
+ pw.println(" Display State=" + Display.stateToString(displayState));
+ pw.println(" Display Brightness=" + brightness);
+ }
+
IndentingPrintWriter ipw = new IndentingPrintWriter(pw, " ");
ipw.increaseIndent();
diff --git a/services/core/java/com/android/server/display/DisplayPowerController.java b/services/core/java/com/android/server/display/DisplayPowerController.java
index 09c9aab..f488260 100644
--- a/services/core/java/com/android/server/display/DisplayPowerController.java
+++ b/services/core/java/com/android/server/display/DisplayPowerController.java
@@ -685,8 +685,6 @@
}
private void initialize() {
- // Initialize the power state object for the default display.
- // In the future, we might manage multiple displays independently.
mPowerState = new DisplayPowerState(mBlanker,
mColorFadeEnabled ? new ColorFade(mDisplayId) : null, mDisplayId);
diff --git a/services/core/java/com/android/server/display/LogicalDisplay.java b/services/core/java/com/android/server/display/LogicalDisplay.java
index e35becc..979c3b8 100644
--- a/services/core/java/com/android/server/display/LogicalDisplay.java
+++ b/services/core/java/com/android/server/display/LogicalDisplay.java
@@ -588,7 +588,7 @@
}
/**
- * Swap the underlying {@link DisplayDevice} with the specificed LogicalDisplay.
+ * Swap the underlying {@link DisplayDevice} with the specified LogicalDisplay.
*
* @param targetDisplay The display with which to swap display-devices.
* @return {@code true} if the displays were swapped, {@code false} otherwise.
diff --git a/services/core/java/com/android/server/display/LogicalDisplayMapper.java b/services/core/java/com/android/server/display/LogicalDisplayMapper.java
index a843af5..45c38b4 100644
--- a/services/core/java/com/android/server/display/LogicalDisplayMapper.java
+++ b/services/core/java/com/android/server/display/LogicalDisplayMapper.java
@@ -17,6 +17,7 @@
package com.android.server.display;
import android.content.Context;
+import android.os.Process;
import android.os.SystemProperties;
import android.text.TextUtils;
import android.util.Slog;
@@ -149,6 +150,10 @@
return null;
}
+ public int[] getDisplayIdsLocked() {
+ return getDisplayIdsLocked(Process.SYSTEM_UID);
+ }
+
public int[] getDisplayIdsLocked(int callingUid) {
final int count = mLogicalDisplays.size();
int[] displayIds = new int[count];
diff --git a/services/core/java/com/android/server/location/LocationShellCommand.java b/services/core/java/com/android/server/location/LocationShellCommand.java
index 3464704..909873f 100644
--- a/services/core/java/com/android/server/location/LocationShellCommand.java
+++ b/services/core/java/com/android/server/location/LocationShellCommand.java
@@ -16,10 +16,9 @@
package com.android.server.location;
+import android.os.BasicShellCommandHandler;
import android.os.UserHandle;
-import com.android.modules.utils.BasicShellCommandHandler;
-
import java.io.PrintWriter;
import java.util.Objects;
diff --git a/services/core/java/com/android/server/media/MediaServerUtils.java b/services/core/java/com/android/server/media/MediaServerUtils.java
new file mode 100644
index 0000000..5fa2b1c
--- /dev/null
+++ b/services/core/java/com/android/server/media/MediaServerUtils.java
@@ -0,0 +1,43 @@
+/*
+ * Copyright (C) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package com.android.server.media;
+
+import android.content.Context;
+import android.content.pm.PackageManager;
+import android.os.Binder;
+
+import java.io.PrintWriter;
+
+/**
+ * Util class for media server.
+ */
+class MediaServerUtils {
+ /**
+ * Verify that caller holds {@link android.Manifest.permission#DUMP}.
+ */
+ public static boolean checkDumpPermission(Context context, String tag, PrintWriter pw) {
+ if (context.checkCallingOrSelfPermission(android.Manifest.permission.DUMP)
+ != PackageManager.PERMISSION_GRANTED) {
+ pw.println("Permission Denial: can't dump " + tag + " from from pid="
+ + Binder.getCallingPid() + ", uid=" + Binder.getCallingUid()
+ + " due to missing android.permission.DUMP permission");
+ return false;
+ } else {
+ return true;
+ }
+ }
+}
diff --git a/services/core/java/com/android/server/media/MediaSessionService.java b/services/core/java/com/android/server/media/MediaSessionService.java
index d5ce8a6..c23bfc4 100644
--- a/services/core/java/com/android/server/media/MediaSessionService.java
+++ b/services/core/java/com/android/server/media/MediaSessionService.java
@@ -83,9 +83,7 @@
import com.android.internal.R;
import com.android.internal.annotations.GuardedBy;
-import com.android.internal.util.DumpUtils;
import com.android.server.SystemService;
-import com.android.server.SystemService.TargetUser;
import com.android.server.Watchdog;
import com.android.server.Watchdog.Monitor;
@@ -1885,7 +1883,7 @@
@Override
public void dump(FileDescriptor fd, final PrintWriter pw, String[] args) {
- if (!DumpUtils.checkDumpPermission(mContext, TAG, pw)) return;
+ if (!MediaServerUtils.checkDumpPermission(mContext, TAG, pw)) return;
pw.println("MEDIA SESSION SERVICE (dumpsys media_session)");
pw.println();
diff --git a/services/core/java/com/android/server/notification/NotificationManagerService.java b/services/core/java/com/android/server/notification/NotificationManagerService.java
index 1516cde..1e2898b 100755
--- a/services/core/java/com/android/server/notification/NotificationManagerService.java
+++ b/services/core/java/com/android/server/notification/NotificationManagerService.java
@@ -494,6 +494,10 @@
final ArrayList<ToastRecord> mToastQueue = new ArrayList<>();
final ArrayMap<String, NotificationRecord> mSummaryByGroupKey = new ArrayMap<>();
+ // True if the toast that's on top of the queue is being shown at the moment.
+ @GuardedBy("mToastQueue")
+ private boolean mIsCurrentToastShown = false;
+
// The last key in this list owns the hardware.
ArrayList<String> mLights = new ArrayList<>();
@@ -7297,10 +7301,15 @@
@GuardedBy("mToastQueue")
void showNextToastLocked() {
+ if (mIsCurrentToastShown) {
+ return; // Don't show the same toast twice.
+ }
+
ToastRecord record = mToastQueue.get(0);
while (record != null) {
if (record.show()) {
scheduleDurationReachedLocked(record);
+ mIsCurrentToastShown = true;
return;
}
int index = mToastQueue.indexOf(record);
@@ -7316,6 +7325,10 @@
ToastRecord record = mToastQueue.get(index);
record.hide();
+ if (index == 0) {
+ mIsCurrentToastShown = false;
+ }
+
ToastRecord lastToast = mToastQueue.remove(index);
mWindowManagerInternal.removeWindowToken(lastToast.windowToken, false /* removeWindows */,
diff --git a/services/core/java/com/android/server/pm/PackageManagerService.java b/services/core/java/com/android/server/pm/PackageManagerService.java
index 7afd3db..0500616 100644
--- a/services/core/java/com/android/server/pm/PackageManagerService.java
+++ b/services/core/java/com/android/server/pm/PackageManagerService.java
@@ -10818,7 +10818,7 @@
continue;
}
final PackageSetting staticLibPkgSetting = getPackageSetting(
- toStaticSharedLibraryPackageName(sharedLibraryInfo.getPackageName(),
+ toStaticSharedLibraryPackageName(sharedLibraryInfo.getName(),
sharedLibraryInfo.getLongVersion()));
if (staticLibPkgSetting == null) {
Slog.wtf(TAG, "Shared lib without setting: " + sharedLibraryInfo);
diff --git a/services/core/java/com/android/server/pm/parsing/PackageInfoUtils.java b/services/core/java/com/android/server/pm/parsing/PackageInfoUtils.java
index 2d2e72a..9dde7df 100644
--- a/services/core/java/com/android/server/pm/parsing/PackageInfoUtils.java
+++ b/services/core/java/com/android/server/pm/parsing/PackageInfoUtils.java
@@ -275,8 +275,8 @@
return null;
}
- ActivityInfo info =
- PackageInfoWithoutStateUtils.generateActivityInfoUnchecked(a, applicationInfo);
+ final ActivityInfo info = PackageInfoWithoutStateUtils.generateActivityInfoUnchecked(
+ a, flags, applicationInfo);
assignSharedFieldsForComponentInfo(info, a, pkgSetting, userId);
return info;
}
@@ -310,8 +310,8 @@
return null;
}
- ServiceInfo info =
- PackageInfoWithoutStateUtils.generateServiceInfoUnchecked(s, applicationInfo);
+ final ServiceInfo info = PackageInfoWithoutStateUtils.generateServiceInfoUnchecked(
+ s, flags, applicationInfo);
assignSharedFieldsForComponentInfo(info, s, pkgSetting, userId);
return info;
}
diff --git a/services/core/java/com/android/server/statusbar/StatusBarManagerService.java b/services/core/java/com/android/server/statusbar/StatusBarManagerService.java
index fb47ebb..bd2d382 100644
--- a/services/core/java/com/android/server/statusbar/StatusBarManagerService.java
+++ b/services/core/java/com/android/server/statusbar/StatusBarManagerService.java
@@ -24,15 +24,18 @@
import android.app.ITransientNotificationCallback;
import android.app.Notification;
import android.app.StatusBarManager;
+import android.app.compat.CompatChanges;
+import android.compat.annotation.ChangeId;
+import android.compat.annotation.EnabledSince;
import android.content.ComponentName;
import android.content.Context;
-import android.hardware.biometrics.BiometricAuthenticator;
import android.hardware.biometrics.IBiometricSysuiReceiver;
import android.hardware.biometrics.PromptInfo;
import android.hardware.display.DisplayManager;
import android.hardware.display.DisplayManager.DisplayListener;
import android.net.Uri;
import android.os.Binder;
+import android.os.Build;
import android.os.Bundle;
import android.os.Handler;
import android.os.IBinder;
@@ -84,6 +87,18 @@
private static final String TAG = "StatusBarManagerService";
private static final boolean SPEW = false;
+ /**
+ * Apps targeting {@code Build.VERSION_CODES.S} or higher need {@link
+ * android.Manifest.permission#STATUS_BAR} permission to collapse the status bar panels due to
+ * security reasons.
+ *
+ * This was being exploited by malware to prevent the user from accessing critical
+ * notifications.
+ */
+ @ChangeId
+ @EnabledSince(targetSdkVersion = Build.VERSION_CODES.S)
+ private static final long LOCK_DOWN_COLLAPSE_STATUS_BAR = 173031413L;
+
private final Context mContext;
private Handler mHandler = new Handler();
@@ -605,7 +620,11 @@
@Override
public void collapsePanels() {
- enforceExpandStatusBar();
+ if (CompatChanges.isChangeEnabled(LOCK_DOWN_COLLAPSE_STATUS_BAR, Binder.getCallingUid())) {
+ enforceStatusBar();
+ } else {
+ enforceExpandStatusBar();
+ }
if (mBar != null) {
try {
diff --git a/services/core/java/com/android/server/tv/TvInputManagerService.java b/services/core/java/com/android/server/tv/TvInputManagerService.java
index abcba5d..afbe552 100755
--- a/services/core/java/com/android/server/tv/TvInputManagerService.java
+++ b/services/core/java/com/android/server/tv/TvInputManagerService.java
@@ -134,12 +134,15 @@
private final Object mLock = new Object();
// ID of the current user.
+ @GuardedBy("mLock")
private int mCurrentUserId = UserHandle.USER_SYSTEM;
// A map from user id to UserState.
+ @GuardedBy("mLock")
private final SparseArray<UserState> mUserStates = new SparseArray<>();
// A map from session id to session state saved in userstate
+ @GuardedBy("mLock")
private final Map<String, SessionState> mSessionIdToSessionStateMap = new HashMap<>();
private final WatchLogHandler mWatchLogHandler;
@@ -280,7 +283,7 @@
return pm.checkPermission(android.Manifest.permission.TV_INPUT_HARDWARE,
component.getPackageName()) == PackageManager.PERMISSION_GRANTED;
}
-
+ @GuardedBy("mLock")
private void buildTvInputListLocked(int userId, String[] updatedPackages) {
UserState userState = getOrCreateUserStateLocked(userId);
userState.packageSet.clear();
@@ -368,6 +371,7 @@
userState.inputMap = inputMap;
}
+ @GuardedBy("mLock")
private void buildTvContentRatingSystemListLocked(int userId) {
UserState userState = getOrCreateUserStateLocked(userId);
userState.contentRatingSystemList.clear();
@@ -444,6 +448,7 @@
}
}
+ @GuardedBy("mLock")
private void clearSessionAndNotifyClientLocked(SessionState state) {
if (state.client != null) {
try {
@@ -528,6 +533,7 @@
return context.getContentResolver();
}
+ @GuardedBy("mLock")
private UserState getOrCreateUserStateLocked(int userId) {
UserState userState = mUserStates.get(userId);
if (userState == null) {
@@ -537,6 +543,7 @@
return userState;
}
+ @GuardedBy("mLock")
private ServiceState getServiceStateLocked(ComponentName component, int userId) {
UserState userState = getOrCreateUserStateLocked(userId);
ServiceState serviceState = userState.serviceStateMap.get(component);
@@ -546,12 +553,13 @@
}
return serviceState;
}
-
+ @GuardedBy("mLock")
private SessionState getSessionStateLocked(IBinder sessionToken, int callingUid, int userId) {
UserState userState = getOrCreateUserStateLocked(userId);
return getSessionStateLocked(sessionToken, callingUid, userState);
}
+ @GuardedBy("mLock")
private SessionState getSessionStateLocked(IBinder sessionToken,
int callingUid, UserState userState) {
SessionState sessionState = userState.sessionStateMap.get(sessionToken);
@@ -566,10 +574,12 @@
return sessionState;
}
+ @GuardedBy("mLock")
private ITvInputSession getSessionLocked(IBinder sessionToken, int callingUid, int userId) {
return getSessionLocked(getSessionStateLocked(sessionToken, callingUid, userId));
}
+ @GuardedBy("mLock")
private ITvInputSession getSessionLocked(SessionState sessionState) {
ITvInputSession session = sessionState.session;
if (session == null) {
@@ -585,6 +595,7 @@
false, methodName, null);
}
+ @GuardedBy("mLock")
private void updateServiceConnectionLocked(ComponentName component, int userId) {
UserState userState = getOrCreateUserStateLocked(userId);
ServiceState serviceState = userState.serviceStateMap.get(component);
@@ -638,6 +649,7 @@
}
}
+ @GuardedBy("mLock")
private void abortPendingCreateSessionRequestsLocked(ServiceState serviceState,
String inputId, int userId) {
// Let clients know the create session requests are failed.
@@ -658,6 +670,7 @@
updateServiceConnectionLocked(serviceState.component, userId);
}
+ @GuardedBy("mLock")
private boolean createSessionInternalLocked(ITvInputService service, IBinder sessionToken,
int userId) {
UserState userState = getOrCreateUserStateLocked(userId);
@@ -691,6 +704,7 @@
return created;
}
+ @GuardedBy("mLock")
private void sendSessionTokenToClientLocked(ITvInputClient client, String inputId,
IBinder sessionToken, InputChannel channel, int seq) {
try {
@@ -700,6 +714,7 @@
}
}
+ @GuardedBy("mLock")
private void releaseSessionLocked(IBinder sessionToken, int callingUid, int userId) {
SessionState sessionState = null;
try {
@@ -725,6 +740,7 @@
removeSessionStateLocked(sessionToken, userId);
}
+ @GuardedBy("mLock")
private void removeSessionStateLocked(IBinder sessionToken, int userId) {
UserState userState = getOrCreateUserStateLocked(userId);
if (sessionToken == userState.mainSessionToken) {
@@ -767,6 +783,7 @@
mWatchLogHandler.obtainMessage(WatchLogHandler.MSG_LOG_WATCH_END, args).sendToTarget();
}
+ @GuardedBy("mLock")
private void setMainLocked(IBinder sessionToken, boolean isMain, int callingUid, int userId) {
try {
SessionState sessionState = getSessionStateLocked(sessionToken, callingUid, userId);
@@ -785,6 +802,7 @@
}
}
+ @GuardedBy("mLock")
private void notifyInputAddedLocked(UserState userState, String inputId) {
if (DEBUG) {
Slog.d(TAG, "notifyInputAddedLocked(inputId=" + inputId + ")");
@@ -800,6 +818,7 @@
userState.mCallbacks.finishBroadcast();
}
+ @GuardedBy("mLock")
private void notifyInputRemovedLocked(UserState userState, String inputId) {
if (DEBUG) {
Slog.d(TAG, "notifyInputRemovedLocked(inputId=" + inputId + ")");
@@ -815,6 +834,7 @@
userState.mCallbacks.finishBroadcast();
}
+ @GuardedBy("mLock")
private void notifyInputUpdatedLocked(UserState userState, String inputId) {
if (DEBUG) {
Slog.d(TAG, "notifyInputUpdatedLocked(inputId=" + inputId + ")");
@@ -830,6 +850,7 @@
userState.mCallbacks.finishBroadcast();
}
+ @GuardedBy("mLock")
private void notifyInputStateChangedLocked(UserState userState, String inputId,
int state, ITvInputManagerCallback targetCallback) {
if (DEBUG) {
@@ -855,6 +876,7 @@
}
}
+ @GuardedBy("mLock")
private void notifyCurrentChannelInfosUpdatedLocked(UserState userState) {
if (DEBUG) {
Slog.d(TAG, "notifyCurrentChannelInfosUpdatedLocked");
@@ -874,6 +896,7 @@
userState.mCallbacks.finishBroadcast();
}
+ @GuardedBy("mLock")
private void updateTvInputInfoLocked(UserState userState, TvInputInfo inputInfo) {
if (DEBUG) {
Slog.d(TAG, "updateTvInputInfoLocked(inputInfo=" + inputInfo + ")");
@@ -897,6 +920,7 @@
userState.mCallbacks.finishBroadcast();
}
+ @GuardedBy("mLock")
private void setStateLocked(String inputId, int state, int userId) {
UserState userState = getOrCreateUserStateLocked(userId);
TvInputState inputState = userState.inputMap.get(inputId);
@@ -2138,6 +2162,7 @@
mTvInputHardwareManager.onDeviceUnavailable(deviceId);
}
+ @GuardedBy("mLock")
private int getClientPidLocked(String sessionId)
throws IllegalStateException {
if (mSessionIdToSessionStateMap.get(sessionId) == null) {
@@ -2277,6 +2302,7 @@
}
}
+ @GuardedBy("mLock")
private List<TunedInfo> getCurrentTunedInfosInternalLocked(
UserState userState, int callingPid, int callingUid) {
List<TunedInfo> channelInfos = new ArrayList<>();
@@ -2375,9 +2401,9 @@
// service.
private final PersistentDataStore persistentDataStore;
- @GuardedBy("mLock")
+ @GuardedBy("TvInputManagerService.this.mLock")
private final Map<Integer, Integer> mAppTagMap = new HashMap<>();
- @GuardedBy("mLock")
+ @GuardedBy("TvInputManagerService.this.mLock")
private int mNextAppTag = 1;
private UserState(Context context, int userId) {
@@ -2625,6 +2651,7 @@
}
}
+ @GuardedBy("mLock")
private void addHardwareInputLocked(TvInputInfo inputInfo) {
ServiceState serviceState = getServiceStateLocked(mComponent, mUserId);
serviceState.hardwareInputMap.put(inputInfo.getId(), inputInfo);
@@ -2694,6 +2721,7 @@
}
}
+ @GuardedBy("mLock")
private boolean addSessionTokenToClientStateLocked(ITvInputSession session) {
try {
session.asBinder().linkToDeath(mSessionState, 0);
diff --git a/services/core/java/com/android/server/wm/ActivityStarter.java b/services/core/java/com/android/server/wm/ActivityStarter.java
index d13b8d4..6f97936 100644
--- a/services/core/java/com/android/server/wm/ActivityStarter.java
+++ b/services/core/java/com/android/server/wm/ActivityStarter.java
@@ -1866,7 +1866,14 @@
}
}
- if (mRestrictedBgActivity && (newTask || !targetTask.isUidPresent(mCallingUid))
+ // Do not allow background activity start in new task or in a task that uid is not present.
+ // Also do not allow pinned window to start single instance activity in background,
+ // as it will recreate the window and makes it to foreground.
+ boolean blockBalInTask = (newTask
+ || !targetTask.isUidPresent(mCallingUid)
+ || (LAUNCH_SINGLE_INSTANCE == mLaunchMode && targetTask.inPinnedWindowingMode()));
+
+ if (mRestrictedBgActivity && blockBalInTask
&& handleBackgroundActivityAbort(mStartActivity)) {
Slog.e(TAG, "Abort background activity starts from " + mCallingUid);
return START_ABORTED;
diff --git a/services/core/java/com/android/server/wm/Task.java b/services/core/java/com/android/server/wm/Task.java
index ac9c289..90c3f9e 100644
--- a/services/core/java/com/android/server/wm/Task.java
+++ b/services/core/java/com/android/server/wm/Task.java
@@ -5888,7 +5888,21 @@
try {
// Protect against recursion.
mInResumeTopActivity = true;
- result = resumeTopActivityInnerLocked(prev, options);
+
+ // TODO(b/172885410): Allow the top activities of all visible leaf tasks to be resumed
+ if (mCreatedByOrganizer && !isLeafTask()
+ && getConfiguration().windowConfiguration.getWindowingMode()
+ == WINDOWING_MODE_FULLSCREEN) {
+ for (int i = mChildren.size() - 1; i >= 0; i--) {
+ final Task child = (Task) getChildAt(i);
+ if (!child.shouldBeVisible(null /* starting */)) {
+ break;
+ }
+ result |= child.resumeTopActivityUncheckedLocked(prev, options);
+ }
+ } else {
+ result = resumeTopActivityInnerLocked(prev, options);
+ }
// When resuming the top activity, it may be necessary to pause the top activity (for
// example, returning to the lock screen. We suppress the normal pause logic in
diff --git a/services/core/java/com/android/server/wm/WindowOrganizerController.java b/services/core/java/com/android/server/wm/WindowOrganizerController.java
index f11cd93..499fbf6 100644
--- a/services/core/java/com/android/server/wm/WindowOrganizerController.java
+++ b/services/core/java/com/android/server/wm/WindowOrganizerController.java
@@ -434,8 +434,7 @@
if (hop.isReparent()) {
final boolean isNonOrganizedRootableTask =
- (task.isRootTask() && !task.mCreatedByOrganizer)
- || task.getParent().asTask().mCreatedByOrganizer;
+ task.isRootTask() || task.getParent().asTask().mCreatedByOrganizer;
if (isNonOrganizedRootableTask) {
WindowContainer newParent = hop.getNewParent() == null
? dc.getDefaultTaskDisplayArea()
diff --git a/services/devicepolicy/java/com/android/server/devicepolicy/ActiveAdmin.java b/services/devicepolicy/java/com/android/server/devicepolicy/ActiveAdmin.java
index 412f582..d29534e 100644
--- a/services/devicepolicy/java/com/android/server/devicepolicy/ActiveAdmin.java
+++ b/services/devicepolicy/java/com/android/server/devicepolicy/ActiveAdmin.java
@@ -16,6 +16,7 @@
package com.android.server.devicepolicy;
+import static android.app.admin.DevicePolicyManager.PASSWORD_COMPLEXITY_NONE;
import static android.app.admin.DevicePolicyManager.PASSWORD_QUALITY_UNSPECIFIED;
import static org.xmlpull.v1.XmlPullParser.END_DOCUMENT;
@@ -130,6 +131,7 @@
private static final String TAG_ALWAYS_ON_VPN_PACKAGE = "vpn-package";
private static final String TAG_ALWAYS_ON_VPN_LOCKDOWN = "vpn-lockdown";
private static final String TAG_COMMON_CRITERIA_MODE = "common-criteria-mode";
+ private static final String TAG_PASSWORD_COMPLEXITY = "password-complexity";
private static final String ATTR_VALUE = "value";
private static final String ATTR_LAST_NETWORK_LOGGING_NOTIFICATION = "last-notification";
private static final String ATTR_NUM_NETWORK_LOGGING_NOTIFICATIONS = "num-notifications";
@@ -142,6 +144,9 @@
@NonNull
PasswordPolicy mPasswordPolicy = new PasswordPolicy();
+ @DevicePolicyManager.PasswordComplexity
+ int mPasswordComplexity = PASSWORD_COMPLEXITY_NONE;
+
@Nullable
FactoryResetProtectionPolicy mFactoryResetProtectionPolicy = null;
@@ -518,6 +523,10 @@
if (mCommonCriteriaMode) {
writeAttributeValueToXml(out, TAG_COMMON_CRITERIA_MODE, mCommonCriteriaMode);
}
+
+ if (mPasswordComplexity != PASSWORD_COMPLEXITY_NONE) {
+ writeAttributeValueToXml(out, TAG_PASSWORD_COMPLEXITY, mPasswordComplexity);
+ }
}
void writeTextToXml(XmlSerializer out, String tag, String text) throws IOException {
@@ -777,6 +786,8 @@
} else if (TAG_COMMON_CRITERIA_MODE.equals(tag)) {
mCommonCriteriaMode = Boolean.parseBoolean(
parser.getAttributeValue(null, ATTR_VALUE));
+ } else if (TAG_PASSWORD_COMPLEXITY.equals(tag)) {
+ mPasswordComplexity = Integer.parseInt(parser.getAttributeValue(null, ATTR_VALUE));
} else {
Slog.w(DevicePolicyManagerService.LOG_TAG, "Unknown admin tag: " + tag);
XmlUtils.skipCurrentTag(parser);
@@ -1112,5 +1123,8 @@
pw.print("mCommonCriteriaMode=");
pw.println(mCommonCriteriaMode);
+
+ pw.print("mPasswordComplexity=");
+ pw.println(mPasswordComplexity);
}
}
diff --git a/services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java b/services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java
index 3db138c..9d634bc 100644
--- a/services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java
+++ b/services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java
@@ -60,6 +60,9 @@
import static android.app.admin.DevicePolicyManager.LOCK_TASK_FEATURE_NOTIFICATIONS;
import static android.app.admin.DevicePolicyManager.LOCK_TASK_FEATURE_OVERVIEW;
import static android.app.admin.DevicePolicyManager.NON_ORG_OWNED_PROFILE_KEYGUARD_FEATURES_AFFECT_OWNER;
+import static android.app.admin.DevicePolicyManager.PASSWORD_COMPLEXITY_HIGH;
+import static android.app.admin.DevicePolicyManager.PASSWORD_COMPLEXITY_LOW;
+import static android.app.admin.DevicePolicyManager.PASSWORD_COMPLEXITY_MEDIUM;
import static android.app.admin.DevicePolicyManager.PASSWORD_COMPLEXITY_NONE;
import static android.app.admin.DevicePolicyManager.PASSWORD_QUALITY_ALPHABETIC;
import static android.app.admin.DevicePolicyManager.PASSWORD_QUALITY_ALPHANUMERIC;
@@ -3432,6 +3435,7 @@
final PasswordPolicy passwordPolicy = ap.mPasswordPolicy;
if (passwordPolicy.quality != quality) {
passwordPolicy.quality = quality;
+ ap.mPasswordComplexity = PASSWORD_COMPLEXITY_NONE;
resetInactivePasswordRequirementsIfRPlus(userId, ap);
updatePasswordValidityCheckpointLocked(userId, parent);
updatePasswordQualityCacheForUserGroup(userId);
@@ -3660,6 +3664,10 @@
private void ensureMinimumQuality(
int userId, ActiveAdmin admin, int minimumQuality, String operation) {
mInjector.binderWithCleanCallingIdentity(() -> {
+ // This check will also take care of the case where the password requirements
+ // are specified as complexity rather than quality: When a password complexity
+ // is set, the quality is reset to "unspecified" which will be below any value
+ // of minimumQuality.
if (admin.mPasswordPolicy.quality < minimumQuality
&& passwordQualityInvocationOrderCheckEnabled(admin.info.getPackageName(),
userId)) {
@@ -4257,6 +4265,8 @@
for (ActiveAdmin admin : admins) {
adminMetrics.add(admin.mPasswordPolicy.getMinMetrics());
}
+ //TODO: Take complexity into account, would need to take complexity from all admins
+ //in the admins list.
return PasswordMetrics.validatePasswordMetrics(PasswordMetrics.merge(adminMetrics),
PASSWORD_COMPLEXITY_NONE, false, metrics).isEmpty();
}
@@ -4291,31 +4301,34 @@
*/
private boolean isPasswordSufficientForUserWithoutCheckpointLocked(
@NonNull PasswordMetrics metrics, @UserIdInt int userId, boolean parent) {
+ final int complexity = getEffectivePasswordComplexityRequirementLocked(userId, parent);
PasswordMetrics minMetrics = getPasswordMinimumMetrics(userId, parent);
final List<PasswordValidationError> passwordValidationErrors =
PasswordMetrics.validatePasswordMetrics(
- minMetrics, PASSWORD_COMPLEXITY_NONE, false, metrics);
+ minMetrics, complexity, false, metrics);
return passwordValidationErrors.isEmpty();
}
@Override
@PasswordComplexity
public int getPasswordComplexity(boolean parent) {
+ final CallerIdentity caller = getNonPrivilegedOrAdminCallerIdentity(null);
DevicePolicyEventLogger
.createEvent(DevicePolicyEnums.GET_USER_PASSWORD_COMPLEXITY_LEVEL)
.setStrings(parent ? CALLED_FROM_PARENT : NOT_CALLED_FROM_PARENT,
mInjector.getPackageManager().getPackagesForUid(
mInjector.binderGetCallingUid()))
.write();
- final CallerIdentity caller = getCallerIdentity();
Preconditions.checkCallAuthorization(!parent || (isDeviceOwner(caller)
|| isProfileOwner(caller) || isSystemUid(caller)),
"Only profile owner, device owner and system may call this method.");
enforceUserUnlocked(caller.getUserId());
- mContext.enforceCallingOrSelfPermission(
- REQUEST_PASSWORD_COMPLEXITY,
- "Must have " + REQUEST_PASSWORD_COMPLEXITY + " permission.");
+ Preconditions.checkCallAuthorization(
+ hasCallingOrSelfPermission(REQUEST_PASSWORD_COMPLEXITY)
+ || isDeviceOwner(caller) || isProfileOwner(caller),
+ "Must have " + REQUEST_PASSWORD_COMPLEXITY
+ + " permission, or be a profile owner or device owner.");
synchronized (getLockObject()) {
final int credentialOwner = getCredentialOwner(caller.getUserId(), parent);
@@ -4325,6 +4338,75 @@
}
@Override
+ public void setRequiredPasswordComplexity(int passwordComplexity, boolean calledOnParent) {
+ if (!mHasFeature) {
+ return;
+ }
+ final Set<Integer> allowedModes = Set.of(PASSWORD_COMPLEXITY_NONE, PASSWORD_COMPLEXITY_LOW,
+ PASSWORD_COMPLEXITY_MEDIUM, PASSWORD_COMPLEXITY_HIGH);
+ Preconditions.checkArgument(allowedModes.contains(passwordComplexity),
+ "Provided complexity is not one of the allowed values.");
+
+ final CallerIdentity caller = getAdminCallerIdentity(null);
+ Preconditions.checkCallAuthorization(isDeviceOwner(caller) || isProfileOwner(caller));
+ Preconditions.checkArgument(!calledOnParent || isProfileOwner(caller));
+
+ synchronized (getLockObject()) {
+ final ActiveAdmin admin = getParentOfAdminIfRequired(
+ getProfileOwnerOrDeviceOwnerLocked(caller), calledOnParent);
+ if (admin.mPasswordComplexity != passwordComplexity) {
+ mInjector.binderWithCleanCallingIdentity(() -> {
+ admin.mPasswordComplexity = passwordComplexity;
+ // Reset the password policy.
+ admin.mPasswordPolicy = new PasswordPolicy();
+ updatePasswordValidityCheckpointLocked(caller.getUserId(), calledOnParent);
+ updatePasswordQualityCacheForUserGroup(caller.getUserId());
+ saveSettingsLocked(caller.getUserId());
+ //TODO: Log password complexity change if security logging is enabled.
+ });
+ }
+ }
+ //TODO: Log metrics.
+ }
+
+ private int getEffectivePasswordComplexityRequirementLocked(@UserIdInt int userHandle,
+ boolean parent) {
+ ensureLocked();
+ List<ActiveAdmin> admins = getActiveAdminsForLockscreenPoliciesLocked(
+ getProfileParentUserIfRequested(userHandle, parent));
+ int maxRequiredComplexity = PASSWORD_COMPLEXITY_NONE;
+ for (ActiveAdmin admin : admins) {
+ final ComponentName adminComponent = admin.info.getComponent();
+ final int adminUser = admin.getUserHandle().getIdentifier();
+ // Password complexity is only taken into account from DO/PO
+ if (isDeviceOwner(adminComponent, adminUser)
+ || isProfileOwner(adminComponent, adminUser)) {
+ maxRequiredComplexity = Math.max(maxRequiredComplexity, admin.mPasswordComplexity);
+ }
+ }
+ return maxRequiredComplexity;
+ }
+
+ @Override
+ public int getRequiredPasswordComplexity(boolean calledOnParent) {
+ if (!mHasFeature) {
+ return PASSWORD_COMPLEXITY_NONE;
+ }
+
+ final CallerIdentity caller = getAdminCallerIdentity(null);
+ Preconditions.checkCallAuthorization(
+ isDeviceOwner(caller) || isProfileOwner(caller));
+
+ Preconditions.checkArgument(!calledOnParent || hasProfileOwner(caller.getUserId()));
+
+ synchronized (getLockObject()) {
+ final ActiveAdmin requiredAdmin = getParentOfAdminIfRequired(
+ getDeviceOrProfileOwnerAdminLocked(caller.getUserId()), calledOnParent);
+ return requiredAdmin.mPasswordComplexity;
+ }
+ }
+
+ @Override
public int getCurrentFailedPasswordAttempts(int userHandle, boolean parent) {
if (!mLockPatternUtils.hasSecureLockScreen()) {
return 0;
@@ -4514,15 +4596,17 @@
synchronized (getLockObject()) {
final PasswordMetrics minMetrics = getPasswordMinimumMetrics(userHandle);
final List<PasswordValidationError> validationErrors;
+ final int complexity =
+ getEffectivePasswordComplexityRequirementLocked(userHandle, false);
// TODO: Consider changing validation API to take LockscreenCredential.
if (password.isEmpty()) {
validationErrors = PasswordMetrics.validatePasswordMetrics(
- minMetrics, PASSWORD_COMPLEXITY_NONE, false /* isPin */,
+ minMetrics, complexity, false /* isPin */,
new PasswordMetrics(CREDENTIAL_TYPE_NONE));
} else {
// TODO(b/120484642): remove getBytes() below
validationErrors = PasswordMetrics.validatePassword(
- minMetrics, PASSWORD_COMPLEXITY_NONE, false, password.getBytes());
+ minMetrics, complexity, false, password.getBytes());
}
if (!validationErrors.isEmpty()) {
@@ -7509,6 +7593,10 @@
}
}
+ private int getDeviceOwnerUserIdUncheckedLocked() {
+ return mOwners.hasDeviceOwner() ? mOwners.getDeviceOwnerUserId() : UserHandle.USER_NULL;
+ }
+
@Override
public int getDeviceOwnerUserId() {
if (!mHasFeature) {
@@ -7517,7 +7605,7 @@
Preconditions.checkCallAuthorization(canManageUsers(getCallerIdentity()));
synchronized (getLockObject()) {
- return mOwners.hasDeviceOwner() ? mOwners.getDeviceOwnerUserId() : UserHandle.USER_NULL;
+ return getDeviceOwnerUserIdUncheckedLocked();
}
}
@@ -8058,7 +8146,7 @@
*/
private @Nullable ActiveAdmin getDeviceOrProfileOwnerAdminLocked(int userHandle) {
ActiveAdmin admin = getProfileOwnerAdminLocked(userHandle);
- if (admin == null && getDeviceOwnerUserId() == userHandle) {
+ if (admin == null && getDeviceOwnerUserIdUncheckedLocked() == userHandle) {
admin = getDeviceOwnerAdminLocked();
}
return admin;
diff --git a/services/tests/inprocesstests/Android.bp b/services/tests/inprocesstests/Android.bp
new file mode 100644
index 0000000..6dd059f
--- /dev/null
+++ b/services/tests/inprocesstests/Android.bp
@@ -0,0 +1,12 @@
+android_test {
+ name: "FrameworksInProcessTests",
+ srcs: ["src/**/*.java"],
+ static_libs: [
+ "androidx.test.core",
+ "androidx.test.rules",
+ "services.core",
+ "truth-prebuilt",
+ "platform-test-annotations",
+ ],
+ test_suites: ["general-tests"],
+}
diff --git a/services/tests/inprocesstests/AndroidManifest.xml b/services/tests/inprocesstests/AndroidManifest.xml
new file mode 100644
index 0000000..efb4a53
--- /dev/null
+++ b/services/tests/inprocesstests/AndroidManifest.xml
@@ -0,0 +1,30 @@
+<!--
+ ~ Copyright (C) 2020 The Android Open Source Project
+ ~
+ ~ Licensed under the Apache License, Version 2.0 (the "License");
+ ~ you may not use this file except in compliance with the License.
+ ~ You may obtain a copy of the License at
+ ~
+ ~ http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing, software
+ ~ distributed under the License is distributed on an "AS IS" BASIS,
+ ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ ~ See the License for the specific language governing permissions and
+ ~ limitations under the License.
+ -->
+
+<manifest xmlns:android="http://schemas.android.com/apk/res/android"
+ package="com.android.frameworks.inprocesstests" >
+
+ <uses-sdk android:minSdkVersion="28" android:targetSdkVersion="28" />
+
+ <application>
+ <uses-library android:name="android.test.runner" />
+ </application>
+
+ <instrumentation android:name="androidx.test.runner.AndroidJUnitRunner"
+ android:targetPackage="android"
+ android:label="Frameworks In-Process Tests"/>
+
+</manifest>
diff --git a/services/tests/inprocesstests/AndroidTest.xml b/services/tests/inprocesstests/AndroidTest.xml
new file mode 100644
index 0000000..89abe3c
--- /dev/null
+++ b/services/tests/inprocesstests/AndroidTest.xml
@@ -0,0 +1,36 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ ~ Copyright (C) 2020 The Android Open Source Project
+ ~
+ ~ Licensed under the Apache License, Version 2.0 (the "License");
+ ~ you may not use this file except in compliance with the License.
+ ~ You may obtain a copy of the License at
+ ~
+ ~ http://www.apache.org/licenses/LICENSE-2.0
+ ~
+ ~ Unless required by applicable law or agreed to in writing, software
+ ~ distributed under the License is distributed on an "AS IS" BASIS,
+ ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ ~ See the License for the specific language governing permissions and
+ ~ limitations under the License.
+ -->
+<configuration description="Runs frameworks in-process tests">
+ <option name="test-suite-tag" value="apct" />
+ <option name="test-suite-tag" value="apct-instrumentation" />
+
+ <target_preparer class="com.android.tradefed.targetprep.suite.SuiteApkInstaller">
+ <option name="cleanup-apks" value="true"/>
+ <option name="test-file-name" value="FrameworksInProcessTests.apk"/>
+ </target_preparer>
+
+ <!-- Restart to clear test code from system server -->
+ <target_preparer class="com.android.tradefed.targetprep.RunCommandTargetPreparer">
+ <option name="teardown-command" value="am restart" />
+ </target_preparer>
+
+ <test class="com.android.tradefed.testtype.AndroidJUnitTest">
+ <option name="package" value="com.android.frameworks.inprocesstests"/>
+ <option name="runner" value="androidx.test.runner.AndroidJUnitRunner" />
+ <option name="restart" value="false" />
+ </test>
+</configuration>
diff --git a/services/tests/inprocesstests/src/com/android/frameworks/inprocesstests/InstrumentSystemServerTest.java b/services/tests/inprocesstests/src/com/android/frameworks/inprocesstests/InstrumentSystemServerTest.java
new file mode 100644
index 0000000..47fc73f
--- /dev/null
+++ b/services/tests/inprocesstests/src/com/android/frameworks/inprocesstests/InstrumentSystemServerTest.java
@@ -0,0 +1,52 @@
+/*
+ * Copyright (C) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package com.android.frameworks.inprocesstests;
+
+import static com.google.common.truth.Truth.assertThat;
+
+import android.os.Process;
+
+import androidx.test.platform.app.InstrumentationRegistry;
+
+import org.junit.Test;
+
+import java.io.BufferedReader;
+import java.io.FileReader;
+
+public class InstrumentSystemServerTest {
+
+ private static final String TAG = "InstrumentSystemServerTest";
+
+ @Test
+ public void testCodeIsRunningInSystemServer() throws Exception {
+ assertThat(InstrumentationRegistry.getInstrumentation().getTargetContext().getPackageName())
+ .isEqualTo("android");
+ assertThat(Process.myUid()).isEqualTo(Process.SYSTEM_UID);
+ assertThat(readCmdLine()).isEqualTo("system_server");
+ }
+
+ private static String readCmdLine() throws Exception {
+ BufferedReader in = null;
+ try {
+ in = new BufferedReader(new FileReader("/proc/self/cmdline"));
+ return in.readLine().trim();
+ } finally {
+ in.close();
+ }
+ }
+
+}
diff --git a/services/tests/servicestests/src/com/android/server/devicepolicy/DevicePolicyManagerTest.java b/services/tests/servicestests/src/com/android/server/devicepolicy/DevicePolicyManagerTest.java
index 77e1676..c0c82d5 100644
--- a/services/tests/servicestests/src/com/android/server/devicepolicy/DevicePolicyManagerTest.java
+++ b/services/tests/servicestests/src/com/android/server/devicepolicy/DevicePolicyManagerTest.java
@@ -25,6 +25,7 @@
import static android.app.admin.DevicePolicyManager.ID_TYPE_MEID;
import static android.app.admin.DevicePolicyManager.ID_TYPE_SERIAL;
import static android.app.admin.DevicePolicyManager.PASSWORD_COMPLEXITY_HIGH;
+import static android.app.admin.DevicePolicyManager.PASSWORD_COMPLEXITY_LOW;
import static android.app.admin.DevicePolicyManager.PASSWORD_COMPLEXITY_MEDIUM;
import static android.app.admin.DevicePolicyManager.PASSWORD_COMPLEXITY_NONE;
import static android.app.admin.DevicePolicyManager.WIPE_EUICC;
@@ -6690,6 +6691,140 @@
.isEqualTo(DevicePolicyManager.PERSONAL_APPS_SUSPENDED_PROFILE_TIMEOUT);
}
+ @Test
+ public void testSetRequiredPasswordComplexity_UnauthorizedCallersOnDO() throws Exception {
+ mContext.binder.callingUid = DpmMockContext.CALLER_SYSTEM_USER_UID;
+ setupDeviceOwner();
+ // DO must be able to set it.
+ dpm.setRequiredPasswordComplexity(PASSWORD_COMPLEXITY_LOW);
+ // But not on the parent DPM.
+ assertExpectException(IllegalArgumentException.class, null,
+ () -> parentDpm.setRequiredPasswordComplexity(PASSWORD_COMPLEXITY_LOW));
+ // Another package must not be allowed to set password complexity.
+ mContext.binder.callingUid = DpmMockContext.ANOTHER_UID;
+ assertExpectException(SecurityException.class, null,
+ () -> dpm.setRequiredPasswordComplexity(PASSWORD_COMPLEXITY_LOW));
+ }
+
+ @Test
+ public void testSetRequiredPasswordComplexity_UnauthorizedCallersOnPO() throws Exception {
+ mContext.binder.callingUid = DpmMockContext.CALLER_UID;
+ setupProfileOwner();
+ // PO must be able to set it.
+ dpm.setRequiredPasswordComplexity(PASSWORD_COMPLEXITY_LOW);
+ // And on the parent profile DPM instance.
+ parentDpm.setRequiredPasswordComplexity(PASSWORD_COMPLEXITY_LOW);
+ // Another package must not be allowed to set password complexity.
+ mContext.binder.callingUid = DpmMockContext.ANOTHER_UID;
+ assertExpectException(SecurityException.class, null,
+ () -> dpm.setRequiredPasswordComplexity(PASSWORD_COMPLEXITY_LOW));
+ }
+
+ @Test
+ public void testSetRequiredPasswordComplexity_validValuesOnly() throws Exception {
+ mContext.binder.callingUid = DpmMockContext.CALLER_UID;
+ setupProfileOwner();
+
+ // Cannot set value other than password_complexity none/low/medium/high
+ assertExpectException(IllegalArgumentException.class, null, () ->
+ dpm.setRequiredPasswordComplexity(-1));
+ assertExpectException(IllegalArgumentException.class, null, () ->
+ dpm.setRequiredPasswordComplexity(7));
+ assertExpectException(IllegalArgumentException.class, null, () ->
+ dpm.setRequiredPasswordComplexity(PASSWORD_COMPLEXITY_HIGH + 1));
+
+ final Set<Integer> allowedModes = Set.of(PASSWORD_COMPLEXITY_NONE, PASSWORD_COMPLEXITY_LOW,
+ PASSWORD_COMPLEXITY_MEDIUM, PASSWORD_COMPLEXITY_HIGH);
+ for (int complexity : allowedModes) {
+ // Ensure exception is not thrown.
+ dpm.setRequiredPasswordComplexity(complexity);
+ }
+ }
+
+ @Test
+ public void testSetRequiredPasswordComplexity_setAndGet() throws Exception {
+ mContext.binder.callingUid = DpmMockContext.CALLER_UID;
+ setupProfileOwner();
+
+ final Set<Integer> allowedModes = Set.of(PASSWORD_COMPLEXITY_NONE, PASSWORD_COMPLEXITY_LOW,
+ PASSWORD_COMPLEXITY_MEDIUM, PASSWORD_COMPLEXITY_HIGH);
+ for (int complexity : allowedModes) {
+ dpm.setRequiredPasswordComplexity(complexity);
+ assertThat(dpm.getRequiredPasswordComplexity()).isEqualTo(complexity);
+ }
+ }
+
+ @Test
+ public void testSetRequiredPasswordComplexityOnParent_setAndGet() throws Exception {
+ final int managedProfileUserId = 15;
+ final int managedProfileAdminUid = UserHandle.getUid(managedProfileUserId, 19436);
+
+ addManagedProfile(admin1, managedProfileAdminUid, admin1);
+ mContext.binder.callingUid = managedProfileAdminUid;
+
+ final Set<Integer> allowedModes = Set.of(PASSWORD_COMPLEXITY_NONE, PASSWORD_COMPLEXITY_LOW,
+ PASSWORD_COMPLEXITY_MEDIUM, PASSWORD_COMPLEXITY_HIGH);
+ for (int complexity : allowedModes) {
+ dpm.getParentProfileInstance(admin1).setRequiredPasswordComplexity(complexity);
+ assertThat(dpm.getParentProfileInstance(admin1).getRequiredPasswordComplexity())
+ .isEqualTo(complexity);
+ assertThat(dpm.getRequiredPasswordComplexity()).isEqualTo(PASSWORD_COMPLEXITY_NONE);
+ }
+ }
+
+ @Test
+ public void testSetRequiredPasswordComplexity_isSufficient() throws Exception {
+ mContext.binder.callingUid = DpmMockContext.CALLER_SYSTEM_USER_UID;
+ mContext.packageName = admin1.getPackageName();
+ setupDeviceOwner();
+
+ dpm.setRequiredPasswordComplexity(PASSWORD_COMPLEXITY_HIGH);
+ assertThat(dpm.getRequiredPasswordComplexity()).isEqualTo(PASSWORD_COMPLEXITY_HIGH);
+ when(getServices().packageManager.getPackagesForUid(
+ DpmMockContext.CALLER_SYSTEM_USER_UID)).thenReturn(new String[0]);
+ mServiceContext.permissions.add(permission.REQUEST_PASSWORD_COMPLEXITY);
+ assertThat(dpm.getPasswordComplexity()).isEqualTo(PASSWORD_COMPLEXITY_NONE);
+
+ reset(mContext.spiedContext);
+ PasswordMetrics passwordMetricsNoSymbols = computeForPassword("1234".getBytes());
+ setActivePasswordState(passwordMetricsNoSymbols);
+ assertThat(dpm.getPasswordComplexity()).isEqualTo(PASSWORD_COMPLEXITY_LOW);
+ assertThat(dpm.isActivePasswordSufficient()).isFalse();
+
+ reset(mContext.spiedContext);
+ passwordMetricsNoSymbols = computeForPassword("84125312943a".getBytes());
+ setActivePasswordState(passwordMetricsNoSymbols);
+ assertThat(dpm.getPasswordComplexity()).isEqualTo(PASSWORD_COMPLEXITY_HIGH);
+ // using isActivePasswordSufficient
+ assertThat(dpm.isActivePasswordSufficient()).isTrue();
+ }
+
+ @Test
+ public void testSetRequiredPasswordComplexity_resetBySettingQuality() throws Exception {
+ mContext.binder.callingUid = DpmMockContext.CALLER_UID;
+ setupProfileOwner();
+
+ // Test that calling setPasswordQuality resets complexity to none.
+ dpm.setRequiredPasswordComplexity(PASSWORD_COMPLEXITY_HIGH);
+ assertThat(dpm.getRequiredPasswordComplexity()).isEqualTo(PASSWORD_COMPLEXITY_HIGH);
+ dpm.setPasswordQuality(admin1, DevicePolicyManager.PASSWORD_QUALITY_NUMERIC_COMPLEX);
+ assertThat(dpm.getRequiredPasswordComplexity()).isEqualTo(PASSWORD_COMPLEXITY_NONE);
+ }
+
+ @Test
+ public void testSetRequiredPasswordComplexity_overridesQuality() throws Exception {
+ mContext.binder.callingUid = DpmMockContext.CALLER_UID;
+ setupProfileOwner();
+
+ // Test that calling setRequiredPasswordComplexity resets password quality.
+ dpm.setPasswordQuality(admin1, DevicePolicyManager.PASSWORD_QUALITY_NUMERIC_COMPLEX);
+ assertThat(dpm.getPasswordQuality(admin1)).isEqualTo(
+ DevicePolicyManager.PASSWORD_QUALITY_NUMERIC_COMPLEX);
+ dpm.setRequiredPasswordComplexity(PASSWORD_COMPLEXITY_HIGH);
+ assertThat(dpm.getPasswordQuality(admin1)).isEqualTo(
+ DevicePolicyManager.PASSWORD_QUALITY_UNSPECIFIED);
+ }
+
private void setUserUnlocked(int userHandle, boolean unlocked) {
when(getServices().userManager.isUserUnlocked(eq(userHandle))).thenReturn(unlocked);
}
diff --git a/services/tests/uiservicestests/src/com/android/server/notification/NotificationManagerServiceTest.java b/services/tests/uiservicestests/src/com/android/server/notification/NotificationManagerServiceTest.java
index 87aaba2..70d3f98 100755
--- a/services/tests/uiservicestests/src/com/android/server/notification/NotificationManagerServiceTest.java
+++ b/services/tests/uiservicestests/src/com/android/server/notification/NotificationManagerServiceTest.java
@@ -4923,6 +4923,32 @@
}
@Test
+ public void testDontCallShowToastAgainOnTheSameCustomToast() throws Exception {
+ final String testPackage = "testPackageName";
+ assertEquals(0, mService.mToastQueue.size());
+ mService.isSystemUid = false;
+
+ // package is not suspended
+ when(mPackageManager.isPackageSuspendedForUser(testPackage, UserHandle.getUserId(mUid)))
+ .thenReturn(false);
+
+ setAppInForegroundForToasts(mUid, true);
+
+ Binder token = new Binder();
+ ITransientNotification callback = mock(ITransientNotification.class);
+ INotificationManager nmService = (INotificationManager) mService.mService;
+
+ // first time trying to show the toast, showToast gets called
+ nmService.enqueueToast(testPackage, token, callback, 2000, 0);
+ verify(callback, times(1)).show(any());
+
+ // second time trying to show the same toast, showToast isn't called again (total number of
+ // invocations stays at one)
+ nmService.enqueueToast(testPackage, token, callback, 2000, 0);
+ verify(callback, times(1)).show(any());
+ }
+
+ @Test
public void testAllowForegroundTextToasts() throws Exception {
final String testPackage = "testPackageName";
assertEquals(0, mService.mToastQueue.size());
@@ -4959,6 +4985,33 @@
}
@Test
+ public void testDontCallShowToastAgainOnTheSameTextToast() throws Exception {
+ final String testPackage = "testPackageName";
+ assertEquals(0, mService.mToastQueue.size());
+ mService.isSystemUid = false;
+
+ // package is not suspended
+ when(mPackageManager.isPackageSuspendedForUser(testPackage, UserHandle.getUserId(mUid)))
+ .thenReturn(false);
+
+ setAppInForegroundForToasts(mUid, true);
+
+ Binder token = new Binder();
+ INotificationManager nmService = (INotificationManager) mService.mService;
+
+ // first time trying to show the toast, showToast gets called
+ nmService.enqueueTextToast(testPackage, token, "Text", 2000, 0, null);
+ verify(mStatusBar, times(1))
+ .showToast(anyInt(), any(), any(), any(), any(), anyInt(), any());
+
+ // second time trying to show the same toast, showToast isn't called again (total number of
+ // invocations stays at one)
+ nmService.enqueueTextToast(testPackage, token, "Text", 2000, 0, null);
+ verify(mStatusBar, times(1))
+ .showToast(anyInt(), any(), any(), any(), any(), anyInt(), any());
+ }
+
+ @Test
public void backgroundSystemCustomToast_callsSetProcessImportantAsForegroundForToast() throws
Exception {
final String testPackage = "testPackageName";
diff --git a/services/tests/wmtests/src/com/android/server/wm/ActivityStarterTests.java b/services/tests/wmtests/src/com/android/server/wm/ActivityStarterTests.java
index c05eb8e..5a6e556 100644
--- a/services/tests/wmtests/src/com/android/server/wm/ActivityStarterTests.java
+++ b/services/tests/wmtests/src/com/android/server/wm/ActivityStarterTests.java
@@ -31,12 +31,15 @@
import static android.app.ActivityManager.START_TASK_TO_FRONT;
import static android.app.WindowConfiguration.ACTIVITY_TYPE_STANDARD;
import static android.app.WindowConfiguration.WINDOWING_MODE_FULLSCREEN;
+import static android.app.WindowConfiguration.WINDOWING_MODE_PINNED;
import static android.app.WindowConfiguration.WINDOWING_MODE_SPLIT_SCREEN_PRIMARY;
import static android.app.WindowConfiguration.WINDOWING_MODE_SPLIT_SCREEN_SECONDARY;
import static android.content.Intent.FLAG_ACTIVITY_LAUNCH_ADJACENT;
import static android.content.Intent.FLAG_ACTIVITY_NEW_TASK;
import static android.content.Intent.FLAG_ACTIVITY_RESET_TASK_IF_NEEDED;
import static android.content.Intent.FLAG_ACTIVITY_SINGLE_TOP;
+import static android.content.pm.ActivityInfo.LAUNCH_MULTIPLE;
+import static android.content.pm.ActivityInfo.LAUNCH_SINGLE_INSTANCE;
import static android.content.pm.ActivityInfo.LAUNCH_SINGLE_TASK;
import static com.android.dx.mockito.inline.extended.ExtendedMockito.clearInvocations;
@@ -304,7 +307,12 @@
}
private ActivityStarter prepareStarter(@Intent.Flags int launchFlags) {
- return prepareStarter(launchFlags, true /* mockGetLaunchStack */);
+ return prepareStarter(launchFlags, true /* mockGetLaunchStack */, LAUNCH_MULTIPLE);
+ }
+
+ private ActivityStarter prepareStarter(@Intent.Flags int launchFlags,
+ boolean mockGetLaunchStack) {
+ return prepareStarter(launchFlags, mockGetLaunchStack, LAUNCH_MULTIPLE);
}
/**
@@ -318,7 +326,7 @@
* @return A {@link ActivityStarter} with default setup.
*/
private ActivityStarter prepareStarter(@Intent.Flags int launchFlags,
- boolean mockGetLaunchStack) {
+ boolean mockGetLaunchStack, int launchMode) {
// always allow test to start activity.
doReturn(true).when(mSupervisor).checkStartAnyActivityPermission(
any(), any(), any(), anyInt(), anyInt(), anyInt(), any(), any(),
@@ -362,6 +370,7 @@
info.applicationInfo = new ApplicationInfo();
info.applicationInfo.packageName = ActivityBuilder.getDefaultComponent().getPackageName();
+ info.launchMode = launchMode;
return new ActivityStarter(mController, mAtm,
mAtm.mStackSupervisor, mock(ActivityStartInterceptor.class))
@@ -416,7 +425,8 @@
@Test
public void testSplitScreenDeliverToTop() {
final ActivityStarter starter = prepareStarter(
- FLAG_ACTIVITY_RESET_TASK_IF_NEEDED | FLAG_ACTIVITY_SINGLE_TOP, false);
+ FLAG_ACTIVITY_RESET_TASK_IF_NEEDED | FLAG_ACTIVITY_SINGLE_TOP,
+ false /* mockGetLaunchStack */);
final ActivityRecord splitPrimaryFocusActivity =
new ActivityBuilder(mAtm).setCreateTask(true).build();
final ActivityRecord splitSecondReusableActivity =
@@ -584,6 +594,12 @@
UNIMPORTANT_UID, false, PROCESS_STATE_TOP + 1,
UNIMPORTANT_UID2, false, PROCESS_STATE_TOP + 1,
true, false, false, false, false);
+ runAndVerifyBackgroundActivityStartsSubtest(
+ "disallowed_pinned_singleinstance_aborted", true,
+ UNIMPORTANT_UID, false, PROCESS_STATE_TOP + 1,
+ UNIMPORTANT_UID2, false, PROCESS_STATE_TOP + 1,
+ false, false, false, false, false, true);
+
}
/**
@@ -647,11 +663,28 @@
boolean callerIsTempAllowed,
boolean callerIsInstrumentingWithBackgroundActivityStartPrivileges,
boolean isCallingUidDeviceOwner) {
+ runAndVerifyBackgroundActivityStartsSubtest(name, shouldHaveAborted, callingUid,
+ callingUidHasVisibleWindow, callingUidProcState, realCallingUid,
+ realCallingUidHasVisibleWindow, realCallingUidProcState,
+ hasForegroundActivities, callerIsRecents, callerIsTempAllowed,
+ callerIsInstrumentingWithBackgroundActivityStartPrivileges,
+ isCallingUidDeviceOwner, false /* isPinnedSingleInstance */);
+ }
+
+ private void runAndVerifyBackgroundActivityStartsSubtest(String name, boolean shouldHaveAborted,
+ int callingUid, boolean callingUidHasVisibleWindow, int callingUidProcState,
+ int realCallingUid, boolean realCallingUidHasVisibleWindow, int realCallingUidProcState,
+ boolean hasForegroundActivities, boolean callerIsRecents,
+ boolean callerIsTempAllowed,
+ boolean callerIsInstrumentingWithBackgroundActivityStartPrivileges,
+ boolean isCallingUidDeviceOwner,
+ boolean isPinnedSingleInstance) {
// window visibility
doReturn(callingUidHasVisibleWindow).when(mAtm.mWindowManager.mRoot)
.isAnyNonToastWindowVisibleForUid(callingUid);
doReturn(realCallingUidHasVisibleWindow).when(mAtm.mWindowManager.mRoot)
.isAnyNonToastWindowVisibleForUid(realCallingUid);
+
// process importance
doReturn(callingUidProcState).when(mAtm).getUidState(callingUid);
doReturn(realCallingUidProcState).when(mAtm).getUidState(realCallingUid);
@@ -679,9 +712,20 @@
// callingUid is the device owner
doReturn(isCallingUidDeviceOwner).when(mAtm).isDeviceOwner(callingUid);
+ int launchMode = LAUNCH_MULTIPLE;
+ if (isPinnedSingleInstance) {
+ final ActivityRecord baseActivity =
+ new ActivityBuilder(mAtm).setCreateTask(true).build();
+ baseActivity.getRootTask()
+ .setWindowingMode(WINDOWING_MODE_PINNED);
+ doReturn(baseActivity).when(mRootWindowContainer).findTask(any(), any());
+ launchMode = LAUNCH_SINGLE_INSTANCE;
+ }
+
final ActivityOptions options = spy(ActivityOptions.makeBasic());
ActivityRecord[] outActivity = new ActivityRecord[1];
- ActivityStarter starter = prepareStarter(FLAG_ACTIVITY_NEW_TASK)
+ ActivityStarter starter = prepareStarter(
+ FLAG_ACTIVITY_NEW_TASK, true, launchMode)
.setCallingPackage("com.whatever.dude")
.setCaller(caller)
.setCallingUid(callingUid)
diff --git a/telecomm/java/android/telecom/Connection.java b/telecomm/java/android/telecom/Connection.java
index bbf34df..724a9e4 100644
--- a/telecomm/java/android/telecom/Connection.java
+++ b/telecomm/java/android/telecom/Connection.java
@@ -767,6 +767,19 @@
"android.telecom.extra.AUDIO_CODEC";
/**
+ * Float connection extra key used to store the audio codec bitrate in kbps for the current
+ * {@link Connection}.
+ */
+ public static final String EXTRA_AUDIO_CODEC_BITRATE_KBPS =
+ "android.telecom.extra.AUDIO_CODEC_BITRATE_KBPS";
+
+ /**
+ * Float connection extra key used to store the audio codec bandwidth in khz for the current
+ * {@link Connection}.
+ */
+ public static final String EXTRA_AUDIO_CODEC_BANDWIDTH_KHZ =
+ "android.telecom.extra.AUDIO_CODEC_BANDWIDTH_KHZ";
+ /**
* Connection event used to inform Telecom that it should play the on hold tone. This is used
* to play a tone when the peer puts the current call on hold. Sent to Telecom via
* {@link #sendConnectionEvent(String, Bundle)}.
diff --git a/telecomm/java/android/telecom/InCallService.java b/telecomm/java/android/telecom/InCallService.java
index 982e5f3..07de617 100644
--- a/telecomm/java/android/telecom/InCallService.java
+++ b/telecomm/java/android/telecom/InCallService.java
@@ -680,6 +680,7 @@
public static abstract class VideoCall {
/** @hide */
+ @SuppressWarnings("HiddenAbstractMethod")
public abstract void destroy();
/**
diff --git a/telecomm/java/android/telecom/TelecomManager.java b/telecomm/java/android/telecom/TelecomManager.java
index b335a90..5bba747 100644
--- a/telecomm/java/android/telecom/TelecomManager.java
+++ b/telecomm/java/android/telecom/TelecomManager.java
@@ -1238,7 +1238,7 @@
* @hide
*/
@SystemApi
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
@Deprecated
public List<PhoneAccountHandle> getPhoneAccountsForPackage() {
try {
@@ -1367,7 +1367,7 @@
* @hide
*/
@SystemApi
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
public void clearPhoneAccounts() {
clearAccounts();
}
@@ -1377,7 +1377,7 @@
* @hide
*/
@SystemApi
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
public void clearAccounts() {
try {
if (isServiceConnected()) {
@@ -1409,7 +1409,7 @@
* @hide
*/
@SystemApi
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
public ComponentName getDefaultPhoneApp() {
try {
if (isServiceConnected()) {
diff --git a/telephony/common/com/android/internal/telephony/CarrierAppUtils.java b/telephony/common/com/android/internal/telephony/CarrierAppUtils.java
index b92d410..7629163 100644
--- a/telephony/common/com/android/internal/telephony/CarrierAppUtils.java
+++ b/telephony/common/com/android/internal/telephony/CarrierAppUtils.java
@@ -33,6 +33,7 @@
import android.util.Log;
import com.android.internal.annotations.VisibleForTesting;
+import com.android.internal.telephony.util.TelephonyUtils;
import java.util.ArrayList;
import java.util.List;
@@ -316,7 +317,7 @@
String[] packageNames = new String[enabledCarrierPackages.size()];
enabledCarrierPackages.toArray(packageNames);
permissionManager.grantDefaultPermissionsToEnabledCarrierApps(packageNames,
- UserHandle.of(userId), Runnable::run, isSuccess -> { });
+ UserHandle.of(userId), TelephonyUtils.DIRECT_EXECUTOR, isSuccess -> { });
}
} catch (PackageManager.NameNotFoundException e) {
Log.w(TAG, "Could not reach PackageManager", e);
diff --git a/telephony/common/com/android/internal/telephony/util/TelephonyUtils.java b/telephony/common/com/android/internal/telephony/util/TelephonyUtils.java
index b8ca326..1252965 100644
--- a/telephony/common/com/android/internal/telephony/util/TelephonyUtils.java
+++ b/telephony/common/com/android/internal/telephony/util/TelephonyUtils.java
@@ -34,6 +34,7 @@
import java.util.Collections;
import java.util.List;
import java.util.concurrent.CountDownLatch;
+import java.util.concurrent.Executor;
import java.util.concurrent.TimeUnit;
import java.util.function.Supplier;
@@ -44,6 +45,8 @@
public static boolean IS_USER = "user".equals(android.os.Build.TYPE);
public static boolean IS_DEBUGGABLE = SystemProperties.getInt("ro.debuggable", 0) == 1;
+ public static final Executor DIRECT_EXECUTOR = Runnable::run;
+
/**
* Verify that caller holds {@link android.Manifest.permission#DUMP}.
*
diff --git a/telephony/java/android/telephony/CarrierConfigManager.java b/telephony/java/android/telephony/CarrierConfigManager.java
index b806313..902dc06 100644
--- a/telephony/java/android/telephony/CarrierConfigManager.java
+++ b/telephony/java/android/telephony/CarrierConfigManager.java
@@ -4792,7 +4792,7 @@
*/
@NonNull
@SystemApi
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
public static PersistableBundle getDefaultConfig() {
return new PersistableBundle(sDefaults);
}
diff --git a/telephony/java/android/telephony/CellLocation.java b/telephony/java/android/telephony/CellLocation.java
index 8f5ec36..e595002 100644
--- a/telephony/java/android/telephony/CellLocation.java
+++ b/telephony/java/android/telephony/CellLocation.java
@@ -98,12 +98,14 @@
/**
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage
public abstract void fillInNotifierBundle(Bundle bundle);
/**
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
@UnsupportedAppUsage
public abstract boolean isEmpty();
@@ -111,6 +113,7 @@
* Invalidate this object. The location area code and the cell id are set to -1.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
public abstract void setStateInvalid();
/**
diff --git a/telephony/java/android/telephony/ImsManager.java b/telephony/java/android/telephony/ImsManager.java
index 28feab2..42d7707 100644
--- a/telephony/java/android/telephony/ImsManager.java
+++ b/telephony/java/android/telephony/ImsManager.java
@@ -22,7 +22,12 @@
import android.annotation.SystemApi;
import android.annotation.SystemService;
import android.content.Context;
+import android.telephony.BinderCacheManager;
import android.telephony.SubscriptionManager;
+import android.telephony.TelephonyFrameworkInitializer;
+import android.telephony.ims.aidl.IImsRcsController;
+
+import com.android.internal.telephony.ITelephony;
/**
* Provides access to information about Telephony IMS services on the device.
@@ -30,8 +35,6 @@
@SystemService(Context.TELEPHONY_IMS_SERVICE)
public class ImsManager {
- private Context mContext;
-
/**
* <p>Broadcast Action: Indicates that a previously allowed IMS operation was rejected by the
* network due to the network returning a "forbidden" response. This may be due to a
@@ -87,6 +90,14 @@
public static final String EXTRA_WFC_REGISTRATION_FAILURE_MESSAGE =
"android.telephony.ims.extra.WFC_REGISTRATION_FAILURE_MESSAGE";
+ // Cache Telephony Binder interfaces, one cache per process.
+ private static final BinderCacheManager<ITelephony> sTelephonyCache =
+ new BinderCacheManager<>(ImsManager::getITelephonyInterface);
+ private static final BinderCacheManager<IImsRcsController> sRcsCache =
+ new BinderCacheManager<>(ImsManager::getIImsRcsControllerInterface);
+
+ private final Context mContext;
+
/**
* Use {@link Context#getSystemService(String)} to get an instance of this class.
* @hide
@@ -108,7 +119,7 @@
throw new IllegalArgumentException("Invalid subscription ID: " + subscriptionId);
}
- return new ImsRcsManager(mContext, subscriptionId);
+ return new ImsRcsManager(mContext, subscriptionId, sRcsCache);
}
/**
@@ -124,17 +135,19 @@
throw new IllegalArgumentException("Invalid subscription ID: " + subscriptionId);
}
- return new ImsMmTelManager(subscriptionId);
+ return new ImsMmTelManager(subscriptionId, sTelephonyCache);
}
/**
- * Create an instance of SipDelegateManager for the subscription id specified.
+ * Create an instance of {@link SipDelegateManager} for the subscription id specified.
* <p>
- * Used for RCS single registration cases, where an IMS application needs to forward SIP
- * traffic through the device's IMS service.
- * @param subscriptionId The ID of the subscription that this SipDelegateManager will use.
+ * Allows an IMS application to forward SIP traffic through the device's IMS service,
+ * which is used for cellular carriers that require the device to share a single IMS
+ * registration for both MMTEL and RCS features.
+ * @param subscriptionId The ID of the subscription that this {@link SipDelegateManager} will
+ * be bound to.
* @throws IllegalArgumentException if the subscription is invalid.
- * @return a SipDelegateManager instance for the specified subscription ID.
+ * @return a {@link SipDelegateManager} instance for the specified subscription ID.
* @hide
*/
@SystemApi
@@ -144,6 +157,22 @@
throw new IllegalArgumentException("Invalid subscription ID: " + subscriptionId);
}
- return new SipDelegateManager(mContext, subscriptionId);
+ return new SipDelegateManager(mContext, subscriptionId, sRcsCache);
+ }
+
+ private static IImsRcsController getIImsRcsControllerInterface() {
+ return IImsRcsController.Stub.asInterface(
+ TelephonyFrameworkInitializer
+ .getTelephonyServiceManager()
+ .getTelephonyImsServiceRegisterer()
+ .get());
+ }
+
+ private static ITelephony getITelephonyInterface() {
+ return ITelephony.Stub.asInterface(
+ TelephonyFrameworkInitializer
+ .getTelephonyServiceManager()
+ .getTelephonyServiceRegisterer()
+ .get());
}
}
diff --git a/telephony/java/android/telephony/TelephonyManager.java b/telephony/java/android/telephony/TelephonyManager.java
index 96f3ce0..4eacad3 100644
--- a/telephony/java/android/telephony/TelephonyManager.java
+++ b/telephony/java/android/telephony/TelephonyManager.java
@@ -4661,7 +4661,7 @@
* be implemented instead.
*/
@SystemApi
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
public void setVisualVoicemailEnabled(PhoneAccountHandle phoneAccountHandle, boolean enabled){
}
@@ -4676,7 +4676,7 @@
*/
@SystemApi
@RequiresPermission(android.Manifest.permission.READ_PHONE_STATE)
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
public boolean isVisualVoicemailEnabled(PhoneAccountHandle phoneAccountHandle){
return false;
}
@@ -4695,7 +4695,7 @@
* @hide
*/
@SystemApi
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
@Nullable
public Bundle getVisualVoicemailSettings(){
try {
@@ -8621,7 +8621,7 @@
/** @hide */
@SystemApi
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
public int checkCarrierPrivilegesForPackage(String pkgName) {
try {
ITelephony telephony = getITelephony();
@@ -8637,7 +8637,7 @@
/** @hide */
@SystemApi
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
public int checkCarrierPrivilegesForPackageAnyPhone(String pkgName) {
try {
ITelephony telephony = getITelephony();
@@ -8713,7 +8713,7 @@
/** @hide */
@SystemApi
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
public void dial(String number) {
try {
ITelephony telephony = getITelephony();
@@ -8772,7 +8772,7 @@
*/
@Deprecated
@SystemApi
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
public void silenceRinger() {
// No-op
}
diff --git a/telephony/java/android/telephony/ims/DelegateMessageCallback.java b/telephony/java/android/telephony/ims/DelegateMessageCallback.java
new file mode 100644
index 0000000..beec4a6
--- /dev/null
+++ b/telephony/java/android/telephony/ims/DelegateMessageCallback.java
@@ -0,0 +1,59 @@
+/*
+ * Copyright (C) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package android.telephony.ims;
+
+import android.annotation.NonNull;
+import android.telephony.ims.stub.SipDelegate;
+
+/**
+ * Callback interface provided to the SipTransport implementation to notify a remote application of
+ * the following:
+ * <ul>
+ * <li>A new incoming SIP message associated with the feature tags the SipDelegate registered
+ * with has been received or an in-dialog request to this SipDelegate has been received.</li>
+ * <li>Acknowledge that an outgoing SIP message from the RCS application has been sent
+ * successfully or notify the application of the reason why it was not sent</li>
+ * </ul>
+ * @hide
+ */
+public interface DelegateMessageCallback {
+
+ /**
+ * Send a new incoming SIP message to the remote application for processing.
+ */
+ void onMessageReceived(@NonNull SipMessage message);
+
+ /**
+ * Notify the remote application that a previous request to send a SIP message using
+ * {@link SipDelegate#sendMessage} has succeeded.
+ *
+ * @param viaTransactionId The transaction ID found in the via header field of the
+ * previously sent {@link SipMessage}.
+ */
+ void onMessageSent(@NonNull String viaTransactionId);
+
+ /**
+ * Notify the remote application that a previous request to send a SIP message using
+ * {@link SipDelegate#sendMessage} has failed.
+ *
+ * @param viaTransactionId The Transaction ID found in the via header field of the previously
+ * sent {@link SipMessage}.
+ * @param reason The reason for the failure.
+ */
+ void onMessageSendFailure(@NonNull String viaTransactionId,
+ @SipDelegateManager.MessageFailureReason int reason);
+}
diff --git a/telephony/java/android/telephony/ims/DelegateRegistrationState.aidl b/telephony/java/android/telephony/ims/DelegateRegistrationState.aidl
new file mode 100644
index 0000000..756ea92
--- /dev/null
+++ b/telephony/java/android/telephony/ims/DelegateRegistrationState.aidl
@@ -0,0 +1,19 @@
+/*
+ * Copyright (c) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package android.telephony.ims;
+
+parcelable DelegateRegistrationState;
diff --git a/telephony/java/android/telephony/ims/DelegateRegistrationState.java b/telephony/java/android/telephony/ims/DelegateRegistrationState.java
new file mode 100644
index 0000000..4facfa7
--- /dev/null
+++ b/telephony/java/android/telephony/ims/DelegateRegistrationState.java
@@ -0,0 +1,327 @@
+/*
+ * Copyright (C) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package android.telephony.ims;
+
+import android.annotation.IntDef;
+import android.annotation.NonNull;
+import android.os.Parcel;
+import android.os.Parcelable;
+import android.util.ArraySet;
+
+import java.lang.annotation.Retention;
+import java.lang.annotation.RetentionPolicy;
+import java.util.ArrayList;
+import java.util.List;
+import java.util.Objects;
+import java.util.Set;
+
+/**
+ * Contains the full state of the IMS feature tags associated with a SipDelegate and managed by the
+ * ImsService.
+ * @hide
+ */
+public final class DelegateRegistrationState implements Parcelable {
+
+ /**
+ * This feature tag has been deregistered for an unknown reason. Outgoing out-of-dialog SIP
+ * messages associated with feature tags that are not registered will fail.
+ */
+ public static final int DEREGISTERED_REASON_UNKNOWN = 0;
+
+ /**
+ * This feature tag has been deregistered because it is not provisioned to be used on this radio
+ * access technology or PDN. Outgoing out-of-dialog SIP messages associated with feature tags
+ * that are not registered will fail.
+ * <p>
+ * There may be new incoming SIP dialog requests on a feature that that is not provisioned. It
+ * is still expected that the SipDelegateConnection responds to the request.
+ */
+ public static final int DEREGISTERED_REASON_NOT_PROVISIONED = 1;
+
+ /**
+ * This feature tag has been deregistered because IMS has been deregistered. All outgoing SIP
+ * messages will fail until IMS registration occurs.
+ */
+ public static final int DEREGISTERED_REASON_NOT_REGISTERED = 2;
+
+ /**
+ * This feature tag is being deregistered because the PDN that the IMS registration is on is
+ *changing.
+ * All open SIP dialogs need to be closed before the PDN change can proceed.
+ */
+ public static final int DEREGISTERING_REASON_PDN_CHANGE = 3;
+
+ /**
+ * This feature tag is being deregistered due to a provisioning change. This can be triggered by
+ * many things, such as a provisioning change triggered by the carrier network, a radio access
+ * technology change by the modem causing a different set of feature tags to be provisioned, or
+ * a user triggered hange, such as data being enabled/disabled.
+ * <p>
+ * All open SIP dialogs associated with the new deprovisioned feature tag need to be closed
+ * before the IMS registration modification can proceed.
+ */
+ public static final int DEREGISTERING_REASON_PROVISIONING_CHANGE = 4;
+
+ /**
+ * This feature tag is deregistering because the SipDelegate associated with this feature tag
+ * needs to change its supported feature set.
+ * <p>
+ * All open SIP Dialogs associated with this feature tag must be closed before this operation
+ * can proceed.
+ */
+ public static final int DEREGISTERING_REASON_FEATURE_TAGS_CHANGING = 5;
+
+ /**
+ * This feature tag is deregistering because the SipDelegate is in the process of being
+ * destroyed.
+ * <p>
+ * All open SIP Dialogs associated with this feature tag must be closed before this operation
+ * can proceed.
+ */
+ public static final int DEREGISTERING_REASON_DESTROY_PENDING = 6;
+
+ /** @hide */
+ @Retention(RetentionPolicy.SOURCE)
+ @IntDef(prefix = "DEREGISTERED_REASON_", value = {
+ DEREGISTERED_REASON_UNKNOWN,
+ DEREGISTERED_REASON_NOT_PROVISIONED,
+ DEREGISTERED_REASON_NOT_REGISTERED
+ })
+ public @interface DeregisteredReason {}
+
+
+ /** @hide */
+ @Retention(RetentionPolicy.SOURCE)
+ @IntDef(prefix = "DEREGISTERING_REASON_", value = {
+ DEREGISTERING_REASON_PDN_CHANGE,
+ DEREGISTERING_REASON_PROVISIONING_CHANGE,
+ DEREGISTERING_REASON_FEATURE_TAGS_CHANGING,
+ DEREGISTERING_REASON_DESTROY_PENDING
+ })
+ public @interface DeregisteringReason {}
+
+ private final ArrayList<String> mRegisteredTags = new ArrayList<>();
+ private final ArrayList<FeatureTagState> mDeregisteringTags = new ArrayList<>();
+ private final ArrayList<FeatureTagState> mDeregisteredTags = new ArrayList<>();
+
+ /**
+ * Builder used to create new instances of {@link DelegateRegistrationState}.
+ */
+ public static class Builder {
+
+ private final DelegateRegistrationState mState;
+
+ /* Create a new instance of {@link Builder} */
+ public Builder() {
+ mState = new DelegateRegistrationState();
+ }
+
+ /**
+ * Add a feature tag that is currently included in the current network IMS Registration.
+ * @param featureTag The IMS media feature tag included in the current IMS registration.
+ * @return The in-progress Builder instance for RegistrationState.
+ */
+ public Builder addRegisteredFeatureTag(@NonNull String featureTag) {
+ if (!mState.mRegisteredTags.contains(featureTag)) {
+ mState.mRegisteredTags.add(featureTag);
+ }
+ return this;
+ }
+
+ /**
+ * Add a list of feature tags that are currently included in the current network IMS
+ * Registration.
+ * @param featureTags The IMS media feature tags included in the current IMS registration.
+ * @return The in-progress Builder instance for RegistrationState.
+ */
+ public Builder addRegisteredFeatureTags(@NonNull Set<String> featureTags) {
+ mState.mRegisteredTags.addAll(featureTags);
+ return this;
+ }
+
+ /**
+ * Add a feature tag that is in the current network IMS Registration, but is in the progress
+ * of being deregistered and requires action from the RCS application before the IMS
+ * registration can be modified.
+ *
+ * See {@link DeregisteringReason} for more information regarding what is required by the
+ * RCS application to proceed.
+ *
+ * @param featureTag The media feature tag that has limited or no availability due to its
+ * current deregistering state.
+ * @param reason The reason why the media feature tag has moved to the deregistering state.
+ * The availability of the feature tag depends on the {@link DeregisteringReason}.
+ * @return The in-progress Builder instance for RegistrationState.
+ */
+ public Builder addDeregisteringFeatureTag(@NonNull String featureTag,
+ @DeregisteringReason int reason) {
+ boolean ftExists = mState.mDeregisteringTags.stream().anyMatch(
+ f -> f.getFeatureTag().equals(featureTag));
+ if (!ftExists) {
+ mState.mDeregisteringTags.add(new FeatureTagState(featureTag, reason));
+ }
+ return this;
+ }
+
+ /**
+ * Add a feature tag that is currently not included in the network RCS registration. See
+ * {@link DeregisteredReason} for more information regarding the reason for why the feature
+ * tag is not registered.
+ * @param featureTag The media feature tag that is not registered.
+ * @param reason The reason why the media feature tag has been deregistered.
+ * @return The in-progress Builder instance for RegistrationState.
+ */
+ public Builder addDeregisteredFeatureTag(@NonNull String featureTag,
+ @DeregisteredReason int reason) {
+ boolean ftExists = mState.mDeregisteredTags.stream().anyMatch(
+ f -> f.getFeatureTag().equals(featureTag));
+ if (!ftExists) {
+ mState.mDeregisteredTags.add(new FeatureTagState(featureTag, reason));
+ }
+ return this;
+ }
+
+ /**
+ * @return the finalized instance.
+ */
+ public DelegateRegistrationState build() {
+ return mState;
+ }
+ }
+
+ /**
+ * The builder should be used to construct a new instance of this class.
+ */
+ private DelegateRegistrationState() {}
+
+ /**
+ * Used for unparcelling only.
+ */
+ private DelegateRegistrationState(Parcel source) {
+ source.readList(mRegisteredTags, null /*classloader*/);
+ readStateFromParcel(source, mDeregisteringTags);
+ readStateFromParcel(source, mDeregisteredTags);
+ }
+
+ /**
+ * Get the feature tags that this SipDelegate is associated with that are currently part of the
+ * network IMS registration. SIP Messages both in and out of a SIP Dialog may be sent and
+ * received using these feature tags.
+ * @return A Set of feature tags that the SipDelegate has associated with that are included in
+ * the network IMS registration.
+ */
+ public @NonNull Set<String> getRegisteredFeatureTags() {
+ return new ArraySet<>(mRegisteredTags);
+ }
+
+ /**
+ * Get the feature tags that this SipDelegate is associated with that are currently part of the
+ * network IMS registration but are in the process of being deregistered.
+ * <p>
+ * Any incoming SIP messages associated with a feature tag included in this list will still be
+ * delivered. Outgoing SIP messages that are still in-dialog will be delivered to the
+ * SipDelegate, but outgoing out-of-dialog SIP messages with a feature tag that is included in
+ * this list will fail.
+ * <p>
+ * The SipDelegate will stay in this state for a limited period of time while it waits for the
+ * RCS application to perform a specific action. More details on the actions that can cause this
+ * state as well as the expected response are included in the reason codes and can be found in
+ * {@link DeregisteringReason}.
+ * @return A Set of feature tags that the SipDelegate has associated with that are included in
+ * the network IMS registration but are in the process of deregistering.
+ */
+ public @NonNull Set<FeatureTagState> getDeregisteringFeatureTags() {
+ return new ArraySet<>(mDeregisteringTags);
+ }
+
+ /**
+ * Get the list of feature tags that are associated with this SipDelegate but are not currently
+ * included in the network IMS registration.
+ * <p>
+ * See {@link DeregisteredReason} codes for more information related to the reasons why this may
+ * occur.
+ * <p>
+ * Due to network race conditions, there may still be onditions where an incoming out-of-dialog
+ * SIP message is delivered for a feature tag that is considered deregistered. Due to this
+ * condition, in-dialog outgoing SIP messages for deregistered feature tags will still be
+ * allowed as long as they are in response to a dialog started by a remote party. Any outgoing
+ * out-of-dialog SIP messages associated with feature tags included in this list will fail to be
+ * sent.
+ * @return A list of feature tags that the SipDelegate has associated with that not included in
+ * the network IMS registration.
+ */
+ public @NonNull Set<FeatureTagState> getDeregisteredFeatureTags() {
+ return new ArraySet<>(mDeregisteredTags);
+ }
+
+ public static final Creator<DelegateRegistrationState> CREATOR =
+ new Creator<DelegateRegistrationState>() {
+ @Override
+ public DelegateRegistrationState createFromParcel(Parcel source) {
+ return new DelegateRegistrationState(source);
+ }
+
+ @Override
+ public DelegateRegistrationState[] newArray(int size) {
+ return new DelegateRegistrationState[size];
+ }
+ };
+
+ @Override
+ public int describeContents() {
+ return 0;
+ }
+
+ @Override
+ public void writeToParcel(Parcel dest, int flags) {
+ dest.writeList(mRegisteredTags);
+ writeStateToParcel(dest, mDeregisteringTags);
+ writeStateToParcel(dest, mDeregisteredTags);
+ }
+
+ private void writeStateToParcel(Parcel dest, List<FeatureTagState> state) {
+ dest.writeInt(state.size());
+ for (FeatureTagState s : state) {
+ dest.writeString(s.getFeatureTag());
+ dest.writeInt(s.getState());
+ }
+ }
+
+ private void readStateFromParcel(Parcel source, List<FeatureTagState> emptyState) {
+ int len = source.readInt();
+ for (int i = 0; i < len; i++) {
+ String ft = source.readString();
+ int reason = source.readInt();
+ emptyState.add(new FeatureTagState(ft, reason));
+ }
+ }
+
+ @Override
+ public boolean equals(Object o) {
+ if (this == o) return true;
+ if (o == null || getClass() != o.getClass()) return false;
+ DelegateRegistrationState that = (DelegateRegistrationState) o;
+ return mRegisteredTags.equals(that.mRegisteredTags)
+ && mDeregisteringTags.equals(that.mDeregisteringTags)
+ && mDeregisteredTags.equals(that.mDeregisteredTags);
+ }
+
+ @Override
+ public int hashCode() {
+ return Objects.hash(mRegisteredTags, mDeregisteringTags, mDeregisteredTags);
+ }
+}
diff --git a/telephony/java/android/telephony/ims/DelegateRequest.aidl b/telephony/java/android/telephony/ims/DelegateRequest.aidl
new file mode 100644
index 0000000..60c990f
--- /dev/null
+++ b/telephony/java/android/telephony/ims/DelegateRequest.aidl
@@ -0,0 +1,19 @@
+/*
+ * Copyright (c) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package android.telephony.ims;
+
+parcelable DelegateRequest;
diff --git a/telephony/java/android/telephony/ims/DelegateRequest.java b/telephony/java/android/telephony/ims/DelegateRequest.java
new file mode 100644
index 0000000..f384901
--- /dev/null
+++ b/telephony/java/android/telephony/ims/DelegateRequest.java
@@ -0,0 +1,101 @@
+/*
+ * Copyright (C) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package android.telephony.ims;
+
+import android.annotation.NonNull;
+import android.os.Parcel;
+import android.os.Parcelable;
+import android.telephony.ims.stub.SipDelegate;
+import android.util.ArraySet;
+
+import java.util.ArrayList;
+import java.util.Objects;
+import java.util.Set;
+
+/**
+ * Contains information required for the creation of a {@link SipDelegate} and the associated
+ * SipDelegateConnection given back to the requesting application.
+ * @hide
+ */
+public final class DelegateRequest implements Parcelable {
+
+ private final ArrayList<String> mFeatureTags;
+
+ /**
+ * Create a new DelegateRequest, which will be used to create a SipDelegate by the ImsService.
+ * @param featureTags The list of IMS feature tags that will be associated with the SipDelegate
+ * created using this DelegateRequest. All feature tags are expected to be in
+ * the format defined in RCC.07 section 2.6.1.3.
+ */
+ public DelegateRequest(@NonNull Set<String> featureTags) {
+ if (featureTags == null) {
+ throw new IllegalStateException("Invalid arguments, featureTags List can not be null");
+ }
+ mFeatureTags = new ArrayList<>(featureTags);
+ }
+
+ /**
+ * @return the list of IMS feature tag associated with this DelegateRequest in the format
+ * defined in RCC.07 section 2.6.1.3.
+ */
+ public Set<String> getFeatureTags() {
+ return new ArraySet<>(mFeatureTags);
+ }
+
+ /**
+ * Internal constructor used only for unparcelling.
+ */
+ private DelegateRequest(Parcel in) {
+ mFeatureTags = new ArrayList<>();
+ in.readList(mFeatureTags, null /*classLoader*/);
+ }
+
+ @Override
+ public int describeContents() {
+ return 0;
+ }
+
+ @Override
+ public void writeToParcel(Parcel dest, int flags) {
+ dest.writeList(mFeatureTags);
+ }
+
+ public static final @NonNull Creator<DelegateRequest> CREATOR = new Creator<DelegateRequest>() {
+ @Override
+ public DelegateRequest createFromParcel(Parcel source) {
+ return new DelegateRequest(source);
+ }
+
+ @Override
+ public DelegateRequest[] newArray(int size) {
+ return new DelegateRequest[size];
+ }
+ };
+
+ @Override
+ public boolean equals(Object o) {
+ if (this == o) return true;
+ if (o == null || getClass() != o.getClass()) return false;
+ DelegateRequest that = (DelegateRequest) o;
+ return mFeatureTags.equals(that.mFeatureTags);
+ }
+
+ @Override
+ public int hashCode() {
+ return Objects.hash(mFeatureTags);
+ }
+}
diff --git a/telephony/java/android/telephony/ims/DelegateStateCallback.java b/telephony/java/android/telephony/ims/DelegateStateCallback.java
new file mode 100644
index 0000000..0f1afc4
--- /dev/null
+++ b/telephony/java/android/telephony/ims/DelegateStateCallback.java
@@ -0,0 +1,101 @@
+/*
+ * Copyright (C) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package android.telephony.ims;
+
+import android.annotation.NonNull;
+import android.annotation.Nullable;
+import android.telephony.ims.stub.SipDelegate;
+import android.telephony.ims.stub.SipTransportImplBase;
+
+import java.util.List;
+
+/**
+ * Callback interface to notify a remote application of the following:
+ * <ul>
+ * <li>the {@link SipDelegate} associated with this callback has been created or destroyed in
+ * response to a creation or destruction request from the framework</li>
+ * <li>the SIP IMS configuration associated with this {@link SipDelegate} has changed</li>
+ * <li>the IMS registration of the feature tags associated with this {@link SipDelegate} have
+ * changed.</li>
+ * </ul>
+ * @hide
+ */
+public interface DelegateStateCallback {
+
+ /**
+ * This must be called by the ImsService after {@link SipTransportImplBase#createSipDelegate} is
+ * called by the framework to notify the framework and remote application that the
+ * {@link SipDelegate} has been successfully created.
+ *
+ * @param delegate The SipDelegate created to service the DelegateRequest.
+ * @param deniedTags A List of {@link FeatureTagState}, which contains the feature tags
+ * associated with this {@link SipDelegate} that have no access to send/receive SIP messages
+ * as well as a reason for why the feature tag is denied. For more information on the reason
+ * why the feature tag was denied access, see the
+ * {@link SipDelegateManager.DeniedReason} reasons. This is considered a permanent denial due
+ * to this {@link SipDelegate} not supporting a feature or this ImsService already
+ * implementing this feature elsewhere. If all features of this {@link SipDelegate} are
+ * denied, {@link #onCreated(SipDelegate, List)} should still be called as the framework will
+ * later call {@link SipTransportImplBase#destroySipDelegate(SipDelegate, int)} to clean the
+ * delegate up.
+ */
+ void onCreated(@NonNull SipDelegate delegate, @Nullable List<FeatureTagState> deniedTags);
+
+ /**
+ * This must be called by the ImsService after the framework calls
+ * {@link SipTransportImplBase#destroySipDelegate} to notify the framework and remote
+ * application that the procedure to destroy the {@link SipDelegate} has been completed.
+ * @param reasonCode The reason for closing this delegate.
+ */
+ void onDestroyed(@SipDelegateManager.SipDelegateDestroyReason int reasonCode);
+
+ /**
+ * Call to notify the remote application of a configuration change associated with this
+ * {@link SipDelegate}.
+ * <p>
+ * The remote application will not be able to proceed sending SIP messages until after this
+ * configuration is sent the first time, so this configuration should be sent as soon as the
+ * {@link SipDelegate} has access to these configuration parameters.
+ * <p>
+ * Incoming SIP messages should not be routed to the remote application until AFTER this
+ * configuration change is sent to ensure that the remote application can respond correctly.
+ * Similarly, if there is an event that triggers the IMS configuration to change, incoming SIP
+ * messages routing should be delayed until the {@link SipDelegate} sends the IMS configuration
+ * change event to reduce conditions where the remote application is using a stale IMS
+ * configuration.
+ */
+ void onImsConfigurationChanged(@NonNull SipDelegateImsConfiguration config);
+
+ /**
+ * Call to notify the remote application that the {@link SipDelegate} has modified the IMS
+ * registration state of the RCS feature tags that were requested as part of the initial
+ * {@link DelegateRequest}.
+ * <p>
+ * See {@link DelegateRegistrationState} for more information about how IMS Registration state
+ * should be communicated the associated SipDelegateConnection in cases such as
+ * IMS deregistration, handover, PDN change, provisioning changes, etc…
+ * <p>
+ * Note: Even after the status of the feature tags are updated here to deregistered, the
+ * SipDelegate must still be able to handle these messages and call
+ * {@link DelegateMessageCallback#onMessageSendFailure} to notify the RCS application that the
+ * message was not sent.
+ *
+ * @param registrationState The current network IMS registration state for all feature tags
+ * associated with this SipDelegate.
+ */
+ void onFeatureTagRegistrationChanged(@NonNull DelegateRegistrationState registrationState);
+}
diff --git a/telephony/java/android/telephony/ims/FeatureTagState.aidl b/telephony/java/android/telephony/ims/FeatureTagState.aidl
new file mode 100644
index 0000000..bce5574
--- /dev/null
+++ b/telephony/java/android/telephony/ims/FeatureTagState.aidl
@@ -0,0 +1,19 @@
+/*
+ * Copyright (c) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package android.telephony.ims;
+
+parcelable FeatureTagState;
diff --git a/telephony/java/android/telephony/ims/FeatureTagState.java b/telephony/java/android/telephony/ims/FeatureTagState.java
new file mode 100644
index 0000000..060be6f
--- /dev/null
+++ b/telephony/java/android/telephony/ims/FeatureTagState.java
@@ -0,0 +1,131 @@
+/*
+ * Copyright (C) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package android.telephony.ims;
+
+import android.annotation.NonNull;
+import android.os.Parcel;
+import android.os.Parcelable;
+import android.telephony.ims.stub.DelegateConnectionStateCallback;
+import android.telephony.ims.stub.SipDelegate;
+
+import java.util.List;
+import java.util.Objects;
+
+/**
+ * Maps an IMS media feature tag 3gpp universal resource name (URN) previously mapped to a
+ * {@link SipDelegate} in the associated {@link DelegateRequest} to its current availability
+ * state as set by the ImsService managing the related IMS registration.
+ *
+ * This class is only used to report more information about a IMS feature tag that is not fully
+ * available at this time.
+ * <p>
+ * Please see {@link DelegateRegistrationState}, {@link DelegateStateCallback}, and
+ * {@link DelegateConnectionStateCallback} for more information about how this class is used to
+ * convey the state of IMS feature tags that were requested by {@link DelegateRequest} but are not
+ * currently available.
+ * @hide
+ */
+public final class FeatureTagState implements Parcelable {
+
+ private final String mFeatureTag;
+ private final int mState;
+
+ /**
+ * Associate an IMS feature tag with its current state. See {@link DelegateRegistrationState}
+ * and {@link DelegateConnectionStateCallback#onFeatureTagStatusChanged(
+ * DelegateRegistrationState, List)} and
+ * {@link DelegateStateCallback#onCreated(SipDelegate, List)} for examples on how and when this
+ * is used.
+ *
+ * @param featureTag The IMS feature tag that is deregistered, in the process of
+ * deregistering, or denied.
+ * @param state The {@link DelegateRegistrationState.DeregisteredReason},
+ * {@link DelegateRegistrationState.DeregisteringReason}, or
+ * {@link SipDelegateManager.DeniedReason} associated with this feature tag.
+ */
+ public FeatureTagState(@NonNull String featureTag, int state) {
+ mFeatureTag = featureTag;
+ mState = state;
+ }
+
+ /**
+ * Used for constructing instances during un-parcelling.
+ */
+ private FeatureTagState(Parcel source) {
+ mFeatureTag = source.readString();
+ mState = source.readInt();
+ }
+
+ /**
+ * @return The IMS feature tag string that is in the process of deregistering,
+ * deregistered, or denied.
+ */
+ public @NonNull String getFeatureTag() {
+ return mFeatureTag;
+ }
+
+ /**
+ * @return The reason for why the feature tag is currently in the process of deregistering,
+ * has been deregistered, or has been denied. See {@link DelegateRegistrationState} and
+ * {@link DelegateConnectionStateCallback} for more information.
+ */
+ public int getState() {
+ return mState;
+ }
+
+ @Override
+ public int describeContents() {
+ return 0;
+ }
+
+ @Override
+ public void writeToParcel(Parcel dest, int flags) {
+ dest.writeString(mFeatureTag);
+ dest.writeInt(mState);
+ }
+
+ public static final Creator<FeatureTagState> CREATOR = new Creator<FeatureTagState>() {
+ @Override
+ public FeatureTagState createFromParcel(Parcel source) {
+ return new FeatureTagState(source);
+ }
+
+ @Override
+ public FeatureTagState[] newArray(int size) {
+ return new FeatureTagState[size];
+ }
+ };
+
+ @Override
+ public boolean equals(Object o) {
+ if (this == o) return true;
+ if (o == null || getClass() != o.getClass()) return false;
+ FeatureTagState that = (FeatureTagState) o;
+ return mState == that.mState
+ && mFeatureTag.equals(that.mFeatureTag);
+ }
+
+ @Override
+ public int hashCode() {
+ return Objects.hash(mFeatureTag, mState);
+ }
+
+ @Override
+ public String toString() {
+ return "FeatureTagState{" + "mFeatureTag='" + mFeatureTag + ", mState=" + mState + '}';
+ }
+}
diff --git a/telephony/java/android/telephony/ims/ImsCallProfile.java b/telephony/java/android/telephony/ims/ImsCallProfile.java
index 9a55cec..1b51936 100644
--- a/telephony/java/android/telephony/ims/ImsCallProfile.java
+++ b/telephony/java/android/telephony/ims/ImsCallProfile.java
@@ -450,8 +450,6 @@
/** Indicates if we have known the intent of the user for the call is emergency */
private boolean mHasKnownUserIntentEmergency = false;
- private Set<RtpHeaderExtensionType> mOfferedRtpHeaderExtensionTypes = new ArraySet<>();
-
private Set<RtpHeaderExtensionType> mAcceptedRtpHeaderExtensionTypes = new ArraySet<>();
/**
@@ -692,7 +690,6 @@
out.writeBoolean(mHasKnownUserIntentEmergency);
out.writeInt(mRestrictCause);
out.writeInt(mCallerNumberVerificationStatus);
- out.writeArray(mOfferedRtpHeaderExtensionTypes.toArray());
out.writeArray(mAcceptedRtpHeaderExtensionTypes.toArray());
}
@@ -708,9 +705,6 @@
mHasKnownUserIntentEmergency = in.readBoolean();
mRestrictCause = in.readInt();
mCallerNumberVerificationStatus = in.readInt();
- Object[] offered = in.readArray(RtpHeaderExtensionType.class.getClassLoader());
- mOfferedRtpHeaderExtensionTypes = Arrays.stream(offered)
- .map(o -> (RtpHeaderExtensionType) o).collect(Collectors.toSet());
Object[] accepted = in.readArray(RtpHeaderExtensionType.class.getClassLoader());
mAcceptedRtpHeaderExtensionTypes = Arrays.stream(accepted)
.map(o -> (RtpHeaderExtensionType) o).collect(Collectors.toSet());
@@ -1106,46 +1100,13 @@
}
/**
- * For an incoming or outgoing call, indicates the {@link RtpHeaderExtensionType}s which the
- * caller is offering to make available.
- * <p>
- * For outgoing calls, an {@link ImsService} will reserve
- * {@link RtpHeaderExtensionType#getLocalIdentifier()} identifiers the telephony stack has
- * proposed to use and not use these same local identifiers. The offered header extension
- * types for an outgoing call can be found in the
- * {@link ImsCallProfile#getOfferedRtpHeaderExtensionTypes()} and will be available to the
- * {@link ImsService} in {@link MmTelFeature#createCallSession(ImsCallProfile)}.
- * The {@link ImsService} sets the accepted {@link #setAcceptedRtpHeaderExtensionTypes(Set)}
- * when the SDP offer/accept process has completed.
- * <p>
- * According to RFC8285, RTP header extensions available to a call are determined using the
- * offer/accept phase of the SDP protocol (see RFC4566).
- *
- * @return the {@link RtpHeaderExtensionType}s which were offered by other end of the call.
- */
- public @NonNull Set<RtpHeaderExtensionType> getOfferedRtpHeaderExtensionTypes() {
- return mOfferedRtpHeaderExtensionTypes;
- }
-
- /**
- * Sets the offered {@link RtpHeaderExtensionType}s for this call.
- * <p>
- * According to RFC8285, RTP header extensions available to a call are determined using the
- * offer/accept phase of the SDP protocol (see RFC4566).
- *
- * @param rtpHeaderExtensions the {@link RtpHeaderExtensionType}s which are offered.
- */
- public void setOfferedRtpHeaderExtensionTypes(@NonNull Set<RtpHeaderExtensionType>
- rtpHeaderExtensions) {
- mOfferedRtpHeaderExtensionTypes.clear();
- mOfferedRtpHeaderExtensionTypes.addAll(rtpHeaderExtensions);
- }
-
- /**
* Gets the {@link RtpHeaderExtensionType}s which have been accepted by both ends of the call.
* <p>
* According to RFC8285, RTP header extensions available to a call are determined using the
* offer/accept phase of the SDP protocol (see RFC4566).
+ * <p>
+ * The offered header extension types supported by the framework and exposed to the
+ * {@link ImsService} via {@link MmTelFeature#changeOfferedRtpHeaderExtensionTypes(Set)}.
*
* @return the {@link RtpHeaderExtensionType}s which were accepted by the other end of the call.
*/
diff --git a/telephony/java/android/telephony/ims/ImsMmTelManager.java b/telephony/java/android/telephony/ims/ImsMmTelManager.java
index 76c1faf..218875e3 100644
--- a/telephony/java/android/telephony/ims/ImsMmTelManager.java
+++ b/telephony/java/android/telephony/ims/ImsMmTelManager.java
@@ -29,6 +29,7 @@
import android.os.RemoteException;
import android.os.ServiceSpecificException;
import android.telephony.AccessNetworkConstants;
+import android.telephony.BinderCacheManager;
import android.telephony.CarrierConfigManager;
import android.telephony.SubscriptionManager;
import android.telephony.TelephonyFrameworkInitializer;
@@ -213,6 +214,7 @@
}
private final int mSubId;
+ private final BinderCacheManager<ITelephony> mBinderCache;
/**
* Create an instance of {@link ImsMmTelManager} for the subscription id specified.
@@ -242,7 +244,8 @@
throw new IllegalArgumentException("Invalid subscription ID");
}
- return new ImsMmTelManager(subId);
+ return new ImsMmTelManager(subId, new BinderCacheManager<>(
+ ImsMmTelManager::getITelephonyInterface));
}
/**
@@ -250,8 +253,9 @@
* @hide
*/
@VisibleForTesting
- public ImsMmTelManager(int subId) {
+ public ImsMmTelManager(int subId, BinderCacheManager<ITelephony> binderCache) {
mSubId = subId;
+ mBinderCache = binderCache;
}
/**
@@ -1367,7 +1371,11 @@
}
}
- private static ITelephony getITelephony() {
+ private ITelephony getITelephony() {
+ return mBinderCache.getBinder();
+ }
+
+ private static ITelephony getITelephonyInterface() {
ITelephony binder = ITelephony.Stub.asInterface(
TelephonyFrameworkInitializer
.getTelephonyServiceManager()
diff --git a/telephony/java/android/telephony/ims/ImsRcsManager.java b/telephony/java/android/telephony/ims/ImsRcsManager.java
index 5a32075..074aefe 100644
--- a/telephony/java/android/telephony/ims/ImsRcsManager.java
+++ b/telephony/java/android/telephony/ims/ImsRcsManager.java
@@ -28,6 +28,7 @@
import android.os.RemoteException;
import android.provider.Settings;
import android.telephony.AccessNetworkConstants;
+import android.telephony.BinderCacheManager;
import android.telephony.CarrierConfigManager;
import android.telephony.TelephonyFrameworkInitializer;
import android.telephony.ims.aidl.IImsCapabilityCallback;
@@ -149,14 +150,17 @@
private final int mSubId;
private final Context mContext;
+ private final BinderCacheManager<IImsRcsController> mBinderCache;
/**
* Use {@link ImsManager#getImsRcsManager(int)} to create an instance of this class.
* @hide
*/
- public ImsRcsManager(Context context, int subId) {
+ public ImsRcsManager(Context context, int subId,
+ BinderCacheManager<IImsRcsController> binderCache) {
mSubId = subId;
mContext = context;
+ mBinderCache = binderCache;
}
/**
diff --git a/telephony/java/android/telephony/ims/SipDelegateConnection.java b/telephony/java/android/telephony/ims/SipDelegateConnection.java
new file mode 100644
index 0000000..6bfdc2c
--- /dev/null
+++ b/telephony/java/android/telephony/ims/SipDelegateConnection.java
@@ -0,0 +1,73 @@
+/*
+ * Copyright (C) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package android.telephony.ims;
+
+import android.annotation.NonNull;
+import android.telephony.ims.stub.SipDelegate;
+
+/**
+ * Represents a connection to the remote {@link SipDelegate} that is managed by the
+ * {@link ImsService} implementing IMS for the subscription that is associated with it.
+ * <p>
+ * The remote delegate will handle messages sent by this {@link SipDelegateConnection}, notifying
+ * the associated {@link DelegateMessageCallback} when the message was either sent successfully or
+ * failed to be sent.
+ * <p>
+ * It is also the responsibility of this {@link SipDelegateConnection} to acknowledge when incoming
+ * SIP messages have been received successfully via
+ * {@link DelegateMessageCallback#onMessageReceived(SipMessage)} or when there was an error
+ * receiving the message using {@link #notifyMessageReceived(String)} and
+ * {@link #notifyMessageReceiveError(String, int)}.
+ *
+ * @see SipDelegateManager#createSipDelegate
+ * @hide
+ */
+public interface SipDelegateConnection {
+
+ /**
+ * Send a SIP message to the SIP delegate to be sent over the carrier’s network. The
+ * {@link SipMessage} will either be acknowledged with
+ * {@link DelegateMessageCallback#onMessageSent(String)} upon successful sending of this message
+ * or {@link DelegateMessageCallback#onMessageSendFailure(String, int)} if there was an error
+ * sending the message.
+ * @param sipMessage The SipMessage to be sent.
+ * @param configVersion The SipDelegateImsConfiguration version used to construct the
+ * SipMessage. See {@link SipDelegateImsConfiguration#getVersion} for more
+ * information on this parameter and why it is used.
+ */
+ void sendMessage(@NonNull SipMessage sipMessage, int configVersion);
+
+ /**
+ * Notify the {@link SipDelegate} that a SIP message received from
+ * {@link DelegateMessageCallback#onMessageReceived(SipMessage)} has been received successfully
+ * and is being processed.
+ * @param viaTransactionId Per RFC3261 Sec 8.1.1.7 the transaction ID associated with the Via
+ * branch parameter.
+ */
+ void notifyMessageReceived(@NonNull String viaTransactionId);
+
+ /**
+ * Notify the SIP delegate that the SIP message has been received from
+ * {@link DelegateMessageCallback#onMessageReceived(SipMessage)}, however there was an error
+ * processing it.
+ * @param viaTransactionId Per RFC3261 Sec 8.1.1.7 the transaction ID associated with the Via
+ * branch parameter.
+ * @param reason The reason why the error occurred.
+ */
+ void notifyMessageReceiveError(@NonNull String viaTransactionId,
+ @SipDelegateManager.MessageFailureReason int reason);
+}
diff --git a/telephony/java/android/telephony/ims/SipDelegateImsConfiguration.aidl b/telephony/java/android/telephony/ims/SipDelegateImsConfiguration.aidl
new file mode 100644
index 0000000..44ae1b1
--- /dev/null
+++ b/telephony/java/android/telephony/ims/SipDelegateImsConfiguration.aidl
@@ -0,0 +1,19 @@
+/*
+ * Copyright (c) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package android.telephony.ims;
+
+parcelable SipDelegateImsConfiguration;
diff --git a/telephony/java/android/telephony/ims/SipDelegateImsConfiguration.java b/telephony/java/android/telephony/ims/SipDelegateImsConfiguration.java
new file mode 100644
index 0000000..8abd0ee
--- /dev/null
+++ b/telephony/java/android/telephony/ims/SipDelegateImsConfiguration.java
@@ -0,0 +1,499 @@
+/*
+ * Copyright (C) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package android.telephony.ims;
+
+import android.annotation.NonNull;
+import android.annotation.StringDef;
+import android.os.Parcel;
+import android.os.Parcelable;
+import android.os.PersistableBundle;
+import android.telephony.ims.stub.SipDelegate;
+
+import java.lang.annotation.Retention;
+import java.lang.annotation.RetentionPolicy;
+
+/**
+ * The IMS registration and other attributes that the {@link SipDelegateConnection} used by the
+ * IMS application will need to be aware of to correctly generate outgoing {@link SipMessage}s.
+ * <p>
+ * The IMS service must generate new instances of this configuration as the IMS configuration
+ * managed by the IMS service changes. Along with each {@link SipDelegateImsConfiguration} instance
+ * containing the configuration is the "version", which should be incremented every time a new
+ * {@link SipDelegateImsConfiguration} instance is created. The {@link SipDelegateConnection} will
+ * include the version of the {@link SipDelegateImsConfiguration} instance that it used in order for
+ * the {@link SipDelegate} to easily identify if the IMS application used a now stale configuration
+ * to generate the {@link SipMessage} and return
+ * {@link SipDelegateManager#MESSAGE_FAILURE_REASON_STALE_IMS_CONFIGURATION} in
+ * {@link DelegateMessageCallback#onMessageSendFailure(String, int)} so that the IMS application can
+ * regenerate that {@link SipMessage} using the correct {@link SipDelegateImsConfiguration}
+ * instance.
+ * <p>
+ * Every time the IMS configuration state changes in the IMS service, a full configuration should
+ * be generated. The new {@link SipDelegateImsConfiguration} instance should not be an incremental
+ * update.
+ * @hide
+ */
+public class SipDelegateImsConfiguration implements Parcelable {
+
+ /**
+ * IPV4 Address type.
+ * <p>
+ * Used as a potential value for {@link #KEY_SIP_CONFIG_IPTYPE_STRING}.
+ */
+ public static final String IPTYPE_IPV4 = "IPV4";
+
+ /**
+ * IPV6 Address type.
+ * <p>
+ * Used as a potential value for {@link #KEY_SIP_CONFIG_IPTYPE_STRING}.
+ */
+ public static final String IPTYPE_IPV6 = "IPV6";
+
+ /**
+ * The SIP transport uses UDP.
+ * <p>
+ * Used as a potential value for {@link #KEY_SIP_CONFIG_TRANSPORT_TYPE_STRING}.
+ */
+ public static final String SIP_TRANSPORT_UDP = "UDP";
+
+ /**
+ * The SIP transport uses TCP.
+ * <p>
+ * Used as a potential value for {@link #KEY_SIP_CONFIG_TRANSPORT_TYPE_STRING}.
+ */
+ public static final String SIP_TRANSPORT_TCP = "TCP";
+
+ /**
+ * Flag specifying if SIP compact form is enabled
+ */
+ public static final String KEY_SIP_CONFIG_IS_COMPACT_FORM_ENABLED_BOOL =
+ "sip_config_is_compact_form_enabled_bool";
+
+ /**
+ * Flag specifying if SIP keepalives are enabled
+ */
+ public static final String KEY_SIP_CONFIG_IS_KEEPALIVE_ENABLED_BOOL =
+ "sip_config_is_keepalive_enabled_bool";
+
+ /**
+ * Maximum SIP payload to be sent on UDP. If the SIP message payload is greater than max udp
+ * payload size, then TCP must be used
+ */
+ public static final String KEY_SIP_CONFIG_MAX_PAYLOAD_SIZE_ON_UDP_INT =
+ "sip_config_udp_max_payload_size_int";
+
+ /**
+ * Transport protocol used for SIP signaling.
+ * Available options are: {@link #SIP_TRANSPORT_UDP }, {@link #SIP_TRANSPORT_TCP }
+ */
+ public static final String KEY_SIP_CONFIG_TRANSPORT_TYPE_STRING =
+ "sip_config_protocol_type_string";
+
+ /**
+ * IMS public user identifier string
+ */
+ public static final String KEY_SIP_CONFIG_UE_PUBLIC_USER_ID_STRING =
+ "sip_config_ue_public_user_id_string";
+
+ /**
+ * IMS private user identifier string
+ */
+ public static final String KEY_SIP_CONFIG_UE_PRIVATE_USER_ID_STRING =
+ "sip_config_ue_private_user_id_string";
+
+ /**
+ * IMS home domain string
+ */
+ public static final String KEY_SIP_CONFIG_HOME_DOMAIN_STRING = "sip_config_home_domain_string";
+
+ /**
+ * IMEI string. Application can include the Instance-ID feature tag " +sip.instance" in the
+ * Contact header with a value of the device IMEI in the form "urn:gsma:imei:<device IMEI>".
+ */
+ public static final String KEY_SIP_CONFIG_IMEI_STRING = "sip_config_imei_string";
+
+ /**
+ * IP address type for SIP signaling.
+ * Available options are: {@link #IPTYPE_IPV6}, {@link #IPTYPE_IPV4}
+ */
+ public static final String KEY_SIP_CONFIG_IPTYPE_STRING = "sip_config_iptype_string";
+
+ /**
+ * Local IPaddress used for SIP signaling.
+ */
+ public static final String KEY_SIP_CONFIG_UE_DEFAULT_IPADDRESS_STRING =
+ "sip_config_ue_default_ipaddress_string";
+
+ /**
+ * Local port used for sending SIP traffic
+ */
+ public static final String KEY_SIP_CONFIG_UE_DEFAULT_PORT_INT =
+ "sip_config_ue_default_port_int";
+
+ /**
+ * SIP server / PCSCF default ip address
+ */
+ public static final String KEY_SIP_CONFIG_SERVER_DEFAULT_IPADDRESS_STRING =
+ "sip_config_server_default_ipaddress_string";
+
+ /**
+ * SIP server / PCSCF port used for sending SIP traffic
+ */
+ public static final String KEY_SIP_CONFIG_SERVER_DEFAULT_PORT_INT =
+ "sip_config_server_default_port_int";
+
+ /**
+ * Flag specifying if Network Address Translation is enabled and UE is behind a NAT.
+ */
+ public static final String KEY_SIP_CONFIG_IS_NAT_ENABLED_BOOL =
+ "sip_config_is_nat_enabled_bool";
+
+ /**
+ * UE's public IPaddress when UE is behind a NAT.
+ * <p>
+ * This key will not exist if {@link #KEY_SIP_CONFIG_IS_NAT_ENABLED_BOOL} is {@code false}.
+ */
+ public static final String KEY_SIP_CONFIG_UE_PUBLIC_IPADDRESS_WITH_NAT_STRING =
+ "sip_config_ue_public_ipaddress_with_nat_string";
+
+ /**
+ * UE's public SIP port when UE is behind a NAT.
+ * <p>
+ * This key will not exist if {@link #KEY_SIP_CONFIG_IS_NAT_ENABLED_BOOL} is {@code false}.
+ */
+ public static final String KEY_SIP_CONFIG_UE_PUBLIC_PORT_WITH_NAT_INT =
+ "sip_config_ue_public_port_with_nat_int";
+
+ /**
+ * Flag specifying if Globally routable user-agent uri (GRUU) is enabled as per TS 23.808
+ */
+ public static final String KEY_SIP_CONFIG_IS_GRUU_ENABLED_BOOL =
+ "sip_config_is_gruu_enabled_bool";
+
+ /**
+ * UE's Globally routable user-agent uri if this feature is enabled.
+ * <p>
+ * This key will not exist if {@link #KEY_SIP_CONFIG_IS_GRUU_ENABLED_BOOL} is {@code false}.
+ */
+ public static final String KEY_SIP_CONFIG_UE_PUBLIC_GRUU_STRING =
+ "sip_config_ue_public_gruu_string";
+
+ /**
+ * Flag specifying if SIP over IPSec is enabled.
+ */
+ public static final String KEY_SIP_CONFIG_IS_IPSEC_ENABLED_BOOL =
+ "sip_config_is_ipsec_enabled_bool";
+ /**
+ * UE's SIP port used to send traffic when IPSec is enabled.
+ * <p>
+ * This key will not exist if {@link #KEY_SIP_CONFIG_IS_IPSEC_ENABLED_BOOL} is {@code false}.
+ */
+ public static final String KEY_SIP_CONFIG_UE_IPSEC_CLIENT_PORT_INT =
+ "sip_config_ue_ipsec_client_port_int";
+
+ /**
+ * UE's SIP port used to receive traffic when IPSec is enabled.
+ * <p>
+ * This key will not exist if {@link #KEY_SIP_CONFIG_IS_IPSEC_ENABLED_BOOL} is {@code false}.
+ */
+ public static final String KEY_SIP_CONFIG_UE_IPSEC_SERVER_PORT_INT =
+ "sip_config_ue_ipsec_server_port_int";
+
+ /**
+ * UE's SIP port used for the previous IPsec security association if IPSec is enabled.
+ * <p>
+ * This key will not exist if {@link #KEY_SIP_CONFIG_IS_IPSEC_ENABLED_BOOL} is {@code false}.
+ */
+ public static final String KEY_SIP_CONFIG_UE_IPSEC_OLD_CLIENT_PORT_INT =
+ "sip_config_ue_ipsec_old_client_port_int";
+
+ /**
+ * Port number used by the SIP server to send SIP traffic when IPSec is enabled.
+ * <p>
+ * This key will not exist if {@link #KEY_SIP_CONFIG_IS_IPSEC_ENABLED_BOOL} is {@code false}.
+ */
+ public static final String KEY_SIP_CONFIG_SERVER_IPSEC_CLIENT_PORT_INT =
+ "sip_config_server_ipsec_client_port_int";
+
+ /**
+ * Port number used by the SIP server to receive incoming SIP traffic when IPSec is enabled.
+ * <p>
+ * This key will not exist if {@link #KEY_SIP_CONFIG_IS_IPSEC_ENABLED_BOOL} is {@code false}.
+ */
+ public static final String KEY_SIP_CONFIG_SERVER_IPSEC_SERVER_PORT_INT =
+ "sip_config_server_ipsec_server_port_int";
+
+ /**
+ * Port number used by the SIP server to send SIP traffic on the previous IPSec security
+ * association when IPSec is enabled.
+ * <p>
+ * This key will not exist if {@link #KEY_SIP_CONFIG_IS_IPSEC_ENABLED_BOOL} is {@code false}.
+ */
+ public static final String KEY_SIP_CONFIG_SERVER_IPSEC_OLD_CLIENT_PORT_INT =
+ "sip_config_server_ipsec_old_client_port_int";
+ /**
+ * SIP Authentication header string
+ */
+ public static final String KEY_SIP_CONFIG_AUTHENTICATION_HEADER_STRING =
+ "sip_config_auhentication_header_string";
+
+ /**
+ * SIP Authentication nonce string
+ */
+ public static final String KEY_SIP_CONFIG_AUTHENTICATION_NONCE_STRING =
+ "sip_config_authentication_nonce_string";
+
+ /**
+ * SIP service route header string
+ */
+ public static final String KEY_SIP_CONFIG_SERVICE_ROUTE_HEADER_STRING =
+ "sip_config_service_route_header_string";
+
+ /**
+ * SIP security verify header string
+ */
+ public static final String KEY_SIP_CONFIG_SECURITY_VERIFY_HEADER_STRING =
+ "sip_config_security_verify_header_string";
+
+ /**
+ * SIP Path header string
+ */
+ public static final String KEY_SIP_CONFIG_PATH_HEADER_STRING =
+ "sip_config_path_header_string";
+
+ /**
+ * SIP User part string in contact header
+ */
+ public static final String KEY_SIP_CONFIG_URI_USER_PART_STRING =
+ "sip_config_uri_user_part_string";
+
+ /**
+ * SIP P-access-network-info header string
+ */
+ public static final String KEY_SIP_CONFIG_P_ACCESS_NETWORK_INFO_HEADER_STRING =
+ "sip_config_p_access_network_info_header_string";
+
+ /**
+ * SIP P-last-access-network-info header string
+ */
+ public static final String KEY_SIP_CONFIG_P_LAST_ACCESS_NETWORK_INFO_HEADER_STRING =
+ "sip_config_p_last_access_network_info_header_string";
+
+ /**
+ * SIP P-associated-uri header string
+ */
+ public static final String KEY_SIP_CONFIG_P_ASSOCIATED_URI_HEADER_STRING =
+ "sip_config_p_associated_uri_header_string";
+
+ /**@hide*/
+ @StringDef(prefix = "KEY_SIP_CONFIG", suffix = "_STRING", value = {
+ KEY_SIP_CONFIG_TRANSPORT_TYPE_STRING,
+ KEY_SIP_CONFIG_UE_PUBLIC_USER_ID_STRING,
+ KEY_SIP_CONFIG_UE_PRIVATE_USER_ID_STRING,
+ KEY_SIP_CONFIG_HOME_DOMAIN_STRING,
+ KEY_SIP_CONFIG_IMEI_STRING,
+ KEY_SIP_CONFIG_IPTYPE_STRING,
+ KEY_SIP_CONFIG_UE_DEFAULT_IPADDRESS_STRING,
+ KEY_SIP_CONFIG_SERVER_DEFAULT_IPADDRESS_STRING,
+ KEY_SIP_CONFIG_UE_PUBLIC_IPADDRESS_WITH_NAT_STRING,
+ KEY_SIP_CONFIG_UE_PUBLIC_GRUU_STRING,
+ KEY_SIP_CONFIG_AUTHENTICATION_HEADER_STRING,
+ KEY_SIP_CONFIG_AUTHENTICATION_NONCE_STRING,
+ KEY_SIP_CONFIG_SERVICE_ROUTE_HEADER_STRING,
+ KEY_SIP_CONFIG_SECURITY_VERIFY_HEADER_STRING,
+ KEY_SIP_CONFIG_PATH_HEADER_STRING,
+ KEY_SIP_CONFIG_URI_USER_PART_STRING,
+ KEY_SIP_CONFIG_P_ACCESS_NETWORK_INFO_HEADER_STRING,
+ KEY_SIP_CONFIG_P_LAST_ACCESS_NETWORK_INFO_HEADER_STRING,
+ KEY_SIP_CONFIG_P_ASSOCIATED_URI_HEADER_STRING
+ })
+ @Retention(RetentionPolicy.SOURCE)
+ public @interface StringConfigKey {}
+
+ /**@hide*/
+ @StringDef(prefix = "KEY_SIP_CONFIG", suffix = "_INT", value = {
+ KEY_SIP_CONFIG_MAX_PAYLOAD_SIZE_ON_UDP_INT,
+ KEY_SIP_CONFIG_UE_DEFAULT_PORT_INT,
+ KEY_SIP_CONFIG_SERVER_DEFAULT_PORT_INT,
+ KEY_SIP_CONFIG_UE_PUBLIC_PORT_WITH_NAT_INT,
+ KEY_SIP_CONFIG_UE_IPSEC_CLIENT_PORT_INT,
+ KEY_SIP_CONFIG_UE_IPSEC_SERVER_PORT_INT,
+ KEY_SIP_CONFIG_UE_IPSEC_OLD_CLIENT_PORT_INT,
+ KEY_SIP_CONFIG_SERVER_IPSEC_CLIENT_PORT_INT,
+ KEY_SIP_CONFIG_SERVER_IPSEC_SERVER_PORT_INT,
+ KEY_SIP_CONFIG_SERVER_IPSEC_OLD_CLIENT_PORT_INT
+ })
+ @Retention(RetentionPolicy.SOURCE)
+ public @interface IntConfigKey {}
+
+ /**@hide*/
+ @StringDef(prefix = "KEY_SIP_CONFIG", suffix = "_BOOL", value = {
+ KEY_SIP_CONFIG_IS_COMPACT_FORM_ENABLED_BOOL,
+ KEY_SIP_CONFIG_IS_KEEPALIVE_ENABLED_BOOL,
+ KEY_SIP_CONFIG_IS_NAT_ENABLED_BOOL,
+ KEY_SIP_CONFIG_IS_GRUU_ENABLED_BOOL,
+ KEY_SIP_CONFIG_IS_IPSEC_ENABLED_BOOL
+ })
+ @Retention(RetentionPolicy.SOURCE)
+ public @interface BooleanConfigKey {}
+
+ /**
+ * Builder class to be used when constructing a new SipDelegateImsConfiguration.
+ */
+ public static class Builder {
+ private final long mVersion;
+ private final PersistableBundle mBundle;
+
+ /**
+ * Creates an empty implementation of SipDelegateImsConfiguration.
+ * @param version The version associated with the SipDelegateImsConfiguration being built.
+ * See {@link #getVersion} for more information.
+ */
+ public Builder(int version) {
+ mVersion = version;
+ mBundle = new PersistableBundle();
+ }
+ /**
+ * Clones an existing implementation of SipDelegateImsConfiguration to handle situations
+ * where only a small number of parameters have changed from the previous configuration.
+ * <p>
+ * Automatically increments the version of this configuration by 1. See {@link #getVersion}
+ * for more information.
+ */
+ public Builder(@NonNull SipDelegateImsConfiguration config) {
+ mVersion = config.getVersion() + 1;
+ mBundle = config.copyBundle();
+ }
+ /**
+ * Put a string value into this configuration bundle for the given key.
+ */
+ public Builder putString(@StringConfigKey String key, String value) {
+ mBundle.putString(key, value);
+ return this;
+ }
+
+ /**
+ * Replace the existing default value with a new value for a given key.
+ */
+ public Builder putInt(@IntConfigKey String key, int value) {
+ mBundle.putInt(key, value);
+ return this;
+ }
+
+ /**
+ * Replace the existing default value with a new value for a given key.
+ */
+ public Builder putBoolean(@BooleanConfigKey String key, boolean value) {
+ mBundle.putBoolean(key, value);
+ return this;
+ }
+
+ /**
+ * @return a new SipDelegateImsConfiguration from this Builder.
+ */
+ public SipDelegateImsConfiguration build() {
+ return new SipDelegateImsConfiguration(mVersion, mBundle);
+ }
+ }
+
+ private final long mVersion;
+ private final PersistableBundle mBundle;
+
+ private SipDelegateImsConfiguration(long version, PersistableBundle bundle) {
+ mVersion = version;
+ mBundle = bundle;
+ }
+
+ private SipDelegateImsConfiguration(Parcel source) {
+ mVersion = source.readLong();
+ mBundle = source.readPersistableBundle();
+ }
+
+ /**
+ * @return the string value associated with a given key or {@code null} if it doesn't exist.
+ */
+ public @StringConfigKey String getString(String key) {
+ return mBundle.getString(key);
+ }
+
+ /**
+ * @return the Integer value associated with a given key or {@code null} if the value doesn't
+ * exist.
+ */
+ public @IntConfigKey Integer getInt(String key) {
+ if (!mBundle.containsKey(key)) {
+ return null;
+ }
+ return mBundle.getInt(key);
+ }
+
+ /**
+ * @return the Integer value associated with a given key or {@code null} if the value doesn't
+ * exist.
+ */
+ public @BooleanConfigKey Boolean getBoolen(String key) {
+ if (!mBundle.containsKey(key)) {
+ return null;
+ }
+ return mBundle.getBoolean(key);
+ }
+
+ /**
+ * @return a shallow copy of the full configuration.
+ */
+ public PersistableBundle copyBundle() {
+ return new PersistableBundle(mBundle);
+ }
+
+ /**
+ * An integer representing the version number of this SipDelegateImsConfiguration.
+ * {@link SipMessage}s that are created using this configuration will also have a this
+ * version number associated with them, which will allow the IMS service to validate that the
+ * {@link SipMessage} was using the latest configuration during creation and not a stale
+ * configuration due to race conditions between the configuration being updated and the RCS
+ * application not receiving the updated configuration before generating a new message.
+ *
+ * @return the version number associated with this {@link SipDelegateImsConfiguration}.
+ */
+ public long getVersion() {
+ return mVersion;
+ }
+
+ @Override
+ public int describeContents() {
+ return 0;
+ }
+
+ @Override
+ public void writeToParcel(Parcel dest, int flags) {
+ dest.writeLong(mVersion);
+ dest.writePersistableBundle(mBundle);
+ }
+
+ public static final Creator<SipDelegateImsConfiguration> CREATOR =
+ new Creator<SipDelegateImsConfiguration>() {
+ @Override
+ public SipDelegateImsConfiguration createFromParcel(Parcel source) {
+ return new SipDelegateImsConfiguration(source);
+ }
+
+ @Override
+ public SipDelegateImsConfiguration[] newArray(int size) {
+ return new SipDelegateImsConfiguration[size];
+ }
+ };
+}
diff --git a/telephony/java/android/telephony/ims/SipDelegateManager.java b/telephony/java/android/telephony/ims/SipDelegateManager.java
index 82c8a9c..337b7d4 100644
--- a/telephony/java/android/telephony/ims/SipDelegateManager.java
+++ b/telephony/java/android/telephony/ims/SipDelegateManager.java
@@ -17,29 +17,251 @@
package android.telephony.ims;
import android.Manifest;
+import android.annotation.IntDef;
+import android.annotation.NonNull;
import android.annotation.RequiresPermission;
import android.annotation.SystemApi;
import android.content.Context;
-import android.os.IBinder;
import android.os.RemoteException;
import android.os.ServiceSpecificException;
+import android.telephony.BinderCacheManager;
import android.telephony.CarrierConfigManager;
-import android.telephony.TelephonyFrameworkInitializer;
import android.telephony.ims.aidl.IImsRcsController;
+import android.telephony.ims.aidl.SipDelegateConnectionAidlWrapper;
+import android.telephony.ims.stub.DelegateConnectionMessageCallback;
+import android.telephony.ims.stub.DelegateConnectionStateCallback;
+import android.telephony.ims.stub.SipDelegate;
import com.android.internal.annotations.VisibleForTesting;
+import java.lang.annotation.Retention;
+import java.lang.annotation.RetentionPolicy;
+import java.util.concurrent.Executor;
+
/**
- * Manages the creation and destruction of SipDelegates, which allow an IMS application to forward
- * SIP messages for the purposes of providing a single IMS registration to the carrier's IMS network
- * from multiple sources.
+ * Manages the creation and destruction of SipDelegates for the {@link ImsService} managing IMS
+ * for the subscription ID that this SipDelegateManager has been created for.
+ *
+ * This allows multiple IMS applications to forward SIP messages to/from their application for the
+ * purposes of providing a single IMS registration to the carrier's IMS network from potentially
+ * many IMS stacks implementing a subset of the supported MMTEL/RCS features.
* @hide
*/
@SystemApi
public class SipDelegateManager {
+ /**
+ * The SIP message has failed being sent or received for an unknown reason.
+ * <p>
+ * The caller should retry a message that failed with this response.
+ * @hide
+ */
+ public static final int MESSAGE_FAILURE_REASON_UNKNOWN = 0;
+
+ /**
+ * The remote service associated with this connection has died and the message was not
+ * properly sent/received.
+ * <p>
+ * This is considered a permanent error and the system will automatically begin the teardown and
+ * destruction of the SipDelegate. No further messages should be sent on this transport.
+ * @hide
+ */
+ public static final int MESSAGE_FAILURE_REASON_DELEGATE_DEAD = 1;
+
+ /**
+ * The message has not been sent/received because the delegate is in the process of closing and
+ * has become unavailable. No further messages should be sent/received on this delegate.
+ * @hide
+ */
+ public static final int MESSAGE_FAILURE_REASON_DELEGATE_CLOSED = 2;
+
+ /**
+ * The SIP message has an invalid start line and the message can not be sent.
+ * @hide
+ */
+ public static final int MESSAGE_FAILURE_REASON_INVALID_START_LINE = 3;
+
+ /**
+ * One or more of the header fields in the header section of the outgoing SIP message is invalid
+ * and the SIP message can not be sent.
+ * @hide
+ */
+ public static final int MESSAGE_FAILURE_REASON_INVALID_HEADER_FIELDS = 4;
+
+ /**
+ * The body content of the SIP message is invalid and the message can not be sent.
+ * @hide
+ */
+ public static final int MESSAGE_FAILURE_REASON_INVALID_BODY_CONTENT = 5;
+
+ /**
+ * The feature tag associated with the outgoing message does not match any known feature tags
+ * and this message can not be sent.
+ * @hide
+ */
+ public static final int MESSAGE_FAILURE_REASON_INVALID_FEATURE_TAG = 6;
+
+ /**
+ * The feature tag associated with the outgoing message is not enabled for the associated
+ * SipDelegateConnection and can not be sent.
+ * @hide
+ */
+ public static final int MESSAGE_FAILURE_REASON_TAG_NOT_ENABLED_FOR_DELEGATE = 7;
+
+ /**
+ * The link to the network has been lost and the outgoing message has failed to send.
+ * <p>
+ * This message should be retried when connectivity to the network is re-established. See
+ * {@link android.net.ConnectivityManager.NetworkCallback} for how this can be determined.
+ * @hide
+ */
+ public static final int MESSAGE_FAILURE_REASON_NETWORK_NOT_AVAILABLE = 8;
+
+ /**
+ * The outgoing SIP message has not been sent due to the SipDelegate not being registered for
+ * IMS at this time.
+ * <p>
+ * This is considered a temporary failure, the message should not be retried until an IMS
+ * registration change callback is received via
+ * {@link DelegateConnectionStateCallback#onFeatureTagStatusChanged}
+ * @hide
+ */
+ public static final int MESSAGE_FAILURE_REASON_NOT_REGISTERED = 9;
+
+ /**
+ * The outgoing SIP message has not been sent because the {@link SipDelegateImsConfiguration}
+ * version associated with the outgoing {@link SipMessage} is now stale and has failed
+ * validation checks.
+ * <p>
+ * The @link SipMessage} should be recreated using the newest
+ * {@link SipDelegateImsConfiguration} and sent again.
+ * @hide
+ */
+ public static final int MESSAGE_FAILURE_REASON_STALE_IMS_CONFIGURATION = 10;
+
+ /**
+ * The outgoing SIP message has not been sent because the internal state of the associated
+ * {@link SipDelegate} is changing and has temporarily brought the transport down.
+ * <p>
+ * This is considered a temporary error and the {@link SipDelegateConnection} should resend the
+ * message once {@link DelegateRegistrationState#DEREGISTERING_REASON_FEATURE_TAGS_CHANGING} is
+ * no longer reported.
+ * @hide
+ */
+ public static final int MESSAGE_FAILURE_REASON_INTERNAL_DELEGATE_STATE_TRANSITION = 11;
+
+ /** @hide */
+ @Retention(RetentionPolicy.SOURCE)
+ @IntDef(prefix = "MESSAGE_FAILURE_REASON_", value = {
+ MESSAGE_FAILURE_REASON_UNKNOWN,
+ MESSAGE_FAILURE_REASON_DELEGATE_DEAD,
+ MESSAGE_FAILURE_REASON_DELEGATE_CLOSED,
+ MESSAGE_FAILURE_REASON_INVALID_START_LINE,
+ MESSAGE_FAILURE_REASON_INVALID_HEADER_FIELDS,
+ MESSAGE_FAILURE_REASON_INVALID_BODY_CONTENT,
+ MESSAGE_FAILURE_REASON_INVALID_FEATURE_TAG,
+ MESSAGE_FAILURE_REASON_TAG_NOT_ENABLED_FOR_DELEGATE,
+ MESSAGE_FAILURE_REASON_NETWORK_NOT_AVAILABLE,
+ MESSAGE_FAILURE_REASON_NOT_REGISTERED,
+ MESSAGE_FAILURE_REASON_STALE_IMS_CONFIGURATION,
+ MESSAGE_FAILURE_REASON_INTERNAL_DELEGATE_STATE_TRANSITION
+ })
+ public @interface MessageFailureReason {}
+
+
+ /**
+ * Access to use this feature tag has been denied for an unknown reason.
+ * @hide
+ */
+ public static final int DENIED_REASON_UNKNOWN = 0;
+
+ /**
+ * This feature tag is allowed to be used by this SipDelegateConnection, but it is in use by
+ * another SipDelegateConnection and can not be associated with this delegate. The feature tag
+ * will stay in this state until the feature tag is release by the other application.
+ * @hide
+ */
+ public static final int DENIED_REASON_IN_USE_BY_ANOTHER_DELEGATE = 1;
+
+ /**
+ * Access to use this feature tag has been denied because this application does not have the
+ * permissions required to access this feature tag.
+ * @hide
+ */
+ public static final int DENIED_REASON_NOT_ALLOWED = 2;
+
+ /**
+ * Access to use this feature tag has been denied because single registration is not allowed by
+ * the carrier at this time. The application should fall back to dual registration if
+ * applicable.
+ * @hide
+ */
+ public static final int DENIED_REASON_SINGLE_REGISTRATION_NOT_ALLOWED = 3;
+
+ /**
+ * This feature tag is not recognized as a valid feature tag by the SipDelegate and has been
+ * denied.
+ * @hide
+ */
+ public static final int DENIED_REASON_INVALID = 4;
+
+ /** @hide */
+ @Retention(RetentionPolicy.SOURCE)
+ @IntDef(prefix = "DENIED_REASON_", value = {
+ DENIED_REASON_UNKNOWN,
+ DENIED_REASON_IN_USE_BY_ANOTHER_DELEGATE,
+ DENIED_REASON_NOT_ALLOWED,
+ DENIED_REASON_SINGLE_REGISTRATION_NOT_ALLOWED,
+ DENIED_REASON_INVALID
+ })
+ public @interface DeniedReason {}
+
+ /**
+ * The SipDelegate has closed due to an unknown reason.
+ * @hide
+ */
+ public static final int SIP_DELEGATE_DESTROY_REASON_UNKNOWN = 0;
+
+ /**
+ * The SipDelegate has closed because the IMS service has died unexpectedly.
+ * @hide
+ */
+ public static final int SIP_DELEGATE_DESTROY_REASON_SERVICE_DEAD = 1;
+
+ /**
+ * The SipDelegate has closed because the IMS application has requested that the connection be
+ * destroyed.
+ * @hide
+ */
+ public static final int SIP_DELEGATE_DESTROY_REASON_REQUESTED_BY_APP = 2;
+
+ /**
+ * The SipDelegate has closed because the IMS service does not support the creation of
+ * SipDelegates.
+ * @hide
+ */
+ public static final int SIP_DELEGATE_DESTROY_REASON_SERVICE_NOT_SUPPORTED = 3;
+
+ /**
+ * The SipDelegate has been closed due to the user disabling RCS.
+ * @hide
+ */
+ public static final int SIP_DELEGATE_DESTROY_REASON_USER_DISABLED_RCS = 4;
+
+ /** @hide */
+ @Retention(RetentionPolicy.SOURCE)
+ @IntDef(prefix = "SIP_DELEGATE_DESTROY_REASON", value = {
+ SIP_DELEGATE_DESTROY_REASON_UNKNOWN,
+ SIP_DELEGATE_DESTROY_REASON_SERVICE_DEAD,
+ SIP_DELEGATE_DESTROY_REASON_REQUESTED_BY_APP,
+ SIP_DELEGATE_DESTROY_REASON_SERVICE_NOT_SUPPORTED,
+ SIP_DELEGATE_DESTROY_REASON_USER_DISABLED_RCS
+ })
+ public @interface SipDelegateDestroyReason {}
+
private final Context mContext;
private final int mSubId;
+ private final BinderCacheManager<IImsRcsController> mBinderCache;
/**
* Only visible for testing. To instantiate an instance of this class, please use
@@ -47,9 +269,11 @@
* @hide
*/
@VisibleForTesting
- public SipDelegateManager(Context context, int subId) {
+ public SipDelegateManager(Context context, int subId,
+ BinderCacheManager<IImsRcsController> binderCache) {
mContext = context;
mSubId = subId;
+ mBinderCache = binderCache;
}
/**
@@ -69,7 +293,7 @@
@RequiresPermission(Manifest.permission.READ_PRIVILEGED_PHONE_STATE)
public boolean isSupported() throws ImsException {
try {
- IImsRcsController controller = getIImsRcsController();
+ IImsRcsController controller = mBinderCache.getBinder();
if (controller == null) {
throw new ImsException("Telephony server is down",
ImsException.CODE_ERROR_SERVICE_UNAVAILABLE);
@@ -83,11 +307,90 @@
}
}
- private IImsRcsController getIImsRcsController() {
- IBinder binder = TelephonyFrameworkInitializer
- .getTelephonyServiceManager()
- .getTelephonyImsServiceRegisterer()
- .get();
- return IImsRcsController.Stub.asInterface(binder);
+ /**
+ * Request that the ImsService implementation create a SipDelegate, which will configure the
+ * ImsService to forward SIP traffic that matches the filtering criteria set in supplied
+ * {@link DelegateRequest} to the application that the supplied callbacks are registered for.
+ * <p>
+ * This API requires that the caller is running as part of a long-running process and will
+ * always be available to handle incoming messages. One mechanism that can be used for this is
+ * the {@link android.service.carrier.CarrierMessagingClientService}, which the framework keeps
+ * a persistent binding to when the app is the default SMS application.
+ * @param request The parameters that are associated with the SipDelegate creation request that
+ * will be used to create the SipDelegate connection.
+ * @param executor The executor that will be used to call the callbacks associated with this
+ * SipDelegate.
+ * @param dc The callback that will be used to notify the listener of the creation/destruction
+ * of the remote SipDelegate as well as changes to the state of the remote SipDelegate
+ * connection.
+ * @param mc The callback that will be used to notify the listener of new incoming SIP messages
+ * as well as the status of messages that were sent by the associated
+ * SipDelegateConnection.
+ * @throws ImsException Thrown if there was a problem communicating with the ImsService
+ * associated with this SipDelegateManager. See {@link ImsException#getCode()}.
+ * @hide
+ */
+ @RequiresPermission(Manifest.permission.MODIFY_PHONE_STATE)
+ public void createSipDelegate(@NonNull DelegateRequest request, @NonNull Executor executor,
+ @NonNull DelegateConnectionStateCallback dc,
+ @NonNull DelegateConnectionMessageCallback mc) throws ImsException {
+ if (request == null || executor == null || dc == null || mc == null) {
+ throw new IllegalArgumentException("Invalid arguments passed into createSipDelegate");
+ }
+ try {
+ SipDelegateConnectionAidlWrapper wrapper =
+ new SipDelegateConnectionAidlWrapper(executor, dc, mc);
+ IImsRcsController controller = mBinderCache.listenOnBinder(wrapper,
+ wrapper::binderDied);
+ if (controller == null) {
+ throw new ImsException("Telephony server is down",
+ ImsException.CODE_ERROR_SERVICE_UNAVAILABLE);
+ }
+ controller.createSipDelegate(mSubId, request, wrapper.getStateCallbackBinder(),
+ wrapper.getMessageCallbackBinder());
+ } catch (ServiceSpecificException e) {
+ throw new ImsException(e.getMessage(), e.errorCode);
+ } catch (RemoteException e) {
+ throw new ImsException(e.getMessage(),
+ ImsException.CODE_ERROR_SERVICE_UNAVAILABLE);
+ }
+ }
+
+ /**
+ * Destroy a previously created {@link SipDelegateConnection} that was created using
+ * {@link #createSipDelegate}.
+ * <p>
+ * This will also clean up all related callbacks in the associated ImsService.
+ * @param delegateConnection The SipDelegateConnection to destroy.
+ * @param reason The reason for why this SipDelegateConnection was destroyed.
+ * @hide
+ */
+ @RequiresPermission(Manifest.permission.MODIFY_PHONE_STATE)
+ public void destroySipDelegate(@NonNull SipDelegateConnection delegateConnection,
+ @SipDelegateDestroyReason int reason) {
+
+ if (delegateConnection == null) {
+ throw new IllegalArgumentException("invalid argument passed into destroySipDelegate");
+ }
+ if (delegateConnection instanceof SipDelegateConnectionAidlWrapper) {
+ SipDelegateConnectionAidlWrapper w =
+ (SipDelegateConnectionAidlWrapper) delegateConnection;
+ try {
+ IImsRcsController c = mBinderCache.removeRunnable(w);
+ c.destroySipDelegate(mSubId, w.getSipDelegateBinder(), reason);
+ } catch (RemoteException e) {
+ // Connection to telephony died, but this will signal destruction of SipDelegate
+ // eventually anyway, so return normally.
+ try {
+ w.getStateCallbackBinder().onDestroyed(
+ SipDelegateManager.SIP_DELEGATE_DESTROY_REASON_REQUESTED_BY_APP);
+ } catch (RemoteException ignore) {
+ // Local to process.
+ }
+ }
+ } else {
+ throw new IllegalArgumentException("Unknown SipDelegateConnection implementation passed"
+ + " into this method");
+ }
}
}
diff --git a/telephony/java/android/telephony/ims/SipMessage.aidl b/telephony/java/android/telephony/ims/SipMessage.aidl
new file mode 100644
index 0000000..5140f8a
--- /dev/null
+++ b/telephony/java/android/telephony/ims/SipMessage.aidl
@@ -0,0 +1,19 @@
+/*
+ * Copyright (c) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package android.telephony.ims;
+
+parcelable SipMessage;
diff --git a/telephony/java/android/telephony/ims/SipMessage.java b/telephony/java/android/telephony/ims/SipMessage.java
new file mode 100644
index 0000000..c3b1be2
--- /dev/null
+++ b/telephony/java/android/telephony/ims/SipMessage.java
@@ -0,0 +1,155 @@
+/*
+ * Copyright (C) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package android.telephony.ims;
+
+import android.annotation.NonNull;
+import android.os.Build;
+import android.os.Parcel;
+import android.os.Parcelable;
+
+/**
+ * Represents a partially encoded SIP message. See RFC 3261 for more information on how SIP
+ * messages are structured and used.
+ * <p>
+ * The SIP message is represented in a partially encoded form in order to allow for easier
+ * verification and should not be used as a generic SIP message container.
+ * @hide
+ */
+public final class SipMessage implements Parcelable {
+ // Should not be set to true for production!
+ private static final boolean IS_DEBUGGING = Build.IS_ENG;
+
+ private static final String[] SIP_REQUEST_METHODS = new String[] {"INVITE", "ACK", "OPTIONS",
+ "BYE", "CANCEL", "REGISTER"};
+
+ private final String mStartLine;
+ private final String mHeaderSection;
+ private final byte[] mContent;
+
+ /**
+ * Represents a partially encoded SIP message.
+ *
+ * @param startLine The start line of the message, containing either the request-line or
+ * status-line.
+ * @param headerSection A String containing the full unencoded SIP message header.
+ * @param content UTF-8 encoded SIP message body.
+ */
+ public SipMessage(@NonNull String startLine, @NonNull String headerSection,
+ @NonNull byte[] content) {
+ if (startLine == null || headerSection == null || content == null) {
+ throw new IllegalArgumentException("One or more null parameters entered");
+ }
+ mStartLine = startLine;
+ mHeaderSection = headerSection;
+ mContent = content;
+ }
+
+ /**
+ * Private constructor used only for unparcelling.
+ */
+ private SipMessage(Parcel source) {
+ mStartLine = source.readString();
+ mHeaderSection = source.readString();
+ mContent = new byte[source.readInt()];
+ source.readByteArray(mContent);
+ }
+ /**
+ * @return The start line of the SIP message, which contains either the request-line or
+ * status-line.
+ */
+ public @NonNull String getStartLine() {
+ return mStartLine;
+ }
+
+ /**
+ * @return The full, unencoded header section of the SIP message.
+ */
+ public @NonNull String getHeaderSection() {
+ return mHeaderSection;
+ }
+
+ /**
+ * @return only the UTF-8 encoded SIP message body.
+ */
+ public @NonNull byte[] getContent() {
+ return mContent;
+ }
+
+ @Override
+ public int describeContents() {
+ return 0;
+ }
+
+ @Override
+ public void writeToParcel(Parcel dest, int flags) {
+ dest.writeString(mStartLine);
+ dest.writeString(mHeaderSection);
+ dest.writeInt(mContent.length);
+ dest.writeByteArray(mContent);
+ }
+
+ public static final Creator<SipMessage> CREATOR = new Creator<SipMessage>() {
+ @Override
+ public SipMessage createFromParcel(Parcel source) {
+ return new SipMessage(source);
+ }
+
+ @Override
+ public SipMessage[] newArray(int size) {
+ return new SipMessage[size];
+ }
+ };
+
+ @Override
+ public String toString() {
+ StringBuilder b = new StringBuilder();
+ b.append("StartLine: [");
+ if (IS_DEBUGGING) {
+ b.append(mStartLine);
+ } else {
+ b.append(sanitizeStartLineRequest(mStartLine));
+ }
+ b.append("], [");
+ b.append("Header: [");
+ if (IS_DEBUGGING) {
+ b.append(mHeaderSection);
+ } else {
+ // only identify transaction id/call ID when it is available.
+ b.append("***");
+ }
+ b.append("], ");
+ b.append("Content: [NOT SHOWN]");
+ return b.toString();
+ }
+
+ /**
+ * Start lines containing requests are formatted: METHOD SP Request-URI SP SIP-Version CRLF.
+ * Detect if this is a REQUEST and redact Request-URI portion here, as it contains PII.
+ */
+ private String sanitizeStartLineRequest(String startLine) {
+ String[] splitLine = startLine.split(" ");
+ if (splitLine == null || splitLine.length == 0) {
+ return "(INVALID STARTLINE)";
+ }
+ for (String method : SIP_REQUEST_METHODS) {
+ if (splitLine[0].contains(method)) {
+ return splitLine[0] + " <Request-URI> " + splitLine[2];
+ }
+ }
+ return startLine;
+ }
+}
diff --git a/telephony/java/android/telephony/ims/aidl/IImsMmTelFeature.aidl b/telephony/java/android/telephony/ims/aidl/IImsMmTelFeature.aidl
index b9a6b3c..37fec7a 100644
--- a/telephony/java/android/telephony/ims/aidl/IImsMmTelFeature.aidl
+++ b/telephony/java/android/telephony/ims/aidl/IImsMmTelFeature.aidl
@@ -21,6 +21,7 @@
import android.telephony.ims.aidl.IImsSmsListener;
import android.telephony.ims.aidl.IImsCapabilityCallback;
import android.telephony.ims.feature.CapabilityChangeRequest;
+import android.telephony.ims.RtpHeaderExtensionType;
import android.telephony.ims.ImsCallProfile;
import com.android.ims.internal.IImsCallSession;
@@ -29,6 +30,8 @@
import com.android.ims.internal.IImsRegistrationListener;
import com.android.ims.internal.IImsUt;
+import java.util.List;
+
/**
* See MmTelFeature for more information.
* {@hide}
@@ -37,6 +40,7 @@
void setListener(IImsMmTelListener l);
int getFeatureState();
ImsCallProfile createCallProfile(int callSessionType, int callType);
+ void changeOfferedRtpHeaderExtensionTypes(in List<RtpHeaderExtensionType> types);
IImsCallSession createCallSession(in ImsCallProfile profile);
int shouldProcessCall(in String[] uris);
IImsUt getUtInterface();
diff --git a/telephony/java/android/telephony/ims/aidl/IImsRcsController.aidl b/telephony/java/android/telephony/ims/aidl/IImsRcsController.aidl
index 8e84e93..f218e35 100644
--- a/telephony/java/android/telephony/ims/aidl/IImsRcsController.aidl
+++ b/telephony/java/android/telephony/ims/aidl/IImsRcsController.aidl
@@ -17,10 +17,15 @@
package android.telephony.ims.aidl;
import android.net.Uri;
+import android.telephony.ims.DelegateRequest;
import android.telephony.ims.aidl.IImsCapabilityCallback;
+import android.telephony.ims.aidl.IImsRegistrationCallback;
import android.telephony.ims.aidl.IRcsUceControllerCallback;
import android.telephony.ims.aidl.IRcsUcePublishStateCallback;
-import android.telephony.ims.aidl.IImsRegistrationCallback;
+import android.telephony.ims.aidl.IRcsUcePublishStateCallback;
+import android.telephony.ims.aidl.ISipDelegate;
+import android.telephony.ims.aidl.ISipDelegateMessageCallback;
+import android.telephony.ims.aidl.ISipDelegateConnectionStateCallback;
import com.android.ims.ImsFeatureContainer;
import com.android.ims.internal.IImsServiceFeatureCallback;
@@ -58,6 +63,10 @@
// SipDelegateManager
boolean isSipDelegateSupported(int subId);
+ void createSipDelegate(int subId, in DelegateRequest request,
+ ISipDelegateConnectionStateCallback delegateState,
+ ISipDelegateMessageCallback delegateMessage);
+ void destroySipDelegate(int subId, ISipDelegate connection, int reason);
// Internal commands that should not be made public
void registerRcsFeatureCallback(int slotId, in IImsServiceFeatureCallback callback);
diff --git a/telephony/java/android/telephony/ims/aidl/ISipDelegate.aidl b/telephony/java/android/telephony/ims/aidl/ISipDelegate.aidl
new file mode 100644
index 0000000..477ee95
--- /dev/null
+++ b/telephony/java/android/telephony/ims/aidl/ISipDelegate.aidl
@@ -0,0 +1,32 @@
+/*
+ * Copyright (c) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package android.telephony.ims.aidl;
+
+import android.telephony.ims.SipMessage;
+
+/**
+ * See {@link SipDelegate} and {@link SipDelegateConnection} for docs regarding this callback.
+ * {@hide}
+ */
+oneway interface ISipDelegate {
+ void sendMessage(in SipMessage sipMessage, int configVersion);
+ void notifyMessageReceived(in String viaTransactionId);
+ void notifyMessageReceiveError(in String viaTransactionId, int reason);
+
+ // only used by SipDelegate.
+ void closeDialog(in String callId);
+}
diff --git a/telephony/java/android/telephony/ims/aidl/ISipDelegateConnectionStateCallback.aidl b/telephony/java/android/telephony/ims/aidl/ISipDelegateConnectionStateCallback.aidl
new file mode 100644
index 0000000..ddfcb99
--- /dev/null
+++ b/telephony/java/android/telephony/ims/aidl/ISipDelegateConnectionStateCallback.aidl
@@ -0,0 +1,34 @@
+/*
+ * Copyright (c) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package android.telephony.ims.aidl;
+
+import android.telephony.ims.DelegateRegistrationState;
+import android.telephony.ims.FeatureTagState;
+import android.telephony.ims.SipDelegateImsConfiguration;
+import android.telephony.ims.aidl.ISipDelegate;
+
+/**
+ * See {@link SipDelegateConnectionStateCallback} for docs regarding this callback.
+ * {@hide}
+ */
+oneway interface ISipDelegateConnectionStateCallback {
+ void onCreated(ISipDelegate c);
+ void onFeatureTagStatusChanged(in DelegateRegistrationState registrationState,
+ in List<FeatureTagState> deniedFeatureTags);
+ void onImsConfigurationChanged(in SipDelegateImsConfiguration registeredSipConfig);
+ void onDestroyed(int reason);
+}
diff --git a/telephony/java/android/telephony/ims/aidl/ISipDelegateMessageCallback.aidl b/telephony/java/android/telephony/ims/aidl/ISipDelegateMessageCallback.aidl
new file mode 100644
index 0000000..30b7d6c
--- /dev/null
+++ b/telephony/java/android/telephony/ims/aidl/ISipDelegateMessageCallback.aidl
@@ -0,0 +1,30 @@
+/*
+ * Copyright (c) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package android.telephony.ims.aidl;
+
+import android.telephony.ims.SipMessage;
+
+/**
+ * See {@link DelegateMessageCallback} and {@link DelegateConnectionMessageCallback} for docs
+ * regarding this callback.
+ * {@hide}
+ */
+oneway interface ISipDelegateMessageCallback {
+ void onMessageReceived(in SipMessage message);
+ void onMessageSent(in String viaTransactionId);
+ void onMessageSendFailure(in String viaTransactionId, int reason);
+}
diff --git a/telephony/java/android/telephony/ims/aidl/ISipDelegateStateCallback.aidl b/telephony/java/android/telephony/ims/aidl/ISipDelegateStateCallback.aidl
new file mode 100644
index 0000000..609ee26
--- /dev/null
+++ b/telephony/java/android/telephony/ims/aidl/ISipDelegateStateCallback.aidl
@@ -0,0 +1,33 @@
+/*
+ * Copyright (c) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package android.telephony.ims.aidl;
+
+import android.telephony.ims.DelegateRegistrationState;
+import android.telephony.ims.FeatureTagState;
+import android.telephony.ims.SipDelegateImsConfiguration;
+import android.telephony.ims.aidl.ISipDelegate;
+
+/**
+ * See {@link SipDelegateStateCallback} for docs regarding this callback.
+ * {@hide}
+ */
+oneway interface ISipDelegateStateCallback {
+ void onCreated(ISipDelegate c, in List<FeatureTagState> deniedFeatureTags);
+ void onFeatureTagRegistrationChanged(in DelegateRegistrationState registrationState);
+ void onImsConfigurationChanged(in SipDelegateImsConfiguration registeredSipConfig);
+ void onDestroyed(int reason);
+}
diff --git a/telephony/java/android/telephony/ims/aidl/ISipTransport.aidl b/telephony/java/android/telephony/ims/aidl/ISipTransport.aidl
index fe23343..cd88839 100644
--- a/telephony/java/android/telephony/ims/aidl/ISipTransport.aidl
+++ b/telephony/java/android/telephony/ims/aidl/ISipTransport.aidl
@@ -16,9 +16,17 @@
package android.telephony.ims.aidl;
+import android.telephony.ims.DelegateRequest;
+import android.telephony.ims.aidl.ISipDelegate;
+import android.telephony.ims.aidl.ISipDelegateMessageCallback;
+import android.telephony.ims.aidl.ISipDelegateStateCallback;
+
/**
* Interface for commands to the SIP Transport implementation.
* {@hide}
*/
-interface ISipTransport {
+oneway interface ISipTransport {
+ void createSipDelegate(in DelegateRequest request, ISipDelegateStateCallback dc,
+ ISipDelegateMessageCallback mc);
+ void destroySipDelegate(ISipDelegate delegate, int reason);
}
diff --git a/telephony/java/android/telephony/ims/aidl/SipDelegateAidlWrapper.java b/telephony/java/android/telephony/ims/aidl/SipDelegateAidlWrapper.java
new file mode 100644
index 0000000..a7f62cc
--- /dev/null
+++ b/telephony/java/android/telephony/ims/aidl/SipDelegateAidlWrapper.java
@@ -0,0 +1,192 @@
+/*
+ * Copyright (C) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package android.telephony.ims.aidl;
+
+import android.annotation.NonNull;
+import android.annotation.Nullable;
+import android.os.Binder;
+import android.os.RemoteException;
+import android.telephony.ims.DelegateMessageCallback;
+import android.telephony.ims.DelegateRegistrationState;
+import android.telephony.ims.DelegateStateCallback;
+import android.telephony.ims.FeatureTagState;
+import android.telephony.ims.SipDelegateImsConfiguration;
+import android.telephony.ims.SipDelegateManager;
+import android.telephony.ims.SipMessage;
+import android.telephony.ims.stub.SipDelegate;
+
+import java.util.List;
+import java.util.concurrent.Executor;
+
+/**
+ * Implementation of callbacks by wrapping the internal AIDL from telephony. Also implements
+ * ISipDelegate internally when {@link DelegateStateCallback#onCreated(SipDelegate, List)} is called
+ * in order to trampoline events back to telephony.
+ * @hide
+ */
+public class SipDelegateAidlWrapper implements DelegateStateCallback, DelegateMessageCallback {
+
+ private final ISipDelegate.Stub mDelegateBinder = new ISipDelegate.Stub() {
+ @Override
+ public void sendMessage(SipMessage sipMessage, int configVersion) {
+ SipDelegate d = mDelegate;
+ final long token = Binder.clearCallingIdentity();
+ try {
+ mExecutor.execute(() -> d.sendMessage(sipMessage, configVersion));
+ } finally {
+ Binder.restoreCallingIdentity(token);
+ }
+ }
+
+ @Override
+ public void notifyMessageReceived(String viaTransactionId) {
+ SipDelegate d = mDelegate;
+ final long token = Binder.clearCallingIdentity();
+ try {
+ mExecutor.execute(() -> d.notifyMessageReceived(viaTransactionId));
+ } finally {
+ Binder.restoreCallingIdentity(token);
+ }
+
+ }
+
+ @Override
+ public void notifyMessageReceiveError(String viaTransactionId, int reason) {
+ SipDelegate d = mDelegate;
+ final long token = Binder.clearCallingIdentity();
+ try {
+ mExecutor.execute(() -> d.notifyMessageReceiveError(viaTransactionId, reason));
+ } finally {
+ Binder.restoreCallingIdentity(token);
+ }
+
+ }
+
+ @Override
+ public void closeDialog(String callId) {
+ SipDelegate d = mDelegate;
+ final long token = Binder.clearCallingIdentity();
+ try {
+ mExecutor.execute(() -> d.closeDialog(callId));
+ } finally {
+ Binder.restoreCallingIdentity(token);
+ }
+ }
+ };
+
+ private final ISipDelegateMessageCallback mMessageBinder;
+ private final ISipDelegateStateCallback mStateBinder;
+ private final Executor mExecutor;
+
+ private volatile SipDelegate mDelegate;
+
+ public SipDelegateAidlWrapper(Executor executor, ISipDelegateStateCallback stateBinder,
+ ISipDelegateMessageCallback messageBinder) {
+ mExecutor = executor;
+ mStateBinder = stateBinder;
+ mMessageBinder = messageBinder;
+ }
+
+ @Override
+ public void onMessageReceived(SipMessage message) {
+ try {
+ mMessageBinder.onMessageReceived(message);
+ } catch (RemoteException e) {
+ // BinderDied will be called on SipTransport instance to trigger destruction. Notify
+ // failure message failure locally for now.
+ SipDelegate d = mDelegate;
+ if (d != null) {
+ notifyLocalMessageFailedToBeReceived(message,
+ SipDelegateManager.MESSAGE_FAILURE_REASON_DELEGATE_DEAD);
+ }
+ }
+ }
+
+ @Override
+ public void onMessageSent(String viaTransactionId) {
+ try {
+ mMessageBinder.onMessageSent(viaTransactionId);
+ } catch (RemoteException e) {
+ // BinderDied will trigger destroySipDelegate, so just ignore this locally.
+ }
+ }
+
+ @Override
+ public void onMessageSendFailure(String viaTransactionId, int reason) {
+ try {
+ mMessageBinder.onMessageSendFailure(viaTransactionId, reason);
+ } catch (RemoteException e) {
+ // BinderDied will trigger destroySipDelegate, so just ignore this locally.
+ }
+ }
+
+ @Override
+ public void onCreated(@NonNull SipDelegate delegate,
+ @Nullable List<FeatureTagState> deniedTags) {
+ mDelegate = delegate;
+ try {
+ mStateBinder.onCreated(mDelegateBinder, deniedTags);
+ } catch (RemoteException e) {
+ // BinderDied will trigger destroySipDelegate, so just ignore this locally.
+ }
+ }
+
+ @Override
+ public void onFeatureTagRegistrationChanged(DelegateRegistrationState registrationState) {
+ try {
+ mStateBinder.onFeatureTagRegistrationChanged(registrationState);
+ } catch (RemoteException e) {
+ // BinderDied will trigger destroySipDelegate, so just ignore this locally.
+ }
+ }
+
+ @Override
+ public void onImsConfigurationChanged(@NonNull SipDelegateImsConfiguration config) {
+ try {
+ mStateBinder.onImsConfigurationChanged(config);
+ } catch (RemoteException e) {
+ // BinderDied will trigger destroySipDelegate, so just ignore this locally.
+ }
+ }
+
+ @Override
+ public void onDestroyed(int reasonCode) {
+ mDelegate = null;
+ try {
+ mStateBinder.onDestroyed(reasonCode);
+ } catch (RemoteException e) {
+ // Do not worry about this if the remote side is already dead.
+ }
+ }
+
+ public SipDelegate getDelegate() {
+ return mDelegate;
+ }
+
+ public ISipDelegate getDelegateBinder() {
+ return mDelegateBinder;
+ }
+
+ private void notifyLocalMessageFailedToBeReceived(SipMessage m, int reason) {
+ //TODO: parse transaction ID or throw IllegalArgumentException if the SipMessage
+ // transaction ID can not be parsed.
+ SipDelegate d = mDelegate;
+ if (d != null) {
+ mExecutor.execute(() -> d.notifyMessageReceiveError(null, reason));
+ }
+ }
+}
diff --git a/telephony/java/android/telephony/ims/aidl/SipDelegateConnectionAidlWrapper.java b/telephony/java/android/telephony/ims/aidl/SipDelegateConnectionAidlWrapper.java
new file mode 100644
index 0000000..3bd1a46
--- /dev/null
+++ b/telephony/java/android/telephony/ims/aidl/SipDelegateConnectionAidlWrapper.java
@@ -0,0 +1,260 @@
+/*
+ * Copyright (C) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package android.telephony.ims.aidl;
+
+import android.os.Binder;
+import android.os.IBinder;
+import android.os.RemoteException;
+import android.telephony.ims.DelegateRegistrationState;
+import android.telephony.ims.FeatureTagState;
+import android.telephony.ims.SipDelegateConnection;
+import android.telephony.ims.SipDelegateImsConfiguration;
+import android.telephony.ims.SipDelegateManager;
+import android.telephony.ims.SipMessage;
+import android.telephony.ims.stub.DelegateConnectionMessageCallback;
+import android.telephony.ims.stub.DelegateConnectionStateCallback;
+import android.telephony.ims.stub.SipDelegate;
+import android.util.ArraySet;
+import android.util.Log;
+
+import java.util.List;
+import java.util.NoSuchElementException;
+import java.util.concurrent.Executor;
+import java.util.concurrent.atomic.AtomicReference;
+
+/**
+ * Wrapper class implementing {@link SipDelegateConnection} using AIDL, which is returned to the
+ * local process. Also holds a reference to incoming connection message and state AIDL impl to
+ * trampoline events to callbacks as well as notify the local process in the event that the remote
+ * process becomes unavailable.
+ * <p>
+ * When the remote {@link SipDelegate} is created, this instance tracks the
+ * {@link ISipDelegate} associated with it and implements the
+ * {@link SipDelegateConnection} sent back to the local callback.
+ * @hide
+ */
+public class SipDelegateConnectionAidlWrapper implements SipDelegateConnection,
+ IBinder.DeathRecipient {
+ private static final String LOG_TAG = "SipDelegateCAW";
+
+ private final ISipDelegateConnectionStateCallback.Stub mStateBinder =
+ new ISipDelegateConnectionStateCallback.Stub() {
+ @Override
+ public void onCreated(ISipDelegate c) {
+ associateSipDelegate(c);
+ final long token = Binder.clearCallingIdentity();
+ try {
+ mExecutor.execute(() ->
+ mStateCallback.onCreated(SipDelegateConnectionAidlWrapper.this));
+ } finally {
+ Binder.restoreCallingIdentity(token);
+ }
+ }
+
+ @Override
+ public void onFeatureTagStatusChanged(DelegateRegistrationState registrationState,
+ List<FeatureTagState> deniedFeatureTags) {
+ final long token = Binder.clearCallingIdentity();
+ try {
+ mExecutor.execute(() ->
+ mStateCallback.onFeatureTagStatusChanged(registrationState,
+ new ArraySet<>(deniedFeatureTags)));
+ } finally {
+ Binder.restoreCallingIdentity(token);
+ }
+ }
+
+ @Override
+ public void onImsConfigurationChanged(SipDelegateImsConfiguration registeredSipConfig) {
+ final long token = Binder.clearCallingIdentity();
+ try {
+ mExecutor.execute(() ->
+ mStateCallback.onImsConfigurationChanged(registeredSipConfig));
+ } finally {
+ Binder.restoreCallingIdentity(token);
+ }
+ }
+
+ @Override
+ public void onDestroyed(int reason) {
+ invalidateSipDelegateBinder();
+ final long token = Binder.clearCallingIdentity();
+ try {
+ mExecutor.execute(() ->
+ mStateCallback.onDestroyed(reason));
+ } finally {
+ Binder.restoreCallingIdentity(token);
+ }
+ }
+ };
+
+ private final ISipDelegateMessageCallback.Stub mMessageBinder =
+ new ISipDelegateMessageCallback.Stub() {
+ @Override
+ public void onMessageReceived(SipMessage message) {
+ final long token = Binder.clearCallingIdentity();
+ try {
+ mExecutor.execute(() ->
+ mMessageCallback.onMessageReceived(message));
+ } finally {
+ Binder.restoreCallingIdentity(token);
+ }
+ }
+
+ @Override
+ public void onMessageSent(String viaTransactionId) {
+ final long token = Binder.clearCallingIdentity();
+ try {
+ mExecutor.execute(() ->
+ mMessageCallback.onMessageSent(viaTransactionId));
+ } finally {
+ Binder.restoreCallingIdentity(token);
+ }
+ }
+
+ @Override
+ public void onMessageSendFailure(String viaTransactionId, int reason) {
+ final long token = Binder.clearCallingIdentity();
+ try {
+ mExecutor.execute(() ->
+ mMessageCallback.onMessageSendFailure(viaTransactionId, reason));
+ } finally {
+ Binder.restoreCallingIdentity(token);
+ }
+ }
+ };
+
+
+ private final Executor mExecutor;
+ private final DelegateConnectionStateCallback mStateCallback;
+ private final DelegateConnectionMessageCallback mMessageCallback;
+ private final AtomicReference<ISipDelegate> mDelegateBinder =
+ new AtomicReference<>();
+
+ /**
+ * Wrap the local state and message callbacks, calling the implementation of these interfaces
+ * when the remote process calls these methods.
+ */
+ public SipDelegateConnectionAidlWrapper(Executor executor,
+ DelegateConnectionStateCallback stateCallback,
+ DelegateConnectionMessageCallback messageCallback) {
+ mExecutor = executor;
+ mStateCallback = stateCallback;
+ mMessageCallback = messageCallback;
+ }
+
+ @Override
+ public void sendMessage(SipMessage sipMessage, int configVersion) {
+ try {
+ ISipDelegate conn = getSipDelegateBinder();
+ if (conn == null) {
+ notifyLocalMessageFailedToSend(sipMessage,
+ SipDelegateManager.MESSAGE_FAILURE_REASON_DELEGATE_CLOSED);
+ return;
+ }
+ conn.sendMessage(sipMessage, configVersion);
+ } catch (RemoteException e) {
+ notifyLocalMessageFailedToSend(sipMessage,
+ SipDelegateManager.MESSAGE_FAILURE_REASON_DELEGATE_DEAD);
+ }
+ }
+
+ @Override
+ public void notifyMessageReceived(String viaTransactionId) {
+ try {
+ ISipDelegate conn = getSipDelegateBinder();
+ if (conn == null) {
+ return;
+ }
+ conn.notifyMessageReceived(viaTransactionId);
+ } catch (RemoteException e) {
+ // Nothing to do here, app will eventually get remote death callback.
+ }
+ }
+
+ @Override
+ public void notifyMessageReceiveError(String viaTransactionId, int reason) {
+ try {
+ ISipDelegate conn = getSipDelegateBinder();
+ if (conn == null) {
+ return;
+ }
+ conn.notifyMessageReceiveError(viaTransactionId, reason);
+ } catch (RemoteException e) {
+ // Nothing to do here, app will eventually get remote death callback.
+ }
+ }
+
+ // Also called upon IImsRcsController death (telephony process dies).
+ @Override
+ public void binderDied() {
+ invalidateSipDelegateBinder();
+ mExecutor.execute(() -> mStateCallback.onDestroyed(
+ SipDelegateManager.SIP_DELEGATE_DESTROY_REASON_SERVICE_DEAD));
+ }
+
+ /**
+ * @return Implementation of state binder.
+ */
+ public ISipDelegateConnectionStateCallback getStateCallbackBinder() {
+ return mStateBinder;
+ }
+
+ /**
+ * @return Implementation of message binder.
+ */
+ public ISipDelegateMessageCallback getMessageCallbackBinder() {
+ return mMessageBinder;
+ }
+
+ /**
+ * @return The ISipDelegateConnection associated with this wrapper.
+ */
+ public ISipDelegate getSipDelegateBinder() {
+ return mDelegateBinder.get();
+ }
+
+ private void associateSipDelegate(ISipDelegate c) {
+ if (c != null) {
+ try {
+ c.asBinder().linkToDeath(this, 0 /*flags*/);
+ } catch (RemoteException e) {
+ // already dead.
+ c = null;
+ }
+ }
+ mDelegateBinder.set(c);
+ }
+
+ private void invalidateSipDelegateBinder() {
+ ISipDelegate oldVal = mDelegateBinder.getAndUpdate((unused) -> null);
+ if (oldVal != null) {
+ try {
+ oldVal.asBinder().unlinkToDeath(this, 0 /*flags*/);
+ } catch (NoSuchElementException e) {
+ Log.i(LOG_TAG, "invalidateSipDelegateBinder: " + e);
+ }
+ }
+ }
+
+ private void notifyLocalMessageFailedToSend(SipMessage m, int reason) {
+ //TODO: parse transaction ID or throw IllegalArgumentException if the SipMessage
+ // transaction ID can not be parsed.
+ mExecutor.execute(() ->
+ mMessageCallback.onMessageSendFailure(null, reason));
+ }
+}
diff --git a/telephony/java/android/telephony/ims/feature/ImsFeature.java b/telephony/java/android/telephony/ims/feature/ImsFeature.java
index b0a7b62..96ca022 100644
--- a/telephony/java/android/telephony/ims/feature/ImsFeature.java
+++ b/telephony/java/android/telephony/ims/feature/ImsFeature.java
@@ -509,6 +509,7 @@
* @return true if the capability is enabled, false otherwise.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
public abstract boolean queryCapabilityConfiguration(int capability, int radioTech);
/**
@@ -547,5 +548,6 @@
* @return Binder instance that the framework will use to communicate with this feature.
* @hide
*/
+ @SuppressWarnings("HiddenAbstractMethod")
protected abstract IInterface getBinder();
}
diff --git a/telephony/java/android/telephony/ims/feature/MmTelFeature.java b/telephony/java/android/telephony/ims/feature/MmTelFeature.java
index 508d1a7..e823417 100644
--- a/telephony/java/android/telephony/ims/feature/MmTelFeature.java
+++ b/telephony/java/android/telephony/ims/feature/MmTelFeature.java
@@ -27,6 +27,8 @@
import android.telephony.ims.ImsCallProfile;
import android.telephony.ims.ImsCallSession;
import android.telephony.ims.ImsReasonInfo;
+import android.telephony.ims.ImsService;
+import android.telephony.ims.RtpHeaderExtensionType;
import android.telephony.ims.aidl.IImsCapabilityCallback;
import android.telephony.ims.aidl.IImsMmTelFeature;
import android.telephony.ims.aidl.IImsMmTelListener;
@@ -37,6 +39,7 @@
import android.telephony.ims.stub.ImsRegistrationImplBase;
import android.telephony.ims.stub.ImsSmsImplBase;
import android.telephony.ims.stub.ImsUtImplBase;
+import android.util.ArraySet;
import com.android.ims.internal.IImsCallSession;
import com.android.ims.internal.IImsEcbm;
@@ -45,6 +48,8 @@
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
+import java.util.List;
+import java.util.Set;
/**
* Base implementation for Voice and SMS (IR-92) and Video (IR-94) IMS support.
@@ -93,6 +98,18 @@
}
@Override
+ public void changeOfferedRtpHeaderExtensionTypes(List<RtpHeaderExtensionType> types)
+ throws RemoteException {
+ synchronized (mLock) {
+ try {
+ MmTelFeature.this.changeOfferedRtpHeaderExtensionTypes(new ArraySet<>(types));
+ } catch (Exception e) {
+ throw new RemoteException(e.getMessage());
+ }
+ }
+ }
+
+ @Override
public IImsCallSession createCallSession(ImsCallProfile profile) throws RemoteException {
synchronized (mLock) {
return createCallSessionInterface(profile);
@@ -623,6 +640,24 @@
}
/**
+ * Called by the framework to report a change to the RTP header extension types which should be
+ * offered during SDP negotiation (see RFC8285 for more information).
+ * <p>
+ * The {@link ImsService} should report the RTP header extensions which were accepted during
+ * SDP negotiation using {@link ImsCallProfile#setAcceptedRtpHeaderExtensionTypes(Set)}.
+ *
+ * @param extensionTypes The RTP header extensions the framework wishes to offer during
+ * outgoing and incoming call setup. An empty list indicates that there
+ * are no framework defined RTP header extension types to offer.
+ * @hide
+ */
+ @SystemApi
+ public void changeOfferedRtpHeaderExtensionTypes(
+ @NonNull Set<RtpHeaderExtensionType> extensionTypes) {
+ // Base implementation - should be overridden if RTP header extension handling is supported.
+ }
+
+ /**
* @hide
*/
public IImsCallSession createCallSessionInterface(ImsCallProfile profile)
diff --git a/telephony/java/android/telephony/ims/stub/DelegateConnectionMessageCallback.java b/telephony/java/android/telephony/ims/stub/DelegateConnectionMessageCallback.java
new file mode 100644
index 0000000..59f9601
--- /dev/null
+++ b/telephony/java/android/telephony/ims/stub/DelegateConnectionMessageCallback.java
@@ -0,0 +1,54 @@
+/*
+ * Copyright (C) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package android.telephony.ims.stub;
+
+import android.annotation.NonNull;
+import android.telephony.ims.SipDelegateConnection;
+import android.telephony.ims.SipDelegateManager;
+import android.telephony.ims.SipMessage;
+
+/**
+ * The callback associated with a {@link SipDelegateConnection}, which handles newly received
+ * messages as well as the result of sending a SIP message.
+ * @hide
+ */
+public interface DelegateConnectionMessageCallback {
+
+ /**
+ * A new {@link SipMessage} has been received from the delegate.
+ * @param message the {@link SipMessage} routed to this RCS application.
+ */
+ void onMessageReceived(@NonNull SipMessage message);
+
+ /**
+ * A message previously sent to the SIP delegate using
+ * {@link SipDelegateConnection#sendMessage} has been successfully sent.
+ * @param viaTransactionId The transaction ID found in the via header field of the
+ * previously sent {@link SipMessage}.
+ */
+ void onMessageSent(@NonNull String viaTransactionId);
+
+ /**
+ * A message previously sent to the SIP delegate using
+ * {@link SipDelegateConnection#sendMessage} has failed to be sent.
+ * @param viaTransactionId The Transaction ID found in the via header field of the
+ * previously sent {@link SipMessage}.
+ * @param reason The reason for the failure.
+ */
+ void onMessageSendFailure(String viaTransactionId,
+ @SipDelegateManager.MessageFailureReason int reason);
+}
diff --git a/telephony/java/android/telephony/ims/stub/DelegateConnectionStateCallback.java b/telephony/java/android/telephony/ims/stub/DelegateConnectionStateCallback.java
new file mode 100644
index 0000000..9761805
--- /dev/null
+++ b/telephony/java/android/telephony/ims/stub/DelegateConnectionStateCallback.java
@@ -0,0 +1,147 @@
+/*
+ * Copyright (C) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package android.telephony.ims.stub;
+
+import android.annotation.NonNull;
+import android.telephony.ims.DelegateRegistrationState;
+import android.telephony.ims.DelegateRequest;
+import android.telephony.ims.FeatureTagState;
+import android.telephony.ims.SipDelegateConnection;
+import android.telephony.ims.SipDelegateImsConfiguration;
+import android.telephony.ims.SipDelegateManager;
+
+import java.util.Set;
+
+/**
+ * The callback associated with a {@link SipDelegateConnection} that manages the state of the
+ * SipDelegateConnection.
+ * <p>
+ * After {@link SipDelegateManager#createSipDelegate} is used to request a new
+ * {@link SipDelegateConnection} be created, {@link #onCreated} will be called with the
+ * {@link SipDelegateConnection} instance that must be used to communicate with the remote
+ * {@link SipDelegate}.
+ * <p>
+ * After, {@link #onFeatureTagStatusChanged} will always be called at least once with the current
+ * status of the feature tags that have been requested. The application may receive multiple
+ * {@link #onFeatureTagStatusChanged} callbacks over the lifetime of the associated
+ * {@link SipDelegateConnection}, which will signal changes to how SIP messages associated with
+ * those feature tags will be handled.
+ * <p>
+ * In order to start sending SIP messages, the SIP configuration parameters will need to be
+ * received, so the messaging application should make no assumptions about these parameters and wait
+ * until {@link #onImsConfigurationChanged(SipDelegateImsConfiguration)} has been called. This is
+ * guaranteed to happen after the first {@link #onFeatureTagStatusChanged} if there is at least one
+ * feature tag that has been successfully associated with the {@link SipDelegateConnection}. If all
+ * feature tags were denied, no IMS configuration will be sent.
+ * <p>
+ * The {@link SipDelegateConnection} will stay associated with this RCS application until either the
+ * RCS application calls {@link SipDelegateManager#destroySipDelegate} or telephony destroys the
+ * {@link SipDelegateConnection}. In both cases, {@link #onDestroyed(int)} will be called.
+ * Telephony destroying the {@link SipDelegateConnection} instance is rare and will only happen in
+ * rare cases, such as if telephony itself or IMS service dies unexpectedly. See
+ * {@link SipDelegateManager.SipDelegateDestroyReason} reasons for more information on all of the
+ * cases that will trigger the {@link SipDelegateConnection} to be destroyed.
+ *
+ * @hide
+ */
+public interface DelegateConnectionStateCallback {
+
+ /**
+ * A {@link SipDelegateConnection} has been successfully created for the
+ * {@link DelegateRequest} used when calling {@link SipDelegateManager#createSipDelegate}.
+ */
+ void onCreated(@NonNull SipDelegateConnection c);
+
+ /**
+ * The status of the RCS feature tags that were requested as part of the initial
+ * {@link DelegateRequest}.
+ * <p>
+ * There are four states that each RCS feature tag can be in: registered, deregistering,
+ * deregistered, and denied.
+ * <p>
+ * When a feature tag is considered registered, SIP messages associated with that feature tag
+ * may be sent and received freely.
+ * <p>
+ * When a feature tag is deregistering, the network IMS registration still contains the feature
+ * tag, however the IMS service and associated {@link SipDelegate} is in the progress of
+ * modifying the IMS registration to remove this feature tag and requires the application to
+ * perform an action before the IMS registration can change. The specific action required for
+ * the SipDelegate to continue modifying the IMS registration can be found in the definition of
+ * each {@link DelegateRegistrationState.DeregisteringReason}.
+ * <p>
+ * When a feature tag is in the deregistered state, new out-of-dialog SIP messages for that
+ * feature tag will be rejected, however due to network race conditions, the RCS application
+ * should still be able to handle new out-of-dialog SIP requests from the network. This may not
+ * be possible, however, if the IMS registration itself was lost. See the
+ * {@link DelegateRegistrationState.DeregisteredReason} reasons for more information on how SIP
+ * messages are handled in each of these cases.
+ * <p>
+ * If a feature tag is denied, no incoming messages will be routed to the associated
+ * {@link DelegateConnectionMessageCallback} and all outgoing SIP messages related to this
+ * feature tag will be rejected. See {@link SipDelegateManager.DeniedReason}
+ * reasons for more information about the conditions when this will happen.
+ * <p>
+ * The set of feature tags contained in the registered, deregistering, deregistered, and denied
+ * lists will always equal the set of feature tags requested in the initial
+ * {@link DelegateRequest}.
+ * <p>
+ * Transitions of feature tags from registered, deregistering, and deregistered and vice-versa
+ * may happen quite often, however transitions to/from denied are rare and only occur if the
+ * user has changed the role of your application to add/remove support for one or more requested
+ * feature tags or carrier provisioning has enabled or disabled single registration entirely.
+ * Please see {@link SipDelegateManager.DeniedReason} reasons for an explanation of each of
+ * these cases as well as what may cause them to change.
+ *
+ * @param registrationState The new IMS registration state of each of the feature tags
+ * associated with the {@link SipDelegate}.
+ * @param deniedFeatureTags A list of {@link FeatureTagState} objects, each containing a feature
+ * tag associated with this {@link SipDelegateConnection} that has no access to
+ * send/receive SIP messages as well as a reason for why the feature tag is denied. For more
+ * information on the reason why the feature tag was denied access, see the
+ * {@link SipDelegateManager.DeniedReason} reasons.
+ */
+ void onFeatureTagStatusChanged(@NonNull DelegateRegistrationState registrationState,
+ @NonNull Set<FeatureTagState> deniedFeatureTags);
+
+
+ /**
+ * IMS configuration of the underlying IMS stack used by this IMS application for construction
+ * of the SIP messages that will be sent over the carrier's network.
+ * <p>
+ * There should never be assumptions made about the configuration of the underling IMS stack and
+ * the IMS application should wait for this indication before sending out any outgoing SIP
+ * messages.
+ * <p>
+ * Configuration may change due to IMS registration changes as well as
+ * other optional events on the carrier network. If IMS stack is already registered at the time
+ * of callback registration, then this method shall be invoked with the current configuration.
+ * Otherwise, there may be a delay in this method being called if initial IMS registration has
+ * not compleed yet.
+ *
+ * @param registeredSipConfig The configuration of the IMS stack registered on the IMS network.
+ */
+ void onImsConfigurationChanged(@NonNull SipDelegateImsConfiguration registeredSipConfig);
+
+ /**
+ * The previously created {@link SipDelegateConnection} instance delivered via
+ * {@link #onCreated(SipDelegateConnection)} has been destroyed. This interface should no longer
+ * be used for any SIP message handling.
+ *
+ * @param reason The reason for the failure.
+ */
+ void onDestroyed(@SipDelegateManager.SipDelegateDestroyReason int reason);
+}
diff --git a/telephony/java/android/telephony/ims/stub/ImsRegistrationImplBase.java b/telephony/java/android/telephony/ims/stub/ImsRegistrationImplBase.java
index 12abdd1..a6f5c45 100644
--- a/telephony/java/android/telephony/ims/stub/ImsRegistrationImplBase.java
+++ b/telephony/java/android/telephony/ims/stub/ImsRegistrationImplBase.java
@@ -17,6 +17,8 @@
package android.telephony.ims.stub;
import android.annotation.IntDef;
+import android.annotation.IntRange;
+import android.annotation.Nullable;
import android.annotation.SystemApi;
import android.net.Uri;
import android.os.RemoteException;
@@ -126,6 +128,57 @@
}
/**
+ * Called by the framework to request that the ImsService perform the network registration
+ * of all SIP delegates associated with this ImsService.
+ * <p>
+ * If the SIP delegate feature tag configuration has changed, then this method will be
+ * called in order to let the ImsService know that it can pick up these changes in the IMS
+ * registration.
+ * @hide
+ */
+ public void updateSipDelegateRegistration() {
+ // Stub implementation, ImsService should implement this
+ }
+
+
+ /**
+ * Called by the framework to request that the ImsService perform the network deregistration of
+ * all SIP delegates associated with this ImsService.
+ * <p>
+ * This is typically called in situations where the user has changed the configuration of the
+ * device (for example, the default messaging application) and the framework is reconfiguring
+ * the tags associated with each IMS application.
+ * <p>
+ * This should not affect the registration of features managed by the ImsService itself, such as
+ * feature tags related to MMTEL registration.
+ * @hide
+ */
+ public void triggerSipDelegateDeregistration() {
+ // Stub implementation, ImsService should implement this
+ }
+
+ /**
+ * Called by the framework to notify the ImsService that a SIP delegate connection has received
+ * a SIP message containing a permanent failure response (such as a 403) or an indication that a
+ * SIP response timer has timed out in response to an outgoing SIP message. This method will be
+ * called when this condition occurs to trigger the ImsService to tear down the full IMS
+ * registration and re-register again.
+ *
+ * @param sipCode The SIP error code that represents a permanent failure that was received in
+ * response to a request generated by the IMS application. See RFC3261 7.2 for the general
+ * classes of responses available here, however the codes that generate this condition may
+ * be carrier specific.
+ * @param sipReason The reason associated with the SIP error code. {@code null} if there was no
+ * reason associated with the error.
+ * @hide
+ */
+ public void triggerNetworkReregistration(@IntRange(from = 100, to = 699) int sipCode,
+ @Nullable String sipReason) {
+ // Stub implementation, ImsService should implement this
+ }
+
+
+ /**
* Notify the framework that the device is connected to the IMS network.
*
* @param imsRadioTech the radio access technology. Valid values are defined as
diff --git a/telephony/java/android/telephony/ims/stub/SipDelegate.java b/telephony/java/android/telephony/ims/stub/SipDelegate.java
new file mode 100644
index 0000000..3ec9709
--- /dev/null
+++ b/telephony/java/android/telephony/ims/stub/SipDelegate.java
@@ -0,0 +1,91 @@
+/*
+ * Copyright (C) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package android.telephony.ims.stub;
+
+import android.annotation.NonNull;
+import android.telephony.ims.DelegateMessageCallback;
+import android.telephony.ims.ImsService;
+import android.telephony.ims.SipDelegateImsConfiguration;
+import android.telephony.ims.SipDelegateManager;
+import android.telephony.ims.SipMessage;
+
+/**
+ * The {@link SipDelegate} is implemented by the {@link ImsService} and allows a privileged
+ * IMS application to use this delegate to send SIP messages as well as acknowledge the receipt of
+ * incoming SIP messages delivered to the application over the existing IMS registration, allowing
+ * for a single IMS registration for multiple IMS applications.
+ * <p>
+ * Once the SIP delegate is created for that application,
+ * {@link ImsRegistrationImplBase#updateSipDelegateRegistration()} will be called, indicating that
+ * the application is finished setting up SipDelegates and the existing IMS registration may be
+ * modified to include the features managed by these SipDelegates.
+ * <p>
+ * This SipDelegate will need to notify the remote application of the registration of these features
+ * as well as the associated {@link SipDelegateImsConfiguration} before the application can start
+ * sending/receiving SIP messages via the transport. See
+ * {@link android.telephony.ims.DelegateStateCallback} for more information.
+ * @hide
+ */
+public interface SipDelegate {
+
+ /**
+ * The framework calls this method when a remote RCS application wishes to send a new outgoing
+ * SIP message.
+ * <p>
+ * Once sent, this SIP delegate should notify the remote application of the success or
+ * failure using {@link DelegateMessageCallback#onMessageSent(String)} or
+ * {@link DelegateMessageCallback#onMessageSendFailure(String, int)}.
+ * @param message The SIP message to be sent over the operator’s network.
+ * @param configVersion The SipDelegateImsConfiguration version used to construct the
+ * SipMessage. See {@link SipDelegateImsConfiguration} for more information. If the
+ * version specified here does not match the most recently constructed
+ * {@link SipDelegateImsConfiguration}, this message should fail validation checks and
+ * {@link DelegateMessageCallback#onMessageSendFailure} should be called with code
+ * {@link SipDelegateManager#MESSAGE_FAILURE_REASON_STALE_IMS_CONFIGURATION}.
+ */
+ void sendMessage(@NonNull SipMessage message, int configVersion);
+
+ /**
+ * The framework is requesting that routing resources associated with the SIP dialog using the
+ * provided Call-ID to be cleaned up.
+ * <p>
+ * Typically a SIP Dialog close event will be signalled by that dialog receiving a BYE or 200 OK
+ * message, however, in some cases, the framework will request that the ImsService close the
+ * dialog due to the open dialog holding up an event such as applying a provisioning change or
+ * handing over to another transport type.
+ * @param callId The call-ID header value associated with the ongoing SIP Dialog that the
+ * framework is requesting be closed.
+ */
+ void closeDialog(@NonNull String callId);
+
+ /**
+ * The remote application has received the SIP message and is processing it.
+ * @param viaTransactionId The Transaction ID found in the via header field of the
+ * previously sent {@link SipMessage}.
+ */
+ void notifyMessageReceived(@NonNull String viaTransactionId);
+
+ /**
+ * The remote application has either not received the SIP message or there was an error
+ * processing it.
+ * @param viaTransactionId The Transaction ID found in the via header field of the
+ * previously sent {@link SipMessage}.
+ * @param reason The reason why the message was not correctly received.
+ */
+ void notifyMessageReceiveError(@NonNull String viaTransactionId,
+ @SipDelegateManager.MessageFailureReason int reason);
+}
diff --git a/telephony/java/android/telephony/ims/stub/SipTransportImplBase.java b/telephony/java/android/telephony/ims/stub/SipTransportImplBase.java
index b2b2914..b48f631 100644
--- a/telephony/java/android/telephony/ims/stub/SipTransportImplBase.java
+++ b/telephony/java/android/telephony/ims/stub/SipTransportImplBase.java
@@ -18,27 +18,75 @@
import android.annotation.NonNull;
import android.annotation.SystemApi;
+import android.os.Binder;
+import android.os.IBinder;
+import android.telephony.ims.DelegateMessageCallback;
+import android.telephony.ims.DelegateRequest;
+import android.telephony.ims.DelegateStateCallback;
+import android.telephony.ims.SipDelegateManager;
+import android.telephony.ims.aidl.ISipDelegate;
+import android.telephony.ims.aidl.ISipDelegateMessageCallback;
+import android.telephony.ims.aidl.ISipDelegateStateCallback;
import android.telephony.ims.aidl.ISipTransport;
+import android.telephony.ims.aidl.SipDelegateAidlWrapper;
+import android.util.Log;
+import java.util.ArrayList;
+import java.util.List;
+import java.util.Objects;
import java.util.concurrent.Executor;
/**
- * Manages the creation and destruction of SipDelegates in order to proxy SIP traffic to other
- * IMS applications in order to support IMS single registration.
+ * The ImsService implements this class to manage the creation and destruction of
+ * {@link SipDelegate}s.
+ *
+ * {@link SipDelegate}s allow the ImsService to forward SIP traffic generated and consumed by IMS
+ * applications as a delegate to the associated carrier's IMS Network in order to support using a
+ * single IMS registration for all MMTEL and RCS signalling traffic.
* @hide
*/
@SystemApi
public class SipTransportImplBase {
+ private static final String LOG_TAG = "SipTransportIB";
+
+ private IBinder.DeathRecipient mDeathRecipient = new IBinder.DeathRecipient() {
+ @Override
+ public void binderDied() {
+ mBinderExecutor.execute(() -> binderDiedInternal());
+ }
+ };
+
+ private final ISipTransport.Stub mSipTransportImpl = new ISipTransport.Stub() {
+ @Override
+ public void createSipDelegate(DelegateRequest request, ISipDelegateStateCallback dc,
+ ISipDelegateMessageCallback mc) {
+ final long token = Binder.clearCallingIdentity();
+ try {
+ mBinderExecutor.execute(() -> createSipDelegateInternal(request, dc, mc));
+ } finally {
+ Binder.restoreCallingIdentity(token);
+ }
+ }
+
+ @Override
+ public void destroySipDelegate(ISipDelegate delegate, int reason) {
+ final long token = Binder.clearCallingIdentity();
+ try {
+ mBinderExecutor.execute(() -> destroySipDelegateInternal(delegate, reason));
+ } finally {
+ Binder.restoreCallingIdentity(token);
+ }
+ }
+ };
private final Executor mBinderExecutor;
- private final ISipTransport mSipTransportImpl = new ISipTransport.Stub() {
-
- };
+ private final ArrayList<SipDelegateAidlWrapper> mDelegates = new ArrayList<>();
/**
* Create an implementation of SipTransportImplBase.
*
- * @param executor The executor that remote calls from the framework should be called on.
+ * @param executor The executor that remote calls from the framework will be called on. This
+ * includes the methods here as well as the methods in {@link SipDelegate}.
*/
public SipTransportImplBase(@NonNull Executor executor) {
if (executor == null) {
@@ -49,6 +97,79 @@
}
/**
+ * Called by the Telephony framework to request the creation of a new {@link SipDelegate}.
+ * <p>
+ * The implementation must call {@link DelegateStateCallback#onCreated(SipDelegate, List)} with
+ * the {@link SipDelegate} that is associated with the {@link DelegateRequest}.
+ * <p>
+ * This method will be called on the Executor specified in
+ * {@link SipTransportImplBase#SipTransportImplBase(Executor)}.
+ *
+ * @param request A SIP delegate request containing the parameters that the remote RCS
+ * application wishes to use.
+ * @param dc A callback back to the remote application to be used to communicate state callbacks
+ * for the SipDelegate.
+ * @param mc A callback back to the remote application to be used to send SIP messages to the
+ * remote application and acknowledge the sending of outgoing SIP messages.
+ * @hide
+ */
+ public void createSipDelegate(@NonNull DelegateRequest request,
+ @NonNull DelegateStateCallback dc, @NonNull DelegateMessageCallback mc) {
+ throw new UnsupportedOperationException("destroySipDelegate not implemented!");
+ }
+
+ /**
+ * Destroys the SipDelegate associated with a remote IMS application.
+ * <p>
+ * After the delegate is destroyed, {@link DelegateStateCallback#onDestroyed(int)} must be
+ * called to notify listeners of its destruction to release associated resources.
+ * <p>
+ * This method will be called on the Executor specified in
+ * {@link SipTransportImplBase#SipTransportImplBase(Executor)}.
+ * @param delegate The delegate to be destroyed.
+ * @param reason The reason the remote connection to this {@link SipDelegate} is being
+ * destroyed.
+ * @hide
+ */
+ public void destroySipDelegate(@NonNull SipDelegate delegate,
+ @SipDelegateManager.SipDelegateDestroyReason int reason) {
+ throw new UnsupportedOperationException("destroySipDelegate not implemented!");
+ }
+
+ private void createSipDelegateInternal(DelegateRequest r, ISipDelegateStateCallback cb,
+ ISipDelegateMessageCallback mc) {
+ SipDelegateAidlWrapper wrapper = new SipDelegateAidlWrapper(mBinderExecutor, cb, mc);
+ mDelegates.add(wrapper);
+ createSipDelegate(r, wrapper, wrapper);
+ }
+
+ private void destroySipDelegateInternal(ISipDelegate d, int reason) {
+ SipDelegateAidlWrapper result = null;
+ for (SipDelegateAidlWrapper w : mDelegates) {
+ if (Objects.equals(d, w.getDelegateBinder())) {
+ result = w;
+ break;
+ }
+ }
+
+ if (result != null) {
+ mDelegates.remove(result);
+ destroySipDelegate(result.getDelegate(), reason);
+ } else {
+ Log.w(LOG_TAG, "destroySipDelegateInternal, could not findSipDelegate corresponding to "
+ + d);
+ }
+ }
+
+ private void binderDiedInternal() {
+ for (SipDelegateAidlWrapper w : mDelegates) {
+ destroySipDelegate(w.getDelegate(),
+ SipDelegateManager.SIP_DELEGATE_DESTROY_REASON_SERVICE_DEAD);
+ }
+ mDelegates.clear();
+ }
+
+ /**
* @return The IInterface used by the framework.
* @hide
*/
diff --git a/tests/FlickerTests/src/com/android/server/wm/flicker/CommonAssertions.kt b/tests/FlickerTests/src/com/android/server/wm/flicker/CommonAssertions.kt
index db0eed8..a85e92c 100644
--- a/tests/FlickerTests/src/com/android/server/wm/flicker/CommonAssertions.kt
+++ b/tests/FlickerTests/src/com/android/server/wm/flicker/CommonAssertions.kt
@@ -16,6 +16,7 @@
package com.android.server.wm.flicker
+import android.platform.helpers.IAppHelper
import com.android.server.wm.flicker.dsl.EventLogAssertion
import com.android.server.wm.flicker.dsl.LayersAssertion
import com.android.server.wm.flicker.dsl.WmAssertion
@@ -24,6 +25,7 @@
const val NAVIGATION_BAR_WINDOW_TITLE = "NavigationBar"
const val STATUS_BAR_WINDOW_TITLE = "StatusBar"
const val DOCKED_STACK_DIVIDER = "DockedStackDivider"
+const val WALLPAPER_TITLE = "Wallpaper"
@JvmOverloads
fun WmAssertion.statusBarWindowIsAlwaysVisible(
@@ -54,6 +56,39 @@
}
}
+fun WmAssertion.launcherReplacesAppWindowAsTopWindow(
+ testApp: IAppHelper,
+ bugId: Int = 0,
+ enabled: Boolean = bugId == 0
+) {
+ all("launcherReplacesAppWindowAsTopWindow", bugId, enabled) {
+ this.showsAppWindowOnTop(testApp.getPackage())
+ .then()
+ .showsAppWindowOnTop("Launcher")
+ }
+}
+
+fun WmAssertion.wallpaperWindowBecomesVisible(
+ bugId: Int = 0,
+ enabled: Boolean = bugId == 0
+) {
+ all("wallpaperWindowBecomesVisible", bugId, enabled) {
+ this.hidesBelowAppWindow(WALLPAPER_TITLE)
+ .then()
+ .showsBelowAppWindow(WALLPAPER_TITLE)
+ }
+}
+
+fun WmAssertion.windowAlwaysVisible(
+ packageName: String,
+ bugId: Int = 0,
+ enabled: Boolean = bugId == 0
+) {
+ all("windowAlwaysVisible", bugId, enabled) {
+ this.showsAppWindowOnTop(packageName)
+ }
+}
+
@JvmOverloads
fun LayersAssertion.noUncoveredRegions(
beginRotation: Int,
@@ -177,6 +212,28 @@
}
}
+fun LayersAssertion.wallpaperLayerReplacesAppLayer(
+ testApp: IAppHelper,
+ bugId: Int = 0,
+ enabled: Boolean = bugId == 0
+) {
+ all("appLayerReplacesWallpaperLayer", bugId, enabled) {
+ this.showsLayer(testApp.getPackage())
+ .then()
+ .replaceVisibleLayer(testApp.getPackage(), WALLPAPER_TITLE)
+ }
+}
+
+fun LayersAssertion.layerAlwaysVisible(
+ packageName: String,
+ bugId: Int = 0,
+ enabled: Boolean = bugId == 0
+) {
+ all("layerAlwaysVisible", bugId, enabled) {
+ this.showsLayer(packageName)
+ }
+}
+
fun EventLogAssertion.focusChanges(
vararg windows: String,
bugId: Int = 0,
diff --git a/tests/FlickerTests/src/com/android/server/wm/flicker/close/CloseAppBackButtonTest.kt b/tests/FlickerTests/src/com/android/server/wm/flicker/close/CloseAppBackButtonTest.kt
index 01853df..a20f96d 100644
--- a/tests/FlickerTests/src/com/android/server/wm/flicker/close/CloseAppBackButtonTest.kt
+++ b/tests/FlickerTests/src/com/android/server/wm/flicker/close/CloseAppBackButtonTest.kt
@@ -20,8 +20,21 @@
import androidx.test.filters.RequiresDevice
import androidx.test.platform.app.InstrumentationRegistry
import com.android.server.wm.flicker.Flicker
+import com.android.server.wm.flicker.endRotation
import com.android.server.wm.flicker.FlickerTestRunnerFactory
import com.android.server.wm.flicker.FlickerTestRunner
+import com.android.server.wm.flicker.navBarWindowIsAlwaysVisible
+import com.android.server.wm.flicker.statusBarWindowIsAlwaysVisible
+import com.android.server.wm.flicker.navBarLayerIsAlwaysVisible
+import com.android.server.wm.flicker.statusBarLayerIsAlwaysVisible
+import com.android.server.wm.flicker.launcherReplacesAppWindowAsTopWindow
+import com.android.server.wm.flicker.wallpaperWindowBecomesVisible
+import com.android.server.wm.flicker.wallpaperLayerReplacesAppLayer
+import com.android.server.wm.flicker.noUncoveredRegions
+import com.android.server.wm.flicker.navBarLayerRotatesAndScales
+import com.android.server.wm.flicker.statusBarLayerRotatesScales
+import com.android.server.wm.flicker.visibleWindowsShownMoreThanOneConsecutiveEntry
+import com.android.server.wm.flicker.visibleLayersShownMoreThanOneConsecutiveEntry
import com.android.server.wm.flicker.helpers.wakeUpAndGoToHomeScreen
import com.android.server.wm.flicker.helpers.StandardAppHelper
import com.android.server.wm.flicker.helpers.buildTestTag
@@ -34,22 +47,6 @@
import org.junit.runners.MethodSorters
import org.junit.runners.Parameterized
-/*
- * Copyright (C) 2020 The Android Open Source Project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
/**
* Test app closes by pressing back button
* To run this test: `atest FlickerTests:CloseAppBackButtonTest`
@@ -93,6 +90,32 @@
testApp.exit()
}
}
+ assertions {
+ windowManagerTrace {
+ navBarWindowIsAlwaysVisible()
+ statusBarWindowIsAlwaysVisible()
+ visibleWindowsShownMoreThanOneConsecutiveEntry()
+
+ launcherReplacesAppWindowAsTopWindow(testApp)
+ wallpaperWindowBecomesVisible()
+ }
+
+ layersTrace {
+ noUncoveredRegions(configuration.startRotation,
+ Surface.ROTATION_0, bugId = 141361128)
+ navBarLayerRotatesAndScales(configuration.startRotation,
+ Surface.ROTATION_0)
+ statusBarLayerRotatesScales(configuration.startRotation,
+ Surface.ROTATION_0)
+ navBarLayerIsAlwaysVisible(
+ enabled = Surface.ROTATION_0 == configuration.endRotation)
+ statusBarLayerIsAlwaysVisible(
+ enabled = Surface.ROTATION_0 == configuration.endRotation)
+ visibleLayersShownMoreThanOneConsecutiveEntry()
+
+ wallpaperLayerReplacesAppLayer(testApp)
+ }
+ }
}
}
}
diff --git a/tests/FlickerTests/src/com/android/server/wm/flicker/close/CloseAppHomeButtonTest.kt b/tests/FlickerTests/src/com/android/server/wm/flicker/close/CloseAppHomeButtonTest.kt
new file mode 100644
index 0000000..b0a1565
--- /dev/null
+++ b/tests/FlickerTests/src/com/android/server/wm/flicker/close/CloseAppHomeButtonTest.kt
@@ -0,0 +1,83 @@
+/*
+ * Copyright (C) 2020 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package com.android.server.wm.flicker.close
+
+import android.view.Surface
+import androidx.test.filters.RequiresDevice
+import androidx.test.platform.app.InstrumentationRegistry
+import com.android.server.wm.flicker.Flicker
+import com.android.server.wm.flicker.FlickerTestRunnerFactory
+import com.android.server.wm.flicker.FlickerTestRunner
+import com.android.server.wm.flicker.helpers.StandardAppHelper
+import com.android.server.wm.flicker.helpers.buildTestTag
+import com.android.server.wm.flicker.helpers.setRotation
+import com.android.server.wm.flicker.helpers.wakeUpAndGoToHomeScreen
+import com.android.server.wm.flicker.helpers.waitUntilGone
+import com.android.server.wm.flicker.repetitions
+import com.android.server.wm.flicker.startRotation
+import org.junit.FixMethodOrder
+import org.junit.runner.RunWith
+import org.junit.runners.MethodSorters
+import org.junit.runners.Parameterized
+
+/**
+ * Test app closes by pressing home button.
+ * To run this test: `atest FlickerTests:CloseAppHomeButtonTest`
+ */
+@RequiresDevice
+@RunWith(Parameterized::class)
+@FixMethodOrder(MethodSorters.NAME_ASCENDING)
+class CloseAppHomeButtonTest(
+ testName: String,
+ flickerSpec: Flicker
+) : FlickerTestRunner(testName, flickerSpec) {
+ companion object {
+ @Parameterized.Parameters(name = "{0}")
+ @JvmStatic
+ fun getParams(): List<Array<Any>> {
+ val instrumentation = InstrumentationRegistry.getInstrumentation()
+ val testApp = StandardAppHelper(instrumentation,
+ "com.android.server.wm.flicker.testapp", "SimpleApp")
+ return FlickerTestRunnerFactory(instrumentation, repetitions = 10)
+ .buildTest { configuration ->
+ withTestName { buildTestTag("closeAppHomeButton", testApp, configuration) }
+ repeat { configuration.repetitions }
+ setup {
+ test {
+ device.wakeUpAndGoToHomeScreen()
+ }
+ eachRun {
+ this.setRotation(configuration.startRotation)
+ testApp.open()
+ }
+ }
+ transitions {
+ device.pressHome()
+ device.waitUntilGone(testApp.getPackage())
+ }
+ teardown {
+ eachRun {
+ this.setRotation(Surface.ROTATION_0)
+ }
+ test {
+ testApp.exit()
+ }
+ }
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git a/tests/FlickerTests/src/com/android/server/wm/flicker/rotation/SeamlessAppRotationTest.kt b/tests/FlickerTests/src/com/android/server/wm/flicker/rotation/SeamlessAppRotationTest.kt
index d100383..a1a7102 100644
--- a/tests/FlickerTests/src/com/android/server/wm/flicker/rotation/SeamlessAppRotationTest.kt
+++ b/tests/FlickerTests/src/com/android/server/wm/flicker/rotation/SeamlessAppRotationTest.kt
@@ -30,6 +30,8 @@
import com.android.server.wm.flicker.FlickerTestRunnerFactory
import com.android.server.wm.flicker.endRotation
import com.android.server.wm.flicker.focusDoesNotChange
+import com.android.server.wm.flicker.windowAlwaysVisible
+import com.android.server.wm.flicker.layerAlwaysVisible
import com.android.server.wm.flicker.helpers.WindowUtils
import com.android.server.wm.flicker.helpers.buildTestTag
import com.android.server.wm.flicker.helpers.setRotation
@@ -39,6 +41,8 @@
import com.android.server.wm.flicker.navBarLayerRotatesAndScales
import com.android.server.wm.flicker.navBarWindowIsAlwaysVisible
import com.android.server.wm.flicker.noUncoveredRegions
+import com.android.server.wm.flicker.visibleWindowsShownMoreThanOneConsecutiveEntry
+import com.android.server.wm.flicker.visibleLayersShownMoreThanOneConsecutiveEntry
import com.android.server.wm.flicker.repetitions
import com.android.server.wm.flicker.startRotation
import com.android.server.wm.flicker.statusBarLayerIsAlwaysVisible
@@ -141,6 +145,8 @@
windowManagerTrace {
navBarWindowIsAlwaysVisible(bugId = 140855415)
statusBarWindowIsAlwaysVisible(bugId = 140855415)
+ visibleWindowsShownMoreThanOneConsecutiveEntry()
+ windowAlwaysVisible(configuration.intentPackageName)
}
layersTrace {
@@ -152,6 +158,9 @@
configuration.endRotation)
statusBarLayerRotatesScales(configuration.startRotation,
configuration.endRotation, enabled = false)
+ visibleLayersShownMoreThanOneConsecutiveEntry(
+ enabled = configuration.startRotation == configuration.endRotation)
+ layerAlwaysVisible(configuration.intentPackageName)
}
layersTrace {
diff --git a/tools/aapt/Resource.cpp b/tools/aapt/Resource.cpp
index ab6dced..dd3ebdb 100644
--- a/tools/aapt/Resource.cpp
+++ b/tools/aapt/Resource.cpp
@@ -519,7 +519,7 @@
String8(parser.getElementName(&len)).string(), attr);
return ATTR_NOT_FOUND;
}
- if ((str=pool->stringAt(value.data, &len)) == NULL) {
+ if ((str = UnpackOptionalString(pool->stringAt(value.data), &len)) == NULL) {
fprintf(stderr, "%s:%d: Tag <%s> attribute %s has corrupt string value.\n",
path.string(), parser.getLineNumber(),
String8(parser.getElementName(&len)).string(), attr);
diff --git a/tools/aapt/ResourceTable.cpp b/tools/aapt/ResourceTable.cpp
index d02f44e..257e96b 100644
--- a/tools/aapt/ResourceTable.cpp
+++ b/tools/aapt/ResourceTable.cpp
@@ -3066,7 +3066,7 @@
for (size_t ti=0; ti<N; ti++) {
// Retrieve them in the same order as the type string block.
size_t len;
- String16 typeName(p->getTypeStrings().stringAt(ti, &len));
+ String16 typeName(UnpackOptionalString(p->getTypeStrings().stringAt(ti), &len));
sp<Type> t = p->getTypes().valueFor(typeName);
LOG_ALWAYS_FATAL_IF(t == NULL && typeName != String16("<empty>"),
"Type name %s not found",
@@ -4169,7 +4169,7 @@
const size_t N = strings->size();
for (size_t i=0; i<N; i++) {
size_t len;
- mappings->add(String16(strings->stringAt(i, &len)), i);
+ mappings->add(String16(UnpackOptionalString(strings->stringAt(i), &len)), i);
}
}
return err;
diff --git a/tools/aapt/StringPool.cpp b/tools/aapt/StringPool.cpp
index 37b61bf..6cacd32 100644
--- a/tools/aapt/StringPool.cpp
+++ b/tools/aapt/StringPool.cpp
@@ -52,9 +52,9 @@
for (size_t i=0; i<N; i++) {
size_t len;
if (pool->isUTF8()) {
- uniqueStrings.add(pool->string8At(i, &len));
+ uniqueStrings.add(UnpackOptionalString(pool->string8At(i), &len));
} else {
- uniqueStrings.add(pool->stringAt(i, &len));
+ uniqueStrings.add(UnpackOptionalString(pool->stringAt(i), &len));
}
}
@@ -66,8 +66,8 @@
const size_t NS = pool->size();
for (size_t s=0; s<NS; s++) {
- String8 str = pool->string8ObjectAt(s);
- printf("String #" ZD ": %s\n", (ZD_TYPE) s, str.string());
+ auto str = pool->string8ObjectAt(s);
+ printf("String #" ZD ": %s\n", (ZD_TYPE) s, (str.has_value() ? str->string() : ""));
}
}
diff --git a/tools/aapt2/Debug.cpp b/tools/aapt2/Debug.cpp
index 439f231..82da249 100644
--- a/tools/aapt2/Debug.cpp
+++ b/tools/aapt2/Debug.cpp
@@ -436,9 +436,9 @@
for (size_t i=0; i<N; i++) {
size_t len;
if (pool->isUTF8()) {
- uniqueStrings.add(pool->string8At(i, &len));
+ uniqueStrings.add(UnpackOptionalString(pool->string8At(i), &len));
} else {
- uniqueStrings.add(pool->stringAt(i, &len));
+ uniqueStrings.add(UnpackOptionalString(pool->stringAt(i), &len));
}
}
@@ -450,8 +450,8 @@
const size_t NS = pool->size();
for (size_t s=0; s<NS; s++) {
- String8 str = pool->string8ObjectAt(s);
- printer->Print(StringPrintf("String #%zd : %s\n", s, str.string()));
+ auto str = pool->string8ObjectAt(s);
+ printer->Print(StringPrintf("String #%zd : %s\n", s, str.has_value() ? str->string() : ""));
}
}
diff --git a/tools/aapt2/ResourceUtils.cpp b/tools/aapt2/ResourceUtils.cpp
index 7dfc983..5b43df6 100644
--- a/tools/aapt2/ResourceUtils.cpp
+++ b/tools/aapt2/ResourceUtils.cpp
@@ -751,10 +751,12 @@
switch (res_value.dataType) {
case android::Res_value::TYPE_STRING: {
const std::string str = util::GetString(src_pool, data);
- const android::ResStringPool_span* spans = src_pool.styleAt(data);
+ auto spans_result = src_pool.styleAt(data);
// Check if the string has a valid style associated with it.
- if (spans != nullptr && spans->name.index != android::ResStringPool_span::END) {
+ if (spans_result.has_value() &&
+ (*spans_result)->name.index != android::ResStringPool_span::END) {
+ const android::ResStringPool_span* spans = spans_result->unsafe_ptr();
StyleString style_str = {str};
while (spans->name.index != android::ResStringPool_span::END) {
style_str.spans.push_back(Span{util::GetString(src_pool, spans->name.index),
diff --git a/tools/aapt2/StringPool_test.cpp b/tools/aapt2/StringPool_test.cpp
index 9a7238b..6e5200b 100644
--- a/tools/aapt2/StringPool_test.cpp
+++ b/tools/aapt2/StringPool_test.cpp
@@ -223,11 +223,11 @@
std::unique_ptr<uint8_t[]> data = util::Copy(buffer);
ResStringPool test;
ASSERT_EQ(test.setTo(data.get(), buffer.size()), NO_ERROR);
- size_t len = 0;
- const char16_t* str = test.stringAt(0, &len);
- EXPECT_THAT(len, Eq(1u));
- EXPECT_THAT(str, Pointee(Eq(u'\u093f')));
- EXPECT_THAT(str[1], Eq(0u));
+ auto str = test.stringAt(0);
+ ASSERT_TRUE(str.has_value());
+ EXPECT_THAT(str->size(), Eq(1u));
+ EXPECT_THAT(str->data(), Pointee(Eq(u'\u093f')));
+ EXPECT_THAT(str->data()[1], Eq(0u));
}
constexpr const char* sLongString =
@@ -278,14 +278,15 @@
EXPECT_THAT(util::GetString(test, 3), Eq(sLongString));
EXPECT_THAT(util::GetString16(test, 3), Eq(util::Utf8ToUtf16(sLongString)));
- size_t len;
- EXPECT_TRUE(test.stringAt(4, &len) != nullptr || test.string8At(4, &len) != nullptr);
+ EXPECT_TRUE(test.stringAt(4).has_value() || test.string8At(4).has_value());
EXPECT_THAT(util::GetString(test, 0), Eq("style"));
EXPECT_THAT(util::GetString16(test, 0), Eq(u"style"));
- const ResStringPool_span* span = test.styleAt(0);
- ASSERT_THAT(span, NotNull());
+ auto span_result = test.styleAt(0);
+ ASSERT_TRUE(span_result.has_value());
+
+ const ResStringPool_span* span = span_result->unsafe_ptr();
EXPECT_THAT(util::GetString(test, span->name.index), Eq("b"));
EXPECT_THAT(util::GetString16(test, span->name.index), Eq(u"b"));
EXPECT_THAT(span->firstChar, Eq(0u));
@@ -318,16 +319,17 @@
// Check that the codepoints are encoded using two three-byte surrogate pairs
ResStringPool test;
ASSERT_EQ(test.setTo(data.get(), buffer.size()), NO_ERROR);
- size_t len;
- const char* str = test.string8At(0, &len);
- ASSERT_THAT(str, NotNull());
- EXPECT_THAT(std::string(str, len), Eq("\xED\xA0\x81\xED\xB0\x80"));
- str = test.string8At(1, &len);
- ASSERT_THAT(str, NotNull());
- EXPECT_THAT(std::string(str, len), Eq("foo \xED\xA0\x81\xED\xB0\xB7 bar"));
- str = test.string8At(2, &len);
- ASSERT_THAT(str, NotNull());
- EXPECT_THAT(std::string(str, len), Eq("\xED\xA0\x81\xED\xB0\x80\xED\xA0\x81\xED\xB0\xB7"));
+ auto str = test.string8At(0);
+ ASSERT_TRUE(str.has_value());
+ EXPECT_THAT(str->to_string(), Eq("\xED\xA0\x81\xED\xB0\x80"));
+
+ str = test.string8At(1);
+ ASSERT_TRUE(str.has_value());
+ EXPECT_THAT(str->to_string(), Eq("foo \xED\xA0\x81\xED\xB0\xB7 bar"));
+
+ str = test.string8At(2);
+ ASSERT_TRUE(str.has_value());
+ EXPECT_THAT(str->to_string(), Eq("\xED\xA0\x81\xED\xB0\x80\xED\xA0\x81\xED\xB0\xB7"));
// Check that retrieving the strings returns the original UTF-8 character bytes
EXPECT_THAT(util::GetString(test, 0), Eq("\xF0\x90\x90\x80"));
diff --git a/tools/aapt2/cmd/Compile_test.cpp b/tools/aapt2/cmd/Compile_test.cpp
index 0aab94d3..8cbd998 100644
--- a/tools/aapt2/cmd/Compile_test.cpp
+++ b/tools/aapt2/cmd/Compile_test.cpp
@@ -314,8 +314,10 @@
ASSERT_NE(content_values.find(relative_path_values_colors), -1);
ASSERT_EQ(content_values.find(path_values_colors), -1);
- Link({"-o", apk_path, "--manifest", GetDefaultManifest(), "--proto-format"},
- compiled_files_dir, &diag);
+ ASSERT_TRUE(Link({"-o", apk_path,
+ "--manifest", GetDefaultManifest(),
+ "--proto-format"},
+ compiled_files_dir, &diag));
std::unique_ptr<LoadedApk> apk = LoadedApk::LoadApkFromPath(apk_path, &diag);
ResourceTable* resource_table = apk.get()->GetResourceTable();
diff --git a/tools/aapt2/cmd/Link.cpp b/tools/aapt2/cmd/Link.cpp
index 118a76f..f92c602 100644
--- a/tools/aapt2/cmd/Link.cpp
+++ b/tools/aapt2/cmd/Link.cpp
@@ -732,22 +732,6 @@
return true;
}
-static android::ApkAssetsCookie FindFrameworkAssetManagerCookie(
- const android::AssetManager2& assets) {
- using namespace android;
-
- // Find the system package (0x01). AAPT always generates attributes with the type 0x01, so
- // we're looking for the first attribute resource in the system package.
- Res_value val{};
- ResTable_config config{};
- uint32_t type_spec_flags;
- ApkAssetsCookie idx = assets.GetResource(0x01010000, true /** may_be_bag */,
- 0 /** density_override */, &val, &config,
- &type_spec_flags);
-
- return idx;
-}
-
class Linker {
public:
Linker(LinkContext* context, const LinkOptions& options)
@@ -760,8 +744,12 @@
void ExtractCompileSdkVersions(android::AssetManager2* assets) {
using namespace android;
- android::ApkAssetsCookie cookie = FindFrameworkAssetManagerCookie(*assets);
- if (cookie == android::kInvalidCookie) {
+ // Find the system package (0x01). AAPT always generates attributes with the type 0x01, so
+ // we're looking for the first attribute resource in the system package.
+ android::ApkAssetsCookie cookie;
+ if (auto value = assets->GetResource(0x01010000, true /** may_be_bag */); value.has_value()) {
+ cookie = value->cookie;
+ } else {
// No Framework assets loaded. Not a failure.
return;
}
diff --git a/tools/aapt2/format/binary/TableFlattener_test.cpp b/tools/aapt2/format/binary/TableFlattener_test.cpp
index 6932baf..f8b8a1c 100644
--- a/tools/aapt2/format/binary/TableFlattener_test.cpp
+++ b/tools/aapt2/format/binary/TableFlattener_test.cpp
@@ -189,16 +189,16 @@
ResTable_config::CONFIG_VERSION));
std::u16string foo_str = u"foo";
- ssize_t idx = res_table.getTableStringBlock(0)->indexOfString(foo_str.data(), foo_str.size());
- ASSERT_GE(idx, 0);
+ auto idx = res_table.getTableStringBlock(0)->indexOfString(foo_str.data(), foo_str.size());
+ ASSERT_TRUE(idx.has_value());
EXPECT_TRUE(Exists(&res_table, "com.app.test:string/test", ResourceId(0x7f040000), {},
- Res_value::TYPE_STRING, (uint32_t)idx, 0u));
+ Res_value::TYPE_STRING, (uint32_t)*idx, 0u));
std::u16string bar_path = u"res/layout/bar.xml";
idx = res_table.getTableStringBlock(0)->indexOfString(bar_path.data(), bar_path.size());
- ASSERT_GE(idx, 0);
+ ASSERT_TRUE(idx.has_value());
EXPECT_TRUE(Exists(&res_table, "com.app.test:layout/bar", ResourceId(0x7f050000), {},
- Res_value::TYPE_STRING, (uint32_t)idx, 0u));
+ Res_value::TYPE_STRING, (uint32_t)*idx, 0u));
}
TEST_F(TableFlattenerTest, FlattenEntriesWithGapsInIds) {
@@ -603,16 +603,16 @@
2u, ResTable_config::CONFIG_VERSION));
std::u16string foo_str = u"foo";
- ssize_t idx = res_table.getTableStringBlock(0)->indexOfString(foo_str.data(), foo_str.size());
- ASSERT_GE(idx, 0);
+ auto idx = res_table.getTableStringBlock(0)->indexOfString(foo_str.data(), foo_str.size());
+ ASSERT_TRUE(idx.has_value());
EXPECT_TRUE(Exists(&res_table, "com.app.test:string/0_resource_name_obfuscated",
- ResourceId(0x7f040000), {}, Res_value::TYPE_STRING, (uint32_t)idx, 0u));
+ ResourceId(0x7f040000), {}, Res_value::TYPE_STRING, (uint32_t)*idx, 0u));
std::u16string bar_path = u"res/layout/bar.xml";
idx = res_table.getTableStringBlock(0)->indexOfString(bar_path.data(), bar_path.size());
- ASSERT_GE(idx, 0);
+ ASSERT_TRUE(idx.has_value());
EXPECT_TRUE(Exists(&res_table, "com.app.test:layout/0_resource_name_obfuscated",
- ResourceId(0x7f050000), {}, Res_value::TYPE_STRING, (uint32_t)idx, 0u));
+ ResourceId(0x7f050000), {}, Res_value::TYPE_STRING, (uint32_t)*idx, 0u));
}
TEST_F(TableFlattenerTest, ObfuscatingResourceNamesWithNameCollapseExemptionsSucceeds) {
@@ -659,16 +659,16 @@
2u, ResTable_config::CONFIG_VERSION));
std::u16string foo_str = u"foo";
- ssize_t idx = res_table.getTableStringBlock(0)->indexOfString(foo_str.data(), foo_str.size());
- ASSERT_GE(idx, 0);
+ auto idx = res_table.getTableStringBlock(0)->indexOfString(foo_str.data(), foo_str.size());
+ ASSERT_TRUE(idx.has_value());
EXPECT_TRUE(Exists(&res_table, "com.app.test:string/test", ResourceId(0x7f040000), {},
- Res_value::TYPE_STRING, (uint32_t)idx, 0u));
+ Res_value::TYPE_STRING, (uint32_t)*idx, 0u));
std::u16string bar_path = u"res/layout/bar.xml";
idx = res_table.getTableStringBlock(0)->indexOfString(bar_path.data(), bar_path.size());
- ASSERT_GE(idx, 0);
+ ASSERT_TRUE(idx.has_value());
EXPECT_TRUE(Exists(&res_table, "com.app.test:layout/0_resource_name_obfuscated",
- ResourceId(0x7f050000), {}, Res_value::TYPE_STRING, (uint32_t)idx, 0u));
+ ResourceId(0x7f050000), {}, Res_value::TYPE_STRING, (uint32_t)*idx, 0u));
}
TEST_F(TableFlattenerTest, FlattenOverlayable) {
diff --git a/tools/aapt2/process/SymbolTable.cpp b/tools/aapt2/process/SymbolTable.cpp
index 897fa80..ad716c7 100644
--- a/tools/aapt2/process/SymbolTable.cpp
+++ b/tools/aapt2/process/SymbolTable.cpp
@@ -265,21 +265,22 @@
static std::unique_ptr<SymbolTable::Symbol> LookupAttributeInTable(
android::AssetManager2& am, ResourceId id) {
+ using namespace android;
if (am.GetApkAssets().empty()) {
return {};
}
- const android::ResolvedBag* bag = am.GetBag(id.id);
- if (bag == nullptr) {
+ auto bag_result = am.GetBag(id.id);
+ if (!bag_result.has_value()) {
return nullptr;
}
// We found a resource.
std::unique_ptr<SymbolTable::Symbol> s = util::make_unique<SymbolTable::Symbol>(id);
-
+ const ResolvedBag* bag = *bag_result;
const size_t count = bag->entry_count;
for (uint32_t i = 0; i < count; i++) {
- if (bag->entries[i].key == android::ResTable_map::ATTR_TYPE) {
+ if (bag->entries[i].key == ResTable_map::ATTR_TYPE) {
s->attribute = std::make_shared<Attribute>(bag->entries[i].value.data);
break;
}
@@ -287,25 +288,25 @@
if (s->attribute) {
for (size_t i = 0; i < count; i++) {
- const android::ResolvedBag::Entry& map_entry = bag->entries[i];
+ const ResolvedBag::Entry& map_entry = bag->entries[i];
if (Res_INTERNALID(map_entry.key)) {
switch (map_entry.key) {
- case android::ResTable_map::ATTR_MIN:
+ case ResTable_map::ATTR_MIN:
s->attribute->min_int = static_cast<int32_t>(map_entry.value.data);
break;
- case android::ResTable_map::ATTR_MAX:
+ case ResTable_map::ATTR_MAX:
s->attribute->max_int = static_cast<int32_t>(map_entry.value.data);
break;
}
continue;
}
- android::AssetManager2::ResourceName name;
- if (!am.GetResourceName(map_entry.key, &name)) {
+ auto name = am.GetResourceName(map_entry.key);
+ if (!name.has_value()) {
return nullptr;
}
- Maybe<ResourceName> parsed_name = ResourceUtils::ToResourceName(name);
+ Maybe<ResourceName> parsed_name = ResourceUtils::ToResourceName(*name);
if (!parsed_name) {
return nullptr;
}
@@ -328,7 +329,7 @@
bool found = false;
ResourceId res_id = 0;
- uint32_t type_spec_flags;
+ uint32_t type_spec_flags = 0;
ResourceName real_name;
// There can be mangled resources embedded within other packages. Here we will
@@ -340,8 +341,19 @@
real_name.package = package_name;
}
- res_id = asset_manager_.GetResourceId(real_name.to_string());
- if (res_id.is_valid_static() && asset_manager_.GetResourceFlags(res_id.id, &type_spec_flags)) {
+ auto real_res_id = asset_manager_.GetResourceId(real_name.to_string());
+ if (!real_res_id.has_value()) {
+ return true;
+ }
+
+ res_id.id = *real_res_id;
+ if (!res_id.is_valid_static()) {
+ return true;
+ }
+
+ auto value = asset_manager_.GetResource(res_id.id, true /* may_be_bag */);
+ if (value.has_value()) {
+ type_spec_flags = value->flags;
found = true;
return false;
}
@@ -371,11 +383,11 @@
static Maybe<ResourceName> GetResourceName(android::AssetManager2& am,
ResourceId id) {
- android::AssetManager2::ResourceName name;
- if (!am.GetResourceName(id.id, &name)) {
+ auto name = am.GetResourceName(id.id);
+ if (!name.has_value()) {
return {};
}
- return ResourceUtils::ToResourceName(name);
+ return ResourceUtils::ToResourceName(*name);
}
std::unique_ptr<SymbolTable::Symbol> AssetManagerSymbolSource::FindById(
@@ -394,9 +406,8 @@
return {};
}
-
- uint32_t type_spec_flags = 0;
- if (!asset_manager_.GetResourceFlags(id.id, &type_spec_flags)) {
+ auto value = asset_manager_.GetResource(id.id, true /* may_be_bag */);
+ if (!value.has_value()) {
return {};
}
@@ -411,7 +422,7 @@
}
if (s) {
- s->is_public = (type_spec_flags & android::ResTable_typeSpec::SPEC_PUBLIC) != 0;
+ s->is_public = (value->flags & android::ResTable_typeSpec::SPEC_PUBLIC) != 0;
return s;
}
return {};
diff --git a/tools/aapt2/util/Util.cpp b/tools/aapt2/util/Util.cpp
index 37ce65e..ef33c34 100644
--- a/tools/aapt2/util/Util.cpp
+++ b/tools/aapt2/util/Util.cpp
@@ -531,19 +531,15 @@
}
StringPiece16 GetString16(const android::ResStringPool& pool, size_t idx) {
- size_t len;
- const char16_t* str = pool.stringAt(idx, &len);
- if (str != nullptr) {
- return StringPiece16(str, len);
+ if (auto str = pool.stringAt(idx)) {
+ return *str;
}
return StringPiece16();
}
std::string GetString(const android::ResStringPool& pool, size_t idx) {
- size_t len;
- const char* str = pool.string8At(idx, &len);
- if (str != nullptr) {
- return ModifiedUtf8ToUtf8(std::string(str, len));
+ if (auto str = pool.string8At(idx)) {
+ return ModifiedUtf8ToUtf8(str->to_string());
}
return Utf16ToUtf8(GetString16(pool, idx));
}
diff --git a/tools/split-select/Main.cpp b/tools/split-select/Main.cpp
index d3eb012..e6966db 100644
--- a/tools/split-select/Main.cpp
+++ b/tools/split-select/Main.cpp
@@ -182,14 +182,18 @@
if (type >= Res_value::TYPE_FIRST_INT && type <= Res_value::TYPE_LAST_INT) {
outInfo.minSdkVersion = xml.getAttributeData(idx);
} else if (type == Res_value::TYPE_STRING) {
- String8 minSdk8(xml.getStrings().string8ObjectAt(idx));
- char* endPtr;
- int minSdk = strtol(minSdk8.string(), &endPtr, 10);
- if (endPtr != minSdk8.string() + minSdk8.size()) {
- fprintf(stderr, "warning: failed to parse android:minSdkVersion '%s'\n",
- minSdk8.string());
+ auto minSdk8 = xml.getStrings().string8ObjectAt(idx);
+ if (!minSdk8.has_value()) {
+ fprintf(stderr, "warning: failed to retrieve android:minSdkVersion.\n");
} else {
- outInfo.minSdkVersion = minSdk;
+ char *endPtr;
+ int minSdk = strtol(minSdk8->string(), &endPtr, 10);
+ if (endPtr != minSdk8->string() + minSdk8->size()) {
+ fprintf(stderr, "warning: failed to parse android:minSdkVersion '%s'\n",
+ minSdk8->string());
+ } else {
+ outInfo.minSdkVersion = minSdk;
+ }
}
} else {
fprintf(stderr, "warning: unrecognized value for android:minSdkVersion.\n");
diff --git a/wifi/jarjar-rules.txt b/wifi/jarjar-rules.txt
index dc96df6..d235c80 100644
--- a/wifi/jarjar-rules.txt
+++ b/wifi/jarjar-rules.txt
@@ -89,6 +89,8 @@
rule android.util.LocalLog* com.android.wifi.x.@0
rule android.util.Rational* com.android.wifi.x.@0
+rule android.os.BasicShellCommandHandler* com.android.wifi.x.@0
+
# Use our statically linked bouncy castle library
rule org.bouncycastle.** com.android.wifi.x.@0
# Use our statically linked protobuf library
diff --git a/wifi/java/android/net/wifi/RttManager.java b/wifi/java/android/net/wifi/RttManager.java
index 73c52ab..034defb 100644
--- a/wifi/java/android/net/wifi/RttManager.java
+++ b/wifi/java/android/net/wifi/RttManager.java
@@ -173,7 +173,7 @@
/** @deprecated Use the new {@link android.net.wifi.RttManager#getRttCapabilities()} API.*/
@Deprecated
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
public Capabilities getCapabilities() {
throw new UnsupportedOperationException(
"getCapabilities is not supported in the adaptation layer");
diff --git a/wifi/java/android/net/wifi/WifiScanner.java b/wifi/java/android/net/wifi/WifiScanner.java
index 41d0857..7c051f0 100644
--- a/wifi/java/android/net/wifi/WifiScanner.java
+++ b/wifi/java/android/net/wifi/WifiScanner.java
@@ -1267,7 +1267,7 @@
* @param bssidInfos access points to watch
*/
@Deprecated
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
public void configureWifiChange(
int rssiSampleSize, /* sample size for RSSI averaging */
int lostApSampleSize, /* samples to confirm AP's loss */
@@ -1301,7 +1301,7 @@
* provided on {@link #stopTrackingWifiChange}
*/
@Deprecated
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
public void startTrackingWifiChange(WifiChangeListener listener) {
throw new UnsupportedOperationException();
}
@@ -1312,7 +1312,7 @@
* #stopTrackingWifiChange}
*/
@Deprecated
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
public void stopTrackingWifiChange(WifiChangeListener listener) {
throw new UnsupportedOperationException();
}
@@ -1320,7 +1320,7 @@
/** @hide */
@SystemApi
@Deprecated
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
public void configureWifiChange(WifiChangeSettings settings) {
throw new UnsupportedOperationException();
}
@@ -1376,7 +1376,7 @@
* also be provided on {@link #stopTrackingBssids}
*/
@Deprecated
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
public void startTrackingBssids(BssidInfo[] bssidInfos,
int apLostThreshold, BssidListener listener) {
throw new UnsupportedOperationException();
@@ -1387,7 +1387,7 @@
* @param listener same object provided in {@link #startTrackingBssids}
*/
@Deprecated
- @SuppressLint("Doclava125")
+ @SuppressLint("RequiresPermission")
public void stopTrackingBssids(BssidListener listener) {
throw new UnsupportedOperationException();
}