diff options
188 files changed, 2125 insertions, 954 deletions
diff --git a/apct-tests/perftests/core/res/layout/test_autosize_textview_10.xml b/apct-tests/perftests/core/res/layout/test_autosize_textview_10.xml index 791f587a98fa..a8d3de0b9a97 100644 --- a/apct-tests/perftests/core/res/layout/test_autosize_textview_10.xml +++ b/apct-tests/perftests/core/res/layout/test_autosize_textview_10.xml @@ -35,8 +35,7 @@ android:layout_width="400dp" android:layout_height="600dp" android:text="@string/long_text" - android:textDirection="rtl" - android:autoSizeText="xy" + android:autoSizeText="uniform" android:autoSizeMinTextSize="10px" android:textSize="20px" android:autoSizeStepGranularity="1px"/> diff --git a/apct-tests/perftests/core/res/layout/test_autosize_textview_100.xml b/apct-tests/perftests/core/res/layout/test_autosize_textview_100.xml index cca4a525b5e1..d991862f7a09 100644 --- a/apct-tests/perftests/core/res/layout/test_autosize_textview_100.xml +++ b/apct-tests/perftests/core/res/layout/test_autosize_textview_100.xml @@ -19,8 +19,7 @@ android:layout_width="400dp" android:layout_height="600dp" android:text="@string/long_text" - android:textDirection="rtl" - android:autoSizeText="xy" + android:autoSizeText="uniform" android:autoSizeMinTextSize="10px" android:textSize="110px" android:autoSizeStepGranularity="1px"/> diff --git a/apct-tests/perftests/core/res/layout/test_autosize_textview_1000.xml b/apct-tests/perftests/core/res/layout/test_autosize_textview_1000.xml index bb9fc5e6aa7f..3b55b6c8b56d 100644 --- a/apct-tests/perftests/core/res/layout/test_autosize_textview_1000.xml +++ b/apct-tests/perftests/core/res/layout/test_autosize_textview_1000.xml @@ -19,8 +19,7 @@ android:layout_width="400dp" android:layout_height="600dp" android:text="@string/long_text" - android:textDirection="rtl" - android:autoSizeText="xy" + android:autoSizeText="uniform" android:autoSizeMinTextSize="10px" android:textSize="1010px" android:autoSizeStepGranularity="1px"/> diff --git a/apct-tests/perftests/core/res/layout/test_autosize_textview_10000.xml b/apct-tests/perftests/core/res/layout/test_autosize_textview_10000.xml index e0e58789a3c7..64a25c27f4a5 100644 --- a/apct-tests/perftests/core/res/layout/test_autosize_textview_10000.xml +++ b/apct-tests/perftests/core/res/layout/test_autosize_textview_10000.xml @@ -19,8 +19,7 @@ android:layout_width="400dp" android:layout_height="600dp" android:text="@string/long_text" - android:textDirection="rtl" - android:autoSizeText="xy" + android:autoSizeText="uniform" android:autoSizeMinTextSize="10px" android:textSize="10010px" android:autoSizeStepGranularity="1px"/> diff --git a/apct-tests/perftests/core/res/layout/test_autosize_textview_100000.xml b/apct-tests/perftests/core/res/layout/test_autosize_textview_100000.xml index 4f668058e59a..1f6078396906 100644 --- a/apct-tests/perftests/core/res/layout/test_autosize_textview_100000.xml +++ b/apct-tests/perftests/core/res/layout/test_autosize_textview_100000.xml @@ -19,8 +19,7 @@ android:layout_width="400dp" android:layout_height="600dp" android:text="@string/long_text" - android:textDirection="rtl" - android:autoSizeText="xy" + android:autoSizeText="uniform" android:autoSizeMinTextSize="10px" android:textSize="100010px" android:autoSizeStepGranularity="1px"/> diff --git a/apct-tests/perftests/core/res/layout/test_autosize_textview_300.xml b/apct-tests/perftests/core/res/layout/test_autosize_textview_300.xml index d3a4040a3910..54c7e71c9a9a 100644 --- a/apct-tests/perftests/core/res/layout/test_autosize_textview_300.xml +++ b/apct-tests/perftests/core/res/layout/test_autosize_textview_300.xml @@ -19,8 +19,7 @@ android:layout_width="400dp" android:layout_height="600dp" android:text="@string/long_text" - android:textDirection="rtl" - android:autoSizeText="xy" + android:autoSizeText="uniform" android:autoSizeMinTextSize="10px" android:textSize="310px" android:autoSizeStepGranularity="1px"/> diff --git a/apct-tests/perftests/core/res/layout/test_autosize_textview_5.xml b/apct-tests/perftests/core/res/layout/test_autosize_textview_5.xml index c7982e769394..525b2c854c7a 100644 --- a/apct-tests/perftests/core/res/layout/test_autosize_textview_5.xml +++ b/apct-tests/perftests/core/res/layout/test_autosize_textview_5.xml @@ -35,8 +35,7 @@ android:layout_width="400dp" android:layout_height="600dp" android:text="@string/long_text" - android:textDirection="rtl" - android:autoSizeText="xy" + android:autoSizeText="uniform" android:autoSizeMinTextSize="10px" android:textSize="15px" android:autoSizeStepGranularity="1px"/> diff --git a/apct-tests/perftests/core/res/layout/test_autosize_textview_50.xml b/apct-tests/perftests/core/res/layout/test_autosize_textview_50.xml index b00988994836..470c4da1376e 100644 --- a/apct-tests/perftests/core/res/layout/test_autosize_textview_50.xml +++ b/apct-tests/perftests/core/res/layout/test_autosize_textview_50.xml @@ -19,8 +19,7 @@ android:layout_width="400dp" android:layout_height="600dp" android:text="@string/long_text" - android:textDirection="rtl" - android:autoSizeText="xy" + android:autoSizeText="uniform" android:autoSizeMinTextSize="10px" android:textSize="60px" android:autoSizeStepGranularity="1px"/> diff --git a/apct-tests/perftests/core/res/layout/test_autosize_textview_500.xml b/apct-tests/perftests/core/res/layout/test_autosize_textview_500.xml index f59d7511b5d8..b8a6e0af49f0 100644 --- a/apct-tests/perftests/core/res/layout/test_autosize_textview_500.xml +++ b/apct-tests/perftests/core/res/layout/test_autosize_textview_500.xml @@ -19,8 +19,7 @@ android:layout_width="400dp" android:layout_height="600dp" android:text="@string/long_text" - android:textDirection="rtl" - android:autoSizeText="xy" + android:autoSizeText="uniform" android:autoSizeMinTextSize="10px" android:textSize="510px" android:autoSizeStepGranularity="1px"/> diff --git a/api/current.txt b/api/current.txt index 96b96dbdaecd..720687ceb398 100644 --- a/api/current.txt +++ b/api/current.txt @@ -79,6 +79,7 @@ package android { field public static final java.lang.String INSTALL_LOCATION_PROVIDER = "android.permission.INSTALL_LOCATION_PROVIDER"; field public static final java.lang.String INSTALL_PACKAGES = "android.permission.INSTALL_PACKAGES"; field public static final java.lang.String INSTALL_SHORTCUT = "com.android.launcher.permission.INSTALL_SHORTCUT"; + field public static final java.lang.String INSTANT_APP_FOREGROUND_SERVICE = "android.permission.INSTANT_APP_FOREGROUND_SERVICE"; field public static final java.lang.String INTERNET = "android.permission.INTERNET"; field public static final java.lang.String KILL_BACKGROUND_PROCESSES = "android.permission.KILL_BACKGROUND_PROCESSES"; field public static final java.lang.String LOCATION_HARDWARE = "android.permission.LOCATION_HARDWARE"; @@ -299,8 +300,8 @@ package android { field public static final int autoRemoveFromRecents = 16843847; // 0x1010447 field public static final int autoSizeMaxTextSize = 16844103; // 0x1010547 field public static final int autoSizeMinTextSize = 16844088; // 0x1010538 + field public static final int autoSizePresetSizes = 16844087; // 0x1010537 field public static final int autoSizeStepGranularity = 16844086; // 0x1010536 - field public static final int autoSizeStepSizeSet = 16844087; // 0x1010537 field public static final int autoSizeText = 16844085; // 0x1010535 field public static final int autoStart = 16843445; // 0x10102b5 field public static final deprecated int autoText = 16843114; // 0x101016a @@ -5503,6 +5504,7 @@ package android.app { public final class NotificationChannelGroup implements android.os.Parcelable { ctor public NotificationChannelGroup(java.lang.String, java.lang.CharSequence); ctor protected NotificationChannelGroup(android.os.Parcel); + method public android.app.NotificationChannelGroup clone(); method public int describeContents(); method public java.util.List<android.app.NotificationChannel> getChannels(); method public java.lang.String getId(); @@ -50379,7 +50381,7 @@ package android.widget { method public int getAutoSizeMaxTextSize(); method public int getAutoSizeMinTextSize(); method public int getAutoSizeStepGranularity(); - method public int[] getAutoSizeTextPresetSizes(); + method public int[] getAutoSizeTextAvailableSizes(); method public int getAutoSizeTextType(); method public int getBreakStrategy(); method public int getCompoundDrawablePadding(); @@ -50587,7 +50589,7 @@ package android.widget { method public void setTypeface(android.graphics.Typeface); method public void setWidth(int); field public static final int AUTO_SIZE_TEXT_TYPE_NONE = 0; // 0x0 - field public static final int AUTO_SIZE_TEXT_TYPE_XY = 1; // 0x1 + field public static final int AUTO_SIZE_TEXT_TYPE_UNIFORM = 1; // 0x1 } public static final class TextView.BufferType extends java.lang.Enum { diff --git a/api/system-current.txt b/api/system-current.txt index 106564dda953..d20b42faf3cd 100644 --- a/api/system-current.txt +++ b/api/system-current.txt @@ -121,6 +121,7 @@ package android { field public static final java.lang.String INSTALL_LOCATION_PROVIDER = "android.permission.INSTALL_LOCATION_PROVIDER"; field public static final java.lang.String INSTALL_PACKAGES = "android.permission.INSTALL_PACKAGES"; field public static final java.lang.String INSTALL_SHORTCUT = "com.android.launcher.permission.INSTALL_SHORTCUT"; + field public static final java.lang.String INSTANT_APP_FOREGROUND_SERVICE = "android.permission.INSTANT_APP_FOREGROUND_SERVICE"; field public static final java.lang.String INTENT_FILTER_VERIFICATION_AGENT = "android.permission.INTENT_FILTER_VERIFICATION_AGENT"; field public static final java.lang.String INTERACT_ACROSS_USERS = "android.permission.INTERACT_ACROSS_USERS"; field public static final java.lang.String INTERACT_ACROSS_USERS_FULL = "android.permission.INTERACT_ACROSS_USERS_FULL"; @@ -411,8 +412,8 @@ package android { field public static final int autoRemoveFromRecents = 16843847; // 0x1010447 field public static final int autoSizeMaxTextSize = 16844103; // 0x1010547 field public static final int autoSizeMinTextSize = 16844088; // 0x1010538 + field public static final int autoSizePresetSizes = 16844087; // 0x1010537 field public static final int autoSizeStepGranularity = 16844086; // 0x1010536 - field public static final int autoSizeStepSizeSet = 16844087; // 0x1010537 field public static final int autoSizeText = 16844085; // 0x1010535 field public static final int autoStart = 16843445; // 0x10102b5 field public static final deprecated int autoText = 16843114; // 0x101016a @@ -5697,6 +5698,7 @@ package android.app { ctor public NotificationChannelGroup(java.lang.String, java.lang.CharSequence); ctor protected NotificationChannelGroup(android.os.Parcel); method public void addChannel(android.app.NotificationChannel); + method public android.app.NotificationChannelGroup clone(); method public int describeContents(); method public java.util.List<android.app.NotificationChannel> getChannels(); method public java.lang.String getId(); @@ -54180,7 +54182,7 @@ package android.widget { method public int getAutoSizeMaxTextSize(); method public int getAutoSizeMinTextSize(); method public int getAutoSizeStepGranularity(); - method public int[] getAutoSizeTextPresetSizes(); + method public int[] getAutoSizeTextAvailableSizes(); method public int getAutoSizeTextType(); method public int getBreakStrategy(); method public int getCompoundDrawablePadding(); @@ -54388,7 +54390,7 @@ package android.widget { method public void setTypeface(android.graphics.Typeface); method public void setWidth(int); field public static final int AUTO_SIZE_TEXT_TYPE_NONE = 0; // 0x0 - field public static final int AUTO_SIZE_TEXT_TYPE_XY = 1; // 0x1 + field public static final int AUTO_SIZE_TEXT_TYPE_UNIFORM = 1; // 0x1 } public static final class TextView.BufferType extends java.lang.Enum { diff --git a/api/test-current.txt b/api/test-current.txt index 36f5835188b3..0ac7f241ce2f 100644 --- a/api/test-current.txt +++ b/api/test-current.txt @@ -79,6 +79,7 @@ package android { field public static final java.lang.String INSTALL_LOCATION_PROVIDER = "android.permission.INSTALL_LOCATION_PROVIDER"; field public static final java.lang.String INSTALL_PACKAGES = "android.permission.INSTALL_PACKAGES"; field public static final java.lang.String INSTALL_SHORTCUT = "com.android.launcher.permission.INSTALL_SHORTCUT"; + field public static final java.lang.String INSTANT_APP_FOREGROUND_SERVICE = "android.permission.INSTANT_APP_FOREGROUND_SERVICE"; field public static final java.lang.String INTERNET = "android.permission.INTERNET"; field public static final java.lang.String KILL_BACKGROUND_PROCESSES = "android.permission.KILL_BACKGROUND_PROCESSES"; field public static final java.lang.String LOCATION_HARDWARE = "android.permission.LOCATION_HARDWARE"; @@ -299,8 +300,8 @@ package android { field public static final int autoRemoveFromRecents = 16843847; // 0x1010447 field public static final int autoSizeMaxTextSize = 16844103; // 0x1010547 field public static final int autoSizeMinTextSize = 16844088; // 0x1010538 + field public static final int autoSizePresetSizes = 16844087; // 0x1010537 field public static final int autoSizeStepGranularity = 16844086; // 0x1010536 - field public static final int autoSizeStepSizeSet = 16844087; // 0x1010537 field public static final int autoSizeText = 16844085; // 0x1010535 field public static final int autoStart = 16843445; // 0x10102b5 field public static final deprecated int autoText = 16843114; // 0x101016a @@ -5513,6 +5514,7 @@ package android.app { public final class NotificationChannelGroup implements android.os.Parcelable { ctor public NotificationChannelGroup(java.lang.String, java.lang.CharSequence); ctor protected NotificationChannelGroup(android.os.Parcel); + method public android.app.NotificationChannelGroup clone(); method public int describeContents(); method public java.util.List<android.app.NotificationChannel> getChannels(); method public java.lang.String getId(); @@ -50699,7 +50701,7 @@ package android.widget { method public int getAutoSizeMaxTextSize(); method public int getAutoSizeMinTextSize(); method public int getAutoSizeStepGranularity(); - method public int[] getAutoSizeTextPresetSizes(); + method public int[] getAutoSizeTextAvailableSizes(); method public int getAutoSizeTextType(); method public int getBreakStrategy(); method public int getCompoundDrawablePadding(); @@ -50907,7 +50909,7 @@ package android.widget { method public void setTypeface(android.graphics.Typeface); method public void setWidth(int); field public static final int AUTO_SIZE_TEXT_TYPE_NONE = 0; // 0x0 - field public static final int AUTO_SIZE_TEXT_TYPE_XY = 1; // 0x1 + field public static final int AUTO_SIZE_TEXT_TYPE_UNIFORM = 1; // 0x1 } public static final class TextView.BufferType extends java.lang.Enum { diff --git a/core/java/android/app/AppOpsManager.java b/core/java/android/app/AppOpsManager.java index 603126b3badd..fb927e96d1f5 100644 --- a/core/java/android/app/AppOpsManager.java +++ b/core/java/android/app/AppOpsManager.java @@ -247,8 +247,10 @@ public class AppOpsManager { public static final int OP_REQUEST_INSTALL_PACKAGES = 66; /** @hide Enter picture-in-picture when hidden. */ public static final int OP_ENTER_PICTURE_IN_PICTURE_ON_HIDE = 67; + /** @hide Instant app start foreground service. */ + public static final int OP_INSTANT_APP_START_FOREGROUND = 68; /** @hide */ - public static final int _NUM_OP = 68; + public static final int _NUM_OP = 69; /** Access to coarse location information. */ public static final String OPSTR_COARSE_LOCATION = "android:coarse_location"; @@ -351,6 +353,9 @@ public class AppOpsManager { = "android:get_accounts"; public static final String OPSTR_READ_PHONE_NUMBER = "android:read_phone_number"; + /** @hide */ + public static final String OPSTR_INSTANT_APP_START_FOREGROUND + = "android:instant_app_start_foreground"; private static final int[] RUNTIME_PERMISSIONS_OPS = { // Contacts @@ -467,6 +472,7 @@ public class AppOpsManager { OP_READ_PHONE_NUMBER, OP_REQUEST_INSTALL_PACKAGES, OP_ENTER_PICTURE_IN_PICTURE_ON_HIDE, + OP_INSTANT_APP_START_FOREGROUND, }; /** @@ -542,6 +548,7 @@ public class AppOpsManager { OPSTR_READ_PHONE_NUMBER, null, // OP_REQUEST_INSTALL_PACKAGES null, + OPSTR_INSTANT_APP_START_FOREGROUND, }; /** @@ -617,6 +624,7 @@ public class AppOpsManager { "READ_PHONE_NUMBER", "REQUEST_INSTALL_PACKAGES", "OP_ENTER_PICTURE_IN_PICTURE_ON_HIDE", + "INSTANT_APP_START_FOREGROUND", }; /** @@ -692,6 +700,7 @@ public class AppOpsManager { Manifest.permission.READ_PHONE_NUMBER, Manifest.permission.REQUEST_INSTALL_PACKAGES, null, // no permission for entering picture-in-picture on hide + Manifest.permission.INSTANT_APP_FOREGROUND_SERVICE, }; /** @@ -768,6 +777,7 @@ public class AppOpsManager { null, // READ_PHONE_NUMBER null, // REQUEST_INSTALL_PACKAGES null, // ENTER_PICTURE_IN_PICTURE_ON_HIDE + null, // INSTANT_APP_START_FOREGROUND }; /** @@ -843,6 +853,7 @@ public class AppOpsManager { false, // READ_PHONE_NUMBER false, // REQUEST_INSTALL_PACKAGES false, // ENTER_PICTURE_IN_PICTURE_ON_HIDE + false, // INSTANT_APP_START_FOREGROUND }; /** @@ -917,6 +928,7 @@ public class AppOpsManager { AppOpsManager.MODE_ALLOWED, AppOpsManager.MODE_DEFAULT, // OP_REQUEST_INSTALL_PACKAGES AppOpsManager.MODE_ALLOWED, // OP_ENTER_PICTURE_IN_PICTURE_ON_HIDE + AppOpsManager.MODE_DEFAULT, // OP_INSTANT_APP_START_FOREGROUND }; /** @@ -995,6 +1007,7 @@ public class AppOpsManager { false, false, // OP_REQUEST_INSTALL_PACKAGES false, // OP_ENTER_PICTURE_IN_PICTURE_ON_HIDE + false, }; /** diff --git a/core/java/android/hardware/camera2/params/OutputConfiguration.java b/core/java/android/hardware/camera2/params/OutputConfiguration.java index d9512944d7ca..522575f09f4d 100644 --- a/core/java/android/hardware/camera2/params/OutputConfiguration.java +++ b/core/java/android/hardware/camera2/params/OutputConfiguration.java @@ -259,6 +259,10 @@ public final class OutputConfiguration implements Parcelable { throw new IllegalArgumentException("Unknow surface source class type"); } + if (surfaceSize.getWidth() == 0 || surfaceSize.getHeight() == 0) { + throw new IllegalArgumentException("Surface size needs to be non-zero"); + } + mSurfaceGroupId = SURFACE_GROUP_ID_NONE; mSurfaces = new ArrayList<Surface>(); mRotation = ROTATION_0; diff --git a/core/java/android/inputmethodservice/InputMethodService.java b/core/java/android/inputmethodservice/InputMethodService.java index 5996fe2b14a3..5ae1fd057122 100644 --- a/core/java/android/inputmethodservice/InputMethodService.java +++ b/core/java/android/inputmethodservice/InputMethodService.java @@ -387,8 +387,9 @@ public class InputMethodService extends AbstractInputMethodService { mInputConnection = binding.getConnection(); if (DEBUG) Log.v(TAG, "bindInput(): binding=" + binding + " ic=" + mInputConnection); - InputConnection ic = getCurrentInputConnection(); - if (ic != null) ic.reportFullscreenMode(mIsFullscreen); + if (mImm != null && mToken != null) { + mImm.reportFullscreenMode(mToken, mIsFullscreen); + } initialize(); onBindInput(); } @@ -1027,8 +1028,9 @@ public class InputMethodService extends AbstractInputMethodService { if (mIsFullscreen != isFullscreen || !mFullscreenApplied) { changed = true; mIsFullscreen = isFullscreen; - InputConnection ic = getCurrentInputConnection(); - if (ic != null) ic.reportFullscreenMode(isFullscreen); + if (mImm != null && mToken != null) { + mImm.reportFullscreenMode(mToken, mIsFullscreen); + } mFullscreenApplied = true; initialize(); LinearLayout.LayoutParams lp = (LinearLayout.LayoutParams) diff --git a/core/java/android/net/INetworkScoreService.aidl b/core/java/android/net/INetworkScoreService.aidl index 9cc256ec6510..f249daf87626 100644 --- a/core/java/android/net/INetworkScoreService.aidl +++ b/core/java/android/net/INetworkScoreService.aidl @@ -132,5 +132,14 @@ interface INetworkScoreService oneway void requestRecommendationAsync(in RecommendationRequest request, in RemoteCallback remoteCallback); + /** + * Returns metadata about the active scorer or <code>null</code> if there is no active scorer. + */ NetworkScorerAppManager.NetworkScorerAppData getActiveScorer(); + + /** + * Returns the list of available scorer apps. The list will be empty if there are + * no valid scorers. + */ + List<NetworkScorerAppManager.NetworkScorerAppData> getAllValidScorers(); } diff --git a/core/java/android/net/NetworkScoreManager.java b/core/java/android/net/NetworkScoreManager.java index 2875580971ae..8f3af6624996 100644 --- a/core/java/android/net/NetworkScoreManager.java +++ b/core/java/android/net/NetworkScoreManager.java @@ -37,6 +37,7 @@ import com.android.internal.util.Preconditions; import java.lang.annotation.Retention; import java.lang.annotation.RetentionPolicy; +import java.util.List; import java.util.concurrent.CompletableFuture; /** @@ -200,6 +201,20 @@ public class NetworkScoreManager { } /** + * Returns the list of available scorer apps. The list will be empty if there are + * no valid scorers. + * + * @hide + */ + public List<NetworkScorerAppData> getAllValidScorers() { + try { + return mService.getAllValidScorers(); + } catch (RemoteException e) { + throw e.rethrowFromSystemServer(); + } + } + + /** * Update network scores. * * <p>This may be called at any time to re-score active networks. Scores will generally be diff --git a/core/java/android/net/NetworkScorerAppManager.java b/core/java/android/net/NetworkScorerAppManager.java index f3cbb52e500d..a166c7ffffe7 100644 --- a/core/java/android/net/NetworkScorerAppManager.java +++ b/core/java/android/net/NetworkScorerAppManager.java @@ -127,6 +127,14 @@ public class NetworkScorerAppManager { } /** + * Returns the list of available scorer apps. The list will be empty if there are + * no valid scorers. + */ + public List<NetworkScorerAppData> getAllValidScorers() { + return Collections.emptyList(); + } + + /** * @return A {@link NetworkScorerAppData} instance containing information about the * best configured network recommendation provider installed or {@code null} * if none of the configured packages can recommend networks. diff --git a/core/java/android/provider/Settings.java b/core/java/android/provider/Settings.java index 2936dfb59184..8b8edac0199e 100755 --- a/core/java/android/provider/Settings.java +++ b/core/java/android/provider/Settings.java @@ -48,6 +48,7 @@ import android.database.Cursor; import android.database.SQLException; import android.location.LocationManager; import android.net.ConnectivityManager; +import android.net.NetworkScoreManager; import android.net.Uri; import android.net.wifi.WifiManager; import android.os.BatteryManager; @@ -6825,39 +6826,6 @@ public final class Settings { "system_navigation_keys_enabled"; /** - * Whether Downloads folder backup is enabled and should run on the device. - * - * @hide - */ - public static final String DOWNLOADS_BACKUP_ENABLED = "downloads_backup_enabled"; - - /** - * Whether Downloads folder backup should only occur if the device is using a metered - * network. - * - * @hide - */ - public static final String DOWNLOADS_BACKUP_ALLOW_METERED = - "downloads_backup_allow_metered"; - - /** - * Whether Downloads folder backup should only occur if the device is charging. - * - * @hide - */ - public static final String DOWNLOADS_BACKUP_CHARGING_ONLY = - "downloads_backup_charging_only"; - - /** - * How many days of information for the automatic storage manager to retain on the device - * for downloads. - * - * @hide - */ - public static final String AUTOMATIC_STORAGE_MANAGER_DOWNLOADS_DAYS_TO_RETAIN = - "automatic_storage_manager_downloads_days_to_retain"; - - /** * Holds comma separated list of ordering of QS tiles. * @hide */ @@ -8220,6 +8188,19 @@ public final class Settings { "network_recommendations_enabled"; /** + * Which package name to use for network recommendations. If null, network recommendations + * will neither be requested nor accepted. + * + * Use {@link NetworkScoreManager#getActiveScorerPackage()} to read this value and + * {@link NetworkScoreManager#setActiveScorer(String)} to write it. + * + * Type: string - package name + * @hide + */ + public static final String NETWORK_RECOMMENDATIONS_PACKAGE = + "network_recommendations_package"; + + /** * Value to specify if the Wi-Fi Framework should defer to * {@link com.android.server.NetworkScoreService} for evaluating saved open networks. * diff --git a/core/java/android/service/autofill/AutoFillService.java b/core/java/android/service/autofill/AutoFillService.java index ab80aa3e23b8..6da6a398203b 100644 --- a/core/java/android/service/autofill/AutoFillService.java +++ b/core/java/android/service/autofill/AutoFillService.java @@ -172,7 +172,7 @@ public abstract class AutoFillService extends Service { * <p>You should generally do initialization here rather than in {@link #onCreate}. */ public void onConnected() { - + //TODO(b/33197203): is not called anymore, fix it! } /** @@ -221,6 +221,6 @@ public abstract class AutoFillService extends Service { * <p> At this point this service may no longer be an active {@link AutoFillService}. */ public void onDisconnected() { - + //TODO(b/33197203): is not called anymore, fix it! } } diff --git a/core/java/android/view/GestureDetector.java b/core/java/android/view/GestureDetector.java index 27c1dcbe8ece..52e53b074165 100644 --- a/core/java/android/view/GestureDetector.java +++ b/core/java/android/view/GestureDetector.java @@ -502,6 +502,8 @@ public class GestureDetector { final boolean pointerUp = (action & MotionEvent.ACTION_MASK) == MotionEvent.ACTION_POINTER_UP; final int skipIndex = pointerUp ? ev.getActionIndex() : -1; + final boolean isGeneratedGesture = + (ev.getFlags() & MotionEvent.FLAG_IS_GENERATED_GESTURE) != 0; // Determine focal point float sumX = 0, sumY = 0; @@ -604,7 +606,8 @@ public class GestureDetector { final int deltaX = (int) (focusX - mDownFocusX); final int deltaY = (int) (focusY - mDownFocusY); int distance = (deltaX * deltaX) + (deltaY * deltaY); - if (distance > mTouchSlopSquare) { + int slopSquare = isGeneratedGesture ? 0 : mTouchSlopSquare; + if (distance > slopSquare) { handled = mListener.onScroll(mCurrentDownEvent, ev, scrollX, scrollY); mLastFocusX = focusX; mLastFocusY = focusY; @@ -613,7 +616,8 @@ public class GestureDetector { mHandler.removeMessages(SHOW_PRESS); mHandler.removeMessages(LONG_PRESS); } - if (distance > mDoubleTapTouchSlopSquare) { + int doubleTapSlopSquare = isGeneratedGesture ? 0 : mDoubleTapTouchSlopSquare; + if (distance > doubleTapSlopSquare) { mAlwaysInBiggerTapRegion = false; } } else if ((Math.abs(scrollX) >= 1) || (Math.abs(scrollY) >= 1)) { @@ -761,7 +765,10 @@ public class GestureDetector { int deltaX = (int) firstDown.getX() - (int) secondDown.getX(); int deltaY = (int) firstDown.getY() - (int) secondDown.getY(); - return (deltaX * deltaX + deltaY * deltaY < mDoubleTapSlopSquare); + final boolean isGeneratedGesture = + (firstDown.getFlags() & MotionEvent.FLAG_IS_GENERATED_GESTURE) != 0; + int slopSquare = isGeneratedGesture ? 0 : mDoubleTapSlopSquare; + return (deltaX * deltaX + deltaY * deltaY < slopSquare); } private void dispatchLongPress() { diff --git a/core/java/android/view/MotionEvent.java b/core/java/android/view/MotionEvent.java index 2316b3829f37..2129039b1b8c 100644 --- a/core/java/android/view/MotionEvent.java +++ b/core/java/android/view/MotionEvent.java @@ -186,7 +186,7 @@ public final class MotionEvent extends InputEvent implements Parcelable { * Bit mask of the parts of the action code that are the action itself. */ public static final int ACTION_MASK = 0xff; - + /** * Constant for {@link #getActionMasked}: A pressed gesture has started, the * motion contains the initial starting location. @@ -197,14 +197,14 @@ public final class MotionEvent extends InputEvent implements Parcelable { * </p> */ public static final int ACTION_DOWN = 0; - + /** * Constant for {@link #getActionMasked}: A pressed gesture has finished, the * motion contains the final release location as well as any intermediate * points since the last down or move event. */ public static final int ACTION_UP = 1; - + /** * Constant for {@link #getActionMasked}: A change has happened during a * press gesture (between {@link #ACTION_DOWN} and {@link #ACTION_UP}). @@ -212,14 +212,14 @@ public final class MotionEvent extends InputEvent implements Parcelable { * points since the last down or move event. */ public static final int ACTION_MOVE = 2; - + /** * Constant for {@link #getActionMasked}: The current gesture has been aborted. * You will not receive any more points in it. You should treat this as * an up event, but not perform any action that you normally would. */ public static final int ACTION_CANCEL = 3; - + /** * Constant for {@link #getActionMasked}: A movement has happened outside of the * normal bounds of the UI element. This does not provide a full gesture, @@ -237,7 +237,7 @@ public final class MotionEvent extends InputEvent implements Parcelable { * </p> */ public static final int ACTION_POINTER_DOWN = 5; - + /** * Constant for {@link #getActionMasked}: A non-primary pointer has gone up. * <p> @@ -343,7 +343,7 @@ public final class MotionEvent extends InputEvent implements Parcelable { * @see #getActionIndex */ public static final int ACTION_POINTER_INDEX_MASK = 0xff00; - + /** * Bit shift for the action bits holding the pointer index as * defined by {@link #ACTION_POINTER_INDEX_MASK}. @@ -358,56 +358,56 @@ public final class MotionEvent extends InputEvent implements Parcelable { */ @Deprecated public static final int ACTION_POINTER_1_DOWN = ACTION_POINTER_DOWN | 0x0000; - + /** * @deprecated Use {@link #ACTION_POINTER_INDEX_MASK} to retrieve the * data index associated with {@link #ACTION_POINTER_DOWN}. */ @Deprecated public static final int ACTION_POINTER_2_DOWN = ACTION_POINTER_DOWN | 0x0100; - + /** * @deprecated Use {@link #ACTION_POINTER_INDEX_MASK} to retrieve the * data index associated with {@link #ACTION_POINTER_DOWN}. */ @Deprecated public static final int ACTION_POINTER_3_DOWN = ACTION_POINTER_DOWN | 0x0200; - + /** * @deprecated Use {@link #ACTION_POINTER_INDEX_MASK} to retrieve the * data index associated with {@link #ACTION_POINTER_UP}. */ @Deprecated public static final int ACTION_POINTER_1_UP = ACTION_POINTER_UP | 0x0000; - + /** * @deprecated Use {@link #ACTION_POINTER_INDEX_MASK} to retrieve the * data index associated with {@link #ACTION_POINTER_UP}. */ @Deprecated public static final int ACTION_POINTER_2_UP = ACTION_POINTER_UP | 0x0100; - + /** * @deprecated Use {@link #ACTION_POINTER_INDEX_MASK} to retrieve the * data index associated with {@link #ACTION_POINTER_UP}. */ @Deprecated public static final int ACTION_POINTER_3_UP = ACTION_POINTER_UP | 0x0200; - + /** * @deprecated Renamed to {@link #ACTION_POINTER_INDEX_MASK} to match * the actual data contained in these bits. */ @Deprecated public static final int ACTION_POINTER_ID_MASK = 0xff00; - + /** * @deprecated Renamed to {@link #ACTION_POINTER_INDEX_SHIFT} to match * the actual data contained in these bits. */ @Deprecated public static final int ACTION_POINTER_ID_SHIFT = 8; - + /** * This flag indicates that the window that received this motion event is partly * or wholly obscured by another visible window above it. This flag is set to true @@ -444,6 +444,14 @@ public final class MotionEvent extends InputEvent implements Parcelable { public static final int FLAG_HOVER_EXIT_PENDING = 0x4; /** + * This flag indicates that the event has been generated by a gesture generator. It + * provides a hint to the GestureDector to not apply any touch slop. + * + * @hide + */ + public static final int FLAG_IS_GENERATED_GESTURE = 0x8; + + /** * Private flag that indicates when the system has detected that this motion event * may be inconsistent with respect to the sequence of previously delivered motion events, * such as when a pointer move event is sent but the pointer is not down. @@ -1582,9 +1590,9 @@ public final class MotionEvent extends InputEvent implements Parcelable { * Create a new MotionEvent, filling in all of the basic values that * define the motion. * - * @param downTime The time (in ms) when the user originally pressed down to start + * @param downTime The time (in ms) when the user originally pressed down to start * a stream of position events. This must be obtained from {@link SystemClock#uptimeMillis()}. - * @param eventTime The the time (in ms) when this specific event was generated. This + * @param eventTime The the time (in ms) when this specific event was generated. This * must be obtained from {@link SystemClock#uptimeMillis()}. * @param action The kind of action being performed, such as {@link #ACTION_DOWN}. * @param pointerCount The number of pointers that will be in this event. @@ -1623,7 +1631,7 @@ public final class MotionEvent extends InputEvent implements Parcelable { /** * Create a new MotionEvent, filling in all of the basic values that * define the motion. - * + * * @param downTime The time (in ms) when the user originally pressed down to start * a stream of position events. This must be obtained from {@link SystemClock#uptimeMillis()}. * @param eventTime The the time (in ms) when this specific event was generated. This @@ -1751,7 +1759,7 @@ public final class MotionEvent extends InputEvent implements Parcelable { * numbers are arbitrary and you shouldn't depend on the values. * @param edgeFlags A bitfield indicating which edges, if any, were touched by this * MotionEvent. - * + * * @deprecated Use {@link #obtain(long, long, int, float, float, float, float, int, float, float, int, int)} * instead. */ @@ -2057,7 +2065,7 @@ public final class MotionEvent extends InputEvent implements Parcelable { public final float getSize() { return nativeGetAxisValue(mNativePtr, AXIS_SIZE, 0, HISTORY_CURRENT); } - + /** * {@link #getTouchMajor(int)} for the first pointer index (may be an * arbitrary pointer identifier). @@ -2077,7 +2085,7 @@ public final class MotionEvent extends InputEvent implements Parcelable { public final float getTouchMinor() { return nativeGetAxisValue(mNativePtr, AXIS_TOUCH_MINOR, 0, HISTORY_CURRENT); } - + /** * {@link #getToolMajor(int)} for the first pointer index (may be an * arbitrary pointer identifier). @@ -2161,7 +2169,7 @@ public final class MotionEvent extends InputEvent implements Parcelable { /** * Given a pointer identifier, find the index of its data in the event. - * + * * @param pointerId The identifier of the pointer to be found. * @return Returns either the index of the pointer (for use with * {@link #getX(int)} et al.), or -1 if there is no data available for @@ -2175,8 +2183,8 @@ public final class MotionEvent extends InputEvent implements Parcelable { * Returns the X coordinate of this event for the given pointer * <em>index</em> (use {@link #getPointerId(int)} to find the pointer * identifier for this index). - * Whole numbers are pixels; the - * value may have a fraction for input devices that are sub-pixel precise. + * Whole numbers are pixels; the + * value may have a fraction for input devices that are sub-pixel precise. * @param pointerIndex Raw index of pointer to retrieve. Value may be from 0 * (the first pointer that is down) to {@link #getPointerCount()}-1. * @@ -2235,7 +2243,7 @@ public final class MotionEvent extends InputEvent implements Parcelable { public final float getSize(int pointerIndex) { return nativeGetAxisValue(mNativePtr, AXIS_SIZE, pointerIndex, HISTORY_CURRENT); } - + /** * Returns the length of the major axis of an ellipse that describes the touch * area at the point of contact for the given pointer @@ -2249,7 +2257,7 @@ public final class MotionEvent extends InputEvent implements Parcelable { public final float getTouchMajor(int pointerIndex) { return nativeGetAxisValue(mNativePtr, AXIS_TOUCH_MAJOR, pointerIndex, HISTORY_CURRENT); } - + /** * Returns the length of the minor axis of an ellipse that describes the touch * area at the point of contact for the given pointer @@ -2263,7 +2271,7 @@ public final class MotionEvent extends InputEvent implements Parcelable { public final float getTouchMinor(int pointerIndex) { return nativeGetAxisValue(mNativePtr, AXIS_TOUCH_MINOR, pointerIndex, HISTORY_CURRENT); } - + /** * Returns the length of the major axis of an ellipse that describes the size of * the approaching tool for the given pointer @@ -2279,7 +2287,7 @@ public final class MotionEvent extends InputEvent implements Parcelable { public final float getToolMajor(int pointerIndex) { return nativeGetAxisValue(mNativePtr, AXIS_TOOL_MAJOR, pointerIndex, HISTORY_CURRENT); } - + /** * Returns the length of the minor axis of an ellipse that describes the size of * the approaching tool for the given pointer @@ -2295,7 +2303,7 @@ public final class MotionEvent extends InputEvent implements Parcelable { public final float getToolMinor(int pointerIndex) { return nativeGetAxisValue(mNativePtr, AXIS_TOOL_MINOR, pointerIndex, HISTORY_CURRENT); } - + /** * Returns the orientation of the touch area and tool area in radians clockwise from vertical * for the given pointer <em>index</em> (use {@link #getPointerId(int)} to find the pointer @@ -2334,7 +2342,7 @@ public final class MotionEvent extends InputEvent implements Parcelable { /** * Populates a {@link PointerCoords} object with pointer coordinate data for * the specified pointer index. - * + * * @param pointerIndex Raw index of pointer to retrieve. Value may be from 0 * (the first pointer that is down) to {@link #getPointerCount()}-1. * @param outPointerCoords The pointer coordinate object to populate. @@ -2622,7 +2630,7 @@ public final class MotionEvent extends InputEvent implements Parcelable { public final float getHistoricalTouchMinor(int pos) { return nativeGetAxisValue(mNativePtr, AXIS_TOUCH_MINOR, 0, pos); } - + /** * {@link #getHistoricalToolMajor(int, int)} for the first pointer index (may be an * arbitrary pointer identifier). @@ -2652,7 +2660,7 @@ public final class MotionEvent extends InputEvent implements Parcelable { public final float getHistoricalToolMinor(int pos) { return nativeGetAxisValue(mNativePtr, AXIS_TOOL_MINOR, 0, pos); } - + /** * {@link #getHistoricalOrientation(int, int)} for the first pointer index (may be an * arbitrary pointer identifier). @@ -2730,7 +2738,7 @@ public final class MotionEvent extends InputEvent implements Parcelable { * (the first pointer that is down) to {@link #getPointerCount()}-1. * @param pos Which historical value to return; must be less than * {@link #getHistorySize} - * + * * @see #getHistorySize * @see #getPressure(int) * @see #AXIS_PRESSURE @@ -2748,7 +2756,7 @@ public final class MotionEvent extends InputEvent implements Parcelable { * (the first pointer that is down) to {@link #getPointerCount()}-1. * @param pos Which historical value to return; must be less than * {@link #getHistorySize} - * + * * @see #getHistorySize * @see #getSize(int) * @see #AXIS_SIZE @@ -2756,7 +2764,7 @@ public final class MotionEvent extends InputEvent implements Parcelable { public final float getHistoricalSize(int pointerIndex, int pos) { return nativeGetAxisValue(mNativePtr, AXIS_SIZE, pointerIndex, pos); } - + /** * Returns a historical touch major axis coordinate, as per {@link #getTouchMajor(int)}, that * occurred between this event and the previous event for the given pointer. @@ -2766,7 +2774,7 @@ public final class MotionEvent extends InputEvent implements Parcelable { * (the first pointer that is down) to {@link #getPointerCount()}-1. * @param pos Which historical value to return; must be less than * {@link #getHistorySize} - * + * * @see #getHistorySize * @see #getTouchMajor(int) * @see #AXIS_TOUCH_MAJOR @@ -2784,7 +2792,7 @@ public final class MotionEvent extends InputEvent implements Parcelable { * (the first pointer that is down) to {@link #getPointerCount()}-1. * @param pos Which historical value to return; must be less than * {@link #getHistorySize} - * + * * @see #getHistorySize * @see #getTouchMinor(int) * @see #AXIS_TOUCH_MINOR @@ -2802,7 +2810,7 @@ public final class MotionEvent extends InputEvent implements Parcelable { * (the first pointer that is down) to {@link #getPointerCount()}-1. * @param pos Which historical value to return; must be less than * {@link #getHistorySize} - * + * * @see #getHistorySize * @see #getToolMajor(int) * @see #AXIS_TOOL_MAJOR @@ -2820,7 +2828,7 @@ public final class MotionEvent extends InputEvent implements Parcelable { * (the first pointer that is down) to {@link #getPointerCount()}-1. * @param pos Which historical value to return; must be less than * {@link #getHistorySize} - * + * * @see #getHistorySize * @see #getToolMinor(int) * @see #AXIS_TOOL_MINOR @@ -2838,7 +2846,7 @@ public final class MotionEvent extends InputEvent implements Parcelable { * (the first pointer that is down) to {@link #getPointerCount()}-1. * @param pos Which historical value to return; must be less than * {@link #getHistorySize} - * + * * @see #getHistorySize * @see #getOrientation(int) * @see #AXIS_ORIENTATION @@ -2871,13 +2879,13 @@ public final class MotionEvent extends InputEvent implements Parcelable { * as per {@link #getPointerCoords}, that occurred between this event and the previous * event for the given pointer. * Only applies to ACTION_MOVE events. - * + * * @param pointerIndex Raw index of pointer to retrieve. Value may be from 0 * (the first pointer that is down) to {@link #getPointerCount()}-1. * @param pos Which historical value to return; must be less than * {@link #getHistorySize} * @param outPointerCoords The pointer coordinate object to populate. - * + * * @see #getHistorySize * @see #getPointerCoords * @see PointerCoords @@ -2886,7 +2894,7 @@ public final class MotionEvent extends InputEvent implements Parcelable { PointerCoords outPointerCoords) { nativeGetPointerCoords(mNativePtr, pointerIndex, pos, outPointerCoords); } - + /** * Returns a bitfield indicating which edges, if any, were touched by this * MotionEvent. For touch events, clients can use this to determine if the @@ -2943,7 +2951,7 @@ public final class MotionEvent extends InputEvent implements Parcelable { float oldY = getY(); offsetLocation(x - oldX, y - oldY); } - + /** * Applies a transformation matrix to all of the points in the event. * @@ -3427,11 +3435,11 @@ public final class MotionEvent extends InputEvent implements Parcelable { /** * Transfer object for pointer coordinates. - * + * * Objects of this type can be used to specify the pointer coordinates when * creating new {@link MotionEvent} objects and to query pointer coordinates * in bulk. - * + * * Refer to {@link InputDevice} for information about how different kinds of * input devices and sources represent pointer coordinates. */ @@ -3471,14 +3479,14 @@ public final class MotionEvent extends InputEvent implements Parcelable { * @see MotionEvent#AXIS_X */ public float x; - + /** * The Y component of the pointer movement. * * @see MotionEvent#AXIS_Y */ public float y; - + /** * A normalized value that describes the pressure applied to the device * by a finger or other tool. @@ -3489,7 +3497,7 @@ public final class MotionEvent extends InputEvent implements Parcelable { * @see MotionEvent#AXIS_PRESSURE */ public float pressure; - + /** * A normalized value that describes the approximate size of the pointer touch area * in relation to the maximum detectable size of the device. @@ -3502,7 +3510,7 @@ public final class MotionEvent extends InputEvent implements Parcelable { * @see MotionEvent#AXIS_SIZE */ public float size; - + /** * The length of the major axis of an ellipse that describes the touch area at * the point of contact. @@ -3512,7 +3520,7 @@ public final class MotionEvent extends InputEvent implements Parcelable { * @see MotionEvent#AXIS_TOUCH_MAJOR */ public float touchMajor; - + /** * The length of the minor axis of an ellipse that describes the touch area at * the point of contact. @@ -3522,7 +3530,7 @@ public final class MotionEvent extends InputEvent implements Parcelable { * @see MotionEvent#AXIS_TOUCH_MINOR */ public float touchMinor; - + /** * The length of the major axis of an ellipse that describes the size of * the approaching tool. @@ -3534,7 +3542,7 @@ public final class MotionEvent extends InputEvent implements Parcelable { * @see MotionEvent#AXIS_TOOL_MAJOR */ public float toolMajor; - + /** * The length of the minor axis of an ellipse that describes the size of * the approaching tool. @@ -3546,7 +3554,7 @@ public final class MotionEvent extends InputEvent implements Parcelable { * @see MotionEvent#AXIS_TOOL_MINOR */ public float toolMinor; - + /** * The orientation of the touch area and tool area in radians clockwise from vertical. * An angle of 0 radians indicates that the major axis of contact is oriented diff --git a/core/java/android/view/autofill/AutoFillId.java b/core/java/android/view/autofill/AutoFillId.java index 3dbf5a8b0415..38dc404ed6d3 100644 --- a/core/java/android/view/autofill/AutoFillId.java +++ b/core/java/android/view/autofill/AutoFillId.java @@ -93,11 +93,11 @@ public final class AutoFillId implements Parcelable { public String toString() { if (!DEBUG) return super.toString(); - final StringBuilder builder = new StringBuilder("FieldId [viewId=").append(mViewId); + final StringBuilder builder = new StringBuilder().append(mViewId); if (mVirtual) { - builder.append(", virtualId=").append(mVirtualId); + builder.append(":").append(mVirtualId); } - return builder.append(']').toString(); + return builder.toString(); } @Override diff --git a/core/java/android/view/autofill/AutoFillValue.java b/core/java/android/view/autofill/AutoFillValue.java index b31f4aff2b1c..af7036130cd8 100644 --- a/core/java/android/view/autofill/AutoFillValue.java +++ b/core/java/android/view/autofill/AutoFillValue.java @@ -104,8 +104,11 @@ public final class AutoFillValue implements Parcelable { public String toString() { if (!DEBUG) return super.toString(); - return "AutoFillValue[text=" + mText + ", listIndex=" + mListIndex + ", toggle=" + mToggle - + "]"; + if (mText != null) { + return mText.length() + "_chars"; + } + + return "[listIndex=" + mListIndex + ", toggle=" + mToggle + "]"; } ///////////////////////////////////// diff --git a/core/java/android/view/autofill/Helper.java b/core/java/android/view/autofill/Helper.java index a9844d7f0b47..b1c9efad6dc6 100644 --- a/core/java/android/view/autofill/Helper.java +++ b/core/java/android/view/autofill/Helper.java @@ -32,7 +32,7 @@ public final class Helper { static StringBuilder append(StringBuilder builder, Bundle bundle) { if (bundle == null) { builder.append("N/A"); - } else if (!DEBUG) { + } else if (!VERBOSE) { builder.append(REDACTED); } else { final Set<String> keySet = bundle.keySet(); diff --git a/core/java/android/view/inputmethod/InputConnection.java b/core/java/android/view/inputmethod/InputConnection.java index 71c1d624976b..57f9895f45fa 100644 --- a/core/java/android/view/inputmethod/InputConnection.java +++ b/core/java/android/view/inputmethod/InputConnection.java @@ -18,6 +18,7 @@ package android.view.inputmethod; import android.annotation.NonNull; import android.annotation.Nullable; +import android.inputmethodservice.InputMethodService; import android.os.Bundle; import android.os.Handler; import android.view.KeyCharacterMap; @@ -751,13 +752,19 @@ public interface InputConnection { public boolean clearMetaKeyStates(int states); /** - * Called by the IME to tell the client when it switches between - * fullscreen and normal modes. This will normally be called for - * you by the standard implementation of - * {@link android.inputmethodservice.InputMethodService}. - * - * @return true on success, false if the input connection is no longer - * valid. + * Called back when the connected IME switches between fullscreen and normal modes. + * + * <p>Note: On {@link android.os.Build.VERSION_CODES#O} and later devices, input methods are no + * longer allowed to directly call this method at any time. To signal this event in the target + * application, input methods should always call + * {@link InputMethodService#updateFullscreenMode()} instead. This approach should work on API + * {@link android.os.Build.VERSION_CODES#N_MR1} and prior devices.</p> + * + * @return For editor authors, the return value will always be ignored. For IME authors, this + * always returns {@code true} on {@link android.os.Build.VERSION_CODES#N_MR1} and prior + * devices and {@code false} on {@link android.os.Build.VERSION_CODES#O} and later + * devices. + * @see InputMethodManager#isFullscreenMode() */ public boolean reportFullscreenMode(boolean enabled); diff --git a/core/java/android/view/inputmethod/InputMethodManager.java b/core/java/android/view/inputmethod/InputMethodManager.java index 2e99092006f0..13abe7c6471d 100644 --- a/core/java/android/view/inputmethod/InputMethodManager.java +++ b/core/java/android/view/inputmethod/InputMethodManager.java @@ -34,7 +34,6 @@ import android.os.ResultReceiver; import android.os.ServiceManager; import android.os.ServiceManager.ServiceNotFoundException; import android.os.Trace; -import android.text.TextUtils; import android.text.style.SuggestionSpan; import android.util.Log; import android.util.Pools.Pool; @@ -396,6 +395,7 @@ public final class InputMethodManager { static final int MSG_TIMEOUT_INPUT_EVENT = 6; static final int MSG_FLUSH_INPUT_EVENT = 7; static final int MSG_SET_USER_ACTION_NOTIFICATION_SEQUENCE_NUMBER = 9; + static final int MSG_REPORT_FULLSCREEN_MODE = 10; class H extends Handler { H(Looper looper) { @@ -476,12 +476,13 @@ public final class InputMethodManager { } case MSG_SET_ACTIVE: { final boolean active = msg.arg1 != 0; + final boolean fullscreen = msg.arg2 != 0; if (DEBUG) { Log.i(TAG, "handleMessage: MSG_SET_ACTIVE " + active + ", was " + mActive); } synchronized (mH) { mActive = active; - mFullscreenMode = false; + mFullscreenMode = fullscreen; if (!active) { // Some other client has starting using the IME, so note // that this happened and make sure our own editor's @@ -523,6 +524,21 @@ public final class InputMethodManager { synchronized (mH) { mNextUserActionNotificationSequenceNumber = msg.arg1; } + return; + } + case MSG_REPORT_FULLSCREEN_MODE: { + final boolean fullscreen = msg.arg1 != 0; + InputConnection ic = null; + synchronized (mH) { + mFullscreenMode = fullscreen; + if (mServedInputConnectionWrapper != null) { + ic = mServedInputConnectionWrapper.getInputConnection(); + } + } + if (ic != null) { + ic.reportFullscreenMode(fullscreen); + } + return; } } } @@ -557,18 +573,11 @@ public final class InputMethodManager { } @Override - protected void onReportFullscreenMode(boolean enabled, boolean calledInBackground) { - mParentInputMethodManager.onReportFullscreenMode(enabled, calledInBackground, - getInputMethodId()); - } - - @Override public String toString() { return "ControlledInputConnectionWrapper{" + "connection=" + getInputConnection() + " finished=" + isFinished() + " mParentInputMethodManager.mActive=" + mParentInputMethodManager.mActive - + " mInputMethodId=" + getInputMethodId() + "}"; } } @@ -600,24 +609,31 @@ public final class InputMethodManager { @Override public void onBindMethod(InputBindResult res) { - mH.sendMessage(mH.obtainMessage(MSG_BIND, res)); + mH.obtainMessage(MSG_BIND, res).sendToTarget(); } @Override public void onUnbindMethod(int sequence, @InputMethodClient.UnbindReason int unbindReason) { - mH.sendMessage(mH.obtainMessage(MSG_UNBIND, sequence, unbindReason)); + mH.obtainMessage(MSG_UNBIND, sequence, unbindReason).sendToTarget(); } @Override - public void setActive(boolean active) { - mH.sendMessage(mH.obtainMessage(MSG_SET_ACTIVE, active ? 1 : 0, 0)); + public void setActive(boolean active, boolean fullscreen) { + mH.obtainMessage(MSG_SET_ACTIVE, active ? 1 : 0, fullscreen ? 1 : 0).sendToTarget(); } @Override public void setUserActionNotificationSequenceNumber(int sequenceNumber) { - mH.sendMessage(mH.obtainMessage(MSG_SET_USER_ACTION_NOTIFICATION_SEQUENCE_NUMBER, - sequenceNumber, 0)); + mH.obtainMessage(MSG_SET_USER_ACTION_NOTIFICATION_SEQUENCE_NUMBER, sequenceNumber, 0) + .sendToTarget(); + } + + @Override + public void reportFullscreenMode(boolean fullscreen) { + mH.obtainMessage(MSG_REPORT_FULLSCREEN_MODE, fullscreen ? 1 : 0, 0) + .sendToTarget(); } + }; final InputConnection mDummyInputConnection = new BaseInputConnection(this, false); @@ -731,16 +747,6 @@ public final class InputMethodManager { } /** @hide */ - public void onReportFullscreenMode(boolean fullScreen, boolean calledInBackground, - String inputMethodId) { - synchronized (mH) { - if (!calledInBackground || TextUtils.equals(mCurId, inputMethodId)) { - mFullscreenMode = fullScreen; - } - } - } - - /** @hide */ public void registerSuggestionSpansForNotification(SuggestionSpan[] spans) { try { mService.registerSuggestionSpansForNotification(spans); @@ -770,6 +776,17 @@ public final class InputMethodManager { } /** + * @hide + */ + public void reportFullscreenMode(IBinder token, boolean fullscreen) { + try { + mService.reportFullscreenMode(token, fullscreen); + } catch (RemoteException e) { + throw e.rethrowFromSystemServer(); + } + } + + /** * Return true if the given view is the currently active view for the * input method. */ @@ -1274,9 +1291,6 @@ public final class InputMethodManager { mCurId = res.id; mNextUserActionNotificationSequenceNumber = res.userActionNotificationSequenceNumber; - if (mServedInputConnectionWrapper != null) { - mServedInputConnectionWrapper.setInputMethodId(mCurId); - } } else { if (res.channel != null && res.channel != mCurChannel) { res.channel.dispose(); @@ -2341,6 +2355,7 @@ public final class InputMethodManager { + " mHasBeenInactive=" + mHasBeenInactive + " mBindSequence=" + mBindSequence + " mCurId=" + mCurId); + p.println(" mFullscreenMode=" + mFullscreenMode); p.println(" mCurMethod=" + mCurMethod); p.println(" mCurRootView=" + mCurRootView); p.println(" mServedView=" + mServedView); diff --git a/core/java/android/widget/TextView.java b/core/java/android/widget/TextView.java index 20e325cb6d9e..17cd446c3d60 100644 --- a/core/java/android/widget/TextView.java +++ b/core/java/android/widget/TextView.java @@ -271,7 +271,7 @@ import java.util.Locale; * @attr ref android.R.styleable#TextView_autoSizeMinTextSize * @attr ref android.R.styleable#TextView_autoSizeMaxTextSize * @attr ref android.R.styleable#TextView_autoSizeStepGranularity - * @attr ref android.R.styleable#TextView_autoSizeStepSizeSet + * @attr ref android.R.styleable#TextView_autoSizePresetSizes */ @RemoteView public class TextView extends View implements ViewTreeObserver.OnPreDrawListener { @@ -698,9 +698,9 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener public static final int AUTO_SIZE_TEXT_TYPE_NONE = 0; // The TextView performs uniform horizontal and vertical text size scaling to fit within the // container. - public static final int AUTO_SIZE_TEXT_TYPE_XY = 1; + public static final int AUTO_SIZE_TEXT_TYPE_UNIFORM = 1; /** @hide */ - @IntDef({AUTO_SIZE_TEXT_TYPE_NONE, AUTO_SIZE_TEXT_TYPE_XY}) + @IntDef({AUTO_SIZE_TEXT_TYPE_NONE, AUTO_SIZE_TEXT_TYPE_UNIFORM}) @Retention(RetentionPolicy.SOURCE) public @interface AutoSizeTextType {} // Default minimum size for auto-sizing text in scaled pixels. {@see #setAutoSizeMinTextSize}. @@ -725,7 +725,7 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener // Specifies whether auto-size should use the provided auto size steps set or if it should // build the steps set using mAutoSizeMinTextSizeInPx, mAutoSizeMaxTextSizeInPx and // mAutoSizeStepGranularityInPx. - private boolean mHasPredefinedAutoSizeSet = false; + private boolean mHasPresetAutoSizeValues = false; // Watcher used to notify changes to auto-fill manager. private AutoFillChangeWatcher mAutoFillChangeWatcher; @@ -1318,12 +1318,12 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener mAutoSizeMaxTextSizeInPx = a.getDimensionPixelSize(attr, 0); break; - case com.android.internal.R.styleable.TextView_autoSizeStepSizeSet: + case com.android.internal.R.styleable.TextView_autoSizePresetSizes: final int autoSizeStepSizeArrayResId = a.getResourceId(attr, 0); if (autoSizeStepSizeArrayResId > 0) { final TypedArray autoSizePreDefTextSizes = a.getResources() .obtainTypedArray(autoSizeStepSizeArrayResId); - setupAutoSizeStepSizeSet(autoSizePreDefTextSizes); + setupAutoSizePresetSizes(autoSizePreDefTextSizes); autoSizePreDefTextSizes.recycle(); } break; @@ -1601,7 +1601,7 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener setImportantForAccessibility(IMPORTANT_FOR_ACCESSIBILITY_YES); } - setupAutoSizeTextXY(); + setupAutoSizeText(); } /** @@ -1610,7 +1610,7 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener * * @param autoSizeTextType the type of auto-size. Must be one of * {@link TextView#AUTO_SIZE_TEXT_TYPE_NONE} or - * {@link TextView#AUTO_SIZE_TEXT_TYPE_XY} + * {@link TextView#AUTO_SIZE_TEXT_TYPE_UNIFORM} * * @attr ref android.R.styleable#TextView_autoSizeText * @@ -1630,10 +1630,10 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener mNeedsAutoSizeText = false; } break; - case AUTO_SIZE_TEXT_TYPE_XY: - if (mAutoSizeTextType != AUTO_SIZE_TEXT_TYPE_XY) { - mAutoSizeTextType = AUTO_SIZE_TEXT_TYPE_XY; - setupAutoSizeTextXY(); + case AUTO_SIZE_TEXT_TYPE_UNIFORM: + if (mAutoSizeTextType != AUTO_SIZE_TEXT_TYPE_UNIFORM) { + mAutoSizeTextType = AUTO_SIZE_TEXT_TYPE_UNIFORM; + setupAutoSizeText(); } break; default: @@ -1648,7 +1648,7 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener * * @return an {@code int} corresponding to one of the auto-size types: * {@link TextView#AUTO_SIZE_TEXT_TYPE_NONE} or - * {@link TextView#AUTO_SIZE_TEXT_TYPE_XY} + * {@link TextView#AUTO_SIZE_TEXT_TYPE_UNIFORM} * * @attr ref android.R.styleable#TextView_autoSizeText * @@ -1678,8 +1678,8 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener if (supportsAutoSizeText()) { mAutoSizeStepGranularityInPx = (int) TypedValue.applyDimension( unit, size, getResources().getDisplayMetrics()); - mHasPredefinedAutoSizeSet = false; - setupAutoSizeTextXY(); + mHasPresetAutoSizeValues = false; + setupAutoSizeText(); } } @@ -1711,8 +1711,8 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener if (supportsAutoSizeText()) { mAutoSizeMinTextSizeInPx = (int) TypedValue.applyDimension( unit, size, getResources().getDisplayMetrics()); - mHasPredefinedAutoSizeSet = false; - setupAutoSizeTextXY(); + mHasPresetAutoSizeValues = false; + setupAutoSizeText(); } } @@ -1745,8 +1745,8 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener if (supportsAutoSizeText()) { mAutoSizeMaxTextSizeInPx = (int) TypedValue.applyDimension( unit, size, getResources().getDisplayMetrics()); - mHasPredefinedAutoSizeSet = false; - setupAutoSizeTextXY(); + mHasPresetAutoSizeValues = false; + setupAutoSizeText(); } } @@ -1774,25 +1774,25 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener * * @param presetSizes an {@code int} array of sizes in pixels * - * @attr ref android.R.styleable#TextView_autoSizeStepSizeSet + * @attr ref android.R.styleable#TextView_autoSizePresetSizes * - * @see #getAutoSizeTextPresetSizes() + * @see #getAutoSizeTextAvailableSizes() */ public void setAutoSizeTextPresetSizes(@NonNull int[] presetSizes) { if (supportsAutoSizeText()) { if (presetSizes.length > 0) { - mAutoSizeTextSizesInPx = cleanupAutoSizePredefinedSizes(presetSizes); + mAutoSizeTextSizesInPx = cleanupAutoSizePresetSizes(presetSizes); final int sizesLength = mAutoSizeTextSizesInPx.length; - mHasPredefinedAutoSizeSet = sizesLength > 0; - if (mHasPredefinedAutoSizeSet) { + mHasPresetAutoSizeValues = sizesLength > 0; + if (mHasPresetAutoSizeValues) { mAutoSizeMinTextSizeInPx = mAutoSizeTextSizesInPx[0]; mAutoSizeMaxTextSizeInPx = mAutoSizeTextSizesInPx[sizesLength - 1]; mAutoSizeStepGranularityInPx = 0; } } else { - mHasPredefinedAutoSizeSet = false; + mHasPresetAutoSizeValues = false; } - setupAutoSizeTextXY(); + setupAutoSizeText(); } } @@ -1804,11 +1804,11 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener * @see #setAutoSizeMaxTextSize(int, float) * @see #setAutoSizeStepGranularity(int, float) */ - public int[] getAutoSizeTextPresetSizes() { + public int[] getAutoSizeTextAvailableSizes() { return mAutoSizeTextSizesInPx; } - private void setupAutoSizeStepSizeSet(TypedArray textSizes) { + private void setupAutoSizePresetSizes(TypedArray textSizes) { final int textSizesLength = textSizes.length(); final int[] parsedSizes = new int[textSizesLength]; @@ -1816,39 +1816,39 @@ public class TextView extends View implements ViewTreeObserver.OnPreDrawListener for (int i = 0; i < textSizesLength; i++) { parsedSizes[i] = textSizes.getDimensionPixelSize(i, -1); } - mAutoSizeTextSizesInPx = cleanupAutoSizePredefinedSizes(parsedSizes); - mHasPredefinedAutoSizeSet = mAutoSizeTextSizesInPx.length > 0; + mAutoSizeTextSizesInPx = cleanupAutoSizePresetSizes(parsedSizes); + mHasPresetAutoSizeValues = mAutoSizeTextSizesInPx.length > 0; } } // Returns distinct sorted positive values. - private int[] cleanupAutoSizePredefinedSizes(int[] predefinedValues) { - final int predefinedValuesLength = predefinedValues.length; - if (predefinedValuesLength == 0) { - return predefinedValues; + private int[] cleanupAutoSizePresetSizes(int[] presetValues) { + final int presetValuesLength = presetValues.length; + if (presetValuesLength == 0) { + return presetValues; } - Arrays.sort(predefinedValues); + Arrays.sort(presetValues); final IntArray uniqueValidSizes = new IntArray(); - for (int i = 0; i < predefinedValuesLength; i++) { - final int currentPredefinedValue = predefinedValues[i]; + for (int i = 0; i < presetValuesLength; i++) { + final int currentPresetValue = presetValues[i]; - if (currentPredefinedValue > 0 - && uniqueValidSizes.binarySearch(currentPredefinedValue) < 0) { - uniqueValidSizes.add(currentPredefinedValue); + if (currentPresetValue > 0 + && uniqueValidSizes.binarySearch(currentPresetValue) < 0) { + uniqueValidSizes.add(currentPresetValue); } } - return predefinedValuesLength == uniqueValidSizes.size() - ? predefinedValues + return presetValuesLength == uniqueValidSizes.size() + ? presetValues : uniqueValidSizes.toArray(); } - private void setupAutoSizeTextXY() { - if (supportsAutoSizeText() && mAutoSizeTextType == AUTO_SIZE_TEXT_TYPE_XY) { + private void setupAutoSizeText() { + if (supportsAutoSizeText() && mAutoSizeTextType == AUTO_SIZE_TEXT_TYPE_UNIFORM) { // Calculate the sizes set based on minimum size, maximum size and step size if we do // not have a predefined set of sizes or if the current sizes array is empty. - if (!mHasPredefinedAutoSizeSet || mAutoSizeTextSizesInPx.length == 0) { + if (!mHasPresetAutoSizeValues || mAutoSizeTextSizesInPx.length == 0) { // Set valid defaults. if (mAutoSizeMinTextSizeInPx <= 0) { mAutoSizeMinTextSizeInPx = (int) TypedValue.applyDimension( diff --git a/core/java/com/android/internal/os/RuntimeInit.java b/core/java/com/android/internal/os/RuntimeInit.java index 304c31d54776..f4be1289eb70 100644 --- a/core/java/com/android/internal/os/RuntimeInit.java +++ b/core/java/com/android/internal/os/RuntimeInit.java @@ -43,8 +43,8 @@ import org.apache.harmony.luni.internal.util.TimezoneGetter; * @hide */ public class RuntimeInit { - private final static String TAG = "AndroidRuntime"; - private final static boolean DEBUG = false; + final static String TAG = "AndroidRuntime"; + final static boolean DEBUG = false; /** true if commonInit() has been called */ private static boolean initialized; @@ -53,7 +53,6 @@ public class RuntimeInit { private static volatile boolean mCrashing = false; - private static final native void nativeZygoteInit(); private static final native void nativeFinishInit(); private static final native void nativeSetExitWithoutCleanup(boolean exitWithoutCleanup); @@ -133,7 +132,7 @@ public class RuntimeInit { } } - private static final void commonInit() { + protected static final void commonInit() { if (DEBUG) Slog.d(TAG, "Entered RuntimeInit!"); /* @@ -287,50 +286,7 @@ public class RuntimeInit { if (DEBUG) Slog.d(TAG, "Leaving RuntimeInit!"); } - /** - * The main function called when started through the zygote process. This - * could be unified with main(), if the native code in nativeFinishInit() - * were rationalized with Zygote startup.<p> - * - * Current recognized args: - * <ul> - * <li> <code> [--] <start class name> <args> - * </ul> - * - * @param targetSdkVersion target SDK version - * @param argv arg strings - */ - public static final void zygoteInit(int targetSdkVersion, String[] argv, ClassLoader classLoader) - throws Zygote.MethodAndArgsCaller { - if (DEBUG) Slog.d(TAG, "RuntimeInit: Starting application from zygote"); - - Trace.traceBegin(Trace.TRACE_TAG_ACTIVITY_MANAGER, "RuntimeInit"); - redirectLogStreams(); - - commonInit(); - nativeZygoteInit(); - applicationInit(targetSdkVersion, argv, classLoader); - } - - /** - * The main function called when an application is started through a - * wrapper process. - * - * When the wrapper starts, the runtime starts {@link RuntimeInit#main} - * which calls {@link WrapperInit#main} which then calls this method. - * So we don't need to call commonInit() here. - * - * @param targetSdkVersion target SDK version - * @param argv arg strings - */ - public static void wrapperInit(int targetSdkVersion, String[] argv) - throws Zygote.MethodAndArgsCaller { - if (DEBUG) Slog.d(TAG, "RuntimeInit: Starting application from wrapper"); - - applicationInit(targetSdkVersion, argv, null); - } - - private static void applicationInit(int targetSdkVersion, String[] argv, ClassLoader classLoader) + protected static void applicationInit(int targetSdkVersion, String[] argv, ClassLoader classLoader) throws Zygote.MethodAndArgsCaller { // If the application calls System.exit(), terminate the process // immediately without running any shutdown hooks. It is not possible to diff --git a/core/java/com/android/internal/os/WrapperInit.java b/core/java/com/android/internal/os/WrapperInit.java index c03bcdf3a834..96468abd9047 100644 --- a/core/java/com/android/internal/os/WrapperInit.java +++ b/core/java/com/android/internal/os/WrapperInit.java @@ -20,7 +20,7 @@ import android.os.Process; import android.os.Trace; import android.util.BootTimingsTraceLog; import android.util.Slog; - +import com.android.internal.os.Zygote.MethodAndArgsCaller; import dalvik.system.VMRuntime; import java.io.DataOutputStream; import java.io.FileDescriptor; @@ -83,7 +83,7 @@ public class WrapperInit { // Launch the application. String[] runtimeArgs = new String[args.length - 2]; System.arraycopy(args, 2, runtimeArgs, 0, runtimeArgs.length); - RuntimeInit.wrapperInit(targetSdkVersion, runtimeArgs); + WrapperInit.wrapperInit(targetSdkVersion, runtimeArgs); } catch (Zygote.MethodAndArgsCaller caller) { caller.run(); } @@ -124,4 +124,24 @@ public class WrapperInit { Zygote.appendQuotedShellArgs(command, args); Zygote.execShell(command.toString()); } + + /** + * The main function called when an application is started through a + * wrapper process. + * + * When the wrapper starts, the runtime starts {@link RuntimeInit#main} + * which calls {@link main} which then calls this method. + * So we don't need to call commonInit() here. + * + * @param targetSdkVersion target SDK version + * @param argv arg strings + */ + private static void wrapperInit(int targetSdkVersion, String[] argv) + throws Zygote.MethodAndArgsCaller { + if (RuntimeInit.DEBUG) { + Slog.d(RuntimeInit.TAG, "RuntimeInit: Starting application from wrapper"); + } + + RuntimeInit.applicationInit(targetSdkVersion, argv, null); + } } diff --git a/core/java/com/android/internal/os/ZygoteConnection.java b/core/java/com/android/internal/os/ZygoteConnection.java index 8fe374c9266f..a7f311b33963 100644 --- a/core/java/com/android/internal/os/ZygoteConnection.java +++ b/core/java/com/android/internal/os/ZygoteConnection.java @@ -789,7 +789,7 @@ class ZygoteConnection { VMRuntime.getCurrentInstructionSet(), pipeFd, parsedArgs.remainingArgs); } else { - RuntimeInit.zygoteInit(parsedArgs.targetSdkVersion, + ZygoteInit.zygoteInit(parsedArgs.targetSdkVersion, parsedArgs.remainingArgs, null /* classLoader */); } } diff --git a/core/java/com/android/internal/os/ZygoteInit.java b/core/java/com/android/internal/os/ZygoteInit.java index 5049738f076a..8d319905b2a9 100644 --- a/core/java/com/android/internal/os/ZygoteInit.java +++ b/core/java/com/android/internal/os/ZygoteInit.java @@ -25,6 +25,7 @@ import android.icu.impl.CacheValue; import android.icu.text.DecimalFormatSymbols; import android.icu.util.ULocale; import android.net.LocalServerSocket; +import android.opengl.EGL14; import android.os.IInstalld; import android.os.Process; import android.os.RemoteException; @@ -44,6 +45,7 @@ import android.text.Hyphenator; import android.util.BootTimingsTraceLog; import android.util.EventLog; import android.util.Log; +import android.util.Slog; import android.webkit.WebViewFactory; import android.widget.TextView; @@ -81,6 +83,7 @@ public class ZygoteInit { private static final String TAG = "Zygote"; private static final String PROPERTY_DISABLE_OPENGL_PRELOADING = "ro.zygote.disable_gl_preload"; + private static final String PROPERTY_GFX_DRIVER = "ro.gfx.driver.0"; private static final String PROPERTY_RUNNING_IN_CONTAINER = "ro.boot.container"; private static final int LOG_BOOT_PROGRESS_PRELOAD_START = 3020; @@ -125,6 +128,9 @@ public class ZygoteInit { bootTimingsTraceLog.traceBegin("PreloadResources"); preloadResources(); bootTimingsTraceLog.traceEnd(); // PreloadResources + Trace.traceBegin(Trace.TRACE_TAG_DALVIK, "PreloadOpenGL"); + preloadOpenGL(); + Trace.traceEnd(Trace.TRACE_TAG_DALVIK); preloadSharedLibraries(); preloadTextResources(); // Ask the WebViewFactory to do any initialization that must run in the zygote process, @@ -174,6 +180,14 @@ public class ZygoteInit { System.loadLibrary("jnigraphics"); } + private static void preloadOpenGL() { + String driverPackageName = SystemProperties.get(PROPERTY_GFX_DRIVER); + if (!SystemProperties.getBoolean(PROPERTY_DISABLE_OPENGL_PRELOADING, false) || + driverPackageName == null || driverPackageName.isEmpty()) { + EGL14.eglGetDisplay(EGL14.EGL_DEFAULT_DISPLAY); + } + } + private static void preloadTextResources() { Hyphenator.init(); TextView.preloadFontCache(); @@ -471,7 +485,7 @@ public class ZygoteInit { /* * Pass the remaining arguments to SystemServer. */ - RuntimeInit.zygoteInit(parsedArgs.targetSdkVersion, parsedArgs.remainingArgs, cl); + ZygoteInit.zygoteInit(parsedArgs.targetSdkVersion, parsedArgs.remainingArgs, cl); } /* should never reach here */ @@ -771,4 +785,33 @@ public class ZygoteInit { */ private ZygoteInit() { } + + /** + * The main function called when started through the zygote process. This + * could be unified with main(), if the native code in nativeFinishInit() + * were rationalized with Zygote startup.<p> + * + * Current recognized args: + * <ul> + * <li> <code> [--] <start class name> <args> + * </ul> + * + * @param targetSdkVersion target SDK version + * @param argv arg strings + */ + public static final void zygoteInit(int targetSdkVersion, String[] argv, + ClassLoader classLoader) throws Zygote.MethodAndArgsCaller { + if (RuntimeInit.DEBUG) { + Slog.d(RuntimeInit.TAG, "RuntimeInit: Starting application from zygote"); + } + + Trace.traceBegin(Trace.TRACE_TAG_ACTIVITY_MANAGER, "ZygoteInit"); + RuntimeInit.redirectLogStreams(); + + RuntimeInit.commonInit(); + ZygoteInit.nativeZygoteInit(); + RuntimeInit.applicationInit(targetSdkVersion, argv, classLoader); + } + + private static final native void nativeZygoteInit(); } diff --git a/test-runner/src/com/android/internal/util/Predicate.java b/core/java/com/android/internal/util/Predicate.java index bc6d6b31dd28..bc6d6b31dd28 100644 --- a/test-runner/src/com/android/internal/util/Predicate.java +++ b/core/java/com/android/internal/util/Predicate.java diff --git a/test-runner/src/com/android/internal/util/Predicates.java b/core/java/com/android/internal/util/Predicates.java index 30b8dc6b6ee2..c006564f129a 100644 --- a/test-runner/src/com/android/internal/util/Predicates.java +++ b/core/java/com/android/internal/util/Predicates.java @@ -21,7 +21,6 @@ import java.util.Arrays; /** * Predicates contains static methods for creating the standard set of * {@code Predicate} objects. - * @hide */ public class Predicates { diff --git a/core/java/com/android/internal/view/IInputConnectionWrapper.java b/core/java/com/android/internal/view/IInputConnectionWrapper.java index 0185e306118f..cb2d88522f3b 100644 --- a/core/java/com/android/internal/view/IInputConnectionWrapper.java +++ b/core/java/com/android/internal/view/IInputConnectionWrapper.java @@ -57,7 +57,6 @@ public abstract class IInputConnectionWrapper extends IInputContext.Stub { private static final int DO_DELETE_SURROUNDING_TEXT_IN_CODE_POINTS = 81; private static final int DO_BEGIN_BATCH_EDIT = 90; private static final int DO_END_BATCH_EDIT = 95; - private static final int DO_REPORT_FULLSCREEN_MODE = 100; private static final int DO_PERFORM_PRIVATE_COMMAND = 120; private static final int DO_CLEAR_META_KEY_STATES = 130; private static final int DO_REQUEST_UPDATE_CURSOR_ANCHOR_INFO = 140; @@ -73,8 +72,6 @@ public abstract class IInputConnectionWrapper extends IInputContext.Stub { private Object mLock = new Object(); @GuardedBy("mLock") private boolean mFinished = false; - @GuardedBy("mLock") - private String mInputMethodId; static class SomeArgs { Object arg1; @@ -113,18 +110,6 @@ public abstract class IInputConnectionWrapper extends IInputContext.Stub { } } - public String getInputMethodId() { - synchronized (mLock) { - return mInputMethodId; - } - } - - public void setInputMethodId(final String inputMethodId) { - synchronized (mLock) { - mInputMethodId = inputMethodId; - } - } - abstract protected boolean isActive(); /** @@ -133,14 +118,6 @@ public abstract class IInputConnectionWrapper extends IInputContext.Stub { */ abstract protected void onUserAction(); - /** - * Called when the input method started or stopped full-screen mode. - * @param enabled {@code true} if the input method starts full-screen mode. - * @param calledInBackground {@code true} if this input connection is in a state when incoming - * events are usually ignored. - */ - abstract protected void onReportFullscreenMode(boolean enabled, boolean calledInBackground); - public void getTextAfterCursor(int length, int flags, int seq, IInputContextCallback callback) { dispatchMessage(obtainMessageIISC(DO_GET_TEXT_AFTER_CURSOR, length, flags, seq, callback)); } @@ -225,10 +202,6 @@ public abstract class IInputConnectionWrapper extends IInputContext.Stub { dispatchMessage(obtainMessage(DO_END_BATCH_EDIT)); } - public void reportFullscreenMode(boolean enabled) { - dispatchMessage(obtainMessageII(DO_REPORT_FULLSCREEN_MODE, enabled ? 1 : 0, 0)); - } - public void performPrivateCommand(String action, Bundle data) { dispatchMessage(obtainMessageOO(DO_PERFORM_PRIVATE_COMMAND, action, data)); } @@ -486,23 +459,6 @@ public abstract class IInputConnectionWrapper extends IInputContext.Stub { ic.endBatchEdit(); return; } - case DO_REPORT_FULLSCREEN_MODE: { - InputConnection ic = getInputConnection(); - boolean isBackground = false; - if (ic == null || !isActive()) { - Log.w(TAG, "reportFullscreenMode on inexistent InputConnection"); - isBackground = true; - } - final boolean enabled = msg.arg1 == 1; - if (!isBackground) { - ic.reportFullscreenMode(enabled); - } - // Due to the nature of asynchronous event handling, currently InputMethodService - // has relied on the fact that #reportFullscreenMode() can be handled even when the - // InputConnection is inactive. We have to notify this event to InputMethodManager. - onReportFullscreenMode(enabled, isBackground); - return; - } case DO_PERFORM_PRIVATE_COMMAND: { InputConnection ic = getInputConnection(); if (ic == null || !isActive()) { diff --git a/core/java/com/android/internal/view/IInputContext.aidl b/core/java/com/android/internal/view/IInputContext.aidl index 728c55786c49..c22799179b72 100644 --- a/core/java/com/android/internal/view/IInputContext.aidl +++ b/core/java/com/android/internal/view/IInputContext.aidl @@ -62,9 +62,7 @@ import com.android.internal.view.IInputContextCallback; void beginBatchEdit(); void endBatchEdit(); - - void reportFullscreenMode(boolean enabled); - + void sendKeyEvent(in KeyEvent event); void clearMetaKeyStates(int states); diff --git a/core/java/com/android/internal/view/IInputMethodClient.aidl b/core/java/com/android/internal/view/IInputMethodClient.aidl index 81056f2edd96..ffa9f75e4370 100644 --- a/core/java/com/android/internal/view/IInputMethodClient.aidl +++ b/core/java/com/android/internal/view/IInputMethodClient.aidl @@ -27,6 +27,7 @@ oneway interface IInputMethodClient { void onBindMethod(in InputBindResult res); // unbindReason corresponds to InputMethodClient.UnbindReason. void onUnbindMethod(int sequence, int unbindReason); - void setActive(boolean active); + void setActive(boolean active, boolean fullscreen); void setUserActionNotificationSequenceNumber(int sequenceNumber); + void reportFullscreenMode(boolean fullscreen); } diff --git a/core/java/com/android/internal/view/IInputMethodManager.aidl b/core/java/com/android/internal/view/IInputMethodManager.aidl index 9e4b43b6c007..2279a6706524 100644 --- a/core/java/com/android/internal/view/IInputMethodManager.aidl +++ b/core/java/com/android/internal/view/IInputMethodManager.aidl @@ -86,5 +86,7 @@ interface IInputMethodManager { IInputContentUriToken createInputContentUriToken(in IBinder token, in Uri contentUri, in String packageName); + void reportFullscreenMode(in IBinder token, boolean fullscreen); + oneway void notifyUserAction(int sequenceNumber); } diff --git a/core/java/com/android/internal/view/InputConnectionWrapper.java b/core/java/com/android/internal/view/InputConnectionWrapper.java index 9a09dcccd1a7..cc0ef756c6b3 100644 --- a/core/java/com/android/internal/view/InputConnectionWrapper.java +++ b/core/java/com/android/internal/view/InputConnectionWrapper.java @@ -467,12 +467,8 @@ public class InputConnectionWrapper implements InputConnection { } public boolean reportFullscreenMode(boolean enabled) { - try { - mIInputContext.reportFullscreenMode(enabled); - return true; - } catch (RemoteException e) { - return false; - } + // Nothing should happen when called from input method. + return false; } public boolean performPrivateCommand(String action, Bundle data) { diff --git a/core/jni/Android.mk b/core/jni/Android.mk index db3ea8c51bf4..dd2f365bb86a 100644 --- a/core/jni/Android.mk +++ b/core/jni/Android.mk @@ -203,6 +203,8 @@ LOCAL_C_INCLUDES += \ $(call include-path-for, libhardware)/hardware \ $(call include-path-for, libhardware_legacy)/hardware_legacy \ $(TOP)/frameworks/base/media/jni \ + $(TOP)/frameworks/rs/cpp \ + $(TOP)/frameworks/rs \ $(TOP)/system/core/base/include \ $(TOP)/system/core/include \ $(TOP)/system/core/libappfuse/include \ diff --git a/core/jni/AndroidRuntime.cpp b/core/jni/AndroidRuntime.cpp index 407e69c2421a..e237ce9f208f 100644 --- a/core/jni/AndroidRuntime.cpp +++ b/core/jni/AndroidRuntime.cpp @@ -216,7 +216,7 @@ static void com_android_internal_os_RuntimeInit_nativeFinishInit(JNIEnv* env, jo gCurRuntime->onStarted(); } -static void com_android_internal_os_RuntimeInit_nativeZygoteInit(JNIEnv* env, jobject clazz) +static void com_android_internal_os_ZygoteInit_nativeZygoteInit(JNIEnv* env, jobject clazz) { gCurRuntime->onZygoteInit(); } @@ -230,19 +230,27 @@ static void com_android_internal_os_RuntimeInit_nativeSetExitWithoutCleanup(JNIE /* * JNI registration. */ -static const JNINativeMethod gMethods[] = { - { "nativeFinishInit", "()V", - (void*) com_android_internal_os_RuntimeInit_nativeFinishInit }, - { "nativeZygoteInit", "()V", - (void*) com_android_internal_os_RuntimeInit_nativeZygoteInit }, - { "nativeSetExitWithoutCleanup", "(Z)V", - (void*) com_android_internal_os_RuntimeInit_nativeSetExitWithoutCleanup }, -}; int register_com_android_internal_os_RuntimeInit(JNIEnv* env) { + const JNINativeMethod methods[] = { + { "nativeFinishInit", "()V", + (void*) com_android_internal_os_RuntimeInit_nativeFinishInit }, + { "nativeSetExitWithoutCleanup", "(Z)V", + (void*) com_android_internal_os_RuntimeInit_nativeSetExitWithoutCleanup }, + }; return jniRegisterNativeMethods(env, "com/android/internal/os/RuntimeInit", - gMethods, NELEM(gMethods)); + methods, NELEM(methods)); +} + +int register_com_android_internal_os_ZygoteInit(JNIEnv* env) +{ + const JNINativeMethod methods[] = { + { "nativeZygoteInit", "()V", + (void*) com_android_internal_os_ZygoteInit_nativeZygoteInit }, + }; + return jniRegisterNativeMethods(env, "com/android/internal/os/ZygoteInit", + methods, NELEM(methods)); } // ---------------------------------------------------------------------- @@ -1271,6 +1279,7 @@ static int register_jni_procs(const RegJNIRec array[], size_t count, JNIEnv* env static const RegJNIRec gRegJNI[] = { REG_JNI(register_com_android_internal_os_RuntimeInit), + REG_JNI(register_com_android_internal_os_ZygoteInit), REG_JNI(register_android_os_SystemClock), REG_JNI(register_android_util_EventLog), REG_JNI(register_android_util_Log), diff --git a/core/proto/android/providers/settings.proto b/core/proto/android/providers/settings.proto index 7674d7a524a0..ee50c294df73 100644 --- a/core/proto/android/providers/settings.proto +++ b/core/proto/android/providers/settings.proto @@ -328,6 +328,7 @@ message GlobalSettingsProto { SettingProto enable_cellular_on_boot = 283; SettingProto max_notification_enqueue_rate = 284; SettingProto cell_on = 285; + SettingProto network_recommendations_package = 286; } message SecureSettingsProto { diff --git a/core/res/AndroidManifest.xml b/core/res/AndroidManifest.xml index 7b800b363e65..5b5e61e6ebdc 100644 --- a/core/res/AndroidManifest.xml +++ b/core/res/AndroidManifest.xml @@ -3252,6 +3252,10 @@ <permission android:name="android.permission.MODIFY_THEME_OVERLAY" android:protectionLevel="signature" /> + <!-- Allows an instant app to create foreground services. --> + <permission android:name="android.permission.INSTANT_APP_FOREGROUND_SERVICE" + android:protectionLevel="signature|development|ephemeral|appop" /> + <application android:process="system" android:persistent="true" android:hasCode="false" diff --git a/core/res/res/values/attrs.xml b/core/res/res/values/attrs.xml index aeba58976637..a3bad54c1297 100644 --- a/core/res/res/values/attrs.xml +++ b/core/res/res/values/attrs.xml @@ -4714,16 +4714,16 @@ <!-- No auto-sizing (default). --> <enum name="none" value="0" /> <!-- Uniform horizontal and vertical scaling. --> - <enum name="xy" value="1" /> + <enum name="uniform" value="1" /> </attr> <!-- Specify the auto-size step size if <code>autoSizeText</code> is set to <code>xy</code>. The default is 1px. Overwrites - <code>autoSizeStepSizeSet</code> if set. --> + <code>autoSizePresetSizes</code> if set. --> <attr name="autoSizeStepGranularity" format="dimension" /> <!-- Array of dimensions to be used in conjunction with <code>autoSizeText</code> set to <code>xy</code>. Overwrites <code>autoSizeStepGranularity</code> if set. --> - <attr name="autoSizeStepSizeSet"/> + <attr name="autoSizePresetSizes"/> <!-- The minimum text size constraint to be used when auto-sizing text --> <attr name="autoSizeMinTextSize" format="dimension" /> <!-- The maximum text size constraint to be used when auto-sizing text --> diff --git a/core/res/res/values/public.xml b/core/res/res/values/public.xml index 1dbd567db453..34659aaa9679 100644 --- a/core/res/res/values/public.xml +++ b/core/res/res/values/public.xml @@ -2767,7 +2767,7 @@ <public name="tooltipText" /> <public name="autoSizeText" /> <public name="autoSizeStepGranularity" /> - <public name="autoSizeStepSizeSet" /> + <public name="autoSizePresetSizes" /> <public name="autoSizeMinTextSize" /> <public name="min" /> <public name="rotationAnimation" /> diff --git a/core/tests/coretests/src/android/provider/SettingsTest.java b/core/tests/coretests/src/android/provider/SettingsTest.java index 1ff2056498f1..019f83751a65 100644 --- a/core/tests/coretests/src/android/provider/SettingsTest.java +++ b/core/tests/coretests/src/android/provider/SettingsTest.java @@ -384,7 +384,6 @@ public class SettingsTest { Settings.Secure.AUTO_FILL_SERVICE, Settings.Secure.AUTOMATIC_STORAGE_MANAGER_BYTES_CLEARED, Settings.Secure.AUTOMATIC_STORAGE_MANAGER_DAYS_TO_RETAIN, - Settings.Secure.AUTOMATIC_STORAGE_MANAGER_DOWNLOADS_DAYS_TO_RETAIN, Settings.Secure.AUTOMATIC_STORAGE_MANAGER_ENABLED, Settings.Secure.AUTOMATIC_STORAGE_MANAGER_LAST_RUN, Settings.Secure.BACKUP_AUTO_RESTORE, @@ -402,9 +401,6 @@ public class SettingsTest { Settings.Secure.DISABLED_PRINT_SERVICES, Settings.Secure.DISABLED_SYSTEM_INPUT_METHODS, Settings.Secure.DISPLAY_DENSITY_FORCED, - Settings.Secure.DOWNLOADS_BACKUP_ALLOW_METERED, // Candidate? - Settings.Secure.DOWNLOADS_BACKUP_CHARGING_ONLY, // Candidate? - Settings.Secure.DOWNLOADS_BACKUP_ENABLED, // Candidate? Settings.Secure.DOZE_ALWAYS_ON, Settings.Secure.EMERGENCY_ASSISTANCE_APPLICATION, Settings.Secure.ENABLED_NOTIFICATION_ASSISTANT, diff --git a/test-runner/tests/src/com/android/internal/util/PredicatesTest.java b/core/tests/utiltests/src/com/android/internal/util/PredicatesTest.java index c46ff051dd33..c46ff051dd33 100644 --- a/test-runner/tests/src/com/android/internal/util/PredicatesTest.java +++ b/core/tests/utiltests/src/com/android/internal/util/PredicatesTest.java diff --git a/data/etc/platform.xml b/data/etc/platform.xml index 9cdc66047662..b394c3ccf296 100644 --- a/data/etc/platform.xml +++ b/data/etc/platform.xml @@ -177,6 +177,9 @@ access while in data mode, even if they aren't in the foreground. --> <allow-in-data-usage-save package="com.android.providers.downloads" /> + <!-- This is a core platform component that needs to freely run in the background --> + <allow-in-power-save package="com.android.cellbroadcastreceiver" /> + <!-- These are the packages that are white-listed to be able to run as system user --> <system-user-whitelisted-app package="com.android.settings" /> diff --git a/libs/androidfw/include/androidfw/StringPiece.h b/libs/androidfw/include/androidfw/StringPiece.h index 8f6824b5322c..a873d66803e7 100644 --- a/libs/androidfw/include/androidfw/StringPiece.h +++ b/libs/androidfw/include/androidfw/StringPiece.h @@ -271,8 +271,36 @@ inline ::std::ostream& operator<<(::std::ostream& out, const BasicStringPiece<ch return out.write(str.data(), str.size()); } +template <typename TChar> +inline ::std::basic_string<TChar>& operator+=(::std::basic_string<TChar>& lhs, + const BasicStringPiece<TChar>& rhs) { + return lhs.append(rhs.data(), rhs.size()); +} + +template <typename TChar> +inline bool operator==(const ::std::basic_string<TChar>& lhs, const BasicStringPiece<TChar>& rhs) { + return rhs == lhs; +} + +template <typename TChar> +inline bool operator!=(const ::std::basic_string<TChar>& lhs, const BasicStringPiece<TChar>& rhs) { + return rhs != lhs; +} + } // namespace android +inline ::std::ostream& operator<<(::std::ostream& out, const std::u16string& str) { + ssize_t utf8_len = utf16_to_utf8_length(str.data(), str.size()); + if (utf8_len < 0) { + return out << "???"; + } + + std::string utf8; + utf8.resize(static_cast<size_t>(utf8_len)); + utf16_to_utf8(str.data(), str.size(), &*utf8.begin(), utf8_len + 1); + return out << utf8; +} + namespace std { template <typename TChar> diff --git a/libs/hwui/Android.mk b/libs/hwui/Android.mk index 692199d7af1f..ff40c8a9fb92 100644 --- a/libs/hwui/Android.mk +++ b/libs/hwui/Android.mk @@ -189,13 +189,11 @@ hwui_c_includes += \ external/harfbuzz_ng/src \ external/freetype/include -ifneq (false,$(ANDROID_ENABLE_RENDERSCRIPT)) - hwui_cflags += -DANDROID_ENABLE_RENDERSCRIPT - hwui_c_includes += \ - $(call intermediates-dir-for,STATIC_LIBRARIES,TARGET,) \ - frameworks/rs/cpp \ - frameworks/rs -endif +# enable RENDERSCRIPT +hwui_c_includes += \ + $(call intermediates-dir-for,STATIC_LIBRARIES,TARGET,) \ + frameworks/rs/cpp \ + frameworks/rs # ------------------------ # static library diff --git a/libs/hwui/FontRenderer.cpp b/libs/hwui/FontRenderer.cpp index 4f9a3de64fc2..ee99018fb652 100644 --- a/libs/hwui/FontRenderer.cpp +++ b/libs/hwui/FontRenderer.cpp @@ -33,14 +33,11 @@ #include <algorithm> #include <cutils/properties.h> +#include <RenderScript.h> #include <SkGlyph.h> #include <SkUtils.h> #include <utils/Log.h> -#ifdef ANDROID_ENABLE_RENDERSCRIPT -#include <RenderScript.h> -#endif - namespace android { namespace uirenderer { @@ -591,17 +588,12 @@ FontRenderer::DropShadow FontRenderer::renderDropShadow(const SkPaint* paint, co return image; } -#ifdef ANDROID_ENABLE_RENDERSCRIPT // Align buffers for renderscript usage if (paddedWidth & (RS_CPU_ALLOCATION_ALIGNMENT - 1)) { paddedWidth += RS_CPU_ALLOCATION_ALIGNMENT - paddedWidth % RS_CPU_ALLOCATION_ALIGNMENT; } int size = paddedWidth * paddedHeight; uint8_t* dataBuffer = (uint8_t*) memalign(RS_CPU_ALLOCATION_ALIGNMENT, size); -#else - int size = paddedWidth * paddedHeight; - uint8_t* dataBuffer = (uint8_t*) malloc(size); -#endif memset(dataBuffer, 0, size); @@ -691,7 +683,6 @@ bool FontRenderer::renderTextOnPath(const SkPaint* paint, const Rect* clip, cons void FontRenderer::blurImage(uint8_t** image, int32_t width, int32_t height, float radius) { uint32_t intRadius = Blur::convertRadiusToInt(radius); -#ifdef ANDROID_ENABLE_RENDERSCRIPT if (width * height * intRadius >= RS_MIN_INPUT_CUTOFF && radius <= 25.0f) { uint8_t* outImage = (uint8_t*) memalign(RS_CPU_ALLOCATION_ALIGNMENT, width * height); @@ -729,7 +720,6 @@ void FontRenderer::blurImage(uint8_t** image, int32_t width, int32_t height, flo return; } } -#endif std::unique_ptr<float[]> gaussian(new float[2 * intRadius + 1]); Blur::generateGaussianWeights(gaussian.get(), radius); diff --git a/libs/hwui/FontRenderer.h b/libs/hwui/FontRenderer.h index dd9c40f89ad0..329309c1cd5c 100644 --- a/libs/hwui/FontRenderer.h +++ b/libs/hwui/FontRenderer.h @@ -34,7 +34,6 @@ #include <vector> -#ifdef ANDROID_ENABLE_RENDERSCRIPT #include "RenderScript.h" namespace RSC { class Element; @@ -42,7 +41,6 @@ namespace RSC { class ScriptIntrinsicBlur; class sp; } -#endif namespace android { namespace uirenderer { @@ -201,12 +199,10 @@ private: FontCacheHistoryTracker mHistoryTracker; #endif -#ifdef ANDROID_ENABLE_RENDERSCRIPT // RS constructs RSC::sp<RSC::RS> mRs; RSC::sp<const RSC::Element> mRsElement; RSC::sp<RSC::ScriptIntrinsicBlur> mRsScript; -#endif static void computeGaussianWeights(float* weights, int32_t radius); static void horizontalBlur(float* weights, int32_t radius, const uint8_t *source, uint8_t *dest, diff --git a/libs/hwui/hwui_static_deps.mk b/libs/hwui/hwui_static_deps.mk index f69da484af43..a75fd6a8d587 100644 --- a/libs/hwui/hwui_static_deps.mk +++ b/libs/hwui/hwui_static_deps.mk @@ -28,6 +28,5 @@ LOCAL_SHARED_LIBRARIES += \ libminikin \ libandroidfw -ifneq (false,$(ANDROID_ENABLE_RENDERSCRIPT)) - LOCAL_SHARED_LIBRARIES += libRScpp -endif +# enable RENDERSCRIPT +LOCAL_SHARED_LIBRARIES += libRScpp diff --git a/packages/SettingsProvider/res/values/defaults.xml b/packages/SettingsProvider/res/values/defaults.xml index 136f17e5a77c..499b6ae0f5d3 100644 --- a/packages/SettingsProvider/res/values/defaults.xml +++ b/packages/SettingsProvider/res/values/defaults.xml @@ -227,4 +227,7 @@ <!-- default setting for Settings.System.END_BUTTON_BEHAVIOR : END_BUTTON_BEHAVIOR_SLEEP --> <integer name="def_end_button_behavior">0x2</integer> + + <!--Default settings for network recommendations. --> + <string name="def_network_recommendations_package" translatable="false">com.android.networkrecommendation</string> </resources> diff --git a/packages/SettingsProvider/src/com/android/providers/settings/SettingsProtoDumpUtil.java b/packages/SettingsProvider/src/com/android/providers/settings/SettingsProtoDumpUtil.java index 4ddafac1aca5..0676efd58904 100644 --- a/packages/SettingsProvider/src/com/android/providers/settings/SettingsProtoDumpUtil.java +++ b/packages/SettingsProvider/src/com/android/providers/settings/SettingsProtoDumpUtil.java @@ -495,6 +495,9 @@ class SettingsProtoDumpUtil { Settings.Global.NETWORK_RECOMMENDATIONS_ENABLED, GlobalSettingsProto.NETWORK_RECOMMENDATIONS_ENABLED); dumpSetting(s, p, + Settings.Global.NETWORK_RECOMMENDATIONS_PACKAGE, + GlobalSettingsProto.NETWORK_RECOMMENDATIONS_PACKAGE); + dumpSetting(s, p, Settings.Global.BLE_SCAN_ALWAYS_AVAILABLE, GlobalSettingsProto.BLE_SCAN_ALWAYS_AVAILABLE); dumpSetting(s, p, @@ -1426,18 +1429,6 @@ class SettingsProtoDumpUtil { Settings.Secure.SYSTEM_NAVIGATION_KEYS_ENABLED, SecureSettingsProto.SYSTEM_NAVIGATION_KEYS_ENABLED); dumpSetting(s, p, - Settings.Secure.DOWNLOADS_BACKUP_ENABLED, - SecureSettingsProto.DOWNLOADS_BACKUP_ENABLED); - dumpSetting(s, p, - Settings.Secure.DOWNLOADS_BACKUP_ALLOW_METERED, - SecureSettingsProto.DOWNLOADS_BACKUP_ALLOW_METERED); - dumpSetting(s, p, - Settings.Secure.DOWNLOADS_BACKUP_CHARGING_ONLY, - SecureSettingsProto.DOWNLOADS_BACKUP_CHARGING_ONLY); - dumpSetting(s, p, - Settings.Secure.AUTOMATIC_STORAGE_MANAGER_DOWNLOADS_DAYS_TO_RETAIN, - SecureSettingsProto.AUTOMATIC_STORAGE_MANAGER_DOWNLOADS_DAYS_TO_RETAIN); - dumpSetting(s, p, Settings.Secure.QS_TILES, SecureSettingsProto.QS_TILES); dumpSetting(s, p, diff --git a/packages/SettingsProvider/src/com/android/providers/settings/SettingsProvider.java b/packages/SettingsProvider/src/com/android/providers/settings/SettingsProvider.java index 229979489855..edcb9b51fceb 100644 --- a/packages/SettingsProvider/src/com/android/providers/settings/SettingsProvider.java +++ b/packages/SettingsProvider/src/com/android/providers/settings/SettingsProvider.java @@ -2735,7 +2735,7 @@ public class SettingsProvider extends ContentProvider { } private final class UpgradeController { - private static final int SETTINGS_VERSION = 138; + private static final int SETTINGS_VERSION = 139; private final int mUserId; @@ -3118,26 +3118,7 @@ public class SettingsProvider extends ContentProvider { } if (currentVersion == 135) { - // Version 135: Migrating the NETWORK_SCORER_APP setting to the - // NETWORK_RECOMMENDATIONS_ENABLED setting. - if (userId == UserHandle.USER_SYSTEM) { - final SettingsState globalSettings = getGlobalSettingsLocked(); - Setting currentSetting = globalSettings.getSettingLocked( - Global.NETWORK_SCORER_APP); - if (!currentSetting.isNull()) { - // A scorer was set so enable recommendations. - globalSettings.insertSettingLocked( - Global.NETWORK_RECOMMENDATIONS_ENABLED, - "1", null, true, - SettingsState.SYSTEM_PACKAGE_NAME); - - // and clear the scorer setting since it's no longer needed. - globalSettings.insertSettingLocked( - Global.NETWORK_SCORER_APP, - null, null, true, - SettingsState.SYSTEM_PACKAGE_NAME); - } - } + // Version 135 no longer used. currentVersion = 136; } @@ -3200,6 +3181,28 @@ public class SettingsProvider extends ContentProvider { currentVersion = 138; } + if (currentVersion == 138) { + // Version 139: Applying the default to NETWORK_RECOMMENDATIONS_PACKAGE + if (userId == UserHandle.USER_SYSTEM) { + final SettingsState globalSettings = getGlobalSettingsLocked(); + final String defaultAppPackage = getContext().getResources() + .getString(R.string.def_network_recommendations_package); + + // Set the network recommendations package name + globalSettings.insertSettingLocked( + Global.NETWORK_RECOMMENDATIONS_PACKAGE, + defaultAppPackage, null, true, + SettingsState.SYSTEM_PACKAGE_NAME); + + // Clear the scorer setting since it's no longer needed. + globalSettings.insertSettingLocked( + Global.NETWORK_SCORER_APP, + null, null, true, + SettingsState.SYSTEM_PACKAGE_NAME); + } + currentVersion = 139; + } + if (currentVersion != newVersion) { Slog.wtf("SettingsProvider", "warning: upgrading settings database to version " + newVersion + " left it at " diff --git a/packages/SystemUI/plugin/src/com/android/systemui/plugins/IntentButtonProvider.java b/packages/SystemUI/plugin/src/com/android/systemui/plugins/IntentButtonProvider.java index 1b8efa79ad73..9c173bd16967 100644 --- a/packages/SystemUI/plugin/src/com/android/systemui/plugins/IntentButtonProvider.java +++ b/packages/SystemUI/plugin/src/com/android/systemui/plugins/IntentButtonProvider.java @@ -32,6 +32,7 @@ public interface IntentButtonProvider extends Plugin { public boolean isVisible = true; public CharSequence contentDescription = null; public Drawable drawable; + public boolean tint = true; } public IconState getIcon(); diff --git a/packages/SystemUI/res/layout/keyguard_bottom_area.xml b/packages/SystemUI/res/layout/keyguard_bottom_area.xml index 078f9d73ffec..fc1271cf74b6 100644 --- a/packages/SystemUI/res/layout/keyguard_bottom_area.xml +++ b/packages/SystemUI/res/layout/keyguard_bottom_area.xml @@ -66,7 +66,6 @@ android:layout_height="@dimen/keyguard_affordance_height" android:layout_width="@dimen/keyguard_affordance_width" android:layout_gravity="bottom|end" - android:tint="#ffffffff" android:src="@drawable/ic_camera_alt_24dp" android:scaleType="center" android:contentDescription="@string/accessibility_camera_button" /> @@ -76,7 +75,6 @@ android:layout_height="@dimen/keyguard_affordance_height" android:layout_width="@dimen/keyguard_affordance_width" android:layout_gravity="bottom|start" - android:tint="#ffffffff" android:src="@drawable/ic_phone_24dp" android:scaleType="center" android:contentDescription="@string/accessibility_phone_button" /> diff --git a/packages/SystemUI/res/values-af/strings.xml b/packages/SystemUI/res/values-af/strings.xml index e647adee4412..7e3a457fb24c 100644 --- a/packages/SystemUI/res/values-af/strings.xml +++ b/packages/SystemUI/res/values-af/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Terug"</string> <string name="accessibility_home" msgid="8217216074895377641">"Tuis"</string> <string name="accessibility_menu" msgid="316839303324695949">"Kieslys"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Oorsig"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Deursoek"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Kamera"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Bladsy <xliff:g id="ID_1">%1$d</xliff:g> van <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Vou uit"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Minimeer"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Maak toe"</string> <string name="high_temp_title" msgid="4589508026407318374">"Foon raak warm"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Sommige kenmerke is beperk terwyl foon afkoel"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Jou foon sal outomaties probeer om af te koel. Jy kan steeds jou foon gebruik, maar dit sal dalk stadiger wees.\n\nJou foon sal normaalweg werk nadat dit afgekoel het."</string> diff --git a/packages/SystemUI/res/values-am/strings.xml b/packages/SystemUI/res/values-am/strings.xml index 392cd0171af7..a793996b3428 100644 --- a/packages/SystemUI/res/values-am/strings.xml +++ b/packages/SystemUI/res/values-am/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"ተመለስ"</string> <string name="accessibility_home" msgid="8217216074895377641">"መነሻ"</string> <string name="accessibility_menu" msgid="316839303324695949">"ምናሌ"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"አጠቃላይ ዕይታ"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"ፈልግ"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"ካሜራ"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"ገጽ <xliff:g id="ID_1">%1$d</xliff:g> ከ <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"ዘርጋ"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"አሳንስ"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"ዝጋ"</string> <string name="high_temp_title" msgid="4589508026407318374">"ስልኩ እየሞቀ ነው"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"ስልኩ እየቀዘቀዘ ሳለ አንዳንድ ባህሪዎች ይገደባሉ"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"የእርስዎ ስልክ በራስ-ሰር ለመቀዝቀዝ ይሞክራል። አሁንም ስልክዎን መጠቀም ይችላሉ፣ ነገር ግን ሊንቀራፈፍ ይችላል።\n\nአንዴ ስልክዎ ከቀዘቀዘ በኋላ በመደበኝነት ያሄዳል።"</string> diff --git a/packages/SystemUI/res/values-ar/strings.xml b/packages/SystemUI/res/values-ar/strings.xml index f9073f534626..ae26d832b571 100644 --- a/packages/SystemUI/res/values-ar/strings.xml +++ b/packages/SystemUI/res/values-ar/strings.xml @@ -87,6 +87,8 @@ <string name="accessibility_back" msgid="567011538994429120">"رجوع"</string> <string name="accessibility_home" msgid="8217216074895377641">"الرئيسية"</string> <string name="accessibility_menu" msgid="316839303324695949">"القائمة"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"النظرة عامة"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"بحث"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"الكاميرا"</string> @@ -679,8 +681,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"الصفحة <xliff:g id="ID_1">%1$d</xliff:g> من <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"توسيع"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"تصغير"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"إغلاق"</string> <string name="high_temp_title" msgid="4589508026407318374">"تزداد درجة حرارة الهاتف"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"يتم تقييد عمل بعض الميزات إلى أن تنخفض درجة حرارة الهاتف"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"سيحاول الهاتف تخفيض درجة حرارته تلقائيًا. سيظل بإمكانك استخدام هاتفك، ولكن قد يعمل بشكل أبطأ.\n\nبعد أن تنخفض درجة حرارة الهاتف، سيستعيد سرعته المعتادة."</string> diff --git a/packages/SystemUI/res/values-az/strings.xml b/packages/SystemUI/res/values-az/strings.xml index ba67b3a56dc8..6d5a321c82bd 100644 --- a/packages/SystemUI/res/values-az/strings.xml +++ b/packages/SystemUI/res/values-az/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Geri"</string> <string name="accessibility_home" msgid="8217216074895377641">"Ana səhifə"</string> <string name="accessibility_menu" msgid="316839303324695949">"Menyu"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"İcmal"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Axtar"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Kamera"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"<xliff:g id="ID_2">%2$d</xliff:g> səhifədən <xliff:g id="ID_1">%1$d</xliff:g> səhifə"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Genişləndirin"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Kiçildin"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Bağlayın"</string> <string name="high_temp_title" msgid="4589508026407318374">"Telefon qızmağa başlayır"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Telefon soyuyana kimi bəzi funksiyalar məhdudlaşdırılır"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Telefonunuz avtomatik olaraq soyumağa başlayacaq. Telefon istifadəsinə davam edə bilərsiniz, lakin sürəti yavaşlaya bilər.\n\nTelefonunuz soyuduqdan sonra normal işləyəcək."</string> diff --git a/packages/SystemUI/res/values-b+sr+Latn/strings.xml b/packages/SystemUI/res/values-b+sr+Latn/strings.xml index 2e01995b77ad..4769d984b87a 100644 --- a/packages/SystemUI/res/values-b+sr+Latn/strings.xml +++ b/packages/SystemUI/res/values-b+sr+Latn/strings.xml @@ -84,6 +84,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Nazad"</string> <string name="accessibility_home" msgid="8217216074895377641">"Početna"</string> <string name="accessibility_menu" msgid="316839303324695949">"Meni"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Pregled"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Pretražite"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Kamera"</string> @@ -673,8 +675,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"<xliff:g id="ID_1">%1$d</xliff:g>. strana od <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Proširi"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Umanji"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Zatvori"</string> <string name="high_temp_title" msgid="4589508026407318374">"Telefon se zagrejao"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Neke funkcije su ograničene dok se telefon ne ohladi"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Telefon će automatski pokušati da se ohladi. I dalje ćete moći da koristite telefon, ali će sporije reagovati.\n\nKada se telefon ohladi, normalno će raditi."</string> diff --git a/packages/SystemUI/res/values-be/strings.xml b/packages/SystemUI/res/values-be/strings.xml index 60f042e167ff..09d305d671b1 100644 --- a/packages/SystemUI/res/values-be/strings.xml +++ b/packages/SystemUI/res/values-be/strings.xml @@ -85,6 +85,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Назад"</string> <string name="accessibility_home" msgid="8217216074895377641">"На Галоўную старонку"</string> <string name="accessibility_menu" msgid="316839303324695949">"Меню"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Агляд"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Пошук"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Камера"</string> @@ -677,8 +679,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Старонка <xliff:g id="ID_1">%1$d</xliff:g> з <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Разгарнуць"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Згарнуць"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Закрыць"</string> <string name="high_temp_title" msgid="4589508026407318374">"Тэлефон награваецца"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Некаторыя функцыі абмежаваны, пакуль тэлефон астывае"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Ваш тэлефон аўтаматычна паспрабуе астыць. Вы можаце па-ранейшаму карыстацца сваім тэлефонам, але ён можа працаваць больш павольна.\n\nПасля таго як ваш тэлефон астыне, ён будзе працаваць у звычайным рэжыме."</string> diff --git a/packages/SystemUI/res/values-bg/strings.xml b/packages/SystemUI/res/values-bg/strings.xml index 2ebac751eb09..6dea2cfe8068 100644 --- a/packages/SystemUI/res/values-bg/strings.xml +++ b/packages/SystemUI/res/values-bg/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Назад"</string> <string name="accessibility_home" msgid="8217216074895377641">"Начало"</string> <string name="accessibility_menu" msgid="316839303324695949">"Меню"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Общ преглед"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Търсене"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Камера"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Страница <xliff:g id="ID_1">%1$d</xliff:g> от <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Разгъване"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Намаляване"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Затваряне"</string> <string name="high_temp_title" msgid="4589508026407318374">"Телефонът загрява"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Някои функции са ограничени, докато телефонът се охлажда"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Телефонът ви автоматично ще направи опит за охлаждане. Пак можете да го използвате, но той може да работи по-бавно.\n\nСлед като се охлади, ще работи нормално."</string> diff --git a/packages/SystemUI/res/values-bn/strings.xml b/packages/SystemUI/res/values-bn/strings.xml index ed86d3d9ce40..e95f5ced2ecc 100644 --- a/packages/SystemUI/res/values-bn/strings.xml +++ b/packages/SystemUI/res/values-bn/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"ফিরুন"</string> <string name="accessibility_home" msgid="8217216074895377641">"হোম"</string> <string name="accessibility_menu" msgid="316839303324695949">"মেনু"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"এক নজরে"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"অনুসন্ধান করুন"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"ক্যামেরা"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"<xliff:g id="ID_2">%2$d</xliff:g>টির মধ্যে <xliff:g id="ID_1">%1$d</xliff:g> নং পৃষ্ঠা"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"প্রসারিত করুন"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"ছোটো করুন"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"বন্ধ করুন"</string> <string name="high_temp_title" msgid="4589508026407318374">"ফোনটি গরম হচ্ছে"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"ফোনটি ঠান্ডা হওয়ার সময় কিছু বৈশিষ্ট্য সীমিত হতে পারে"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"আপনার ফোনটি নিজে থেকেই ঠান্ডা হওয়ার চেষ্টা করবে৷ আপনি তবুও আপনার ফোন ব্যবহার করতে পারেন, কিন্তু এটি একটু ধীরে চলতে পারে৷\n\nআপনার ফোনটি পুরোপুরি ঠান্ডা হয়ে গেলে এটি স্বাভাবিকভাবে চলবে৷"</string> diff --git a/packages/SystemUI/res/values-bs/strings.xml b/packages/SystemUI/res/values-bs/strings.xml index d17775cba5af..186d6f33da5a 100644 --- a/packages/SystemUI/res/values-bs/strings.xml +++ b/packages/SystemUI/res/values-bs/strings.xml @@ -84,6 +84,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Nazad"</string> <string name="accessibility_home" msgid="8217216074895377641">"Dugme za početnu stranicu"</string> <string name="accessibility_menu" msgid="316839303324695949">"Dugme Meni"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Pregled"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Traži"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Kamera"</string> @@ -675,8 +677,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Stranica <xliff:g id="ID_1">%1$d</xliff:g> od <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Proširi"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Umanji"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Zatvori"</string> <string name="high_temp_title" msgid="4589508026407318374">"Telefon se pregrijava"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Neke funkcije su ograničene dok se telefon hladi"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Vaš telefon će se automatski pokušati ohladiti. I dalje možete koristi telefon, ali će možda raditi sporije.\n\nNakon što se ohladi, telefon će normalno raditi."</string> diff --git a/packages/SystemUI/res/values-ca/strings.xml b/packages/SystemUI/res/values-ca/strings.xml index 009942c5119e..0311231099fc 100644 --- a/packages/SystemUI/res/values-ca/strings.xml +++ b/packages/SystemUI/res/values-ca/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Enrere"</string> <string name="accessibility_home" msgid="8217216074895377641">"Pàgina d\'inici"</string> <string name="accessibility_menu" msgid="316839303324695949">"Menú"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Visió general"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Cerca"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Càmera"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Pàgina <xliff:g id="ID_1">%1$d</xliff:g> (<xliff:g id="ID_2">%2$d</xliff:g> en total)"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Desplega"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Minimitza"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Tanca"</string> <string name="high_temp_title" msgid="4589508026407318374">"El telèfon s\'està escalfant"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Algunes funcions estaran limitades mentre el telèfon es refreda"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"El telèfon provarà de refredar-se automàticament. Podràs continuar utilitzant-lo, però és possible que funcioni més lentament.\n\nUn cop s\'hagi refredat, funcionarà amb normalitat."</string> diff --git a/packages/SystemUI/res/values-cs/strings.xml b/packages/SystemUI/res/values-cs/strings.xml index dc3df04fa023..75b2a9a47034 100644 --- a/packages/SystemUI/res/values-cs/strings.xml +++ b/packages/SystemUI/res/values-cs/strings.xml @@ -85,6 +85,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Zpět"</string> <string name="accessibility_home" msgid="8217216074895377641">"Domů"</string> <string name="accessibility_menu" msgid="316839303324695949">"Menu"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Přehled"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Hledat"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Fotoaparát"</string> @@ -677,8 +679,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Stránka <xliff:g id="ID_1">%1$d</xliff:g> z <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Rozbalit"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Minimalizovat"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Zavřít"</string> <string name="high_temp_title" msgid="4589508026407318374">"Telefon se zahřívá"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Některé funkce jsou při chladnutí omezeny"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Telefon se automaticky pokusí vychladnout. Lze jej nadále používat, ale může být pomalejší.\n\nAž telefon vychladne, bude fungovat normálně."</string> diff --git a/packages/SystemUI/res/values-da/strings.xml b/packages/SystemUI/res/values-da/strings.xml index dda65e2e0c3b..7c2f954b2be3 100644 --- a/packages/SystemUI/res/values-da/strings.xml +++ b/packages/SystemUI/res/values-da/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Tilbage"</string> <string name="accessibility_home" msgid="8217216074895377641">"Startskærm"</string> <string name="accessibility_menu" msgid="316839303324695949">"Menu"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Oversigt"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Søg"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Kamera"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Side <xliff:g id="ID_1">%1$d</xliff:g> af <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Udvid"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Minimer"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Luk"</string> <string name="high_temp_title" msgid="4589508026407318374">"Telefonen er ved at blive varm"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Nogle funktioner er begrænsede, mens telefonen køler ned"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Din telefon forsøger automatisk at køle ned. Du kan stadig bruge telefonen, men den kører muligvis langsommere.\n\nNår din telefon er kølet ned, fungerer den normalt igen."</string> diff --git a/packages/SystemUI/res/values-de/strings.xml b/packages/SystemUI/res/values-de/strings.xml index 5509a5774fec..8916dbb2442b 100644 --- a/packages/SystemUI/res/values-de/strings.xml +++ b/packages/SystemUI/res/values-de/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Zurück"</string> <string name="accessibility_home" msgid="8217216074895377641">"Startbildschirm"</string> <string name="accessibility_menu" msgid="316839303324695949">"Menü"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Übersicht"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Suchen"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Kamera"</string> @@ -673,8 +675,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Seite <xliff:g id="ID_1">%1$d</xliff:g> von <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Maximieren"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Minimieren"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Schließen"</string> <string name="high_temp_title" msgid="4589508026407318374">"Smartphone wird warm"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Einige Funktionen sind während der Abkühlphase des Smartphones eingeschränkt"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Dein Smartphone kühlt sich automatisch ab. Du kannst dein Smartphone weiterhin nutzen, aber es reagiert möglicherweise langsamer.\n\nSobald dein Smartphone abgekühlt ist, funktioniert es wieder normal."</string> diff --git a/packages/SystemUI/res/values-el/strings.xml b/packages/SystemUI/res/values-el/strings.xml index 1de2dae33f8c..baee007b78e8 100644 --- a/packages/SystemUI/res/values-el/strings.xml +++ b/packages/SystemUI/res/values-el/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Πίσω"</string> <string name="accessibility_home" msgid="8217216074895377641">"Αρχική οθόνη"</string> <string name="accessibility_menu" msgid="316839303324695949">"Μενού"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Επισκόπηση"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Αναζήτηση"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Φωτογραφική μηχανή"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Σελίδα <xliff:g id="ID_1">%1$d</xliff:g> από <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Ανάπτυξη"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Ελαχιστοποίηση"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Κλείσιμο"</string> <string name="high_temp_title" msgid="4589508026407318374">"Αύξηση θερμοκρασίας τηλεφώνου"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Ορισμένες λειτουργίες περιορίζονται κατά τη μείωση της θερμοκρασίας"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Το τηλέφωνό σας θα προσπαθήσει να μειώσει αυτόματα τη θερμοκρασία. Μπορείτε να εξακολουθήσετε να το χρησιμοποιείτε, αλλά είναι πιθανό να λειτουργεί πιο αργά.\n\nΜόλις μειωθεί η θερμοκρασία του τηλεφώνου σας, θα λειτουργεί ξανά κανονικά."</string> diff --git a/packages/SystemUI/res/values-en-rAU/strings.xml b/packages/SystemUI/res/values-en-rAU/strings.xml index a79caad47130..e66cb0492ce4 100644 --- a/packages/SystemUI/res/values-en-rAU/strings.xml +++ b/packages/SystemUI/res/values-en-rAU/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Back"</string> <string name="accessibility_home" msgid="8217216074895377641">"Home"</string> <string name="accessibility_menu" msgid="316839303324695949">"Menu"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Overview"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Search"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Camera"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Page <xliff:g id="ID_1">%1$d</xliff:g> of <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Expand"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Minimise"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Close"</string> <string name="high_temp_title" msgid="4589508026407318374">"Phone is getting warm"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Some features limited while phone cools down"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Your phone will automatically try to cool down. You can still use your phone, but it may run more slowly.\n\nOnce your phone has cooled down, it will run normally."</string> diff --git a/packages/SystemUI/res/values-en-rGB/strings.xml b/packages/SystemUI/res/values-en-rGB/strings.xml index a79caad47130..e66cb0492ce4 100644 --- a/packages/SystemUI/res/values-en-rGB/strings.xml +++ b/packages/SystemUI/res/values-en-rGB/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Back"</string> <string name="accessibility_home" msgid="8217216074895377641">"Home"</string> <string name="accessibility_menu" msgid="316839303324695949">"Menu"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Overview"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Search"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Camera"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Page <xliff:g id="ID_1">%1$d</xliff:g> of <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Expand"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Minimise"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Close"</string> <string name="high_temp_title" msgid="4589508026407318374">"Phone is getting warm"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Some features limited while phone cools down"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Your phone will automatically try to cool down. You can still use your phone, but it may run more slowly.\n\nOnce your phone has cooled down, it will run normally."</string> diff --git a/packages/SystemUI/res/values-en-rIN/strings.xml b/packages/SystemUI/res/values-en-rIN/strings.xml index a79caad47130..e66cb0492ce4 100644 --- a/packages/SystemUI/res/values-en-rIN/strings.xml +++ b/packages/SystemUI/res/values-en-rIN/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Back"</string> <string name="accessibility_home" msgid="8217216074895377641">"Home"</string> <string name="accessibility_menu" msgid="316839303324695949">"Menu"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Overview"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Search"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Camera"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Page <xliff:g id="ID_1">%1$d</xliff:g> of <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Expand"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Minimise"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Close"</string> <string name="high_temp_title" msgid="4589508026407318374">"Phone is getting warm"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Some features limited while phone cools down"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Your phone will automatically try to cool down. You can still use your phone, but it may run more slowly.\n\nOnce your phone has cooled down, it will run normally."</string> diff --git a/packages/SystemUI/res/values-es-rUS/strings.xml b/packages/SystemUI/res/values-es-rUS/strings.xml index 1c4d42ad94a5..a1fa331eb515 100644 --- a/packages/SystemUI/res/values-es-rUS/strings.xml +++ b/packages/SystemUI/res/values-es-rUS/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Atrás"</string> <string name="accessibility_home" msgid="8217216074895377641">"Página principal"</string> <string name="accessibility_menu" msgid="316839303324695949">"Menú"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Recientes"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Buscar"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Cámara"</string> @@ -673,8 +675,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Página <xliff:g id="ID_1">%1$d</xliff:g> de <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Expandir"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Minimizar"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Cerrar"</string> <string name="high_temp_title" msgid="4589508026407318374">"El teléfono se está calentando"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Se limitarán algunas funciones mientras se enfría el teléfono"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Tu teléfono intentará enfriarse automáticamente. Podrás usarlo, pero es posible que funcione más lento.\n\nUna vez que se haya enfriado, volverá a funcionar correctamente."</string> diff --git a/packages/SystemUI/res/values-es/strings.xml b/packages/SystemUI/res/values-es/strings.xml index 28299b7acf12..50a1b1d38c07 100644 --- a/packages/SystemUI/res/values-es/strings.xml +++ b/packages/SystemUI/res/values-es/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Atrás"</string> <string name="accessibility_home" msgid="8217216074895377641">"Inicio"</string> <string name="accessibility_menu" msgid="316839303324695949">"Menú"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Aplicaciones recientes"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Buscar"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Cámara"</string> @@ -673,8 +675,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Página <xliff:g id="ID_1">%1$d</xliff:g> de <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Mostrar"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Minimizar"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Cerrar"</string> <string name="high_temp_title" msgid="4589508026407318374">"El teléfono se está calentando"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Se limitan algunas funciones mientras el teléfono se enfría"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"El teléfono intentará enfriarse. Puedes seguir utilizándolo, pero es posible que funcione con mayor lentitud.\n\nUna vez que se haya enfriado, funcionará con normalidad."</string> diff --git a/packages/SystemUI/res/values-et/strings.xml b/packages/SystemUI/res/values-et/strings.xml index 9a888c55dc20..1c40495f7f1b 100644 --- a/packages/SystemUI/res/values-et/strings.xml +++ b/packages/SystemUI/res/values-et/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Tagasi"</string> <string name="accessibility_home" msgid="8217216074895377641">"Kodu"</string> <string name="accessibility_menu" msgid="316839303324695949">"Menüü"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Ülevaade"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Otsing"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Kaamera"</string> @@ -673,8 +675,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Leht <xliff:g id="ID_1">%1$d</xliff:g>/<xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Laiendamine"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Minimeeri"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Sule"</string> <string name="high_temp_title" msgid="4589508026407318374">"Telefon soojeneb"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Mõned funktsioonid on piiratud, kuni telefon jahtub"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Teie telefon proovib automaatselt maha jahtuda. Saate telefoni ikka kasutada, kuid see võib olla aeglasem.\n\nKui telefon on jahtunud, töötab see tavapäraselt."</string> diff --git a/packages/SystemUI/res/values-eu/strings.xml b/packages/SystemUI/res/values-eu/strings.xml index 45ec067e55d9..241c9aa5b79c 100644 --- a/packages/SystemUI/res/values-eu/strings.xml +++ b/packages/SystemUI/res/values-eu/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Atzera"</string> <string name="accessibility_home" msgid="8217216074895377641">"Hasiera"</string> <string name="accessibility_menu" msgid="316839303324695949">"Menua"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Ikuspegi orokorra"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Bilatu"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Kamera"</string> @@ -673,8 +675,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"<xliff:g id="ID_1">%1$d</xliff:g>/<xliff:g id="ID_2">%2$d</xliff:g> orria"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Zabaldu"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Minimizatu"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Itxi"</string> <string name="high_temp_title" msgid="4589508026407318374">"Berotzen ari da telefonoa"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Eginbide batzuk ezingo dira erabili telefonoa hoztu arte"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Telefonoa automatikoki saiatuko da hozten. Hoztu bitartean, telefonoa erabiltzen jarrai dezakezu, baina mantsoago funtziona lezake.\n\nTelefonoaren tenperatura jaitsi bezain laster, ohi bezala funtzionatzen jarraituko du."</string> diff --git a/packages/SystemUI/res/values-fa/strings.xml b/packages/SystemUI/res/values-fa/strings.xml index cd125b566284..08ad029f2b11 100644 --- a/packages/SystemUI/res/values-fa/strings.xml +++ b/packages/SystemUI/res/values-fa/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"برگشت"</string> <string name="accessibility_home" msgid="8217216074895377641">"صفحهٔ اصلی"</string> <string name="accessibility_menu" msgid="316839303324695949">"منو"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"نمای کلی"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"جستجو"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"دوربین"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"صفحه <xliff:g id="ID_1">%1$d</xliff:g> از <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"بزرگ کردن"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"کوچک کردن"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"بستن"</string> <string name="high_temp_title" msgid="4589508026407318374">"تلفن درحال گرم شدن است"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"وقتی تلفن درحال خنک شدن است، بعضی از قابلیتها محدود میشوند"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"تلفنتان بهطور خودکار سعی میکند خنک شود. همچنان میتوانید از تلفنتان استفاده کنید، اما ممکن است کندتر عمل کند.\n\nوقتی تلفن خنک شد، عملکرد عادیاش از سرگرفته میشود."</string> diff --git a/packages/SystemUI/res/values-fi/strings.xml b/packages/SystemUI/res/values-fi/strings.xml index 623ee51ebe0c..36bf5425a001 100644 --- a/packages/SystemUI/res/values-fi/strings.xml +++ b/packages/SystemUI/res/values-fi/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Takaisin"</string> <string name="accessibility_home" msgid="8217216074895377641">"Aloituspainike"</string> <string name="accessibility_menu" msgid="316839303324695949">"Valikko"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Viimeisimmät"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Haku"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Kamera"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Sivu <xliff:g id="ID_1">%1$d</xliff:g>/<xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Laajenna"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Pienennä"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Sulje"</string> <string name="high_temp_title" msgid="4589508026407318374">"Puhelin lämpenee"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Joidenkin ominaisuuksien käyttöä on rajoitettu puhelimen jäähtymisen aikana."</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Puhelimesi yrittää automaattisesti jäähdyttää itsensä. Voit silti käyttää puhelinta, mutta se voi toimia hitaammin.\n\nKun puhelin on jäähtynyt, se toimii normaalisti."</string> diff --git a/packages/SystemUI/res/values-fr-rCA/strings.xml b/packages/SystemUI/res/values-fr-rCA/strings.xml index 5d4867c0d27b..3ffb1fa4f9d2 100644 --- a/packages/SystemUI/res/values-fr-rCA/strings.xml +++ b/packages/SystemUI/res/values-fr-rCA/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Précédent"</string> <string name="accessibility_home" msgid="8217216074895377641">"Domicile"</string> <string name="accessibility_menu" msgid="316839303324695949">"Menu"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Aperçu"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Rechercher"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Appareil photo"</string> @@ -673,8 +675,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Page <xliff:g id="ID_1">%1$d</xliff:g> sur <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Développer"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Réduire"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Fermer"</string> <string name="high_temp_title" msgid="4589508026407318374">"Le téléphone commence à chauffer"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Les fonctionnalités sont limitées pendant que le téléphone refroidit"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Votre téléphone va essayer de se refroidir automatiquement. Vous pouvez toujours l\'utiliser, mais il risque d\'être plus lent.\n\nUne fois refroidi, il fonctionnera normalement."</string> @@ -685,7 +686,6 @@ <string name="lockscreen_unlock" msgid="4934466194763269051">"Demander le mot de passe"</string> <string name="notification_channel_alerts" msgid="4496839309318519037">"Alertes"</string> <string name="notification_channel_screenshot" msgid="6314080179230000938">"Saisies d\'écran"</string> - <!-- no translation found for notification_channel_general (4525309436693914482) --> - <skip /> + <string name="notification_channel_general" msgid="4525309436693914482">"Messages généraux"</string> <string name="notification_channel_storage" msgid="3077205683020695313">"Stockage"</string> </resources> diff --git a/packages/SystemUI/res/values-fr/strings.xml b/packages/SystemUI/res/values-fr/strings.xml index 97748a2b6d4a..61c5a07be438 100644 --- a/packages/SystemUI/res/values-fr/strings.xml +++ b/packages/SystemUI/res/values-fr/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Retour"</string> <string name="accessibility_home" msgid="8217216074895377641">"Accueil"</string> <string name="accessibility_menu" msgid="316839303324695949">"Menu"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Aperçu"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Rechercher"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Appareil photo"</string> @@ -673,8 +675,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Page <xliff:g id="ID_1">%1$d</xliff:g> sur <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Développer"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Réduire"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Fermer"</string> <string name="high_temp_title" msgid="4589508026407318374">"Le téléphone chauffe"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Fonctionnalités limitées pendant le refroidissement du téléphone"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Votre téléphone va essayer de se refroidir automatiquement. Vous pouvez toujours l\'utiliser, mais il risque d\'être plus lent.\n\nUne fois refroidi, il fonctionnera normalement."</string> diff --git a/packages/SystemUI/res/values-gl/strings.xml b/packages/SystemUI/res/values-gl/strings.xml index 5821bb96a0c5..14d00ef5ec45 100644 --- a/packages/SystemUI/res/values-gl/strings.xml +++ b/packages/SystemUI/res/values-gl/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Volver"</string> <string name="accessibility_home" msgid="8217216074895377641">"Inicio"</string> <string name="accessibility_menu" msgid="316839303324695949">"Menú"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Visión xeral"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Buscar"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Cámara"</string> @@ -673,8 +675,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Páxina <xliff:g id="ID_1">%1$d</xliff:g> de <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Despregar"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Minimizar"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Pechar"</string> <string name="high_temp_title" msgid="4589508026407318374">"O teléfono está quentando"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"O uso dalgunhas funcións é limitado mentres o teléfono arrefría"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"O teléfono tentará arrefriar automaticamente. Podes utilizalo, pero é probable que funcione máis lento.\n\nUnha vez que arrefríe, funcionará con normalidade."</string> diff --git a/packages/SystemUI/res/values-gu/strings.xml b/packages/SystemUI/res/values-gu/strings.xml index 5fedb2dbceba..979a2bbfeabe 100644 --- a/packages/SystemUI/res/values-gu/strings.xml +++ b/packages/SystemUI/res/values-gu/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"પાછળ"</string> <string name="accessibility_home" msgid="8217216074895377641">"હોમ"</string> <string name="accessibility_menu" msgid="316839303324695949">"મેનુ"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"વિહંગાવલોકન"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"શોધો"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"કૅમેરો"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"<xliff:g id="ID_2">%2$d</xliff:g> માંથી <xliff:g id="ID_1">%1$d</xliff:g> પૃષ્ઠ"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"વિસ્તૃત કરો"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"નાનું કરો"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"બંધ કરો"</string> <string name="high_temp_title" msgid="4589508026407318374">"ફોન ગરમ થઈ રહ્યો છે"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"ફોન ઠંડો થાય ત્યાં સુધી કેટલીક સુવિધાઓ મર્યાદિત હોય છે"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"તમારો ફોન આપમેળે ઠંડો થવાનો પ્રયાસ કરશે. તમે હજી પણ તમારા ફોનનો ઉપયોગ કરી શકો છો, પરંતુ તે કદાચ થોડો ધીમો ચાલે.\n\nતમારો ફોન ઠંડો થઈ જવા પર, તે સામાન્ય રીતે ચાલશે."</string> diff --git a/packages/SystemUI/res/values-hi/strings.xml b/packages/SystemUI/res/values-hi/strings.xml index b6cba3c34784..29dadd2534e4 100644 --- a/packages/SystemUI/res/values-hi/strings.xml +++ b/packages/SystemUI/res/values-hi/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"वापस जाएं"</string> <string name="accessibility_home" msgid="8217216074895377641">"होम"</string> <string name="accessibility_menu" msgid="316839303324695949">"मेनू"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"अवलोकन"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"खोजें"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"कैमरा"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"पेज <xliff:g id="ID_2">%2$d</xliff:g> में से <xliff:g id="ID_1">%1$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"विस्तृत करें"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"छोटा करें"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"बंद करें"</string> <string name="high_temp_title" msgid="4589508026407318374">"फ़ोन गर्म हो रहा है"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"फ़ोन के ठंडा होने के दौरान कुछ सुविधाएं सीमित होती हैं"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"आपका फ़ोन अपने आप ठंडा होने की कोशिश करेगा. आप अभी भी अपने फ़ोन का उपयोग कर सकते हैं, लेकिन हो सकता है कि यह धीमी गति से चले.\n\nठंडा हो जाने पर आपका फ़ोन सामान्य रूप से चलेगा."</string> diff --git a/packages/SystemUI/res/values-hr/strings.xml b/packages/SystemUI/res/values-hr/strings.xml index 85a744d9292e..b706706fd3ec 100644 --- a/packages/SystemUI/res/values-hr/strings.xml +++ b/packages/SystemUI/res/values-hr/strings.xml @@ -84,6 +84,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Natrag"</string> <string name="accessibility_home" msgid="8217216074895377641">"Početna"</string> <string name="accessibility_menu" msgid="316839303324695949">"Izbornik"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Pregled"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Pretraži"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Fotoaparat"</string> @@ -673,8 +675,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Stranica <xliff:g id="ID_1">%1$d</xliff:g> od <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Proširivanje"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Minimiziraj"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Zatvori"</string> <string name="high_temp_title" msgid="4589508026407318374">"Telefon se zagrijava"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Neke su značajke ograničene dok se telefon hladi"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Telefon će se automatski pokušati ohladiti. Možete ga nastaviti koristiti, no mogao bi raditi sporije.\n\nKad se ohladi, radit će normalno."</string> diff --git a/packages/SystemUI/res/values-hu/strings.xml b/packages/SystemUI/res/values-hu/strings.xml index 81f3d5e158ca..ef573cbc533e 100644 --- a/packages/SystemUI/res/values-hu/strings.xml +++ b/packages/SystemUI/res/values-hu/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Vissza"</string> <string name="accessibility_home" msgid="8217216074895377641">"Főoldal"</string> <string name="accessibility_menu" msgid="316839303324695949">"Menü"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Áttekintés"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Keresés"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Kamera"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"<xliff:g id="ID_1">%1$d</xliff:g>. oldal, összesen: <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Kibontás"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Kis méret"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Bezárás"</string> <string name="high_temp_title" msgid="4589508026407318374">"A telefon melegszik"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Bizonyos funkciók korlátozottan működnek a telefon hűlése közben"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"A telefon automatikusan megpróbál lehűlni. Továbbra is tudja használni a telefont, de elképzelhető, hogy működése lelassul.\n\nAmint a telefon lehűl, újra a szokásos módon működik majd."</string> diff --git a/packages/SystemUI/res/values-hy/strings.xml b/packages/SystemUI/res/values-hy/strings.xml index e5169f255201..ddcbdfe02973 100644 --- a/packages/SystemUI/res/values-hy/strings.xml +++ b/packages/SystemUI/res/values-hy/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Հետ"</string> <string name="accessibility_home" msgid="8217216074895377641">"Տուն"</string> <string name="accessibility_menu" msgid="316839303324695949">"Ցանկ"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Համատեսք"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Որոնել"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Ֆոտոխցիկ"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Էջ <xliff:g id="ID_1">%1$d</xliff:g> / <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Ընդարձակել"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Ծալել"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Փակել"</string> <string name="high_temp_title" msgid="4589508026407318374">"Հեռախոսը տաքանում է"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Հովանալու ընթացքում հեռախոսի որոշ գործառույթներ սահմանափակ են"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Ձեր հեռախոսն ավտոմատ կերպով կփորձի hովանալ: Կարող եք շարունակել օգտագործել հեռախոսը, սակայն հնարավոր է, որ այն ավելի դանդաղ աշխատի:\n\nՀովանալուց հետո հեռախոսը կաշխատի կանոնավոր կերպով:"</string> diff --git a/packages/SystemUI/res/values-in/strings.xml b/packages/SystemUI/res/values-in/strings.xml index a2d38e9faa60..bbd7c90ba9ed 100644 --- a/packages/SystemUI/res/values-in/strings.xml +++ b/packages/SystemUI/res/values-in/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Kembali"</string> <string name="accessibility_home" msgid="8217216074895377641">"Utama"</string> <string name="accessibility_menu" msgid="316839303324695949">"Menu"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Ringkasan"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Telusuri"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Kamera"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Halaman <xliff:g id="ID_1">%1$d</xliff:g> dari <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Luaskan"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Minimalkan"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Tutup"</string> <string name="high_temp_title" msgid="4589508026407318374">"Ponsel menjadi hangat"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Beberapa fitur dibatasi saat ponsel mendingin"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Ponsel akan otomatis mencoba mendingin. Anda tetap dapat menggunakan ponsel, tetapi mungkin berjalan lebih lambat.\n\nSetelah dingin, ponsel akan berjalan seperti biasa."</string> diff --git a/packages/SystemUI/res/values-is/strings.xml b/packages/SystemUI/res/values-is/strings.xml index b0dacfc4162b..d04af35adb51 100644 --- a/packages/SystemUI/res/values-is/strings.xml +++ b/packages/SystemUI/res/values-is/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Til baka"</string> <string name="accessibility_home" msgid="8217216074895377641">"Heim"</string> <string name="accessibility_menu" msgid="316839303324695949">"Valmynd"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Yfirlit"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Leita"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Myndavél"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Blaðsíða <xliff:g id="ID_1">%1$d</xliff:g> af <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Stækka"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Minnka"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Loka"</string> <string name="high_temp_title" msgid="4589508026407318374">"Síminn er að hitna"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Sumir eiginleikar eru takmarkaðir þegar síminn kælir sig"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Síminn reynir sjálfkrafa að kæla sig. Þú getur enn notað símann en hann gæti verið hægvirkari.\n\nEftir að síminn hefur kælt sig niður virkar hann eðlilega."</string> diff --git a/packages/SystemUI/res/values-it/strings.xml b/packages/SystemUI/res/values-it/strings.xml index 8dacab213eab..7b1e117d029e 100644 --- a/packages/SystemUI/res/values-it/strings.xml +++ b/packages/SystemUI/res/values-it/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Indietro"</string> <string name="accessibility_home" msgid="8217216074895377641">"Home"</string> <string name="accessibility_menu" msgid="316839303324695949">"Menu"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Panoramica"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Cerca"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Fotocamera"</string> @@ -673,8 +675,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Pagina <xliff:g id="ID_1">%1$d</xliff:g> di <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Espandi"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Riduci a icona"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Chiudi"</string> <string name="high_temp_title" msgid="4589508026407318374">"Il telefono si sta scaldando"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Alcune funzioni limitate durante il raffreddamento del telefono"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Il telefono cercherà automaticamente di raffreddarsi. Puoi comunque usarlo, ma potrebbe essere più lento.\n\nUna volta raffreddato, il telefono funzionerà normalmente."</string> diff --git a/packages/SystemUI/res/values-iw/strings.xml b/packages/SystemUI/res/values-iw/strings.xml index d39a07aec821..c237fc62bc02 100644 --- a/packages/SystemUI/res/values-iw/strings.xml +++ b/packages/SystemUI/res/values-iw/strings.xml @@ -85,6 +85,8 @@ <string name="accessibility_back" msgid="567011538994429120">"הקודם"</string> <string name="accessibility_home" msgid="8217216074895377641">"בית"</string> <string name="accessibility_menu" msgid="316839303324695949">"תפריט"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"סקירה"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"חפש"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"מצלמה"</string> @@ -675,8 +677,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"דף <xliff:g id="ID_1">%1$d</xliff:g> מתוך <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"הרחב"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"מזער"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"סגור"</string> <string name="high_temp_title" msgid="4589508026407318374">"הטלפון מתחמם"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"חלק מהתכונות מוגבלות כל עוד הטלפון מתקרר"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"קירור הטלפון ייעשה באופן אוטומטי. תוכל עדיין להשתמש בטלפון, אבל ייתכן שהוא יפעל לאט יותר.\n\nהטלפון יחזור לפעול כרגיל לאחר שיתקרר."</string> diff --git a/packages/SystemUI/res/values-ja/strings.xml b/packages/SystemUI/res/values-ja/strings.xml index 9ea02b97a22d..14d1c4230d16 100644 --- a/packages/SystemUI/res/values-ja/strings.xml +++ b/packages/SystemUI/res/values-ja/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"戻る"</string> <string name="accessibility_home" msgid="8217216074895377641">"ホーム"</string> <string name="accessibility_menu" msgid="316839303324695949">"メニュー"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"最近"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"検索"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"カメラ"</string> @@ -673,8 +675,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"ページ <xliff:g id="ID_1">%1$d</xliff:g>/<xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"展開"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"最小化"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"閉じる"</string> <string name="high_temp_title" msgid="4589508026407318374">"スマートフォンの温度が上昇中"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"スマートフォンのクールダウン中は一部の機能が制限されます"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"スマートフォンは自動的にクールダウンを行います。その間もスマートフォンを使用できますが、動作が遅くなる可能性があります。\n\nクールダウンが完了すると、通常どおり動作します。"</string> diff --git a/packages/SystemUI/res/values-ka/strings.xml b/packages/SystemUI/res/values-ka/strings.xml index 30b503e48701..38c52fc0ac97 100644 --- a/packages/SystemUI/res/values-ka/strings.xml +++ b/packages/SystemUI/res/values-ka/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"უკან"</string> <string name="accessibility_home" msgid="8217216074895377641">"საწყისი"</string> <string name="accessibility_menu" msgid="316839303324695949">"მენიუ"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"მიმოხილვა"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"ძიება"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"კამერა"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"გვერდი <xliff:g id="ID_1">%1$d</xliff:g> / <xliff:g id="ID_2">%2$d</xliff:g>-დან"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"გაშლა"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"ჩაკეცვა"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"დახურვა"</string> <string name="high_temp_title" msgid="4589508026407318374">"ტელეფონი ცხელდება"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"ზოგიერთი ფუნქცია შეზღუდული იქნება, სანამ ტელეფონი გაგრილდება"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"თქვენი ტელეფონი გაგრილებას ავტომატურად შეეცდება. შეგიძლიათ გააგრძელოთ მისით სარგებლობა, თუმცა ტელეფონმა შეიძლება უფრო ნელა იმუშაოს.\n\nგაგრილების შემდგომ ის ჩვეულებრივად იმუშავებს."</string> diff --git a/packages/SystemUI/res/values-kk/strings.xml b/packages/SystemUI/res/values-kk/strings.xml index cfcd2ec102fc..0a8f3e703674 100644 --- a/packages/SystemUI/res/values-kk/strings.xml +++ b/packages/SystemUI/res/values-kk/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Артқа"</string> <string name="accessibility_home" msgid="8217216074895377641">"Үй"</string> <string name="accessibility_menu" msgid="316839303324695949">"Mәзір"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Шолу"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Іздеу"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Камера"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"<xliff:g id="ID_2">%2$d</xliff:g> ішінен <xliff:g id="ID_1">%1$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Жаю"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Кішірейту"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Жабу"</string> <string name="high_temp_title" msgid="4589508026407318374">"Телефон қызуда"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Телефон толық суығанға дейін, кейбір функциялардың жұмысы шектеледі"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Телефон автоматты түрде суи бастайды. Оны пайдалана бере аласыз, бірақ ол баяуырақ жұмыс істеуі мүмкін.\n\nТелефон суығаннан кейін, оның жұмысы қалпына келеді."</string> diff --git a/packages/SystemUI/res/values-km/strings.xml b/packages/SystemUI/res/values-km/strings.xml index a958258e1d5e..062162392a7e 100644 --- a/packages/SystemUI/res/values-km/strings.xml +++ b/packages/SystemUI/res/values-km/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"ថយក្រោយ"</string> <string name="accessibility_home" msgid="8217216074895377641">"គេហទំព័រ"</string> <string name="accessibility_menu" msgid="316839303324695949">"ម៉ឺនុយ"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"ទិដ្ឋភាព"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"ស្វែងរក"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"ម៉ាស៊ីនថត"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"ទំព័រ <xliff:g id="ID_1">%1$d</xliff:g> នៃ <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"ពង្រីក"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"បង្រួម"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"បិទ"</string> <string name="high_temp_title" msgid="4589508026407318374">"ទូរសព្ទនេះកំពុងកើនកម្តៅ"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"មុខងារមួយចំនួននឹងមិនអាចប្រើបានពេញលេញនោះទេ ខណៈពេលដែលទូរសព្ទកំពុងបញ្ចុះកម្តៅ"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"ទូរសព្ទរបស់អ្នកនឹងព្យាយាមបញ្ចុះកម្តៅដោយស្វ័យប្រវត្តិ។ អ្នកនៅតែអាចប្រើទូរសព្ទរបស់អ្នកបានដដែល ប៉ុន្តែវានឹងដំណើរការយឺតជាងមុន។\n\nបន្ទាប់ពីទូរសព្ទរបស់អ្នកត្រជាក់ជាងមុនហើយ វានឹងដំណើរការដូចធម្មតា។"</string> diff --git a/packages/SystemUI/res/values-kn/strings.xml b/packages/SystemUI/res/values-kn/strings.xml index ba681db62f6c..79c56952bb72 100644 --- a/packages/SystemUI/res/values-kn/strings.xml +++ b/packages/SystemUI/res/values-kn/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"ಹಿಂದೆ"</string> <string name="accessibility_home" msgid="8217216074895377641">"ಮುಖಪುಟ"</string> <string name="accessibility_menu" msgid="316839303324695949">"ಮೆನು"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"ಸಮಗ್ರ ನೋಟ"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"ಹುಡುಕಿ"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"ಕ್ಯಾಮರಾ"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"<xliff:g id="ID_2">%2$d</xliff:g> ರಲ್ಲಿ <xliff:g id="ID_1">%1$d</xliff:g> ಪುಟ"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"ವಿಸ್ತೃತಗೊಳಿಸು"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"ಕುಗ್ಗಿಸಿ"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"ಮುಚ್ಚಿ"</string> <string name="high_temp_title" msgid="4589508026407318374">"ಫೋನ್ ಬಿಸಿಯಾಗುತ್ತಿದೆ"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"ಫೋನ್ ತಣ್ಣಗಾಗುವವರೆಗೂ ಕೆಲವು ವೈಶಿಷ್ಟ್ಯಗಳನ್ನು ಸೀಮಿತಗೊಳಿಸುತ್ತದೆ"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"ನಿಮ್ಮ ಫೋನ್ ಸ್ವಯಂಚಾಲಿತವಾಗಿ ತಣ್ಣಗಾಗಲು ಪ್ರಯತ್ನಿಸುತ್ತದೆ. ನಿಮ್ಮ ಫೋನ್ ಅನ್ನು ನೀವು ಈಗಲೂ ಬಳಸಬಹುದಾಗಿರುತ್ತದೆ, ಆದರೆ ಇದು ನಿಧಾನವಾಗಿರಬಹುದು.\n\nಒಮ್ಮೆ ನಿಮ್ಮ ಫೋನ್ ತಣ್ಣಗಾದ ನಂತರ ಇದು ಸಾಮಾನ್ಯ ರೀತಿಯಲ್ಲಿ ಕಾರ್ಯನಿರ್ವಹಿಸುತ್ತದೆ."</string> diff --git a/packages/SystemUI/res/values-ko/strings.xml b/packages/SystemUI/res/values-ko/strings.xml index c5faa18ed85c..f7071f8f4d56 100644 --- a/packages/SystemUI/res/values-ko/strings.xml +++ b/packages/SystemUI/res/values-ko/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"뒤로"</string> <string name="accessibility_home" msgid="8217216074895377641">"홈"</string> <string name="accessibility_menu" msgid="316839303324695949">"메뉴"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"최근 사용"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"검색"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"카메라"</string> @@ -673,8 +675,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"<xliff:g id="ID_2">%2$d</xliff:g>페이지 중 <xliff:g id="ID_1">%1$d</xliff:g>페이지"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"펼치기"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"최소화"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"닫기"</string> <string name="high_temp_title" msgid="4589508026407318374">"휴대전화 온도가 높음"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"휴대전화 온도를 낮추는 동안 일부 기능이 제한됩니다."</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"휴대전화 온도를 자동으로 낮추려고 시도합니다. 휴대전화를 계속 사용할 수는 있지만 작동이 느려질 수도 있습니다.\n\n휴대전화 온도가 낮아지면 정상적으로 작동됩니다."</string> diff --git a/packages/SystemUI/res/values-ky/strings.xml b/packages/SystemUI/res/values-ky/strings.xml index 6f57a7355421..aca37b6b3f89 100644 --- a/packages/SystemUI/res/values-ky/strings.xml +++ b/packages/SystemUI/res/values-ky/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Артка"</string> <string name="accessibility_home" msgid="8217216074895377641">"Үйгө"</string> <string name="accessibility_menu" msgid="316839303324695949">"Меню"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Көз жүгүртүү"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Издөө"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Камера"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"<xliff:g id="ID_2">%2$d</xliff:g> ичинен <xliff:g id="ID_1">%1$d</xliff:g>-бет"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Жайып көрсөтүү"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Кичирейтүү"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Жабуу"</string> <string name="high_temp_title" msgid="4589508026407318374">"Телефонуңуз ысып баратат"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Телефон сууганча айрым элементтердин иши чектелген"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Телефонуңуз автоматтык түрдө сууйт. Аны колдоно берсеңиз болот, бирок ал жайыраак иштеп калат.\n\nТелефонуңуз суугандан кийин адаттагыдай эле иштеп баштайт."</string> diff --git a/packages/SystemUI/res/values-lo/strings.xml b/packages/SystemUI/res/values-lo/strings.xml index c7475bc61264..4c7aafa4a542 100644 --- a/packages/SystemUI/res/values-lo/strings.xml +++ b/packages/SystemUI/res/values-lo/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"ກັບຄືນ"</string> <string name="accessibility_home" msgid="8217216074895377641">"ໜ້າທຳອິດ"</string> <string name="accessibility_menu" msgid="316839303324695949">"ເມນູ"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"ພາບຮວມ"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"ຊອກຫາ"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"ກ້ອງ"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"<xliff:g id="ID_1">%1$d</xliff:g> ຈາກທັງໝົດ <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"ຂະຫຍາຍ"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"ຫຍໍ້"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"ປິດ"</string> <string name="high_temp_title" msgid="4589508026407318374">"ໂທລະສັບກຳລັງຮ້ອນຂຶ້ນ"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"ຄຸນສົມບັດບາງຢ່າງຖືກຈຳກັດໄວ້ເນື່ອງໃນເວລາຫຼຸດອຸນຫະພູມຂອງໂທລະສັບ"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"ໂທລະສັບຂອງທ່ານຈະພະຍາຍາມລົດອຸນຫະພູມລົງ. ທ່ານຍັງຄົງສາມາດໃຊ້ໂທລະສັບຂອງທ່ານໄດ້ຢູ່, ແຕ່ມັນຈະເຮັດວຽກຊ້າລົງ.\n\nເມື່ອໂທລະສັບຂອງທ່ານບໍ່ຮ້ອນຫຼາຍແລ້ວ, ມັນຈະກັບມາເຮັດວຽກຕາມປົກກະຕິ."</string> diff --git a/packages/SystemUI/res/values-lt/strings.xml b/packages/SystemUI/res/values-lt/strings.xml index e6713f2ba207..9438368c30c8 100644 --- a/packages/SystemUI/res/values-lt/strings.xml +++ b/packages/SystemUI/res/values-lt/strings.xml @@ -85,6 +85,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Atgal"</string> <string name="accessibility_home" msgid="8217216074895377641">"Pagrindinis"</string> <string name="accessibility_menu" msgid="316839303324695949">"Meniu"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Apžvalga"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Ieškoti"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Fotoaparatas"</string> @@ -675,8 +677,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"<xliff:g id="ID_1">%1$d</xliff:g> psl. iš <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Išskleisti"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Sumažinti"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Uždaryti"</string> <string name="high_temp_title" msgid="4589508026407318374">"Telefonas kaista"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Kai kurios funkcijos gali neveikti, kol telefonas vėsta"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Telefonas automatiškai bandys atvėsti. Telefoną vis tiek galėsite naudoti, tačiau jis gali veikti lėčiau.\n\nKai telefonas atvės, jis veiks įprastai."</string> diff --git a/packages/SystemUI/res/values-lv/strings.xml b/packages/SystemUI/res/values-lv/strings.xml index ba6ce3c040f0..29b227a0cd4c 100644 --- a/packages/SystemUI/res/values-lv/strings.xml +++ b/packages/SystemUI/res/values-lv/strings.xml @@ -84,6 +84,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Atpakaļ"</string> <string name="accessibility_home" msgid="8217216074895377641">"Sākums"</string> <string name="accessibility_menu" msgid="316839303324695949">"Izvēlne"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Pārskats"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Meklēt"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Kamera"</string> @@ -673,8 +675,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"<xliff:g id="ID_1">%1$d</xliff:g>. lpp. no <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Izvērst"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Minimizēt"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Aizvērt"</string> <string name="high_temp_title" msgid="4589508026407318374">"Tālrunis kļūst silts"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Dažas funkcijas ir ierobežotas, kamēr tālrunis mēģina atdzist"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Jūsu tālrunis automātiski mēģinās atdzist. Jūs joprojām varat izmantot tālruni, taču tas, iespējams, darbosies lēnāk.\n\nTiklīdz tālrunis būs atdzisis, tas darbosies normāli."</string> diff --git a/packages/SystemUI/res/values-mk/strings.xml b/packages/SystemUI/res/values-mk/strings.xml index 5308d657dc17..91bfd35768e6 100644 --- a/packages/SystemUI/res/values-mk/strings.xml +++ b/packages/SystemUI/res/values-mk/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Назад"</string> <string name="accessibility_home" msgid="8217216074895377641">"Почетна страница"</string> <string name="accessibility_menu" msgid="316839303324695949">"Мени"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Краток преглед"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Пребарај"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Камера"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Страница <xliff:g id="ID_1">%1$d</xliff:g> од <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Проширете"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Минимизирај"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Затвори"</string> <string name="high_temp_title" msgid="4589508026407318374">"Телефонот се загрева"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Некои функции се ограничени додека телефонот се лади"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Телефонот автоматски ќе се обиде да се олади. Вие сепак ќе може да го користите, но тој може да работи побавно.\n\nОткако ќе се олади, ќе работи нормално."</string> diff --git a/packages/SystemUI/res/values-ml/strings.xml b/packages/SystemUI/res/values-ml/strings.xml index cf32631a1d35..5fd50226674c 100644 --- a/packages/SystemUI/res/values-ml/strings.xml +++ b/packages/SystemUI/res/values-ml/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"മടങ്ങുക"</string> <string name="accessibility_home" msgid="8217216074895377641">"ഹോം"</string> <string name="accessibility_menu" msgid="316839303324695949">"മെനു"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"കാഴ്ച"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"തിരയൽ"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"ക്യാമറ"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"പേജ് <xliff:g id="ID_1">%1$d</xliff:g> / <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"വികസിപ്പിക്കുക"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"ചെറുതാക്കുക"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"അടയ്ക്കുക"</string> <string name="high_temp_title" msgid="4589508026407318374">"ഫോൺ ചൂടായിക്കൊണ്ടിരിക്കുന്നു"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"ഫോൺ തണുത്തുകൊണ്ടിരിക്കുമ്പോൾ ചില ഫീച്ചറുകൾ പരിമിതപ്പെടുത്തപ്പെടും"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"നിങ്ങളുടെ ഫോൺ സ്വയമേവ തണുക്കാൻ ശ്രമിക്കും. നിങ്ങൾക്ക് അപ്പോഴും ഫോൺ ഉപയോഗിക്കാമെങ്കിലും പ്രവർത്തനം മന്ദഗതിയിലായിരിക്കും.\n\nതണുത്തുകഴിഞ്ഞാൽ, ഫോൺ സാധാരണ ഗതിയിൽ പ്രവർത്തിക്കും."</string> @@ -683,7 +684,6 @@ <string name="lockscreen_unlock" msgid="4934466194763269051">"പാസ്വേഡ് ആവശ്യപ്പെടുക"</string> <string name="notification_channel_alerts" msgid="4496839309318519037">"അലേർട്ടുകൾ"</string> <string name="notification_channel_screenshot" msgid="6314080179230000938">"സ്ക്രീൻഷോട്ടുകൾ"</string> - <!-- no translation found for notification_channel_general (4525309436693914482) --> - <skip /> + <string name="notification_channel_general" msgid="4525309436693914482">"പൊതുവായ സന്ദേശങ്ങൾ"</string> <string name="notification_channel_storage" msgid="3077205683020695313">"സ്റ്റോറേജ്"</string> </resources> diff --git a/packages/SystemUI/res/values-mn/strings.xml b/packages/SystemUI/res/values-mn/strings.xml index 336429f159e5..1c0d8ea9d3cc 100644 --- a/packages/SystemUI/res/values-mn/strings.xml +++ b/packages/SystemUI/res/values-mn/strings.xml @@ -81,6 +81,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Буцах"</string> <string name="accessibility_home" msgid="8217216074895377641">"Гэрийн"</string> <string name="accessibility_menu" msgid="316839303324695949">"Цэс"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Тойм"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Хайх"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Камер"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"<xliff:g id="ID_2">%2$d</xliff:g>-н <xliff:g id="ID_1">%1$d</xliff:g>-р хуудас"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Дэлгэх"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Багасгах"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Хаах"</string> <string name="high_temp_title" msgid="4589508026407318374">"Утас халж эхэлж байна"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Таны утас хөрж байх зуур зарим онцлогийг хязгаарласан"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Таны утас автоматаар хөрөх болно. Та утсаа ашиглаж болох хэдий ч удаан ажиллаж болзошгүй.\n\nТаны утас хөрсний дараагаар хэвийн ажиллана."</string> diff --git a/packages/SystemUI/res/values-mr/strings.xml b/packages/SystemUI/res/values-mr/strings.xml index 7b09c9d44241..47679c7a6f36 100644 --- a/packages/SystemUI/res/values-mr/strings.xml +++ b/packages/SystemUI/res/values-mr/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"परत"</string> <string name="accessibility_home" msgid="8217216074895377641">"मुख्यपृष्ठ"</string> <string name="accessibility_menu" msgid="316839303324695949">"मेनू"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"विहंगावलोकन"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"शोधा"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"कॅमेरा"</string> @@ -683,7 +685,6 @@ <string name="lockscreen_unlock" msgid="4934466194763269051">"संकेतशब्दासाठी संकेत"</string> <string name="notification_channel_alerts" msgid="4496839309318519037">"सूचना"</string> <string name="notification_channel_screenshot" msgid="6314080179230000938">"स्क्रीनशॉट"</string> - <!-- no translation found for notification_channel_general (4525309436693914482) --> - <skip /> + <string name="notification_channel_general" msgid="4525309436693914482">"सर्वसाधारण संदेश"</string> <string name="notification_channel_storage" msgid="3077205683020695313">"संचय"</string> </resources> diff --git a/packages/SystemUI/res/values-ms/strings.xml b/packages/SystemUI/res/values-ms/strings.xml index 9ba75b224b4f..7ed12dc17b36 100644 --- a/packages/SystemUI/res/values-ms/strings.xml +++ b/packages/SystemUI/res/values-ms/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Kembali"</string> <string name="accessibility_home" msgid="8217216074895377641">"Rumah"</string> <string name="accessibility_menu" msgid="316839303324695949">"Menu"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Ikhtisar"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Cari"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Kamera"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Halaman <xliff:g id="ID_1">%1$d</xliff:g> daripada <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Kembangkan"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Minimumkan"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Tutup"</string> <string name="high_temp_title" msgid="4589508026407318374">"Telefon semakin panas"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Sesetengah ciri adalah terhad semasa telefon menyejuk"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Telefon anda akan cuba menyejuk secara automatik. Anda masih dapat menggunakan telefon itu tetapi telefon tersebut mungkin berjalan lebih perlahan.\n\nSetelah telefon anda sejuk, telefon itu akan berjalan seperti biasa."</string> diff --git a/packages/SystemUI/res/values-my/strings.xml b/packages/SystemUI/res/values-my/strings.xml index 32ff25dcbdfa..c2b1e59ac9db 100644 --- a/packages/SystemUI/res/values-my/strings.xml +++ b/packages/SystemUI/res/values-my/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"နောက်သို့"</string> <string name="accessibility_home" msgid="8217216074895377641">"ပင်မစာမျက်နှာ"</string> <string name="accessibility_menu" msgid="316839303324695949">"မီနူး"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"ခြုံကြည့်မှု။"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"ရှာဖွေရန်"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"ကင်မရာ"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"စာမျက်နှာ <xliff:g id="ID_2">%2$d</xliff:g> အနက်မှ စာမျက်နှာ <xliff:g id="ID_1">%1$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"ချဲ့ရန်"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"ချုံ့ရန်"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"ပိတ်ရန်"</string> <string name="high_temp_title" msgid="4589508026407318374">"ဖုန်း ပူနွေးလာပါပြီ"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"ဖုန်းကို အေးအောင်ပြုလုပ်နေစဉ်တွင် အချို့ဝန်ဆောင်မှုများကို ကန့်သတ်ထားပါသည်"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"သင့်ဖုန်းသည် အလိုအလျောက် ပြန်အေးသွားပါလိမ့်မည်။ ဖုန်းကို အသုံးပြုနိုင်ပါသေးသည် သို့သော် ပိုနှေးနိုင်ပါသည်။\n\nသင့်ဖုန်း အေးသွားသည်နှင့် ပုံမှန်အတိုင်း ပြန်အလုပ်လုပ်ပါလိမ့်မည်။"</string> diff --git a/packages/SystemUI/res/values-nb/strings.xml b/packages/SystemUI/res/values-nb/strings.xml index 66245833a2fa..60dcae8d76c7 100644 --- a/packages/SystemUI/res/values-nb/strings.xml +++ b/packages/SystemUI/res/values-nb/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Tilbake"</string> <string name="accessibility_home" msgid="8217216074895377641">"Startside"</string> <string name="accessibility_menu" msgid="316839303324695949">"Meny"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Oversikt"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Søk"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Kamera"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Side <xliff:g id="ID_1">%1$d</xliff:g> av <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Vis"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Minimer"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Lukk"</string> <string name="high_temp_title" msgid="4589508026407318374">"Telefonen begynner å bli varm"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Enkelte funksjoner er begrenset mens telefonen kjøles ned"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Telefonen din kommer til å prøve å kjøle seg ned automatisk. Du kan fremdeles bruke telefonen, men den kjører muligens saktere.\n\nTelefonen kommer til å kjøre som normalt, når den har kjølt seg ned."</string> diff --git a/packages/SystemUI/res/values-ne/strings.xml b/packages/SystemUI/res/values-ne/strings.xml index ee0499280c5a..ad450bab7312 100644 --- a/packages/SystemUI/res/values-ne/strings.xml +++ b/packages/SystemUI/res/values-ne/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"पछाडि"</string> <string name="accessibility_home" msgid="8217216074895377641">"गृह"</string> <string name="accessibility_menu" msgid="316839303324695949">"मेनु"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"सारांश"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"खोज्नुहोस्"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"क्यामेरा"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"<xliff:g id="ID_2">%2$d</xliff:g> मध्ये पृष्ठ <xliff:g id="ID_1">%1$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"विस्तृत गर्नुहोस्"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"सानो बनाउनुहोस्"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"बन्द गर्नुहोस्"</string> <string name="high_temp_title" msgid="4589508026407318374">"फोन तातो भइरहेको छ"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"फोन चिसो हुँदै गर्दा केही विशेषताहरूलाई सीमित गरिन्छ"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"तपाईंको फोन स्वतः चिसो हुने प्रयास गर्नेछ। तपाईं अझै पनि आफ्नो फोनको प्रयोग गर्न सक्नुहुन्छ तर त्यो अझ ढिलो चल्न सक्छ।\n\nचिसो भएपछि तपाईंको फोन सामान्य गतिमा चल्नेछ।"</string> @@ -683,7 +684,6 @@ <string name="lockscreen_unlock" msgid="4934466194763269051">"पासवर्ड माग्ने"</string> <string name="notification_channel_alerts" msgid="4496839309318519037">"अलर्टहरू"</string> <string name="notification_channel_screenshot" msgid="6314080179230000938">"स्क्रिनशटहरू"</string> - <!-- no translation found for notification_channel_general (4525309436693914482) --> - <skip /> + <string name="notification_channel_general" msgid="4525309436693914482">"सामान्य सन्देशहरू"</string> <string name="notification_channel_storage" msgid="3077205683020695313">"भण्डारण"</string> </resources> diff --git a/packages/SystemUI/res/values-nl/strings.xml b/packages/SystemUI/res/values-nl/strings.xml index f4c306a55854..398f39d2e6ff 100644 --- a/packages/SystemUI/res/values-nl/strings.xml +++ b/packages/SystemUI/res/values-nl/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Terug"</string> <string name="accessibility_home" msgid="8217216074895377641">"Homepage"</string> <string name="accessibility_menu" msgid="316839303324695949">"Menu"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Overzicht"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Zoeken"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Camera"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Pagina <xliff:g id="ID_1">%1$d</xliff:g> van <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Uitvouwen"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Minimaliseren"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Sluiten"</string> <string name="high_temp_title" msgid="4589508026407318374">"De telefoon wordt warm"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Bepaalde functies zijn beperkt terwijl de telefoon afkoelt"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Je telefoon probeert automatisch af te koelen. Je kunt je telefoon nog steeds gebruiken, maar deze kan langzamer werken.\n\nZodra de telefoon is afgekoeld, werkt deze weer normaal."</string> diff --git a/packages/SystemUI/res/values-pa/strings.xml b/packages/SystemUI/res/values-pa/strings.xml index 97ec2f165f19..c06dfde1d93e 100644 --- a/packages/SystemUI/res/values-pa/strings.xml +++ b/packages/SystemUI/res/values-pa/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"ਪਿੱਛੇ"</string> <string name="accessibility_home" msgid="8217216074895377641">"ਘਰ"</string> <string name="accessibility_menu" msgid="316839303324695949">"ਮੀਨੂ"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"ਰੂਪ-ਰੇਖਾ"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"ਖੋਜੋ"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"ਕੈਮਰਾ"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"<xliff:g id="ID_2">%2$d</xliff:g> ਦਾ <xliff:g id="ID_1">%1$d</xliff:g> ਪੰਨਾ"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"ਵਿਸਤਾਰ ਕਰੋ"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"ਛੋਟਾ ਕਰੋ"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"ਬੰਦ ਕਰੋ"</string> <string name="high_temp_title" msgid="4589508026407318374">"ਫ਼ੋਨ ਗਰਮ ਹੋ ਰਿਹਾ ਹੈ"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"ਫ਼ੋਨ ਦੇ ਠੰਡਾ ਹੋਣ ਦੇ ਦੌਰਾਨ ਕੁਝ ਵਿਸ਼ੇਸ਼ਤਾਵਾਂ ਸੀਮਿਤ ਹੁੰਦੀਆਂ ਹਨ"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"ਤੁਹਾਡਾ ਫ਼ੋਨ ਸਵੈਚਲਿਤ ਰੂਪ ਵਿੱਚ ਠੰਡਾ ਹੋਣ ਦੀ ਕੋਸ਼ਿਸ਼ ਕਰੇਗਾ। ਤੁਸੀਂ ਹਾਲੇ ਵੀ ਆਪਣੇ ਫ਼ੋਨ ਨੂੰ ਵਰਤ ਸਕਦੇ ਹੋ, ਪਰੰਤੂ ਹੋ ਸਕਦਾ ਹੈ ਕਿ ਇਹ ਵਧੇਰੇ ਹੌਲੀ ਚੱਲੇ।\n\nਇੱਕ ਵਾਰ ਠੰਡਾ ਹੋਣ ਤੋਂ ਬਾਅਦ ਤੁਹਾਡਾ ਫ਼ੋਨ ਸਧਾਰਨ ਤੌਰ \'ਤੇ ਚੱਲੇਗਾ।"</string> diff --git a/packages/SystemUI/res/values-pl/strings.xml b/packages/SystemUI/res/values-pl/strings.xml index 04efcd4a9fb2..b93ef4429cd1 100644 --- a/packages/SystemUI/res/values-pl/strings.xml +++ b/packages/SystemUI/res/values-pl/strings.xml @@ -85,6 +85,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Wróć"</string> <string name="accessibility_home" msgid="8217216074895377641">"Ekran główny"</string> <string name="accessibility_menu" msgid="316839303324695949">"Menu"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Przegląd"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Szukaj"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Aparat"</string> @@ -675,8 +677,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Strona <xliff:g id="ID_1">%1$d</xliff:g> z <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Rozwiń"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Minimalizuj"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Zamknij"</string> <string name="high_temp_title" msgid="4589508026407318374">"Telefon się nagrzewa"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Podczas obniżania temperatury telefonu niektóre funkcje są ograniczone"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Telefon automatycznie podejmie próbę obniżenia temperatury. Możesz go wciąż używać, ale telefon może działać wolniej.\n\nGdy temperatura się obniży, telefon będzie działał normalnie."</string> diff --git a/packages/SystemUI/res/values-pt-rBR/strings.xml b/packages/SystemUI/res/values-pt-rBR/strings.xml index e5a875474f1f..9414a87051d5 100644 --- a/packages/SystemUI/res/values-pt-rBR/strings.xml +++ b/packages/SystemUI/res/values-pt-rBR/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Voltar"</string> <string name="accessibility_home" msgid="8217216074895377641">"Página inicial"</string> <string name="accessibility_menu" msgid="316839303324695949">"Menu"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Visão geral"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Pesquisar"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Câmera"</string> @@ -673,8 +675,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Página <xliff:g id="ID_1">%1$d</xliff:g> de <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Expandir"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Minimizar"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Fechar"</string> <string name="high_temp_title" msgid="4589508026407318374">"O smartphone está esquentando"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Alguns recursos ficam limitados enquanto o smartphone é resfriado"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Seu smartphone tentará se resfriar automaticamente. Você ainda poderá usá-lo, mas talvez ele fique mais lento.\n\nQuando o smartphone estiver resfriado, ele voltará ao normal."</string> diff --git a/packages/SystemUI/res/values-pt-rPT/strings.xml b/packages/SystemUI/res/values-pt-rPT/strings.xml index 4304d9992a0b..f4ff723e3131 100644 --- a/packages/SystemUI/res/values-pt-rPT/strings.xml +++ b/packages/SystemUI/res/values-pt-rPT/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Anterior"</string> <string name="accessibility_home" msgid="8217216074895377641">"Página inicial"</string> <string name="accessibility_menu" msgid="316839303324695949">"Menu"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Visão geral"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Pesquisar"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Câmara"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Página <xliff:g id="ID_1">%1$d</xliff:g> de <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Expandir"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Minimizar"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Fechar"</string> <string name="high_temp_title" msgid="4589508026407318374">"O telemóvel está a aquecer"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Algumas funcionalidades são limitadas enquanto o telemóvel arrefece"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"O telemóvel tenta arrefecer automaticamente. Pode continuar a utilizá-lo, mas este poderá funcionar mais lentamente.\n\nAssim que o telemóvel tiver arrefecido, funcionará normalmente."</string> diff --git a/packages/SystemUI/res/values-pt/strings.xml b/packages/SystemUI/res/values-pt/strings.xml index e5a875474f1f..9414a87051d5 100644 --- a/packages/SystemUI/res/values-pt/strings.xml +++ b/packages/SystemUI/res/values-pt/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Voltar"</string> <string name="accessibility_home" msgid="8217216074895377641">"Página inicial"</string> <string name="accessibility_menu" msgid="316839303324695949">"Menu"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Visão geral"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Pesquisar"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Câmera"</string> @@ -673,8 +675,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Página <xliff:g id="ID_1">%1$d</xliff:g> de <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Expandir"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Minimizar"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Fechar"</string> <string name="high_temp_title" msgid="4589508026407318374">"O smartphone está esquentando"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Alguns recursos ficam limitados enquanto o smartphone é resfriado"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Seu smartphone tentará se resfriar automaticamente. Você ainda poderá usá-lo, mas talvez ele fique mais lento.\n\nQuando o smartphone estiver resfriado, ele voltará ao normal."</string> diff --git a/packages/SystemUI/res/values-ro/strings.xml b/packages/SystemUI/res/values-ro/strings.xml index 535b5c3ea22e..cf1304edd555 100644 --- a/packages/SystemUI/res/values-ro/strings.xml +++ b/packages/SystemUI/res/values-ro/strings.xml @@ -84,6 +84,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Înapoi"</string> <string name="accessibility_home" msgid="8217216074895377641">"Ecranul de pornire"</string> <string name="accessibility_menu" msgid="316839303324695949">"Meniu"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Vizualizare generală"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Căutați"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Cameră foto"</string> @@ -675,8 +677,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Pagina <xliff:g id="ID_1">%1$d</xliff:g> din <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Extindeți"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Minimizați"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Închideți"</string> <string name="high_temp_title" msgid="4589508026407318374">"Telefonul se încălzește"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Anumite funcții sunt limitate în timp ce telefonul se răcește"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Telefonul va încerca automat să se răcească. Puteți folosi telefonul în continuare, dar este posibil să funcționeze mai lent.\n\nDupă ce se răcește, telefonul va funcționa normal."</string> diff --git a/packages/SystemUI/res/values-ru/strings.xml b/packages/SystemUI/res/values-ru/strings.xml index 68d499d1cc2e..e2a1f7484d0c 100644 --- a/packages/SystemUI/res/values-ru/strings.xml +++ b/packages/SystemUI/res/values-ru/strings.xml @@ -85,6 +85,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Назад"</string> <string name="accessibility_home" msgid="8217216074895377641">"Домой"</string> <string name="accessibility_menu" msgid="316839303324695949">"Меню"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Обзор."</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Поиск"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Камера"</string> @@ -677,8 +679,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Страница <xliff:g id="ID_1">%1$d</xliff:g> из <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Развернуть"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Свернуть"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Закрыть"</string> <string name="high_temp_title" msgid="4589508026407318374">"Телефон нагревается"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Пока телефон не остынет, некоторые функции могут быть недоступны."</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Ваш телефон остынет автоматически.\n\nОбратите внимание, что до тех пор он может работать медленнее, чем обычно."</string> diff --git a/packages/SystemUI/res/values-si/strings.xml b/packages/SystemUI/res/values-si/strings.xml index 9c58ba1e3d7a..6ede3da69bf7 100644 --- a/packages/SystemUI/res/values-si/strings.xml +++ b/packages/SystemUI/res/values-si/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"ආපසු"</string> <string name="accessibility_home" msgid="8217216074895377641">"මුල් පිටුව"</string> <string name="accessibility_menu" msgid="316839303324695949">"මෙනුව"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"දළ විශ්ලේෂණය"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"සොයන්න"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"කැමරාව"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"<xliff:g id="ID_2">%2$d</xliff:g> න් <xliff:g id="ID_1">%1$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"දිග හරින්න"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"කුඩා කරන්න"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"වසන්න"</string> <string name="high_temp_title" msgid="4589508026407318374">"දුරකථනය උණුසුම් වෙමින්"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"දුරකථනය සිසිල් වන අතරතුර සමහර විශේෂාංග සීමිත විය හැකිය"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"ඔබගේ දුරකථනය ස්වයංක්රියව සිසිල් වීමට උත්සාහ කරනු ඇත. ඔබට තවම ඔබේ දුරකථනය භාවිත කළ හැකිය, නමුත් එය සෙමින් ධාවනය විය හැකිය.\n\nඔබේ දුරකථනය සිසිල් වූ පසු, එය සාමාන්ය ලෙස ධාවනය වනු ඇත."</string> diff --git a/packages/SystemUI/res/values-sk/strings.xml b/packages/SystemUI/res/values-sk/strings.xml index cddcaf0a5855..b81c19122e28 100644 --- a/packages/SystemUI/res/values-sk/strings.xml +++ b/packages/SystemUI/res/values-sk/strings.xml @@ -85,6 +85,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Späť"</string> <string name="accessibility_home" msgid="8217216074895377641">"Plocha"</string> <string name="accessibility_menu" msgid="316839303324695949">"Menu"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Prehľad"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Hľadať"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Fotoaparát"</string> @@ -677,8 +679,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Strana <xliff:g id="ID_1">%1$d</xliff:g> z <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Rozbaliť"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Minimalizovať"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Zavrieť"</string> <string name="high_temp_title" msgid="4589508026407318374">"Teplota telefónu stúpa"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Niektoré funkcie budú obmedzené, dokým neklesne teplota telefónu"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Váš telefón sa automaticky pokúsi schladiť. Môžete ho naďalej používať, ale môže fungovať pomalšie.\n\nPo poklese teploty bude telefón fungovať ako normálne."</string> diff --git a/packages/SystemUI/res/values-sl/strings.xml b/packages/SystemUI/res/values-sl/strings.xml index da993b4eb9ef..e8ee37a72e38 100644 --- a/packages/SystemUI/res/values-sl/strings.xml +++ b/packages/SystemUI/res/values-sl/strings.xml @@ -85,6 +85,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Nazaj"</string> <string name="accessibility_home" msgid="8217216074895377641">"Začetni zaslon"</string> <string name="accessibility_menu" msgid="316839303324695949">"Meni"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Pregled"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Iskanje"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Fotoaparat"</string> @@ -677,8 +679,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"<xliff:g id="ID_1">%1$d</xliff:g>. stran od <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Razširi"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Minimiraj"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Zapri"</string> <string name="high_temp_title" msgid="4589508026407318374">"Telefon se segreva"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Nekatere funkcije bodo med ohlajanjem omejene."</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Telefon se bo samodejno poskusil ohladiti. Še naprej ga lahko uporabljate, vendar bo morda deloval počasneje.\n\nKo se telefon ohladi, bo zopet deloval kot običajno."</string> diff --git a/packages/SystemUI/res/values-sq/strings.xml b/packages/SystemUI/res/values-sq/strings.xml index 6b8bb9725757..152ecef85ab8 100644 --- a/packages/SystemUI/res/values-sq/strings.xml +++ b/packages/SystemUI/res/values-sq/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Prapa"</string> <string name="accessibility_home" msgid="8217216074895377641">"Faqja bazë"</string> <string name="accessibility_menu" msgid="316839303324695949">"Menyja"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Përmbledhje"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Kërko"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Kamera"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Faqja <xliff:g id="ID_1">%1$d</xliff:g> nga <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Zgjero"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Minimizo"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Mbyll"</string> <string name="high_temp_title" msgid="4589508026407318374">"Telefoni po bëhet i ngrohtë"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Disa funksione janë të kufizuara kur telefoni është duke u ftohur"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Telefoni yt do të përpiqet automatikisht që të ftohet. Mund ta përdorësh përsëri telefonin, por ai mund të punojë më ngadalë.\n\nPasi telefoni të jetë ftohur, ai do të punojë si normalisht."</string> diff --git a/packages/SystemUI/res/values-sr/strings.xml b/packages/SystemUI/res/values-sr/strings.xml index 0af49e4e68f0..4a80a94eae6e 100644 --- a/packages/SystemUI/res/values-sr/strings.xml +++ b/packages/SystemUI/res/values-sr/strings.xml @@ -84,6 +84,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Назад"</string> <string name="accessibility_home" msgid="8217216074895377641">"Почетна"</string> <string name="accessibility_menu" msgid="316839303324695949">"Мени"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Преглед"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Претражите"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Камера"</string> @@ -673,8 +675,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"<xliff:g id="ID_1">%1$d</xliff:g>. страна од <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Прошири"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Умањи"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Затвори"</string> <string name="high_temp_title" msgid="4589508026407318374">"Телефон се загрејао"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Неке функције су ограничене док се телефон не охлади"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Телефон ће аутоматски покушати да се охлади. И даље ћете моћи да користите телефон, али ће спорије реаговати.\n\nКада се телефон охлади, нормално ће радити."</string> diff --git a/packages/SystemUI/res/values-sv/strings.xml b/packages/SystemUI/res/values-sv/strings.xml index 9700f0a331d5..630225dd8413 100644 --- a/packages/SystemUI/res/values-sv/strings.xml +++ b/packages/SystemUI/res/values-sv/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Tillbaka"</string> <string name="accessibility_home" msgid="8217216074895377641">"Startsida"</string> <string name="accessibility_menu" msgid="316839303324695949">"Meny"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Översikt"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Sök"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Kamera"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Sida <xliff:g id="ID_1">%1$d</xliff:g> av <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Utöka"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Minimera"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Stäng"</string> <string name="high_temp_title" msgid="4589508026407318374">"Mobilen börjar bli varm"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Vissa funktioner är begränsade medan mobilen svalnar"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Mobilen försöker svalna automatiskt. Du kan fortfarande använda mobilen, men den kan vara långsammare än vanligt.\n\nMobilen fungerar som vanligt när den har svalnat."</string> diff --git a/packages/SystemUI/res/values-sw/strings.xml b/packages/SystemUI/res/values-sw/strings.xml index fc9439c94433..4bf4d903b72c 100644 --- a/packages/SystemUI/res/values-sw/strings.xml +++ b/packages/SystemUI/res/values-sw/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Nyuma"</string> <string name="accessibility_home" msgid="8217216074895377641">"Nyumbani"</string> <string name="accessibility_menu" msgid="316839303324695949">"Menyu"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Muhtasari"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Tafuta"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Kamera"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Ukurasa wa <xliff:g id="ID_1">%1$d</xliff:g> kati ya <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Panua"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Punguza"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Funga"</string> <string name="high_temp_title" msgid="4589508026407318374">"Joto la simu linaongezeka"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Baadhi ya vipengele havitatumika kwenye simu wakati inapoa"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Simu yako itajaribu kupoa kiotomatiki. Bado unaweza kutumia simu yako, lakini huenda ikafanya kazi polepole. \n\nPindi simu yako itakapopoa, itaendelea kufanya kazi kama kawaida."</string> diff --git a/packages/SystemUI/res/values-ta/strings.xml b/packages/SystemUI/res/values-ta/strings.xml index b79e8a9ed3cb..5dea611cceee 100644 --- a/packages/SystemUI/res/values-ta/strings.xml +++ b/packages/SystemUI/res/values-ta/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"பின்செல்"</string> <string name="accessibility_home" msgid="8217216074895377641">"முகப்பு"</string> <string name="accessibility_menu" msgid="316839303324695949">"மெனு"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"மேலோட்டப் பார்வை"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"தேடு"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"கேமரா"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"பக்கம் <xliff:g id="ID_1">%1$d</xliff:g> / <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"விரி"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"சிறிதாக்கு"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"மூடு"</string> <string name="high_temp_title" msgid="4589508026407318374">"மொபைல் சூடாகிறது"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"மொபைலின் வெப்ப அளவு குறையும் போது, சில அம்சங்களைப் பயன்படுத்த முடியாது"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"உங்கள் மொபைலின் வெப்ப அளவு தானாகவே குறையும். தொடர்ந்து நீங்கள் மொபைலைப் பயன்படுத்தலாம், ஆனால் அதன் வேகம் குறைவாக இருக்கக்கூடும்.\n\nமொபைலின் வெப்ப அளவு குறைந்தவுடன், அது இயல்பு நிலையில் இயங்கும்."</string> diff --git a/packages/SystemUI/res/values-te/strings.xml b/packages/SystemUI/res/values-te/strings.xml index 2175c5a49d25..eb5bc5e4726d 100644 --- a/packages/SystemUI/res/values-te/strings.xml +++ b/packages/SystemUI/res/values-te/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"వెనుకకు"</string> <string name="accessibility_home" msgid="8217216074895377641">"హోమ్"</string> <string name="accessibility_menu" msgid="316839303324695949">"మెను"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"అవలోకనం"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"శోధించు"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"కెమెరా"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"<xliff:g id="ID_2">%2$d</xliff:g>లో <xliff:g id="ID_1">%1$d</xliff:g>వ పేజీ"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"విస్తరింపజేయి"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"కనిష్టీకరించు"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"మూసివేయి"</string> <string name="high_temp_title" msgid="4589508026407318374">"ఫోన్ వేడెక్కుతోంది"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"ఫోన్ను చల్లబరిచే క్రమంలో కొన్ని లక్షణాలు పరిమితం చేయబడ్డాయి"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"మీ ఫోన్ స్వయంచాలకంగా చల్లబడటానికి ప్రయత్నిస్తుంది. మీరు ఇప్పటికీ మీ ఫోన్ను ఉపయోగించవచ్చు, కానీ దాని పనితీరు నెమ్మదిగా ఉండవచ్చు.\n\nమీ ఫోన్ చల్లబడిన తర్వాత, అది సాధారణ రీతిలో పని చేస్తుంది."</string> diff --git a/packages/SystemUI/res/values-th/strings.xml b/packages/SystemUI/res/values-th/strings.xml index e4d489d2c7c0..d64e2b9eccb6 100644 --- a/packages/SystemUI/res/values-th/strings.xml +++ b/packages/SystemUI/res/values-th/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"กลับ"</string> <string name="accessibility_home" msgid="8217216074895377641">"หน้าแรก"</string> <string name="accessibility_menu" msgid="316839303324695949">"เมนู"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"ภาพรวม"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"ค้นหา"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"กล้องถ่ายรูป"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"หน้า <xliff:g id="ID_1">%1$d</xliff:g> จาก <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"ขยาย"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"ย่อเล็กสุด"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"ปิด"</string> <string name="high_temp_title" msgid="4589508026407318374">"โทรศัพท์เริ่มเครื่องร้อน"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"คุณลักษณะบางอย่างจะใช้งานได้จำกัดขณะโทรศัพท์ลดอุณหภูมิลง"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"โทรศัพท์จะพยายามลดอุณหภูมิลงโดยอัตโนมัติ คุณยังสามารถใช้โทรศัพท์ได้ แต่โทรศัพท์อาจทำงานช้าลง\n\nโทรศัพท์จะทำงานตามปกติเมื่อเย็นลงแล้ว"</string> diff --git a/packages/SystemUI/res/values-tl/strings.xml b/packages/SystemUI/res/values-tl/strings.xml index ac5aa927d9a7..042f66dcd1ff 100644 --- a/packages/SystemUI/res/values-tl/strings.xml +++ b/packages/SystemUI/res/values-tl/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Bumalik"</string> <string name="accessibility_home" msgid="8217216074895377641">"Home"</string> <string name="accessibility_menu" msgid="316839303324695949">"Menu"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Overview"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Hanapin"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Camera"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Page <xliff:g id="ID_1">%1$d</xliff:g> ng <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Palawakin"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"I-minimize"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Isara"</string> <string name="high_temp_title" msgid="4589508026407318374">"Umiinit ang telepono"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Limitado ang ilang feature habang nagku-cool down ang telepono"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Awtomatikong susubukan ng iyong telepono na mag-cool down. Magagamit mo pa rin ang iyong telepono, ngunit maaaring mas mabagal ang paggana nito.\n\nKapag nakapag-cool down na ang iyong telepono, gagana na ito nang normal."</string> diff --git a/packages/SystemUI/res/values-tr/strings.xml b/packages/SystemUI/res/values-tr/strings.xml index 8cf0633f073d..e46782a42d2e 100644 --- a/packages/SystemUI/res/values-tr/strings.xml +++ b/packages/SystemUI/res/values-tr/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Geri"</string> <string name="accessibility_home" msgid="8217216074895377641">"Ana sayfa"</string> <string name="accessibility_menu" msgid="316839303324695949">"Menü"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Genel Bakış"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Ara"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Kamera"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Sayfa <xliff:g id="ID_1">%1$d</xliff:g> / <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Genişlet"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Simge durumuna getir"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Kapat"</string> <string name="high_temp_title" msgid="4589508026407318374">"Telefon ısınıyor"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Telefon soğurken bazı özellikler sınırlı olarak kullanılabilir"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Telefonunuz otomatik olarak soğumaya çalışacak. Bu sırada telefonunuzu kullanmaya devam edebilirsiniz ancak uygulamalar daha yavaş çalışabilir.\n\nTelefonunuz soğuduktan sonra normal şekilde çalışacaktır."</string> diff --git a/packages/SystemUI/res/values-uk/strings.xml b/packages/SystemUI/res/values-uk/strings.xml index 62c0c8c0968f..591caa1faf02 100644 --- a/packages/SystemUI/res/values-uk/strings.xml +++ b/packages/SystemUI/res/values-uk/strings.xml @@ -85,6 +85,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Назад"</string> <string name="accessibility_home" msgid="8217216074895377641">"Головна"</string> <string name="accessibility_menu" msgid="316839303324695949">"Меню"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Огляд"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Пошук"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Камера"</string> @@ -677,8 +679,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Сторінка <xliff:g id="ID_1">%1$d</xliff:g> з <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Розгорнути"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Згорнути"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Закрити"</string> <string name="high_temp_title" msgid="4589508026407318374">"Телефон нагрівається"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Під час охолодження деякі функції обмежуються"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Ваш телефон охолоджуватиметься автоматично. Ви можете далі користуватися телефоном, але він може працювати повільніше.\n\nКоли телефон охолоне, він працюватиме належним чином."</string> diff --git a/packages/SystemUI/res/values-ur/strings.xml b/packages/SystemUI/res/values-ur/strings.xml index 9a7629b47fbe..a4b0f875726f 100644 --- a/packages/SystemUI/res/values-ur/strings.xml +++ b/packages/SystemUI/res/values-ur/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"واپس جائیں"</string> <string name="accessibility_home" msgid="8217216074895377641">"ہوم"</string> <string name="accessibility_menu" msgid="316839303324695949">"مینو"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"مجموعی جائزہ"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"تلاش کریں"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"کیمرا"</string> @@ -683,7 +685,6 @@ <string name="lockscreen_unlock" msgid="4934466194763269051">"پاسورڈ کا اشارہ"</string> <string name="notification_channel_alerts" msgid="4496839309318519037">"الرٹس"</string> <string name="notification_channel_screenshot" msgid="6314080179230000938">"اسکرین شاٹس"</string> - <!-- no translation found for notification_channel_general (4525309436693914482) --> - <skip /> + <string name="notification_channel_general" msgid="4525309436693914482">"عمومی پیغامات"</string> <string name="notification_channel_storage" msgid="3077205683020695313">"اسٹوریج"</string> </resources> diff --git a/packages/SystemUI/res/values-uz/strings.xml b/packages/SystemUI/res/values-uz/strings.xml index f6df9068e9bc..a9c7b04ef6cd 100644 --- a/packages/SystemUI/res/values-uz/strings.xml +++ b/packages/SystemUI/res/values-uz/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Orqaga"</string> <string name="accessibility_home" msgid="8217216074895377641">"Uyga"</string> <string name="accessibility_menu" msgid="316839303324695949">"Menyu"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Umumiy nazar"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Qidirish"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Kamera"</string> @@ -673,8 +675,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"<xliff:g id="ID_1">%1$d</xliff:g>-sahifa, jami: <xliff:g id="ID_2">%2$d</xliff:g> ta sahifa"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Yoyish"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Yig‘ish"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Yopish"</string> <string name="high_temp_title" msgid="4589508026407318374">"Telefon qizib ketdi"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Telefon sovish paytida ayrim funksiyalar ishlamasligi mumkin"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Telefon avtomatik ravishda o‘zini sovitadi. Telefoningizdan foydalanishda davom etishingiz mumkin, lekin u sekinroq ishlashi mumkin.\n\nTelefon sovishi bilan normal holatda ishlashni boshlaydi."</string> diff --git a/packages/SystemUI/res/values-vi/strings.xml b/packages/SystemUI/res/values-vi/strings.xml index ce5d46fe1356..e2a87a434249 100644 --- a/packages/SystemUI/res/values-vi/strings.xml +++ b/packages/SystemUI/res/values-vi/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Quay lại"</string> <string name="accessibility_home" msgid="8217216074895377641">"Trang chủ"</string> <string name="accessibility_menu" msgid="316839303324695949">"Menu"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Tổng quan"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Tìm kiếm"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Máy ảnh"</string> @@ -673,8 +675,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Trang <xliff:g id="ID_1">%1$d</xliff:g> / <xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Mở rộng"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Thu nhỏ"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Đóng"</string> <string name="high_temp_title" msgid="4589508026407318374">"Điện thoại đang nóng lên"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Một số tính năng bị hạn chế trong khi điện thoại nguội dần"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Điện thoại của bạn sẽ tự động nguội dần. Bạn vẫn có thể sử dụng điện thoại, nhưng điện thoại có thể chạy chậm hơn. \n\nSau khi đã nguội, điện thoại sẽ chạy bình thường."</string> diff --git a/packages/SystemUI/res/values-zh-rCN/strings.xml b/packages/SystemUI/res/values-zh-rCN/strings.xml index d0c9e001941f..bfaba9eab97a 100644 --- a/packages/SystemUI/res/values-zh-rCN/strings.xml +++ b/packages/SystemUI/res/values-zh-rCN/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"返回"</string> <string name="accessibility_home" msgid="8217216074895377641">"主屏幕"</string> <string name="accessibility_menu" msgid="316839303324695949">"菜单"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"概览"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"搜索"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"相机"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"第 <xliff:g id="ID_1">%1$d</xliff:g> 页,共 <xliff:g id="ID_2">%2$d</xliff:g> 页"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"展开"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"最小化"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"关闭"</string> <string name="high_temp_title" msgid="4589508026407318374">"手机温度上升中"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"手机降温时,部分功能的使用会受限制"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"您的手机将自动尝试降温。您依然可以使用您的手机,但是手机运行速度可能会更慢。\n\n手机降温后,就会恢复正常的运行速度。"</string> @@ -683,7 +684,6 @@ <string name="lockscreen_unlock" msgid="4934466194763269051">"提示输入密码"</string> <string name="notification_channel_alerts" msgid="4496839309318519037">"提醒"</string> <string name="notification_channel_screenshot" msgid="6314080179230000938">"屏幕截图"</string> - <!-- no translation found for notification_channel_general (4525309436693914482) --> - <skip /> + <string name="notification_channel_general" msgid="4525309436693914482">"常规消息"</string> <string name="notification_channel_storage" msgid="3077205683020695313">"存储空间"</string> </resources> diff --git a/packages/SystemUI/res/values-zh-rHK/strings.xml b/packages/SystemUI/res/values-zh-rHK/strings.xml index f7bf78e6b3a8..4f299ebc8bc2 100644 --- a/packages/SystemUI/res/values-zh-rHK/strings.xml +++ b/packages/SystemUI/res/values-zh-rHK/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"返回"</string> <string name="accessibility_home" msgid="8217216074895377641">"首頁"</string> <string name="accessibility_menu" msgid="316839303324695949">"選單"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"概覽"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"搜尋"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"相機"</string> @@ -673,8 +675,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"第 <xliff:g id="ID_1">%1$d</xliff:g> 頁 (共 <xliff:g id="ID_2">%2$d</xliff:g> 頁)"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"展開"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"最小化"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"關閉"</string> <string name="high_temp_title" msgid="4589508026407318374">"手機溫度正在上升"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"手機降溫時,部分功能會受限制"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"手機會自動嘗試降溫。您仍可以使用手機,但手機的運作速度可能較慢。\n\n手機降溫後便會恢復正常。"</string> diff --git a/packages/SystemUI/res/values-zh-rTW/strings.xml b/packages/SystemUI/res/values-zh-rTW/strings.xml index 54ef0a6449ff..1d28f140c82c 100644 --- a/packages/SystemUI/res/values-zh-rTW/strings.xml +++ b/packages/SystemUI/res/values-zh-rTW/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"返回"</string> <string name="accessibility_home" msgid="8217216074895377641">"主螢幕"</string> <string name="accessibility_menu" msgid="316839303324695949">"選單"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"總覽"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"搜尋"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"相機"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"第 <xliff:g id="ID_1">%1$d</xliff:g> 頁,共 <xliff:g id="ID_2">%2$d</xliff:g> 頁"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"展開"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"最小化"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"關閉"</string> <string name="high_temp_title" msgid="4589508026407318374">"手機變熱"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"手機降溫時,部分功能會受限"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"手機會自動嘗試降溫。你仍可繼續使用手機,但是手機的運作速度可能會較慢。\n\n手機降溫完畢後,就會恢復正常的運作速度。"</string> diff --git a/packages/SystemUI/res/values-zu/strings.xml b/packages/SystemUI/res/values-zu/strings.xml index 78589627d6e7..da0f2de6fd4e 100644 --- a/packages/SystemUI/res/values-zu/strings.xml +++ b/packages/SystemUI/res/values-zu/strings.xml @@ -83,6 +83,8 @@ <string name="accessibility_back" msgid="567011538994429120">"Emuva"</string> <string name="accessibility_home" msgid="8217216074895377641">"Ekhaya"</string> <string name="accessibility_menu" msgid="316839303324695949">"Imenyu"</string> + <!-- no translation found for accessibility_accessibility_button (7601252764577607915) --> + <skip /> <string name="accessibility_recent" msgid="5208608566793607626">"Buka konke"</string> <string name="accessibility_search_light" msgid="1103867596330271848">"Sesha"</string> <string name="accessibility_camera_button" msgid="8064671582820358152">"Ikhamela"</string> @@ -671,8 +673,7 @@ <string name="accessibility_quick_settings_page" msgid="5032979051755200721">"Ikhasi <xliff:g id="ID_1">%1$d</xliff:g> kwangu-<xliff:g id="ID_2">%2$d</xliff:g>"</string> <string name="pip_phone_expand" msgid="5889780005575693909">"Nweba"</string> <string name="pip_phone_minimize" msgid="1079119422589131792">"Nciphisa"</string> - <!-- no translation found for pip_phone_close (8416647892889710330) --> - <skip /> + <string name="pip_phone_close" msgid="8416647892889710330">"Vala"</string> <string name="high_temp_title" msgid="4589508026407318374">"Ifoni iyafudumala"</string> <string name="high_temp_notif_message" msgid="5642466103153429279">"Ezinye izici zikhawulelwe ngenkathi ifoni iphola"</string> <string name="high_temp_dialog_message" msgid="6840700639374113553">"Ifoni yakho izozama ngokuzenzakalela ukuphola. Ungasasebenzisa ifoni yakho, kodwa ingasebenza ngokungasheshi.\n\nUma ifoni yakho isipholile, izosebenza ngokuvamile."</string> diff --git a/packages/SystemUI/src/com/android/systemui/Dependency.java b/packages/SystemUI/src/com/android/systemui/Dependency.java index 7a0108f41204..8d46b431d2c5 100644 --- a/packages/SystemUI/src/com/android/systemui/Dependency.java +++ b/packages/SystemUI/src/com/android/systemui/Dependency.java @@ -23,6 +23,7 @@ import android.os.Process; import android.util.ArrayMap; import com.android.internal.annotations.VisibleForTesting; +import com.android.internal.util.Preconditions; import com.android.systemui.assist.AssistManager; import com.android.systemui.plugins.PluginManager; import com.android.systemui.statusbar.phone.ConfigurationControllerImpl; @@ -92,18 +93,19 @@ public class Dependency extends SystemUI { /** * Key for getting a background Looper for background work. */ - public static final String BG_LOOPER = "background_loooper"; + public static final DependencyKey<Looper> BG_LOOPER = new DependencyKey<>("background_looper"); /** * Key for getting a Handler for receiving time tick broadcasts on. */ - public static final String TIME_TICK_HANDLER = "time_tick_handler"; + public static final DependencyKey<Handler> TIME_TICK_HANDLER = + new DependencyKey<>("time_tick_handler"); /** * Generic handler on the main thread. */ - public static final String MAIN_HANDLER = "main_handler"; + public static final DependencyKey<Handler> MAIN_HANDLER = new DependencyKey<>("main_handler"); - private final ArrayMap<String, Object> mDependencies = new ArrayMap<>(); - private final ArrayMap<String, DependencyProvider> mProviders = new ArrayMap<>(); + private final ArrayMap<Object, Object> mDependencies = new ArrayMap<>(); + private final ArrayMap<Object, DependencyProvider> mProviders = new ArrayMap<>(); @Override public void start() { @@ -122,87 +124,87 @@ public class Dependency extends SystemUI { return thread.getLooper(); }); mProviders.put(MAIN_HANDLER, () -> new Handler(Looper.getMainLooper())); - mProviders.put(ActivityStarter.class.getName(), () -> new ActivityStarterDelegate()); - mProviders.put(ActivityStarterDelegate.class.getName(), () -> + mProviders.put(ActivityStarter.class, () -> new ActivityStarterDelegate()); + mProviders.put(ActivityStarterDelegate.class, () -> getDependency(ActivityStarter.class)); - mProviders.put(BluetoothController.class.getName(), () -> + mProviders.put(BluetoothController.class, () -> new BluetoothControllerImpl(mContext, getDependency(BG_LOOPER))); - mProviders.put(LocationController.class.getName(), () -> + mProviders.put(LocationController.class, () -> new LocationControllerImpl(mContext, getDependency(BG_LOOPER))); - mProviders.put(RotationLockController.class.getName(), () -> + mProviders.put(RotationLockController.class, () -> new RotationLockControllerImpl(mContext)); - mProviders.put(NetworkController.class.getName(), () -> + mProviders.put(NetworkController.class, () -> new NetworkControllerImpl(mContext, getDependency(BG_LOOPER), getDependency(DeviceProvisionedController.class))); - mProviders.put(ZenModeController.class.getName(), () -> + mProviders.put(ZenModeController.class, () -> new ZenModeControllerImpl(mContext, getDependency(MAIN_HANDLER))); - mProviders.put(HotspotController.class.getName(), () -> + mProviders.put(HotspotController.class, () -> new HotspotControllerImpl(mContext)); - mProviders.put(CastController.class.getName(), () -> + mProviders.put(CastController.class, () -> new CastControllerImpl(mContext)); - mProviders.put(FlashlightController.class.getName(), () -> + mProviders.put(FlashlightController.class, () -> new FlashlightControllerImpl(mContext)); - mProviders.put(KeyguardMonitor.class.getName(), () -> + mProviders.put(KeyguardMonitor.class, () -> new KeyguardMonitorImpl(mContext)); - mProviders.put(UserSwitcherController.class.getName(), () -> + mProviders.put(UserSwitcherController.class, () -> new UserSwitcherController(mContext, getDependency(KeyguardMonitor.class), getDependency(MAIN_HANDLER), getDependency(ActivityStarter.class))); - mProviders.put(UserInfoController.class.getName(), () -> + mProviders.put(UserInfoController.class, () -> new UserInfoControllerImpl(mContext)); - mProviders.put(BatteryController.class.getName(), () -> + mProviders.put(BatteryController.class, () -> new BatteryControllerImpl(mContext)); - mProviders.put(ManagedProfileController.class.getName(), () -> + mProviders.put(ManagedProfileController.class, () -> new ManagedProfileControllerImpl(mContext)); - mProviders.put(NextAlarmController.class.getName(), () -> + mProviders.put(NextAlarmController.class, () -> new NextAlarmControllerImpl(mContext)); - mProviders.put(DataSaverController.class.getName(), () -> + mProviders.put(DataSaverController.class, () -> get(NetworkController.class).getDataSaverController()); - mProviders.put(AccessibilityController.class.getName(), () -> + mProviders.put(AccessibilityController.class, () -> new AccessibilityController(mContext)); - mProviders.put(DeviceProvisionedController.class.getName(), () -> + mProviders.put(DeviceProvisionedController.class, () -> new DeviceProvisionedControllerImpl(mContext)); - mProviders.put(PluginManager.class.getName(), () -> + mProviders.put(PluginManager.class, () -> new PluginManager(mContext)); - mProviders.put(AssistManager.class.getName(), () -> + mProviders.put(AssistManager.class, () -> new AssistManager(getDependency(DeviceProvisionedController.class), mContext)); - mProviders.put(SecurityController.class.getName(), () -> + mProviders.put(SecurityController.class, () -> new SecurityControllerImpl(mContext)); - mProviders.put(LeakDetector.class.getName(), LeakDetector::create); + mProviders.put(LeakDetector.class, LeakDetector::create); - mProviders.put(TunerService.class.getName(), () -> + mProviders.put(TunerService.class, () -> new TunerService(mContext)); - mProviders.put(StatusBarWindowManager.class.getName(), () -> + mProviders.put(StatusBarWindowManager.class, () -> new StatusBarWindowManager(mContext)); - mProviders.put(DarkIconDispatcher.class.getName(), () -> + mProviders.put(DarkIconDispatcher.class, () -> new DarkIconDispatcherImpl(mContext)); - mProviders.put(ConfigurationController.class.getName(), () -> + mProviders.put(ConfigurationController.class, () -> new ConfigurationControllerImpl(mContext)); - mProviders.put(StatusBarIconController.class.getName(), () -> + mProviders.put(StatusBarIconController.class, () -> new StatusBarIconControllerImpl(mContext)); // Put all dependencies above here so the factory can override them if it wants. @@ -225,20 +227,28 @@ public class Dependency extends SystemUI { } protected final <T> T getDependency(Class<T> cls) { - return getDependency(cls.getName()); + return getDependencyInner(cls); } - protected final <T> T getDependency(String cls) { - T obj = (T) mDependencies.get(cls); + protected final <T> T getDependency(DependencyKey<T> key) { + return getDependencyInner(key); + } + + private <T> T getDependencyInner(Object key) { + @SuppressWarnings("unchecked") + T obj = (T) mDependencies.get(key); if (obj == null) { - obj = createDependency(cls); - mDependencies.put(cls, obj); + obj = createDependency(key); + mDependencies.put(key, obj); } return obj; } @VisibleForTesting - protected <T> T createDependency(String cls) { + protected <T> T createDependency(Object cls) { + Preconditions.checkArgument(cls instanceof DependencyKey<?> || cls instanceof Class<?>); + + @SuppressWarnings("unchecked") DependencyProvider<T> provider = mProviders.get(cls); if (provider == null) { throw new IllegalArgumentException("Unsupported dependency " + cls); @@ -264,10 +274,23 @@ public class Dependency extends SystemUI { } public static <T> T get(Class<T> cls) { - return sDependency.getDependency(cls.getName()); + return sDependency.getDependency(cls); } - public static <T> T get(String cls) { + public static <T> T get(DependencyKey<T> cls) { return sDependency.getDependency(cls); } + + public static final class DependencyKey<V> { + private final String mDisplayName; + + public DependencyKey(String displayName) { + mDisplayName = displayName; + } + + @Override + public String toString() { + return mDisplayName; + } + } } diff --git a/packages/SystemUI/src/com/android/systemui/SystemUIFactory.java b/packages/SystemUI/src/com/android/systemui/SystemUIFactory.java index 1ff07010731d..411fd3d8f4f2 100644 --- a/packages/SystemUI/src/com/android/systemui/SystemUIFactory.java +++ b/packages/SystemUI/src/com/android/systemui/SystemUIFactory.java @@ -113,6 +113,6 @@ public class SystemUIFactory { return null; } - public void injectDependencies(ArrayMap<String, DependencyProvider> providers, + public void injectDependencies(ArrayMap<Object, DependencyProvider> providers, Context context) { } } diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/KeyguardAffordanceView.java b/packages/SystemUI/src/com/android/systemui/statusbar/KeyguardAffordanceView.java index 8b4225a8ab0b..b15f0900a72b 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/KeyguardAffordanceView.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/KeyguardAffordanceView.java @@ -21,6 +21,7 @@ import android.animation.AnimatorListenerAdapter; import android.animation.ArgbEvaluator; import android.animation.PropertyValuesHolder; import android.animation.ValueAnimator; +import android.annotation.Nullable; import android.content.Context; import android.graphics.Canvas; import android.graphics.CanvasProperty; @@ -78,6 +79,7 @@ public class KeyguardAffordanceView extends ImageView { private boolean mSupportHardware; private boolean mFinishing; private boolean mLaunchingAffordance; + private boolean mShouldTint = true; private CanvasProperty<Float> mHwCircleRadius; private CanvasProperty<Float> mHwCenterX; @@ -137,6 +139,12 @@ public class KeyguardAffordanceView extends ImageView { mFlingAnimationUtils = new FlingAnimationUtils(mContext, 0.3f); } + public void setImageDrawable(@Nullable Drawable drawable, boolean tint) { + super.setImageDrawable(drawable); + mShouldTint = tint; + updateIconColor(); + } + @Override protected void onLayout(boolean changed, int left, int top, int right, int bottom) { super.onLayout(changed, left, top, right, bottom); @@ -165,6 +173,7 @@ public class KeyguardAffordanceView extends ImageView { } private void updateIconColor() { + if (!mShouldTint) return; Drawable drawable = getDrawable().mutate(); float alpha = mCircleRadius / mMinBackgroundRadius; alpha = Math.min(1.0f, alpha); diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/KeyguardBottomAreaView.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/KeyguardBottomAreaView.java index 14f991997e35..2836f41b04f5 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/KeyguardBottomAreaView.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/KeyguardBottomAreaView.java @@ -324,7 +324,7 @@ public class KeyguardBottomAreaView extends FrameLayout implements View.OnClickL private void updateRightAffordanceIcon() { IconState state = mRightButton.getIcon(); mRightAffordanceView.setVisibility(state.isVisible ? View.VISIBLE : View.GONE); - mRightAffordanceView.setImageDrawable(state.drawable); + mRightAffordanceView.setImageDrawable(state.drawable, state.tint); mRightAffordanceView.setContentDescription(state.contentDescription); } @@ -376,7 +376,7 @@ public class KeyguardBottomAreaView extends FrameLayout implements View.OnClickL private void updateLeftAffordanceIcon() { IconState state = mLeftButton.getIcon(); mLeftAffordanceView.setVisibility(state.isVisible ? View.VISIBLE : View.GONE); - mLeftAffordanceView.setImageDrawable(state.drawable); + mLeftAffordanceView.setImageDrawable(state.drawable, state.tint); mLeftAffordanceView.setContentDescription(state.contentDescription); } diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBar.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBar.java index 433dc3f92e5a..365d99165121 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBar.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBar.java @@ -196,6 +196,8 @@ import com.android.systemui.statusbar.policy.UserSwitcherController; import com.android.systemui.statusbar.stack.NotificationStackScrollLayout; import com.android.systemui.statusbar.stack.NotificationStackScrollLayout.OnChildLocationsChangedListener; + +import com.android.systemui.util.leak.LeakDetector; import com.android.systemui.volume.VolumeComponent; import java.io.FileDescriptor; @@ -6596,6 +6598,7 @@ public class StatusBar extends SystemUI implements DemoMode, return null; } updateNotifications(); + Dependency.get(LeakDetector.class).trackGarbage(entry); return entry.notification; } @@ -6604,6 +6607,7 @@ public class StatusBar extends SystemUI implements DemoMode, Log.d(TAG, "createNotificationViews(notification=" + sbn); } NotificationData.Entry entry = new NotificationData.Entry(sbn); + Dependency.get(LeakDetector.class).trackInstance(entry); try { entry.createIcons(mContext, sbn); } catch (NotificationData.IconException exception) { diff --git a/packages/SystemUI/src/com/android/systemui/tuner/LockscreenFragment.java b/packages/SystemUI/src/com/android/systemui/tuner/LockscreenFragment.java index 9d579f561ea8..6f4a3a4969fa 100644 --- a/packages/SystemUI/src/com/android/systemui/tuner/LockscreenFragment.java +++ b/packages/SystemUI/src/com/android/systemui/tuner/LockscreenFragment.java @@ -26,6 +26,7 @@ import android.content.pm.LauncherApps.ShortcutQuery; import android.content.pm.PackageManager.NameNotFoundException; import android.content.pm.ShortcutInfo; import android.graphics.drawable.Drawable; +import android.graphics.drawable.ScaleDrawable; import android.os.Bundle; import android.os.Handler; import android.os.Process; @@ -37,6 +38,9 @@ import android.support.v7.widget.LinearLayoutManager; import android.support.v7.widget.RecyclerView; import android.support.v7.widget.RecyclerView.ViewHolder; import android.text.TextUtils; +import android.util.Log; +import android.util.TypedValue; +import android.view.Gravity; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; @@ -46,6 +50,7 @@ import android.widget.TextView; import com.android.systemui.Dependency; import com.android.systemui.R; import com.android.systemui.plugins.IntentButtonProvider.IntentButton; +import com.android.systemui.statusbar.ScalingDrawableWrapper; import com.android.systemui.statusbar.phone.ExpandableIndicator; import com.android.systemui.tuner.ShortcutParser.Shortcut; import com.android.systemui.tuner.TunerService.Tunable; @@ -365,8 +370,13 @@ public class LockscreenFragment extends PreferenceFragment { mShortcut = shortcut; mIconState = new IconState(); mIconState.isVisible = true; - mIconState.drawable = shortcut.icon.loadDrawable(context); + mIconState.drawable = shortcut.icon.loadDrawable(context).mutate(); mIconState.contentDescription = mShortcut.label; + int size = (int) TypedValue.applyDimension(TypedValue.COMPLEX_UNIT_DIP, 32, + context.getResources().getDisplayMetrics()); + mIconState.drawable = new ScalingDrawableWrapper(mIconState.drawable, + size / (float) mIconState.drawable.getIntrinsicWidth()); + mIconState.tint = false; } @Override @@ -388,8 +398,13 @@ public class LockscreenFragment extends PreferenceFragment { mIntent = new Intent().setComponent(new ComponentName(info.packageName, info.name)); mIconState = new IconState(); mIconState.isVisible = true; - mIconState.drawable = info.loadIcon(context.getPackageManager()); + mIconState.drawable = info.loadIcon(context.getPackageManager()).mutate(); mIconState.contentDescription = info.loadLabel(context.getPackageManager()); + int size = (int) TypedValue.applyDimension(TypedValue.COMPLEX_UNIT_DIP, 32, + context.getResources().getDisplayMetrics()); + mIconState.drawable = new ScalingDrawableWrapper(mIconState.drawable, + size / (float) mIconState.drawable.getIntrinsicWidth()); + mIconState.tint = false; } @Override diff --git a/packages/SystemUI/src/com/android/systemui/tuner/TunerService.java b/packages/SystemUI/src/com/android/systemui/tuner/TunerService.java index 0edff86a624b..85be4d79d64f 100644 --- a/packages/SystemUI/src/com/android/systemui/tuner/TunerService.java +++ b/packages/SystemUI/src/com/android/systemui/tuner/TunerService.java @@ -48,8 +48,10 @@ import com.android.systemui.SystemUIApplication; import com.android.systemui.settings.CurrentUserTracker; import com.android.systemui.statusbar.phone.StatusBarIconController; import com.android.systemui.statusbar.phone.SystemUIDialog; +import com.android.systemui.util.leak.LeakDetector; import java.util.HashMap; +import java.util.HashSet; import java.util.Set; @@ -66,6 +68,8 @@ public class TunerService { private final ArrayMap<Uri, String> mListeningUris = new ArrayMap<>(); // Map of settings keys to the listener. private final HashMap<String, Set<Tunable>> mTunableLookup = new HashMap<>(); + // Set of all tunables, used for leak detection. + private final HashSet<Tunable> mTunables = LeakDetector.ENABLED ? new HashSet<>() : null; private final Context mContext; private ContentResolver mContentResolver; @@ -150,6 +154,10 @@ public class TunerService { mTunableLookup.put(key, new ArraySet<Tunable>()); } mTunableLookup.get(key).add(tunable); + if (LeakDetector.ENABLED) { + mTunables.add(tunable); + Dependency.get(LeakDetector.class).trackCollection(mTunables, "TunerService.mTunables"); + } Uri uri = Settings.Secure.getUriFor(key); if (!mListeningUris.containsKey(uri)) { mListeningUris.put(uri, key); @@ -164,6 +172,9 @@ public class TunerService { for (Set<Tunable> list : mTunableLookup.values()) { list.remove(tunable); } + if (LeakDetector.ENABLED) { + mTunables.remove(tunable); + } } protected void reregisterAll() { diff --git a/packages/SystemUI/src/com/android/systemui/util/leak/LeakDetector.java b/packages/SystemUI/src/com/android/systemui/util/leak/LeakDetector.java index 2124f903bfc8..a0f8659ab5d0 100644 --- a/packages/SystemUI/src/com/android/systemui/util/leak/LeakDetector.java +++ b/packages/SystemUI/src/com/android/systemui/util/leak/LeakDetector.java @@ -32,7 +32,7 @@ import java.util.Collection; */ public class LeakDetector implements Dumpable { - private static final boolean ENABLED = Build.IS_DEBUGGABLE; + public static final boolean ENABLED = Build.IS_DEBUGGABLE; private final TrackedCollections mTrackedCollections; private final TrackedGarbage mTrackedGarbage; diff --git a/packages/SystemUI/tests/src/com/android/systemui/DependencyTest.java b/packages/SystemUI/tests/src/com/android/systemui/DependencyTest.java index fb4b6bdf3f1b..27955ecbca72 100644 --- a/packages/SystemUI/tests/src/com/android/systemui/DependencyTest.java +++ b/packages/SystemUI/tests/src/com/android/systemui/DependencyTest.java @@ -22,19 +22,25 @@ import static org.mockito.Mockito.verify; import android.os.Looper; +import com.android.systemui.Dependency.DependencyKey; import com.android.systemui.statusbar.policy.FlashlightController; +import org.junit.Assert; import org.junit.Test; import java.io.PrintWriter; public class DependencyTest extends SysuiTestCase { + public static final DependencyKey<Dumpable> DUMPABLE = new DependencyKey<>("dumpable"); + public static final DependencyKey<ConfigurationChangedReceiver> CONFIGURATION_CHANGED_RECEIVER + = new DependencyKey<>("config_changed_receiver"); + @Test public void testClassDependency() { FlashlightController f = mock(FlashlightController.class); injectTestDependency(FlashlightController.class, f); - assertEquals(f, Dependency.get(FlashlightController.class)); + Assert.assertEquals(f, Dependency.get(FlashlightController.class)); } @Test @@ -47,8 +53,8 @@ public class DependencyTest extends SysuiTestCase { @Test public void testDump() { Dumpable d = mock(Dumpable.class); - injectTestDependency("test", d); - Dependency.get("test"); + injectTestDependency(DUMPABLE, d); + Dependency.get(DUMPABLE); mDependency.dump(null, mock(PrintWriter.class), null); verify(d).dump(eq(null), any(), eq(null)); } @@ -56,8 +62,8 @@ public class DependencyTest extends SysuiTestCase { @Test public void testConfigurationChanged() { ConfigurationChangedReceiver d = mock(ConfigurationChangedReceiver.class); - injectTestDependency("test", d); - Dependency.get("test"); + injectTestDependency(CONFIGURATION_CHANGED_RECEIVER, d); + Dependency.get(CONFIGURATION_CHANGED_RECEIVER); mDependency.onConfigurationChanged(null); verify(d).onConfigurationChanged(eq(null)); } diff --git a/packages/SystemUI/tests/src/com/android/systemui/FragmentTestCase.java b/packages/SystemUI/tests/src/com/android/systemui/FragmentTestCase.java index f8f67bb15c29..1678d9232652 100644 --- a/packages/SystemUI/tests/src/com/android/systemui/FragmentTestCase.java +++ b/packages/SystemUI/tests/src/com/android/systemui/FragmentTestCase.java @@ -29,6 +29,7 @@ import android.view.WindowManager; import android.view.WindowManager.LayoutParams; import android.widget.FrameLayout; +import com.android.systemui.utils.TestableLooper; import com.android.systemui.utils.ViewUtils; import com.android.systemui.utils.leaks.LeakCheckedTest; @@ -59,12 +60,14 @@ public abstract class FragmentTestCase extends LeakCheckedTest { } @Before - public void setupFragment() throws IllegalAccessException, InstantiationException { + public void setupFragment() throws Exception { mView = new FrameLayout(mContext); mView.setId(VIEW_ID); - mHandler = new Handler(Looper.getMainLooper()); - mFragment = mCls.newInstance(); - postAndWait(() -> { + + TestableLooper.get(this).runWithLooper(() -> { + mHandler = new Handler(); + + mFragment = mCls.newInstance(); mFragments = FragmentController.createController(new HostCallbacks()); mFragments.attachHost(null); mFragments.getFragmentManager().beginTransaction() @@ -73,30 +76,39 @@ public abstract class FragmentTestCase extends LeakCheckedTest { }); } + private String hex(Looper looper) { + return Integer.toHexString(System.identityHashCode(looper)); + } + @After - public void tearDown() { + public void tearDown() throws Exception { if (mFragments != null) { // Set mFragments to null to let it know not to destroy. - postAndWait(() -> mFragments.dispatchDestroy()); + TestableLooper.get(this).runWithLooper(() -> mFragments.dispatchDestroy()); } } @Test public void testCreateDestroy() { - postAndWait(() -> mFragments.dispatchCreate()); + mFragments.dispatchCreate(); + processAllMessages(); destroyFragments(); } @Test public void testStartStop() { - postAndWait(() -> mFragments.dispatchStart()); - postAndWait(() -> mFragments.dispatchStop()); + mFragments.dispatchStart(); + processAllMessages(); + mFragments.dispatchStop(); + processAllMessages(); } @Test public void testResumePause() { - postAndWait(() -> mFragments.dispatchResume()); - postAndWait(() -> mFragments.dispatchPause()); + mFragments.dispatchResume(); + processAllMessages(); + mFragments.dispatchPause(); + processAllMessages(); } @Test @@ -105,54 +117,57 @@ public abstract class FragmentTestCase extends LeakCheckedTest { LayoutParams.MATCH_PARENT, LayoutParams.MATCH_PARENT, LayoutParams.TYPE_SYSTEM_ALERT, 0, PixelFormat.TRANSLUCENT); - postAndWait(() -> mFragments.dispatchResume()); + mFragments.dispatchResume(); + processAllMessages(); attachFragmentToWindow(); detachFragmentToWindow(); - postAndWait(() -> mFragments.dispatchPause()); - } - - protected void attachFragmentToWindow() { - ViewUtils.attachView(mView); - } - - protected void detachFragmentToWindow() { - ViewUtils.detachView(mView); + mFragments.dispatchPause(); + processAllMessages(); } @Test public void testRecreate() { - postAndWait(() -> mFragments.dispatchResume()); - postAndWait(() -> { - mFragments.dispatchPause(); - Parcelable p = mFragments.saveAllState(); - mFragments.dispatchDestroy(); + mFragments.dispatchResume(); + processAllMessages(); + mFragments.dispatchPause(); + Parcelable p = mFragments.saveAllState(); + mFragments.dispatchDestroy(); - mFragments = FragmentController.createController(new HostCallbacks()); - mFragments.attachHost(null); - mFragments.restoreAllState(p, (FragmentManagerNonConfig) null); - mFragments.dispatchResume(); - }); + mFragments = FragmentController.createController(new HostCallbacks()); + mFragments.attachHost(null); + mFragments.restoreAllState(p, (FragmentManagerNonConfig) null); + mFragments.dispatchResume(); + processAllMessages(); } @Test public void testMultipleResumes() { - postAndWait(() -> mFragments.dispatchResume()); - postAndWait(() -> mFragments.dispatchStop()); - postAndWait(() -> mFragments.dispatchResume()); + mFragments.dispatchResume(); + processAllMessages(); + mFragments.dispatchStop(); + processAllMessages(); + mFragments.dispatchResume(); + processAllMessages(); } - protected void destroyFragments() { - postAndWait(() -> mFragments.dispatchDestroy()); - mFragments = null; + protected void attachFragmentToWindow() { + ViewUtils.attachView(mView); + TestableLooper.get(this).processMessages(1); } - protected void postAndWait(Runnable r) { - mHandler.post(r); - waitForFragments(); + protected void detachFragmentToWindow() { + ViewUtils.detachView(mView); + TestableLooper.get(this).processMessages(1); + } + + protected void destroyFragments() { + mFragments.dispatchDestroy(); + processAllMessages(); + mFragments = null; } - protected void waitForFragments() { - waitForIdleSync(mHandler); + protected void processAllMessages() { + TestableLooper.get(this).processAllMessages(); } private View findViewById(int id) { diff --git a/packages/SystemUI/tests/src/com/android/systemui/SysUIRunner.java b/packages/SystemUI/tests/src/com/android/systemui/SysUIRunner.java new file mode 100644 index 000000000000..1607b7086c61 --- /dev/null +++ b/packages/SystemUI/tests/src/com/android/systemui/SysUIRunner.java @@ -0,0 +1,87 @@ +/* + * Copyright (C) 2017 The Android Open Source Project + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the + * License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the specific language governing + * permissions and limitations under the License. + */ + +package com.android.systemui; + +import android.support.test.internal.runner.junit4.statement.RunAfters; +import android.support.test.internal.runner.junit4.statement.RunBefores; +import android.support.test.internal.runner.junit4.statement.UiThreadStatement; + +import com.android.systemui.utils.TestableLooper.LooperStatement; +import com.android.systemui.utils.TestableLooper.RunWithLooper; + +import org.junit.After; +import org.junit.Before; +import org.junit.Test; +import org.junit.internal.runners.statements.FailOnTimeout; +import org.junit.runners.BlockJUnit4ClassRunner; +import org.junit.runners.model.FrameworkMethod; +import org.junit.runners.model.InitializationError; +import org.junit.runners.model.Statement; + +import java.util.List; + +public class SysUIRunner extends BlockJUnit4ClassRunner { + + private final long mTimeout; + private final Class<?> mKlass; + + public SysUIRunner(Class<?> klass) throws InitializationError { + super(klass); + mKlass = klass; + // Can't seem to get reference to timeout parameter from here, so set default to 10 mins. + mTimeout = 10 * 60 * 1000; + } + + @Override + protected Statement methodInvoker(FrameworkMethod method, Object test) { + return UiThreadStatement.shouldRunOnUiThread(method) ? new UiThreadStatement( + methodInvokerInt(method, test), true) : methodInvokerInt(method, test); + } + + protected Statement methodInvokerInt(FrameworkMethod method, Object test) { + RunWithLooper annotation = method.getAnnotation(RunWithLooper.class); + if (annotation == null) annotation = mKlass.getAnnotation(RunWithLooper.class); + if (annotation != null) { + return new LooperStatement(super.methodInvoker(method, test), + annotation.setAsMainLooper(), test); + } + return super.methodInvoker(method, test); + } + + protected Statement withBefores(FrameworkMethod method, Object target, Statement statement) { + List befores = this.getTestClass().getAnnotatedMethods(Before.class); + return befores.isEmpty() ? statement : new RunBefores(method, statement, + befores, target); + } + + protected Statement withAfters(FrameworkMethod method, Object target, Statement statement) { + List afters = this.getTestClass().getAnnotatedMethods(After.class); + return afters.isEmpty() ? statement : new RunAfters(method, statement, afters, + target); + } + + protected Statement withPotentialTimeout(FrameworkMethod method, Object test, Statement next) { + long timeout = this.getTimeout(method.getAnnotation(Test.class)); + if (timeout <= 0L && mTimeout > 0L) { + timeout = mTimeout; + } + + return timeout <= 0L ? next : new FailOnTimeout(next, timeout); + } + + private long getTimeout(Test annotation) { + return annotation == null ? 0L : annotation.timeout(); + } +} diff --git a/packages/SystemUI/tests/src/com/android/systemui/SysuiTestCase.java b/packages/SystemUI/tests/src/com/android/systemui/SysuiTestCase.java index 12a485ecef4b..6c454e126eaf 100644 --- a/packages/SystemUI/tests/src/com/android/systemui/SysuiTestCase.java +++ b/packages/SystemUI/tests/src/com/android/systemui/SysuiTestCase.java @@ -25,6 +25,7 @@ import android.support.test.InstrumentationRegistry; import android.util.ArrayMap; import android.util.Log; +import com.android.systemui.Dependency.DependencyKey; import com.android.systemui.utils.TestableContext; import com.android.systemui.utils.leaks.Tracker; @@ -91,15 +92,15 @@ public abstract class SysuiTestCase { return null; } - public void injectMockDependency(Class<?> cls) { - mDependency.injectTestDependency(cls.getName(), mock(cls)); + public <T> void injectMockDependency(Class<T> cls) { + injectTestDependency(cls, mock(cls)); } - public void injectTestDependency(Class<?> cls, Object obj) { - mDependency.injectTestDependency(cls.getName(), obj); + public <T> void injectTestDependency(Class<T> cls, T obj) { + mDependency.injectTestDependency(cls, obj); } - public void injectTestDependency(String key, Object obj) { + public <T> void injectTestDependency(DependencyKey<T> key, T obj) { mDependency.injectTestDependency(key, obj); } @@ -109,16 +110,20 @@ public abstract class SysuiTestCase { } public static class TestDependency extends Dependency { - private final ArrayMap<String, Object> mObjs = new ArrayMap<>(); + private final ArrayMap<Object, Object> mObjs = new ArrayMap<>(); - private void injectTestDependency(String key, Object obj) { + private <T> void injectTestDependency(DependencyKey<T> key, T obj) { + mObjs.put(key, obj); + } + + private <T> void injectTestDependency(Class<T> key, T obj) { mObjs.put(key, obj); } @Override - protected <T> T createDependency(String cls) { - if (mObjs.containsKey(cls)) return (T) mObjs.get(cls); - return super.createDependency(cls); + protected <T> T createDependency(Object key) { + if (mObjs.containsKey(key)) return (T) mObjs.get(key); + return super.createDependency(key); } } diff --git a/packages/SystemUI/tests/src/com/android/systemui/qs/QSFragmentTest.java b/packages/SystemUI/tests/src/com/android/systemui/qs/QSFragmentTest.java index 9eac0a0d8b04..e7fa7998350d 100644 --- a/packages/SystemUI/tests/src/com/android/systemui/qs/QSFragmentTest.java +++ b/packages/SystemUI/tests/src/com/android/systemui/qs/QSFragmentTest.java @@ -14,17 +14,23 @@ package com.android.systemui.qs; +import static org.junit.Assert.assertEquals; import static org.mockito.Mockito.mock; +import android.os.Looper; + import com.android.systemui.Dependency; import com.android.systemui.FragmentTestCase; import com.android.systemui.R; +import com.android.systemui.SysUIRunner; import com.android.systemui.statusbar.phone.QSTileHost; import com.android.systemui.statusbar.phone.QuickStatusBarHeader; import com.android.systemui.statusbar.phone.StatusBarIconController; import com.android.systemui.statusbar.policy.UserSwitcherController; import com.android.systemui.tuner.TunerService; import com.android.systemui.util.LayoutInflaterBuilder; +import com.android.systemui.utils.TestableLooper; +import com.android.systemui.utils.TestableLooper.RunWithLooper; import org.junit.Before; import org.junit.Test; @@ -37,7 +43,8 @@ import android.support.test.runner.AndroidJUnit4; import android.view.View; import android.widget.FrameLayout; -@RunWith(AndroidJUnit4.class) +@RunWith(SysUIRunner.class) +@RunWithLooper(setAsMainLooper = true) public class QSFragmentTest extends FragmentTestCase { public QSFragmentTest() { @@ -53,32 +60,31 @@ public class QSFragmentTest extends FragmentTestCase { .replace("TextClock", View.class) .build()); - injectTestDependency(Dependency.BG_LOOPER, Looper.getMainLooper()); + injectTestDependency(Dependency.BG_LOOPER, TestableLooper.get(this).getLooper()); injectMockDependency(UserSwitcherController.class); injectLeakCheckedDependencies(ALL_SUPPORTED_CLASSES); } @Test public void testListening() { + assertEquals(Looper.myLooper(), Looper.getMainLooper()); QSFragment qs = (QSFragment) mFragment; - postAndWait(() -> mFragments.dispatchResume()); - QSTileHost host = new QSTileHost(mContext, null, - mock(StatusBarIconController.class)); + mFragments.dispatchResume(); + processAllMessages(); + QSTileHost host = new QSTileHost(mContext, null, mock(StatusBarIconController.class)); qs.setHost(host); - Handler h = new Handler((Looper) Dependency.get(Dependency.BG_LOOPER)); qs.setListening(true); - waitForIdleSync(h); + processAllMessages(); qs.setListening(false); - waitForIdleSync(h); + processAllMessages(); // Manually push header through detach so it can handle standard cleanup it does on // removed from window. ((QuickStatusBarHeader) qs.getView().findViewById(R.id.header)).onDetachedFromWindow(); host.destroy(); - // Ensure the tuner cleans up its persistent listeners. - Dependency.get(TunerService.class).destroy(); + processAllMessages(); } } diff --git a/packages/SystemUI/tests/src/com/android/systemui/statusbar/NotificationMenuRowTest.java b/packages/SystemUI/tests/src/com/android/systemui/statusbar/NotificationMenuRowTest.java index 71411706c4a9..72f6ca8ec730 100644 --- a/packages/SystemUI/tests/src/com/android/systemui/statusbar/NotificationMenuRowTest.java +++ b/packages/SystemUI/tests/src/com/android/systemui/statusbar/NotificationMenuRowTest.java @@ -14,12 +14,18 @@ package com.android.systemui.statusbar; +import com.android.systemui.SysUIRunner; +import com.android.systemui.utils.TestableLooper; +import com.android.systemui.utils.TestableLooper.RunWithLooper; import com.android.systemui.utils.ViewUtils; import com.android.systemui.utils.leaks.LeakCheckedTest; import org.junit.Before; import org.junit.Test; +import org.junit.runner.RunWith; +@RunWith(SysUIRunner.class) +@RunWithLooper public class NotificationMenuRowTest extends LeakCheckedTest { @Before @@ -31,6 +37,8 @@ public class NotificationMenuRowTest extends LeakCheckedTest { public void testAttachDetach() { NotificationMenuRow row = new NotificationMenuRow(mContext); ViewUtils.attachView(row); + TestableLooper.get(this).processAllMessages(); ViewUtils.detachView(row); + TestableLooper.get(this).processAllMessages(); } } diff --git a/packages/SystemUI/tests/src/com/android/systemui/statusbar/phone/CollapsedStatusBarFragmentTest.java b/packages/SystemUI/tests/src/com/android/systemui/statusbar/phone/CollapsedStatusBarFragmentTest.java index cb30df4b2f9d..f55115e005b2 100644 --- a/packages/SystemUI/tests/src/com/android/systemui/statusbar/phone/CollapsedStatusBarFragmentTest.java +++ b/packages/SystemUI/tests/src/com/android/systemui/statusbar/phone/CollapsedStatusBarFragmentTest.java @@ -25,16 +25,21 @@ import android.view.ViewPropertyAnimator; import com.android.systemui.FragmentTestCase; import com.android.systemui.R; +import com.android.systemui.SysUIRunner; import com.android.systemui.statusbar.CommandQueue; import com.android.systemui.statusbar.policy.KeyguardMonitor; import com.android.systemui.statusbar.policy.NetworkController; import com.android.systemui.statusbar.policy.SecurityController; import com.android.systemui.tuner.TunerService; +import com.android.systemui.utils.TestableLooper.RunWithLooper; import org.junit.Before; +import org.junit.runner.RunWith; import org.junit.Test; import org.mockito.Mockito; +@RunWith(SysUIRunner.class) +@RunWithLooper(setAsMainLooper = true) public class CollapsedStatusBarFragmentTest extends FragmentTestCase { private NotificationIconAreaController mMockNotificiationAreaController; @@ -59,7 +64,8 @@ public class CollapsedStatusBarFragmentTest extends FragmentTestCase { @Test public void testDisableNone() throws Exception { - postAndWait(() -> mFragments.dispatchResume()); + mFragments.dispatchResume(); + processAllMessages(); CollapsedStatusBarFragment fragment = (CollapsedStatusBarFragment) mFragment; fragment.initNotificationIconArea(mMockNotificiationAreaController); @@ -71,7 +77,8 @@ public class CollapsedStatusBarFragmentTest extends FragmentTestCase { @Test public void testDisableSystemInfo() throws Exception { - postAndWait(() -> mFragments.dispatchResume()); + mFragments.dispatchResume(); + processAllMessages(); CollapsedStatusBarFragment fragment = (CollapsedStatusBarFragment) mFragment; fragment.initNotificationIconArea(mMockNotificiationAreaController); @@ -88,7 +95,8 @@ public class CollapsedStatusBarFragmentTest extends FragmentTestCase { @Test public void testDisableNotifications() throws Exception { - postAndWait(() -> mFragments.dispatchResume()); + mFragments.dispatchResume(); + processAllMessages(); CollapsedStatusBarFragment fragment = (CollapsedStatusBarFragment) mFragment; fragment.initNotificationIconArea(mMockNotificiationAreaController); diff --git a/packages/SystemUI/tests/src/com/android/systemui/statusbar/phone/NavigationBarFragmentTest.java b/packages/SystemUI/tests/src/com/android/systemui/statusbar/phone/NavigationBarFragmentTest.java index 3bce64fe1f20..1fa98461d02d 100644 --- a/packages/SystemUI/tests/src/com/android/systemui/statusbar/phone/NavigationBarFragmentTest.java +++ b/packages/SystemUI/tests/src/com/android/systemui/statusbar/phone/NavigationBarFragmentTest.java @@ -24,13 +24,18 @@ import android.view.WindowManager; import com.android.systemui.Dependency; import com.android.systemui.FragmentTestCase; +import com.android.systemui.SysUIRunner; import com.android.systemui.recents.Recents; import com.android.systemui.stackdivider.Divider; import com.android.systemui.statusbar.CommandQueue; +import com.android.systemui.utils.TestableLooper.RunWithLooper; import org.junit.Before; import org.junit.Test; +import org.junit.runner.RunWith; +@RunWith(SysUIRunner.class) +@RunWithLooper(setAsMainLooper = true) public class NavigationBarFragmentTest extends FragmentTestCase { public NavigationBarFragmentTest() { @@ -56,7 +61,8 @@ public class NavigationBarFragmentTest extends FragmentTestCase { public void testHomeLongPress() { NavigationBarFragment navigationBarFragment = (NavigationBarFragment) mFragment; - postAndWait(() -> mFragments.dispatchResume()); + mFragments.dispatchResume(); + processAllMessages(); navigationBarFragment.onHomeLongClick(navigationBarFragment.getView()); } diff --git a/packages/SystemUI/tests/src/com/android/systemui/statusbar/phone/StatusBarTest.java b/packages/SystemUI/tests/src/com/android/systemui/statusbar/phone/StatusBarTest.java index 21c7fce44579..e8eee24b8dc0 100644 --- a/packages/SystemUI/tests/src/com/android/systemui/statusbar/phone/StatusBarTest.java +++ b/packages/SystemUI/tests/src/com/android/systemui/statusbar/phone/StatusBarTest.java @@ -79,6 +79,12 @@ public class StatusBarTest extends SysuiTestCase { mMetricsReader = new MetricsReader(); mMetricsReader.checkpoint(); // clear out old logs + try { + // pause so that no new events arrive in the rest of this millisecond. + Thread.sleep(2); + } catch (InterruptedException e) { + // pass + } } @Test diff --git a/packages/SystemUI/tests/src/com/android/systemui/utils/TestableLooper.java b/packages/SystemUI/tests/src/com/android/systemui/utils/TestableLooper.java new file mode 100644 index 000000000000..d27597331aa2 --- /dev/null +++ b/packages/SystemUI/tests/src/com/android/systemui/utils/TestableLooper.java @@ -0,0 +1,260 @@ +/* + * Copyright (C) 2017 The Android Open Source Project + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the + * License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the specific language governing + * permissions and limitations under the License. + */ + +package com.android.systemui.utils; + +import android.os.Handler; +import android.os.Looper; +import android.os.Message; +import android.os.MessageQueue; +import android.util.ArrayMap; + +import org.junit.runners.model.Statement; + +import java.lang.annotation.ElementType; +import java.lang.annotation.Retention; +import java.lang.annotation.RetentionPolicy; +import java.lang.annotation.Target; +import java.lang.reflect.Constructor; +import java.lang.reflect.Field; +import java.lang.reflect.Method; +import java.util.Map; + +/** + * Creates a looper on the current thread with control over if/when messages are + * executed. Warning: This class works through some reflection and may break/need + * to be updated from time to time. + */ +public class TestableLooper { + + private final Method mNext; + private final Method mRecycleUnchecked; + + private Looper mLooper; + private MessageQueue mQueue; + private boolean mMain; + private Object mOriginalMain; + private MessageHandler mMessageHandler; + + private int mParsedCount; + private Handler mHandler; + private Message mEmptyMessage; + + public TestableLooper() throws Exception { + this(true); + } + + public TestableLooper(boolean setMyLooper) throws Exception { + setupQueue(setMyLooper); + mNext = mQueue.getClass().getDeclaredMethod("next"); + mNext.setAccessible(true); + mRecycleUnchecked = Message.class.getDeclaredMethod("recycleUnchecked"); + mRecycleUnchecked.setAccessible(true); + } + + public Looper getLooper() { + return mLooper; + } + + private void clearLooper() throws NoSuchFieldException, IllegalAccessException { + Field field = Looper.class.getDeclaredField("sThreadLocal"); + field.setAccessible(true); + ThreadLocal<Looper> sThreadLocal = (ThreadLocal<Looper>) field.get(null); + sThreadLocal.set(null); + } + + private boolean setForCurrentThread() throws NoSuchFieldException, IllegalAccessException { + if (Looper.myLooper() != mLooper) { + Field field = Looper.class.getDeclaredField("sThreadLocal"); + field.setAccessible(true); + ThreadLocal<Looper> sThreadLocal = (ThreadLocal<Looper>) field.get(null); + sThreadLocal.set(mLooper); + return true; + } + return false; + } + + private void setupQueue(boolean setMyLooper) throws Exception { + if (setMyLooper) { + clearLooper(); + Looper.prepare(); + mLooper = Looper.myLooper(); + } else { + Constructor<Looper> constructor = Looper.class.getDeclaredConstructor( + boolean.class); + constructor.setAccessible(true); + mLooper = constructor.newInstance(true); + } + + mQueue = mLooper.getQueue(); + mHandler = new Handler(mLooper); + } + + public void setAsMainLooper() throws NoSuchFieldException, IllegalAccessException { + mMain = true; + setAsMainInt(); + } + + private void setAsMainInt() throws NoSuchFieldException, IllegalAccessException { + Field field = mLooper.getClass().getDeclaredField("sMainLooper"); + field.setAccessible(true); + if (mOriginalMain == null) { + mOriginalMain = field.get(null); + } + field.set(null, mLooper); + } + + /** + * Must be called if setAsMainLooper is called to restore the main looper when the + * test is complete, otherwise the main looper will not be available for any subsequent + * tests. + */ + public void destroy() throws NoSuchFieldException, IllegalAccessException { + if (Looper.myLooper() == mLooper) { + clearLooper(); + } + if (mMain && mOriginalMain != null) { + Field field = mLooper.getClass().getDeclaredField("sMainLooper"); + field.setAccessible(true); + field.set(null, mOriginalMain); + mOriginalMain = null; + } + } + + public void setMessageHandler(MessageHandler handler) { + mMessageHandler = handler; + } + + /** + * Parse num messages from the message queue. + * + * @param num Number of messages to parse + */ + public int processMessages(int num) { + for (int i = 0; i < num; i++) { + if (!parseMessageInt()) { + return i + 1; + } + } + return num; + } + + public void processAllMessages() { + while (processQueuedMessages() != 0) ; + } + + private int processQueuedMessages() { + int count = 0; + mEmptyMessage = mHandler.obtainMessage(1); + mHandler.sendMessageDelayed(mEmptyMessage, 1); + while (parseMessageInt()) count++; + return count; + } + + private boolean parseMessageInt() { + try { + Message result = (Message) mNext.invoke(mQueue); + if (result != null) { + // This is a break message. + if (result == mEmptyMessage) { + mRecycleUnchecked.invoke(result); + return false; + } + + if (mMessageHandler != null) { + if (mMessageHandler.onMessageHandled(result)) { + result.getTarget().dispatchMessage(result); + mRecycleUnchecked.invoke(result); + } else { + mRecycleUnchecked.invoke(result); + // Message handler indicated it doesn't want us to continue. + return false; + } + } else { + result.getTarget().dispatchMessage(result); + mRecycleUnchecked.invoke(result); + } + } else { + // No messages, don't continue parsing + return false; + } + } catch (Exception e) { + throw new RuntimeException(e); + } + return true; + } + + /** + * Runs an executable with myLooper set and processes all messages added. + */ + public void runWithLooper(RunnableWithException runnable) throws Exception { + boolean set = setForCurrentThread(); + runnable.run(); + processAllMessages(); + if (set) clearLooper(); + } + + public interface RunnableWithException { + void run() throws Exception; + } + + @Retention(RetentionPolicy.RUNTIME) + @Target({ElementType.METHOD, ElementType.TYPE}) + public @interface RunWithLooper { + boolean setAsMainLooper() default false; + } + + private static final Map<Object, TestableLooper> sLoopers = new ArrayMap<>(); + + public static TestableLooper get(Object test) { + return sLoopers.get(test); + } + + public static class LooperStatement extends Statement { + private final boolean mSetAsMain; + private final Statement mBase; + private final TestableLooper mLooper; + + public LooperStatement(Statement base, boolean setAsMain, Object test) { + mBase = base; + try { + mLooper = new TestableLooper(false); + sLoopers.put(test, mLooper); + mSetAsMain = setAsMain; + } catch (Exception e) { + throw new RuntimeException(e); + } + } + + @Override + public void evaluate() throws Throwable { + mLooper.setForCurrentThread(); + if (mSetAsMain) { + mLooper.setAsMainLooper(); + } + + mBase.evaluate(); + + mLooper.destroy(); + } + } + + public interface MessageHandler { + /** + * Return true to have the message executed and delivered to target. + * Return false to not execute the message and stop executing messages. + */ + boolean onMessageHandled(Message m); + } +} diff --git a/packages/SystemUI/tests/src/com/android/systemui/utils/TestableLooperTest.java b/packages/SystemUI/tests/src/com/android/systemui/utils/TestableLooperTest.java new file mode 100644 index 000000000000..2416e1d8438f --- /dev/null +++ b/packages/SystemUI/tests/src/com/android/systemui/utils/TestableLooperTest.java @@ -0,0 +1,184 @@ +/* + * Copyright (C) 2017 The Android Open Source Project + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the + * License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the specific language governing + * permissions and limitations under the License. + */ + +package com.android.systemui.utils; + +import static org.junit.Assert.assertEquals; +import static org.junit.Assert.assertNotEquals; +import static org.mockito.Matchers.any; +import static org.mockito.Matchers.eq; +import static org.mockito.Mockito.mock; +import static org.mockito.Mockito.never; +import static org.mockito.Mockito.times; +import static org.mockito.Mockito.verify; +import static org.mockito.Mockito.when; + +import android.os.Handler; +import android.os.Looper; +import android.os.Message; + +import com.android.systemui.SysUIRunner; +import com.android.systemui.SysuiTestCase; +import com.android.systemui.utils.TestableLooper.MessageHandler; +import com.android.systemui.utils.TestableLooper.RunWithLooper; + +import org.junit.After; +import org.junit.Before; +import org.junit.Test; +import org.junit.runner.RunWith; + +@RunWith(SysUIRunner.class) +@RunWithLooper +public class TestableLooperTest extends SysuiTestCase { + + private TestableLooper mTestableLooper; + + @Before + public void setup() throws Exception { + mTestableLooper = TestableLooper.get(this); + } + + @After + public void tearDown() throws Exception { + mTestableLooper.destroy(); + } + + @Test + public void testMessageExecuted() throws Exception { + Handler h = new Handler(); + Runnable r = mock(Runnable.class); + h.post(r); + verify(r, never()).run(); + mTestableLooper.processAllMessages(); + verify(r).run(); + } + + @Test + public void testMessageCallback() throws Exception { + Handler h = new Handler(); + Message m = h.obtainMessage(3); + Runnable r = mock(Runnable.class); + MessageHandler messageHandler = mock(MessageHandler.class); + when(messageHandler.onMessageHandled(any())).thenReturn(false); + mTestableLooper.setMessageHandler(messageHandler); + + m.sendToTarget(); + h.post(r); + + mTestableLooper.processAllMessages(); + + verify(messageHandler).onMessageHandled(eq(m)); + // This should never be run becaus the mock returns false on the first message, and + // the second will get skipped. + verify(r, never()).run(); + } + + @Test + public void testProcessNumberOfMessages() throws Exception { + Handler h = new Handler(); + Runnable r = mock(Runnable.class); + h.post(r); + h.post(r); + h.post(r); + + mTestableLooper.processMessages(2); + + verify(r, times(2)).run(); + } + + @Test + public void testProcessAllMessages() throws Exception { + Handler h = new Handler(); + Runnable r = mock(Runnable.class); + Runnable poster = () -> h.post(r); + h.post(poster); + + mTestableLooper.processAllMessages(); + verify(r).run(); + } + + @Test + public void test3Chain() throws Exception { + Handler h = new Handler(); + Runnable r = mock(Runnable.class); + Runnable poster = () -> h.post(r); + Runnable poster2 = () -> h.post(poster); + h.post(poster2); + + mTestableLooper.processAllMessages(); + verify(r).run(); + } + + @Test + public void testProcessAllMessages_2Messages() throws Exception { + Handler h = new Handler(); + Runnable r = mock(Runnable.class); + Runnable r2 = mock(Runnable.class); + h.post(r); + h.post(r2); + + mTestableLooper.processAllMessages(); + verify(r).run(); + verify(r2).run(); + } + + @Test + public void testMainLooper() throws Exception { + assertNotEquals(Looper.myLooper(), Looper.getMainLooper()); + + Looper originalMain = Looper.getMainLooper(); + mTestableLooper.setAsMainLooper(); + assertEquals(Looper.myLooper(), Looper.getMainLooper()); + Runnable r = mock(Runnable.class); + + new Handler(Looper.getMainLooper()).post(r); + mTestableLooper.processAllMessages(); + + verify(r).run(); + mTestableLooper.destroy(); + + assertEquals(originalMain, Looper.getMainLooper()); + } + + @Test + public void testNotMyLooper() throws Exception { + TestableLooper looper = new TestableLooper(false); + + assertEquals(Looper.myLooper(), mTestableLooper.getLooper()); + assertNotEquals(Looper.myLooper(), looper.getLooper()); + + Runnable r = mock(Runnable.class); + Runnable r2 = mock(Runnable.class); + new Handler().post(r); + new Handler(looper.getLooper()).post(r2); + + looper.processAllMessages(); + verify(r2).run(); + verify(r, never()).run(); + + mTestableLooper.processAllMessages(); + verify(r).run(); + } + + @Test + public void testNonMainLooperAnnotation() { + assertNotEquals(Looper.myLooper(), Looper.getMainLooper()); + } + + @Test + @RunWithLooper(setAsMainLooper = true) + public void testMainLooperAnnotation() { + assertEquals(Looper.myLooper(), Looper.getMainLooper()); + } +} diff --git a/packages/SystemUI/tests/src/com/android/systemui/utils/ViewUtils.java b/packages/SystemUI/tests/src/com/android/systemui/utils/ViewUtils.java index 202c4cfda782..07e5f6663a3f 100644 --- a/packages/SystemUI/tests/src/com/android/systemui/utils/ViewUtils.java +++ b/packages/SystemUI/tests/src/com/android/systemui/utils/ViewUtils.java @@ -34,13 +34,11 @@ public class ViewUtils { Handler handler = new Handler(Looper.getMainLooper()); handler.post(() -> InstrumentationRegistry.getContext() .getSystemService(WindowManager.class).addView(view, lp)); - SysuiTestCase.waitForIdleSync(handler); } public static void detachView(View view) { Handler handler = new Handler(Looper.getMainLooper()); handler.post(() -> InstrumentationRegistry.getContext() .getSystemService(WindowManager.class).removeView(view)); - SysuiTestCase.waitForIdleSync(handler); } } diff --git a/packages/SystemUI/tests/src/com/android/systemui/utils/leaks/LeakCheckedTest.java b/packages/SystemUI/tests/src/com/android/systemui/utils/leaks/LeakCheckedTest.java index 6ff80983f3ef..6c5152496692 100644 --- a/packages/SystemUI/tests/src/com/android/systemui/utils/leaks/LeakCheckedTest.java +++ b/packages/SystemUI/tests/src/com/android/systemui/utils/leaks/LeakCheckedTest.java @@ -149,10 +149,14 @@ public abstract class LeakCheckedTest extends SysuiTestCase { public void injectLeakCheckedDependencies(Class<?>... cls) { for (Class<?> c : cls) { - injectTestDependency(c, getLeakChecker(c)); + injectLeakCheckedDependency(c); } } + public <T> void injectLeakCheckedDependency(Class<T> c) { + injectTestDependency(c, getLeakChecker(c)); + } + public <T extends CallbackController> T addListening(T mock, Class<T> cls, String tag) { doAnswer(new Answer<Void>() { @Override diff --git a/services/autofill/java/com/android/server/autofill/AutoFillManagerServiceImpl.java b/services/autofill/java/com/android/server/autofill/AutoFillManagerServiceImpl.java index 859e1a1ecc3a..9e0b31a76a6e 100644 --- a/services/autofill/java/com/android/server/autofill/AutoFillManagerServiceImpl.java +++ b/services/autofill/java/com/android/server/autofill/AutoFillManagerServiceImpl.java @@ -886,8 +886,10 @@ final class AutoFillManagerServiceImpl { } private AutoFillUI getUiForShowing() { - mUi.setCallback(this, mActivityToken); - return mUi; + synchronized (mLock) { + mUi.setCallbackLocked(this, mActivityToken); + return mUi; + } } private ViewNode findViewNodeByIdLocked(AutoFillId id) { @@ -926,7 +928,7 @@ final class AutoFillManagerServiceImpl { private void destroyLocked() { mRemoteFillService.destroy(); mUi.hideAll(); - mUi.setCallback(null, null); + mUi.setCallbackLocked(null, null); } private void removeSelf() { diff --git a/services/autofill/java/com/android/server/autofill/AutoFillUI.java b/services/autofill/java/com/android/server/autofill/AutoFillUI.java index e9fc0440ba3a..0763c745f121 100644 --- a/services/autofill/java/com/android/server/autofill/AutoFillUI.java +++ b/services/autofill/java/com/android/server/autofill/AutoFillUI.java @@ -100,7 +100,7 @@ final class AutoFillUI { mWm = (WindowManager) context.getSystemService(Context.WINDOW_SERVICE); } - void setCallback(AutoFillUiCallback callback, IBinder activityToken) { + void setCallbackLocked(AutoFillUiCallback callback, IBinder activityToken) { hideAll(); mCallback = callback; mActivityToken = activityToken; @@ -180,7 +180,11 @@ final class AutoFillUI { synchronized (mLock) { callback = mCallback; } - callback.fill(dataset); + if (callback != null) { + callback.fill(dataset); + } else { + Slog.w(TAG, "null callback on showFillUi() for " + viewState.mId); + } hideFillUi(); }); diff --git a/services/autofill/java/com/android/server/autofill/Helper.java b/services/autofill/java/com/android/server/autofill/Helper.java index 7400a64c36f8..0f2bb608ead3 100644 --- a/services/autofill/java/com/android/server/autofill/Helper.java +++ b/services/autofill/java/com/android/server/autofill/Helper.java @@ -38,7 +38,7 @@ final class Helper { static void append(StringBuilder builder, Bundle bundle) { if (bundle == null) { builder.append("N/A"); - } else if (!DEBUG) { + } else if (!VERBOSE) { builder.append(REDACTED); } else { final Set<String> keySet = bundle.keySet(); diff --git a/services/backup/java/com/android/server/backup/BackupManagerService.java b/services/backup/java/com/android/server/backup/BackupManagerService.java index 1592338158e6..c4e2a5399042 100644 --- a/services/backup/java/com/android/server/backup/BackupManagerService.java +++ b/services/backup/java/com/android/server/backup/BackupManagerService.java @@ -9616,7 +9616,14 @@ if (MORE_DEBUG) Slog.v(TAG, " + got " + nRead + "; now wanting " + (size - soF public String[] getTransportWhitelist() { // No permission check, intentionally. - return mTransportManager.getTransportWhitelist().toArray(new String[0]); + Set<ComponentName> whitelistedComponents = mTransportManager.getTransportWhitelist(); + String[] whitelistedTransports = new String[whitelistedComponents.size()]; + int i = 0; + for (ComponentName component : whitelistedComponents) { + whitelistedTransports[i] = component.flattenToShortString(); + i++; + } + return whitelistedTransports; } // Select which transport to use for the next backup operation. diff --git a/services/backup/java/com/android/server/backup/TransportManager.java b/services/backup/java/com/android/server/backup/TransportManager.java index 93d5a1ea8880..b9dbe13af7c8 100644 --- a/services/backup/java/com/android/server/backup/TransportManager.java +++ b/services/backup/java/com/android/server/backup/TransportManager.java @@ -31,6 +31,7 @@ import android.os.IBinder; import android.os.RemoteException; import android.os.UserHandle; import android.util.ArrayMap; +import android.util.ArraySet; import android.util.EventLog; import android.util.Log; import android.util.Slog; @@ -84,7 +85,7 @@ class TransportManager { TransportBoundListener listener) { mContext = context; mPackageManager = context.getPackageManager(); - mTransportWhitelist = whitelist; + mTransportWhitelist = (whitelist != null) ? whitelist : new ArraySet<>(); mCurrentTransportName = defaultTransport; mTransportBoundListener = listener; } diff --git a/services/core/java/com/android/server/InputMethodManagerService.java b/services/core/java/com/android/server/InputMethodManagerService.java index 08cb1094ae38..f0f50f07fcca 100644 --- a/services/core/java/com/android/server/InputMethodManagerService.java +++ b/services/core/java/com/android/server/InputMethodManagerService.java @@ -21,6 +21,7 @@ import static android.view.WindowManager.LayoutParams.TYPE_INPUT_METHOD; import static android.view.WindowManager.LayoutParams.TYPE_INPUT_METHOD_DIALOG; import static java.lang.annotation.RetentionPolicy.SOURCE; +import com.android.internal.annotations.GuardedBy; import com.android.internal.content.PackageMonitor; import com.android.internal.inputmethod.IInputContentUriToken; import com.android.internal.inputmethod.InputMethodSubtypeSwitchingController; @@ -181,6 +182,7 @@ public class InputMethodManagerService extends IInputMethodManager.Stub static final int MSG_SET_ACTIVE = 3020; static final int MSG_SET_INTERACTIVE = 3030; static final int MSG_SET_USER_ACTION_NOTIFICATION_SEQUENCE_NUMBER = 3040; + static final int MSG_REPORT_FULLSCREEN_MODE = 3045; static final int MSG_SWITCH_IME = 3050; static final int MSG_HARD_KEYBOARD_SWITCH_CHANGED = 4000; @@ -411,6 +413,11 @@ public class InputMethodManagerService extends IInputMethodManager.Stub boolean mInputShown; /** + * {@code true} if the current input method is in fullscreen mode. + */ + boolean mInFullscreenMode; + + /** * The Intent used to connect to the current input method. */ Intent mCurIntent; @@ -634,7 +641,28 @@ public class InputMethodManagerService extends IInputMethodManager.Stub Settings.Secure.ENABLED_INPUT_METHODS, mergedImesAndSubtypesString); } - class MyPackageMonitor extends PackageMonitor { + final class MyPackageMonitor extends PackageMonitor { + /** + * Set of packages to be monitored. + * + * <p>No need to include packages because of direct-boot unaware IMEs since we always rescan + * all the packages when the user is unlocked, and direct-boot awareness will not be changed + * dynamically unless the entire package is updated, which also always triggers package + * rescanning.</p> + */ + @GuardedBy("mMethodMap") + private ArraySet<String> mPackagesToMonitorComponentChange = new ArraySet<>(); + + @GuardedBy("mMethodMap") + void clearPackagesToMonitorComponentChangeLocked() { + mPackagesToMonitorComponentChange.clear(); + } + + @GuardedBy("mMethodMap") + final void addPackageToMonitorComponentChangeLocked(@NonNull String packageName) { + mPackagesToMonitorComponentChange.add(packageName); + } + private boolean isChangingPackagesOfCurrentUser() { final int userId = getChangingUserId(); final boolean retval = userId == mSettings.getCurrentUserId(); @@ -676,6 +704,14 @@ public class InputMethodManagerService extends IInputMethodManager.Stub } @Override + public boolean onPackageChanged(String packageName, int uid, String[] components) { + // If this package is in the watch list, we want to check it. + synchronized (mMethodMap) { + return mPackagesToMonitorComponentChange.contains(packageName); + } + } + + @Override public void onSomePackagesChanged() { if (!isChangingPackagesOfCurrentUser()) { return; @@ -1265,8 +1301,8 @@ public class InputMethodManagerService extends IInputMethodManager.Stub } } - executeOrSendMessage(mCurClient.client, mCaller.obtainMessageIO( - MSG_SET_ACTIVE, 0, mCurClient)); + executeOrSendMessage(mCurClient.client, mCaller.obtainMessageIIO( + MSG_SET_ACTIVE, 0, 0, mCurClient)); executeOrSendMessage(mCurClient.client, mCaller.obtainMessageIIO( MSG_UNBIND_CLIENT, mCurSeq, unbindClientReason, mCurClient.client)); mCurClient.sessionRequested = false; @@ -1649,6 +1685,7 @@ public class InputMethodManagerService extends IInputMethodManager.Stub if (mStatusBar != null) { mStatusBar.setIconVisibility(mSlotIme, false); } + mInFullscreenMode = false; } @Override @@ -2915,7 +2952,7 @@ public class InputMethodManagerService extends IInputMethodManager.Stub } case MSG_SET_ACTIVE: try { - ((ClientState)msg.obj).client.setActive(msg.arg1 != 0); + ((ClientState)msg.obj).client.setActive(msg.arg1 != 0, msg.arg2 != 0); } catch (RemoteException e) { Slog.w(TAG, "Got RemoteException sending setActive(false) notification to pid " + ((ClientState)msg.obj).pid + " uid " @@ -2942,6 +2979,18 @@ public class InputMethodManagerService extends IInputMethodManager.Stub } return true; } + case MSG_REPORT_FULLSCREEN_MODE: { + final boolean fullscreen = msg.arg1 != 0; + final ClientState clientState = (ClientState)msg.obj; + try { + clientState.client.reportFullscreenMode(fullscreen); + } catch (RemoteException e) { + Slog.w(TAG, "Got RemoteException sending " + + "reportFullscreen(" + fullscreen + ") notification to pid=" + + clientState.pid + " uid=" + clientState.uid); + } + return true; + } // -------------------------------------------------------------- case MSG_HARD_KEYBOARD_SWITCH_CHANGED: @@ -2962,8 +3011,9 @@ public class InputMethodManagerService extends IInputMethodManager.Stub // Inform the current client of the change in active status if (mCurClient != null && mCurClient.client != null) { - executeOrSendMessage(mCurClient.client, mCaller.obtainMessageIO( - MSG_SET_ACTIVE, mIsInteractive ? 1 : 0, mCurClient)); + executeOrSendMessage(mCurClient.client, mCaller.obtainMessageIIO( + MSG_SET_ACTIVE, mIsInteractive ? 1 : 0, mInFullscreenMode ? 1 : 0, + mCurClient)); } } } @@ -3019,6 +3069,7 @@ public class InputMethodManagerService extends IInputMethodManager.Stub } mMethodList.clear(); mMethodMap.clear(); + mMyPackageMonitor.clearPackagesToMonitorComponentChangeLocked(); // Use for queryIntentServicesAsUser final PackageManager pm = mContext.getPackageManager(); @@ -3061,6 +3112,26 @@ public class InputMethodManagerService extends IInputMethodManager.Stub } } + // Construct the set of possible IME packages for onPackageChanged() to avoid false + // negatives when the package state remains to be the same but only the component state is + // changed. + { + // Here we intentionally use PackageManager.MATCH_DISABLED_COMPONENTS since the purpose + // of this query is to avoid false negatives. PackageManager.MATCH_ALL could be more + // conservative, but it seems we cannot use it for now (Issue 35176630). + final List<ResolveInfo> allInputMethodServices = pm.queryIntentServicesAsUser( + new Intent(InputMethod.SERVICE_INTERFACE), + PackageManager.MATCH_DISABLED_COMPONENTS, mSettings.getCurrentUserId()); + final int N = allInputMethodServices.size(); + for (int i = 0; i < N; ++i) { + final ServiceInfo si = allInputMethodServices.get(i).serviceInfo; + if (!android.Manifest.permission.BIND_INPUT_METHOD.equals(si.permission)) { + continue; + } + mMyPackageMonitor.addPackageToMonitorComponentChangeLocked(si.packageName); + } + } + // TODO: The following code should find better place to live. if (!resetDefaultEnabledIme) { boolean enabledImeFound = false; @@ -3963,6 +4034,23 @@ public class InputMethodManagerService extends IInputMethodManager.Stub } @Override + public void reportFullscreenMode(IBinder token, boolean fullscreen) { + if (!calledFromValidUser()) { + return; + } + synchronized (mMethodMap) { + if (!calledWithValidToken(token)) { + return; + } + if (mCurClient != null && mCurClient.client != null) { + mInFullscreenMode = fullscreen; + executeOrSendMessage(mCurClient.client, mCaller.obtainMessageIO( + MSG_REPORT_FULLSCREEN_MODE, fullscreen ? 1 : 0, mCurClient)); + } + } + } + + @Override protected void dump(FileDescriptor fd, PrintWriter pw, String[] args) { if (mContext.checkCallingOrSelfPermission(android.Manifest.permission.DUMP) != PackageManager.PERMISSION_GRANTED) { @@ -4014,6 +4102,7 @@ public class InputMethodManagerService extends IInputMethodManager.Stub + " mShowExplicitlyRequested=" + mShowExplicitlyRequested + " mShowForced=" + mShowForced + " mInputShown=" + mInputShown); + p.println(" mInFullscreenMode=" + mInFullscreenMode); p.println(" mCurUserActionNotificationSequenceNumber=" + mCurUserActionNotificationSequenceNumber); p.println(" mSystemReady=" + mSystemReady + " mInteractive=" + mIsInteractive); diff --git a/services/core/java/com/android/server/NetworkScoreService.java b/services/core/java/com/android/server/NetworkScoreService.java index 0ac51b90249e..f9b5db6c0b0e 100644 --- a/services/core/java/com/android/server/NetworkScoreService.java +++ b/services/core/java/com/android/server/NetworkScoreService.java @@ -718,6 +718,15 @@ public class NetworkScoreService extends INetworkScoreService.Stub { return null; } + /** + * Returns the list of available scorer apps. The list will be empty if there are + * no valid scorers. + */ + @Override + public List<NetworkScorerAppData> getAllValidScorers() { + return mNetworkScorerAppManager.getAllValidScorers(); + } + @Override public void disableScoring() { // Only the active scorer or the system should be allowed to disable scoring. diff --git a/services/core/java/com/android/server/am/ActiveServices.java b/services/core/java/com/android/server/am/ActiveServices.java index 041fee2352e3..793a163300bd 100644 --- a/services/core/java/com/android/server/am/ActiveServices.java +++ b/services/core/java/com/android/server/am/ActiveServices.java @@ -723,6 +723,39 @@ public final class ActiveServices { if (notification == null) { throw new IllegalArgumentException("null notification"); } + // Instant apps need permission to create foreground services. + if (r.appInfo.isInstantApp()) { + final int mode = mAm.mAppOpsService.checkOperation( + AppOpsManager.OP_INSTANT_APP_START_FOREGROUND, + r.appInfo.uid, + r.appInfo.packageName); + switch (mode) { + case AppOpsManager.MODE_ALLOWED: + break; + case AppOpsManager.MODE_IGNORED: + Slog.w(TAG, "Instant app " + r.appInfo.packageName + + " does not have permission to create foreground services" + + ", ignoring."); + return; + case AppOpsManager.MODE_ERRORED: + throw new SecurityException("Instant app " + r.appInfo.packageName + + " does not have permission to create foreground services"); + default: + try { + if (AppGlobals.getPackageManager().checkPermission( + android.Manifest.permission.INSTANT_APP_FOREGROUND_SERVICE, + r.appInfo.packageName, + r.appInfo.uid) != PackageManager.PERMISSION_GRANTED) { + throw new SecurityException("Instant app " + r.appInfo.packageName + + " does not have permission to create foreground" + + "services"); + } + } catch (RemoteException e) { + throw new SecurityException("Failed to check instant app permission." , + e); + } + } + } if (r.foregroundId != id) { cancelForegroudNotificationLocked(r); r.foregroundId = id; diff --git a/services/core/java/com/android/server/am/ActivityManagerService.java b/services/core/java/com/android/server/am/ActivityManagerService.java index 3ab4e6d9517b..69a3a263bbf8 100644 --- a/services/core/java/com/android/server/am/ActivityManagerService.java +++ b/services/core/java/com/android/server/am/ActivityManagerService.java @@ -8115,8 +8115,8 @@ public class ActivityManagerService extends IActivityManager.Stub // of service-launch policy, allow those callers to proceed unrestricted. int appServicesRestrictedInBackgroundLocked(int uid, String packageName, int packageTargetSdk) { // Persistent app? NB: expects that persistent uids are always active. - final UidRecord uidRec = mActiveUids.get(uid); - if (uidRec != null && uidRec.persistent) { + final UidRecord appIdRec = mActiveUids.get(UserHandle.getAppId(uid)); + if (appIdRec != null && appIdRec.persistent) { if (DEBUG_BACKGROUND_CHECK) { Slog.i(TAG, "App " + uid + "/" + packageName + " is persistent; not restricted in background"); diff --git a/services/core/java/com/android/server/am/TaskRecord.java b/services/core/java/com/android/server/am/TaskRecord.java index e237e41a3d52..80ed8333fdc4 100644 --- a/services/core/java/com/android/server/am/TaskRecord.java +++ b/services/core/java/com/android/server/am/TaskRecord.java @@ -969,18 +969,9 @@ final class TaskRecord extends ConfigurationContainer implements TaskWindowConta || topRunningActivityLocked() != null; } - void setFrontOfTask() { - setFrontOfTask(null); - } - /** Call after activity movement or finish to make sure that frontOfTask is set correctly */ - void setFrontOfTask(ActivityRecord newTop) { - // If a top candidate is suggested by the caller, go ahead and use it and mark all others - // as not front. This is needed in situations where the current front activity in the - // task isn't finished yet and we want to set the front to the activity moved to the front - // of the task. - boolean foundFront = newTop != null ? true : false; - + final void setFrontOfTask() { + boolean foundFront = false; final int numActivities = mActivities.size(); for (int activityNdx = 0; activityNdx < numActivities; ++activityNdx) { final ActivityRecord r = mActivities.get(activityNdx); @@ -997,9 +988,6 @@ final class TaskRecord extends ConfigurationContainer implements TaskWindowConta // activity, make the bottom activity front. mActivities.get(0).frontOfTask = true; } - if (newTop != null) { - newTop.frontOfTask = true; - } } /** @@ -1014,7 +1002,7 @@ final class TaskRecord extends ConfigurationContainer implements TaskWindowConta mActivities.add(newTop); updateEffectiveIntent(); - setFrontOfTask(newTop); + setFrontOfTask(); } void addActivityAtBottom(ActivityRecord r) { diff --git a/services/core/java/com/android/server/audio/AudioService.java b/services/core/java/com/android/server/audio/AudioService.java index 1d60946129a7..0860e5b18d39 100644 --- a/services/core/java/com/android/server/audio/AudioService.java +++ b/services/core/java/com/android/server/audio/AudioService.java @@ -778,7 +778,8 @@ public class AudioService extends IAudioService.Stub 0, 0, TAG, - SAFE_VOLUME_CONFIGURE_TIMEOUT_MS); + SystemProperties.getBoolean("audio.safemedia.bypass", false) ? + 0 : SAFE_VOLUME_CONFIGURE_TIMEOUT_MS); initA11yMonitoring(); onIndicateSystemReady(); diff --git a/services/core/java/com/android/server/clipboard/ClipboardService.java b/services/core/java/com/android/server/clipboard/ClipboardService.java index 4487d5b9b28e..94417b531c71 100644 --- a/services/core/java/com/android/server/clipboard/ClipboardService.java +++ b/services/core/java/com/android/server/clipboard/ClipboardService.java @@ -404,9 +404,11 @@ public class ClipboardService extends SystemService { return; } clipboard.primaryClip = clip; - final ClipDescription description = clipboard.primaryClip.getDescription(); - if (description != null) { - description.setTimestamp(SystemClock.elapsedRealtime()); + if (clip != null) { + final ClipDescription description = clip.getDescription(); + if (description != null) { + description.setTimestamp(SystemClock.elapsedRealtime()); + } } final long ident = Binder.clearCallingIdentity(); final int n = clipboard.primaryClipListeners.beginBroadcast(); diff --git a/services/core/java/com/android/server/emergency/EmergencyAffordanceService.java b/services/core/java/com/android/server/emergency/EmergencyAffordanceService.java index 353f4506e1e9..98771dfa1f33 100644 --- a/services/core/java/com/android/server/emergency/EmergencyAffordanceService.java +++ b/services/core/java/com/android/server/emergency/EmergencyAffordanceService.java @@ -245,23 +245,25 @@ public class EmergencyAffordanceService extends SystemService { } } } - if (neededNow != neededBefore) { - setSimNeedsEmergencyAffordance(neededNow); - } + setSimNeedsEmergencyAffordance(neededNow); return neededNow; } private void setSimNeedsEmergencyAffordance(boolean simNeedsEmergencyAffordance) { - mSimNeedsEmergencyAffordance = simNeedsEmergencyAffordance; - Settings.Global.putInt(mContext.getContentResolver(), - EMERGENCY_SIM_INSERTED_SETTING, - simNeedsEmergencyAffordance ? 1 : 0); - updateEmergencyAffordanceNeeded(); + if (simNeededAffordanceBefore() != simNeedsEmergencyAffordance) { + Settings.Global.putInt(mContext.getContentResolver(), + EMERGENCY_SIM_INSERTED_SETTING, + simNeedsEmergencyAffordance ? 1 : 0); + } + if (simNeedsEmergencyAffordance != mSimNeedsEmergencyAffordance) { + mSimNeedsEmergencyAffordance = simNeedsEmergencyAffordance; + updateEmergencyAffordanceNeeded(); + } } private boolean simNeededAffordanceBefore() { return Settings.Global.getInt(mContext.getContentResolver(), - "emergency_sim_inserted_before", 0) != 0; + EMERGENCY_SIM_INSERTED_SETTING, 0) != 0; } private boolean handleUpdateCellInfo() { diff --git a/services/core/java/com/android/server/wm/WindowManagerService.java b/services/core/java/com/android/server/wm/WindowManagerService.java index 597e8b6ac8fc..be0771ae97b5 100644 --- a/services/core/java/com/android/server/wm/WindowManagerService.java +++ b/services/core/java/com/android/server/wm/WindowManagerService.java @@ -22,8 +22,11 @@ import static android.Manifest.permission.REGISTER_WINDOW_MANAGER_LISTENERS; import static android.app.ActivityManager.DOCKED_STACK_CREATE_MODE_TOP_OR_LEFT; import static android.app.ActivityManager.StackId.PINNED_STACK_ID; import static android.app.StatusBarManager.DISABLE_MASK; +import static android.content.Intent.ACTION_USER_REMOVED; +import static android.content.Intent.EXTRA_USER_HANDLE; import static android.content.pm.ActivityInfo.SCREEN_ORIENTATION_UNSPECIFIED; import static android.content.pm.PackageManager.PERMISSION_GRANTED; +import static android.os.UserHandle.USER_NULL; import static android.view.Display.DEFAULT_DISPLAY; import static android.view.WindowManager.DOCKED_INVALID; import static android.view.WindowManager.LayoutParams.FIRST_APPLICATION_WINDOW; @@ -346,6 +349,13 @@ public class WindowManagerService extends IWindowManager.Stub if (DevicePolicyManager.ACTION_DEVICE_POLICY_MANAGER_STATE_CHANGED.equals(action)) { mKeyguardDisableHandler.sendEmptyMessage( KeyguardDisableHandler.KEYGUARD_POLICY_CHANGED); + } else if (ACTION_USER_REMOVED.equals(action)) { + final int userId = intent.getIntExtra(EXTRA_USER_HANDLE, USER_NULL); + if (userId != USER_NULL) { + synchronized (mWindowMap) { + mScreenCaptureDisabled.remove(userId); + } + } } } }; @@ -1021,9 +1031,11 @@ public class WindowManagerService extends IWindowManager.Stub setAnimatorDurationScale(Settings.Global.getFloat(context.getContentResolver(), Settings.Global.ANIMATOR_DURATION_SCALE, mAnimatorDurationScaleSetting)); - // Track changes to DevicePolicyManager state so we can enable/disable keyguard. IntentFilter filter = new IntentFilter(); + // Track changes to DevicePolicyManager state so we can enable/disable keyguard. filter.addAction(DevicePolicyManager.ACTION_DEVICE_POLICY_MANAGER_STATE_CHANGED); + // Listen to user removal broadcasts so that we can remove the user-specific data. + filter.addAction(Intent.ACTION_USER_REMOVED); mContext.registerReceiver(mBroadcastReceiver, filter); mSettingsObserver = new SettingsObserver(); diff --git a/services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java b/services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java index 5075a41aae3b..5bd2e930f63a 100644 --- a/services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java +++ b/services/devicepolicy/java/com/android/server/devicepolicy/DevicePolicyManagerService.java @@ -1886,11 +1886,14 @@ public class DevicePolicyManagerService extends IDevicePolicyManager.Stub { } private void setDeviceOwnerSystemPropertyLocked() { - // Device owner may still be provisioned, do not set the read-only system property yet. - // Wear devices don't set device_provisioned until the device is paired, so allow - // device_owner property to be set without that. - if (!mIsWatch - && mInjector.settingsGlobalGetInt(Settings.Global.DEVICE_PROVISIONED, 0) == 0) { + final boolean deviceProvisioned = + mInjector.settingsGlobalGetInt(Settings.Global.DEVICE_PROVISIONED, 0) != 0; + // If the device is not provisioned and there is currently no device owner, do not set the + // read-only system property yet, since Device owner may still be provisioned. For Wear + // devices, if there is already a device owner then it's OK to set the property to true now, + // regardless the provision state. + final boolean isWatchWithDeviceOwner = mIsWatch && mOwners.hasDeviceOwner(); + if (!isWatchWithDeviceOwner && !deviceProvisioned) { return; } // Still at the first stage of CryptKeeper double bounce, mOwners.hasDeviceOwner is diff --git a/services/tests/servicestests/src/com/android/server/wm/WindowFrameTests.java b/services/tests/servicestests/src/com/android/server/wm/WindowFrameTests.java index 98ff0e254a19..28b6e45dc8da 100644 --- a/services/tests/servicestests/src/com/android/server/wm/WindowFrameTests.java +++ b/services/tests/servicestests/src/com/android/server/wm/WindowFrameTests.java @@ -338,9 +338,12 @@ public class WindowFrameTests { w.mDockedResizingForTest = true; w.calculatePolicyCrop(policyCrop); - // But if we are docked resizing it won't be. + // But if we are docked resizing it won't be, however we will still be + // shrunk to the decor frame and the display. final DisplayInfo displayInfo = w.getDisplayContent().getDisplayInfo(); - assertRect(policyCrop, 0, 0, 1000, 1000); + assertRect(policyCrop, 0, 0, + Math.min(pf.width(), displayInfo.logicalWidth), + Math.min(pf.height(), displayInfo.logicalHeight)); } private WindowStateWithTask createWindow(Task task, int width, int height) { diff --git a/tools/aapt2/Main.cpp b/tools/aapt2/Main.cpp index 227ffa34af4c..ba378d716793 100644 --- a/tools/aapt2/Main.cpp +++ b/tools/aapt2/Main.cpp @@ -25,7 +25,7 @@ namespace aapt { static const char* sMajorVersion = "2"; // Update minor version whenever a feature or flag is added. -static const char* sMinorVersion = "6"; +static const char* sMinorVersion = "7"; int PrintVersion() { std::cerr << "Android Asset Packaging Tool (aapt) " << sMajorVersion << "." diff --git a/tools/aapt2/ResourceParser.cpp b/tools/aapt2/ResourceParser.cpp index 1c750c6748b9..47ca2660f15a 100644 --- a/tools/aapt2/ResourceParser.cpp +++ b/tools/aapt2/ResourceParser.cpp @@ -26,6 +26,7 @@ #include "ResourceValues.h" #include "ValueVisitor.h" #include "util/ImmutableMap.h" +#include "util/Maybe.h" #include "util/Util.h" #include "xml/XmlPullParser.h" @@ -150,82 +151,108 @@ ResourceParser::ResourceParser(IDiagnostics* diag, ResourceTable* table, /** * Build a string from XML that converts nested elements into Span objects. */ -bool ResourceParser::FlattenXmlSubtree(xml::XmlPullParser* parser, - std::string* out_raw_string, - StyleString* out_style_string) { +bool ResourceParser::FlattenXmlSubtree( + xml::XmlPullParser* parser, std::string* out_raw_string, StyleString* out_style_string, + std::vector<UntranslatableSection>* out_untranslatable_sections) { + // Keeps track of formatting tags (<b>, <i>) and the range of characters for which they apply. std::vector<Span> span_stack; - bool error = false; + // Clear the output variables. out_raw_string->clear(); out_style_string->spans.clear(); + out_untranslatable_sections->clear(); + + // The StringBuilder will concatenate the various segments of text which are initially + // separated by tags. It also handles unicode escape codes and quotations. util::StringBuilder builder; + + // The first occurrence of a <xliff:g> tag. Nested <xliff:g> tags are illegal. + Maybe<size_t> untranslatable_start_depth; + size_t depth = 1; while (xml::XmlPullParser::IsGoodEvent(parser->Next())) { const xml::XmlPullParser::Event event = parser->event(); - if (event == xml::XmlPullParser::Event::kEndElement) { - if (!parser->element_namespace().empty()) { - // We already warned and skipped the start element, so just skip here - // too - continue; - } - - depth--; - if (depth == 0) { - break; - } - span_stack.back().last_char = builder.Utf16Len() - 1; - out_style_string->spans.push_back(span_stack.back()); - span_stack.pop_back(); + if (event == xml::XmlPullParser::Event::kStartElement) { + if (parser->element_namespace().empty()) { + // This is an HTML tag which we encode as a span. Add it to the span stack. + std::string span_name = parser->element_name(); + const auto end_attr_iter = parser->end_attributes(); + for (auto attr_iter = parser->begin_attributes(); attr_iter != end_attr_iter; ++attr_iter) { + span_name += ";"; + span_name += attr_iter->name; + span_name += "="; + span_name += attr_iter->value; + } - } else if (event == xml::XmlPullParser::Event::kText) { - out_raw_string->append(parser->text()); - builder.Append(parser->text()); + // Make sure the string is representable in our binary format. + if (builder.Utf16Len() > std::numeric_limits<uint32_t>::max()) { + diag_->Error(DiagMessage(source_.WithLine(parser->line_number())) + << "style string '" << builder.ToString() << "' is too long"); + return false; + } - } else if (event == xml::XmlPullParser::Event::kStartElement) { - if (!parser->element_namespace().empty()) { - if (parser->element_namespace() != sXliffNamespaceUri) { - // Only warn if this isn't an xliff namespace. - diag_->Warn(DiagMessage(source_.WithLine(parser->line_number())) - << "skipping element '" << parser->element_name() - << "' with unknown namespace '" - << parser->element_namespace() << "'"); + span_stack.push_back(Span{std::move(span_name), static_cast<uint32_t>(builder.Utf16Len())}); + } else if (parser->element_namespace() == sXliffNamespaceUri) { + if (parser->element_name() == "g") { + if (untranslatable_start_depth) { + // We've already encountered an <xliff:g> tag, and nested <xliff:g> tags are illegal. + diag_->Error(DiagMessage(source_.WithLine(parser->line_number())) + << "illegal nested XLIFF 'g' tag"); + return false; + } else { + // Mark the start of an untranslatable section. Use UTF8 indices/lengths. + untranslatable_start_depth = depth; + const size_t current_idx = builder.ToString().size(); + out_untranslatable_sections->push_back(UntranslatableSection{current_idx, current_idx}); + } } - continue; - } - depth++; + // Ignore other xliff tags, they get handled by other tools. - // Build a span object out of the nested element. - std::string span_name = parser->element_name(); - const auto end_attr_iter = parser->end_attributes(); - for (auto attr_iter = parser->begin_attributes(); - attr_iter != end_attr_iter; ++attr_iter) { - span_name += ";"; - span_name += attr_iter->name; - span_name += "="; - span_name += attr_iter->value; + } else { + // Besides XLIFF, any other namespaced tag is unsupported and ignored. + diag_->Warn(DiagMessage(source_.WithLine(parser->line_number())) + << "ignoring element '" << parser->element_name() + << "' with unknown namespace '" << parser->element_namespace() << "'"); } - if (builder.Utf16Len() > std::numeric_limits<uint32_t>::max()) { - diag_->Error(DiagMessage(source_.WithLine(parser->line_number())) - << "style string '" << builder.ToString() - << "' is too long"); - error = true; - } else { - span_stack.push_back( - Span{span_name, static_cast<uint32_t>(builder.Utf16Len())}); + // Enter one level inside the element. + depth++; + } else if (event == xml::XmlPullParser::Event::kText) { + // Record both the raw text and append to the builder to deal with escape sequences + // and quotations. + out_raw_string->append(parser->text()); + builder.Append(parser->text()); + } else if (event == xml::XmlPullParser::Event::kEndElement) { + // Return one level from within the element. + depth--; + if (depth == 0) { + break; } + if (parser->element_namespace().empty()) { + // This is an HTML tag which we encode as a span. Update the span + // stack and pop the top entry. + Span& top_span = span_stack.back(); + top_span.last_char = builder.Utf16Len() - 1; + out_style_string->spans.push_back(std::move(top_span)); + span_stack.pop_back(); + } else if (untranslatable_start_depth == make_value(depth)) { + // This is the end of an untranslatable section. Use UTF8 indices/lengths. + UntranslatableSection& untranslatable_section = out_untranslatable_sections->back(); + untranslatable_section.end = builder.ToString().size(); + untranslatable_start_depth = {}; + } } else if (event == xml::XmlPullParser::Event::kComment) { - // Skip + // Ignore. } else { LOG(FATAL) << "unhandled XML event"; } } - CHECK(span_stack.empty()) << "spans haven't been fully processed"; + CHECK(span_stack.empty()) << "spans haven't been fully processed"; out_style_string->str = builder.ToString(); - return !error; + return true; } bool ResourceParser::Parse(xml::XmlPullParser* parser) { @@ -548,15 +575,18 @@ std::unique_ptr<Item> ResourceParser::ParseXml(xml::XmlPullParser* parser, std::string raw_value; StyleString style_string; - if (!FlattenXmlSubtree(parser, &raw_value, &style_string)) { + std::vector<UntranslatableSection> untranslatable_sections; + if (!FlattenXmlSubtree(parser, &raw_value, &style_string, &untranslatable_sections)) { return {}; } if (!style_string.spans.empty()) { // This can only be a StyledString. - return util::make_unique<StyledString>(table_->string_pool.MakeRef( - style_string, - StringPool::Context(StringPool::Context::kStylePriority, config_))); + std::unique_ptr<StyledString> styled_string = + util::make_unique<StyledString>(table_->string_pool.MakeRef( + style_string, StringPool::Context(StringPool::Context::kStylePriority, config_))); + styled_string->untranslatable_sections = std::move(untranslatable_sections); + return std::move(styled_string); } auto on_create_reference = [&](const ResourceName& name) { @@ -582,8 +612,10 @@ std::unique_ptr<Item> ResourceParser::ParseXml(xml::XmlPullParser* parser, // Try making a regular string. if (type_mask & android::ResTable_map::TYPE_STRING) { // Use the trimmed, escaped string. - return util::make_unique<String>(table_->string_pool.MakeRef( - style_string.str, StringPool::Context(config_))); + std::unique_ptr<String> string = util::make_unique<String>( + table_->string_pool.MakeRef(style_string.str, StringPool::Context(config_))); + string->untranslatable_sections = std::move(untranslatable_sections); + return std::move(string); } if (allow_raw_value) { @@ -609,17 +641,15 @@ bool ResourceParser::ParseString(xml::XmlPullParser* parser, formatted = maybe_formatted.value(); } - bool translateable = options_.translatable; - if (Maybe<StringPiece> translateable_attr = - xml::FindAttribute(parser, "translatable")) { - Maybe<bool> maybe_translateable = - ResourceUtils::ParseBool(translateable_attr.value()); - if (!maybe_translateable) { + bool translatable = options_.translatable; + if (Maybe<StringPiece> translatable_attr = xml::FindAttribute(parser, "translatable")) { + Maybe<bool> maybe_translatable = ResourceUtils::ParseBool(translatable_attr.value()); + if (!maybe_translatable) { diag_->Error(DiagMessage(out_resource->source) << "invalid value for 'translatable'. Must be a boolean"); return false; } - translateable = maybe_translateable.value(); + translatable = maybe_translatable.value(); } out_resource->value = @@ -630,9 +660,9 @@ bool ResourceParser::ParseString(xml::XmlPullParser* parser, } if (String* string_value = ValueCast<String>(out_resource->value.get())) { - string_value->SetTranslateable(translateable); + string_value->SetTranslatable(translatable); - if (formatted && translateable) { + if (formatted && translatable) { if (!util::VerifyJavaStringFormat(*string_value->value)) { DiagMessage msg(out_resource->source); msg << "multiple substitutions specified in non-positional format; " @@ -646,9 +676,8 @@ bool ResourceParser::ParseString(xml::XmlPullParser* parser, } } - } else if (StyledString* string_value = - ValueCast<StyledString>(out_resource->value.get())) { - string_value->SetTranslateable(translateable); + } else if (StyledString* string_value = ValueCast<StyledString>(out_resource->value.get())) { + string_value->SetTranslatable(translatable); } return true; } @@ -1151,19 +1180,17 @@ bool ResourceParser::ParseArrayImpl(xml::XmlPullParser* parser, std::unique_ptr<Array> array = util::make_unique<Array>(); - bool translateable = options_.translatable; - if (Maybe<StringPiece> translateable_attr = - xml::FindAttribute(parser, "translatable")) { - Maybe<bool> maybe_translateable = - ResourceUtils::ParseBool(translateable_attr.value()); - if (!maybe_translateable) { + bool translatable = options_.translatable; + if (Maybe<StringPiece> translatable_attr = xml::FindAttribute(parser, "translatable")) { + Maybe<bool> maybe_translatable = ResourceUtils::ParseBool(translatable_attr.value()); + if (!maybe_translatable) { diag_->Error(DiagMessage(out_resource->source) << "invalid value for 'translatable'. Must be a boolean"); return false; } - translateable = maybe_translateable.value(); + translatable = maybe_translatable.value(); } - array->SetTranslateable(translateable); + array->SetTranslatable(translatable); bool error = false; const size_t depth = parser->depth(); diff --git a/tools/aapt2/ResourceParser.h b/tools/aapt2/ResourceParser.h index cc0fa26f44d5..825801995862 100644 --- a/tools/aapt2/ResourceParser.h +++ b/tools/aapt2/ResourceParser.h @@ -60,16 +60,16 @@ class ResourceParser { private: DISALLOW_COPY_AND_ASSIGN(ResourceParser); - /* - * Parses the XML subtree as a StyleString (flattened XML representation for - * strings - * with formatting). If successful, `out_style_string` - * contains the escaped and whitespace trimmed text, while `out_raw_string` - * contains the unescaped text. Returns true on success. - */ - bool FlattenXmlSubtree(xml::XmlPullParser* parser, - std::string* out_raw_string, - StyleString* out_style_string); + // Parses the XML subtree as a StyleString (flattened XML representation for strings with + // formatting). If parsing fails, false is returned and the out parameters are left in an + // unspecified state. Otherwise, + // `out_style_string` contains the escaped and whitespace trimmed text. + // `out_raw_string` contains the un-escaped text. + // `out_untranslatable_sections` contains the sections of the string that should not be + // translated. + bool FlattenXmlSubtree(xml::XmlPullParser* parser, std::string* out_raw_string, + StyleString* out_style_string, + std::vector<UntranslatableSection>* out_untranslatable_sections); /* * Parses the XML subtree and returns an Item. diff --git a/tools/aapt2/ResourceParser_test.cpp b/tools/aapt2/ResourceParser_test.cpp index cf901dae11bb..67ed476b7a99 100644 --- a/tools/aapt2/ResourceParser_test.cpp +++ b/tools/aapt2/ResourceParser_test.cpp @@ -76,6 +76,7 @@ TEST_F(ResourceParserTest, ParseQuotedString) { String* str = test::GetValue<String>(&table_, "string/foo"); ASSERT_NE(nullptr, str); EXPECT_EQ(std::string(" hey there "), *str->value); + EXPECT_TRUE(str->untranslatable_sections.empty()); } TEST_F(ResourceParserTest, ParseEscapedString) { @@ -85,6 +86,7 @@ TEST_F(ResourceParserTest, ParseEscapedString) { String* str = test::GetValue<String>(&table_, "string/foo"); ASSERT_NE(nullptr, str); EXPECT_EQ(std::string("?123"), *str->value); + EXPECT_TRUE(str->untranslatable_sections.empty()); } TEST_F(ResourceParserTest, ParseFormattedString) { @@ -97,8 +99,7 @@ TEST_F(ResourceParserTest, ParseFormattedString) { TEST_F(ResourceParserTest, ParseStyledString) { // Use a surrogate pair unicode point so that we can verify that the span - // indices - // use UTF-16 length and not UTF-18 length. + // indices use UTF-16 length and not UTF-8 length. std::string input = "<string name=\"foo\">This is my aunt\u2019s <b>string</b></string>"; ASSERT_TRUE(TestParse(input)); @@ -109,6 +110,7 @@ TEST_F(ResourceParserTest, ParseStyledString) { const std::string expected_str = "This is my aunt\u2019s string"; EXPECT_EQ(expected_str, *str->value->str); EXPECT_EQ(1u, str->value->spans.size()); + EXPECT_TRUE(str->untranslatable_sections.empty()); EXPECT_EQ(std::string("b"), *str->value->spans[0].name); EXPECT_EQ(17u, str->value->spans[0].first_char); @@ -122,6 +124,7 @@ TEST_F(ResourceParserTest, ParseStringWithWhitespace) { String* str = test::GetValue<String>(&table_, "string/foo"); ASSERT_NE(nullptr, str); EXPECT_EQ(std::string("This is what I think"), *str->value); + EXPECT_TRUE(str->untranslatable_sections.empty()); input = "<string name=\"foo2\">\" This is what I think \"</string>"; ASSERT_TRUE(TestParse(input)); @@ -131,16 +134,61 @@ TEST_F(ResourceParserTest, ParseStringWithWhitespace) { EXPECT_EQ(std::string(" This is what I think "), *str->value); } -TEST_F(ResourceParserTest, IgnoreXliffTags) { - std::string input = - "<string name=\"foo\" \n" - " xmlns:xliff=\"urn:oasis:names:tc:xliff:document:1.2\">\n" - " There are <xliff:g id=\"count\">%1$d</xliff:g> apples</string>"; +TEST_F(ResourceParserTest, IgnoreXliffTagsOtherThanG) { + std::string input = R"EOF( + <string name="foo" xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2"> + There are <xliff:source>no</xliff:source> apples</string>)EOF"; + ASSERT_TRUE(TestParse(input)); + + String* str = test::GetValue<String>(&table_, "string/foo"); + ASSERT_NE(nullptr, str); + EXPECT_EQ(StringPiece("There are no apples"), StringPiece(*str->value)); + EXPECT_TRUE(str->untranslatable_sections.empty()); +} + +TEST_F(ResourceParserTest, NestedXliffGTagsAreIllegal) { + std::string input = R"EOF( + <string name="foo" xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2"> + Do not <xliff:g>translate <xliff:g>this</xliff:g></xliff:g></string>)EOF"; + EXPECT_FALSE(TestParse(input)); +} + +TEST_F(ResourceParserTest, RecordUntranslateableXliffSectionsInString) { + std::string input = R"EOF( + <string name="foo" xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2"> + There are <xliff:g id="count">%1$d</xliff:g> apples</string>)EOF"; ASSERT_TRUE(TestParse(input)); String* str = test::GetValue<String>(&table_, "string/foo"); ASSERT_NE(nullptr, str); EXPECT_EQ(StringPiece("There are %1$d apples"), StringPiece(*str->value)); + + ASSERT_EQ(1u, str->untranslatable_sections.size()); + + // We expect indices and lengths that span to include the whitespace + // before %1$d. This is due to how the StringBuilder withholds whitespace unless + // needed (to deal with line breaks, etc.). + EXPECT_EQ(9u, str->untranslatable_sections[0].start); + EXPECT_EQ(14u, str->untranslatable_sections[0].end); +} + +TEST_F(ResourceParserTest, RecordUntranslateableXliffSectionsInStyledString) { + std::string input = R"EOF( + <string name="foo" xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2"> + There are <b><xliff:g id="count">%1$d</xliff:g></b> apples</string>)EOF"; + ASSERT_TRUE(TestParse(input)); + + StyledString* str = test::GetValue<StyledString>(&table_, "string/foo"); + ASSERT_NE(nullptr, str); + EXPECT_EQ(StringPiece("There are %1$d apples"), StringPiece(*str->value->str)); + + ASSERT_EQ(1u, str->untranslatable_sections.size()); + + // We expect indices and lengths that span to include the whitespace + // before %1$d. This is due to how the StringBuilder withholds whitespace unless + // needed (to deal with line breaks, etc.). + EXPECT_EQ(9u, str->untranslatable_sections[0].start); + EXPECT_EQ(14u, str->untranslatable_sections[0].end); } TEST_F(ResourceParserTest, ParseNull) { @@ -149,15 +197,11 @@ TEST_F(ResourceParserTest, ParseNull) { // The Android runtime treats a value of android::Res_value::TYPE_NULL as // a non-existing value, and this causes problems in styles when trying to - // resolve - // an attribute. Null values must be encoded as - // android::Res_value::TYPE_REFERENCE + // resolve an attribute. Null values must be encoded as android::Res_value::TYPE_REFERENCE // with a data value of 0. - BinaryPrimitive* integer = - test::GetValue<BinaryPrimitive>(&table_, "integer/foo"); + BinaryPrimitive* integer = test::GetValue<BinaryPrimitive>(&table_, "integer/foo"); ASSERT_NE(nullptr, integer); - EXPECT_EQ(uint16_t(android::Res_value::TYPE_REFERENCE), - integer->value.dataType); + EXPECT_EQ(uint16_t(android::Res_value::TYPE_REFERENCE), integer->value.dataType); EXPECT_EQ(0u, integer->value.data); } diff --git a/tools/aapt2/ResourceValues.cpp b/tools/aapt2/ResourceValues.cpp index 7956ad826acd..f75ed7ad978a 100644 --- a/tools/aapt2/ResourceValues.cpp +++ b/tools/aapt2/ResourceValues.cpp @@ -140,7 +140,23 @@ bool String::Equals(const Value* value) const { if (!other) { return false; } - return *this->value == *other->value; + + if (this->value != other->value) { + return false; + } + + if (untranslatable_sections.size() != other->untranslatable_sections.size()) { + return false; + } + + auto other_iter = other->untranslatable_sections.begin(); + for (const UntranslatableSection& this_section : untranslatable_sections) { + if (this_section != *other_iter) { + return false; + } + ++other_iter; + } + return true; } bool String::Flatten(android::Res_value* out_value) const { @@ -158,6 +174,7 @@ String* String::Clone(StringPool* new_pool) const { String* str = new String(new_pool->MakeRef(*value)); str->comment_ = comment_; str->source_ = source_; + str->untranslatable_sections = untranslatable_sections; return str; } @@ -173,17 +190,22 @@ bool StyledString::Equals(const Value* value) const { return false; } - if (*this->value->str == *other->value->str) { - const std::vector<StringPool::Span>& spans_a = this->value->spans; - const std::vector<StringPool::Span>& spans_b = other->value->spans; - return std::equal( - spans_a.begin(), spans_a.end(), spans_b.begin(), - [](const StringPool::Span& a, const StringPool::Span& b) -> bool { - return *a.name == *b.name && a.first_char == b.first_char && - a.last_char == b.last_char; - }); + if (this->value != other->value) { + return false; + } + + if (untranslatable_sections.size() != other->untranslatable_sections.size()) { + return false; + } + + auto other_iter = other->untranslatable_sections.begin(); + for (const UntranslatableSection& this_section : untranslatable_sections) { + if (this_section != *other_iter) { + return false; + } + ++other_iter; } - return false; + return true; } bool StyledString::Flatten(android::Res_value* out_value) const { @@ -200,6 +222,7 @@ StyledString* StyledString::Clone(StringPool* new_pool) const { StyledString* str = new StyledString(new_pool->MakeRef(value)); str->comment_ = comment_; str->source_ = source_; + str->untranslatable_sections = untranslatable_sections; return str; } @@ -218,7 +241,7 @@ bool FileReference::Equals(const Value* value) const { if (!other) { return false; } - return *path == *other->path; + return path == other->path; } bool FileReference::Flatten(android::Res_value* out_value) const { diff --git a/tools/aapt2/ResourceValues.h b/tools/aapt2/ResourceValues.h index d380f8d0583d..c71c738892da 100644 --- a/tools/aapt2/ResourceValues.h +++ b/tools/aapt2/ResourceValues.h @@ -34,44 +34,35 @@ namespace aapt { struct RawValueVisitor; -/** - * A resource value. This is an all-encompassing representation - * of Item and Map and their subclasses. The way to do - * type specific operations is to check the Value's type() and - * cast it to the appropriate subclass. This isn't super clean, - * but it is the simplest strategy. - */ +// A resource value. This is an all-encompassing representation +// of Item and Map and their subclasses. The way to do +// type specific operations is to check the Value's type() and +// cast it to the appropriate subclass. This isn't super clean, +// but it is the simplest strategy. struct Value { virtual ~Value() = default; - /** - * Whether this value is weak and can be overridden without - * warning or error. Default is false. - */ + // Whether this value is weak and can be overridden without warning or error. Default is false. bool IsWeak() const { return weak_; } void SetWeak(bool val) { weak_ = val; } - // Whether the value is marked as translateable. + // Whether the value is marked as translatable. // This does not persist when flattened. // It is only used during compilation phase. - void SetTranslateable(bool val) { translateable_ = val; } + void SetTranslatable(bool val) { translatable_ = val; } // Default true. - bool IsTranslateable() const { return translateable_; } + bool IsTranslatable() const { return translatable_; } - /** - * Returns the source where this value was defined. - */ + // Returns the source where this value was defined. const Source& GetSource() const { return source_; } void SetSource(const Source& source) { source_ = source; } void SetSource(Source&& source) { source_ = std::move(source); } - /** - * Returns the comment that was associated with this resource. - */ + // Returns the comment that was associated with this resource. const std::string& GetComment() const { return comment_; } void SetComment(const android::StringPiece& str) { comment_ = str.to_string(); } @@ -80,70 +71,48 @@ struct Value { virtual bool Equals(const Value* value) const = 0; - /** - * Calls the appropriate overload of ValueVisitor. - */ + // Calls the appropriate overload of ValueVisitor. virtual void Accept(RawValueVisitor* visitor) = 0; - /** - * Clone the value. new_pool is the new StringPool that - * any resources with strings should use when copying their string. - */ + // Clone the value. `new_pool` is the new StringPool that + // any resources with strings should use when copying their string. virtual Value* Clone(StringPool* new_pool) const = 0; - /** - * Human readable printout of this value. - */ + // Human readable printout of this value. virtual void Print(std::ostream* out) const = 0; protected: Source source_; std::string comment_; bool weak_ = false; - bool translateable_ = true; + bool translatable_ = true; }; -/** - * Inherit from this to get visitor accepting implementations for free. - */ +// Inherit from this to get visitor accepting implementations for free. template <typename Derived> struct BaseValue : public Value { void Accept(RawValueVisitor* visitor) override; }; -/** - * A resource item with a single value. This maps to android::ResTable_entry. - */ +// A resource item with a single value. This maps to android::ResTable_entry. struct Item : public Value { - /** - * Clone the Item. - */ + // Clone the Item. virtual Item* Clone(StringPool* new_pool) const override = 0; - /** - * Fills in an android::Res_value structure with this Item's binary - * representation. - * Returns false if an error occurred. - */ + // Fills in an android::Res_value structure with this Item's binary representation. + // Returns false if an error occurred. virtual bool Flatten(android::Res_value* out_value) const = 0; }; -/** - * Inherit from this to get visitor accepting implementations for free. - */ +// Inherit from this to get visitor accepting implementations for free. template <typename Derived> struct BaseItem : public Item { void Accept(RawValueVisitor* visitor) override; }; -/** - * A reference to another resource. This maps to - * android::Res_value::TYPE_REFERENCE. - * - * A reference can be symbolic (with the name set to a valid resource name) or - * be - * numeric (the id is set to a valid resource ID). - */ +// A reference to another resource. This maps to android::Res_value::TYPE_REFERENCE. +// A reference can be symbolic (with the name set to a valid resource name) or be +// numeric (the id is set to a valid resource ID). struct Reference : public BaseItem<Reference> { enum class Type { kResource, @@ -169,9 +138,7 @@ struct Reference : public BaseItem<Reference> { bool operator<(const Reference&, const Reference&); bool operator==(const Reference&, const Reference&); -/** - * An ID resource. Has no real value, just a place holder. - */ +// An ID resource. Has no real value, just a place holder. struct Id : public BaseItem<Id> { Id() { weak_ = true; } bool Equals(const Value* value) const override; @@ -180,11 +147,8 @@ struct Id : public BaseItem<Id> { void Print(std::ostream* out) const override; }; -/** - * A raw, unprocessed string. This may contain quotations, - * escape sequences, and whitespace. This shall *NOT* - * end up in the final resource table. - */ +// A raw, unprocessed string. This may contain quotations, escape sequences, and whitespace. +// This shall *NOT* end up in the final resource table. struct RawString : public BaseItem<RawString> { StringPool::Ref value; @@ -196,9 +160,32 @@ struct RawString : public BaseItem<RawString> { void Print(std::ostream* out) const override; }; +// Identifies a range of characters in a string that are untranslatable. +// These should not be pseudolocalized. The start and end indices are measured in bytes. +struct UntranslatableSection { + // Start offset inclusive. + size_t start; + + // End offset exclusive. + size_t end; +}; + +inline bool operator==(const UntranslatableSection& a, const UntranslatableSection& b) { + return a.start == b.start && a.end == b.end; +} + +inline bool operator!=(const UntranslatableSection& a, const UntranslatableSection& b) { + return a.start != b.start || a.end != b.end; +} + struct String : public BaseItem<String> { StringPool::Ref value; + // Sections of the string to NOT translate. Mainly used + // for pseudolocalization. This data is NOT persisted + // in any format. + std::vector<UntranslatableSection> untranslatable_sections; + explicit String(const StringPool::Ref& ref); bool Equals(const Value* value) const override; @@ -210,6 +197,11 @@ struct String : public BaseItem<String> { struct StyledString : public BaseItem<StyledString> { StringPool::StyleRef value; + // Sections of the string to NOT translate. Mainly used + // for pseudolocalization. This data is NOT persisted + // in any format. + std::vector<UntranslatableSection> untranslatable_sections; + explicit StyledString(const StringPool::StyleRef& ref); bool Equals(const Value* value) const override; @@ -221,9 +213,8 @@ struct StyledString : public BaseItem<StyledString> { struct FileReference : public BaseItem<FileReference> { StringPool::Ref path; - /** - * A handle to the file object from which this file can be read. - */ + // A handle to the file object from which this file can be read. + // This field is NOT persisted in any format. It is transient. io::IFile* file = nullptr; FileReference() = default; @@ -235,9 +226,7 @@ struct FileReference : public BaseItem<FileReference> { void Print(std::ostream* out) const override; }; -/** - * Represents any other android::Res_value. - */ +// Represents any other android::Res_value. struct BinaryPrimitive : public BaseItem<BinaryPrimitive> { android::Res_value value; @@ -279,10 +268,7 @@ struct Style : public BaseValue<Style> { Maybe<Reference> parent; - /** - * If set to true, the parent was auto inferred from the - * style's name. - */ + // If set to true, the parent was auto inferred from the style's name. bool parent_inferred = false; std::vector<Entry> entries; @@ -319,9 +305,7 @@ struct Styleable : public BaseValue<Styleable> { void MergeWith(Styleable* styleable); }; -/** - * Stream operator for printing Value objects. - */ +// Stream operator for printing Value objects. inline ::std::ostream& operator<<(::std::ostream& out, const Value& value) { value.Print(&out); return out; diff --git a/tools/aapt2/StringPool.cpp b/tools/aapt2/StringPool.cpp index d968d73c44ee..57da5f01dcd1 100644 --- a/tools/aapt2/StringPool.cpp +++ b/tools/aapt2/StringPool.cpp @@ -63,6 +63,14 @@ StringPool::Ref& StringPool::Ref::operator=(const StringPool::Ref& rhs) { return *this; } +bool StringPool::Ref::operator==(const Ref& rhs) const { + return entry_->value == rhs.entry_->value; +} + +bool StringPool::Ref::operator!=(const Ref& rhs) const { + return entry_->value != rhs.entry_->value; +} + const std::string* StringPool::Ref::operator->() const { return &entry_->value; } @@ -109,6 +117,28 @@ StringPool::StyleRef& StringPool::StyleRef::operator=( return *this; } +bool StringPool::StyleRef::operator==(const StyleRef& rhs) const { + if (entry_->str != rhs.entry_->str) { + return false; + } + + if (entry_->spans.size() != rhs.entry_->spans.size()) { + return false; + } + + auto rhs_iter = rhs.entry_->spans.begin(); + for (const Span& span : entry_->spans) { + const Span& rhs_span = *rhs_iter; + if (span.first_char != rhs_span.first_char || span.last_char != rhs_span.last_char || + span.name != rhs_span.name) { + return false; + } + } + return true; +} + +bool StringPool::StyleRef::operator!=(const StyleRef& rhs) const { return !operator==(rhs); } + const StringPool::StyleEntry* StringPool::StyleRef::operator->() const { return entry_; } diff --git a/tools/aapt2/StringPool.h b/tools/aapt2/StringPool.h index d0ce489dae26..a626d375b625 100644 --- a/tools/aapt2/StringPool.h +++ b/tools/aapt2/StringPool.h @@ -70,6 +70,8 @@ class StringPool { ~Ref(); Ref& operator=(const Ref& rhs); + bool operator==(const Ref& rhs) const; + bool operator!=(const Ref& rhs) const; const std::string* operator->() const; const std::string& operator*() const; @@ -93,6 +95,8 @@ class StringPool { ~StyleRef(); StyleRef& operator=(const StyleRef& rhs); + bool operator==(const StyleRef& rhs) const; + bool operator!=(const StyleRef& rhs) const; const StyleEntry* operator->() const; const StyleEntry& operator*() const; diff --git a/tools/aapt2/compile/PseudolocaleGenerator.cpp b/tools/aapt2/compile/PseudolocaleGenerator.cpp index 5035f816f0fa..fad9edd04e4c 100644 --- a/tools/aapt2/compile/PseudolocaleGenerator.cpp +++ b/tools/aapt2/compile/PseudolocaleGenerator.cpp @@ -43,16 +43,16 @@ std::unique_ptr<StyledString> PseudolocalizeStyledString( } // The ranges are all represented with a single value. This is the start of - // one range and - // end of another. + // one range and end of another. struct Range { size_t start; - // Once the new string is localized, these are the pointers to the spans to - // adjust. + // If set to true, toggles the state of translatability. + bool toggle_translatability; + + // Once the new string is localized, these are the pointers to the spans to adjust. // Since this struct represents the start of one range and end of another, - // we have - // the two pointers respectively. + // we have the two pointers respectively. uint32_t* update_start; uint32_t* update_end; }; @@ -63,12 +63,11 @@ std::unique_ptr<StyledString> PseudolocalizeStyledString( // Construct the ranges. The ranges are represented like so: [0, 2, 5, 7] // The ranges are the spaces in between. In this example, with a total string - // length of 9, - // the vector represents: (0,1], (2,4], (5,6], (7,9] + // length of 9, the vector represents: (0,1], (2,4], (5,6], (7,9] // std::vector<Range> ranges; - ranges.push_back(Range{0}); - ranges.push_back(Range{original_text.size() - 1}); + ranges.push_back(Range{0, false, nullptr, nullptr}); + ranges.push_back(Range{original_text.size() - 1, false, nullptr, nullptr}); for (size_t i = 0; i < string->value->spans.size(); i++) { const StringPool::Span& span = string->value->spans[i]; @@ -78,8 +77,7 @@ std::unique_ptr<StyledString> PseudolocalizeStyledString( if (iter != ranges.end() && iter->start == span.first_char) { iter->update_start = &localized.spans[i].first_char; } else { - ranges.insert(iter, Range{span.first_char, &localized.spans[i].first_char, - nullptr}); + ranges.insert(iter, Range{span.first_char, false, &localized.spans[i].first_char, nullptr}); } // Insert or update the Range marker for the end of this span. @@ -87,14 +85,45 @@ std::unique_ptr<StyledString> PseudolocalizeStyledString( if (iter != ranges.end() && iter->start == span.last_char) { iter->update_end = &localized.spans[i].last_char; } else { - ranges.insert( - iter, Range{span.last_char, nullptr, &localized.spans[i].last_char}); + ranges.insert(iter, Range{span.last_char, false, nullptr, &localized.spans[i].last_char}); + } + } + + // Parts of the string may be untranslatable. Merge those ranges + // in as well, so that we have continuous sections of text to + // feed into the pseudolocalizer. + // We do this by marking the beginning of a range as either toggling + // the translatability state or not. + for (const UntranslatableSection& section : string->untranslatable_sections) { + auto iter = std::lower_bound(ranges.begin(), ranges.end(), section.start, cmp); + if (iter != ranges.end() && iter->start == section.start) { + // An existing span starts (or ends) here. We just need to mark that + // the translatability should toggle here. If translatability was + // already being toggled, then that means we have two adjacent ranges of untranslatable + // text, so remove the toggle and only toggle at the end of this range, + // effectively merging these ranges. + iter->toggle_translatability = !iter->toggle_translatability; + } else { + // Insert a new range that specifies to toggle the translatability. + iter = ranges.insert(iter, Range{section.start, true, nullptr, nullptr}); + } + + // Update/create an end to the untranslatable section. + iter = std::lower_bound(iter, ranges.end(), section.end, cmp); + if (iter != ranges.end() && iter->start == section.end) { + iter->toggle_translatability = true; + } else { + iter = ranges.insert(iter, Range{section.end, true, nullptr, nullptr}); } } localized.str += localizer.Start(); // Iterate over the ranges and localize each section. + // The text starts as translatable, and each time a range has toggle_translatability + // set to true, we toggle whether to translate or not. + // This assumes no untranslatable ranges overlap. + bool translatable = true; for (size_t i = 0; i < ranges.size(); i++) { const size_t start = ranges[i].start; size_t len = original_text.size() - start; @@ -110,15 +139,20 @@ std::unique_ptr<StyledString> PseudolocalizeStyledString( *ranges[i].update_end = localized.str.size(); } - localized.str += localizer.Text(original_text.substr(start, len)); + if (ranges[i].toggle_translatability) { + translatable = !translatable; + } + + if (translatable) { + localized.str += localizer.Text(original_text.substr(start, len)); + } else { + localized.str += original_text.substr(start, len); + } } localized.str += localizer.End(); - std::unique_ptr<StyledString> localized_string = - util::make_unique<StyledString>(pool->MakeRef(localized)); - localized_string->SetSource(string->GetSource()); - return localized_string; + return util::make_unique<StyledString>(pool->MakeRef(localized)); } namespace { @@ -152,8 +186,30 @@ class Visitor : public RawValueVisitor { } void Visit(String* string) override { - std::string result = - localizer_.Start() + localizer_.Text(*string->value) + localizer_.End(); + const StringPiece original_string = *string->value; + std::string result = localizer_.Start(); + + // Pseudolocalize only the translatable sections. + size_t start = 0u; + for (const UntranslatableSection& section : string->untranslatable_sections) { + // Pseudolocalize the content before the untranslatable section. + const size_t len = section.start - start; + if (len > 0u) { + result += localizer_.Text(original_string.substr(start, len)); + } + + // Copy the untranslatable content. + result += original_string.substr(section.start, section.end - section.start); + start = section.end; + } + + // Pseudolocalize the content after the last untranslatable section. + if (start != original_string.size()) { + const size_t len = original_string.size() - start; + result += localizer_.Text(original_string.substr(start, len)); + } + result += localizer_.End(); + std::unique_ptr<String> localized = util::make_unique<String>(pool_->MakeRef(result)); localized->SetSource(string->GetSource()); @@ -163,6 +219,7 @@ class Visitor : public RawValueVisitor { void Visit(StyledString* string) override { item = PseudolocalizeStyledString(string, method_, pool_); + item->SetSource(string->GetSource()); item->SetWeak(true); } @@ -228,7 +285,7 @@ void PseudolocalizeIfNeeded(const Pseudolocalizer::Method method, /** * A value is pseudolocalizable if it does not define a locale (or is the * default locale) - * and is translateable. + * and is translatable. */ static bool IsPseudolocalizable(ResourceConfigValue* config_value) { const int diff = @@ -236,7 +293,7 @@ static bool IsPseudolocalizable(ResourceConfigValue* config_value) { if (diff & ConfigDescription::CONFIG_LOCALE) { return false; } - return config_value->value->IsTranslateable(); + return config_value->value->IsTranslatable(); } } // namespace diff --git a/tools/aapt2/compile/PseudolocaleGenerator_test.cpp b/tools/aapt2/compile/PseudolocaleGenerator_test.cpp index 5a9884d34dd1..4db37db55eb7 100644 --- a/tools/aapt2/compile/PseudolocaleGenerator_test.cpp +++ b/tools/aapt2/compile/PseudolocaleGenerator_test.cpp @@ -89,7 +89,7 @@ TEST(PseudolocaleGeneratorTest, PseudolocalizeOnlyDefaultConfigs) { String* val = test::GetValue<String>(table.get(), "android:string/four"); ASSERT_NE(nullptr, val); - val->SetTranslateable(false); + val->SetTranslatable(false); std::unique_ptr<IAaptContext> context = test::ContextBuilder().Build(); PseudolocaleGenerator generator; @@ -130,4 +130,47 @@ TEST(PseudolocaleGeneratorTest, PseudolocalizeOnlyDefaultConfigs) { test::ParseConfigOrDie("ar-rXB"))); } +TEST(PseudolocaleGeneratorTest, RespectUntranslateableSections) { + std::unique_ptr<IAaptContext> context = + test::ContextBuilder().SetCompilationPackage("android").Build(); + std::unique_ptr<ResourceTable> table = util::make_unique<ResourceTable>(); + + { + StyleString original_style; + original_style.str = "Hello world!"; + original_style.spans = {Span{"b", 2, 3}, Span{"b", 6, 7}, Span{"i", 1, 10}}; + + auto styled_string = + util::make_unique<StyledString>(table->string_pool.MakeRef(original_style)); + styled_string->untranslatable_sections.push_back(UntranslatableSection{6u, 8u}); + styled_string->untranslatable_sections.push_back(UntranslatableSection{8u, 11u}); + + auto string = util::make_unique<String>(table->string_pool.MakeRef(original_style.str)); + string->untranslatable_sections.push_back(UntranslatableSection{6u, 11u}); + + ASSERT_TRUE(table->AddResource(test::ParseNameOrDie("android:string/foo"), ConfigDescription{}, + {} /* product */, std::move(styled_string), + context->GetDiagnostics())); + ASSERT_TRUE(table->AddResource(test::ParseNameOrDie("android:string/bar"), ConfigDescription{}, + {} /* product */, std::move(string), context->GetDiagnostics())); + } + + PseudolocaleGenerator generator; + ASSERT_TRUE(generator.Consume(context.get(), table.get())); + + StyledString* new_styled_string = test::GetValueForConfig<StyledString>( + table.get(), "android:string/foo", test::ParseConfigOrDie("en-rXA")); + ASSERT_NE(nullptr, new_styled_string); + + // "world" should be untranslated. + EXPECT_NE(std::string::npos, new_styled_string->value->str->find("world")); + + String* new_string = test::GetValueForConfig<String>(table.get(), "android:string/bar", + test::ParseConfigOrDie("en-rXA")); + ASSERT_NE(nullptr, new_string); + + // "world" should be untranslated. + EXPECT_NE(std::string::npos, new_string->value->find("world")); +} + } // namespace aapt diff --git a/tools/aapt2/readme.md b/tools/aapt2/readme.md index 44d22c42468d..8bc4e8c65fac 100644 --- a/tools/aapt2/readme.md +++ b/tools/aapt2/readme.md @@ -1,5 +1,9 @@ # Android Asset Packaging Tool 2.0 (AAPT2) release notes +## Version 2.7 +### `aapt2 compile` +- Fixes bug where psuedolocalization auto-translated strings marked 'translateable="false"'. + ## Version 2.6 ### `aapt2` - Support legacy `configVarying` resource type. diff --git a/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/android/BridgeIInputMethodManager.java b/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/android/BridgeIInputMethodManager.java index ab73a8b820cd..468710bbb470 100644 --- a/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/android/BridgeIInputMethodManager.java +++ b/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/android/BridgeIInputMethodManager.java @@ -248,4 +248,9 @@ public class BridgeIInputMethodManager implements IInputMethodManager { // TODO Auto-generated method stub return null; } + + @Override + public void reportFullscreenMode(IBinder token, boolean fullscreen) { + // TODO Auto-generated method stub + } } |