Created
November 9, 2017 17:17
-
-
Save neosinan/9bd0d2b03d38395f1df114753ef90919 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static final Uri EC = EXTERNAL_CONTENT_URI; //Added as Media image | |
public static final Uri IC = INTERNAL_CONTENT_URI; | |
public static final String FILES = "image"; | |
public static final String PROVIDER_AUTHORITY = "com.neosinan.cspr.simplecamera"; | |
public static final Uri CONTENT_URI = Uri.parse("content://" | |
+ PROVIDER_AUTHORITY + "/"); | |
public static final Uri FILES_URI = Uri.parse("content://" | |
+ PROVIDER_AUTHORITY + "/" + FILES + "/"); | |
public static final String CONTENT_TYPE = "vnd.android.cursor.dir/image" + PROVIDER_AUTHORITY + "." + FILES; | |
public static final String CONTENT_ITEM_TYPE = "vnd.android.cursor.dir/image" + PROVIDER_AUTHORITY + "." + FILES; | |
static final int FILE_ROOT = 1; | |
static final int FILE_ID = 2; | |
public static final String CONTENT_TYP = "vnd.android.cursor.dir/image"; | |
public static final String CONTENT = "content://vnd.android.cursor.dir/image"; | |
@Nullable | |
@Override | |
public String getType(@NonNull Uri uri) { | |
/*String path = uri.toString(); | |
for (String extension : MIME_TYPES.keySet()) { | |
if (path.endsWith(extension)) { | |
return (MIME_TYPES.get(extension)); | |
} | |
} | |
return (null);*/ | |
return CONTENT; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment