/frameworks/opt/setupwizard/library/main/src/com/android/setupwizardlib/util/ |
D | WizardManagerHelper.java | 225 final String theme = intent.getStringExtra(EXTRA_THEME); in isLightTheme() local 226 return isLightTheme(theme, def); in isLightTheme() 237 public static boolean isLightTheme(String theme, boolean def) { in isLightTheme() argument 238 if (THEME_HOLO_LIGHT.equals(theme) || THEME_MATERIAL_LIGHT.equals(theme) in isLightTheme() 239 || THEME_GLIF_LIGHT.equals(theme) || THEME_GLIF_V2_LIGHT.equals(theme)) { in isLightTheme() 241 } else if (THEME_HOLO.equals(theme) || THEME_MATERIAL.equals(theme) in isLightTheme() 242 || THEME_GLIF.equals(theme) || THEME_GLIF_V2.equals(theme)) { in isLightTheme() 261 final String theme = intent.getStringExtra(EXTRA_THEME); in getThemeRes() local 262 return getThemeRes(theme, defaultTheme); in getThemeRes() 284 public static @StyleRes int getThemeRes(String theme, @StyleRes int defaultTheme) { in getThemeRes() argument [all …]
|
/frameworks/base/libs/androidfw/tests/ |
D | Theme_test.cpp | 60 std::unique_ptr<Theme> theme = assetmanager.NewTheme(); in TEST_F() local 61 EXPECT_EQ(0u, theme->GetChangingConfigurations()); in TEST_F() 62 EXPECT_EQ(&assetmanager, theme->GetAssetManager()); in TEST_F() 66 EXPECT_EQ(kInvalidCookie, theme->GetAttribute(app::R::attr::attr_one, &value, &flags)); in TEST_F() 73 std::unique_ptr<Theme> theme = assetmanager.NewTheme(); in TEST_F() local 74 ASSERT_TRUE(theme->ApplyStyle(app::R::style::StyleOne)); in TEST_F() 80 cookie = theme->GetAttribute(app::R::attr::attr_one, &value, &flags); in TEST_F() 86 cookie = theme->GetAttribute(app::R::attr::attr_two, &value, &flags); in TEST_F() 97 std::unique_ptr<Theme> theme = assetmanager.NewTheme(); in TEST_F() local 98 ASSERT_TRUE(theme->ApplyStyle(app::R::style::StyleTwo)); in TEST_F() [all …]
|
D | Theme_bench.cpp | 41 auto theme = assets.NewTheme(); in BM_ThemeApplyStyleFramework() local 42 theme->ApplyStyle(kStyleId, false /* force */); in BM_ThemeApplyStyleFramework() 58 std::unique_ptr<ResTable::Theme> theme{new ResTable::Theme(res_table)}; in BM_ThemeApplyStyleFrameworkOld() local 59 theme->applyStyle(kStyleId, false /* force */); in BM_ThemeApplyStyleFrameworkOld() 70 auto theme = assets.NewTheme(); in BM_ThemeGetAttribute() local 71 theme->ApplyStyle(kStyleId, false /* force */); in BM_ThemeGetAttribute() 77 theme->GetAttribute(kAttrId, &value, &flags); in BM_ThemeGetAttribute() 87 std::unique_ptr<ResTable::Theme> theme{new ResTable::Theme(res_table)}; in BM_ThemeGetAttributeOld() local 88 theme->applyStyle(kStyleId, false /* force */); in BM_ThemeGetAttributeOld() 94 theme->getAttribute(kAttrId, &value, &flags); in BM_ThemeGetAttributeOld()
|
/frameworks/base/core/java/android/animation/ |
D | AnimatorInflater.java | 104 public static Animator loadAnimator(Resources resources, Theme theme, int id) in loadAnimator() argument 106 return loadAnimator(resources, theme, id, 1); in loadAnimator() 110 public static Animator loadAnimator(Resources resources, Theme theme, int id, in loadAnimator() argument 114 Animator animator = animatorCache.getInstance(id, resources, theme); in loadAnimator() 126 animator = createAnimatorFromXml(resources, theme, parser, pathErrorScale); in loadAnimator() 134 animatorCache.put(id, theme, constantState); in loadAnimator() 136 animator = constantState.newInstance(resources, theme); in loadAnimator() 162 final Theme theme = context.getTheme(); in loadStateListAnimator() local 163 StateListAnimator animator = cache.getInstance(id, resources, theme); in loadStateListAnimator() 176 cache.put(id, theme, constantState); in loadStateListAnimator() [all …]
|
/frameworks/base/core/java/android/view/ |
D | ContextThemeWrapper.java | 73 public ContextThemeWrapper(Context base, Resources.Theme theme) { in ContextThemeWrapper() argument 75 mTheme = theme; in ContextThemeWrapper() 185 protected void onApplyThemeResource(Resources.Theme theme, int resId, boolean first) { in onApplyThemeResource() argument 186 theme.applyStyle(resId, true); in onApplyThemeResource() 193 final Resources.Theme theme = getBaseContext().getTheme(); in initializeTheme() local 194 if (theme != null) { in initializeTheme() 195 mTheme.setTo(theme); in initializeTheme()
|
/frameworks/support/v7/appcompat/ |
D | THEMES | 19 theme automatically. These should setup the framework theme ready so 20 that they are the theme is mostly the same on all platform versions. 31 to build up the theme across platforms. These themes do most of the work. 41 There are the themes which are pointers to the correct third level theme. 45 Because of this, every time there is a third level theme set, there should be a second level 46 theme pointing to it. This is so that devices do not use themes from newer and unavailable 59 the second level relevant second level theme below.
|
/frameworks/support/v7/appcompat/src/android/support/v7/content/res/ |
D | AppCompatColorStateListInflater.java | 54 @Nullable Resources.Theme theme) throws XmlPullParserException, IOException { in createFromXml() argument 67 return createFromXmlInner(r, parser, attrs, theme); in createFromXml() 80 @Nullable Resources.Theme theme) in createFromXmlInner() argument 88 return inflate(r, parser, attrs, theme); in createFromXmlInner() 95 @NonNull AttributeSet attrs, @Nullable Resources.Theme theme) in inflate() argument 113 final TypedArray a = obtainAttributes(r, theme, attrs, R.styleable.ColorStateListItem); in inflate() 162 private static TypedArray obtainAttributes(Resources res, Resources.Theme theme, in obtainAttributes() argument 164 return theme == null ? res.obtainAttributes(set, attrs) in obtainAttributes() 165 : theme.obtainStyledAttributes(set, attrs, 0, 0); in obtainAttributes()
|
/frameworks/support/v7/appcompat/src/android/support/v7/view/ |
D | ContextThemeWrapper.java | 82 public ContextThemeWrapper(Context base, Resources.Theme theme) { in ContextThemeWrapper() argument 84 mTheme = theme; in ContextThemeWrapper() 187 protected void onApplyThemeResource(Resources.Theme theme, int resid, boolean first) { in onApplyThemeResource() argument 188 theme.applyStyle(resid, true); in onApplyThemeResource() 195 Resources.Theme theme = getBaseContext().getTheme(); in initializeTheme() local 196 if (theme != null) { in initializeTheme() 197 mTheme.setTo(theme); in initializeTheme()
|
/frameworks/support/v7/appcompat/src/android/support/v7/widget/ |
D | ThemedSpinnerAdapter.java | 51 void setDropDownViewTheme(@Nullable Resources.Theme theme); in setDropDownViewTheme() argument 122 public void setDropDownViewTheme(@Nullable Resources.Theme theme) { in setDropDownViewTheme() argument 123 if (theme == null) { in setDropDownViewTheme() 125 } else if (theme == mContext.getTheme()) { in setDropDownViewTheme() 128 final Context context = new ContextThemeWrapper(mContext, theme); in setDropDownViewTheme()
|
/frameworks/support/samples/Support4Demos/src/com/example/android/supportv4/app/ |
D | FragmentDialogSupport.java | 128 int style = DialogFragment.STYLE_NORMAL, theme = 0; in onCreate() local 139 case 2: theme = android.R.style.Theme_Panel; break; in onCreate() 140 case 4: theme = android.R.style.Theme; break; in onCreate() 141 case 5: theme = android.R.style.Theme_Light; break; in onCreate() 142 case 6: theme = android.R.style.Theme_Light_Panel; break; in onCreate() 143 case 7: theme = android.R.style.Theme_Light; break; in onCreate() 145 setStyle(style, theme); in onCreate()
|
/frameworks/opt/setupwizard/library/main/src/com/android/setupwizardlib/template/ |
D | ButtonFooterMixin.java | 71 public Button addButton(CharSequence text, @StyleRes int theme) { in addButton() argument 72 Button button = createThemedButton(mContext, theme); in addButton() 88 public Button addButton(@StringRes int text, @StyleRes int theme) { in addButton() argument 89 Button button = createThemedButton(mContext, theme); in addButton() 167 private Button createThemedButton(Context context, @StyleRes int theme) { in createThemedButton() argument 170 LayoutInflater inflater = LayoutInflater.from(new ContextThemeWrapper(context, theme)); in createThemedButton()
|
/frameworks/opt/setupwizard/library/main/src/com/android/setupwizardlib/view/ |
D | NavigationBar.java | 62 int theme = attributes.getResourceId(suwNavBarTheme, 0); in getNavbarTheme() local 63 if (theme == 0) { in getNavbarTheme() 71 theme = isDarkBg ? R.style.SuwNavBarThemeDark : R.style.SuwNavBarThemeLight; in getNavbarTheme() 74 return theme; in getNavbarTheme() 78 final int theme = getNavbarTheme(context); in getThemedContext() local 79 return new ContextThemeWrapper(context, theme); in getThemedContext()
|
/frameworks/layoutlib/bridge/src/android/content/res/ |
D | ComplexColor_Accessor.java | 36 @NonNull XmlPullParser parser, @NonNull AttributeSet attrs, @Nullable Theme theme) in createGradientColorFromXmlInner() argument 38 return GradientColor.createFromXmlInner(r, parser, attrs, theme); in createGradientColorFromXmlInner() 42 @NonNull XmlPullParser parser, @NonNull AttributeSet attrs, @Nullable Theme theme) in createColorStateListFromXmlInner() argument 44 return ColorStateList.createFromXmlInner(r, parser, attrs, theme); in createColorStateListFromXmlInner()
|
/frameworks/support/compat/java/android/support/v4/content/res/ |
D | ResourcesCompat.java | 74 @Nullable Theme theme) throws NotFoundException { in getDrawable() argument 76 return res.getDrawable(id, theme); in getDrawable() 107 int density, @Nullable Theme theme) throws NotFoundException { in getDrawableForDensity() argument 109 return res.getDrawableForDensity(id, density, theme); in getDrawableForDensity() 136 public static int getColor(@NonNull Resources res, @ColorRes int id, @Nullable Theme theme) in getColor() argument 139 return res.getColor(id, theme); in getColor() 167 @Nullable Theme theme) throws NotFoundException { in getColorStateList() argument 169 return res.getColorStateList(id, theme); in getColorStateList()
|
/frameworks/base/core/java/com/android/internal/graphics/drawable/ |
D | AnimationScaleListDrawable.java | 78 @NonNull AttributeSet attrs, @Nullable Theme theme) in inflate() argument 80 final TypedArray a = obtainAttributes(r, theme, attrs, in inflate() 85 inflateChildElements(r, parser, attrs, theme); in inflate() 94 @NonNull AttributeSet attrs, @Nullable Theme theme) in inflateChildElements() argument 112 final TypedArray a = obtainAttributes(r, theme, attrs, in inflateChildElements() 127 dr = Drawable.createFromXmlInner(r, parser, attrs, theme); in inflateChildElements() 239 public void applyTheme(@NonNull Theme theme) { in applyTheme() argument 240 super.applyTheme(theme); in applyTheme()
|
/frameworks/base/core/java/android/app/ |
D | Presentation.java | 188 public Presentation(Context outerContext, Display display, int theme) { in Presentation() argument 189 super(createPresentationContext(outerContext, display, theme), theme, false); in Presentation() local 311 Context outerContext, Display display, int theme) { in createPresentationContext() argument 320 if (theme == 0) { in createPresentationContext() 324 theme = outValue.resourceId; in createPresentationContext() 335 return new ContextThemeWrapper(displayContext, theme) { in createPresentationContext()
|
/frameworks/base/core/java/android/widget/ |
D | ResourceCursorAdapter.java | 114 public void setDropDownViewTheme(Resources.Theme theme) { in setDropDownViewTheme() argument 115 super.setDropDownViewTheme(theme); in setDropDownViewTheme() 117 if (theme == null) { in setDropDownViewTheme() 119 } else if (theme == mInflater.getContext().getTheme()) { in setDropDownViewTheme() 122 final Context context = new ContextThemeWrapper(mContext, theme); in setDropDownViewTheme()
|
/frameworks/support/graphics/drawable/animated/src/android/support/graphics/drawable/ |
D | AnimatorInflaterCompat.java | 116 public static Animator loadAnimator(Context context, Resources resources, Theme theme, in loadAnimator() argument 118 return loadAnimator(context, resources, theme, id, 1); in loadAnimator() 124 public static Animator loadAnimator(Context context, Resources resources, Theme theme, in loadAnimator() argument 131 animator = createAnimatorFromXml(context, resources, theme, parser, pathErrorScale); in loadAnimator() 497 private static Animator createAnimatorFromXml(Context context, Resources res, Theme theme, in createAnimatorFromXml() argument 501 return createAnimatorFromXml(context, res, theme, parser, Xml.asAttributeSet(parser), null, in createAnimatorFromXml() 505 private static Animator createAnimatorFromXml(Context context, Resources res, Theme theme, in createAnimatorFromXml() argument 527 anim = loadObjectAnimator(context, res, theme, attrs, pixelSize, parser); in createAnimatorFromXml() 529 anim = loadAnimator(context, res, theme, attrs, null, pixelSize, parser); in createAnimatorFromXml() 532 TypedArray a = TypedArrayUtils.obtainAttributes(res, theme, attrs, in createAnimatorFromXml() [all …]
|
/frameworks/base/graphics/java/android/graphics/drawable/ |
D | DrawableInflater.java | 76 @NonNull Resources resources, @Nullable Theme theme, @DrawableRes int id) { in loadDrawable() argument 77 return resources.getDrawable(id, theme); in loadDrawable() 113 @NonNull AttributeSet attrs, @Nullable Theme theme) in inflateFromXml() argument 115 return inflateFromXmlForDensity(name, parser, attrs, 0, theme); in inflateFromXml() 124 @NonNull AttributeSet attrs, int density, @Nullable Theme theme) in inflateFromXmlForDensity() argument 142 drawable.inflate(mRes, parser, attrs, theme); in inflateFromXmlForDensity()
|
D | LevelListDrawable.java | 88 public void inflate(Resources r, XmlPullParser parser, AttributeSet attrs, Theme theme) in inflate() argument 90 super.inflate(r, parser, attrs, theme); in inflate() 93 inflateChildElements(r, parser, attrs, theme); in inflate() 97 Theme theme) throws XmlPullParserException, IOException { in inflateChildElements() argument 115 TypedArray a = obtainAttributes(r, theme, attrs, in inflateChildElements() 134 dr = r.getDrawable(drawableRes, theme); in inflateChildElements() 144 dr = Drawable.createFromXmlInner(r, parser, attrs, theme); in inflateChildElements()
|
D | AnimatedStateListDrawable.java | 376 @NonNull AttributeSet attrs, @Nullable Theme theme) in inflate() argument 379 r, theme, attrs, R.styleable.AnimatedStateListDrawable); in inflate() 385 inflateChildElements(r, parser, attrs, theme); in inflate() 391 public void applyTheme(@Nullable Theme theme) { in applyTheme() argument 392 super.applyTheme(theme); in applyTheme() 399 final TypedArray a = theme.resolveAttributes( in applyTheme() 436 Theme theme) throws XmlPullParserException, IOException { in inflateChildElements() argument 453 parseItem(r, parser, attrs, theme); in inflateChildElements() 455 parseTransition(r, parser, attrs, theme); in inflateChildElements() 461 @NonNull AttributeSet attrs, @Nullable Theme theme) in parseTransition() argument [all …]
|
/frameworks/base/core/java/android/content/res/ |
D | ThemedResourceCache.java | 47 public void put(long key, @Nullable Theme theme, @NonNull T entry) { in put() argument 48 put(key, theme, entry, true); in put() 61 public void put(long key, @Nullable Theme theme, @NonNull T entry, boolean usesTheme) { in put() argument 71 entries = getThemedLocked(theme, true); in put() 87 public T get(long key, @Nullable Theme theme) { in get() argument 93 final LongSparseArray<WeakReference<T>> themedEntries = getThemedLocked(theme, false); in get()
|
D | DrawableCache.java | 34 public Drawable getInstance(long key, Resources resources, Resources.Theme theme) { in getInstance() argument 35 final Drawable.ConstantState entry = get(key, theme); in getInstance() 37 return entry.newDrawable(resources, theme); in getInstance()
|
D | ConfigurationBoundResourceCache.java | 37 public T getInstance(long key, Resources resources, Resources.Theme theme) { in getInstance() argument 38 final ConstantState<T> entry = get(key, theme); in getInstance() 40 return entry.newInstance(resources, theme); in getInstance()
|
/frameworks/base/core/java/android/view/animation/ |
D | AnimationUtils.java | 334 …public static Interpolator loadInterpolator(Resources res, Theme theme, int id) throws NotFoundExc… in loadInterpolator() argument 338 return createInterpolatorFromXml(res, theme, parser); in loadInterpolator() 356 …private static Interpolator createInterpolatorFromXml(Resources res, Theme theme, XmlPullParser pa… in createInterpolatorFromXml() argument 379 interpolator = new AccelerateInterpolator(res, theme, attrs); in createInterpolatorFromXml() 381 interpolator = new DecelerateInterpolator(res, theme, attrs); in createInterpolatorFromXml() 385 interpolator = new CycleInterpolator(res, theme, attrs); in createInterpolatorFromXml() 387 interpolator = new AnticipateInterpolator(res, theme, attrs); in createInterpolatorFromXml() 389 interpolator = new OvershootInterpolator(res, theme, attrs); in createInterpolatorFromXml() 391 interpolator = new AnticipateOvershootInterpolator(res, theme, attrs); in createInterpolatorFromXml() 395 interpolator = new PathInterpolator(res, theme, attrs); in createInterpolatorFromXml()
|