Lines Matching refs:uri
109 Uri uri = Uri.parse(drawableId); in getIcon()
110 if (ContentResolver.SCHEME_ANDROID_RESOURCE.equals(uri.getScheme())) { in getIcon()
112 drawable = new Now<Drawable>(getDrawable(uri)); in getIcon()
114 drawable = new IconLaterTask(uri); in getIcon()
142 private Drawable getDrawable(Uri uri) { in getDrawable() argument
144 String scheme = uri.getScheme(); in getDrawable()
147 OpenResourceIdResult r = getResourceId(uri); in getDrawable()
151 throw new FileNotFoundException("Resource does not exist: " + uri); in getDrawable()
155 InputStream stream = mPackageContext.getContentResolver().openInputStream(uri); in getDrawable()
157 throw new FileNotFoundException("Failed to open " + uri); in getDrawable()
165 Log.e(TAG, "Error closing icon stream for " + uri, ex); in getDrawable()
170 Log.w(TAG, "Icon not found: " + uri + ", " + fnfe.getMessage()); in getDrawable()
186 private OpenResourceIdResult getResourceId(Uri uri) throws FileNotFoundException { in getResourceId() argument
187 String authority = uri.getAuthority(); in getResourceId()
190 throw new FileNotFoundException("No authority: " + uri); in getResourceId()
198 List<String> path = uri.getPathSegments(); in getResourceId()
200 throw new FileNotFoundException("No path: " + uri); in getResourceId()
208 throw new FileNotFoundException("Single path segment is not a resource ID: " + uri); in getResourceId()
213 throw new FileNotFoundException("More than two path segments: " + uri); in getResourceId()
216 throw new FileNotFoundException("No resource found for: " + uri); in getResourceId()