aboutsummaryrefslogtreecommitdiffstats
path: root/src/main
diff options
context:
space:
mode:
authorsteckbrief <steckbrief@chefmail.de>2018-01-28 22:09:57 +0100
committersteckbrief <steckbrief@chefmail.de>2018-01-28 22:09:57 +0100
commit622412fc723fb402035ce2600f980806952709b8 (patch)
tree5b9c07b3c5d3b14a670dce2bb8fa1e4d94942d53 /src/main
parenta892bb6f1685b84b74ba37e5a6a24ee8fb45eee7 (diff)
Introducing product flavor 'beta' and removing product flavor 'playstore'0.0.8-beta1
Diffstat (limited to 'src/main')
-rw-r--r--src/main/AndroidManifest.xml2
-rw-r--r--src/main/java/de/thedevstack/conversationsplus/providers/ConversationsPlusFileProvider.java3
-rw-r--r--src/main/java/de/thedevstack/conversationsplus/services/PushManagementService.java24
3 files changed, 27 insertions, 2 deletions
diff --git a/src/main/AndroidManifest.xml b/src/main/AndroidManifest.xml
index ca369a5d..c2fe9878 100644
--- a/src/main/AndroidManifest.xml
+++ b/src/main/AndroidManifest.xml
@@ -176,7 +176,7 @@
</intent-filter>
</service>
<provider
- android:authorities="de.thedevstack.conversationsplus"
+ android:authorities="${applicationId}"
android:name=".providers.ConversationsPlusFileProvider"
android:exported="false"
android:grantUriPermissions="true">
diff --git a/src/main/java/de/thedevstack/conversationsplus/providers/ConversationsPlusFileProvider.java b/src/main/java/de/thedevstack/conversationsplus/providers/ConversationsPlusFileProvider.java
index a718b161..577a5dd4 100644
--- a/src/main/java/de/thedevstack/conversationsplus/providers/ConversationsPlusFileProvider.java
+++ b/src/main/java/de/thedevstack/conversationsplus/providers/ConversationsPlusFileProvider.java
@@ -3,6 +3,7 @@ package de.thedevstack.conversationsplus.providers;
import android.net.Uri;
import android.support.v4.content.FileProvider;
+import de.thedevstack.conversationsplus.BuildConfig;
import de.thedevstack.conversationsplus.ConversationsPlusApplication;
import de.thedevstack.conversationsplus.entities.DownloadableFile;
@@ -12,7 +13,7 @@ import de.thedevstack.conversationsplus.entities.DownloadableFile;
public class ConversationsPlusFileProvider extends FileProvider {
private static final String SCHEME = "content";
- private static final String AUTHORITY = "de.thedevstack.conversationsplus";
+ private static final String AUTHORITY = BuildConfig.APPLICATION_ID;
public static Uri createUriForPrivateFile(DownloadableFile file) {
return FileProvider.getUriForFile(ConversationsPlusApplication.getAppContext(), AUTHORITY, file);
diff --git a/src/main/java/de/thedevstack/conversationsplus/services/PushManagementService.java b/src/main/java/de/thedevstack/conversationsplus/services/PushManagementService.java
new file mode 100644
index 00000000..c11b6e98
--- /dev/null
+++ b/src/main/java/de/thedevstack/conversationsplus/services/PushManagementService.java
@@ -0,0 +1,24 @@
+package de.thedevstack.conversationsplus.services;
+
+import de.thedevstack.conversationsplus.entities.Account;
+
+public class PushManagementService {
+
+ protected final XmppConnectionService mXmppConnectionService;
+
+ public PushManagementService(XmppConnectionService service) {
+ this.mXmppConnectionService = service;
+ }
+
+ public void registerPushTokenOnServer(Account account) {
+ //stub implementation. only affects playstore flavor
+ }
+
+ public boolean available(Account account) {
+ return false;
+ }
+
+ public boolean isStub() {
+ return true;
+ }
+}