Removed invite / other apps

pull/182/head
M66B 5 years ago
parent 0e4cfedc14
commit e556b917b6

@ -129,32 +129,26 @@ android {
dimension "all" dimension "all"
buildConfigField "boolean", "BETA_RELEASE", "true" buildConfigField "boolean", "BETA_RELEASE", "true"
buildConfigField "boolean", "PLAY_STORE_RELEASE", "false" buildConfigField "boolean", "PLAY_STORE_RELEASE", "false"
buildConfigField "String", "INVITE_URI", "\"https://email.faircode.eu/\""
buildConfigField "String", "PRO_FEATURES_URI", "\"https://email.faircode.eu/donate/\"" buildConfigField "String", "PRO_FEATURES_URI", "\"https://email.faircode.eu/donate/\""
buildConfigField "String", "CHANGELOG", "\"https://github.com/M66B/FairEmail/releases/\"" buildConfigField "String", "CHANGELOG", "\"https://github.com/M66B/FairEmail/releases/\""
buildConfigField "String", "GITHUB_LATEST_API", "\"https://api.github.com/repos/M66B/open-source-email/releases/latest\"" buildConfigField "String", "GITHUB_LATEST_API", "\"https://api.github.com/repos/M66B/open-source-email/releases/latest\""
buildConfigField "String", "APPS_URI", "\"https://github.com/M66B?tab=repositories/\""
} }
fdroid { fdroid {
dimension "all" dimension "all"
buildConfigField "boolean", "BETA_RELEASE", "true" buildConfigField "boolean", "BETA_RELEASE", "true"
buildConfigField "boolean", "PLAY_STORE_RELEASE", "false" buildConfigField "boolean", "PLAY_STORE_RELEASE", "false"
buildConfigField "String", "INVITE_URI", "\"https://email.faircode.eu/\""
buildConfigField "String", "PRO_FEATURES_URI", "\"https://email.faircode.eu/donate/\"" buildConfigField "String", "PRO_FEATURES_URI", "\"https://email.faircode.eu/donate/\""
buildConfigField "String", "CHANGELOG", "\"https://github.com/M66B/FairEmail/releases/\"" buildConfigField "String", "CHANGELOG", "\"https://github.com/M66B/FairEmail/releases/\""
buildConfigField "String", "GITHUB_LATEST_API", "\"https://api.github.com/repos/M66B/open-source-email/releases/latest\"" buildConfigField "String", "GITHUB_LATEST_API", "\"https://api.github.com/repos/M66B/open-source-email/releases/latest\""
buildConfigField "String", "APPS_URI", "\"https://github.com/M66B?tab=repositories/\""
} }
play { play {
dimension "all" dimension "all"
//minSdkVersion 23 //minSdkVersion 23
buildConfigField "boolean", "BETA_RELEASE", "true" buildConfigField "boolean", "BETA_RELEASE", "true"
buildConfigField "boolean", "PLAY_STORE_RELEASE", "true" buildConfigField "boolean", "PLAY_STORE_RELEASE", "true"
buildConfigField "String", "INVITE_URI", "\"https://play.google.com/store/apps/details?id=eu.faircode.email\""
buildConfigField "String", "PRO_FEATURES_URI", "\"https://email.faircode.eu/#pro\"" buildConfigField "String", "PRO_FEATURES_URI", "\"https://email.faircode.eu/#pro\""
buildConfigField "String", "CHANGELOG", "\"\"" buildConfigField "String", "CHANGELOG", "\"\""
buildConfigField "String", "GITHUB_LATEST_API", "\"\"" buildConfigField "String", "GITHUB_LATEST_API", "\"\""
buildConfigField "String", "APPS_URI", "\"https://play.google.com/store/apps/dev?id=8420080860664580239\""
} }
} }

@ -542,15 +542,6 @@ public class ActivityView extends ActivityBilling implements FragmentManager.OnB
} }
})); }));
extra.add(new NavMenuItem(R.drawable.baseline_people_24, R.string.menu_invite, new Runnable() {
@Override
public void run() {
if (!drawerLayout.isLocked(drawerContainer))
drawerLayout.closeDrawer(drawerContainer);
onMenuInvite();
}
}).setExternal(true));
if ((Helper.isPlayStoreInstall() || BuildConfig.DEBUG)) if ((Helper.isPlayStoreInstall() || BuildConfig.DEBUG))
extra.add(new NavMenuItem(R.drawable.baseline_star_24, R.string.menu_rate, new Runnable() { extra.add(new NavMenuItem(R.drawable.baseline_star_24, R.string.menu_rate, new Runnable() {
@Override @Override
@ -561,15 +552,6 @@ public class ActivityView extends ActivityBilling implements FragmentManager.OnB
} }
}).setExternal(true)); }).setExternal(true));
extra.add(new NavMenuItem(R.drawable.baseline_get_app_24, R.string.menu_other, new Runnable() {
@Override
public void run() {
if (!drawerLayout.isLocked(drawerContainer))
drawerLayout.closeDrawer(drawerContainer);
onMenuOtherApps();
}
}).setExternal(true));
adapterNavMenuExtra.set(extra); adapterNavMenuExtra.set(extra);
// Live data // Live data
@ -1007,12 +989,6 @@ public class ActivityView extends ActivityBilling implements FragmentManager.OnB
} }
} }
private Intent getIntentOtherApps() {
Intent intent = new Intent(Intent.ACTION_VIEW);
intent.setData(Uri.parse(BuildConfig.APPS_URI));
return intent;
}
private void onMenuFolders(long account) { private void onMenuFolders(long account) {
if (getLifecycle().getCurrentState().isAtLeast(Lifecycle.State.STARTED)) if (getLifecycle().getCurrentState().isAtLeast(Lifecycle.State.STARTED))
getSupportFragmentManager().popBackStack("unified", 0); getSupportFragmentManager().popBackStack("unified", 0);
@ -1126,18 +1102,10 @@ public class ActivityView extends ActivityBilling implements FragmentManager.OnB
fragmentTransaction.commit(); fragmentTransaction.commit();
} }
private void onMenuInvite() {
startActivity(getIntentInvite(this));
}
private void onMenuRate() { private void onMenuRate() {
new FragmentDialogRate().show(getSupportFragmentManager(), "rate"); new FragmentDialogRate().show(getSupportFragmentManager(), "rate");
} }
private void onMenuOtherApps() {
Helper.view(this, getIntentOtherApps());
}
private void onDebugInfo() { private void onDebugInfo() {
new SimpleTask<Long>() { new SimpleTask<Long>() {
@Override @Override
@ -1335,18 +1303,6 @@ public class ActivityView extends ActivityBilling implements FragmentManager.OnB
String html_url; String html_url;
} }
private static Intent getIntentInvite(Context context) {
StringBuilder sb = new StringBuilder();
sb.append(context.getString(R.string.title_try)).append("\n\n");
sb.append(BuildConfig.INVITE_URI).append("\n\n");
Intent intent = new Intent(Intent.ACTION_SEND);
intent.setType("text/plain");
intent.putExtra(Intent.EXTRA_SUBJECT, context.getString(R.string.app_name));
intent.putExtra(Intent.EXTRA_TEXT, sb.toString());
return intent;
}
public static class FragmentDialogFirst extends FragmentDialogBase { public static class FragmentDialogFirst extends FragmentDialogBase {
@NonNull @NonNull
@Override @Override

@ -122,9 +122,7 @@
<string name="menu_about">About</string> <string name="menu_about">About</string>
<string name="menu_pro">Pro features</string> <string name="menu_pro">Pro features</string>
<string name="menu_invite">Invite</string>
<string name="menu_rate">Rate this app</string> <string name="menu_rate">Rate this app</string>
<string name="menu_other">Other apps</string>
<string name="title_welcome">Welcome</string> <string name="title_welcome">Welcome</string>
<string name="title_eula">End-user license agreement</string> <string name="title_eula">End-user license agreement</string>
@ -1262,8 +1260,6 @@
<string name="title_icalendar_maybe">Maybe</string> <string name="title_icalendar_maybe">Maybe</string>
<string name="title_icalendar_calendar">Calendar</string> <string name="title_icalendar_calendar">Calendar</string>
<string name="title_try">Try FairEmail, an open source, privacy friendly email app for Android</string>
<string name="title_pro_feature">This is a pro feature</string> <string name="title_pro_feature">This is a pro feature</string>
<string name="title_pro_list">List of pro features</string> <string name="title_pro_list">List of pro features</string>
<string name="title_pro_purchase">Buy</string> <string name="title_pro_purchase">Buy</string>

Loading…
Cancel
Save