/frameworks/support/v7/appcompat/src/android/support/v7/widget/ |
D | ResourcesWrapper.java | 43 private final Resources mResources; field in ResourcesWrapper 47 mResources = resources; in ResourcesWrapper() 52 return mResources.getText(id); in getText() 57 return mResources.getQuantityText(id, quantity); in getQuantityText() 62 return mResources.getString(id); in getString() 67 return mResources.getString(id, formatArgs); in getString() 73 return mResources.getQuantityString(id, quantity, formatArgs); in getQuantityString() 78 return mResources.getQuantityString(id, quantity); in getQuantityString() 83 return mResources.getText(id, def); in getText() 88 return mResources.getTextArray(id); in getTextArray() [all …]
|
D | TintContextWrapper.java | 78 private final Resources mResources; field in TintContextWrapper 87 mResources = new VectorEnabledTintResources(this, base.getResources()); in TintContextWrapper() 88 mTheme = mResources.newTheme(); in TintContextWrapper() 91 mResources = new TintResources(this, base.getResources()); in TintContextWrapper() 112 return mResources; in getResources()
|
/frameworks/support/compat/tests/java/android/support/v4/content/res/ |
D | ResourcesCompatTest.java | 34 private Resources mResources; field in ResourcesCompatTest 38 mResources = InstrumentationRegistry.getContext().getResources(); in setup() 44 ResourcesCompat.getColor(mResources, R.color.text_color, null), in testGetColor() 50 final Resources.Theme yellowTheme = mResources.newTheme(); in testGetColor() 53 ResourcesCompat.getColor(mResources, R.color.simple_themed_selector, in testGetColor() 56 final Resources.Theme lilacTheme = mResources.newTheme(); in testGetColor() 59 ResourcesCompat.getColor(mResources, R.color.simple_themed_selector, in testGetColor() 67 ResourcesCompat.getColorStateList(mResources, R.color.complex_unthemed_selector, in testGetColorStateList() 81 final Resources.Theme yellowTheme = mResources.newTheme(); in testGetColorStateList() 84 ResourcesCompat.getColorStateList(mResources, R.color.complex_themed_selector, in testGetColorStateList() [all …]
|
/frameworks/base/graphics/tests/graphicstests/src/android/graphics/ |
D | ColorStateListTest.java | 32 private Resources mResources; field in ColorStateListTest 38 mResources = mContext.getResources(); in setUp() 39 mFailureColor = mResources.getColor(R.color.failColor); in setUp() 44 ColorStateList colorStateList = mResources.getColorStateList(R.color.color1); in testStateIsInList() 47 assertEquals(mResources.getColor(R.color.testcolor1), focusColor); in testStateIsInList() 52 ColorStateList colorStateList = mResources.getColorStateList(R.color.color1); in testEmptyState() 55 assertEquals(mResources.getColor(R.color.testcolor2), defaultColor); in testEmptyState() 60 int defaultColor = mResources.getColor(R.color.color1); in testGetColor() 61 assertEquals(mResources.getColor(R.color.testcolor2), defaultColor); in testGetColor() 66 int defaultColor = mResources.getColor(R.color.color_no_default); in testGetColorWhenListHasNoDefault() [all …]
|
D | GraphicsPerformanceTests.java | 125 private Resources mResources; field in GraphicsPerformanceTests.DecodeBitmapTest 134 mResources = context.getResources(); in setUp() 135 Assert.assertNotNull(mResources); in setUp() 145 BitmapFactory.decodeResource(mResources, R.drawable.test16x12); in testDecodeBitmap() 146 BitmapFactory.decodeResource(mResources, R.drawable.test32x24); in testDecodeBitmap() 147 BitmapFactory.decodeResource(mResources, R.drawable.test64x48); in testDecodeBitmap() 148 BitmapFactory.decodeResource(mResources, R.drawable.test128x96); in testDecodeBitmap() 149 BitmapFactory.decodeResource(mResources, R.drawable.test256x192); in testDecodeBitmap() 150 BitmapFactory.decodeResource(mResources, R.drawable.test320x240); in testDecodeBitmap()
|
/frameworks/support/v7/appcompat/tests/src/android/support/v7/widget/ |
D | AppCompatBaseViewTest.java | 53 protected Resources mResources; field in AppCompatBaseViewTest 63 mResources = activity.getResources(); in setUp() 113 mResources, R.color.color_state_list_sand, null); in testBackgroundTintingWithNoBackground() 157 mResources, R.color.color_state_list_lilac, null); in testBackgroundTintingViewCompatWithNoBackground() 182 mResources, R.color.lilac_default, null); in testBackgroundTintingAcrossStateChange() 184 mResources, R.color.lilac_disabled, null); in testBackgroundTintingAcrossStateChange() 186 mResources, R.color.sand_default, null); in testBackgroundTintingAcrossStateChange() 188 mResources, R.color.sand_disabled, null); in testBackgroundTintingAcrossStateChange() 190 mResources, R.color.ocean_default, null); in testBackgroundTintingAcrossStateChange() 192 mResources, R.color.ocean_disabled, null); in testBackgroundTintingAcrossStateChange() [all …]
|
D | PopupMenuTest.java | 83 private Resources mResources; field in PopupMenuTest 96 mResources = mActivityTestRule.getActivity().getResources(); in setUp() 119 onView(withText(mResources.getString(R.string.popup_menu_highlight))) in testBasicContent() 123 onView(withText(mResources.getString(R.string.popup_menu_edit))) in testBasicContent() 127 onView(withText(mResources.getString(R.string.popup_menu_delete))) in testBasicContent() 131 onView(withText(mResources.getString(R.string.popup_menu_ignore))) in testBasicContent() 135 onView(withText(mResources.getString(R.string.popup_menu_share))) in testBasicContent() 139 onView(withText(mResources.getString(R.string.popup_menu_print))) in testBasicContent() 144 onView(withText(mResources.getString(R.string.popup_menu_share_email))) in testBasicContent() 147 onView(withText(mResources.getString(R.string.popup_menu_share_circles))) in testBasicContent() [all …]
|
D | AppCompatButtonTest.java | 47 final String text1 = mResources.getString(R.string.sample_text1); in testAllCaps() 48 final String text2 = mResources.getString(R.string.sample_text2); in testAllCaps() 77 final String text = mResources.getString(R.string.sample_text2); in testAppCompatAllCapsFalseOnButton()
|
/frameworks/base/core/java/android/view/ |
D | ContextThemeWrapper.java | 35 private Resources mResources; field in ContextThemeWrapper 94 if (mResources != null) { in applyOverrideConfiguration() 125 if (mResources == null) { in getResourcesInternal() 127 mResources = super.getResources(); in getResourcesInternal() 130 mResources = resContext.getResources(); in getResourcesInternal() 133 return mResources; in getResourcesInternal()
|
/frameworks/base/tools/layoutlib/bridge/src/com/android/layoutlib/bridge/impl/ |
D | Layout.java | 315 private final RenderResources mResources; field in Layout.Builder 332 mResources = mParams.getResources(); in Builder() 333 mWindowIsFloating = getBooleanThemeValue(mResources, ATTR_WINDOW_FLOATING, true, true); in Builder() 346 mWindowBackground = mResources.findItemInTheme(ATTR_WINDOW_BACKGROUND, true); in findBackground() 347 mWindowBackground = mResources.resolveResValue(mWindowBackground); in findBackground() 353 getBooleanThemeValue(mResources, ATTR_WINDOW_FULL_SCREEN, true, false); in findStatusBar() 357 mTranslucentStatus = getBooleanThemeValue(mResources, in findStatusBar() 367 boolean windowActionBar = getBooleanThemeValue(mResources, ATTR_WINDOW_ACTION_BAR, in findActionBar() 374 getBooleanThemeValue(mResources, ATTR_WINDOW_NO_TITLE, true, false); in findActionBar() 402 mTranslucentNav = getBooleanThemeValue(mResources, in findNavBar() [all …]
|
/frameworks/support/graphics/drawable/static/tests/src/android/support/graphics/drawable/tests/ |
D | VectorDrawableTest.java | 117 private Resources mResources; field in VectorDrawableTest 132 mResources = mContext.getResources(); in setup() 145 mVectorDrawable = VectorDrawableCompat.create(mResources, resIds[i], mTheme); in verifyVectorDrawables() 158 Bitmap golden = BitmapFactory.decodeResource(mResources, goldenImages[i]); in verifyVectorDrawables() 159 compareImages(mBitmap, golden, mResources.getString(resIds[i])); in verifyVectorDrawables() 175 String originalFilePath = mResources.getString(resIds[index]); in saveVectorDrawableIntoPNG() 217 final String state = mResources.getResourceName(stateSet[i]); in getTitleForStateSet() 269 VectorDrawableCompat.create(mResources, TEST_ICON, mTheme); in testGetChangingConfigurations() 294 VectorDrawableCompat.create(mResources, R.drawable.vector_icon_delete, mTheme); in testGetConstantState() 308 VectorDrawableCompat.create(mResources, TEST_ICON, mTheme); in testMutate() [all …]
|
/frameworks/base/core/tests/overlaytests/OverlayTest/src/com/android/overlaytest/ |
D | OverlayBaseTest.java | 15 private Resources mResources; field in OverlayBaseTest 22 mResources = getContext().getResources(); in setUp() 28 input = mResources.openRawResource(resId); in calculateRawResourceChecksum() 43 mResources.updateConfiguration(config, mResources.getDisplayMetrics()); in setLocale() 104 boolean actual = mResources.getBoolean(resId); in assertResource() 110 int actual = mResources.getInteger(resId); in assertResource() 116 String actual = mResources.getString(resId); in assertResource() 122 int[] actual = mResources.getIntArray(resId); in assertResource() 204 XmlResourceParser parser = mResources.getXml(R.xml.integer); in testAppXml() 224 input = mResources.openRawResource(resId); in testAppRaw()
|
/frameworks/opt/setupwizard/library/main/src/com/android/setupwizardlib/util/ |
D | Partner.java | 89 return new ResourceEntry(partner.mResources, partnerId, true); in getResourceEntry() 144 private final Resources mResources; field in Partner 148 mResources = res; in Partner() 156 return mResources; in getResources() 160 return mResources.getIdentifier(name, defType, mPackageName); in getIdentifier()
|
/frameworks/support/v7/appcompat/tests/src/android/support/v7/custom/ |
D | ContextWrapperFrameLayout.java | 39 private final Resources mResources; field in ContextWrapperFrameLayout.CustomContextWrapper 43 mResources = new CustomResources(base.getResources()); in CustomContextWrapper() 48 return mResources; in getResources()
|
/frameworks/opt/bitmap/src/com/android/bitmap/drawable/ |
D | ExtendedBitmapDrawable.java | 60 private final Resources mResources; field in ExtendedBitmapDrawable 76 mResources = res; in ExtendedBitmapDrawable() 94 … final int fadeOutDurationMs = mResources.getInteger(R.integer.bitmap_fade_animation_duration); in onOptsChanged() 95 mProgressDelayMs = mResources.getInteger(R.integer.bitmap_progress_animation_delay); in onOptsChanged() 99 int placeholderWidth = mResources.getDimensionPixelSize(R.dimen.placeholder_size); in onOptsChanged() 100 int placeholderHeight = mResources.getDimensionPixelSize(R.dimen.placeholder_size); in onOptsChanged() 104 placeholder = constantState.newDrawable(mResources); in onOptsChanged() 122 … mPlaceholder = new Placeholder(placeholder, mResources, placeholderWidth, placeholderHeight, in onOptsChanged() 129 int progressBarSize = mResources.getDimensionPixelSize(R.dimen.progress_bar_size); in onOptsChanged() 130 … mProgress = new Progress(mOpts.progressBar.getConstantState().newDrawable(mResources), mResources, in onOptsChanged()
|
/frameworks/opt/bitmap/src/com/android/bitmap/ |
D | ResourceRequestKey.java | 29 private Resources mResources; field in ResourceRequestKey 44 mResources = res; in ResourceRequestKey() 55 return mResources.openRawResource(mResId); in createInputStream()
|
/frameworks/support/v7/appcompat/src/android/support/v7/app/ |
D | AppCompatActivity.java | 67 private Resources mResources; field in AppCompatActivity 162 if (mResources != null) { in onConfigurationChanged() 166 mResources.updateConfiguration(newConfig, newMetrics); in onConfigurationChanged() 548 if (mResources == null && VectorEnabledTintResources.shouldBeUsed()) { in getResources() 549 mResources = new VectorEnabledTintResources(this, super.getResources()); in getResources() 551 return mResources == null ? super.getResources() : mResources; in getResources()
|
/frameworks/base/core/java/android/view/animation/ |
D | ScaleAnimation.java | 31 private final Resources mResources; field in ScaleAnimation 65 mResources = context.getResources(); in ScaleAnimation() 146 mResources = null; in ScaleAnimation() 173 mResources = null; in ScaleAnimation() 214 mResources = null; in ScaleAnimation() 265 targetSize = TypedValue.complexToDimension(data, mResources.getDisplayMetrics()); in resolveScale()
|
/frameworks/support/v17/leanback/src/android/support/v17/leanback/system/ |
D | Settings.java | 111 Resources mResources; field in Settings.Customizations 115 mResources = resources; in Customizations() 120 int resId = mResources.getIdentifier(resourceName, "bool", mPackageName); in getBoolean() 121 return resId > 0 ? mResources.getBoolean(resId) : defaultValue; in getBoolean()
|
/frameworks/base/core/tests/coretests/src/android/view/ |
D | InflateTest.java | 33 private Resources mResources; field in InflateTest 41 mResources = mContext.getResources(); in setUp() 60 mResources.flushLayoutCache(); in inflateTest()
|
/frameworks/base/core/java/android/content/res/ |
D | TypedArray.java | 71 private final Resources mResources; field in TypedArray 138 return mResources; in getResources() 451 final ColorStateList csl = mResources.loadColorStateList( in getColor() 496 return mResources.loadComplexColor(value, value.resourceId, mTheme); in getComplexColor() 531 return mResources.loadColorStateList(value, value.resourceId, mTheme); in getColorStateList() 928 return mResources.loadDrawable(value, value.resourceId, mTheme); in getDrawable() 955 return mResources.getTextArray(value.resourceId); in getTextArray() 1095 mResources.mTypedArrayPool.release(this); in recycle() 1221 mResources = resources; in TypedArray() 1222 mMetrics = mResources.getDisplayMetrics(); in TypedArray() [all …]
|
/frameworks/base/core/java/com/android/internal/os/ |
D | ZygoteInit.java | 103 private static Resources mResources; field in ZygoteInit 409 mResources = Resources.getSystem(); in preloadResources() 410 mResources.startPreloading(); in preloadResources() 415 TypedArray ar = mResources.obtainTypedArray( in preloadResources() 423 ar = mResources.obtainTypedArray( in preloadResources() 430 if (mResources.getBoolean( in preloadResources() 433 ar = mResources.obtainTypedArray( in preloadResources() 441 mResources.finishPreloading(); in preloadResources() 455 if (mResources.getColorStateList(id, null) == null) { in preloadColorStateLists() 475 if (mResources.getDrawable(id, null) == null) { in preloadDrawables()
|
/frameworks/support/graphics/drawable/animated/tests/src/android/support/graphics/drawable/tests/ |
D | AnimatedVectorDrawableTest.java | 63 private Resources mResources; field in AnimatedVectorDrawableTest 78 mResources = mContext.getResources(); in setup() 93 String originalFilePath = mResources.getString(resId); in saveVectorDrawableIntoPNG() 118 XmlPullParser parser = mResources.getXml(DRAWABLE_RES_ID); in testInflate() 131 mAnimatedVectorDrawable.inflate(mResources, parser, attrs); in testInflate()
|
/frameworks/base/libs/androidfw/ |
D | AssetManager.cpp | 143 mResources(NULL), mConfig(new ResTable_config), in AssetManager() 161 delete mResources; in ~AssetManager() 222 if (mResources != NULL) { in addAssetPath() 287 if (mResources != NULL) { in addOverlayPath() 383 ResTable* res = mResources; in setLocaleLocked() 607 size_t nextEntryIdx = mResources->getTableCount(); in appendPathToResTable() 664 ALOGV("Installing resource asset %p in to table %p\n", ass, mResources); in appendPathToResTable() 667 mResources->add(sharedRes, ap.isSystemAsset); in appendPathToResTable() 670 mResources->add(ass, idmap, nextEntryIdx + 1, !shared, appAsLib, ap.isSystemAsset); in appendPathToResTable() 678 ALOGV("Installing empty resources in to table %p\n", mResources); in appendPathToResTable() [all …]
|
/frameworks/opt/telephony/tests/telephonytests/src/com/android/internal/telephony/ |
D | ContextFixture.java | 244 return mResources; in getResources() 470 private final Resources mResources = mock(Resources.class); field in ContextFixture 517 doReturn(mConfiguration).when(mResources).getConfiguration(); in ContextFixture() 529 when(mResources.getText(eq(id))).thenReturn(value); in putResource() 530 when(mResources.getString(eq(id))).thenReturn(value); in putResource() 531 when(mResources.getString(eq(id), any())).thenAnswer(new Answer<String>() { in putResource() 541 when(mResources.getBoolean(eq(id))).thenReturn(value); in putBooleanResource() 545 doReturn(values).when(mResources).getStringArray(eq(id)); in putStringArrayResource() 549 doReturn(values).when(mResources).getIntArray(eq(id)); in putIntArrayResource()
|