/frameworks/support/core-utils/java/android/support/v4/provider/ |
TreeDocumentFile.java | 23 private Context mContext; 28 mContext = context; 34 final Uri result = DocumentsContractApi21.createFile(mContext, mUri, mimeType, displayName); 35 return (result != null) ? new TreeDocumentFile(this, mContext, result) : null; 40 final Uri result = DocumentsContractApi21.createDirectory(mContext, mUri, displayName); 41 return (result != null) ? new TreeDocumentFile(this, mContext, result) : null; 51 return DocumentsContractApi19.getName(mContext, mUri); 56 return DocumentsContractApi19.getType(mContext, mUri); 61 return DocumentsContractApi19.isDirectory(mContext, mUri); 66 return DocumentsContractApi19.isFile(mContext, mUri) [all...] |
SingleDocumentFile.java | 24 private Context mContext; 29 mContext = context; 50 return DocumentsContractApi19.getName(mContext, mUri); 55 return DocumentsContractApi19.getType(mContext, mUri); 60 return DocumentsContractApi19.isDirectory(mContext, mUri); 65 return DocumentsContractApi19.isFile(mContext, mUri); 70 return DocumentsContractApi19.lastModified(mContext, mUri); 75 return DocumentsContractApi19.length(mContext, mUri); 80 return DocumentsContractApi19.canRead(mContext, mUri); 85 return DocumentsContractApi19.canWrite(mContext, mUri) [all...] |
/cts/tests/tests/text/src/android/text/format/cts/ |
FormatterTest.java | 35 assertEquals("0 B", Formatter.formatFileSize(mContext, 0)); 36 assertEquals("1 B", Formatter.formatFileSize(mContext, 1)); 37 assertEquals("9 B", Formatter.formatFileSize(mContext, 9)); 38 assertEquals("10 B", Formatter.formatFileSize(mContext, 10)); 39 assertEquals("99 B", Formatter.formatFileSize(mContext, 99)); 40 assertEquals("100 B", Formatter.formatFileSize(mContext, 100)); 41 assertEquals("900 B", Formatter.formatFileSize(mContext, 900)); 42 assertEquals("0.88 KB", Formatter.formatFileSize(mContext, 901)); 44 assertEquals("1.00 KB", Formatter.formatFileSize(mContext, bd.pow(1).longValue())); 46 assertEquals("1.00 MB", Formatter.formatFileSize(mContext, bd.pow(2).longValue())) [all...] |
/cts/tests/tests/widget/src/android/widget/cts/ |
RadioButtonTest.java | 32 private Context mContext; 37 mContext = getInstrumentation().getTargetContext(); 41 AttributeSet attrs = mContext.getResources().getLayout(R.layout.radiogroup_1); 44 new RadioButton(mContext); 51 new RadioButton(mContext, attrs); 57 new RadioButton(mContext, null); 59 new RadioButton(mContext, attrs, 0); 65 new RadioButton(mContext, null, 0); 66 new RadioButton(mContext, attrs, Integer.MAX_VALUE); 67 new RadioButton(mContext, attrs, Integer.MIN_VALUE) [all...] |
ZoomControlsTest.java | 31 private Context mContext; 36 mContext = getInstrumentation().getContext(); 41 new ZoomControls(mContext); 43 new ZoomControls(mContext, null); 48 ZoomControls zoomControls = new ZoomControls(mContext); 66 ZoomControls zoomControls = new ZoomControls(mContext); 78 ZoomControls zoomControls = new ZoomControls(mContext); 91 final ZoomControls zoomControls = new ZoomControls(mContext); 103 ZoomControls zoomControls = new ZoomControls(mContext); 110 ZoomControls zoomControls = new ZoomControls(mContext); [all...] |
CursorAdapterTest.java | 61 private Context mContext; 66 mContext = getInstrumentation().getTargetContext(); 67 File dbDir = mContext.getDir("tests", Context.MODE_PRIVATE); 80 final LayoutInflater inflater = LayoutInflater.from(mContext); 98 new MockCursorAdapter(mContext, mCursor); 102 new MockCursorAdapter(mContext, mCursor, true); 118 cursorAdapter.init(mContext, null, false); 119 assertSame(mContext, cursorAdapter.getContext()); 126 cursorAdapter.init(mContext, null, true); 127 assertSame(mContext, cursorAdapter.getContext()) [all...] |
/packages/apps/DeskClock/src/com/android/deskclock/data/ |
SettingsModel.java | 34 private final Context mContext; 40 mContext = context; 43 SettingsDAO.setDefaultHomeTimeZone(mContext, TimeZone.getDefault()); 47 return SettingsDAO.getCitySort(mContext); 51 SettingsDAO.toggleCitySort(mContext); 55 return SettingsDAO.getHomeTimeZone(mContext); 59 return SettingsDAO.getClockStyle(mContext); 63 return SettingsDAO.getScreensaverClockStyle(mContext); 67 if (!SettingsDAO.getAutoShowHomeClock(mContext)) { 73 final TimeZone homeTimeZone = SettingsDAO.getHomeTimeZone(mContext); [all...] |
/frameworks/base/core/tests/coretests/src/android/view/ |
CreateViewTest.java | 41 new CreateViewTest.ViewOne(mContext); 46 LinearLayout vert = new LinearLayout(mContext); 47 vert.addView(new CreateViewTest.ViewOne(mContext), 53 LinearLayout vert = new LinearLayout(mContext); 55 ViewOne one = new ViewOne(mContext); 58 ViewOne two = new ViewOne(mContext); 61 ViewOne three = new ViewOne(mContext); 64 ViewOne four = new ViewOne(mContext); 67 ViewOne five = new ViewOne(mContext); 70 ViewOne six = new ViewOne(mContext); [all...] |
/hardware/intel/img/hwcomposer/merrifield/ips/anniedale/ |
AnnRGBPlane.cpp | 30 memset(&mContext, 0, sizeof(mContext)); 51 return (void *)&mContext; 135 mContext.type = DC_SPRITE_PLANE; 137 mContext.type = DC_PRIMARY_PLANE; 147 mContext.ctx.sp_ctx.index = mIndex; 148 mContext.ctx.sp_ctx.pipe = mDevice; 149 mContext.ctx.sp_ctx.cntr = spriteFormat | 0x80000000; 150 mContext.ctx.sp_ctx.linoff = linoff; 151 mContext.ctx.sp_ctx.stride = stride [all...] |
/frameworks/base/packages/SystemUI/src/com/android/systemui/statusbar/policy/ |
RotationLockControllerImpl.java | 28 private final Context mContext; 41 mContext = context; 55 return RotationPolicy.getRotationLockOrientation(mContext); 59 return RotationPolicy.isRotationLocked(mContext); 63 RotationPolicy.setRotationLock(mContext, locked); 67 return RotationPolicy.isRotationLockToggleVisible(mContext); 73 RotationPolicy.registerRotationPolicyListener(mContext, mRotationPolicyListener, 76 RotationPolicy.unregisterRotationPolicyListener(mContext, mRotationPolicyListener); 87 callback.onRotationLockStateChanged(RotationPolicy.isRotationLocked(mContext), 88 RotationPolicy.isRotationLockToggleVisible(mContext)); [all...] |
/hardware/intel/img/hwcomposer/moorefield_hdmi/ips/anniedale/ |
AnnRGBPlane.cpp | 30 memset(&mContext, 0, sizeof(mContext)); 75 return (void *)&mContext; 194 mContext.type = DC_SPRITE_PLANE; 196 mContext.type = DC_PRIMARY_PLANE; 206 mContext.ctx.sp_ctx.index = mIndex; 207 mContext.ctx.sp_ctx.pipe = mDevice; 208 mContext.ctx.sp_ctx.cntr = spriteFormat | 0x80000000; 209 mContext.ctx.sp_ctx.linoff = linoff; 210 mContext.ctx.sp_ctx.stride = stride [all...] |
/cts/tests/tests/content/src/android/content/cts/ |
ContextTest.java | 43 private Context mContext; 48 mContext = getContext(); 49 mContext.setTheme(R.style.Test_Theme); 53 String testString = mContext.getString(R.string.context_test_string1); 56 testString = mContext.getString(R.string.context_test_string1, "expected"); 59 testString = mContext.getString(R.string.context_test_string2); 64 testString = mContext.getString(0, "expected"); 71 testString = mContext.getString(0); 78 CharSequence testCharSequence = mContext.getText(R.string.context_test_string2); 83 testCharSequence = mContext.getText(0) [all...] |
Intent_ShortcutIconResourceTest.java | 31 Context mContext; 38 mContext = getContext(); 42 String resourceName = mContext.getResources().getResourceName( 44 mShortcutIconResource = ShortcutIconResource.fromContext(mContext, 52 String resourceName = mContext.getResources().getResourceName( 54 mShortcutIconResource = ShortcutIconResource.fromContext(mContext, 59 assertEquals(mContext.getPackageName(), 65 mShortcutIconResource = ShortcutIconResource.fromContext(mContext,
|
/packages/apps/Bluetooth/src/com/android/bluetooth/btservice/ |
ProfileObserver.java | 17 private Context mContext; 23 mContext = context; 29 mContext.getContentResolver().registerContentObserver( 35 mContext.unregisterReceiver(mStateObserver); 36 Config.init(mContext); 41 mContext.getContentResolver().unregisterContentObserver(this); 47 mContext.registerReceiver(mStateObserver,
|
/cts/hostsidetests/numberblocking/app/src/com/android/cts/numberblocking/hostside/ |
NumberBlockingAppTest.java | 27 assertTrue(BlockedNumberContract.canCurrentUserBlockNumbers(mContext)); 29 assertTrue(mContext.getContentResolver().delete( 36 assertTrue(BlockedNumberContract.canCurrentUserBlockNumbers(mContext)); 42 assertFalse(BlockedNumberContract.canCurrentUserBlockNumbers(mContext)); 45 BlockedNumberContract.isBlocked(mContext, mBlockedPhoneNumber); 52 assertTrue(BlockedNumberContract.canCurrentUserBlockNumbers(mContext)); 54 assertEquals(1, mContext.getContentResolver().delete( 63 mContext.getContentResolver().insert( 65 assertTrue(BlockedNumberContract.isBlocked(mContext, mBlockedPhoneNumber));
|
/cts/tests/tests/media/src/android/media/cts/ |
RingtoneTest.java | 33 private Context mContext; 45 mContext = getInstrumentation().getContext(); 46 mAudioManager = (AudioManager) mContext.getSystemService(Context.AUDIO_SERVICE); 47 mRingtone = RingtoneManager.getRingtone(mContext, Settings.System.DEFAULT_RINGTONE_URI); 57 mContext.getPackageName(), getInstrumentation(), true); 65 mContext.getPackageName(), getInstrumentation(), false); 68 mDefaultRingUri = RingtoneManager.getActualDefaultRingtoneUri(mContext, 94 mContext.getPackageName(), getInstrumentation(), true); 100 mContext.getPackageName(), getInstrumentation(), false); 103 RingtoneManager.setActualDefaultRingtoneUri(mContext, RingtoneManager.TYPE_RINGTONE [all...] |
/frameworks/base/packages/MtpDocumentsProvider/src/com/android/mtp/ |
ServiceIntentSender.java | 27 private Context mContext; 30 mContext = context; 35 intent.setComponent(new ComponentName(mContext, MtpDocumentsService.class)); 36 mContext.startService(intent);
|
/frameworks/opt/telephony/tests/telephonytests/src/com/android/internal/telephony/dataconnection/ |
ApnSettingTest.java | 216 isMetered(mContext, 1, isRoaming)); 220 isMetered(mContext, 1, isRoaming)); 224 isMetered(mContext, 1, isRoaming)); 228 isMetered(mContext, 1, isRoaming)); 232 isMetered(mContext, 1, isRoaming)); 236 isMetered(mContext, 1, isRoaming)); 240 isMetered(mContext, 1, isRoaming)); 244 isMetered(mContext, 1, isRoaming)); 248 mContext, 1, isRoaming)); 250 mContext, 1, isRoaming)) [all...] |
/cts/tests/tests/view/src/android/view/cts/ |
OrientationListenerTest.java | 29 private Context mContext; 34 mContext = getContext(); 38 new MockOrientationListener(mContext); 40 new MockOrientationListener(mContext, SensorManager.SENSOR_DELAY_UI); 45 MockOrientationListener listener = new MockOrientationListener(mContext); 52 new MockOrientationListener(mContext).onAccuracyChanged(SensorManager.SENSOR_ACCELEROMETER, 55 new MockOrientationListener(mContext).onAccuracyChanged(SensorManager.SENSOR_ORIENTATION, 61 MockOrientationListener listener = new MockOrientationListener(mContext); 66 new MockOrientationListener(mContext).onSensorChanged(SensorManager.SENSOR_ACCELEROMETER, 73 new MockOrientationListener(mContext).onSensorChanged(SensorManager.SENSOR_MAGNETIC_FIELD [all...] |
/frameworks/base/packages/SystemUI/src/com/android/systemui/qs/ |
GlobalSetting.java | 28 private final Context mContext; 35 mContext = context; 40 return Global.getInt(mContext.getContentResolver(), mSettingName, 0); 44 Global.putInt(mContext.getContentResolver(), mSettingName, value); 50 mContext.getContentResolver().registerContentObserver( 53 mContext.getContentResolver().unregisterContentObserver(this);
|
/hardware/intel/img/hwcomposer/merrifield/ips/tangier/ |
TngSpritePlane.cpp | 29 memset(&mContext, 0, sizeof(mContext)); 88 mContext.type = DC_SPRITE_PLANE; 89 mContext.ctx.sp_ctx.index = mIndex; 90 mContext.ctx.sp_ctx.pipe = mDevice; 93 mContext.ctx.sp_ctx.cntr = PixelFormat::PLANE_PIXEL_FORMAT_BGRX8888 96 mContext.ctx.sp_ctx.cntr = spriteFormat | 0x80000000; 97 mContext.ctx.sp_ctx.linoff = linoff; 98 mContext.ctx.sp_ctx.stride = stride; 99 mContext.ctx.sp_ctx.surf = mapper.getGttOffsetInPage(0) << 12 [all...] |
/external/conscrypt/src/main/java/org/conscrypt/ |
OpenSSLX509CRLEntry.java | 31 private final long mContext; 34 mContext = ctx; 40 NativeCrypto.get_X509_REVOKED_ext_oids(mContext, 49 && (NativeCrypto.get_X509_REVOKED_ext_oids(mContext, 59 return NativeCrypto.X509_REVOKED_get_ext_oid(mContext, oid); 65 NativeCrypto.get_X509_REVOKED_ext_oids(mContext, 74 && (NativeCrypto.get_X509_REVOKED_ext_oids(mContext, 85 NativeCrypto.get_X509_REVOKED_ext_oids(mContext, 88 final long extensionRef = NativeCrypto.X509_REVOKED_get_ext(mContext, oid); 99 return NativeCrypto.i2d_X509_REVOKED(mContext); [all...] |
/frameworks/base/services/tests/servicestests/src/com/android/server/devicepolicy/ |
DevicePolicyManagerTest.java | 83 private DpmMockContext mContext; 91 mContext = getContext(); 93 when(mContext.packageManager.hasSystemFeature(eq(PackageManager.FEATURE_DEVICE_ADMIN))) 97 when(mContext.userManager.isUserUnlocked(anyInt())).thenReturn(true); 111 final long ident = mContext.binder.clearCallingIdentity(); 115 dpms = new DevicePolicyManagerServiceTestable(mContext, dataDir); 120 dpm = new DevicePolicyManagerTestable(mContext, dpms); 122 mContext.binder.restoreCallingIdentity(ident); 142 }).when(mContext.userManager).setApplicationRestrictions( 154 }).when(mContext.userManager).getApplicationRestrictions [all...] |
/cts/tests/app/src/android/app/cts/ |
PendingIntentTest.java | 40 private Context mContext; 52 mContext = getContext(); 138 mIntent.setClass(mContext, PendingIntentStubActivity.class); 140 mPendingIntent = PendingIntent.getActivity(mContext, 1, mIntent, 142 assertEquals(mContext.getPackageName(), mPendingIntent.getTargetPackage()); 152 mPendingIntent = PendingIntent.getActivity(mContext, 1, mIntent, 156 mPendingIntent = PendingIntent.getActivity(mContext, 1, mIntent, 178 mIntent.setClass(mContext, MockReceiver.class); 179 mPendingIntent = PendingIntent.getBroadcast(mContext, 1, mIntent, 189 mPendingIntent = PendingIntent.getBroadcast(mContext, 1, mIntent [all...] |
/frameworks/support/core-utils/tests/java/android/support/v4/content/ |
FileProviderTest.java | 60 strat.addRoot("tag", mContext.getFilesDir()); 62 File file = buildPath(mContext.getFilesDir(), "file.test"); 66 file = buildPath(mContext.getFilesDir(), "subdir", "file.test"); 80 strat.addRoot("tag", mContext.getFilesDir()); 82 File file = buildPath(mContext.getFilesDir(), "..", "file.test"); 92 strat.addRoot("tag1", mContext.getFilesDir()); 95 File file = buildPath(mContext.getFilesDir(), "file.test"); 101 strat.addRoot("tag2", mContext.getFilesDir()); 103 file = buildPath(mContext.getFilesDir(), "file.test"); 110 strat.addRoot("tag", mContext.getFilesDir()) [all...] |