/frameworks/support/v7/appcompat/src/android/support/v7/content/res/ |
H A D | AppCompatColorStateListInflater.java | 48 * @param theme Optional theme to apply to the color state list, may be 50 * @return A new color state list. 75 * @return A new color state list for the current tag. 85 parser.getPositionDescription() + ": invalid color state list tag " + name); 132 if (stateResId != android.R.attr.color && stateResId != android.R.attr.alpha 141 // Apply alpha modulation. If we couldn't resolve the color or 144 final int color = modulateColorAlpha(baseColor, alphaMod); 146 defaultColor = color; 149 colorList = GrowingArrayUtils.append(colorList, listSize, color); 168 private static int modulateColorAlpha(int color, floa argument [all...] |
/frameworks/support/v7/appcompat/tests/src/android/support/v7/testutils/ |
H A D | TestUtilsMatchers.java | 41 * with the specific color. 43 public static Matcher drawable(@ColorInt final int color) { argument 49 description.appendText("with drawable of color: "); 63 // all pixels in a Drawable are of the same specified color. 66 view.getHeight(), true, color, 0, true); 67 // If we are here, the color comparison has passed. 71 // If we are here, the color comparison has failed. 81 * with the specific color. 83 public static Matcher isBackground(@ColorInt final int color) { argument 89 description.appendText("with background of color 120 isCombinedBackground(@olorInt final int color, final boolean onlyTestCenterPixel) argument [all...] |
/frameworks/support/v7/cardview/api21/android/support/v7/widget/ |
H A D | RoundRectDrawable.java | 64 private void setBackground(ColorStateList color) { argument 65 mBackground = (color == null) ? ColorStateList.valueOf(Color.TRANSPARENT) : color; 158 public void setColor(@Nullable ColorStateList color) { argument 159 setBackground(color); 202 * Ensures the tint filter is consistent with the current tint color and 209 final int color = tint.getColorForState(getState(), Color.TRANSPARENT); 210 return new PorterDuffColorFilter(color, tintMode);
|
/frameworks/base/packages/SystemUI/src/com/android/systemui/qs/ |
H A D | DataUsageGraph.java | 48 mTrackColor = context.getColor(R.color.data_usage_graph_track); 50 mOverlimitColor = context.getColor(R.color.system_warning_color); 51 mWarningColor = context.getColor(R.color.data_usage_graph_warning);
|
/frameworks/base/tests/HwAccelerationTest/src/com/android/test/hwui/ |
H A D | BitmapMutateActivity.java | 93 int color = 0xff000000; 95 color |= (int) ((0xff * ((i + mOffset) % mSlice) / (float) mSlice)) << 98 mPixels[y * width + x] = color;
|
H A D | MultiLayersActivity.java | 62 public LayerView(Context context, int color) { argument 65 mPaint.setColor(color);
|
/frameworks/base/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/bars/ |
H A D | NavigationBar.java | 29 /** Navigation bar background color attribute name. */ 54 int color = getBarColor(ATTR_COLOR, ATTR_TRANSLUCENT); 55 setBackgroundColor(color == 0 ? 0xFF000000 : color);
|
/frameworks/support/v17/leanback/src/android/support/v17/leanback/widget/ |
H A D | RowContainerView.java | 81 public void setForegroundColor(@ColorInt int color) { argument 83 ((ColorDrawable) mForeground.mutate()).setColor(color); 86 setForeground(new ColorDrawable(color));
|
H A D | AbstractMediaListHeaderPresenter.java | 113 * Sets the background color for the row views within the playlist. 114 * If this is not set, a default color, defaultBrandColor, from theme is used. 116 * @param color The ARGB color used to set as the header text background color. 118 public void setBackgroundColor(int color) { argument 120 mBackgroundColor = color;
|
/frameworks/support/v7/appcompat/src/android/support/v7/widget/ |
H A D | ThemeUtils.java | 42 // Now create a new ColorStateList with the default color, and the new disabled 43 // color 87 // Else, we'll generate the color using disabledAlpha from the theme 108 final int color = getThemeAttrColor(context, attr); 109 final int originalAlpha = Color.alpha(color); 110 return ColorUtils.setAlphaComponent(color, Math.round(originalAlpha * alpha));
|
/frameworks/rs/java/tests/VrDemo/src/com/example/android/rs/vr/engine/ |
H A D | Volume.java | 58 public void addLook(String name, int[][] color, int[][] opacity) {
argument 59 mLooks.put(name, new Look(name, color, opacity));
91 public Look(String name, int[][] color, int[][] opacity) {
argument 92 mColor = color;
|
/frameworks/support/core-ui/java/android/support/v4/widget/ |
H A D | CircleImageView.java | 50 CircleImageView(Context context, int color) { argument 72 circle.getPaint().setColor(color); 110 * Update the background color of the circle image view. 112 * @param colorRes Id of a color resource. 119 public void setBackgroundColor(int color) { argument 121 ((ShapeDrawable) getBackground()).getPaint().setColor(color);
|
/frameworks/support/core-utils/java/android/support/v4/graphics/ |
H A D | ColorUtils.java | 27 * A set of color-related utility methods, building upon those available in {@code Color}. 72 * Returns the luminance of a color as a float between {@code 0.0} and {@code 1.0}. 73 * <p>Defined as the Y component in the XYZ representation of {@code color}.</p> 76 public static double calculateLuminance(@ColorInt int color) { argument 78 colorToXYZ(color, result); 112 * @param foreground the foreground color 113 * @param background the opaque background color 210 * Convert the ARGB color to its HSL (hue-saturation-lightness) components. 217 * @param color the ARGB color t 220 colorToHSL(@olorInt int color, @NonNull float[] outHsl) argument 295 setAlphaComponent(@olorInt int color, @IntRange(from = 0x0, to = 0xFF) int alpha) argument 309 colorToLAB(@olorInt int color, @NonNull double[] outLab) argument 352 colorToXYZ(@olorInt int color, @NonNull double[] outXyz) argument [all...] |
/frameworks/support/design/base/android/support/design/widget/ |
H A D | FloatingActionButtonImpl.java | 156 ContextCompat.getColor(context, R.color.design_fab_stroke_top_outer_color), 157 ContextCompat.getColor(context, R.color.design_fab_stroke_top_inner_color), 158 ContextCompat.getColor(context, R.color.design_fab_stroke_end_inner_color), 159 ContextCompat.getColor(context, R.color.design_fab_stroke_end_outer_color));
|
/frameworks/support/v7/appcompat/tests/src/android/support/v7/widget/ |
H A D | AppCompatTextViewTest.java | 97 assertEquals(ContextCompat.getColor(textView.getContext(), R.color.ocean_default), 101 assertEquals(ContextCompat.getColor(textView.getContext(), R.color.ocean_disabled), 117 assertEquals(ContextCompat.getColor(textView.getContext(), R.color.sand_default), 121 assertEquals(ContextCompat.getColor(textView.getContext(), R.color.sand_disabled),
|
/frameworks/support/v7/cardview/base/android/support/v7/widget/ |
H A D | CardViewImpl.java | 53 void setBackgroundColor(CardViewDelegate cardView, @Nullable ColorStateList color); argument
|
/frameworks/base/core/tests/coretests/src/android/hardware/display/ |
H A D | VirtualDisplayTest.java | 63 // values for each color channel so as to detect possible RGBA vs. BGRA buffer format issues. 283 final int color, final int windowType, final int windowFlags) { 286 mImageListener.getColor() != color); 295 color, windowType, windowFlags); 302 mImageListener.waitForColor(color, TIMEOUT)); 349 int color, int windowType, int windowFlags) { 351 mColor = color; 364 // Create a solid color image to use as the content of the presentation. 374 * Watches for an image with a large amount of some particular solid color to be shown. 386 public boolean waitForColor(int color, lon argument 282 assertDisplayCanShowPresentation(String message, final Display display, final int color, final int windowType, final int windowFlags) argument 348 TestPresentation(Context context, Display display, int color, int windowType, int windowFlags) argument [all...] |
/frameworks/base/core/tests/coretests/src/android/widget/ |
H A D | LabelView.java | 107 * Sets the text color for this label 108 * @param color ARGB value for the text 110 public void setTextColor(int color) { argument 111 mTextPaint.setColor(color);
|
/frameworks/base/graphics/java/android/graphics/drawable/ |
H A D | PaintDrawable.java | 35 public PaintDrawable(int color) { argument 36 getPaint().setColor(color);
|
H A D | ColorDrawable.java | 39 * A specialized Drawable that fills the Canvas with a specified color. 42 * <p>It can be defined in an XML file with the <code><color></code> element.</p> 63 * Creates a new ColorDrawable with the specified color. 65 * @param color The color to draw. 67 public ColorDrawable(@ColorInt int color) { argument 70 setColor(color); 112 // Restore original color filter. 118 * Gets the drawable's color value. 120 * @return int The color t 134 setColor(@olorInt int color) argument [all...] |
/frameworks/base/libs/hwui/renderstate/ |
H A D | RenderState.cpp | 252 fill.program->setColor(fill.color); 262 const FloatColor& color = fill.filter.color; local 264 color.r, color.g, color.b, color.a); 321 // vertex attributes (tex coord, color, alpha) 332 glVertexAttribPointer(colorLocation, 4, GL_FLOAT, GL_FALSE, vertices.stride, vertices.color);
|
/frameworks/base/tests/LockTaskTests/src/com/google/android/example/locktasktests/ |
H A D | MainActivity.java | 33 final int color = activityManager.getLockTaskModeState() != 35 findViewById(R.id.root_launch).setBackgroundColor(color);
|
/frameworks/base/tests/UiBench/src/com/android/test/uibench/ |
H A D | InvalidateActivity.java | 42 public void setColor(@ColorInt int color) { argument 43 mColor = color;
|
/frameworks/support/core-utils/tests/java/android/support/v4/graphics/ |
H A D | ColorUtilsTest.java | 182 private static void verifyMinAlpha(String title, int color, float expected, int actual) { argument 183 final String message = title + " text within error for #" + Integer.toHexString(color); 191 private static void verifyColorToHSL(int color, float[] expected) { argument 193 ColorUtils.colorToHSL(color, actualHSL); 214 private static void verifyColorToLAB(int color, double[] expected) { argument 216 ColorUtils.colorToLAB(color, result); 223 private static void verifyColorToXYZ(int color, double[] expected) { argument 225 ColorUtils.colorToXYZ(color, result);
|
/frameworks/av/cmds/stagefright/ |
H A D | recordvideo.cpp | 45 fprintf(stderr, " -c YUV420 color format: [0] semi planar or [1] planar or other omx YUV420 color format (default: 1)\n"); 111 // iterate through solid planes of color. 146 // returns -1 if mapping of the given color is unsuccessful 147 // returns an omx color enum value otherwise 148 static int translateColorToOmxEnumValue(int color) { argument 149 switch (color) { 155 fprintf(stderr, "Custom OMX color format: %d\n", color); 156 if (color [all...] |