Don't remove wifi preferences when updating AP to avoid GC. am: 9d031f2fbc
am: 1330f130d6
Change-Id: Ifa8d1b0f30a07243a49a61bd92072de4e90e8709
diff --git a/res/drawable/drag_handle.xml b/res/drawable/drag_handle.xml
index 33a68c6..835ac5b 100644
--- a/res/drawable/drag_handle.xml
+++ b/res/drawable/drag_handle.xml
@@ -22,6 +22,6 @@
android:tint="@color/material_grey_600">
<path android:fillColor="@android:color/white"
- android:pathData="M8,18v4h32v-4hm-32,8v4h32v-4z" />
+ android:pathData="M6,30h36v-4L6,26v4zM6,38h36v-4L6,34v4zM6,22h36L42,18L6,18v4zM6,10v4h36L42,10L6,10z" />
</vector>
diff --git a/res/drawable/ic_wifi_signal_0.xml b/res/drawable/ic_wifi_signal_0.xml
new file mode 100644
index 0000000..55faf64
--- /dev/null
+++ b/res/drawable/ic_wifi_signal_0.xml
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright (C) 2015 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.
+-->
+<vector xmlns:android="http://schemas.android.com/apk/res/android"
+ android:width="26dp"
+ android:height="24dp"
+ android:viewportWidth="26"
+ android:viewportHeight="24">
+ <path
+ android:fillAlpha="0.3"
+ android:fillColor="?attr/wifi_signal_color"
+ android:pathData="M13.0,22.0L25.6,6.5C25.1,6.1 20.3,2.1 13.0,2.1S0.9,6.1 0.4,6.5L13.0,22.0L13.0,22.0L13.0,22.0L13.0,22.0L13.0,22.0z"/>
+</vector>
\ No newline at end of file
diff --git a/res/layout-land/fingerprint_enroll_enrolling.xml b/res/layout-land/fingerprint_enroll_enrolling.xml
index 8154d0c..ba0f803 100644
--- a/res/layout-land/fingerprint_enroll_enrolling.xml
+++ b/res/layout-land/fingerprint_enroll_enrolling.xml
@@ -20,6 +20,7 @@
android:id="@+id/setup_wizard_layout"
android:layout_width="match_parent"
android:layout_height="match_parent"
+ android:layout="@layout/suw_glif_blank_template"
style="?attr/fingerprint_layout_theme">
<LinearLayout
@@ -33,39 +34,62 @@
<!-- Both texts are kept as separate text views so it doesn't jump around in portrait.
See layouts/fingerprint_enroll_enrolling_base.xml. -->
- <RelativeLayout
+ <LinearLayout
android:layout_width="0dp"
android:layout_weight="1"
- android:layout_height="wrap_content">
+ android:layout_height="match_parent"
+ android:layout_marginStart="?attr/suwMarginSides"
+ android:layout_marginBottom="@dimen/suw_content_frame_padding_bottom"
+ android:orientation="vertical">
+
+ <ImageView
+ android:id="@+id/suw_layout_icon"
+ style="@style/SuwGlifIcon"
+ android:layout_width="wrap_content"
+ android:layout_height="wrap_content"
+ android:layout_marginStart="0dp"
+ android:layout_marginEnd="0dp"
+ android:src="@drawable/ic_lock" />
<TextView
- style="@style/TextAppearance.FingerprintMessage"
- android:id="@+id/start_message"
+ android:id="@+id/suw_layout_title"
+ style="@style/SuwGlifHeaderTitle"
android:layout_width="match_parent"
android:layout_height="wrap_content"
- android:layout_alignParentTop="true"
- android:text="@string/security_settings_fingerprint_enroll_start_message"/>
+ android:layout_marginStart="0dp"
+ android:layout_marginEnd="0dp" />
- <TextView
- style="@style/TextAppearance.FingerprintMessage"
- android:id="@+id/repeat_message"
+ <FrameLayout
android:layout_width="match_parent"
- android:layout_height="wrap_content"
- android:layout_alignParentTop="true"
- android:text="@string/security_settings_fingerprint_enroll_repeat_message"
- android:visibility="invisible"/>
+ android:layout_height="wrap_content">
+
+ <TextView
+ style="@style/TextAppearance.FingerprintMessage"
+ android:id="@+id/start_message"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:text="@string/security_settings_fingerprint_enroll_start_message"/>
+
+ <TextView
+ style="@style/TextAppearance.FingerprintMessage"
+ android:id="@+id/repeat_message"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:text="@string/security_settings_fingerprint_enroll_repeat_message"
+ android:visibility="invisible"/>
+
+ </FrameLayout>
<Button
android:id="@+id/skip_button"
style="@style/SetupWizardButton.Negative"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
- android:layout_alignParentBottom="true"
- android:layout_marginBottom="8dp"
+ android:layout_marginTop="8dp"
android:text="@string/skip_label"
android:visibility="gone" />
- </RelativeLayout>
+ </LinearLayout>
<FrameLayout
android:layout_width="0dp"
@@ -84,6 +108,7 @@
android:layout_height="wrap_content"
android:layout_marginBottom="16dp"
android:layout_gravity="center_horizontal|bottom"
+ android:accessibilityLiveRegion="polite"
android:visibility="invisible"/>
</FrameLayout>
diff --git a/res/layout/condition_card.xml b/res/layout/condition_card.xml
index c911f03..7c9e46d 100644
--- a/res/layout/condition_card.xml
+++ b/res/layout/condition_card.xml
@@ -25,7 +25,6 @@
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
- android:paddingStart="16dp"
android:background="?android:attr/colorAccent"
android:elevation="2dp"
android:clickable="true"
@@ -35,6 +34,7 @@
android:id="@+id/collapsed_group"
android:layout_width="match_parent"
android:layout_height="56dp"
+ android:background="?android:attr/selectableItemBackground"
android:orientation="horizontal"
android:gravity="center">
@@ -42,6 +42,7 @@
android:id="@android:id/icon"
android:layout_width="24dp"
android:layout_height="wrap_content"
+ android:layout_marginStart="16dp"
android:layout_marginEnd="32dp"
android:tint="?android:attr/textColorPrimaryInverse" />
@@ -58,10 +59,7 @@
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:padding="16dp"
- android:tint="?android:attr/textColorPrimaryInverse"
- android:clickable="true"
- android:focusable="true"
- android:background="?android:attr/selectableItemBackground" />
+ android:tint="?android:attr/textColorPrimaryInverse"/>
</LinearLayout>
@@ -69,7 +67,7 @@
android:id="@+id/detail_group"
android:layout_width="match_parent"
android:layout_height="0dp"
- android:paddingStart="56dp"
+ android:paddingStart="72dp"
android:visibility="gone"
android:orientation="vertical">
@@ -103,18 +101,22 @@
<Button
android:id="@+id/first_action"
- android:layout_width="wrap_content"
+ android:layout_width="0dp"
android:layout_height="wrap_content"
+ android:layout_weight="1"
android:paddingStart="0dp"
android:alpha=".8"
+ android:textAlignment="viewStart"
android:textColor="?android:attr/textColorPrimaryInverse"
style="?android:attr/buttonBarButtonStyle" />
<Button
android:id="@+id/second_action"
- android:layout_width="wrap_content"
+ android:layout_width="0dp"
android:layout_height="wrap_content"
+ android:layout_weight="1"
android:alpha=".8"
+ android:textAlignment="viewStart"
android:textColor="?android:attr/textColorPrimaryInverse"
style="?android:attr/buttonBarButtonStyle" />
diff --git a/res/layout/dashboard.xml b/res/layout/dashboard.xml
index ebf5204..73a7255 100644
--- a/res/layout/dashboard.xml
+++ b/res/layout/dashboard.xml
@@ -19,9 +19,11 @@
android:id="@+id/dashboard_container"
android:layout_width="match_parent"
android:layout_height="match_parent"
+ android:clipChildren="false"
+ android:clipToPadding="false"
+ android:focusable="false"
android:paddingStart="@dimen/dashboard_padding_start"
android:paddingEnd="@dimen/dashboard_padding_end"
android:paddingTop="@dimen/dashboard_padding_top"
android:paddingBottom="@dimen/dashboard_padding_bottom"
- android:clipChildren="false"
- android:clipToPadding="false" />
+ android:scrollbars="vertical"/>
diff --git a/res/layout/enable_accessibility_service_dialog_content.xml b/res/layout/enable_accessibility_service_dialog_content.xml
index 25c6ba2..3ca40ac 100644
--- a/res/layout/enable_accessibility_service_dialog_content.xml
+++ b/res/layout/enable_accessibility_service_dialog_content.xml
@@ -26,25 +26,30 @@
android:layout_height="wrap_content"
android:orientation="vertical"
android:paddingStart="16dip"
- android:paddingEnd="16dip" >
+ android:paddingEnd="16dip">
- <TextView android:id="@+id/encryption_warning"
+ <TextView
+ android:id="@+id/encryption_warning"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:padding="10dip"
+ android:textAlignment="viewStart"
android:textAppearance="?android:attr/textAppearanceMedium"/>
- <TextView android:id="@+id/capabilities_header"
+ <TextView
+ android:id="@+id/capabilities_header"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:padding="10dip"
- android:textAppearance="?android:attr/textAppearanceMedium" />
+ android:textAlignment="viewStart"
+ android:textAppearance="?android:attr/textAppearanceMedium"/>
- <LinearLayout android:id="@+id/capabilities"
+ <LinearLayout
+ android:id="@+id/capabilities"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
- android:padding="10dip" />
+ android:padding="10dip"/>
</LinearLayout>
diff --git a/res/layout/nfc_payment_option.xml b/res/layout/nfc_payment_option.xml
index 90ba279..be5fe5f 100644
--- a/res/layout/nfc_payment_option.xml
+++ b/res/layout/nfc_payment_option.xml
@@ -21,7 +21,7 @@
android:focusable="true"
android:clickable="false"
android:orientation="horizontal"
- android:paddingLeft="24dip"
+ android:paddingStart="24dip"
android:minHeight="?android:attr/listPreferredItemHeight"
android:background="?android:attr/selectableItemBackground">
<RadioButton xmlns:android="http://schemas.android.com/apk/res/android"
diff --git a/res/layout/support_fragment.xml b/res/layout/support_fragment.xml
index 481a548..10b9418 100644
--- a/res/layout/support_fragment.xml
+++ b/res/layout/support_fragment.xml
@@ -19,4 +19,5 @@
xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/support_items"
android:layout_width="match_parent"
- android:layout_height="match_parent"/>
\ No newline at end of file
+ android:layout_height="match_parent"
+ android:focusable="false" />
\ No newline at end of file
diff --git a/res/layout/support_offline_escalation_options.xml b/res/layout/support_offline_escalation_options.xml
index 18b7d69..18d8f98 100644
--- a/res/layout/support_offline_escalation_options.xml
+++ b/res/layout/support_offline_escalation_options.xml
@@ -41,6 +41,7 @@
android:layout_height="wrap_content"
android:orientation="horizontal">
<TextView
+ android:id="@+id/support_text"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:paddingEnd="8dp"
diff --git a/res/layout/user_dictionary_add_word.xml b/res/layout/user_dictionary_add_word.xml
index 3624dad..2b8c19a 100644
--- a/res/layout/user_dictionary_add_word.xml
+++ b/res/layout/user_dictionary_add_word.xml
@@ -14,72 +14,73 @@
limitations under the License.
-->
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
- android:id="@+id/user_dict_settings_add_dialog_top"
- android:layout_width="match_parent"
- android:layout_height="wrap_content"
- android:orientation="vertical">
+ android:id="@+id/user_dict_settings_add_dialog_top"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:orientation="vertical">
<LinearLayout android:layout_width="match_parent"
- android:layout_height="wrap_content"
- android:orientation="vertical">
+ android:layout_height="wrap_content"
+ android:orientation="vertical">
<com.android.internal.widget.DialogTitle
- style="?android:attr/windowTitleStyle"
- android:singleLine="true"
- android:ellipsize="end"
- android:layout_width="match_parent"
- android:layout_height="64dip"
- android:layout_marginStart="16dip"
- android:layout_marginEnd="16dip"
- android:gravity="center_vertical|start"
- android:text="@string/user_dict_settings_add_dialog_title" />
- <View android:layout_width="match_parent"
- android:layout_height="2dip"
- android:background="@android:color/holo_blue_light" />
+ style="?android:attr/windowTitleStyle"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:layout_marginStart="24dip"
+ android:layout_marginEnd="24dip"
+ android:layout_marginTop="24dip"
+ android:layout_marginBottom="0dip"
+ android:ellipsize="end"
+ android:gravity="center_vertical|start"
+ android:singleLine="true"
+ android:text="@string/user_dict_settings_add_dialog_title" />
</LinearLayout>
<EditText android:id="@+id/user_dictionary_add_word_text"
- android:maxLength="@integer/maximum_user_dictionary_word_length"
- android:layout_height="match_parent"
- android:layout_width="match_parent"
- android:layout_gravity="fill_horizontal|center_vertical"
- android:layout_marginStart="8dip"
- android:layout_marginBottom="8dip"
- android:layout_marginTop="8dip"
- android:hint="@string/user_dict_settings_add_word_hint"
- android:inputType="textNoSuggestions"
- android:imeOptions="flagNoFullscreen">
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ android:layout_gravity="fill_horizontal|center_vertical"
+ android:layout_marginStart="24dip"
+ android:layout_marginEnd="24dip"
+ android:layout_marginTop="20dip"
+ android:layout_marginBottom="24dip"
+ android:hint="@string/user_dict_settings_add_word_hint"
+ android:imeOptions="flagNoFullscreen"
+ android:inputType="textNoSuggestions"
+ android:maxLength="@integer/maximum_user_dictionary_word_length">
<requestFocus />
</EditText>
<LinearLayout android:layout_width="match_parent"
- android:layout_height="wrap_content"
- android:orientation="vertical"
- android:divider="?android:attr/dividerHorizontal"
- android:showDividers="beginning"
- android:dividerPadding="0dip">
+ android:layout_height="wrap_content"
+ android:divider="?android:attr/dividerHorizontal"
+ android:dividerPadding="0dip"
+ android:orientation="vertical"
+ android:showDividers="beginning">
<LinearLayout style="?android:attr/buttonBarStyle"
- android:layout_width="match_parent"
- android:layout_height="wrap_content"
- android:orientation="horizontal"
- android:measureWithLargestChild="true">
- <Button android:layout_width="0dip"
- android:layout_gravity="start"
- android:layout_weight="1"
+ android:layout_width="match_parent"
+ android:layout_height="wrap_content"
+ android:gravity="end"
+ android:orientation="horizontal">
+ <Button style="?android:attr/buttonBarButtonStyle"
+ android:layout_width="wrap_content"
+ android:layout_height="36dip"
+ android:layout_marginTop="8dip"
+ android:layout_marginBottom="8dip"
+ android:layout_marginLeft="8dip"
+ android:layout_marginRight="0dip"
android:maxLines="2"
- style="?android:attr/buttonBarButtonStyle"
+ android:onClick="onClickCancel"
android:textSize="14sp"
- android:text="@string/cancel"
- android:layout_height="wrap_content"
- android:onClick="onClickCancel" />
- <Button android:layout_width="0dip"
- android:layout_gravity="end"
- android:layout_weight="1"
+ android:text="@string/cancel" />
+ <Button style="?android:attr/buttonBarButtonStyle"
+ android:layout_width="wrap_content"
+ android:layout_height="36dip"
+ android:layout_margin="8dip"
android:maxLines="2"
- style="?android:attr/buttonBarButtonStyle"
+ android:onClick="onClickConfirm"
android:textSize="14sp"
- android:text="@string/user_dict_settings_add_dialog_confirm"
- android:layout_height="wrap_content"
- android:onClick="onClickConfirm" />
+ android:text="@string/user_dict_settings_add_dialog_confirm" />
</LinearLayout>
</LinearLayout>
-</LinearLayout>
+</LinearLayout>
\ No newline at end of file
diff --git a/res/values-bs-rBA/strings.xml b/res/values-bs-rBA/strings.xml
index 2466876..284ca24 100644
--- a/res/values-bs-rBA/strings.xml
+++ b/res/values-bs-rBA/strings.xml
@@ -2928,8 +2928,8 @@
<string name="assist_access_context_summary" msgid="1991421283142279560">"Dozvolite da aplikacija za pomoć pristupa sadržaju na ekranu kao tekstu"</string>
<string name="assist_access_screenshot_title" msgid="4034721336291215819">"Koristi snimku ekrana"</string>
<string name="assist_access_screenshot_summary" msgid="6761636689013259901">"Dozvoli aplikaciji za pomoć da pristupi slici ekrana"</string>
- <string name="assist_flash_title" msgid="506661221230034891">"Neka ekran zabljesne"</string>
- <string name="assist_flash_summary" msgid="9160668468824099262">"Neka ivice ekrana zabljesnu kada aplikacija za pomoć pristupi tekstu s ekrana ili snimku ekrana"</string>
+ <string name="assist_flash_title" msgid="506661221230034891">"Bljeskanje ekrana"</string>
+ <string name="assist_flash_summary" msgid="9160668468824099262">"Ivice ekrana bljeskaju kada aplikacija za pomoć pristupi tekstu s ekrana ili snimku ekrana"</string>
<string name="assist_footer" msgid="1982791172085896864">"Aplikacije za pomoć vam mogu pomoći na osnovu informacija sa ekrana koji pregledate. Kako bi vam pružile sveukupnu pomoć, neke aplikacije podržavaju i usluge pokretača i glasovnog unosa."</string>
<string name="average_memory_use" msgid="829566450150198512">"Prosječna iskorištenost memorije"</string>
<string name="maximum_memory_use" msgid="7493720799710132496">"Maksimalna upotreba memorije"</string>
diff --git a/res/values-ca/strings.xml b/res/values-ca/strings.xml
index 1625231..3883634 100644
--- a/res/values-ca/strings.xml
+++ b/res/values-ca/strings.xml
@@ -636,10 +636,8 @@
<string name="nfc_quick_toggle_title" msgid="6769159366307299004">"NFC"</string>
<string name="nfc_quick_toggle_summary" product="tablet" msgid="8302974395787498915">"Permet l\'intercanvi de dades quan la tauleta toqui un altre dispositiu"</string>
<string name="nfc_quick_toggle_summary" product="default" msgid="5237208142892767592">"Permet l\'intercanvi de dades quan el telèfon toqui un altre dispositiu"</string>
- <!-- no translation found for nfc_disclaimer_title (4364003873202264039) -->
- <skip />
- <!-- no translation found for nfc_disclaimer_content (5566907911915158075) -->
- <skip />
+ <string name="nfc_disclaimer_title" msgid="4364003873202264039">"Activa l\'NFC"</string>
+ <string name="nfc_disclaimer_content" msgid="5566907911915158075">"L\'NFC permet que aquest dispositiu pugui intercanviar dades amb altres dispositius o objectius propers, com ara terminals de pagament, lectors d\'accés o anuncis i etiquetes interactius."</string>
<string name="android_beam_settings_title" msgid="7832812974600338649">"Android Beam"</string>
<string name="android_beam_on_summary" msgid="3618057099355636830">"Preparat per compartir contingut d\'aplicacions mitjançant NFC"</string>
<string name="android_beam_off_summary" msgid="4663095428454779138">"Desactivat"</string>
@@ -2901,10 +2899,8 @@
<string name="assist_access_context_summary" msgid="1991421283142279560">"Permet que l\'aplicació d\'assistència accedeixi als continguts de la pantalla en forma de text"</string>
<string name="assist_access_screenshot_title" msgid="4034721336291215819">"Ús de captures de pantalla"</string>
<string name="assist_access_screenshot_summary" msgid="6761636689013259901">"Permet que l\'aplicació d\'assistència accedeixi a una imatge de la pantalla"</string>
- <!-- no translation found for assist_flash_title (506661221230034891) -->
- <skip />
- <!-- no translation found for assist_flash_summary (9160668468824099262) -->
- <skip />
+ <string name="assist_flash_title" msgid="506661221230034891">"Fes centellejar la pantalla"</string>
+ <string name="assist_flash_summary" msgid="9160668468824099262">"Fa centellejar les vores de la pantalla quan l\'aplicació d\'assistència accedeix al text d\'una pantalla o d\'una captura de pantalla"</string>
<string name="assist_footer" msgid="1982791172085896864">"Les aplicacions d\'assistència et poden ajudar en funció de la informació que estiguis visualitzant a la pantalla. Algunes aplicacions admeten tant els serveis de Launcher com els d\'entrada de veu per oferir-te una assistència integrada."</string>
<string name="average_memory_use" msgid="829566450150198512">"Ús mitjà de la memòria"</string>
<string name="maximum_memory_use" msgid="7493720799710132496">"Ús màxim de la memòria"</string>
diff --git a/res/values-cs/strings.xml b/res/values-cs/strings.xml
index bd2028e..79fab31 100644
--- a/res/values-cs/strings.xml
+++ b/res/values-cs/strings.xml
@@ -2591,7 +2591,7 @@
<string name="ringtone_title" msgid="5379026328015343686">"Vyzváněcí tón telefonu"</string>
<string name="notification_ringtone_title" msgid="3361201340352664272">"Výchozí tón oznámení"</string>
<string name="alarm_ringtone_title" msgid="2015124067611102995">"Výchozí tón budíku"</string>
- <string name="vibrate_when_ringing_title" msgid="3806079144545849032">"Vibrovat také u volání"</string>
+ <string name="vibrate_when_ringing_title" msgid="3806079144545849032">"U hovorů také vibrovat"</string>
<string name="other_sound_settings" msgid="3151004537006844718">"Ostatní zvuky"</string>
<string name="dial_pad_tones_title" msgid="1999293510400911558">"Tóny číselníku"</string>
<string name="screen_locking_sounds_title" msgid="1340569241625989837">"Zvuky zámku obrazovky"</string>
diff --git a/res/values-eu-rES/strings.xml b/res/values-eu-rES/strings.xml
index 556e141..f73709d 100644
--- a/res/values-eu-rES/strings.xml
+++ b/res/values-eu-rES/strings.xml
@@ -637,7 +637,7 @@
<string name="nfc_quick_toggle_summary" product="tablet" msgid="8302974395787498915">"Eman datuak trukatzeko baimena tabletak beste gailu bat ukitzean."</string>
<string name="nfc_quick_toggle_summary" product="default" msgid="5237208142892767592">"Onartu datuen trukea telefonoak beste gailu bat ukitzen duenean"</string>
<string name="nfc_disclaimer_title" msgid="4364003873202264039">"Aktibatu NFC"</string>
- <string name="nfc_disclaimer_content" msgid="5566907911915158075">"NFC eginbideak datuak trukatzen ditu gailu honen eta inguruko beste gailu edo helburu batzuen artean (adibidez, ordainketa-terminalak, sarbide-irakurgailuak eta iragarki edo etiketa interaktiboak)."</string>
+ <string name="nfc_disclaimer_content" msgid="5566907911915158075">"NFC eginbideak datuak trukatzen ditu gailu honen eta inguruko beste gailu edo helburu batzuen artean (adibidez, ordainketa-terminalak, sarbide-irakurgailuak, eta iragarki edo etiketa interaktiboak)."</string>
<string name="android_beam_settings_title" msgid="7832812974600338649">"Android Beam"</string>
<string name="android_beam_on_summary" msgid="3618057099355636830">"Aplikazioaren edukia NFC bidez transmititzeko prest"</string>
<string name="android_beam_off_summary" msgid="4663095428454779138">"Desaktibatuta"</string>
diff --git a/res/values-fr-rCA/strings.xml b/res/values-fr-rCA/strings.xml
index b901058..64efd46 100644
--- a/res/values-fr-rCA/strings.xml
+++ b/res/values-fr-rCA/strings.xml
@@ -3018,7 +3018,7 @@
<string name="condition_hotspot_summary" msgid="3433182779269409683">"Le point d\'accès Wi-Fi mobile « <xliff:g id="ID_1">%1$s</xliff:g> » est actif. Le Wi-Fi est désactivé pour cet appareil."</string>
<string name="condition_airplane_title" msgid="287356299107070503">"Le mode Avion est activé"</string>
<string name="condition_airplane_summary" msgid="2136872325308526329">"Le Wi-Fi, le Bluetooth et le réseau cellulaire sont désactivés. Vous ne pouvez pas faire d\'appels téléphoniques ni vous connecter à Internet."</string>
- <string name="condition_zen_title" msgid="2679168532600816392">"Mode Ne pas déranger activé (<xliff:g id="ID_1">%1$s</xliff:g>)"</string>
+ <string name="condition_zen_title" msgid="2679168532600816392">"Mode « Ne pas déranger » activé (<xliff:g id="ID_1">%1$s</xliff:g>)"</string>
<string name="condition_battery_title" msgid="3272131008388575349">"Économie d\'énergie activée"</string>
<string name="condition_battery_summary" msgid="4418839236027977450">"Les performances sont réduites. Les services de localisation et les données en arrière-plan sont désactivés."</string>
<string name="condition_cellular_title" msgid="2398754272044917264">"Données cellulaire désactivées"</string>
diff --git a/res/values-fr/strings.xml b/res/values-fr/strings.xml
index f6077ca..44efd37 100644
--- a/res/values-fr/strings.xml
+++ b/res/values-fr/strings.xml
@@ -918,11 +918,11 @@
<string name="night_display_auto_mode_twilight" msgid="2123345097508167094">"Du coucher au lever du soleil"</string>
<string name="night_display_start_time_title" msgid="8918016772613689584">"Heure de début"</string>
<string name="night_display_end_time_title" msgid="8286061578083519350">"Heure de fin"</string>
- <string name="night_display_summary_off" msgid="1792750041697946539">"Désactivé/<xliff:g id="ID_1">%1$s</xliff:g>"</string>
+ <string name="night_display_summary_off" msgid="1792750041697946539">"Désactivé - <xliff:g id="ID_1">%1$s</xliff:g>"</string>
<string name="night_display_summary_off_auto_mode_never" msgid="8865054549719499274">"Ne jamais activer automatiquement"</string>
<string name="night_display_summary_off_auto_mode_custom" msgid="4962295097132112885">"Activer automatiquement à <xliff:g id="ID_1">%1$s</xliff:g>"</string>
<string name="night_display_summary_off_auto_mode_twilight" msgid="5520577516590422267">"Activer automatiquement au coucher du soleil"</string>
- <string name="night_display_summary_on" msgid="1355713529996456744">"Activé/<xliff:g id="ID_1">%1$s</xliff:g>"</string>
+ <string name="night_display_summary_on" msgid="1355713529996456744">"Activé - <xliff:g id="ID_1">%1$s</xliff:g>"</string>
<string name="night_display_summary_on_auto_mode_never" msgid="44005841579902825">"Ne jamais désactiver automatiquement"</string>
<string name="night_display_summary_on_auto_mode_custom" msgid="4350556852471560173">"Désactiver automatiquement à <xliff:g id="ID_1">%1$s</xliff:g>"</string>
<string name="night_display_summary_on_auto_mode_twilight" msgid="6122152828111119250">"Désactiver automatiquement au lever du soleil"</string>
diff --git a/res/values-gl-rES/strings.xml b/res/values-gl-rES/strings.xml
index 2d9e43b..7b8a067 100644
--- a/res/values-gl-rES/strings.xml
+++ b/res/values-gl-rES/strings.xml
@@ -637,7 +637,7 @@
<string name="nfc_quick_toggle_summary" product="tablet" msgid="8302974395787498915">"Permite o intercambio de datos cando a tableta toca outro dispositivo"</string>
<string name="nfc_quick_toggle_summary" product="default" msgid="5237208142892767592">"Permite o intercambio de datos cando o teléfono toca outro dispositivo"</string>
<string name="nfc_disclaimer_title" msgid="4364003873202264039">"Activar NFC"</string>
- <string name="nfc_disclaimer_content" msgid="5566907911915158075">"NFC intercambia datos entre este dispositivo e outros segmentos ou dispositivos próximos, como terminais de pago, lectores de acceso e etiquetas ou anuncios interactivos."</string>
+ <string name="nfc_disclaimer_content" msgid="5566907911915158075">"NFC intercambia datos entre este dispositivo e outros obxectivos ou dispositivos próximos, como terminais de pago, lectores de acceso e etiquetas ou anuncios interactivos."</string>
<string name="android_beam_settings_title" msgid="7832812974600338649">"Android Beam"</string>
<string name="android_beam_on_summary" msgid="3618057099355636830">"Listo para transmitir o contido da aplicación a través de NFC"</string>
<string name="android_beam_off_summary" msgid="4663095428454779138">"Desactivado"</string>
@@ -2899,8 +2899,8 @@
<string name="assist_access_context_summary" msgid="1991421283142279560">"Permitir que a aplicación do asistente acceda aos contidos da pantalla en forma de texto"</string>
<string name="assist_access_screenshot_title" msgid="4034721336291215819">"Usar captura de pantalla"</string>
<string name="assist_access_screenshot_summary" msgid="6761636689013259901">"Permitir que a aplicación do asistente acceda á imaxe da pantalla"</string>
- <string name="assist_flash_title" msgid="506661221230034891">"Flash na pantalla"</string>
- <string name="assist_flash_summary" msgid="9160668468824099262">"Aplica o flash nos bordos da pantalla cando a aplicación do asistente accede ao texto desde a pantalla ou a captura de pantalla"</string>
+ <string name="assist_flash_title" msgid="506661221230034891">"Facer pestanexar a pantalla"</string>
+ <string name="assist_flash_summary" msgid="9160668468824099262">"Facer pestanexar os bordos da pantalla cando a aplicación do asistente accede ao texto desde a pantalla ou a captura de pantalla"</string>
<string name="assist_footer" msgid="1982791172085896864">"As aplicacións do asistente pódente axudar segundo a información que aparece en pantalla. Algunhas aplicacións son compatibles tanto cos servizos de entrada de voz como co launcher para proporcionarche unha asistencia integrada."</string>
<string name="average_memory_use" msgid="829566450150198512">"Uso medio da memoria"</string>
<string name="maximum_memory_use" msgid="7493720799710132496">"Uso máximo da memoria"</string>
diff --git a/res/values-iw/strings.xml b/res/values-iw/strings.xml
index 64c97a4..7f6fb85 100644
--- a/res/values-iw/strings.xml
+++ b/res/values-iw/strings.xml
@@ -655,7 +655,7 @@
<string name="nfc_quick_toggle_summary" product="tablet" msgid="8302974395787498915">"אפשר חילופי מידע כאשר הטאבלט נוגע במכשיר אחר"</string>
<string name="nfc_quick_toggle_summary" product="default" msgid="5237208142892767592">"אפשר החלפת נתונים כאשר הטלפון נוגע במכשיר אחר"</string>
<string name="nfc_disclaimer_title" msgid="4364003873202264039">"הפעלת NFC"</string>
- <string name="nfc_disclaimer_content" msgid="5566907911915158075">"NFC מחליף נתונים בין המכשיר הזה לבין מכשירים או יעדים אחרים בקרבת מקום, כמו למשל מסופי תשלום, שעוני נוכחות ומודעות או תגים אינטראקטיביים."</string>
+ <string name="nfc_disclaimer_content" msgid="5566907911915158075">"מתקיימת תקשורת נתונים ב-NFC בין המכשיר הזה לבין מכשירים או יעדים אחרים בקרבת מקום, כמו למשל מסופי תשלום, מתקנים לזיהוי גישה, ומודעות או תגים אינטראקטיביים."</string>
<string name="android_beam_settings_title" msgid="7832812974600338649">"Android Beam"</string>
<string name="android_beam_on_summary" msgid="3618057099355636830">"מוכן לשדר תוכן אפליקציה באמצעות NFC"</string>
<string name="android_beam_off_summary" msgid="4663095428454779138">"כבוי"</string>
@@ -2960,7 +2960,7 @@
<string name="assist_access_screenshot_title" msgid="4034721336291215819">"שימוש בצילום מסך"</string>
<string name="assist_access_screenshot_summary" msgid="6761636689013259901">"התר לאפליקציית האסיסטנט לגשת אל צילום של המסך"</string>
<string name="assist_flash_title" msgid="506661221230034891">"הבהוב מסך"</string>
- <string name="assist_flash_summary" msgid="9160668468824099262">"קצות המסך יהבהבו כאשר אפליקציית אסיסטנט תיגש לטקסט מהמסך או מצילום מסך"</string>
+ <string name="assist_flash_summary" msgid="9160668468824099262">"שולי המסך יהבהבו כאשר אפליקציית אסיסטנט תיגש לטקסט מהמסך או מצילום מסך"</string>
<string name="assist_footer" msgid="1982791172085896864">"אפליקציות אסיסטנט יכולות לעזור לך בהתבסס על מידע המופיע במסך שאתה מציג. כדי לספק סיוע משולב, אפליקציות מסוימות תומכות בשירותי מפעיל אפליקציות ובקלט קולי."</string>
<string name="average_memory_use" msgid="829566450150198512">"שימוש ממוצע בזיכרון"</string>
<string name="maximum_memory_use" msgid="7493720799710132496">"שימוש מקסימלי בזיכרון"</string>
diff --git a/res/values-kk-rKZ/strings.xml b/res/values-kk-rKZ/strings.xml
index 62afe97..0e247a7 100644
--- a/res/values-kk-rKZ/strings.xml
+++ b/res/values-kk-rKZ/strings.xml
@@ -637,7 +637,7 @@
<string name="nfc_quick_toggle_summary" product="tablet" msgid="8302974395787498915">"Планшет басқа құрылғымен қатынасқанда дерек алмастыруға рұқсат беру"</string>
<string name="nfc_quick_toggle_summary" product="default" msgid="5237208142892767592">"Телефон басқа құрылғымен қатынасқанда дерек алмастыру мүмкіндігін береді"</string>
<string name="nfc_disclaimer_title" msgid="4364003873202264039">"NFC желісін қосу"</string>
- <string name="nfc_disclaimer_content" msgid="5566907911915158075">"NFC арқылы бұл құрылғы басқа маңайдағы құрылғылармен не нысандармен, соның ішінде төлем терминалдарымен, кіру деректерін оқу құралдармен және интеративті жарнамалармен немесе тегтермен деректер алмасады."</string>
+ <string name="nfc_disclaimer_content" msgid="5566907911915158075">"NFC арқылы бұл құрылғы басқа маңайдағы құрылғылармен не нысандармен, соның ішінде төлем терминалдарымен, кіру деректерін оқу құралдармен және интеративті жарнамалармен немесе тэгтермен деректер алмасады."</string>
<string name="android_beam_settings_title" msgid="7832812974600338649">"Android тарату функциясы"</string>
<string name="android_beam_on_summary" msgid="3618057099355636830">"Қолданба мазмұнын ЖӨБ арқылы жіберуге әзір"</string>
<string name="android_beam_off_summary" msgid="4663095428454779138">"Өшірулі"</string>
@@ -2899,7 +2899,7 @@
<string name="assist_access_context_summary" msgid="1991421283142279560">"Қолданбаға экран мазмұнына мәтін ретінде қатынасуға рұқсат ету"</string>
<string name="assist_access_screenshot_title" msgid="4034721336291215819">"Скриншотты пайдалану"</string>
<string name="assist_access_screenshot_summary" msgid="6761636689013259901">"Қолданбаға экран кескініне қатынасуға рұқсат ету"</string>
- <string name="assist_flash_title" msgid="506661221230034891">"Экран жарқылы"</string>
+ <string name="assist_flash_title" msgid="506661221230034891">"Экранды жарықтандыру"</string>
<string name="assist_flash_summary" msgid="9160668468824099262">"Көмекші қолданба экрандағы не скриншоттағы мәтінге кірген кезде, экранның шеттері жанады"</string>
<string name="assist_footer" msgid="1982791172085896864">"Көмекші қолданбалар көріп жатқан экран ақпаратының негізінде сізге көмектесе алады. Кейбір қолданбалар біріктірілген көмекті беру үшін қосқышты да, дауыспен енгізу қызметтерін де қолдайды."</string>
<string name="average_memory_use" msgid="829566450150198512">"Жадты орташа пайдалануы"</string>
diff --git a/res/values-kn-rIN/strings.xml b/res/values-kn-rIN/strings.xml
index 293b54e..12685de 100644
--- a/res/values-kn-rIN/strings.xml
+++ b/res/values-kn-rIN/strings.xml
@@ -2900,7 +2900,7 @@
<string name="assist_access_screenshot_title" msgid="4034721336291215819">"ಸ್ಕ್ರೀನ್ಶಾಟ್ ಬಳಸಿ"</string>
<string name="assist_access_screenshot_summary" msgid="6761636689013259901">"ಸಹಾಯಕ ಅಪ್ಲಿಕೇಶನ್ಗೆ ಪರದೆಯ ಚಿತ್ರವನ್ನು ಪ್ರವೇಶಿಸಲು ಅನುಮತಿಸಿ"</string>
<string name="assist_flash_title" msgid="506661221230034891">"ಫ್ಲ್ಯಾಶ್ ಪರದೆ"</string>
- <string name="assist_flash_summary" msgid="9160668468824099262">"ಪರದೆ ಅಥವಾ ಸ್ಕ್ರೀನ್ಶಾಟ್ನಿಂದ ಪಠ್ಯವನ್ನು ಸಹಾಯ ಅಪ್ಲಿಕೇಶನ್ ಪ್ರವೇಶ ಮಾಡಿದಾಗ ಪರದೆಯ ಫ್ಲ್ಯಾಶ್ ಅಂಚುಗಳು"</string>
+ <string name="assist_flash_summary" msgid="9160668468824099262">"ಪರದೆ ಅಥವಾ ಸ್ಕ್ರೀನ್ಶಾಟ್ನಿಂದ ಪಠ್ಯವನ್ನು ಸಹಾಯ ಅಪ್ಲಿಕೇಶನ್ ಪ್ರವೇಶ ಮಾಡಿದಾಗ ಪರದೆಯ ಅಂಚುಗಳು ಫ್ಲ್ಯಾಶ್ ಆಗುವುದು"</string>
<string name="assist_footer" msgid="1982791172085896864">"ನೀವು ವೀಕ್ಷಿಸುತ್ತಿರುವ ಪರದೆಯ ಮಾಹಿತಿಯನ್ನು ಆಧರಿಸಿ ಸಹಾಯಕ ಅಪ್ಲಿಕೇಶನ್ಗಳು ನಿಮಗೆ ಸಹಾಯ ಮಾಡಬಹುದು. ನಿಮಗೆ ಸಂಪೂರ್ಣ ಸಹಾಯ ನೀಡಲು ಕೆಲವು ಅಪ್ಲಿಕೇಶನ್ಗಳು ಲಾಂಚರ್ ಮತ್ತು ಧ್ವನಿ ಇನ್ಪುಟ್ ಸೇವೆ ಎರಡನ್ನೂ ಬೆಂಬಲಿಸುತ್ತವೆ."</string>
<string name="average_memory_use" msgid="829566450150198512">"ಸರಾಸರಿ ಮೆಮೊರಿ ಬಳಕೆ"</string>
<string name="maximum_memory_use" msgid="7493720799710132496">"ಗರಿಷ್ಠ ಮೆಮೊರಿ ಬಳಕೆ"</string>
diff --git a/res/values-ko/strings.xml b/res/values-ko/strings.xml
index faecf4d..88eb8fc 100644
--- a/res/values-ko/strings.xml
+++ b/res/values-ko/strings.xml
@@ -909,7 +909,7 @@
<string name="auto_brightness_title" msgid="6341042882350279391">"밝기 자동 조절"</string>
<string name="auto_brightness_summary" msgid="1799041158760605375">"빛의 양에 따라 밝기 수준 최적화"</string>
<string name="night_display_title" msgid="2626451512200357686">"야간 조명"</string>
- <string name="night_display_text" msgid="4535302797673277668">"야간 조명은 화면에 빨간색 농담 효과를 줍니다. 그러면 어두운 불빛에서 화면이 더 잘 보이며 수면 방해 효과가 줄어듭니다."</string>
+ <string name="night_display_text" msgid="4535302797673277668">"야간 조명은 화면에 빨간색 농담 효과를 줍니다. 그러면 어두운 불빛에서 화면이 더 잘 보이며 수면에도 방해가 되지 않습니다."</string>
<string name="night_display_category_schedule" msgid="2044072617637348966">"예약"</string>
<string name="night_display_category_status" msgid="1952928783124400330">"상태"</string>
<string name="night_display_auto_mode_title" msgid="8046314360381608455">"자동으로 사용 설정"</string>
@@ -1121,7 +1121,7 @@
<string name="storage_detail_other" msgid="8404938385075638238">"기타"</string>
<string name="storage_detail_system" msgid="4629506366064709687">"시스템"</string>
<string name="storage_detail_explore" msgid="7911344011431568294">"<xliff:g id="NAME">^1</xliff:g> 탐색"</string>
- <string name="storage_detail_dialog_other" msgid="5343550781234524040">"앱에서 저장한 공유 파일, 인터넷으로 또는 블루투스로 다운로드한 파일, Android 파일 등이 기타에 포함됩니다. \n\n이 <xliff:g id="NAME">^1</xliff:g>의 전체 콘텐츠를 보려면 탐색을 탭하세요."</string>
+ <string name="storage_detail_dialog_other" msgid="5343550781234524040">"앱에서 저장한 공유 파일, 인터넷 또는 블루투스로 다운로드한 파일, Android 파일 등이 기타에 포함됩니다. \n\n이 <xliff:g id="NAME">^1</xliff:g>의 전체 콘텐츠를 보려면 탐색을 탭하세요."</string>
<string name="storage_detail_dialog_system" msgid="3058775028564971102">"Android 운영체제에 의해 내부적으로 사용된 파일이 시스템에 포함되어 있습니다. \n\n이 파일을 개별적으로 볼 수 없습니다."</string>
<string name="storage_detail_dialog_user" msgid="1675756743326079688">"<xliff:g id="USER_0">^1</xliff:g>님이 <xliff:g id="SIZE">^2</xliff:g>의 저장용량을 차지하는 사진, 음악, 영화, 앱 또는 기타 데이터를 저장했을 수 있습니다. \n\n자세한 내용을 확인하려면 <xliff:g id="USER_1">^1</xliff:g>님으로 전환하세요."</string>
<string name="storage_wizard_init_title" msgid="5085400514028585772">"<xliff:g id="NAME">^1</xliff:g> 설정"</string>
diff --git a/res/values-ky-rKG/strings.xml b/res/values-ky-rKG/strings.xml
index 0b4b69f..f59b8b3 100644
--- a/res/values-ky-rKG/strings.xml
+++ b/res/values-ky-rKG/strings.xml
@@ -636,7 +636,7 @@
<string name="nfc_quick_toggle_summary" product="tablet" msgid="8302974395787498915">"Планшет башка түзмөккө тийгенде берилиштердин алмашуусуна уруксат берүү"</string>
<string name="nfc_quick_toggle_summary" product="default" msgid="5237208142892767592">"Телефон башка түзмөккө тийгенде, берилиштер алмашуусуна уруксат берилсин"</string>
<string name="nfc_disclaimer_title" msgid="4364003873202264039">"NFC\'ни күйгүзүү"</string>
- <string name="nfc_disclaimer_content" msgid="5566907911915158075">"NFC ушул жана башка жакын арадагы түзмөктөрдүн ортосунда маалыматты алмаштырат, мисалы, төлөм терминалдары, кабыл алуучу түзмөктөр жана интерактивдүү жарнамалар менен тегдер."</string>
+ <string name="nfc_disclaimer_content" msgid="5566907911915158075">"NFC ушул жана башка жакын арадагы түзмөктөрдүн (мисалы, төлөм терминалдары, кабыл алуучу түзмөктөр жана интерактивдүү жарнамалар менен тегдер) ортосунда маалымат алмашууга мүмкүндүк берет."</string>
<string name="android_beam_settings_title" msgid="7832812974600338649">"Android Beam"</string>
<string name="android_beam_on_summary" msgid="3618057099355636830">"Колдонмо мазмунун NFC аркылуу өткөргөнгө даяр"</string>
<string name="android_beam_off_summary" msgid="4663095428454779138">"Өчүк"</string>
@@ -2899,7 +2899,7 @@
<string name="assist_access_screenshot_title" msgid="4034721336291215819">"Скриншот колдонуу"</string>
<string name="assist_access_screenshot_summary" msgid="6761636689013259901">"Көмөкчү колдонмого экрандагы сүрөттү колдонууга уруксат бериңиз"</string>
<string name="assist_flash_title" msgid="506661221230034891">"Экран жаркылдасын"</string>
- <string name="assist_flash_summary" msgid="9160668468824099262">"Экрандан же скриншоттон көмөкчү колдонмого кирүү мүмкүнчүлүгү ишке ашканын билдирген текст пайда болгондо, экрандын чети жаркылдасын"</string>
+ <string name="assist_flash_summary" msgid="9160668468824099262">"Көмөкчү колдонмо скриншотко же текстке кирүү мүмкүнчүлүгүн алганда, экрандын чети жаркылдасын"</string>
<string name="assist_footer" msgid="1982791172085896864">"Көмөкчү колдонмо сиз көрүп жаткан экрандын маалыматынын негизинде жардам бере алат. Айрым колдонмолордо үн буйруктары жана жүргүзгүч тактасынан киргизүү мүмкүнчүлүктөрү иштейт."</string>
<string name="average_memory_use" msgid="829566450150198512">"Эстутумдун орточо керектелиши"</string>
<string name="maximum_memory_use" msgid="7493720799710132496">"Эстутумдун эң көп керектелиши"</string>
diff --git a/res/values-pt-rBR/strings.xml b/res/values-pt-rBR/strings.xml
index 0eaac70..9e4ef9c 100644
--- a/res/values-pt-rBR/strings.xml
+++ b/res/values-pt-rBR/strings.xml
@@ -912,9 +912,9 @@
<string name="night_display_text" msgid="4535302797673277668">"O modo noturno tinge sua tela de vermelho. Isso facilita olhar para a tela ou ler com pouca luz e pode ajudar você a adormecer com mais facilidade."</string>
<string name="night_display_category_schedule" msgid="2044072617637348966">"Programar"</string>
<string name="night_display_category_status" msgid="1952928783124400330">"Status"</string>
- <string name="night_display_auto_mode_title" msgid="8046314360381608455">"Ativar automaticamente"</string>
+ <string name="night_display_auto_mode_title" msgid="8046314360381608455">"Ativação automática"</string>
<string name="night_display_auto_mode_never" msgid="6723636142053240947">"Nunca"</string>
- <string name="night_display_auto_mode_custom" msgid="6012300346981608242">"Programação personalizada"</string>
+ <string name="night_display_auto_mode_custom" msgid="6012300346981608242">"Personalizada"</string>
<string name="night_display_auto_mode_twilight" msgid="2123345097508167094">"Do pôr ao nascer do sol"</string>
<string name="night_display_start_time_title" msgid="8918016772613689584">"Horário de início"</string>
<string name="night_display_end_time_title" msgid="8286061578083519350">"Horário de término"</string>
@@ -3181,8 +3181,8 @@
<string name="automatic_storage_manager_text" msgid="4562950476680600604">"Para ajudar a liberar espaço de armazenamento, o gerenciador de armazenamento remove fotos e vídeos do seu dispositivo salvos em backup."</string>
<string name="automatic_storage_manager_days_title" msgid="2017913896160914647">"Remover fotos e vídeos"</string>
<string name="automatic_storage_manager_preference_title" msgid="5753702798151073383">"Gerenciador de armazenamento"</string>
- <string name="deletion_helper_automatic_title" msgid="6605660435498272520">"Automáticas"</string>
- <string name="deletion_helper_manual_title" msgid="7947432164411214029">"Manual"</string>
+ <string name="deletion_helper_automatic_title" msgid="6605660435498272520">"Modo automático"</string>
+ <string name="deletion_helper_manual_title" msgid="7947432164411214029">"Modo manual"</string>
<string name="deletion_helper_preference_title" msgid="5271510052022285884">"Liberar espaço agora"</string>
<string name="gesture_preference_title" msgid="5280023307132819052">"Gestos"</string>
<string name="gesture_preference_summary" msgid="8627850388011956901">"Gestos rápidos para controlar seu smartphone"</string>
diff --git a/res/values-pt-rPT/strings.xml b/res/values-pt-rPT/strings.xml
index 996e550..78b0b37 100644
--- a/res/values-pt-rPT/strings.xml
+++ b/res/values-pt-rPT/strings.xml
@@ -909,7 +909,7 @@
<string name="auto_brightness_title" msgid="6341042882350279391">"Luminosidade adaptável"</string>
<string name="auto_brightness_summary" msgid="1799041158760605375">"Otimizar o nível de luminosidade de acordo com a luz disponível"</string>
<string name="night_display_title" msgid="2626451512200357686">"Luz noturna"</string>
- <string name="night_display_text" msgid="4535302797673277668">"A Luz noturna aplica uma tonalidade vermelha ao ecrã. Assim, é mais fácil olhar para o ecrã ou ler com pouca luz e pode ajudar a adormecer mais facilmente."</string>
+ <string name="night_display_text" msgid="4535302797673277668">"A Luz noturna aplica uma tonalidade vermelha ao ecrã que torna mais fácil olhar para ele ou ler com pouca luz. Também pode ajudar a adormecer mais facilmente."</string>
<string name="night_display_category_schedule" msgid="2044072617637348966">"Programação"</string>
<string name="night_display_category_status" msgid="1952928783124400330">"Estado"</string>
<string name="night_display_auto_mode_title" msgid="8046314360381608455">"Ativar automaticamente"</string>
@@ -1096,7 +1096,7 @@
<string name="storage_external_title" msgid="3433462910096848696">"Armazenamento portátil"</string>
<string name="storage_volume_summary" msgid="7023441974367853372">"<xliff:g id="USED">%1$s</xliff:g> utilizados de <xliff:g id="TOTAL">%2$s</xliff:g>"</string>
<string name="storage_size_large" msgid="5691585991420946254">"<xliff:g id="NUMBER">^1</xliff:g>"<small><small>" <xliff:g id="UNIT">^2</xliff:g>"</small></small>""</string>
- <string name="storage_volume_used" msgid="1303803057698959872">"Utilizado de <xliff:g id="TOTAL">%1$s</xliff:g>"</string>
+ <string name="storage_volume_used" msgid="1303803057698959872">"Utilizado(s) de <xliff:g id="TOTAL">%1$s</xliff:g>"</string>
<string name="storage_volume_used_total" msgid="6113121714019000244">"Total utilizado de <xliff:g id="TOTAL">%1$s</xliff:g>"</string>
<string name="storage_mount_success" msgid="687641090137253647">"<xliff:g id="NAME">%1$s</xliff:g> está montado"</string>
<string name="storage_mount_failure" msgid="1042621107954547316">"Não foi possível montar <xliff:g id="NAME">%1$s</xliff:g>"</string>
@@ -1121,7 +1121,7 @@
<string name="storage_detail_other" msgid="8404938385075638238">"Outros"</string>
<string name="storage_detail_system" msgid="4629506366064709687">"Sistema"</string>
<string name="storage_detail_explore" msgid="7911344011431568294">"Explorar <xliff:g id="NAME">^1</xliff:g>"</string>
- <string name="storage_detail_dialog_other" msgid="5343550781234524040">"Os outros ficheiros incluem ficheiros partilhados guardados por aplicações, ficheiros transferidos da Internet ou através do Bluetooth, ficheiros Android, etc. \n\nPara ver todos os conteúdos deste <xliff:g id="NAME">^1</xliff:g>, toque em Explorar."</string>
+ <string name="storage_detail_dialog_other" msgid="5343550781234524040">"Os outros ficheiros incluem ficheiros partilhados que foram guardados por aplicações, ficheiros transferidos da Internet ou através do Bluetooth, ficheiros Android, etc. \n\nPara ver todos os conteúdos deste <xliff:g id="NAME">^1</xliff:g>, toque em Explorar."</string>
<string name="storage_detail_dialog_system" msgid="3058775028564971102">"O sistema inclui ficheiros utilizados internamente pelo sistema operativo Android. \n\nNão é possível visualizar estes ficheiros individualmente."</string>
<string name="storage_detail_dialog_user" msgid="1675756743326079688">"<xliff:g id="USER_0">^1</xliff:g> pode ter fotos, música, filmes, aplicações ou outros dados guardados que estejam a utilizar <xliff:g id="SIZE">^2</xliff:g> de armazenamento. \n\nPara ver detalhes, mude para <xliff:g id="USER_1">^1</xliff:g>."</string>
<string name="storage_wizard_init_title" msgid="5085400514028585772">"Configurar o <xliff:g id="NAME">^1</xliff:g>"</string>
@@ -3192,7 +3192,7 @@
<string name="double_twist_for_camera_mode_summary" msgid="122977081337563340"></string>
<string name="ambient_display_title" msgid="7369291941168001738">"Verificação rápida do ecrã"</string>
<string name="ambient_display_summary" msgid="3606386731704368561">"Para consultar o telemóvel sem o ativar completamente, toque-lhe duas vezes ou pegue nele."</string>
- <string name="fingerprint_swipe_for_notifications_title" msgid="2750203868053669600">"Deslizar rapidamente para consultar as notificações"</string>
+ <string name="fingerprint_swipe_for_notifications_title" msgid="2750203868053669600">"Deslizar rapid. para ver as notificações"</string>
<string name="fingerprint_swipe_for_notifications_summary" msgid="5274050434459511239">"Para consultar as notificações, deslize rapidamente com o dedo para baixo no sensor de impressões digitais situado na parte posterior do telemóvel."</string>
<string name="gesture_setting_on" msgid="3455094265233870280">"Ativados"</string>
<string name="gesture_setting_off" msgid="5230169535435881894">"Desativados"</string>
diff --git a/res/values-pt/strings.xml b/res/values-pt/strings.xml
index 0eaac70..9e4ef9c 100644
--- a/res/values-pt/strings.xml
+++ b/res/values-pt/strings.xml
@@ -912,9 +912,9 @@
<string name="night_display_text" msgid="4535302797673277668">"O modo noturno tinge sua tela de vermelho. Isso facilita olhar para a tela ou ler com pouca luz e pode ajudar você a adormecer com mais facilidade."</string>
<string name="night_display_category_schedule" msgid="2044072617637348966">"Programar"</string>
<string name="night_display_category_status" msgid="1952928783124400330">"Status"</string>
- <string name="night_display_auto_mode_title" msgid="8046314360381608455">"Ativar automaticamente"</string>
+ <string name="night_display_auto_mode_title" msgid="8046314360381608455">"Ativação automática"</string>
<string name="night_display_auto_mode_never" msgid="6723636142053240947">"Nunca"</string>
- <string name="night_display_auto_mode_custom" msgid="6012300346981608242">"Programação personalizada"</string>
+ <string name="night_display_auto_mode_custom" msgid="6012300346981608242">"Personalizada"</string>
<string name="night_display_auto_mode_twilight" msgid="2123345097508167094">"Do pôr ao nascer do sol"</string>
<string name="night_display_start_time_title" msgid="8918016772613689584">"Horário de início"</string>
<string name="night_display_end_time_title" msgid="8286061578083519350">"Horário de término"</string>
@@ -3181,8 +3181,8 @@
<string name="automatic_storage_manager_text" msgid="4562950476680600604">"Para ajudar a liberar espaço de armazenamento, o gerenciador de armazenamento remove fotos e vídeos do seu dispositivo salvos em backup."</string>
<string name="automatic_storage_manager_days_title" msgid="2017913896160914647">"Remover fotos e vídeos"</string>
<string name="automatic_storage_manager_preference_title" msgid="5753702798151073383">"Gerenciador de armazenamento"</string>
- <string name="deletion_helper_automatic_title" msgid="6605660435498272520">"Automáticas"</string>
- <string name="deletion_helper_manual_title" msgid="7947432164411214029">"Manual"</string>
+ <string name="deletion_helper_automatic_title" msgid="6605660435498272520">"Modo automático"</string>
+ <string name="deletion_helper_manual_title" msgid="7947432164411214029">"Modo manual"</string>
<string name="deletion_helper_preference_title" msgid="5271510052022285884">"Liberar espaço agora"</string>
<string name="gesture_preference_title" msgid="5280023307132819052">"Gestos"</string>
<string name="gesture_preference_summary" msgid="8627850388011956901">"Gestos rápidos para controlar seu smartphone"</string>
diff --git a/res/values-sw600dp-land/dimens.xml b/res/values-sw600dp-land/dimens.xml
index eb37d0f..eeb677a 100755
--- a/res/values-sw600dp-land/dimens.xml
+++ b/res/values-sw600dp-land/dimens.xml
@@ -27,4 +27,6 @@
<!-- CryptKeeper top margin for pattern screen -->
<dimen name="crypt_keeper_pattern_top_margin">128dip</dimen>
+ <dimen name="captioning_preview_height">150dp</dimen>
+
</resources>
diff --git a/res/values-th/strings.xml b/res/values-th/strings.xml
index 14d67d9..f3d4fd3 100644
--- a/res/values-th/strings.xml
+++ b/res/values-th/strings.xml
@@ -637,7 +637,7 @@
<string name="nfc_quick_toggle_summary" product="tablet" msgid="8302974395787498915">"อนุญาตให้มีการแลกเปลี่ยนข้อมูล เมื่อแตะแท็บเล็ตกับอุปกรณ์อื่น"</string>
<string name="nfc_quick_toggle_summary" product="default" msgid="5237208142892767592">"อนุญาตให้มีการแลกเปลี่ยนข้อมูล เมื่อแตะโทรศัพท์กับอุปกรณ์อื่น"</string>
<string name="nfc_disclaimer_title" msgid="4364003873202264039">"เปิดใช้ NFC"</string>
- <string name="nfc_disclaimer_content" msgid="5566907911915158075">"NFC จะแลกเปลี่ยนข้อมูลระหว่างอุปกรณ์นี้และอุปกรณ์อื่นที่อยู่ใกล้ๆ หรืออุปกรณ์เป้าหมาย เช่น เครื่องชำระเงิน เข้าถึง Reader และโฆษณาเชิงโต้ตอบหรือแท็ก"</string>
+ <string name="nfc_disclaimer_content" msgid="5566907911915158075">"NFC จะแลกเปลี่ยนข้อมูลระหว่างอุปกรณ์นี้กับอุปกรณ์อื่นที่อยู่ใกล้ๆ หรืออุปกรณ์เป้าหมาย เช่น เครื่องชำระเงิน เครื่องอ่านการเข้าถึง และโฆษณาหรือป้ายสินค้าเชิงโต้ตอบ"</string>
<string name="android_beam_settings_title" msgid="7832812974600338649">"Android Beam"</string>
<string name="android_beam_on_summary" msgid="3618057099355636830">"พร้อมที่จะส่งเนื้อหาแอปพลิเคชันผ่านทาง NFC"</string>
<string name="android_beam_off_summary" msgid="4663095428454779138">"ปิด"</string>
@@ -2330,7 +2330,7 @@
<string name="user_add_user_item_title" msgid="8212199632466198969">"ผู้ใช้"</string>
<string name="user_add_profile_item_title" msgid="8353515490730363621">"โปรไฟล์ที่ถูกจำกัด"</string>
<string name="user_add_user_title" msgid="2108112641783146007">"ต้องการเพิ่มผู้ใช้ใหม่ใช่ไหม"</string>
- <string name="user_add_user_message_long" msgid="8562152293752222985">"คุณสามารถแชร์อุปกรณ์นี้กับผู้อื่นได้โดยการสร้างผู้ใช้เพิ่มเติม ผู้ใช้แต่ละคนจะมีพื้นที่ของตนเองซึ่งสามารถปรับใช้กับแอป วอลล์เปเปอร์ และอื่นๆ ผู้ใช้สามารถปรับการตั้งค่าอุปกรณ์ เช่น Wi‑Fi ที่มีผลกับทุกคน\n\nเมื่อคุณเพิ่มผู้ใช้ใหม่ ผู้ใช้ดังกล่าวจะต้องตั้งค่าพื้นที่ของตน\n\nผู้ใช้ทุกคนสามารถอัปเดตแอปสำหรับผู้ใช้รายอื่นๆ ทั้งหมดได้"</string>
+ <string name="user_add_user_message_long" msgid="8562152293752222985">"คุณสามารถแชร์อุปกรณ์นี้กับผู้อื่นได้โดยการสร้างผู้ใช้เพิ่มเติม ผู้ใช้แต่ละคนจะมีพื้นที่ของตนเองซึ่งสามารถปรับใช้กับแอป วอลล์เปเปอร์ และอื่นๆ ผู้ใช้ยังสามารถปรับการตั้งค่าอุปกรณ์ เช่น Wi‑Fi ที่มีผลกับทุกคน\n\nเมื่อคุณเพิ่มผู้ใช้ใหม่ ผู้ใช้ดังกล่าวจะต้องตั้งค่าพื้นที่ของตน\n\nผู้ใช้ทุกคนสามารถอัปเดตแอปสำหรับผู้ใช้รายอื่นๆ ทั้งหมดได้"</string>
<string name="user_add_user_message_short" msgid="1511354412249044381">"เมื่อคุณเพิ่มผู้ใช้ใหม่ ผู้ใช้ดังกล่าวจะต้องตั้งค่าพื้นที่ของตนเอง\n\nผู้ใช้ทุกคนสามารถอัปเดตแอปสำหรับผู้ใช้รายอื่นได้"</string>
<string name="user_setup_dialog_title" msgid="1765794166801864563">"ตั้งค่าผู้ใช้เลยไหม"</string>
<string name="user_setup_dialog_message" msgid="1004068621380867148">"ตรวจสอบว่าบุคคลดังกล่าวสามารถนำอุปกรณ์ไปตั้งค่าพื้นที่ของตนได้"</string>
@@ -2899,8 +2899,8 @@
<string name="assist_access_context_summary" msgid="1991421283142279560">"อนุญาตให้แอปผู้ช่วยสามารถเข้าถึงเนื้อหาบนหน้าจอเป็นข้อความ"</string>
<string name="assist_access_screenshot_title" msgid="4034721336291215819">"ใช้ภาพหน้าจอ"</string>
<string name="assist_access_screenshot_summary" msgid="6761636689013259901">"อนุญาตให้แอปผู้ช่วยสามารถเข้าถึงรูปภาพของหน้าจอ"</string>
- <string name="assist_flash_title" msgid="506661221230034891">"หน้าจอ Flash"</string>
- <string name="assist_flash_summary" msgid="9160668468824099262">"แสดงขอบของหน้าจอเมื่อแอปผู้ช่วยเข้าถึงข้อความจากหน้าจอหรือภาพหน้าจอ"</string>
+ <string name="assist_flash_title" msgid="506661221230034891">"กะพริบหน้าจอ"</string>
+ <string name="assist_flash_summary" msgid="9160668468824099262">"กะพริบขอบของหน้าจอเมื่อแอปผู้ช่วยเข้าถึงข้อความจากหน้าจอหรือภาพหน้าจอ"</string>
<string name="assist_footer" msgid="1982791172085896864">"แอปผู้ช่วยสามารถช่วยเหลือคุณโดยใช้ข้อมูลจากหน้าจอที่คุณกำลังดูอยู่ แอปบางแอปจะสนับสนุนทั้ง Launcher และบริการป้อนข้อมูลด้วยเสียงเพื่อให้ความช่วยเหลือแบบบูรณาการแก่คุณ"</string>
<string name="average_memory_use" msgid="829566450150198512">"การใช้หน่วยความจำโดยเฉลี่ย"</string>
<string name="maximum_memory_use" msgid="7493720799710132496">"การใช้หน่วยความจำสูงสุด"</string>
diff --git a/res/values-tr/strings.xml b/res/values-tr/strings.xml
index bc70c55..5a69f6f 100644
--- a/res/values-tr/strings.xml
+++ b/res/values-tr/strings.xml
@@ -2900,7 +2900,7 @@
<string name="assist_access_screenshot_title" msgid="4034721336291215819">"Ekran görüntüsü kullan"</string>
<string name="assist_access_screenshot_summary" msgid="6761636689013259901">"Yardımcı uygulamanın ekrandaki bir resme erişmesine izin verin"</string>
<string name="assist_flash_title" msgid="506661221230034891">"Ekranda ışık yakıp söndür"</string>
- <string name="assist_flash_summary" msgid="9160668468824099262">"Yardım uygulaması, ekrandan veya ekran görüntüsünden metne eriştiğinde kenarlarda ışık yakıp söndür"</string>
+ <string name="assist_flash_summary" msgid="9160668468824099262">"Yardım uygulaması, ekrandan veya ekran görüntüsünden metne eriştiğinde ekran kenarlarında ışık yakıp söndürür"</string>
<string name="assist_footer" msgid="1982791172085896864">"Yardımcı uygulamalar, görüntülemekte olduğunuz ekrandaki bilgilere dayalı olarak size yardım edebilir. Bazı uygulamalar, entegre yardım sağlamak için hem başlatıcıyı hem de ses girişi hizmetlerini destekler."</string>
<string name="average_memory_use" msgid="829566450150198512">"Ortalama bellek kullanımı"</string>
<string name="maximum_memory_use" msgid="7493720799710132496">"Maksimum bellek kullanımı"</string>
diff --git a/res/values-zh-rCN/strings.xml b/res/values-zh-rCN/strings.xml
index 0357275..7f2ac63 100644
--- a/res/values-zh-rCN/strings.xml
+++ b/res/values-zh-rCN/strings.xml
@@ -1794,7 +1794,7 @@
<string name="print_blocked_state_title_template" msgid="9065391617425962424">"打印机拒绝打印“<xliff:g id="PRINT_JOB_NAME">%1$s</xliff:g>”"</string>
<string name="print_search_box_shown_utterance" msgid="7730361832020726951">"搜索框已显示"</string>
<string name="print_search_box_hidden_utterance" msgid="7980832833405818400">"搜索框已隐藏"</string>
- <string name="printer_info_desc" msgid="5824995108703060003">"关于此打印机的更多信息"</string>
+ <string name="printer_info_desc" msgid="5824995108703060003">"此打印机的详细信息"</string>
<string name="power_usage_summary_title" msgid="7190304207330319919">"电池"</string>
<string name="power_usage_summary" msgid="7237084831082848168">"耗电情况"</string>
<string name="power_usage_not_available" msgid="3109326074656512387">"没有电池使用数据。"</string>
@@ -1810,7 +1810,7 @@
<string name="battery_stats_screen_on_label" msgid="7150221809877509708">"屏幕开启"</string>
<string name="battery_stats_gps_on_label" msgid="1193657533641951256">"GPS 开启"</string>
<string name="battery_stats_camera_on_label" msgid="4935637383628414968">"相机开启"</string>
- <string name="battery_stats_flashlight_on_label" msgid="4319637669889411307">"手电筒已开启"</string>
+ <string name="battery_stats_flashlight_on_label" msgid="4319637669889411307">"手电筒开启"</string>
<string name="battery_stats_wifi_running_label" msgid="1845839195549226252">"WLAN"</string>
<string name="battery_stats_wake_lock_label" msgid="1908942681902324095">"唤醒"</string>
<string name="battery_stats_phone_signal_label" msgid="3537569115723850618">"移动网络信号"</string>
diff --git a/res/values-zh-rTW/strings.xml b/res/values-zh-rTW/strings.xml
index d097594..c4190aa 100644
--- a/res/values-zh-rTW/strings.xml
+++ b/res/values-zh-rTW/strings.xml
@@ -910,11 +910,11 @@
<string name="auto_brightness_summary" msgid="1799041158760605375">"根據環境光源調整最佳亮度"</string>
<string name="night_display_title" msgid="2626451512200357686">"夜燈"</string>
<string name="night_display_text" msgid="4535302797673277668">"夜燈功能會將您的螢幕色調改為紅色,讓您更輕鬆地在光線昏暗的環境中查看螢幕,也比較容易入睡。"</string>
- <string name="night_display_category_schedule" msgid="2044072617637348966">"排程"</string>
+ <string name="night_display_category_schedule" msgid="2044072617637348966">"設定時間"</string>
<string name="night_display_category_status" msgid="1952928783124400330">"狀態"</string>
<string name="night_display_auto_mode_title" msgid="8046314360381608455">"自動開啟"</string>
<string name="night_display_auto_mode_never" msgid="6723636142053240947">"永不"</string>
- <string name="night_display_auto_mode_custom" msgid="6012300346981608242">"自訂時間表"</string>
+ <string name="night_display_auto_mode_custom" msgid="6012300346981608242">"自訂時間"</string>
<string name="night_display_auto_mode_twilight" msgid="2123345097508167094">"日落到日出"</string>
<string name="night_display_start_time_title" msgid="8918016772613689584">"開始時間"</string>
<string name="night_display_end_time_title" msgid="8286061578083519350">"結束時間"</string>
diff --git a/res/values/strings.xml b/res/values/strings.xml
index fa17aab..cc3ee44 100644
--- a/res/values/strings.xml
+++ b/res/values/strings.xml
@@ -833,11 +833,6 @@
<!-- Text shown in fingerprint enroll when we didn't observe progress for a few seconds. [CHAR LIMIT=100] -->
<string name="security_settings_fingerprint_enroll_lift_touch_again">Lift finger, then touch sensor again</string>
- <!-- Message shown in fingerprint enrollment during setup wizard once enrollment is complete. [CHAR LIMIT=NONE] -->
- <string name="setup_fingerprint_enroll_finish_message">Whenever you see this icon, you can use your fingerprint.</string>
- <!-- Secondary message shown in fingerprint enrollment during setup wizard once enrollment is complete, telling the user how to change the settings after they are done with setup. [CHAR LIMIT=NONE] -->
- <string name="setup_fingerprint_enroll_finish_secondary_message">To change your settings, go to Settings > Security > Fingerprint.</string>
-
<!-- Text shown when "Add fingerprint" button is disabled -->
<string name="fingerprint_add_max">You can add up to <xliff:g id="count" example="5">%d</xliff:g> fingerprints</string>
@@ -7733,7 +7728,7 @@
<string name="double_tap_power_for_camera_title">Jump to Camera</string>
<!-- Summary text for double tap power for camera [CHAR LIMIT=160]-->
- <string name="double_tap_power_for_camera_summary">To quickly open camera, just double-tap the power button. Works from any screen</string>
+ <string name="double_tap_power_for_camera_summary">To quickly open camera, press the power button twice. Works from any screen</string>
<!-- Title text for double twist for camera mode [CHAR LIMIT=60]-->
<string name="double_twist_for_camera_mode_title">Flip camera</string>
diff --git a/res/values/themes.xml b/res/values/themes.xml
index e861113..0009bed 100644
--- a/res/values/themes.xml
+++ b/res/values/themes.xml
@@ -99,6 +99,7 @@
<item name="@dropdownPreferenceStyle">@style/Preference.DropDown.Material</item>
<item name="@android:preferenceFragmentStyle">@style/PreferenceFragmentStyle</item>
<item name="apnPreferenceStyle">@style/ApnPreference</item>
+ <item name="android:scrollbars">vertical</item>
</style>
<style name="PreferenceTheme.SetupWizard" parent="SetupWizardTheme">
diff --git a/src/com/android/settings/ConfirmDeviceCredentialBaseFragment.java b/src/com/android/settings/ConfirmDeviceCredentialBaseFragment.java
index b46fa92..dd76b79 100644
--- a/src/com/android/settings/ConfirmDeviceCredentialBaseFragment.java
+++ b/src/com/android/settings/ConfirmDeviceCredentialBaseFragment.java
@@ -189,7 +189,6 @@
(TrustManager) getActivity().getSystemService(Context.TRUST_SERVICE);
trustManager.setDeviceLockedForUser(mEffectiveUserId, false);
authenticationSucceeded();
- authenticationSucceeded();
checkForPendingIntent();
}
}
diff --git a/src/com/android/settings/DevelopmentSettings.java b/src/com/android/settings/DevelopmentSettings.java
index dbcb277..08eae1a 100644
--- a/src/com/android/settings/DevelopmentSettings.java
+++ b/src/com/android/settings/DevelopmentSettings.java
@@ -53,11 +53,11 @@
import android.os.StrictMode;
import android.os.SystemProperties;
import android.os.UserHandle;
-import android.service.persistentdata.PersistentDataBlockManager;
import android.os.UserManager;
import android.os.storage.IMountService;
import android.provider.SearchIndexableResource;
import android.provider.Settings;
+import android.service.persistentdata.PersistentDataBlockManager;
import android.support.v14.preference.SwitchPreference;
import android.support.v7.preference.ListPreference;
import android.support.v7.preference.Preference;
@@ -67,9 +67,9 @@
import android.telephony.TelephonyManager;
import android.text.TextUtils;
import android.util.Log;
-import android.view.ThreadedRenderer;
import android.view.IWindowManager;
import android.view.LayoutInflater;
+import android.view.ThreadedRenderer;
import android.view.View;
import android.view.ViewGroup;
import android.view.accessibility.AccessibilityManager;
@@ -684,10 +684,6 @@
Settings.Global.STAY_ON_WHILE_PLUGGED_IN, 0) != 0);
updateSwitchPreference(mBtHciSnoopLog, Settings.Secure.getInt(cr,
Settings.Secure.BLUETOOTH_HCI_LOG, 0) != 0);
- if (mEnableOemUnlock != null) {
- updateSwitchPreference(mEnableOemUnlock, Utils.isOemUnlockEnabled(getActivity()));
- updateOemUnlockSettingDescription();
- }
updateSwitchPreference(mDebugViewAttributes, Settings.Global.getInt(cr,
Settings.Global.DEBUG_VIEW_ATTRIBUTES, 0) != 0);
updateSwitchPreference(mForceAllowOnExternal, Settings.Global.getInt(cr,
@@ -1039,6 +1035,8 @@
private void updateOemUnlockOptions() {
if (mEnableOemUnlock != null) {
+ updateSwitchPreference(mEnableOemUnlock, Utils.isOemUnlockEnabled(getActivity()));
+ updateOemUnlockSettingDescription();
// Showing mEnableOemUnlock preference as device has persistent data block.
mEnableOemUnlock.setDisabledByAdmin(null);
mEnableOemUnlock.setEnabled(enableOemUnlockPreference());
diff --git a/src/com/android/settings/PreviewPagerAdapter.java b/src/com/android/settings/PreviewPagerAdapter.java
index 7e4ebf3..5001518 100644
--- a/src/com/android/settings/PreviewPagerAdapter.java
+++ b/src/com/android/settings/PreviewPagerAdapter.java
@@ -23,6 +23,8 @@
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
+import android.view.ViewStub;
+import android.view.ViewStub.OnInflateListener;
import android.view.animation.AccelerateInterpolator;
import android.view.animation.DecelerateInterpolator;
import android.view.animation.Interpolator;
@@ -53,10 +55,13 @@
private int mAnimationCounter;
+ private boolean[][] mViewStubInflated;
+
public PreviewPagerAdapter(Context context, boolean isLayoutRtl,
int[] previewSampleResIds, Configuration[] configurations) {
mIsLayoutRtl = isLayoutRtl;
mPreviewFrames = new FrameLayout[previewSampleResIds.length];
+ mViewStubInflated = new boolean[previewSampleResIds.length][configurations.length];
for (int i = 0; i < previewSampleResIds.length; ++i) {
int p = mIsLayoutRtl ? previewSampleResIds.length - 1 - i : i;
@@ -65,18 +70,25 @@
LinearLayout.LayoutParams.MATCH_PARENT,
LinearLayout.LayoutParams.MATCH_PARENT));
- for (Configuration configuration : configurations) {
+ for (int j = 0; j < configurations.length; ++j) {
// Create a new configuration for the specified value. It won't
// have any theme set, so manually apply the current theme.
- final Context configContext = context.createConfigurationContext(configuration);
+ final Context configContext = context.createConfigurationContext(configurations[j]);
configContext.setTheme(context.getThemeResId());
final LayoutInflater configInflater = LayoutInflater.from(configContext);
- final View sampleView = configInflater.inflate(previewSampleResIds[i],
- mPreviewFrames[p], false);
- sampleView.setAlpha(0);
- sampleView.setVisibility(View.INVISIBLE);
- mPreviewFrames[p].addView(sampleView);
+ final ViewStub sampleViewStub = new ViewStub(configContext);
+ sampleViewStub.setLayoutResource(previewSampleResIds[i]);
+ final int fi = i, fj = j;
+ sampleViewStub.setOnInflateListener(new OnInflateListener() {
+ @Override
+ public void onInflate(ViewStub stub, View inflated) {
+ inflated.setVisibility(stub.getVisibility());
+ mViewStubInflated[fi][fj] = true;
+ }
+ });
+
+ mPreviewFrames[p].addView(sampleViewStub);
}
}
}
@@ -110,44 +122,71 @@
mAnimationEndAction = action;
}
- void setPreviewLayer(int newIndex, int currentIndex, int currentItem, boolean animate) {
+ void setPreviewLayer(int newLayerIndex, int currentLayerIndex, int currentFrameIndex,
+ final boolean animate) {
for (FrameLayout previewFrame : mPreviewFrames) {
- if (currentIndex >= 0) {
- final View lastLayer = previewFrame.getChildAt(currentIndex);
- if (animate && previewFrame == mPreviewFrames[currentItem]) {
- lastLayer.animate()
- .alpha(0)
- .setInterpolator(FADE_OUT_INTERPOLATOR)
- .setDuration(CROSS_FADE_DURATION_MS)
- .setListener(new PreviewFrameAnimatorListener())
- .withEndAction(new Runnable() {
- @Override
- public void run() {
- lastLayer.setVisibility(View.INVISIBLE);
- }
- });
- } else {
- lastLayer.setAlpha(0);
- lastLayer.setVisibility(View.INVISIBLE);
+ if (currentLayerIndex >= 0) {
+ final View lastLayer = previewFrame.getChildAt(currentLayerIndex);
+ if (mViewStubInflated[currentFrameIndex][currentLayerIndex]) {
+ // Explicitly set to INVISIBLE only when the stub has
+ // already been inflated.
+ if (previewFrame == mPreviewFrames[currentFrameIndex]) {
+ setVisibility(lastLayer, View.INVISIBLE, animate);
+ } else {
+ setVisibility(lastLayer, View.INVISIBLE, false);
+ }
}
}
- final View nextLayer = previewFrame.getChildAt(newIndex);
- if (animate && previewFrame == mPreviewFrames[currentItem]) {
- nextLayer.animate()
- .alpha(1)
- .setInterpolator(FADE_IN_INTERPOLATOR)
- .setDuration(CROSS_FADE_DURATION_MS)
- .setListener(new PreviewFrameAnimatorListener())
- .withStartAction(new Runnable() {
- @Override
- public void run() {
- nextLayer.setVisibility(View.VISIBLE);
- }
- });
+ // Set next layer visible, as well as inflate necessary views.
+ View nextLayer = previewFrame.getChildAt(newLayerIndex);
+ if (previewFrame == mPreviewFrames[currentFrameIndex]) {
+ // Inflate immediately if the stub has not yet been inflated.
+ if (!mViewStubInflated[currentFrameIndex][newLayerIndex]) {
+ nextLayer = ((ViewStub) nextLayer).inflate();
+ nextLayer.setAlpha(0.0f);
+ }
+ setVisibility(nextLayer, View.VISIBLE, animate);
} else {
- nextLayer.setVisibility(View.VISIBLE);
- nextLayer.setAlpha(1);
+ setVisibility(nextLayer, View.VISIBLE, false);
+ }
+ }
+ }
+
+ private void setVisibility(final View view, final int visibility, boolean animate) {
+ final float alpha = (visibility == View.VISIBLE ? 1.0f : 0.0f);
+ if (!animate) {
+ view.setAlpha(alpha);
+ view.setVisibility(visibility);
+ } else {
+ final Interpolator interpolator = (visibility == View.VISIBLE ? FADE_IN_INTERPOLATOR
+ : FADE_OUT_INTERPOLATOR);
+ if (visibility == View.VISIBLE) {
+ // Fade in animation.
+ view.animate()
+ .alpha(alpha)
+ .setInterpolator(FADE_IN_INTERPOLATOR)
+ .setDuration(CROSS_FADE_DURATION_MS)
+ .setListener(new PreviewFrameAnimatorListener())
+ .withStartAction(new Runnable() {
+ @Override
+ public void run() {
+ view.setVisibility(visibility);
+ }
+ });
+ } else {
+ // Fade out animation.
+ view.animate()
+ .alpha(alpha)
+ .setInterpolator(FADE_OUT_INTERPOLATOR)
+ .setDuration(CROSS_FADE_DURATION_MS)
+ .setListener(new PreviewFrameAnimatorListener())
+ .withEndAction(new Runnable() {
+ @Override
+ public void run() {
+ view.setVisibility(visibility);
+ }
+ });
}
}
}
diff --git a/src/com/android/settings/SettingsActivity.java b/src/com/android/settings/SettingsActivity.java
index 5b81c56..05d67b5 100644
--- a/src/com/android/settings/SettingsActivity.java
+++ b/src/com/android/settings/SettingsActivity.java
@@ -588,7 +588,6 @@
// of starting fresh.
mSearchMenuItemExpanded = savedState.getBoolean(SAVE_KEY_SEARCH_MENU_EXPANDED);
mSearchQuery = savedState.getString(SAVE_KEY_SEARCH_QUERY);
-
setTitleFromIntent(intent);
ArrayList<DashboardCategory> categories =
@@ -601,6 +600,7 @@
mDisplayHomeAsUpEnabled = savedState.getBoolean(SAVE_KEY_SHOW_HOME_AS_UP);
mDisplaySearch = savedState.getBoolean(SAVE_KEY_SHOW_SEARCH);
+
} else {
if (!mIsShowingDashboard) {
mDisplaySearch = false;
@@ -623,7 +623,13 @@
// Show Search affordance
mDisplaySearch = true;
mInitialTitleResId = R.string.dashboard_title;
- switchToFragment(DashboardContainerFragment.class.getName(), null, false, false,
+
+ // add argument to indicate which settings tab should be initially selected
+ final Bundle args = new Bundle();
+ final String extraName = DashboardContainerFragment.EXTRA_SELECT_SETTINGS_TAB;
+ args.putString(extraName, intent.getStringExtra(extraName));
+
+ switchToFragment(DashboardContainerFragment.class.getName(), args, false, false,
mInitialTitleResId, mInitialTitle, false);
}
}
@@ -1272,5 +1278,4 @@
}
super.onActivityResult(requestCode, resultCode, data);
}
-
}
diff --git a/src/com/android/settings/ShowAdminSupportDetailsDialog.java b/src/com/android/settings/ShowAdminSupportDetailsDialog.java
index 8ee07f9..2f65bb5 100644
--- a/src/com/android/settings/ShowAdminSupportDetailsDialog.java
+++ b/src/com/android/settings/ShowAdminSupportDetailsDialog.java
@@ -17,17 +17,14 @@
package com.android.settings;
import android.app.Activity;
-import android.app.ActivityManagerNative;
import android.app.AlertDialog;
import android.app.AppGlobals;
-import android.app.IActivityManager;
import android.app.admin.DevicePolicyManager;
import android.content.ComponentName;
import android.content.Context;
import android.content.DialogInterface;
import android.content.Intent;
import android.content.pm.ActivityInfo;
-import android.content.pm.PackageManager;
import android.graphics.drawable.Drawable;
import android.os.Bundle;
import android.os.Process;
@@ -47,8 +44,6 @@
private static final String TAG = "AdminSupportDialog";
- private DevicePolicyManager mDpm;
-
private EnforcedAdmin mEnforcedAdmin;
private View mDialogView;
@@ -56,7 +51,6 @@
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
- mDpm = getSystemService(DevicePolicyManager.class);
mEnforcedAdmin = getAdminDetailsFromIntent(getIntent());
AlertDialog.Builder builder = new AlertDialog.Builder(this);
@@ -84,26 +78,11 @@
if (intent == null) {
return admin;
}
- // Only allow apps with MANAGE_DEVICE_ADMINS permission to specify admin and user.
- if (checkIfCallerHasPermission(android.Manifest.permission.MANAGE_DEVICE_ADMINS)) {
- admin.component = intent.getParcelableExtra(DevicePolicyManager.EXTRA_DEVICE_ADMIN);
- admin.userId = intent.getIntExtra(Intent.EXTRA_USER_ID, UserHandle.myUserId());
- }
+ admin.component = intent.getParcelableExtra(DevicePolicyManager.EXTRA_DEVICE_ADMIN);
+ admin.userId = intent.getIntExtra(Intent.EXTRA_USER_ID, UserHandle.myUserId());
return admin;
}
- private boolean checkIfCallerHasPermission(String permission) {
- IActivityManager am = ActivityManagerNative.getDefault();
- try {
- final int uid = am.getLaunchedFromUid(getActivityToken());
- return AppGlobals.getPackageManager().checkUidPermission(permission, uid)
- == PackageManager.PERMISSION_GRANTED;
- } catch (RemoteException e) {
- Log.e(TAG, "Could not talk to activity manager.", e);
- }
- return false;
- }
-
private void initializeDialogViews(View root, ComponentName admin, int userId) {
if (admin != null) {
if (!RestrictedLockUtils.isAdminInCurrentUserOrProfile(this, admin)
diff --git a/src/com/android/settings/Utils.java b/src/com/android/settings/Utils.java
index 0725386..a37039f 100644
--- a/src/com/android/settings/Utils.java
+++ b/src/com/android/settings/Utils.java
@@ -515,7 +515,7 @@
if (resultTo == null) {
context.startActivity(intent);
} else {
- resultTo.startActivityForResult(intent, resultRequestCode);
+ resultTo.getActivity().startActivityForResult(intent, resultRequestCode);
}
}
diff --git a/src/com/android/settings/accounts/AccountSyncSettings.java b/src/com/android/settings/accounts/AccountSyncSettings.java
index fc760e6..8ceb5e5 100644
--- a/src/com/android/settings/accounts/AccountSyncSettings.java
+++ b/src/com/android/settings/accounts/AccountSyncSettings.java
@@ -28,9 +28,12 @@
import android.content.ContentResolver;
import android.content.Context;
import android.content.DialogInterface;
+import android.content.Intent;
+import android.content.IntentSender;
import android.content.SyncAdapterType;
import android.content.SyncInfo;
import android.content.SyncStatusInfo;
+import android.content.pm.PackageManager;
import android.content.pm.ProviderInfo;
import android.content.pm.UserInfo;
import android.os.Binder;
@@ -58,7 +61,6 @@
import java.io.IOException;
import java.util.ArrayList;
-import java.util.Collections;
import java.util.Date;
import java.util.List;
@@ -73,6 +75,7 @@
private static final int REALLY_REMOVE_DIALOG = 100;
private static final int FAILED_REMOVAL_DIALOG = 101;
private static final int CANT_DO_ONETIME_SYNC_DIALOG = 102;
+
private TextView mUserId;
private TextView mProviderId;
private ImageView mProviderIcon;
@@ -234,13 +237,15 @@
mAuthenticatorHelper.stopListeningToAccountUpdates();
}
- private void addSyncStateSwitch(Account account, String authority) {
+ private void addSyncStateSwitch(Account account, String authority,
+ String packageName, int uid) {
SyncStateSwitchPreference item = (SyncStateSwitchPreference) getCachedPreference(authority);
if (item == null) {
- item = new SyncStateSwitchPreference(getPrefContext(), account, authority);
+ item = new SyncStateSwitchPreference(getPrefContext(), account, authority,
+ packageName, uid);
getPreferenceScreen().addPreference(item);
} else {
- item.setup(account, authority);
+ item.setup(account, authority, packageName, uid);
}
item.setPersistent(false);
final ProviderInfo providerInfo = getPackageManager().resolveContentProviderAsUser(
@@ -323,20 +328,56 @@
}
@Override
+ public void onActivityResult(int requestCode, int resultCode, Intent data) {
+ if (resultCode == Activity.RESULT_OK) {
+ final int uid = requestCode;
+ final int count = getPreferenceScreen().getPreferenceCount();
+ for (int i = 0; i < count; i++) {
+ Preference preference = getPreferenceScreen().getPreference(i);
+ if (preference instanceof SyncStateSwitchPreference) {
+ SyncStateSwitchPreference syncPref = (SyncStateSwitchPreference) preference;
+ if (syncPref.getUid() == uid) {
+ onPreferenceTreeClick(syncPref);
+ return;
+ }
+ }
+ }
+ }
+ }
+
+ @Override
public boolean onPreferenceTreeClick(Preference preference) {
+ if (getActivity() == null) {
+ return false;
+ }
if (preference instanceof SyncStateSwitchPreference) {
SyncStateSwitchPreference syncPref = (SyncStateSwitchPreference) preference;
String authority = syncPref.getAuthority();
Account account = syncPref.getAccount();
final int userId = mUserHandle.getIdentifier();
+ String packageName = syncPref.getPackageName();
+
boolean syncAutomatically = ContentResolver.getSyncAutomaticallyAsUser(account,
authority, userId);
if (syncPref.isOneTimeSyncMode()) {
+ // If the sync adapter doesn't have access to the account we either
+ // request access by starting an activity if possible or kick off the
+ // sync which will end up posting an access request notification.
+ if (requestAccountAccessIfNeeded(packageName)) {
+ return true;
+ }
requestOrCancelSync(account, authority, true);
} else {
boolean syncOn = syncPref.isChecked();
boolean oldSyncState = syncAutomatically;
if (syncOn != oldSyncState) {
+ // Toggling this switch triggers sync but we may need a user approval.
+ // If the sync adapter doesn't have access to the account we either
+ // request access by starting an activity if possible or kick off the
+ // sync which will end up posting an access request notification.
+ if (syncOn && requestAccountAccessIfNeeded(packageName)) {
+ return true;
+ }
// if we're enabling sync, this will request a sync as well
ContentResolver.setSyncAutomaticallyAsUser(account, authority, syncOn, userId);
// if the master sync switch is off, the request above will
@@ -353,6 +394,36 @@
}
}
+ private boolean requestAccountAccessIfNeeded(String packageName) {
+ if (packageName == null) {
+ return false;
+ }
+
+ final int uid;
+ try {
+ uid = getContext().getPackageManager().getPackageUidAsUser(
+ packageName, mUserHandle.getIdentifier());
+ } catch (PackageManager.NameNotFoundException e) {
+ Log.e(TAG, "Invalid sync ", e);
+ return false;
+ }
+
+ AccountManager accountManager = getContext().getSystemService(AccountManager.class);
+ if (!accountManager.hasAccountAccess(mAccount, packageName, mUserHandle)) {
+ IntentSender intent = accountManager.createRequestAccountAccessIntentSenderAsUser(
+ mAccount, packageName, mUserHandle);
+ if (intent != null) {
+ try {
+ startIntentSenderForResult(intent, uid, null, 0, 0, 0, null);
+ return true;
+ } catch (IntentSender.SendIntentException e) {
+ Log.e(TAG, "Error requesting account access", e);
+ }
+ }
+ }
+ return false;
+ }
+
private void startSyncForEnabledProviders() {
requestOrCancelSyncForEnabledProviders(true /* start them */);
final Activity activity = getActivity();
@@ -520,7 +591,7 @@
SyncAdapterType[] syncAdapters = ContentResolver.getSyncAdapterTypesAsUser(
mUserHandle.getIdentifier());
- ArrayList<String> authorities = new ArrayList<String>();
+ ArrayList<SyncAdapterType> authorities = new ArrayList<>();
for (int i = 0, n = syncAdapters.length; i < n; i++) {
final SyncAdapterType sa = syncAdapters[i];
// Only keep track of sync adapters for this account
@@ -530,7 +601,7 @@
Log.d(TAG, "updateAccountSwitches: added authority " + sa.authority
+ " to accountType " + sa.accountType);
}
- authorities.add(sa.authority);
+ authorities.add(sa);
} else {
// keep track of invisible sync adapters, so sync now forces
// them to sync as well.
@@ -543,15 +614,23 @@
}
cacheRemoveAllPrefs(getPreferenceScreen());
for (int j = 0, m = authorities.size(); j < m; j++) {
- final String authority = authorities.get(j);
+ final SyncAdapterType syncAdapter = authorities.get(j);
// We could check services here....
- int syncState = ContentResolver.getIsSyncableAsUser(mAccount, authority,
+ int syncState = ContentResolver.getIsSyncableAsUser(mAccount, syncAdapter.authority,
mUserHandle.getIdentifier());
if (Log.isLoggable(TAG, Log.VERBOSE)) {
- Log.d(TAG, " found authority " + authority + " " + syncState);
+ Log.d(TAG, " found authority " + syncAdapter.authority + " " + syncState);
}
if (syncState > 0) {
- addSyncStateSwitch(mAccount, authority);
+ final int uid;
+ try {
+ uid = getContext().getPackageManager().getPackageUidAsUser(
+ syncAdapter.getPackageName(), mUserHandle.getIdentifier());
+ addSyncStateSwitch(mAccount, syncAdapter.authority,
+ syncAdapter.getPackageName(), uid);
+ } catch (PackageManager.NameNotFoundException e) {
+ Log.e(TAG, "No uid for package" + syncAdapter.getPackageName(), e);
+ }
}
}
removeCachedPrefs(getPreferenceScreen());
diff --git a/src/com/android/settings/accounts/SyncStateSwitchPreference.java b/src/com/android/settings/accounts/SyncStateSwitchPreference.java
index c6632d0..058fedd 100644
--- a/src/com/android/settings/accounts/SyncStateSwitchPreference.java
+++ b/src/com/android/settings/accounts/SyncStateSwitchPreference.java
@@ -36,6 +36,8 @@
private boolean mFailed = false;
private Account mAccount;
private String mAuthority;
+ private String mPackageName;
+ private int mUid;
/**
* A mode for this preference where clicking does a one-time sync instead of
@@ -47,16 +49,21 @@
super(context, attrs, 0, R.style.SyncSwitchPreference);
mAccount = null;
mAuthority = null;
+ mPackageName = null;
+ mUid = 0;
}
- public SyncStateSwitchPreference(Context context, Account account, String authority) {
+ public SyncStateSwitchPreference(Context context, Account account, String authority,
+ String packageName, int uid) {
super(context, null, 0, R.style.SyncSwitchPreference);
- setup(account, authority);
+ setup(account, authority, packageName, uid);
}
- public void setup(Account account, String authority) {
+ public void setup(Account account, String authority, String packageName, int uid) {
mAccount = account;
mAuthority = authority;
+ mPackageName = packageName;
+ mUid = uid;
notifyChanged();
}
@@ -152,4 +159,12 @@
public String getAuthority() {
return mAuthority;
}
+
+ public String getPackageName() {
+ return mPackageName;
+ };
+
+ public int getUid() {
+ return mUid;
+ };
}
diff --git a/src/com/android/settings/applications/AppInfoBase.java b/src/com/android/settings/applications/AppInfoBase.java
index 8a99e03..f7992cc 100644
--- a/src/com/android/settings/applications/AppInfoBase.java
+++ b/src/com/android/settings/applications/AppInfoBase.java
@@ -22,8 +22,10 @@
import android.app.DialogFragment;
import android.app.Fragment;
import android.app.admin.DevicePolicyManager;
+import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;
+import android.content.IntentFilter;
import android.content.pm.PackageInfo;
import android.content.pm.PackageManager;
import android.content.pm.PackageManager.NameNotFoundException;
@@ -74,6 +76,7 @@
protected static final int DLG_BASE = 0;
protected boolean mFinishing;
+ protected boolean mListeningToPackageRemove;
@Override
public void onCreate(Bundle savedInstanceState) {
@@ -90,6 +93,7 @@
mUsbManager = IUsbManager.Stub.asInterface(b);
retrieveAppEntry();
+ startListeningToPackageRemove();
}
@Override
@@ -114,6 +118,7 @@
@Override
public void onDestroy() {
+ stopListeningToPackageRemove();
mSession.release();
super.onDestroy();
}
@@ -246,4 +251,37 @@
return dialogFragment;
}
}
+
+ protected void startListeningToPackageRemove() {
+ if (mListeningToPackageRemove) {
+ return;
+ }
+ mListeningToPackageRemove = true;
+ final IntentFilter filter = new IntentFilter(Intent.ACTION_PACKAGE_REMOVED);
+ filter.addDataScheme("package");
+ getContext().registerReceiver(mPackageRemovedReceiver, filter);
+ }
+
+ protected void stopListeningToPackageRemove() {
+ if (!mListeningToPackageRemove) {
+ return;
+ }
+ mListeningToPackageRemove = false;
+ getContext().unregisterReceiver(mPackageRemovedReceiver);
+ }
+
+ protected void onPackageRemoved() {
+ getActivity().finishAndRemoveTask();
+ }
+
+ protected final BroadcastReceiver mPackageRemovedReceiver = new BroadcastReceiver() {
+ @Override
+ public void onReceive(Context context, Intent intent) {
+ String packageName = intent.getData().getSchemeSpecificPart();
+ if (!mFinishing && mAppEntry.info.packageName.equals(packageName)) {
+ onPackageRemoved();
+ }
+ }
+ };
+
}
diff --git a/src/com/android/settings/applications/AppStorageSettings.java b/src/com/android/settings/applications/AppStorageSettings.java
index 357ec1e..7c7d5a5 100644
--- a/src/com/android/settings/applications/AppStorageSettings.java
+++ b/src/com/android/settings/applications/AppStorageSettings.java
@@ -60,6 +60,9 @@
import java.util.Objects;
import java.util.TreeMap;
+import static android.content.pm.ApplicationInfo.FLAG_ALLOW_CLEAR_USER_DATA;
+import static android.content.pm.ApplicationInfo.FLAG_SYSTEM;
+
public class AppStorageSettings extends AppInfoWithHeader
implements OnClickListener, Callbacks, DialogInterface.OnClickListener {
private static final String TAG = AppStorageSettings.class.getSimpleName();
@@ -354,19 +357,27 @@
}
private void initDataButtons() {
- // If the app doesn't have its own space management UI
- // And it's a system app that doesn't allow clearing user data or is an active admin
- // Then disable the Clear Data button.
- if (mAppEntry.info.manageSpaceActivityName == null
- && ((mAppEntry.info.flags&(ApplicationInfo.FLAG_SYSTEM
- | ApplicationInfo.FLAG_ALLOW_CLEAR_USER_DATA))
- == ApplicationInfo.FLAG_SYSTEM
- || mDpm.packageHasActiveAdmins(mPackageName))) {
+ final boolean appHasSpaceManagementUI = mAppEntry.info.manageSpaceActivityName != null;
+ final boolean appHasActiveAdmins = mDpm.packageHasActiveAdmins(mPackageName);
+ // Check that SYSTEM_APP flag is set, and ALLOW_CLEAR_USER_DATA is not set.
+ final boolean isNonClearableSystemApp =
+ (mAppEntry.info.flags & (FLAG_SYSTEM | FLAG_ALLOW_CLEAR_USER_DATA)) == FLAG_SYSTEM;
+ final boolean appRestrictsClearingData = isNonClearableSystemApp || appHasActiveAdmins;
+
+ final Intent intent = new Intent(Intent.ACTION_DEFAULT);
+ if (appHasSpaceManagementUI) {
+ intent.setClassName(mAppEntry.info.packageName, mAppEntry.info.manageSpaceActivityName);
+ }
+ final boolean isManageSpaceActivityAvailable =
+ getPackageManager().resolveActivity(intent, 0) != null;
+
+ if ((!appHasSpaceManagementUI && appRestrictsClearingData)
+ || !isManageSpaceActivityAvailable) {
mClearDataButton.setText(R.string.clear_user_data_text);
mClearDataButton.setEnabled(false);
mCanClearData = false;
} else {
- if (mAppEntry.info.manageSpaceActivityName != null) {
+ if (appHasSpaceManagementUI) {
mClearDataButton.setText(R.string.manage_space_text);
} else {
mClearDataButton.setText(R.string.clear_user_data_text);
diff --git a/src/com/android/settings/applications/DefaultPhonePreference.java b/src/com/android/settings/applications/DefaultPhonePreference.java
index 5689c83..e151274 100644
--- a/src/com/android/settings/applications/DefaultPhonePreference.java
+++ b/src/com/android/settings/applications/DefaultPhonePreference.java
@@ -82,9 +82,13 @@
return false;
}
- final UserManager um =
- (UserManager) context.getSystemService(Context.USER_SERVICE);
- return !um.hasUserRestriction(UserManager.DISALLOW_OUTGOING_CALLS);
+ final UserManager um = (UserManager) context.getSystemService(Context.USER_SERVICE);
+ final boolean hasUserRestriction =
+ um.hasUserRestriction(UserManager.DISALLOW_OUTGOING_CALLS);
+ final CharSequence[] entries = getEntries();
+ return !hasUserRestriction
+ && entries != null
+ && entries.length > 0;
}
public static boolean hasPhonePreference(String pkg, Context context) {
diff --git a/src/com/android/settings/applications/InstalledAppDetails.java b/src/com/android/settings/applications/InstalledAppDetails.java
index f3d5f51..977f0b0 100755
--- a/src/com/android/settings/applications/InstalledAppDetails.java
+++ b/src/com/android/settings/applications/InstalledAppDetails.java
@@ -483,21 +483,22 @@
@Override
public void onActivityResult(int requestCode, int resultCode, Intent data) {
super.onActivityResult(requestCode, resultCode, data);
- if (requestCode == REQUEST_UNINSTALL) {
- if (mDisableAfterUninstall) {
- mDisableAfterUninstall = false;
- new DisableChanger(this, mAppEntry.info,
- PackageManager.COMPONENT_ENABLED_STATE_DISABLED_USER)
- .execute((Object)null);
- }
- if (!refreshUi()) {
- setIntentAndFinish(true, true);
- }
- }
- if (requestCode == REQUEST_REMOVE_DEVICE_ADMIN) {
- if (!refreshUi()) {
- setIntentAndFinish(true, true);
- }
+ switch (requestCode) {
+ case REQUEST_UNINSTALL:
+ if (mDisableAfterUninstall) {
+ mDisableAfterUninstall = false;
+ new DisableChanger(this, mAppEntry.info,
+ PackageManager.COMPONENT_ENABLED_STATE_DISABLED_USER)
+ .execute((Object)null);
+ }
+ // continue with following operations
+ case REQUEST_REMOVE_DEVICE_ADMIN:
+ if (!refreshUi()) {
+ setIntentAndFinish(true, true);
+ } else {
+ startListeningToPackageRemove();
+ }
+ break;
}
}
@@ -675,6 +676,7 @@
}
private void uninstallPkg(String packageName, boolean allUsers, boolean andDisable) {
+ stopListeningToPackageRemove();
// Create new intent to launch Uninstaller activity
Uri packageURI = Uri.parse("package:"+packageName);
Intent uninstallIntent = new Intent(Intent.ACTION_UNINSTALL_PACKAGE, packageURI);
@@ -730,7 +732,7 @@
intent.putExtra(Intent.EXTRA_PACKAGE_NAME, mAppEntry.info.packageName);
intent.putExtra(AppHeader.EXTRA_HIDE_INFO_BUTTON, true);
try {
- startActivity(intent);
+ getActivity().startActivityForResult(intent, SUB_INFO_FRAGMENT);
} catch (ActivityNotFoundException e) {
Log.w(LOG_TAG, "No app can handle android.intent.action.MANAGE_APP_PERMISSIONS");
}
@@ -764,6 +766,7 @@
String packageName = mAppEntry.info.packageName;
if (v == mUninstallButton) {
if (mDpm.packageHasActiveAdmins(mPackageInfo.packageName)) {
+ stopListeningToPackageRemove();
Activity activity = getActivity();
Intent uninstallDAIntent = new Intent(activity, DeviceAdminAdd.class);
uninstallDAIntent.putExtra(DeviceAdminAdd.EXTRA_DEVICE_ADMIN_PACKAGE_NAME,
@@ -1077,6 +1080,12 @@
return summary.toString();
}
+ @Override
+ protected void onPackageRemoved() {
+ getActivity().finishActivity(SUB_INFO_FRAGMENT);
+ super.onPackageRemoved();
+ }
+
private class MemoryUpdater extends AsyncTask<Void, Void, ProcStatsPackageEntry> {
@Override
diff --git a/src/com/android/settings/applications/ProcStatsEntry.java b/src/com/android/settings/applications/ProcStatsEntry.java
index 36d397e..90ef5d7 100644
--- a/src/com/android/settings/applications/ProcStatsEntry.java
+++ b/src/com/android/settings/applications/ProcStatsEntry.java
@@ -20,12 +20,13 @@
import android.content.pm.PackageManager;
import android.os.Parcel;
import android.os.Parcelable;
+import android.text.TextUtils;
import android.util.ArrayMap;
import android.util.Log;
import android.util.SparseArray;
-import com.android.internal.app.procstats.ProcessStats;
import com.android.internal.app.procstats.ProcessState;
+import com.android.internal.app.procstats.ProcessStats;
import com.android.internal.app.procstats.ServiceState;
import java.util.ArrayList;
@@ -33,6 +34,7 @@
import java.util.Comparator;
public final class ProcStatsEntry implements Parcelable {
+
private static final String TAG = "ProcStatsEntry";
private static boolean DEBUG = ProcessStatsUi.DEBUG;
@@ -40,7 +42,7 @@
final int mUid;
final String mName;
public CharSequence mLabel;
- final ArrayList<String> mPackages = new ArrayList<String>();
+ final ArrayList<String> mPackages = new ArrayList<>();
final long mBgDuration;
final long mAvgBgMem;
final long mMaxBgMem;
@@ -52,7 +54,7 @@
String mBestTargetPackage;
- ArrayMap<String, ArrayList<Service>> mServices = new ArrayMap<String, ArrayList<Service>>(1);
+ ArrayMap<String, ArrayList<Service>> mServices = new ArrayMap<>(1);
public ProcStatsEntry(ProcessState proc, String packageName,
ProcessStats.ProcessDataCollection tmpBgTotals,
@@ -249,6 +251,10 @@
+ " not as good as last " + bestRunTime);
}
}
+ // Final fallback, just pick the first subProc.
+ if (TextUtils.isEmpty(mBestTargetPackage)) {
+ mBestTargetPackage = subProcs.get(0).mPackage;
+ }
} else if (subProcs.size() == 1) {
mBestTargetPackage = subProcs.get(0).mPackage;
}
diff --git a/src/com/android/settings/bluetooth/RequestPermissionActivity.java b/src/com/android/settings/bluetooth/RequestPermissionActivity.java
index 9ce332d..3148aed 100644
--- a/src/com/android/settings/bluetooth/RequestPermissionActivity.java
+++ b/src/com/android/settings/bluetooth/RequestPermissionActivity.java
@@ -267,7 +267,7 @@
Log.d(TAG, "Setting Bluetooth Discoverable Timeout = " + mTimeout);
- if (mTimeout < 0 || mTimeout > MAX_DISCOVERABLE_TIMEOUT) {
+ if (mTimeout < 1 || mTimeout > MAX_DISCOVERABLE_TIMEOUT) {
mTimeout = BluetoothDiscoverableEnabler.DEFAULT_DISCOVERABLE_TIMEOUT;
}
} else {
diff --git a/src/com/android/settings/dashboard/DashboardContainerFragment.java b/src/com/android/settings/dashboard/DashboardContainerFragment.java
index 4268b81..cd42f7d 100644
--- a/src/com/android/settings/dashboard/DashboardContainerFragment.java
+++ b/src/com/android/settings/dashboard/DashboardContainerFragment.java
@@ -22,6 +22,7 @@
import android.content.Context;
import android.os.Bundle;
import android.support.v13.app.FragmentPagerAdapter;
+import android.text.TextUtils;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
@@ -42,6 +43,10 @@
*/
public final class DashboardContainerFragment extends InstrumentedFragment {
+ public static final String EXTRA_SELECT_SETTINGS_TAB = ":settings:select_settings_tab";
+
+ private static final String ARG_SUPPORT_TAB = "SUPPORT";
+ private static final String ARG_SUMMARY_TAB = "SUMMARY";
private static final int INDEX_SUMMARY_FRAGMENT = 0;
private static final int INDEX_SUPPORT_FRAGMENT = 1;
@@ -69,7 +74,16 @@
mViewPager.setAdapter(mPagerAdapter);
mViewPager.addOnPageChangeListener(
new TabChangeListener((SettingsActivity) getActivity()));
- mViewPager.setCurrentItem(INDEX_SUMMARY_FRAGMENT);
+
+ // check if support tab needs to be selected
+ final String selectedTab = getArguments().
+ getString(EXTRA_SELECT_SETTINGS_TAB, ARG_SUMMARY_TAB);
+ if (TextUtils.equals(selectedTab, ARG_SUPPORT_TAB)) {
+ mViewPager.setCurrentItem(INDEX_SUPPORT_FRAGMENT);
+ } else {
+ mViewPager.setCurrentItem(INDEX_SUMMARY_FRAGMENT);
+ }
+
mHeaderView = inflater.inflate(R.layout.dashboard_container_header, parent, false);
((SlidingTabLayout) mHeaderView).setViewPager(mViewPager);
return content;
diff --git a/src/com/android/settings/dashboard/DashboardSummary.java b/src/com/android/settings/dashboard/DashboardSummary.java
index 1c7e22d..12f036a 100644
--- a/src/com/android/settings/dashboard/DashboardSummary.java
+++ b/src/com/android/settings/dashboard/DashboardSummary.java
@@ -42,6 +42,7 @@
import com.android.settingslib.drawer.SettingsDrawerActivity;
import com.android.settingslib.drawer.Tile;
+import java.util.ArrayList;
import java.util.List;
public class DashboardSummary extends InstrumentedFragment
@@ -63,6 +64,8 @@
private static final String SUGGESTIONS = "suggestions";
private static final String EXTRA_SCROLL_POSITION = "scroll_position";
+ private static final String EXTRA_SUGGESTION_SHOWN_LOGGED = "suggestions_shown_logged";
+ private static final String EXTRA_SUGGESTION_HIDDEN_LOGGED = "suggestions_hidden_logged";
private FocusRecyclerView mDashboard;
private DashboardAdapter mAdapter;
@@ -71,6 +74,8 @@
private SuggestionParser mSuggestionParser;
private LinearLayoutManager mLayoutManager;
private SuggestionsChecks mSuggestionsChecks;
+ private ArrayList<String> mSuggestionsShownLogged;
+ private ArrayList<String> mSuggestionsHiddenLogged;
@Override
protected int getMetricsCategory() {
@@ -90,6 +95,15 @@
mSuggestionParser = new SuggestionParser(context,
context.getSharedPreferences(SUGGESTIONS, 0), R.xml.suggestion_ordering);
mSuggestionsChecks = new SuggestionsChecks(getContext());
+ if (savedInstanceState == null) {
+ mSuggestionsShownLogged = new ArrayList<>();
+ mSuggestionsHiddenLogged = new ArrayList<>();
+ } else {
+ mSuggestionsShownLogged =
+ savedInstanceState.getStringArrayList(EXTRA_SUGGESTION_SHOWN_LOGGED);
+ mSuggestionsHiddenLogged =
+ savedInstanceState.getStringArrayList(EXTRA_SUGGESTION_HIDDEN_LOGGED);
+ }
if (DEBUG_TIMING) Log.d(TAG, "onCreate took " + (System.currentTimeMillis() - startTime)
+ " ms");
}
@@ -112,12 +126,6 @@
MetricsLogger.visible(getContext(), c.getMetricsConstant());
}
}
- if (mAdapter.getSuggestions() != null) {
- for (Tile suggestion : mAdapter.getSuggestions()) {
- MetricsLogger.action(getContext(), MetricsEvent.ACTION_SHOW_SETTINGS_SUGGESTION,
- DashboardAdapter.getSuggestionIdentifier(getContext(), suggestion));
- }
- }
if (DEBUG_TIMING) Log.d(TAG, "onStart took " + (System.currentTimeMillis() - startTime)
+ " ms");
}
@@ -136,9 +144,15 @@
if (mAdapter.getSuggestions() == null) {
return;
}
- for (Tile suggestion : mAdapter.getSuggestions()) {
- MetricsLogger.action(getContext(), MetricsEvent.ACTION_HIDE_SETTINGS_SUGGESTION,
- DashboardAdapter.getSuggestionIdentifier(getContext(), suggestion));
+ if (!getActivity().isChangingConfigurations()) {
+ for (Tile suggestion : mAdapter.getSuggestions()) {
+ String id = DashboardAdapter.getSuggestionIdentifier(getContext(), suggestion);
+ if (!mSuggestionsHiddenLogged.contains(id)) {
+ mSuggestionsHiddenLogged.add(id);
+ MetricsLogger.action(getContext(),
+ MetricsEvent.ACTION_HIDE_SETTINGS_SUGGESTION, id);
+ }
+ }
}
}
@@ -169,6 +183,8 @@
if (mAdapter != null) {
mAdapter.onSaveInstanceState(outState);
}
+ outState.putStringArrayList(EXTRA_SUGGESTION_HIDDEN_LOGGED, mSuggestionsHiddenLogged);
+ outState.putStringArrayList(EXTRA_SUGGESTION_SHOWN_LOGGED, mSuggestionsShownLogged);
}
@Override
@@ -222,9 +238,17 @@
protected List<Tile> doInBackground(Void... params) {
List<Tile> suggestions = mSuggestionParser.getSuggestions();
for (int i = 0; i < suggestions.size(); i++) {
- if (mSuggestionsChecks.isSuggestionComplete(suggestions.get(i))) {
- mAdapter.disableSuggestion(suggestions.get(i));
+ Tile suggestion = suggestions.get(i);
+ if (mSuggestionsChecks.isSuggestionComplete(suggestion)) {
+ mAdapter.disableSuggestion(suggestion);
suggestions.remove(i--);
+ } else {
+ String id = DashboardAdapter.getSuggestionIdentifier(getContext(), suggestion);
+ if (!mSuggestionsShownLogged.contains(id)) {
+ mSuggestionsShownLogged.add(id);
+ MetricsLogger.action(getContext(),
+ MetricsEvent.ACTION_SHOW_SETTINGS_SUGGESTION, id);
+ }
}
}
return suggestions;
diff --git a/src/com/android/settings/dashboard/SupportItemAdapter.java b/src/com/android/settings/dashboard/SupportItemAdapter.java
index b5c130c..9ef69883 100644
--- a/src/com/android/settings/dashboard/SupportItemAdapter.java
+++ b/src/com/android/settings/dashboard/SupportItemAdapter.java
@@ -20,6 +20,7 @@
import android.annotation.LayoutRes;
import android.annotation.StringRes;
import android.app.Activity;
+import android.app.ActivityManager;
import android.app.DialogFragment;
import android.content.Context;
import android.content.Intent;
@@ -372,6 +373,13 @@
} else {
holder.text2View.setVisibility(View.GONE);
}
+
+ if (ActivityManager.isUserAMonkey()) {
+ holder.text1View.setVisibility(View.GONE);
+ holder.text2View.setVisibility(View.GONE);
+ spinner.setVisibility(View.GONE);
+ holder.itemView.findViewById(R.id.support_text).setVisibility(View.GONE);
+ }
}
private void bindSignInPromoTile(ViewHolder holder, EscalationData data) {
diff --git a/src/com/android/settings/dashboard/conditional/ConditionAdapterUtils.java b/src/com/android/settings/dashboard/conditional/ConditionAdapterUtils.java
index 51fd132..a16de50 100644
--- a/src/com/android/settings/dashboard/conditional/ConditionAdapterUtils.java
+++ b/src/com/android/settings/dashboard/conditional/ConditionAdapterUtils.java
@@ -68,12 +68,13 @@
card.setOnClickListener(onClickListener);
view.icon.setImageIcon(condition.getIcon());
view.title.setText(condition.getTitle());
- ImageView expand = (ImageView) view.itemView.findViewById(R.id.expand_indicator);
- expand.setTag(condition);
+ final View collapsedGroup = view.itemView.findViewById(R.id.collapsed_group);
+ collapsedGroup.setTag(condition);
+ final ImageView expand = (ImageView) view.itemView.findViewById(R.id.expand_indicator);
expand.setImageResource(isExpanded ? R.drawable.ic_expand_less : R.drawable.ic_expand_more);
expand.setContentDescription(expand.getContext().getString(isExpanded
? R.string.condition_expand_hide : R.string.condition_expand_show));
- expand.setOnClickListener(onExpandListener);
+ collapsedGroup.setOnClickListener(onExpandListener);
View detailGroup = view.itemView.findViewById(R.id.detail_group);
CharSequence[] actions = condition.getActions();
diff --git a/src/com/android/settings/datausage/BillingCycleSettings.java b/src/com/android/settings/datausage/BillingCycleSettings.java
index e9aa8c9..482703b 100644
--- a/src/com/android/settings/datausage/BillingCycleSettings.java
+++ b/src/com/android/settings/datausage/BillingCycleSettings.java
@@ -198,10 +198,16 @@
final long limitDisabled = isLimit ? LIMIT_DISABLED : WARNING_DISABLED;
if (bytes > 1.5f * GB_IN_BYTES) {
- bytesPicker.setText(formatText(bytes / (float) GB_IN_BYTES));
+ final String bytesText = formatText(bytes / (float) GB_IN_BYTES);
+ bytesPicker.setText(bytesText);
+ bytesPicker.setSelection(0, bytesText.length());
+
type.setSelection(1);
} else {
- bytesPicker.setText(formatText(bytes / (float) MB_IN_BYTES));
+ final String bytesText = formatText(bytes / (float) MB_IN_BYTES);
+ bytesPicker.setText(bytesText);
+ bytesPicker.setSelection(0, bytesText.length());
+
type.setSelection(0);
}
}
diff --git a/src/com/android/settings/deviceinfo/StorageSettings.java b/src/com/android/settings/deviceinfo/StorageSettings.java
index 532c720..ee68311 100644
--- a/src/com/android/settings/deviceinfo/StorageSettings.java
+++ b/src/com/android/settings/deviceinfo/StorageSettings.java
@@ -58,6 +58,7 @@
import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
+import java.util.Objects;
import static com.android.settingslib.RestrictedLockUtils.EnforcedAdmin;
@@ -165,17 +166,14 @@
for (VolumeInfo vol : volumes) {
if (vol.getType() == VolumeInfo.TYPE_PRIVATE) {
+ final long volumeTotalBytes = getTotalSize(vol);
final int color = COLOR_PRIVATE[privateCount++ % COLOR_PRIVATE.length];
mInternalCategory.addPreference(
- new StorageVolumePreference(context, vol, color, sTotalInternalStorage));
+ new StorageVolumePreference(context, vol, color, volumeTotalBytes));
if (vol.isMountedReadable()) {
final File path = vol.getPath();
- privateUsedBytes += path.getTotalSpace() - path.getFreeSpace();
- if (sTotalInternalStorage > 0) {
- privateTotalBytes = sTotalInternalStorage;
- } else {
- privateTotalBytes += path.getTotalSpace();
- }
+ privateUsedBytes += (volumeTotalBytes - path.getFreeSpace());
+ privateTotalBytes += volumeTotalBytes;
}
} else if (vol.getType() == VolumeInfo.TYPE_PUBLIC) {
mExternalCategory.addPreference(
@@ -277,7 +275,7 @@
if (vol.getType() == VolumeInfo.TYPE_PRIVATE) {
final Bundle args = new Bundle();
args.putString(VolumeInfo.EXTRA_VOLUME_ID, vol.getId());
- PrivateVolumeSettings.setVolumeSize(args, sTotalInternalStorage);
+ PrivateVolumeSettings.setVolumeSize(args, getTotalSize(vol));
startFragment(this, PrivateVolumeSettings.class.getCanonicalName(),
-1, 0, args);
return true;
@@ -495,19 +493,11 @@
long privateFreeBytes = 0;
long privateTotalBytes = 0;
for (VolumeInfo info : volumes) {
- if (info.getType() != VolumeInfo.TYPE_PUBLIC
- && info.getType() != VolumeInfo.TYPE_PRIVATE) {
- continue;
- }
final File path = info.getPath();
- if (path == null) {
+ if (info.getType() != VolumeInfo.TYPE_PRIVATE || path == null) {
continue;
}
- if (info.getType() == VolumeInfo.TYPE_PRIVATE && sTotalInternalStorage > 0) {
- privateTotalBytes = sTotalInternalStorage;
- } else {
- privateTotalBytes += path.getTotalSpace();
- }
+ privateTotalBytes += getTotalSize(info);
privateFreeBytes += path.getFreeSpace();
}
long privateUsedBytes = privateTotalBytes - privateFreeBytes;
@@ -517,6 +507,27 @@
}
}
+ private static long getTotalSize(VolumeInfo info) {
+ // Device could have more than one primary storage, which could be located in the
+ // internal flash (UUID_PRIVATE_INTERNAL) or in an external disk.
+ // If it's internal, try to get its total size from StorageManager first
+ // (sTotalInternalStorage), since that size is more precise because it accounts for
+ // the system partition.
+ if (info.getType() == VolumeInfo.TYPE_PRIVATE
+ && Objects.equals(info.getFsUuid(), StorageManager.UUID_PRIVATE_INTERNAL)
+ && sTotalInternalStorage > 0) {
+ return sTotalInternalStorage;
+ } else {
+ final File path = info.getPath();
+ if (path == null) {
+ // Should not happen, caller should have checked.
+ Log.e(TAG, "info's path is null on getTotalSize(): " + info);
+ return 0;
+ }
+ return path.getTotalSpace();
+ }
+ }
+
public static final SummaryLoader.SummaryProviderFactory SUMMARY_PROVIDER_FACTORY
= new SummaryLoader.SummaryProviderFactory() {
@Override
diff --git a/src/com/android/settings/fuelgauge/BatterySaverSettings.java b/src/com/android/settings/fuelgauge/BatterySaverSettings.java
index bd19db8..e19f683 100644
--- a/src/com/android/settings/fuelgauge/BatterySaverSettings.java
+++ b/src/com/android/settings/fuelgauge/BatterySaverSettings.java
@@ -25,6 +25,7 @@
import android.database.ContentObserver;
import android.net.Uri;
import android.os.AsyncTask;
+import android.os.BatteryManager;
import android.os.Bundle;
import android.os.Handler;
import android.os.PowerManager;
@@ -186,23 +187,36 @@
};
private final class Receiver extends BroadcastReceiver {
+
private boolean mRegistered;
@Override
public void onReceive(Context context, Intent intent) {
if (DEBUG) Log.d(TAG, "Received " + intent.getAction());
- mHandler.post(mUpdateSwitch);
+ String action = intent.getAction();
+ if (action.equals(ACTION_POWER_SAVE_MODE_CHANGING)) {
+ mHandler.post(mUpdateSwitch);
+ } else if (action.equals(Intent.ACTION_BATTERY_CHANGED)) {
+ final int status = intent.getIntExtra(BatteryManager.EXTRA_STATUS, -1);
+ // disable BSM switch if phone is plugged in or at 100% while plugged in
+ mSwitchBar.setEnabled(
+ !(status == BatteryManager.BATTERY_STATUS_CHARGING
+ || status == BatteryManager.BATTERY_STATUS_FULL));
+ }
}
-
public void setListening(boolean listening) {
if (listening && !mRegistered) {
- mContext.registerReceiver(this, new IntentFilter(ACTION_POWER_SAVE_MODE_CHANGING));
+ final IntentFilter ifilter = new IntentFilter();
+ ifilter.addAction(ACTION_POWER_SAVE_MODE_CHANGING);
+ ifilter.addAction(Intent.ACTION_BATTERY_CHANGED);
+ mContext.registerReceiver(this, ifilter);
mRegistered = true;
} else if (!listening && mRegistered) {
mContext.unregisterReceiver(this);
mRegistered = false;
}
}
+
}
private final class SettingsObserver extends ContentObserver {
diff --git a/src/com/android/settings/gestures/GesturePreference.java b/src/com/android/settings/gestures/GesturePreference.java
index eae7316..2d921bf 100644
--- a/src/com/android/settings/gestures/GesturePreference.java
+++ b/src/com/android/settings/gestures/GesturePreference.java
@@ -185,6 +185,12 @@
Loader<Bitmap> loader = manager.initLoader(id, Bundle.EMPTY, this);
}
+ void onViewVisible() {
+ if (mVideoReady && mMediaPlayer != null && !mMediaPlayer.isPlaying()) {
+ mMediaPlayer.seekTo(0);
+ }
+ }
+
private static final class PreviewRetriever extends AsyncLoader<Bitmap> {
private Uri mVideoPath;
diff --git a/src/com/android/settings/gestures/GestureSettings.java b/src/com/android/settings/gestures/GestureSettings.java
index 8f028b6..9932bd6 100644
--- a/src/com/android/settings/gestures/GestureSettings.java
+++ b/src/com/android/settings/gestures/GestureSettings.java
@@ -119,6 +119,14 @@
}
@Override
+ public void onStart() {
+ super.onStart();
+ for (GesturePreference preference : mPreferences) {
+ preference.onViewVisible();
+ }
+ }
+
+ @Override
public boolean onPreferenceChange(Preference preference, Object newValue) {
boolean enabled = (boolean) newValue;
String key = preference.getKey();
diff --git a/src/com/android/settings/users/UserSettings.java b/src/com/android/settings/users/UserSettings.java
index d943e52..4e0d8fa 100644
--- a/src/com/android/settings/users/UserSettings.java
+++ b/src/com/android/settings/users/UserSettings.java
@@ -224,6 +224,7 @@
mMePreference.setSummary(R.string.user_admin);
}
mAddUser = (DimmableIconPreference) findPreference(KEY_ADD_USER);
+ mAddUser.useAdminDisabledSummary(false);
// Determine if add user/profile button should be visible
if (mUserCaps.mCanAddUser && Utils.isDeviceProvisioned(getActivity())) {
mAddUser.setOnPreferenceClickListener(this);
diff --git a/src/com/android/settings/wifi/LongPressAccessPointPreference.java b/src/com/android/settings/wifi/LongPressAccessPointPreference.java
index 46746cb..79f29ef 100644
--- a/src/com/android/settings/wifi/LongPressAccessPointPreference.java
+++ b/src/com/android/settings/wifi/LongPressAccessPointPreference.java
@@ -17,21 +17,8 @@
import android.app.Fragment;
import android.content.Context;
-import android.content.pm.PackageManager;
-import android.graphics.drawable.Drawable;
-import android.graphics.drawable.StateListDrawable;
-import android.net.wifi.WifiConfiguration;
-import android.os.Looper;
-import android.os.UserHandle;
-import android.support.v7.preference.Preference;
import android.support.v7.preference.PreferenceViewHolder;
-import android.text.TextUtils;
import android.util.AttributeSet;
-import android.util.SparseArray;
-import android.view.View;
-import android.widget.TextView;
-
-import com.android.settings.R;
import com.android.settingslib.wifi.AccessPoint;
import com.android.settingslib.wifi.AccessPointPreference;
@@ -51,6 +38,12 @@
mFragment = fragment;
}
+ public LongPressAccessPointPreference(AccessPoint accessPoint, Context context,
+ UserBadgeCache cache, boolean forSavedNetworks, int iconResId, Fragment fragment) {
+ super(accessPoint, context, cache, iconResId, forSavedNetworks);
+ mFragment = fragment;
+ }
+
@Override
public void onBindViewHolder(final PreferenceViewHolder view) {
super.onBindViewHolder(view);
diff --git a/src/com/android/settings/wifi/WifiSettings.java b/src/com/android/settings/wifi/WifiSettings.java
index a34ccab..41700ff 100644
--- a/src/com/android/settings/wifi/WifiSettings.java
+++ b/src/com/android/settings/wifi/WifiSettings.java
@@ -634,10 +634,10 @@
}
LongPressAccessPointPreference
preference = new LongPressAccessPointPreference(accessPoint,
- getPrefContext(), mUserBadgeCache, false, this);
+ getPrefContext(), mUserBadgeCache, false,
+ R.drawable.ic_wifi_signal_0, this);
preference.setKey(key);
preference.setOrder(index++);
-
if (mOpenSsid != null && mOpenSsid.equals(accessPoint.getSsidStr())
&& !accessPoint.isSaved()
&& accessPoint.getSecurity() != AccessPoint.SECURITY_NONE) {
@@ -646,6 +646,7 @@
}
getPreferenceScreen().addPreference(preference);
accessPoint.setListener(this);
+ preference.refresh();
}
}
removeCachedPrefs(getPreferenceScreen());
diff --git a/tests/app/Android.mk b/tests/app/Android.mk
index bb31539..cd13384 100644
--- a/tests/app/Android.mk
+++ b/tests/app/Android.mk
@@ -7,6 +7,11 @@
LOCAL_JAVA_LIBRARIES := android.test.runner bouncycastle
+LOCAL_STATIC_JAVA_LIBRARIES := \
+ android-support-test \
+ mockito-target \
+ espresso-core
+
# Include all test java files.
LOCAL_SRC_FILES := $(call all-java-files-under, src)
diff --git a/tests/app/AndroidManifest.xml b/tests/app/AndroidManifest.xml
index 2ef96cf..1c50700 100644
--- a/tests/app/AndroidManifest.xml
+++ b/tests/app/AndroidManifest.xml
@@ -51,9 +51,9 @@
</activity>
</application>
- <instrumentation android:name="android.test.InstrumentationTestRunner"
+ <instrumentation android:name="android.support.test.runner.AndroidJUnitRunner"
android:targetPackage="com.android.settings"
- android:label="Settings App Tests">
+ android:label="Settings Test Cases">
</instrumentation>
<instrumentation android:name="SettingsLaunchPerformance"
diff --git a/tests/app/src/com/android/settings/dashboard/TabSelectionOnLaunchTest.java b/tests/app/src/com/android/settings/dashboard/TabSelectionOnLaunchTest.java
new file mode 100644
index 0000000..24c1ead
--- /dev/null
+++ b/tests/app/src/com/android/settings/dashboard/TabSelectionOnLaunchTest.java
@@ -0,0 +1,108 @@
+/*
+ * Copyright (C) 2016 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.settings.dashboard;
+
+import android.content.Intent;
+import android.support.test.InstrumentationRegistry;
+import android.support.test.filters.SmallTest;
+import android.support.test.rule.ActivityTestRule;
+import android.support.test.runner.AndroidJUnit4;
+import com.android.settings.Settings;
+import org.junit.Rule;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+
+import static android.support.test.espresso.Espresso.onView;
+import static android.support.test.espresso.assertion.ViewAssertions.matches;
+import static android.support.test.espresso.matcher.ViewMatchers.isSelected;
+import static android.support.test.espresso.matcher.ViewMatchers.withText;
+import static org.hamcrest.core.IsNot.not;
+
+@RunWith(AndroidJUnit4.class)
+@SmallTest
+public class TabSelectionOnLaunchTest {
+ @Rule
+ public ActivityTestRule<Settings> mActivityRule =
+ new ActivityTestRule<>(Settings.class, true, false);
+
+ private final int FLAG_RESTART = Intent.FLAG_ACTIVITY_CLEAR_TASK|Intent.FLAG_ACTIVITY_NEW_TASK;
+ private final String ARG_SELECT_SUPPORT_TAB = "SUPPORT";
+ private final String ARG_SELECT_FAKE_TAB = "NOT_SUPPORT";
+
+ @Test
+ /* cold start for settings app with correct flags and extra always selects support tab */
+ public void test_ColdStartWithCorrectArgsCorrectFlags_SupportSelected() {
+ launchSettingsWithFlags(ARG_SELECT_SUPPORT_TAB, FLAG_RESTART);
+ verifySupportSelected();
+ }
+
+ @Test
+ /* cold start with correct flags and wrong extra defaults to all tab */
+ public void test_ColdStartWithWrongExtra_DoesNotSelectSupport() {
+ launchSettingsWithFlags(ARG_SELECT_FAKE_TAB, FLAG_RESTART);
+ verifySupportNotSelected();
+ }
+
+ @Test
+ /* warm start from elsewhere in settings with wrong flags does not select support */
+ public void test_WarmStartSummarySelectedCorrectExtraWrongFlags_DoesNotSelectSupport() {
+ InstrumentationRegistry.getContext().
+ startActivity(new Intent(android.provider.Settings.ACTION_SETTINGS));
+ launchSettingsNoFlags(ARG_SELECT_SUPPORT_TAB);
+ verifySupportNotSelected();
+ }
+
+ @Test
+ /* warm start from elsewhere in settings with with wrong flags & extra does not select support*/
+ public void test_WarmStartSummarySelectedWrongExtraWrongFlags_DoesNotSelectSupport() {
+ InstrumentationRegistry.getContext().
+ startActivity(new Intent(android.provider.Settings.ACTION_SETTINGS));
+ launchSettingsNoFlags(ARG_SELECT_FAKE_TAB);
+ verifySupportNotSelected();
+ }
+
+ @Test
+ /* settings does not crash on null string */
+ public void test_DoesNotCrashOnNullExtra_DoesNotSelectSupport() {
+ launchSettingsWithFlags(null, FLAG_RESTART);
+ verifySupportNotSelected();
+ }
+
+ private void verifySupportNotSelected() {
+ onView(withText(mActivityRule.getActivity().getApplicationContext().
+ getString(com.android.settings.R.string.page_tab_title_support))).
+ check(matches(not(isSelected())));
+ }
+
+ private void verifySupportSelected() {
+ onView(withText(mActivityRule.getActivity().getApplicationContext().
+ getString(com.android.settings.R.string.page_tab_title_support))).
+ check(matches(isSelected()));
+ }
+
+ private void launchSettingsWithFlags(String extra, int flags) {
+ Intent intent = new Intent(android.provider.Settings.ACTION_SETTINGS);
+ intent.setFlags(flags);
+ intent.putExtra(DashboardContainerFragment.EXTRA_SELECT_SETTINGS_TAB, extra);
+ mActivityRule.launchActivity(intent);
+ }
+
+ private void launchSettingsNoFlags(String extra) {
+ Intent intent = new Intent(android.provider.Settings.ACTION_SETTINGS);
+ intent.putExtra(DashboardContainerFragment.EXTRA_SELECT_SETTINGS_TAB, extra);
+ mActivityRule.launchActivity(intent);
+ }
+}
\ No newline at end of file
diff --git a/tests/unit/Android.mk b/tests/unit/Android.mk
index 3ba4606..5b20173 100644
--- a/tests/unit/Android.mk
+++ b/tests/unit/Android.mk
@@ -7,7 +7,10 @@
LOCAL_JAVA_LIBRARIES := android.test.runner
-LOCAL_STATIC_JAVA_LIBRARIES := android-support-test mockito-target
+LOCAL_STATIC_JAVA_LIBRARIES := \
+ android-support-test \
+ mockito-target \
+ espresso-core
# Include all test java files.
LOCAL_SRC_FILES := $(call all-java-files-under, src)