Branch
Hash :
fca3eb6b
Author :
Date :
2023-12-12T23:00:41
Refactor ANGLE settings UI. This patch refactors the ANGLE settings UI to make sure it aligns better with the settings global variables. This patch: 1) moves all ANGLE rule parsing logic to its own class, the parsing will only parse the rule and store them, it currently does not set the settings global variables; 2) removes the global enablement as it is now an option in Developer options and that one has better guarding condition; 3) refactors the logic to query all packages in the system, instead of constructing them with raw package name, use application name to allow a more user-friendly UI, and also allow to toggle for system applications. 4) adds two new entries to allow building ANGLE apk without any ANGLE libraries; 5) adds a README.md file to document the design. 6) removes unused functions and variables and minor renames. Bug: b/293503000 Test: manual Change-Id: I7287935791c00040b0eacba7dce3e4df5eb4de3e Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/5118135 Reviewed-by: Cody Northrop <cnorthrop@google.com> Commit-Queue: Peiyong Lin <lpy@google.com>
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright 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.
-->
<androidx.preference.PreferenceScreen
xmlns:android="http://schemas.android.com/apk/res/android">
<PreferenceCategory
android:key="@string/pref_key_angle_flags_category"
android:title="@string/angle_general_title">
<androidx.preference.SwitchPreference
android:key="@string/pref_key_angle_in_use_dialog"
android:title="@string/show_angle_in_use_toast_title"
android:summary="@string/show_angle_in_use_toast_summary"
android:defaultValue="false"
android:enabled="true"/>
</PreferenceCategory>
<PreferenceCategory
android:key="@string/pref_key_select_opengl_driver_category"
android:title="@string/select_opengl_driver_title">
</PreferenceCategory>
</androidx.preference.PreferenceScreen>