Home
last modified time | relevance | path

Searched refs:getContext (Results 1 – 25 of 147) sorted by relevance

123456

/development/samples/MySampleRss/src/com/example/codelab/rssexample/
DRssContentProvider.java104 final Context con = getContext(); in onCreate()
106 mDb = mDbHelper.openDatabase(getContext(), DATABASE_NAME, null, DB_VERSION); in onCreate()
165 c.setNotificationUri(getContext().getContentResolver(), uri); in query()
175 getContext().getContentResolver().notifyUpdate(uri, null); in update()
189 getContext().getContentResolver().notifyInsert(CONTENT_URI, null); in insert()
199 getContext().getContentResolver().notifyDelete(uri, null); in delete()
/development/samples/ApiDemos/tests/src/com/example/android/apis/app/
DLocalServiceTest.java66 startIntent.setClass(getContext(), LocalService.class); in testStartable()
76 startIntent.setClass(getContext(), LocalService.class); in testBindable()
/development/samples/browseable/MediaBrowserService/src/com.example.android.mediabrowserservice/
DQueueAdapter.java55 convertView = LayoutInflater.from(getContext()) in getView()
75 getContext().getDrawable(R.drawable.ic_equalizer_white_24dp)); in getView()
78 getContext().getDrawable(R.drawable.ic_play_arrow_white_24dp)); in getView()
/development/samples/browseable/StorageProvider/src/com.example.android.storageprovider/
DMyCloudProvider.java96 mBaseDir = getContext().getFilesDir(); in onCreate()
125 row.add(Root.COLUMN_SUMMARY, getContext().getString(R.string.root_summary)); in queryRoots()
136 row.add(Root.COLUMN_TITLE, getContext().getString(R.string.app_name)); in queryRoots()
308 Handler handler = new Handler(getContext().getMainLooper()); in openDocument()
579 InputStream ins = getContext().getResources().openRawResource(resId);
589 String filename = getContext().getResources().getResourceEntryName(resId) + extension;
590 FileOutputStream fos = getContext().openFileOutput(filename, Context.MODE_PRIVATE);
600 TypedArray ar = getContext().getResources().obtainTypedArray(arrayResId);
615 getContext().getSharedPreferences(getContext().getString(R.string.app_name),
617 return sharedPreferences.getBoolean(getContext().getString(R.string.key_logged_in), false);
/development/samples/IntentPlayground/src/com/example/android/intentplayground/
DInlineAdapter.java74 View task = LayoutInflater.from(parent.getContext()) in onCreateViewHolder()
104 ? mTaskIdTextView.getContext().getString(R.string.new_task) in setTask()
106 int taskColor = mTaskIdTextView.getContext() in setTask()
113 View activityView = LayoutInflater.from(mActivitiesLayout.getContext()) in setTask()
/development/samples/training/threadsample/src/com/example/android/threadsample/
DDataProvider.java226 mHelper = new DataProviderHelper(getContext()); in onCreate()
261 returnCursor.setNotificationUri(getContext().getContentResolver(), uri); in query()
326 getContext().getContentResolver().notifyChange(uri, null); in insert()
394 getContext().getContentResolver().notifyChange(uri, null); in bulkInsert()
468 getContext().getContentResolver().notifyChange(uri, null); in update()
/development/samples/browseable/BasicSyncAdapter/src/com.example.android.basicsyncadapter/provider/
DFeedProvider.java65 mDatabaseHelper = new FeedDatabase(getContext()); in onCreate()
109 Context ctx = getContext(); in query()
138 Context ctx = getContext(); in insert()
170 Context ctx = getContext(); in delete()
201 Context ctx = getContext(); in update()
/development/samples/ApiDemos/src/com/example/android/apis/app/
DLoaderCustom.java119 return mLoader.getContext().getResources().getDrawable( in getIcon()
192 mLoader.getContext().registerReceiver(this, filter); in PackageIntentReceiver()
197 mLoader.getContext().registerReceiver(this, sdFilter); in PackageIntentReceiver()
222 mPm = getContext().getPackageManager(); in AppListLoader()
239 final Context context = getContext(); in loadInBackground()
303 boolean configChange = mLastConfig.applyNewConfig(getContext().getResources()); in onStartLoading()
349 getContext().unregisterReceiver(mPackageObserver); in onReset()
DLoaderThrottle.java202 mOpenHelper = new DatabaseHelper(getContext()); in onCreate()
246 c.setNotificationUri(getContext().getContentResolver(), uri); in query()
294 getContext().getContentResolver().notifyChange(noteUri, null); in insert()
332 getContext().getContentResolver().notifyChange(uri, null); in delete()
364 getContext().getContentResolver().notifyChange(uri, null); in update()
/development/samples/browseable/BatchStepSensor/src/com.example.android.batchstepsensor/cardstream/
DCardStreamLinearLayout.java242 animator = mAnimators.getDisappearingAnimator(getContext()); in onLayout()
245 animator = mAnimators.getAppearingAnimator(getContext()); in onLayout()
276 mSwipeSlop = ViewConfiguration.get(getContext()).getScaledTouchSlop(); in isSwiping()
379 mAnimators.getAppearingAnimator(getContext()) ); in setCardStreamAnimator()
381 mAnimators.getDisappearingAnimator(getContext()) ); in setCardStreamAnimator()
400 TypedArray a = getContext().obtainStyledAttributes(attrs, in initialize()
434 mSwipeSlop = ViewConfiguration.get(getContext()).getScaledTouchSlop(); in initialize()
469 ObjectAnimator animator = mAnimators.getInitalAnimator(getContext()); in runInitialAnimations()
/development/samples/browseable/ActivitySceneTransitionBasic/src/com.example.android.activityscenetransitionbasic/
DDetailActivity.java92 Picasso.with(mHeaderImageView.getContext()) in loadThumbnail()
102 Picasso.with(mHeaderImageView.getContext()) in loadFullSizeImage()
/development/apps/launchperf/src/com/android/launchperf/
DEmptyActivityLaunchPerformance.java40 mIntent.setClassName(getContext(), "com.android.launchperf.EmptyActivity"); in onCreate()
DSimpleActivityLaunchPerformance.java40 mIntent.setClassName(getContext(), "com.android.launchperf.SimpleActivity"); in onCreate()
DComplexActivityLaunchPerformance.java41 mIntent.setClassName(getContext(), "com.android.launchperf.ComplexActivity"); in onCreate()
/development/samples/Vault/src/com/example/android/vault/
DVaultProvider.java135 mKeyFile = new File(getContext().getFilesDir(), "vault.key"); in onCreate()
136 mDocumentsDir = new File(getContext().getFilesDir(), "documents"); in onCreate()
141 loadOrGenerateKeys(getContext(), mKeyFile); in onCreate()
210 row.add(Root.COLUMN_TITLE, getContext().getString(R.string.app_label)); in queryRoots()
216 row.add(Root.COLUMN_SUMMARY, getContext().getString(R.string.info_software)); in queryRoots()
300 final SharedPreferences prefs = getContext() in createDocument()
432 getContext().getContentResolver().notifyChange( in deleteDocumentReferences()
468 result.setNotificationUri(getContext().getContentResolver(), in queryChildDocuments()
474 getContext().getString(R.string.info_software_detail)); in queryChildDocuments()
/development/samples/XmlAdapters/src/com/example/android/xmladapters/
DUrlIntentListener.java36 final Context context = parent.getContext(); in onItemClick()
/development/samples/browseable/DragAndDropAcrossApps/DragSource/src/com.example.android/dragsource/
DDragSourceFragment.java161 getContext().getContentResolver().getType(imageUri)}); in setUpDraggableImage()
198 File filePath = new File(getContext().getFilesDir(), "images"); in getFileUri()
210 return FileProvider.getUriForFile(getContext(), CONTENT_AUTHORITY, newFile); in getFileUri()
/development/samples/NotePad/src/com/example/android/notepad/
DNotePadProvider.java210 mOpenHelper = new DatabaseHelper(getContext()); in onCreate()
289 c.setNotificationUri(getContext().getContentResolver(), uri); in query()
528 getContext().getContentResolver().notifyChange(noteUri, null); in insert()
609 getContext().getContentResolver().notifyChange(uri, null); in delete()
702 getContext().getContentResolver().notifyChange(uri, null); in update()
/development/samples/browseable/Notifications/Application/src/com.example.android.support.wearable.notifications/
DBackgroundPickers.java59 LayoutInflater inflater = LayoutInflater.from(mContainer.getContext()); in generatePickers()
86 Context context = mContainer.getContext(); in getRes()
/development/samples/browseable/SlidingTabsColors/src/com.example.android.common/view/
DSlidingTabLayout.java181 getContext().getTheme().resolveAttribute(android.R.attr.selectableItemBackground, in createDefaultTabView()
207 tabView = LayoutInflater.from(getContext()).inflate(mTabViewLayoutId, mTabStrip, in populateTabStrip()
213 tabView = createDefaultTabView(getContext()); in populateTabStrip()
/development/samples/ShortcutDemo/launcher/src/com/example/android/pm/shortcutlauncherdemo/
DBaseActivityListFragment.java66 Global.showToast(getContext(), e.getMessage()); in refreshList()
190 Global.showToast(getContext(), e.getMessage()); in onClick()
197 Global.showToast(getContext(), e.getMessage()); in onClick()
/development/samples/browseable/SwipeRefreshLayoutBasic/src/com.example.android.common/view/
DSlidingTabLayout.java181 getContext().getTheme().resolveAttribute(android.R.attr.selectableItemBackground, in createDefaultTabView()
207 tabView = LayoutInflater.from(getContext()).inflate(mTabViewLayoutId, mTabStrip, in populateTabStrip()
213 tabView = createDefaultTabView(getContext()); in populateTabStrip()
/development/samples/browseable/SwipeRefreshListFragment/src/com.example.android.common/view/
DSlidingTabLayout.java181 getContext().getTheme().resolveAttribute(android.R.attr.selectableItemBackground, in createDefaultTabView()
207 tabView = LayoutInflater.from(getContext()).inflate(mTabViewLayoutId, mTabStrip, in populateTabStrip()
213 tabView = createDefaultTabView(getContext()); in populateTabStrip()
/development/samples/browseable/BasicTransition/src/com.example.android.common/view/
DSlidingTabLayout.java181 getContext().getTheme().resolveAttribute(android.R.attr.selectableItemBackground, in createDefaultTabView()
207 tabView = LayoutInflater.from(getContext()).inflate(mTabViewLayoutId, mTabStrip, in populateTabStrip()
213 tabView = createDefaultTabView(getContext()); in populateTabStrip()
/development/samples/browseable/SwipeRefreshMultipleViews/src/com.example.android.common/view/
DSlidingTabLayout.java181 getContext().getTheme().resolveAttribute(android.R.attr.selectableItemBackground, in createDefaultTabView()
207 tabView = LayoutInflater.from(getContext()).inflate(mTabViewLayoutId, mTabStrip, in populateTabStrip()
213 tabView = createDefaultTabView(getContext()); in populateTabStrip()

123456