summaryrefslogtreecommitdiffstats
path: root/res
diff options
context:
space:
mode:
authorHeemin Seog <hseog@google.com>2019-05-10 08:27:52 -0700
committerHeemin Seog <hseog@google.com>2019-05-17 13:18:32 -0700
commit1a028cddc31cca340708847310b2cf52a97579b2 (patch)
tree9df1a2fc191c6d8b3d1a527543a20522ef1c516d /res
parentbb0d5d0ced1bab08a0d7be23a1ed0953d57413ea (diff)
downloadandroid_packages_apps_PackageInstaller-1a028cddc31cca340708847310b2cf52a97579b2.tar.gz
android_packages_apps_PackageInstaller-1a028cddc31cca340708847310b2cf52a97579b2.tar.bz2
android_packages_apps_PackageInstaller-1a028cddc31cca340708847310b2cf52a97579b2.zip
New permissions page for app specific permissions
This does not handle All permissions quite yet. This will be handled in a separate CL. This change by itself also affects the full permissions page, so it will not be submitted until other permissions CLs are approved. This CL also tries to unify the base frame for car related settings permission controller. Will need to do a separate cleanup CL for default applications. Bug: 122822231 Test: manual Change-Id: Idf946d4ce0b299e6b3a4b3b094d475a708bdfd13
Diffstat (limited to 'res')
-rw-r--r--res/layout/car_default_app_frame.xml55
-rw-r--r--res/layout/car_settings_frame.xml90
-rw-r--r--res/values/styles.xml2
3 files changed, 91 insertions, 56 deletions
diff --git a/res/layout/car_default_app_frame.xml b/res/layout/car_default_app_frame.xml
deleted file mode 100644
index 2fe0856e..00000000
--- a/res/layout/car_default_app_frame.xml
+++ /dev/null
@@ -1,55 +0,0 @@
-<?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.
--->
-
-<LinearLayout
- xmlns:android="http://schemas.android.com/apk/res/android"
- android:layout_width="match_parent"
- android:layout_height="match_parent"
- android:orientation="vertical">
- <LinearLayout
- android:layout_width="match_parent"
- android:layout_height="@dimen/car_action_bar_height"
- android:gravity="center_vertical"
- android:orientation="horizontal">
- <FrameLayout
- android:id="@+id/back_button"
- android:layout_width="@dimen/car_margin"
- android:layout_height="match_parent">
- <ImageView
- android:layout_width="@dimen/car_icon_size"
- android:layout_height="@dimen/car_icon_size"
- android:layout_gravity="center"
- android:scaleType="fitCenter"
- android:src="@drawable/ic_arrow_back"
- android:tint="?android:attr/textColorPrimary"/>
- </FrameLayout>
-
- <TextView
- android:id="@+id/label"
- android:layout_width="wrap_content"
- android:layout_height="wrap_content"
- android:singleLine="true"
- android:textAppearance="?android:attr/textAppearanceLarge"/>
- </LinearLayout>
-
- <FrameLayout
- android:id="@android:id/list_container"
- android:layout_width="match_parent"
- android:layout_height="match_parent"
- android:paddingEnd="@dimen/car_margin"
- android:paddingStart="@dimen/car_margin"/>
-</LinearLayout>
diff --git a/res/layout/car_settings_frame.xml b/res/layout/car_settings_frame.xml
new file mode 100644
index 00000000..4381d014
--- /dev/null
+++ b/res/layout/car_settings_frame.xml
@@ -0,0 +1,90 @@
+<?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.
+-->
+
+<LinearLayout
+ xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:app="http://schemas.android.com/apk/res-auto"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:orientation="vertical">
+
+ <androidx.constraintlayout.widget.ConstraintLayout
+ android:layout_width="match_parent"
+ android:layout_height="@*android:dimen/car_app_bar_height">
+
+ <FrameLayout
+ android:id="@+id/back_button"
+ android:layout_width="0dp"
+ android:layout_height="0dp"
+ android:background="?android:attr/selectableItemBackground"
+ app:layout_constraintBottom_toBottomOf="parent"
+ app:layout_constraintEnd_toStartOf="@+id/start_margin"
+ app:layout_constraintStart_toStartOf="parent"
+ app:layout_constraintTop_toTopOf="parent">
+ <ImageView
+ android:layout_width="@*android:dimen/car_primary_icon_size"
+ android:layout_height="@*android:dimen/car_primary_icon_size"
+ android:layout_gravity="center"
+ android:scaleType="fitCenter"
+ android:src="@drawable/ic_arrow_back"
+ android:tint="?android:attr/textColorPrimary"/>
+ </FrameLayout>
+
+ <androidx.constraintlayout.widget.Guideline
+ android:id="@+id/start_margin"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:orientation="vertical"
+ app:layout_constraintGuide_begin="@*android:dimen/action_bar_margin_start"/>
+
+ <TextView
+ android:id="@+id/label"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:singleLine="true"
+ android:textAppearance="?android:attr/textAppearanceLarge"
+ app:layout_constraintBottom_toBottomOf="parent"
+ app:layout_constraintStart_toEndOf="@+id/start_margin"
+ app:layout_constraintTop_toTopOf="parent"/>
+
+ <Button
+ android:id="@+id/action"
+ style="@*android:style/ActionBarButton"
+ android:layout_width="wrap_content"
+ android:layout_height="0dp"
+ android:layout_marginEnd="@*android:dimen/action_bar_button_margin"
+ android:visibility="gone"
+ app:layout_constraintBottom_toBottomOf="parent"
+ app:layout_constraintEnd_toEndOf="parent"
+ app:layout_constraintTop_toTopOf="parent"/>
+ </androidx.constraintlayout.widget.ConstraintLayout>
+
+ <ProgressBar
+ android:id="@+id/progress_bar"
+ style="@android:style/Widget.DeviceDefault.ProgressBar.Horizontal"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:indeterminate="true"
+ android:visibility="gone"/>
+
+ <FrameLayout
+ android:id="@android:id/list_container"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:paddingEnd="@*android:dimen/car_margin"
+ android:paddingStart="@*android:dimen/car_margin"/>
+</LinearLayout>
diff --git a/res/values/styles.xml b/res/values/styles.xml
index b8fbc380..6469cbd9 100644
--- a/res/values/styles.xml
+++ b/res/values/styles.xml
@@ -861,7 +861,7 @@
<!-- START CAR SETTINGS PREFERENCE STYLES -->
<style name="CarPreferenceFragment">
- <item name="android:layout">@layout/car_default_app_frame</item>
+ <item name="android:layout">@layout/car_settings_frame</item>
</style>
<style name="CarPreferenceFragmentList">