/frameworks/base/core/tests/coretests/src/com/android/internal/util/ |
D | ContrastColorUtilTest.java | 56 int blueContrastColor = ContrastColorUtil.ensureTextContrast(Color.BLUE, darkBg, true); in testEnsureTextContrastAgainstDark() 59 int redContrastColor = ContrastColorUtil.ensureTextContrast(Color.RED, darkBg, true); in testEnsureTextContrastAgainstDark() 63 int greenContrastColor = ContrastColorUtil.ensureTextContrast(darkGreen, darkBg, true); in testEnsureTextContrastAgainstDark() 66 int grayContrastColor = ContrastColorUtil.ensureTextContrast(Color.DKGRAY, darkBg, true); in testEnsureTextContrastAgainstDark() 69 int selfContrastColor = ContrastColorUtil.ensureTextContrast(darkBg, darkBg, true); in testEnsureTextContrastAgainstDark() 79 int blueContrastColor = ContrastColorUtil.ensureTextContrast(lightBlue, lightBg, false); in testEnsureTextContrastAgainstLight() 82 int redContrastColor = ContrastColorUtil.ensureTextContrast(Color.RED, lightBg, false); in testEnsureTextContrastAgainstLight() 85 int greenContrastColor = ContrastColorUtil.ensureTextContrast(Color.GREEN, lightBg, false); in testEnsureTextContrastAgainstLight() 88 int grayContrastColor = ContrastColorUtil.ensureTextContrast(Color.LTGRAY, lightBg, false); in testEnsureTextContrastAgainstLight() 91 int selfContrastColor = ContrastColorUtil.ensureTextContrast(lightBg, lightBg, false); in testEnsureTextContrastAgainstLight() [all …]
|
/frameworks/base/core/java/com/android/internal/widget/ |
D | ColoredIconHelper.java | 26 import com.android.internal.util.ContrastColorUtil; 50 int grey = ContrastColorUtil.resolveColor(ctx, Notification.COLOR_DEFAULT, inNightMode); in applyGrayTint()
|
D | PeopleHelper.java | 39 import com.android.internal.util.ContrastColorUtil; 135 double luminance = ContrastColorUtil.calculateLuminance(layoutColor); in findColor() 141 return ContrastColorUtil.getShiftedColor(layoutColor, in findColor()
|
D | MessagingLayout.java | 49 import com.android.internal.util.ContrastColorUtil; 402 double luminance = ContrastColorUtil.calculateLuminance(layoutColor); in findColor() 408 return ContrastColorUtil.getShiftedColor(layoutColor, in findColor()
|
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/notification/icon/ui/viewbinder/ |
D | StatusBarIconViewBinder.kt | 22 import com.android.internal.util.ContrastColorUtil in <lambda>() 59 contrastColorUtil: ContrastColorUtil, in <lambda>()
|
D | NotificationIconContainerViewBinder.kt | 30 import com.android.internal.util.ContrastColorUtil in <lambda>() 71 val contrastColorUtil = ContrastColorUtil.getInstance(view.context) in <lambda>()
|
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/phone/ |
D | LetterboxAppearanceCalculator.kt | 28 import com.android.internal.util.ContrastColorUtil in <lambda>() 185 ContrastColorUtil.calculateContrast(darkAppearanceIconColor, backgroundColor) in getOuterAppearance() 187 ContrastColorUtil.calculateContrast(lightAppearanceIconColor, backgroundColor) in getOuterAppearance()
|
D | LegacyNotificationIconAreaControllerImpl.java | 37 import com.android.internal.util.ContrastColorUtil; 86 private final ContrastColorUtil mContrastColorUtil; 142 mContrastColorUtil = ContrastColorUtil.getInstance(context); in LegacyNotificationIconAreaControllerImpl()
|
/frameworks/base/core/java/com/android/internal/util/ |
D | ContrastColorUtil.java | 53 public class ContrastColorUtil { class 59 private static ContrastColorUtil sInstance; 67 public static ContrastColorUtil getInstance(Context context) { in getInstance() 70 sInstance = new ContrastColorUtil(context); in getInstance() 76 private ContrastColorUtil(Context context) { in ContrastColorUtil() method in ContrastColorUtil 322 newColors[i] = ContrastColorUtil.ensureLargeTextContrast( in ensureColorSpanContrast() 342 foregroundColor = ContrastColorUtil.ensureLargeTextContrast( in ensureColorSpanContrast() 565 return ContrastColorUtil.resolveContrastColor(context, notificationColor, in resolveContrastColor() 584 color = ContrastColorUtil.ensureTextContrast(color, backgroundColor, isDark); in resolveContrastColor() 592 ContrastColorUtil.contrastChange(resolvedColor, color, backgroundColor), in resolveContrastColor() [all …]
|
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/notification/ |
D | NotificationUtils.java | 25 import com.android.internal.util.ContrastColorUtil; 40 public static boolean isGrayscale(ImageView v, ContrastColorUtil colorUtil) { in isGrayscale()
|
/frameworks/base/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/ |
D | StackEducationView.kt | 27 import com.android.internal.util.ContrastColorUtil 111 textColor = ContrastColorUtil.ensureTextContrast(textColor, bgColor, true) in setTextColor()
|
D | BubbleOverflowContainerView.java | 46 import com.android.internal.util.ContrastColorUtil; 234 textColor = ContrastColorUtil.ensureTextContrast(textColor, bgColor, isNightMode); in updateTheme() 322 textColor = ContrastColorUtil.ensureTextContrast(textColor, bgColor, true); in onCreateViewHolder()
|
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/policy/ |
D | SmartReplyView.java | 34 import com.android.internal.util.ContrastColorUtil; 117 mMinStrokeContrast = ContrastColorUtil.calculateContrast(mDefaultStrokeColor, in SmartReplyView() 729 final boolean dark = ContrastColorUtil.isColorDark(backgroundColor); in setBackgroundTintColor() 731 mCurrentTextColor = ContrastColorUtil.ensureTextContrast( in setBackgroundTintColor() 734 mCurrentStrokeColor = colorized ? mCurrentTextColor : ContrastColorUtil.ensureContrast( in setBackgroundTintColor()
|
D | RemoteInputView.java | 81 import com.android.internal.util.ContrastColorUtil; 218 final boolean dark = ContrastColorUtil.isColorDark(backgroundColor); in setBackgroundTintColor()
|
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/notification/row/wrapper/ |
D | NotificationViewWrapper.java | 39 import com.android.internal.util.ContrastColorUtil; 179 backgroundColor = ContrastColorUtil.compositeColors(backgroundColor, parentBackground); in childrenNeedInversion()
|
D | NotificationTemplateViewWrapper.java | 41 import com.android.internal.util.ContrastColorUtil; 262 return ContrastColorUtil.compositeColors(Color.argb((int) (alpha * 255), in blendColorWithBackground()
|
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/notification/row/ |
D | NotificationBackgroundView.java | 35 import com.android.internal.util.ContrastColorUtil; 144 ColorStateList newColor = ContrastColorUtil.isColorDark(mTintColor) in setStatefulColors()
|
/frameworks/base/libs/WindowManager/Shell/src/com/android/wm/shell/startingsurface/ |
D | SplashscreenWindowCreator.java | 57 import com.android.internal.util.ContrastColorUtil; 215 ContrastColorUtil.isColorLight( in addSplashScreenStartingWindow()
|
/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/statusbar/ |
D | StatusBarIconViewTest.java | 54 import com.android.internal.util.ContrastColorUtil; 129 ContrastColorUtil.satisfiesTextContrast(Color.WHITE, color)); in testGetContrastedStaticDrawableColor()
|
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/ |
D | StatusBarIconView.java | 61 import com.android.internal.util.ContrastColorUtil; 830 if (!ContrastColorUtil.satisfiesTextContrast(mCachedContrastBackgroundColor, in updateContrastedStaticColor() 839 boolean isDark = !ContrastColorUtil.isColorLight(mCachedContrastBackgroundColor); in updateContrastedStaticColor() 840 contrastedColor = ContrastColorUtil.resolveContrastColor(mContext, in updateContrastedStaticColor()
|
/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/statusbar/phone/ |
D | LightBarControllerTest.java | 45 import com.android.internal.util.ContrastColorUtil; 111 colors.setSupportsDarkText(!ContrastColorUtil.isColorDark(bgColor)); in makeColors()
|
/frameworks/base/core/java/android/app/ |
D | Notification.java | 116 import com.android.internal.util.ContrastColorUtil; 4372 private ContrastColorUtil mColorUtil; 4480 private ContrastColorUtil getColorUtil() { in getColorUtil() 4482 mColorUtil = ContrastColorUtil.getInstance(mContext); in getColorUtil() 6874 ContrastColorUtil.resolveSecondaryColor( in generateActionButton() 6891 title = ContrastColorUtil.clearColorSpans(title); in generateActionButton() 6903 title = ContrastColorUtil.ensureColorSpanContrast(title, buttonFillColor); in generateActionButton() 6917 int textColor = ContrastColorUtil.resolvePrimaryColor(mContext, in generateActionButton() 6921 ContrastColorUtil.resolveSecondaryColor( in generateActionButton() 7039 return ContrastColorUtil.ensureColorSpanContrast(cs, buttonFillColor); in ensureColorSpanContrastOrStripStyling() [all …]
|
D | WallpaperColors.java | 41 import com.android.internal.util.ContrastColorUtil; 583 final boolean satisfiesTextContrast = ContrastColorUtil in calculateDarkHints()
|
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/notification/collection/ |
D | NotificationEntry.java | 59 import com.android.internal.util.ContrastColorUtil; 540 final int contrasted = ContrastColorUtil.resolveContrastColor(context, rawColor, in getContrastedColor()
|
/frameworks/base/core/tests/coretests/src/android/app/ |
D | NotificationTest.java | 104 import com.android.internal.util.ContrastColorUtil; 513 assertThat(ContrastColorUtil.calculateLuminance(result)) in testBuilder_ensureButtonFillContrast_adjustsDarker() 514 .isLessThan(ContrastColorUtil.calculateLuminance(background)); in testBuilder_ensureButtonFillContrast_adjustsDarker() 523 assertThat(ContrastColorUtil.calculateLuminance(result)) in testBuilder_ensureButtonFillContrast_adjustsLighter() 524 .isGreaterThan(ContrastColorUtil.calculateLuminance(background)); in testBuilder_ensureButtonFillContrast_adjustsLighter()
|