Loading AconfigFlags.bp +7 −0 Original line number Diff line number Diff line Loading @@ -411,6 +411,13 @@ cc_aconfig_library { host_supported: true, } cc_aconfig_library { name: "android.companion.virtualdevice.flags-aconfig-cc-test", aconfig_declarations: "android.companion.virtualdevice.flags-aconfig", host_supported: true, mode: "test", } java_aconfig_library { name: "android.companion.virtualdevice.flags-aconfig-java", aconfig_declarations: "android.companion.virtualdevice.flags-aconfig", Loading core/java/android/companion/virtual/flags/flags.aconfig +7 −0 Original line number Diff line number Diff line Loading @@ -103,3 +103,10 @@ flag { description: "API for on-demand rotation of virtual displays" bug: "291748430" } flag { namespace: "virtual_devices" name: "high_resolution_scroll" description: "Enable high resolution scroll" bug: "335160780" } core/java/com/android/internal/os/BinderTransactionNameResolver.java +11 −1 Original line number Diff line number Diff line Loading @@ -17,6 +17,7 @@ package com.android.internal.os; import android.os.Binder; import android.text.TextUtils; import com.android.internal.annotations.VisibleForTesting; Loading @@ -37,6 +38,8 @@ import java.util.HashMap; @VisibleForTesting(visibility = VisibleForTesting.Visibility.PACKAGE) public class BinderTransactionNameResolver { private static final Method NO_GET_DEFAULT_TRANSACTION_NAME_METHOD; private static final boolean USE_TRANSACTION_CODES_FOR_UNKNOWN_METHODS = Flags.useTransactionCodesForUnknownMethods(); /** * Generates the default transaction method name, which is just the transaction code. Loading Loading @@ -81,7 +84,14 @@ public class BinderTransactionNameResolver { } try { return (String) method.invoke(null, transactionCode); String methodName = (String) method.invoke(null, transactionCode); if (USE_TRANSACTION_CODES_FOR_UNKNOWN_METHODS) { return TextUtils.isEmpty(methodName) ? String.valueOf(transactionCode) : methodName; } else { return methodName; } } catch (IllegalAccessException | InvocationTargetException e) { throw new RuntimeException(e); } Loading core/java/com/android/internal/os/flags.aconfig +11 −0 Original line number Diff line number Diff line Loading @@ -9,3 +9,14 @@ flag { is_fixed_read_only: true bug: "241474956" } flag { name: "use_transaction_codes_for_unknown_methods" namespace: "dropbox" description: "Use transaction codes when the method names is unknown" bug: "350041302" is_fixed_read_only: true metadata { purpose: PURPOSE_BUGFIX } } No newline at end of file core/java/com/android/internal/widget/NotificationRowIconView.java +8 −3 Original line number Diff line number Diff line Loading @@ -35,8 +35,10 @@ import android.util.AttributeSet; import android.view.RemotableViewMethod; import android.widget.RemoteViews; import com.android.internal.R; /** * An image view that holds the icon displayed on the left side of a notification row. * An image view that holds the icon displayed at the start of a notification row. */ @RemoteViews.RemoteView public class NotificationRowIconView extends CachingIconView { Loading Loading @@ -98,9 +100,12 @@ public class NotificationRowIconView extends CachingIconView { setPadding(0, 0, 0, 0); // Make the background white in case the icon itself doesn't have one. int white = Color.rgb(255, 255, 255); ColorFilter colorFilter = new PorterDuffColorFilter(white, ColorFilter colorFilter = new PorterDuffColorFilter(Color.WHITE, PorterDuff.Mode.SRC_ATOP); if (mOriginalBackground == null) { setBackground(getContext().getDrawable(R.drawable.notification_icon_circle)); } getBackground().mutate().setColorFilter(colorFilter); } else { // Restore original padding and background if needed Loading Loading
AconfigFlags.bp +7 −0 Original line number Diff line number Diff line Loading @@ -411,6 +411,13 @@ cc_aconfig_library { host_supported: true, } cc_aconfig_library { name: "android.companion.virtualdevice.flags-aconfig-cc-test", aconfig_declarations: "android.companion.virtualdevice.flags-aconfig", host_supported: true, mode: "test", } java_aconfig_library { name: "android.companion.virtualdevice.flags-aconfig-java", aconfig_declarations: "android.companion.virtualdevice.flags-aconfig", Loading
core/java/android/companion/virtual/flags/flags.aconfig +7 −0 Original line number Diff line number Diff line Loading @@ -103,3 +103,10 @@ flag { description: "API for on-demand rotation of virtual displays" bug: "291748430" } flag { namespace: "virtual_devices" name: "high_resolution_scroll" description: "Enable high resolution scroll" bug: "335160780" }
core/java/com/android/internal/os/BinderTransactionNameResolver.java +11 −1 Original line number Diff line number Diff line Loading @@ -17,6 +17,7 @@ package com.android.internal.os; import android.os.Binder; import android.text.TextUtils; import com.android.internal.annotations.VisibleForTesting; Loading @@ -37,6 +38,8 @@ import java.util.HashMap; @VisibleForTesting(visibility = VisibleForTesting.Visibility.PACKAGE) public class BinderTransactionNameResolver { private static final Method NO_GET_DEFAULT_TRANSACTION_NAME_METHOD; private static final boolean USE_TRANSACTION_CODES_FOR_UNKNOWN_METHODS = Flags.useTransactionCodesForUnknownMethods(); /** * Generates the default transaction method name, which is just the transaction code. Loading Loading @@ -81,7 +84,14 @@ public class BinderTransactionNameResolver { } try { return (String) method.invoke(null, transactionCode); String methodName = (String) method.invoke(null, transactionCode); if (USE_TRANSACTION_CODES_FOR_UNKNOWN_METHODS) { return TextUtils.isEmpty(methodName) ? String.valueOf(transactionCode) : methodName; } else { return methodName; } } catch (IllegalAccessException | InvocationTargetException e) { throw new RuntimeException(e); } Loading
core/java/com/android/internal/os/flags.aconfig +11 −0 Original line number Diff line number Diff line Loading @@ -9,3 +9,14 @@ flag { is_fixed_read_only: true bug: "241474956" } flag { name: "use_transaction_codes_for_unknown_methods" namespace: "dropbox" description: "Use transaction codes when the method names is unknown" bug: "350041302" is_fixed_read_only: true metadata { purpose: PURPOSE_BUGFIX } } No newline at end of file
core/java/com/android/internal/widget/NotificationRowIconView.java +8 −3 Original line number Diff line number Diff line Loading @@ -35,8 +35,10 @@ import android.util.AttributeSet; import android.view.RemotableViewMethod; import android.widget.RemoteViews; import com.android.internal.R; /** * An image view that holds the icon displayed on the left side of a notification row. * An image view that holds the icon displayed at the start of a notification row. */ @RemoteViews.RemoteView public class NotificationRowIconView extends CachingIconView { Loading Loading @@ -98,9 +100,12 @@ public class NotificationRowIconView extends CachingIconView { setPadding(0, 0, 0, 0); // Make the background white in case the icon itself doesn't have one. int white = Color.rgb(255, 255, 255); ColorFilter colorFilter = new PorterDuffColorFilter(white, ColorFilter colorFilter = new PorterDuffColorFilter(Color.WHITE, PorterDuff.Mode.SRC_ATOP); if (mOriginalBackground == null) { setBackground(getContext().getDrawable(R.drawable.notification_icon_circle)); } getBackground().mutate().setColorFilter(colorFilter); } else { // Restore original padding and background if needed Loading