mirror of
https://github.com/iSoron/uhabits.git
synced 2025-12-06 09:08:52 -06:00
@@ -68,7 +68,7 @@ public class AboutActivity extends Activity implements View.OnClickListener
|
|||||||
{
|
{
|
||||||
Intent intent = new Intent();
|
Intent intent = new Intent();
|
||||||
intent.setAction(Intent.ACTION_VIEW);
|
intent.setAction(Intent.ACTION_VIEW);
|
||||||
intent.setData(Uri.parse("market://details?id=org.isoron.uhabits"));
|
intent.setData(Uri.parse(getString(R.string.playStoreURL)));
|
||||||
startActivity(intent);
|
startActivity(intent);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
@@ -77,8 +77,7 @@ public class AboutActivity extends Activity implements View.OnClickListener
|
|||||||
{
|
{
|
||||||
Intent intent = new Intent();
|
Intent intent = new Intent();
|
||||||
intent.setAction(Intent.ACTION_SENDTO);
|
intent.setAction(Intent.ACTION_SENDTO);
|
||||||
intent.setData(Uri.parse("mailto:isoron+habits@gmail.com?" +
|
intent.setData(Uri.parse(getString(R.string.feedbackURL)));
|
||||||
"subject=Feedback%20about%20Loop%20Habit%20Tracker"));
|
|
||||||
startActivity(intent);
|
startActivity(intent);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
@@ -87,7 +86,7 @@ public class AboutActivity extends Activity implements View.OnClickListener
|
|||||||
{
|
{
|
||||||
Intent intent = new Intent();
|
Intent intent = new Intent();
|
||||||
intent.setAction(Intent.ACTION_VIEW);
|
intent.setAction(Intent.ACTION_VIEW);
|
||||||
intent.setData(Uri.parse("https://github.com/iSoron/uhabits"));
|
intent.setData(Uri.parse(getString(R.string.sourceCodeURL)));
|
||||||
startActivity(intent);
|
startActivity(intent);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -21,7 +21,9 @@ package org.isoron.uhabits.fragments;
|
|||||||
|
|
||||||
import android.app.Activity;
|
import android.app.Activity;
|
||||||
import android.app.Fragment;
|
import android.app.Fragment;
|
||||||
|
import android.content.Intent;
|
||||||
import android.content.SharedPreferences;
|
import android.content.SharedPreferences;
|
||||||
|
import android.net.Uri;
|
||||||
import android.os.Bundle;
|
import android.os.Bundle;
|
||||||
import android.preference.PreferenceManager;
|
import android.preference.PreferenceManager;
|
||||||
import android.view.ActionMode;
|
import android.view.ActionMode;
|
||||||
@@ -222,6 +224,15 @@ public class ListHabitsFragment extends Fragment
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
case R.id.action_faq:
|
||||||
|
{
|
||||||
|
Intent intent = new Intent();
|
||||||
|
intent.setAction(Intent.ACTION_VIEW);
|
||||||
|
intent.setData(Uri.parse(getString(R.string.helpURL)));
|
||||||
|
startActivity(intent);
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
default:
|
default:
|
||||||
return super.onOptionsItemSelected(item);
|
return super.onOptionsItemSelected(item);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -34,6 +34,12 @@
|
|||||||
android:title="@string/action_settings"
|
android:title="@string/action_settings"
|
||||||
app:showAsAction="never"/>
|
app:showAsAction="never"/>
|
||||||
|
|
||||||
|
<item
|
||||||
|
android:id="@+id/action_faq"
|
||||||
|
android:orderInCategory="100"
|
||||||
|
android:title="@string/help"
|
||||||
|
app:showAsAction="never"/>
|
||||||
|
|
||||||
<item
|
<item
|
||||||
android:id="@+id/action_about"
|
android:id="@+id/action_about"
|
||||||
android:orderInCategory="100"
|
android:orderInCategory="100"
|
||||||
|
|||||||
25
app/src/main/res/values/constants.xml
Normal file
25
app/src/main/res/values/constants.xml
Normal file
@@ -0,0 +1,25 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<!--
|
||||||
|
~ Copyright (C) 2016 Álinson Santos Xavier <isoron@gmail.com>
|
||||||
|
~
|
||||||
|
~ This file is part of Loop Habit Tracker.
|
||||||
|
~
|
||||||
|
~ Loop Habit Tracker is free software: you can redistribute it and/or modify
|
||||||
|
~ it under the terms of the GNU General Public License as published by the
|
||||||
|
~ Free Software Foundation, either version 3 of the License, or (at your
|
||||||
|
~ option) any later version.
|
||||||
|
~
|
||||||
|
~ Loop Habit Tracker is distributed in the hope that it will be useful, but
|
||||||
|
~ WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
|
||||||
|
~ or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
|
||||||
|
~ more details.
|
||||||
|
~
|
||||||
|
~ You should have received a copy of the GNU General Public License along
|
||||||
|
~ with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
-->
|
||||||
|
<resources>
|
||||||
|
<string name="helpURL">https://isoron.github.io/uhabits/faq.html</string>
|
||||||
|
<string name="playStoreURL">market://details?id=org.isoron.uhabits</string>
|
||||||
|
<string name="feedbackURL" formatted="false">mailto:isoron+habits@gmail.com?subject=Feedback%20about%20Loop%20Habit%20Tracker</string>
|
||||||
|
<string name="sourceCodeURL">https://github.com/iSoron/uhabits</string>
|
||||||
|
</resources>
|
||||||
@@ -137,4 +137,5 @@
|
|||||||
<string name="two_times_per_week">2 times per week</string>
|
<string name="two_times_per_week">2 times per week</string>
|
||||||
<string name="five_times_per_week">5 times per week</string>
|
<string name="five_times_per_week">5 times per week</string>
|
||||||
<string name="custom_frequency">Custom …</string>
|
<string name="custom_frequency">Custom …</string>
|
||||||
|
<string name="help">Help & FAQ</string>
|
||||||
</resources>
|
</resources>
|
||||||
@@ -44,6 +44,12 @@
|
|||||||
android:key="pref_key_links"
|
android:key="pref_key_links"
|
||||||
android:title="@string/links">
|
android:title="@string/links">
|
||||||
|
|
||||||
|
<Preference android:title="@string/help">
|
||||||
|
<intent
|
||||||
|
android:action="android.intent.action.VIEW"
|
||||||
|
android:data="@string/helpURL"/>
|
||||||
|
</Preference>
|
||||||
|
|
||||||
<Preference android:title="@string/about">
|
<Preference android:title="@string/about">
|
||||||
<intent
|
<intent
|
||||||
android:action="android.intent.action.VIEW"
|
android:action="android.intent.action.VIEW"
|
||||||
|
|||||||
Reference in New Issue
Block a user