/frameworks/support/v7/appcompat/src/androidTest/java/androidx/appcompat/app/inflater/ |
D | CustomViewInflater.java | 36 public CustomTextView(Context context) { in CustomTextView() argument 37 super(context); in CustomTextView() 40 public CustomTextView(Context context, in CustomTextView() argument 42 super(context, attrs); in CustomTextView() 45 public CustomTextView(Context context, in CustomTextView() argument 47 super(context, attrs, defStyleAttr); in CustomTextView() 52 public CustomButton(Context context) { in CustomButton() argument 53 super(context); in CustomButton() 56 public CustomButton(Context context, AttributeSet attrs) { in CustomButton() argument 57 super(context, attrs); in CustomButton() [all …]
|
/frameworks/support/v7/appcompat/src/main/java/androidx/appcompat/app/ |
D | AppCompatViewInflater.java | 79 final View createView(View parent, final String name, @NonNull Context context, in createView() argument 82 final Context originalContext = context; in createView() 87 context = parent.getContext(); in createView() 91 context = themifyContext(context, attrs, readAndroidTheme, readAppTheme); in createView() 94 context = TintContextWrapper.wrap(context); in createView() 102 view = createTextView(context, attrs); in createView() 106 view = createImageView(context, attrs); in createView() 110 view = createButton(context, attrs); in createView() 114 view = createEditText(context, attrs); in createView() 118 view = createSpinner(context, attrs); in createView() [all …]
|
/frameworks/av/packages/MediaComponents/src/com/android/support/mediarouter/app/ |
D | MediaRouterThemeHelper.java | 46 static Context createThemedButtonContext(Context context) { in createThemedButtonContext() argument 48 context = new ContextThemeWrapper(context, getRouterThemeId(context)); in createThemedButtonContext() 51 int style = getThemeResource(context, R.attr.mediaRouteTheme); in createThemedButtonContext() 53 context = new ContextThemeWrapper(context, style); in createThemedButtonContext() 56 return context; in createThemedButtonContext() 72 static Context createThemedDialogContext(Context context, int theme, boolean alertDialog) { in createThemedDialogContext() argument 77 theme = getThemeResource(context, in createThemedDialogContext() 81 context = new ContextThemeWrapper(context, theme); in createThemedDialogContext() 84 if (getThemeResource(context, R.attr.mediaRouteTheme) != 0) { in createThemedDialogContext() 85 context = new ContextThemeWrapper(context, getRouterThemeId(context)); in createThemedDialogContext() [all …]
|
/frameworks/support/mediarouter/src/main/java/androidx/mediarouter/app/ |
D | MediaRouterThemeHelper.java | 46 static Context createThemedButtonContext(Context context) { in createThemedButtonContext() argument 48 context = new ContextThemeWrapper(context, getRouterThemeId(context)); in createThemedButtonContext() 51 int style = getThemeResource(context, R.attr.mediaRouteTheme); in createThemedButtonContext() 53 context = new ContextThemeWrapper(context, style); in createThemedButtonContext() 56 return context; in createThemedButtonContext() 72 static Context createThemedDialogContext(Context context, int theme, boolean alertDialog) { in createThemedDialogContext() argument 77 theme = getThemeResource(context, !alertDialog in createThemedDialogContext() 82 context = new ContextThemeWrapper(context, theme); in createThemedDialogContext() 85 if (getThemeResource(context, R.attr.mediaRouteTheme) != 0) { in createThemedDialogContext() 86 context = new ContextThemeWrapper(context, getRouterThemeId(context)); in createThemedDialogContext() [all …]
|
/frameworks/base/packages/CarrierDefaultApp/src/com/android/carrierdefaultapp/ |
D | CarrierActionUtils.java | 60 public static void applyCarrierAction(int actionIdx, Intent intent, Context context) { in applyCarrierAction() argument 63 onEnableAllMeteredApns(intent, context); in applyCarrierAction() 66 onDisableAllMeteredApns(intent, context); in applyCarrierAction() 69 onDisableRadio(intent, context); in applyCarrierAction() 72 onEnableRadio(intent, context); in applyCarrierAction() 75 onShowCaptivePortalNotification(intent, context); in applyCarrierAction() 78 onShowNoDataServiceNotification(context); in applyCarrierAction() 81 onCancelAllNotifications(context); in applyCarrierAction() 84 onEnableDefaultURLHandler(context); in applyCarrierAction() 87 onDisableDefaultURLHandler(context); in applyCarrierAction() [all …]
|
/frameworks/support/leanback/src/main/java/androidx/leanback/widget/ |
D | PlaybackControlsRow.java | 219 public PlayPauseAction(Context context) { 222 drawables[INDEX_PLAY] = getStyledDrawable(context, 224 drawables[INDEX_PAUSE] = getStyledDrawable(context, 229 labels[INDEX_PLAY] = context.getString(R.string.lb_playback_controls_play); 230 labels[INDEX_PAUSE] = context.getString(R.string.lb_playback_controls_pause); 246 public FastForwardAction(Context context) { 247 this(context, 1); 255 public FastForwardAction(Context context, int numSpeeds) { 262 drawables[0] = getStyledDrawable(context, 267 labels[0] = context.getString(R.string.lb_playback_controls_fast_forward); [all …]
|
/frameworks/base/core/java/android/app/admin/ |
D | DeviceAdminReceiver.java | 515 public DevicePolicyManager getManager(Context context) { in getManager() argument 519 mManager = (DevicePolicyManager)context.getSystemService( in getManager() 529 public ComponentName getWho(Context context) { in getWho() argument 533 mWho = new ComponentName(context, getClass()); in getWho() 550 public void onEnabled(Context context, Intent intent) { in onEnabled() argument 564 public CharSequence onDisableRequested(Context context, Intent intent) { in onDisableRequested() argument 576 public void onDisabled(Context context, Intent intent) { in onDisabled() argument 591 public void onPasswordChanged(Context context, Intent intent) { in onPasswordChanged() argument 605 public void onPasswordChanged(Context context, Intent intent, UserHandle user) { in onPasswordChanged() argument 606 onPasswordChanged(context, intent); in onPasswordChanged() [all …]
|
/frameworks/av/packages/MediaComponents/src/com/android/media/update/ |
D | ApiHelper.java | 57 public static Resources getLibResources(Context context) { in getLibResources() argument 58 return getLibTheme(context).getResources(); in getLibResources() 61 public static Theme getLibTheme(Context context) { in getLibTheme() argument 64 return getLibThemeSynchronized(context); in getLibTheme() 67 public static Theme getLibTheme(Context context, int themeId) { in getLibTheme() argument 68 Theme theme = getLibResources(context).newTheme(); in getLibTheme() 73 public static LayoutInflater getLayoutInflater(Context context) { in getLayoutInflater() argument 74 return getLayoutInflater(context, null); in getLayoutInflater() 77 public static LayoutInflater getLayoutInflater(Context context, Theme theme) { in getLayoutInflater() argument 79 theme = getLibTheme(context); in getLayoutInflater() [all …]
|
/frameworks/support/documentfile/src/main/java/androidx/documentfile/provider/ |
D | DocumentsContractApi19.java | 39 public static boolean isVirtual(Context context, Uri self) { in isVirtual() argument 40 if (!DocumentsContract.isDocumentUri(context, self)) { in isVirtual() 44 return (getFlags(context, self) & FLAG_VIRTUAL_DOCUMENT) != 0; in isVirtual() 48 public static String getName(Context context, Uri self) { in getName() argument 49 return queryForString(context, self, DocumentsContract.Document.COLUMN_DISPLAY_NAME, null); in getName() 53 private static String getRawType(Context context, Uri self) { in getRawType() argument 54 return queryForString(context, self, DocumentsContract.Document.COLUMN_MIME_TYPE, null); in getRawType() 58 public static String getType(Context context, Uri self) { in getType() argument 59 final String rawType = getRawType(context, self); in getType() 67 public static long getFlags(Context context, Uri self) { in getFlags() argument [all …]
|
/frameworks/opt/net/wifi/service/java/com/android/server/wifi/ |
D | FrameworkFacade.java | 47 public boolean setIntegerSetting(Context context, String name, int def) { in setIntegerSetting() argument 48 return Settings.Global.putInt(context.getContentResolver(), name, def); in setIntegerSetting() 51 public int getIntegerSetting(Context context, String name, int def) { in getIntegerSetting() argument 52 return Settings.Global.getInt(context.getContentResolver(), name, def); in getIntegerSetting() 55 public long getLongSetting(Context context, String name, long def) { in getLongSetting() argument 56 return Settings.Global.getLong(context.getContentResolver(), name, def); in getLongSetting() 59 public boolean setStringSetting(Context context, String name, String def) { in setStringSetting() argument 60 return Settings.Global.putString(context.getContentResolver(), name, def); in setStringSetting() 63 public String getStringSetting(Context context, String name) { in getStringSetting() argument 64 return Settings.Global.getString(context.getContentResolver(), name); in getStringSetting() [all …]
|
/frameworks/base/packages/SettingsLib/src/com/android/settingslib/ |
D | RestrictedLockUtils.java | 59 public static Drawable getRestrictedPadlock(Context context) { in getRestrictedPadlock() argument 60 Drawable restrictedPadlock = context.getDrawable(R.drawable.ic_info); in getRestrictedPadlock() 61 final int iconSize = context.getResources().getDimensionPixelSize( in getRestrictedPadlock() 78 public static EnforcedAdmin checkIfRestrictionEnforced(Context context, in checkIfRestrictionEnforced() argument 80 final DevicePolicyManager dpm = (DevicePolicyManager) context.getSystemService( in checkIfRestrictionEnforced() 86 final UserManager um = UserManager.get(context); in checkIfRestrictionEnforced() 102 return getProfileOwner(context, userRestriction, adminUserId); in checkIfRestrictionEnforced() 108 ? getProfileOwner(context, userRestriction, adminUserId) in checkIfRestrictionEnforced() 115 ? getDeviceOwner(context, userRestriction) in checkIfRestrictionEnforced() 123 public static boolean hasBaseUserRestriction(Context context, in hasBaseUserRestriction() argument [all …]
|
/frameworks/base/packages/SettingsLib/src/com/android/settingslib/fuelgauge/ |
D | BatterySaverUtils.java | 66 public Parameters(Context context) { in Parameters() argument 67 mContext = context; in Parameters() 91 public static synchronized boolean setPowerSaveMode(Context context, in setPowerSaveMode() argument 96 final ContentResolver cr = context.getContentResolver(); in setPowerSaveMode() 98 if (enable && needFirstTimeWarning && maybeShowBatterySaverConfirmation(context)) { in setPowerSaveMode() 102 setBatterySaverConfirmationAcknowledged(context); in setPowerSaveMode() 105 if (context.getSystemService(PowerManager.class).setPowerSaveMode(enable)) { in setPowerSaveMode() 111 final Parameters parameters = new Parameters(context); in setPowerSaveMode() 118 showAutoBatterySaverSuggestion(context); in setPowerSaveMode() 127 private static boolean maybeShowBatterySaverConfirmation(Context context) { in maybeShowBatterySaverConfirmation() argument [all …]
|
/frameworks/base/packages/SystemUI/src/com/android/systemui/ |
D | Prefs.java | 108 public static boolean getBoolean(Context context, @Key String key, boolean defaultValue) { in getBoolean() argument 109 return get(context).getBoolean(key, defaultValue); in getBoolean() 112 public static void putBoolean(Context context, @Key String key, boolean value) { in putBoolean() argument 113 get(context).edit().putBoolean(key, value).apply(); in putBoolean() 116 public static int getInt(Context context, @Key String key, int defaultValue) { in getInt() argument 117 return get(context).getInt(key, defaultValue); in getInt() 120 public static void putInt(Context context, @Key String key, int value) { in putInt() argument 121 get(context).edit().putInt(key, value).apply(); in putInt() 124 public static long getLong(Context context, @Key String key, long defaultValue) { in getLong() argument 125 return get(context).getLong(key, defaultValue); in getLong() [all …]
|
/frameworks/base/core/java/com/android/internal/view/ |
D | RotationPolicy.java | 58 public static boolean isRotationSupported(Context context) { in isRotationSupported() argument 59 PackageManager pm = context.getPackageManager(); in isRotationSupported() 63 && context.getResources().getBoolean( in isRotationSupported() 75 public static int getRotationLockOrientation(Context context) { in getRotationLockOrientation() argument 76 if (!areAllRotationsAllowed(context)) { in getRotationLockOrientation() 93 public static boolean isRotationLockToggleVisible(Context context) { in isRotationLockToggleVisible() argument 94 return isRotationSupported(context) && in isRotationLockToggleVisible() 95 Settings.System.getIntForUser(context.getContentResolver(), in isRotationLockToggleVisible() 103 public static boolean isRotationLocked(Context context) { in isRotationLocked() argument 104 return Settings.System.getIntForUser(context.getContentResolver(), in isRotationLocked() [all …]
|
/frameworks/opt/telephony/src/java/com/android/internal/telephony/util/ |
D | NotificationChannelController.java | 54 private static void createAll(Context context) { in createAll() argument 57 context.getText(R.string.notification_channel_network_alert), in createAll() 66 context.getText(R.string.notification_channel_mobile_data_status), in createAll() 73 context.getText(R.string.notification_channel_sim), in createAll() 79 context.getSystemService(NotificationManager.class) in createAll() 82 context.getText(R.string.notification_channel_call_forward), in createAll() 85 context.getText(R.string.notification_channel_sms), in createAll() 88 context.getText(R.string.notification_channel_wfc), in createAll() 94 if (getChannel(CHANNEL_ID_VOICE_MAIL, context) != null) { in createAll() 95 migrateVoicemailNotificationSettings(context); in createAll() [all …]
|
/frameworks/base/tests/NetworkSecurityConfigTest/src/android/security/net/config/ |
D | XmlConfigTests.java | 61 SSLContext context = TestUtils.getSSLContext(source); in testEmptyConfigFile() local 62 TestUtils.assertConnectionSucceeds(context, "android.com", 443); in testEmptyConfigFile() 63 TestUtils.assertConnectionSucceeds(context, "developer.android.com", 443); in testEmptyConfigFile() 64 TestUtils.assertUrlConnectionSucceeds(context, "google.com", 443); in testEmptyConfigFile() 80 SSLContext context = TestUtils.getSSLContext(source); in testEmptyAnchors() local 81 TestUtils.assertConnectionFails(context, "android.com", 443); in testEmptyAnchors() 82 TestUtils.assertConnectionFails(context, "developer.android.com", 443); in testEmptyAnchors() 83 TestUtils.assertUrlConnectionFails(context, "google.com", 443); in testEmptyAnchors() 107 SSLContext context = TestUtils.getSSLContext(source); in testBasicDomainConfig() local 108 TestUtils.assertConnectionSucceeds(context, "android.com", 443); in testBasicDomainConfig() [all …]
|
/frameworks/support/v7/appcompat/src/main/java/androidx/appcompat/widget/ |
D | AppCompatDrawableManager.java | 70 Drawable createFromXmlInner(@NonNull Context context, @NonNull XmlPullParser parser, in createFromXmlInner() argument 185 public Drawable getDrawable(@NonNull Context context, @DrawableRes int resId) { in getDrawable() argument 186 return getDrawable(context, resId, false); in getDrawable() 189 Drawable getDrawable(@NonNull Context context, @DrawableRes int resId, in getDrawable() argument 191 checkVectorDrawableSetup(context); in getDrawable() 193 Drawable drawable = loadDrawableFromDelegates(context, resId); in getDrawable() 195 drawable = createDrawableIfNeeded(context, resId); in getDrawable() 198 drawable = ContextCompat.getDrawable(context, resId); in getDrawable() 203 drawable = tintDrawable(context, resId, failIfNotKnown, drawable); in getDrawable() 212 public void onConfigurationChanged(@NonNull Context context) { in onConfigurationChanged() argument [all …]
|
/frameworks/base/packages/SettingsLib/src/com/android/settingslib/bluetooth/ |
D | Utils.java | 37 static void showError(Context context, String name, int messageResId) { in showError() argument 39 sErrorListener.onShowError(context, name, messageResId); in showError() 48 void onShowError(Context context, String name, int messageResId); in onShowError() argument 51 public static Pair<Drawable, String> getBtClassDrawableWithDescription(Context context, in getBtClassDrawableWithDescription() argument 53 return getBtClassDrawableWithDescription(context, cachedDevice, 1 /* iconScale */); in getBtClassDrawableWithDescription() 56 public static Pair<Drawable, String> getBtClassDrawableWithDescription(Context context, in getBtClassDrawableWithDescription() argument 63 return new Pair<>(getBluetoothDrawable(context, R.drawable.ic_bt_laptop, level, in getBtClassDrawableWithDescription() 65 context.getString(R.string.bluetooth_talkback_computer)); in getBtClassDrawableWithDescription() 69 getBluetoothDrawable(context, R.drawable.ic_bt_cellphone, level, in getBtClassDrawableWithDescription() 71 context.getString(R.string.bluetooth_talkback_phone)); in getBtClassDrawableWithDescription() [all …]
|
/frameworks/base/telecomm/java/android/telecom/ |
D | DefaultDialerManager.java | 51 public static boolean setDefaultDialerApplication(Context context, String packageName) { in setDefaultDialerApplication() argument 52 return setDefaultDialerApplication(context, packageName, ActivityManager.getCurrentUser()); in setDefaultDialerApplication() 65 public static boolean setDefaultDialerApplication(Context context, String packageName, in setDefaultDialerApplication() argument 68 String oldPackageName = Settings.Secure.getStringForUser(context.getContentResolver(), in setDefaultDialerApplication() 77 List<String> packageNames = getInstalledDialerApplications(context); in setDefaultDialerApplication() 81 Settings.Secure.putStringForUser(context.getContentResolver(), in setDefaultDialerApplication() 101 public static String getDefaultDialerApplication(Context context) { in getDefaultDialerApplication() argument 102 return getDefaultDialerApplication(context, context.getUserId()); in getDefaultDialerApplication() 118 public static String getDefaultDialerApplication(Context context, int user) { in getDefaultDialerApplication() argument 119 String defaultPackageName = Settings.Secure.getStringForUser(context.getContentResolver(), in getDefaultDialerApplication() [all …]
|
/frameworks/base/packages/EasterEgg/src/com/android/egg/neko/ |
D | Cat.java | 143 public Cat(Context context, long seed) { in Cat() argument 144 D = new CatParts(context); in Cat() 147 setName(context.getString(R.string.default_cat_name, in Cat() 202 public static Cat create(Context context) { 203 return new Cat(context, Math.abs(ThreadLocalRandom.current().nextInt())); 206 public Notification.Builder buildNotification(Context context) { 208 extras.putString("android.substName", context.getString(R.string.notification_name)); 210 .setClass(context, NekoLand.class) 212 return new Notification.Builder(context) 213 .setSmallIcon(Icon.createWithResource(context, R.drawable.stat_icon)) [all …]
|
/frameworks/rs/tests/java_api/RSUnitTests/supportlibsrc_gen/com/android/rs/unittest/ |
D | ctxt_default.rs | 30 int RS_KERNEL root(int ain, rs_kernel_context context, uint32_t x) { 31 _RS_ASSERT_EQU(rsGetArray0(context), 0); 32 _RS_ASSERT_EQU(rsGetArray1(context), 0); 33 _RS_ASSERT_EQU(rsGetArray2(context), 0); 34 _RS_ASSERT_EQU(rsGetArray3(context), 0); 35 _RS_ASSERT_EQU(rsGetFace(context), RS_ALLOCATION_CUBEMAP_FACE_POSITIVE_X); 36 _RS_ASSERT_EQU(rsGetLod(context), 0); 38 _RS_ASSERT_EQU(rsGetDimY(context), 0); 39 _RS_ASSERT_EQU(rsGetDimZ(context), 0); 40 _RS_ASSERT_EQU(rsGetDimArray0(context), 0); [all …]
|
/frameworks/rs/tests/java_api/RSUnitTests/src/com/android/rs/unittest/ |
D | ctxt_default.rs | 28 int RS_KERNEL root(int ain, rs_kernel_context context, uint32_t x) { 29 _RS_ASSERT_EQU(rsGetArray0(context), 0); 30 _RS_ASSERT_EQU(rsGetArray1(context), 0); 31 _RS_ASSERT_EQU(rsGetArray2(context), 0); 32 _RS_ASSERT_EQU(rsGetArray3(context), 0); 33 _RS_ASSERT_EQU(rsGetFace(context), RS_ALLOCATION_CUBEMAP_FACE_POSITIVE_X); 34 _RS_ASSERT_EQU(rsGetLod(context), 0); 36 _RS_ASSERT_EQU(rsGetDimY(context), 0); 37 _RS_ASSERT_EQU(rsGetDimZ(context), 0); 38 _RS_ASSERT_EQU(rsGetDimArray0(context), 0); [all …]
|
/frameworks/rs/ |
D | rsHidlAdaptation.cpp | 190 IContext *RsHidlAdaptation::GetIContextHandle(RsContext context) { in GetIContextHandle() argument 191 return (IContext *)context; in GetIContextHandle() 197 sp<IContext> context = mHidl->contextCreate(sdkVersion, (ContextType)ct, flags); in ContextCreate() local 198 RsContext ret = (RsContext)(uintptr_t)context.get(); in ContextCreate() 201 mContexts.insert(context); in ContextCreate() 205 void RsHidlAdaptation::ContextDestroy (RsContext context) in ContextDestroy() argument 208 GetIContextHandle(context)->contextDestroy(); in ContextDestroy() 211 mContexts.erase((IContext*)context); in ContextDestroy() 214 const void* RsHidlAdaptation::AllocationGetType(RsContext context, RsAllocation allocation) in AllocationGetType() argument 218 uint64_t typeRet = GetIContextHandle(context)->allocationGetType(_allocation); in AllocationGetType() [all …]
|
/frameworks/opt/telephony/src/java/com/android/internal/telephony/uicc/ |
D | InstallCarrierAppUtils.java | 52 static void showNotification(Context context, String pkgName) { in showNotification() argument 56 String appName = getAppNameFromPackageName(context, pkgName); in showNotification() 67 context.getContentResolver(), in showNotification() 70 PendingIntent goToStore = PendingIntent.getActivity(context, 0, in showNotification() 76 Notification notification = new Notification.Builder(context, in showNotification() 86 getNotificationManager(context).notify( in showNotification() 92 static void hideAllNotifications(Context context) { in hideAllNotifications() argument 93 NotificationManager notificationManager = getNotificationManager(context); in hideAllNotifications() 107 static void hideNotification(Context context, String pkgName) { in hideNotification() argument 108 getNotificationManager(context).cancel(pkgName, ACTIVATE_CELL_SERVICE_NOTIFICATION_ID); in hideNotification() [all …]
|
/frameworks/base/packages/SettingsLib/src/com/android/settingslib/core/instrumentation/ |
D | MetricsFeatureProvider.java | 44 public void visible(Context context, int source, int category) { in visible() argument 46 writer.visible(context, source, category); in visible() 50 public void hidden(Context context, int category) { in hidden() argument 52 writer.hidden(context, category); in hidden() 56 public void actionWithSource(Context context, int source, int category) { in actionWithSource() argument 58 writer.actionWithSource(context, source, category); in actionWithSource() 84 public void action(Context context, int category, Pair<Integer, Object>... taggedData) { in action() argument 86 writer.action(context, category, taggedData); in action() 92 public void action(Context context, int category, int value) { in action() argument 94 writer.action(context, category, value); in action() [all …]
|