mirror of
https://github.com/iSoron/uhabits.git
synced 2025-12-06 01:08:50 -06:00
Add link to privacy policy
This commit is contained in:
@@ -97,6 +97,13 @@ public class AboutRootView extends BaseRootView
|
||||
behavior.onTranslateApp();
|
||||
}
|
||||
|
||||
@OnClick(R.id.tvPrivacy)
|
||||
public void onClickPrivacy()
|
||||
{
|
||||
behavior.onClickPrivacy();
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
protected void initToolbar()
|
||||
{
|
||||
|
||||
@@ -74,4 +74,10 @@ public class AboutScreen extends BaseScreen implements AboutBehavior.Screen
|
||||
{
|
||||
activity.startActivity(intents.helpTranslate(activity));
|
||||
}
|
||||
|
||||
@Override
|
||||
public void showPrivacyPolicyWebsite()
|
||||
{
|
||||
activity.startActivity(intents.privacyPolicy(activity));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -46,6 +46,9 @@ class IntentFactory
|
||||
fun sendFeedback(context: Context) =
|
||||
buildSendToIntent(context.getString(R.string.feedbackURL))
|
||||
|
||||
fun privacyPolicy(context: Context) =
|
||||
buildViewIntent(context.getString(R.string.privacyPolicyURL))
|
||||
|
||||
fun startAboutActivity(context: Context) =
|
||||
Intent(context, AboutActivity::class.java)
|
||||
|
||||
|
||||
@@ -97,6 +97,11 @@
|
||||
style="@style/About.Item.Clickable"
|
||||
android:text="@string/pref_view_source_code"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvPrivacy"
|
||||
style="@style/About.Item.Clickable"
|
||||
android:text="@string/pref_view_privacy"/>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
|
||||
@@ -22,6 +22,7 @@
|
||||
<string name="playStoreURL">market://details?id=org.isoron.uhabits</string>
|
||||
<string name="feedbackURL" formatted="false">mailto:dev@loophabits.org?subject=Feedback%20about%20Loop%20Habit%20Tracker</string>
|
||||
<string name="bugReportURL" formatted="false">mailto:dev@loophabits.org?subject=Bug%20Report%20-%20Loop%20Habit%20Tracker</string>
|
||||
<string name="privacyPolicyURL" formatted="false">http://loophabits.org/privacy</string>
|
||||
<string name="sourceCodeURL">https://github.com/iSoron/uhabits</string>
|
||||
<string name="translateURL">http://translate.loophabits.org/</string>
|
||||
<string name="bugReportTo">dev@loophabits.org</string>
|
||||
|
||||
@@ -235,4 +235,6 @@
|
||||
<string name="no">No</string>
|
||||
<string name="customize_notification_summary">Change sound, vibration, light and other notification settings</string>
|
||||
<string name="customize_notification">Customize notifications</string>
|
||||
<string name="pref_view_privacy">View our privacy policy</string>
|
||||
|
||||
</resources>
|
||||
@@ -72,6 +72,10 @@ public class AboutBehavior
|
||||
screen.showSourceCodeWebsite();
|
||||
}
|
||||
|
||||
public void onClickPrivacy() {
|
||||
screen.showPrivacyPolicyWebsite();
|
||||
}
|
||||
|
||||
public enum Message
|
||||
{
|
||||
YOU_ARE_NOW_A_DEVELOPER
|
||||
@@ -88,6 +92,8 @@ public class AboutBehavior
|
||||
void showSourceCodeWebsite();
|
||||
|
||||
void showTranslationWebsite();
|
||||
|
||||
void showPrivacyPolicyWebsite();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user