diff options
author | lookshe <github@lookshe.org> | 2016-03-27 14:46:54 +0200 |
---|---|---|
committer | lookshe <github@lookshe.org> | 2016-03-27 14:46:54 +0200 |
commit | a3bfd4a30256dcdd65b06c2b5b3082b0a06b74be (patch) | |
tree | afc2d6fd3aa4e1ad1df4922875ef2c52409bcf96 /src/main/java/de/thedevstack | |
parent | 903bf55b5e80043f020f774af7ed253be388dd41 (diff) | |
parent | 9773b16a98c946e42d39afccc6255e1f1f611aed (diff) |
Merge branch 'trz/rename' into trz/rebase
Diffstat (limited to 'src/main/java/de/thedevstack')
-rw-r--r-- | src/main/java/de/thedevstack/conversationsplus/providers/ConversationsPlusFileProvider.java | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/src/main/java/de/thedevstack/conversationsplus/providers/ConversationsPlusFileProvider.java b/src/main/java/de/thedevstack/conversationsplus/providers/ConversationsPlusFileProvider.java new file mode 100644 index 00000000..a718b161 --- /dev/null +++ b/src/main/java/de/thedevstack/conversationsplus/providers/ConversationsPlusFileProvider.java @@ -0,0 +1,20 @@ +package de.thedevstack.conversationsplus.providers; + +import android.net.Uri; +import android.support.v4.content.FileProvider; + +import de.thedevstack.conversationsplus.ConversationsPlusApplication; +import de.thedevstack.conversationsplus.entities.DownloadableFile; + +/** + * Created by lookshe on 27.03.16. + */ +public class ConversationsPlusFileProvider extends FileProvider { + + private static final String SCHEME = "content"; + private static final String AUTHORITY = "de.thedevstack.conversationsplus"; + + public static Uri createUriForPrivateFile(DownloadableFile file) { + return FileProvider.getUriForFile(ConversationsPlusApplication.getAppContext(), AUTHORITY, file); + } +} |