Skip to content

Commit

Permalink
Fix crash when opening Settings on Gingerbread
Browse files Browse the repository at this point in the history
Added links to Google+ community and CrowdIn translation to About preferences
  • Loading branch information
codinguser committed Oct 8, 2015
1 parent 4830396 commit dbed8af
Show file tree
Hide file tree
Showing 24 changed files with 108 additions and 24 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@
import android.preference.Preference;
import android.preference.PreferenceFragment;
import android.support.v7.app.ActionBar;
import android.support.v7.app.AppCompatActivity;

import org.gnucash.android.BuildConfig;
import org.gnucash.android.R;
Expand Down Expand Up @@ -50,7 +49,7 @@ public void onCreate(Bundle savedInstanceState) {
@Override
public void onResume() {
super.onResume();
Preference pref = findPreference(getString(R.string.key_build_version));
Preference pref = findPreference(getString(R.string.key_about_gnucash));
if (BuildConfig.FLAVOR.equals("development")){
pref.setSummary(pref.getSummary() + " - Built: " + BuildConfig.BUILD_TIME);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,8 @@
import org.gnucash.android.importer.ImportAsyncTask;
import org.gnucash.android.model.Money;
import org.gnucash.android.model.Transaction;
import org.gnucash.android.ui.common.UxArgument;
import org.gnucash.android.ui.account.AccountsActivity;
import org.gnucash.android.ui.common.UxArgument;
import org.gnucash.android.ui.passcode.PasscodeLockScreenActivity;
import org.gnucash.android.ui.passcode.PasscodePreferenceActivity;

Expand Down Expand Up @@ -163,6 +163,7 @@ protected void onCreate(Bundle savedInstanceState) {
addPreferencesFromResource(R.xml.fragment_general_preferences);
addPreferencesFromResource(R.xml.fragment_account_preferences);
addPreferencesFromResource(R.xml.fragment_transaction_preferences);
addPreferencesFromResource(R.xml.fragment_backup_preferences);
addPreferencesFromResource(R.xml.fragment_about_preferences);
setDefaultCurrencyListener();

Expand All @@ -181,7 +182,7 @@ protected void onCreate(Bundle savedInstanceState) {
pref = findPreference(getString(R.string.key_delete_all_accounts));
pref.setOnPreferenceClickListener(this);

pref = findPreference(getString(R.string.key_build_version));
pref = findPreference(getString(R.string.key_about_gnucash));
pref.setOnPreferenceClickListener(this);

pref = findPreference(getString(R.string.key_change_passcode));
Expand Down Expand Up @@ -309,7 +310,7 @@ public boolean onPreferenceClick(Preference preference) {
restoreBackup();
}

if (key.equals(getString(R.string.key_build_version))){
if (key.equals(getString(R.string.key_about_gnucash))){
AccountsActivity.showWhatsNewDialog(this);
return true;
}
Expand Down
1 change: 1 addition & 0 deletions app/src/main/res/layout/fragment_split_editor.xml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ limitations under the License.
-->
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:animateLayoutChanges="true"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context=".ui.FormActivity">
Expand Down
1 change: 1 addition & 0 deletions app/src/main/res/layout/fragment_transaction_form.xml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@

<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:gnucash="http://schemas.android.com/apk/res-auto"
android:animateLayoutChanges="true"
android:layout_width="match_parent"
android:layout_height="match_parent">

Expand Down
4 changes: 4 additions & 0 deletions app/src/main/res/values-de/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -554,6 +554,10 @@ No user-identifiable information will be collected as part of this process!</str
<string name="menu_group_by_year">Year</string>
<string name="title_balance_sheet_report">Balance Sheet</string>
<string name="label_balance_sheet_total">Total:</string>
<string name="title_google_plus_community">Google+ Community</string>
<string name="title_translate_gnucash">Translate GnuCash</string>
<string name="summary_google_plus">Share ideas, discuss changes or report problems</string>
<string name="summary_translate_gnucash">Translate or proof-read on CrowdIn</string>
<string-array name="report_time_range">
<item>Current month</item>
<item>Last 3 months</item>
Expand Down
4 changes: 4 additions & 0 deletions app/src/main/res/values-el/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -569,6 +569,10 @@ No user-identifiable information will be collected as part of this process!
<string name="menu_group_by_year">Year</string>
<string name="title_balance_sheet_report">Balance Sheet</string>
<string name="label_balance_sheet_total">Total:</string>
<string name="title_google_plus_community">Google+ Community</string>
<string name="title_translate_gnucash">Translate GnuCash</string>
<string name="summary_google_plus">Share ideas, discuss changes or report problems</string>
<string name="summary_translate_gnucash">Translate or proof-read on CrowdIn</string>
<string-array name="report_time_range">
<item>Current month</item>
<item>Last 3 months</item>
Expand Down
4 changes: 4 additions & 0 deletions app/src/main/res/values-es-rMX/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -558,6 +558,10 @@ No user-identifiable information will be collected as part of this process!
<string name="menu_group_by_year">Year</string>
<string name="title_balance_sheet_report">Balance Sheet</string>
<string name="label_balance_sheet_total">Total:</string>
<string name="title_google_plus_community">Google+ Community</string>
<string name="title_translate_gnucash">Translate GnuCash</string>
<string name="summary_google_plus">Share ideas, discuss changes or report problems</string>
<string name="summary_translate_gnucash">Translate or proof-read on CrowdIn</string>
<string-array name="report_time_range">
<item>Current month</item>
<item>Last 3 months</item>
Expand Down
4 changes: 4 additions & 0 deletions app/src/main/res/values-es/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -555,6 +555,10 @@ Este proceso solo recoge informaci&#243;n que no permite identificar al usuario<
<string name="menu_group_by_year">A&#241;o</string>
<string name="title_balance_sheet_report">Hoja de Balance</string>
<string name="label_balance_sheet_total">Total:</string>
<string name="title_google_plus_community">Google+ Community</string>
<string name="title_translate_gnucash">Translate GnuCash</string>
<string name="summary_google_plus">Share ideas, discuss changes or report problems</string>
<string name="summary_translate_gnucash">Translate or proof-read on CrowdIn</string>
<string-array name="report_time_range">
<item>Mes actual</item>
<item>&#218;ltimos 3 meses</item>
Expand Down
4 changes: 4 additions & 0 deletions app/src/main/res/values-fr/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -555,6 +555,10 @@ Aucune information permettant d\'identifier l\'utilisateur ne sera recueillis da
<string name="menu_group_by_year">Année</string>
<string name="title_balance_sheet_report">Bilans</string>
<string name="label_balance_sheet_total">Total:</string>
<string name="title_google_plus_community">Google+ Community</string>
<string name="title_translate_gnucash">Translate GnuCash</string>
<string name="summary_google_plus">Share ideas, discuss changes or report problems</string>
<string name="summary_translate_gnucash">Translate or proof-read on CrowdIn</string>
<string-array name="report_time_range">
<item>Mois actuel</item>
<item>3 derniers mois</item>
Expand Down
4 changes: 4 additions & 0 deletions app/src/main/res/values-hu/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -559,6 +559,10 @@ No user-identifiable information will be collected as part of this process!
<string name="menu_group_by_year">Year</string>
<string name="title_balance_sheet_report">Balance Sheet</string>
<string name="label_balance_sheet_total">Total:</string>
<string name="title_google_plus_community">Google+ Community</string>
<string name="title_translate_gnucash">Translate GnuCash</string>
<string name="summary_google_plus">Share ideas, discuss changes or report problems</string>
<string name="summary_translate_gnucash">Translate or proof-read on CrowdIn</string>
<string-array name="report_time_range">
<item>Current month</item>
<item>Last 3 months</item>
Expand Down
4 changes: 4 additions & 0 deletions app/src/main/res/values-it/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -559,6 +559,10 @@ No user-identifiable information will be collected as part of this process!
<string name="menu_group_by_year">Year</string>
<string name="title_balance_sheet_report">Balance Sheet</string>
<string name="label_balance_sheet_total">Total:</string>
<string name="title_google_plus_community">Google+ Community</string>
<string name="title_translate_gnucash">Translate GnuCash</string>
<string name="summary_google_plus">Share ideas, discuss changes or report problems</string>
<string name="summary_translate_gnucash">Translate or proof-read on CrowdIn</string>
<string-array name="report_time_range">
<item>Current month</item>
<item>Last 3 months</item>
Expand Down
4 changes: 4 additions & 0 deletions app/src/main/res/values-nb/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -556,6 +556,10 @@ Ingen brukerinformasjon vil bli delt i denne prosessen!
<string name="menu_group_by_year">Year</string>
<string name="title_balance_sheet_report">Balance Sheet</string>
<string name="label_balance_sheet_total">Total:</string>
<string name="title_google_plus_community">Google+ Community</string>
<string name="title_translate_gnucash">Translate GnuCash</string>
<string name="summary_google_plus">Share ideas, discuss changes or report problems</string>
<string name="summary_translate_gnucash">Translate or proof-read on CrowdIn</string>
<string-array name="report_time_range">
<item>Current month</item>
<item>Last 3 months</item>
Expand Down
4 changes: 4 additions & 0 deletions app/src/main/res/values-nl/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -561,6 +561,10 @@ No user-identifiable information will be collected as part of this process!
<string name="menu_group_by_year">Jaar</string>
<string name="title_balance_sheet_report">Balans</string>
<string name="label_balance_sheet_total">Totaal:</string>
<string name="title_google_plus_community">Google+ Community</string>
<string name="title_translate_gnucash">Translate GnuCash</string>
<string name="summary_google_plus">Share ideas, discuss changes or report problems</string>
<string name="summary_translate_gnucash">Translate or proof-read on CrowdIn</string>
<string-array name="report_time_range">
<item>Huidige maand</item>
<item>Afgelopen 3 maanden</item>
Expand Down
6 changes: 5 additions & 1 deletion app/src/main/res/values-pl/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
limitations under the License.
-->

<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
<resources>
<string name="title_create_account">Utwórz konto</string>
<string name="title_edit_account">Edytuj konto</string>
<string name="info_details">Info</string>
Expand Down Expand Up @@ -555,6 +555,10 @@
<string name="menu_group_by_year">Roku</string>
<string name="title_balance_sheet_report">Bilans</string>
<string name="label_balance_sheet_total">Suma:</string>
<string name="title_google_plus_community">Google+ Community</string>
<string name="title_translate_gnucash">Translate GnuCash</string>
<string name="summary_google_plus">Share ideas, discuss changes or report problems</string>
<string name="summary_translate_gnucash">Translate or proof-read on CrowdIn</string>
<string-array name="report_time_range">
<item>Bieżący miesiąc</item>
<item>Ostatnie 3 miesiące</item>
Expand Down
4 changes: 4 additions & 0 deletions app/src/main/res/values-pt-rBR/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -558,6 +558,10 @@ Nenhuma informação de identificação do usuário será coletada neste proces
<string name="menu_group_by_year">Ano</string>
<string name="title_balance_sheet_report">Balanço</string>
<string name="label_balance_sheet_total">Total:</string>
<string name="title_google_plus_community">Google+ Community</string>
<string name="title_translate_gnucash">Translate GnuCash</string>
<string name="summary_google_plus">Share ideas, discuss changes or report problems</string>
<string name="summary_translate_gnucash">Translate or proof-read on CrowdIn</string>
<string-array name="report_time_range">
<item>Mês atual</item>
<item>Last 3 meses</item>
Expand Down
6 changes: 5 additions & 1 deletion app/src/main/res/values-pt/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
limitations under the License.
-->

<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
<resources>
<string name="title_create_account">Criar Conta</string>
<string name="title_edit_account">Editar Conta</string>
<string name="info_details">Info</string>
Expand Down Expand Up @@ -554,6 +554,10 @@ Neste processo n&#227;o ser&#227;o recolhidas informa&#231;&#245;es do utilizado
<string name="label_no_favorite_accounts">Sem Contas favoritas</string>
<string name="label_no_recent_accounts">Sem Contas recentes</string>
<string name="hint_account_description">Descri&#231;&#227;o da Conta</string>
<string name="title_google_plus_community">Google+ Community</string>
<string name="title_translate_gnucash">Translate GnuCash</string>
<string name="summary_google_plus">Share ideas, discuss changes or report problems</string>
<string name="summary_translate_gnucash">Translate or proof-read on CrowdIn</string>
<string-array name="report_time_range">
<item>Current month</item>
<item>Last 3 months</item>
Expand Down
4 changes: 4 additions & 0 deletions app/src/main/res/values-ru/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -562,6 +562,10 @@
<string name="menu_group_by_year">Year</string>
<string name="title_balance_sheet_report">Balance Sheet</string>
<string name="label_balance_sheet_total">Total:</string>
<string name="title_google_plus_community">Google+ Community</string>
<string name="title_translate_gnucash">Translate GnuCash</string>
<string name="summary_google_plus">Share ideas, discuss changes or report problems</string>
<string name="summary_translate_gnucash">Translate or proof-read on CrowdIn</string>
<string-array name="report_time_range">
<item>Current month</item>
<item>Last 3 months</item>
Expand Down
4 changes: 4 additions & 0 deletions app/src/main/res/values-uk/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -542,6 +542,10 @@
<string name="menu_group_by_year">Year</string>
<string name="title_balance_sheet_report">Balance Sheet</string>
<string name="label_balance_sheet_total">Total:</string>
<string name="title_google_plus_community">Google+ Community</string>
<string name="title_translate_gnucash">Translate GnuCash</string>
<string name="summary_google_plus">Share ideas, discuss changes or report problems</string>
<string name="summary_translate_gnucash">Translate or proof-read on CrowdIn</string>
<string-array name="report_time_range">
<item>Current month</item>
<item>Last 3 months</item>
Expand Down
6 changes: 5 additions & 1 deletion app/src/main/res/values-zh-rTW/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
limitations under the License.
-->

<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
<resources>
<string name="title_create_account">建立會計科目</string>
<string name="title_edit_account">修改會計科目</string>
<string name="info_details">信息</string>
Expand Down Expand Up @@ -556,6 +556,10 @@ No user-identifiable information will be collected as part of this process!
<string name="menu_group_by_year">Year</string>
<string name="title_balance_sheet_report">Balance Sheet</string>
<string name="label_balance_sheet_total">Total:</string>
<string name="title_google_plus_community">Google+ Community</string>
<string name="title_translate_gnucash">Translate GnuCash</string>
<string name="summary_google_plus">Share ideas, discuss changes or report problems</string>
<string name="summary_translate_gnucash">Translate or proof-read on CrowdIn</string>
<string-array name="report_time_range">
<item>Current month</item>
<item>Last 3 months</item>
Expand Down
6 changes: 5 additions & 1 deletion app/src/main/res/values-zh/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
limitations under the License.
-->

<resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
<resources>
<string name="title_create_account">创建科目</string>
<string name="title_edit_account">修改科目</string>
<string name="info_details">信息</string>
Expand Down Expand Up @@ -557,6 +557,10 @@ No user-identifiable information will be collected as part of this process!
<string name="menu_group_by_year">Year</string>
<string name="title_balance_sheet_report">Balance Sheet</string>
<string name="label_balance_sheet_total">Total:</string>
<string name="title_google_plus_community">Google+ Community</string>
<string name="title_translate_gnucash">Translate GnuCash</string>
<string name="summary_google_plus">Share ideas, discuss changes or report problems</string>
<string name="summary_translate_gnucash">Translate or proof-read on CrowdIn</string>
<string-array name="report_time_range">
<item>Current month</item>
<item>Last 3 months</item>
Expand Down
2 changes: 1 addition & 1 deletion app/src/main/res/values/donottranslate.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<string name="key_license" translatable="false">app_license</string>
<string name="key_enable_passcode" translatable="false">enable_passcode</string>
<string name="key_change_passcode" translatable="false">change_passcode</string>
<string name="key_about" translatable="false">about_gnucash</string>
<string name="key_about_gnucash" translatable="false">about_gnucash</string>
<string name="key_default_transaction_type" translatable="false">default_transaction_type</string>
<string name="key_export_all_transactions" translatable="false">export_all_transactions</string>
<string name="key_delete_transactions_after_export" translatable="false">delete_transactions_after_export</string>
Expand Down
4 changes: 4 additions & 0 deletions app/src/main/res/values/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -561,6 +561,10 @@
<string name="menu_group_by_year">Year</string>
<string name="title_balance_sheet_report">Balance Sheet</string>
<string name="label_balance_sheet_total">Total:</string>
<string name="title_google_plus_community">Google+ Community</string>
<string name="title_translate_gnucash">Translate GnuCash</string>
<string name="summary_google_plus">Share ideas, discuss changes or report problems</string>
<string name="summary_translate_gnucash">Translate or proof-read on CrowdIn</string>
<string-array name="report_time_range">
<item>Current month</item>
<item>Last 3 months</item>
Expand Down
16 changes: 12 additions & 4 deletions app/src/main/res/xml-v11/fragment_about_preferences.xml
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,18 @@
-->

<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android" >
<Preference android:key="@string/key_about" android:summary="@string/summary_about_gnucash"
android:title="@string/title_about"/>
<Preference android:key="@string/key_build_version" android:title="@string/title_build_version"
android:summary="@string/app_version_name"/>
<Preference android:key="@string/key_about_gnucash" android:summary="@string/app_version_name"
android:title="@string/title_about_gnucash"/>
<Preference android:title="@string/title_google_plus_community"
android:summary="@string/summary_google_plus" >
<intent android:action="android.intent.action.VIEW"
android:data="https://plus.google.com/communities/104728406764752407046"/>
</Preference>
<Preference android:title="@string/title_translate_gnucash"
android:summary="@string/summary_translate_gnucash">
<intent android:action="android.intent.action.VIEW"
android:data="https://crowdin.com/project/gnucash-android" />
</Preference>
<Preference android:summary="@string/summary_licence_details"
android:title="@string/title_license"
android:key="@string/key_license">
Expand Down
26 changes: 16 additions & 10 deletions app/src/main/res/xml/fragment_about_preferences.xml
Original file line number Diff line number Diff line change
Expand Up @@ -17,18 +17,24 @@

<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android" >
<PreferenceCategory android:title="@string/title_about_gnucash"/>
<Preference android:key="@string/key_about" android:summary="@string/summary_about_gnucash"
android:title="@string/title_about"/>
<Preference android:key="@string/key_build_version"
android:title="@string/title_build_version"
android:summary="@string/app_version_name"/>
<Preference android:summary="@string/summary_licence_details"
android:title="@string/title_license"
<Preference android:key="@string/key_about_gnucash" android:summary="@string/app_version_name"
android:title="@string/title_about_gnucash"/>
<Preference android:title="@string/title_google_plus_community"
android:summary="@string/summary_google_plus" >
<intent android:action="android.intent.action.VIEW"
android:data="https://plus.google.com/communities/104728406764752407046"/>
</Preference>
<Preference android:title="@string/title_translate_gnucash"
android:summary="@string/summary_translate_gnucash">
<intent android:action="android.intent.action.VIEW"
android:data="https://crowdin.com/project/gnucash-android" />
</Preference>
<Preference android:summary="@string/summary_licence_details"
android:title="@string/title_license"
android:key="@string/key_license">
<intent android:action="android.intent.action.VIEW"
android:data="http://www.apache.org/licenses/LICENSE-2.0.html" />
</Preference>

android:data="http://www.apache.org/licenses/LICENSE-2.0.html" />
</Preference>
<CheckBoxPreference android:title="@string/title_enable_crashlytics"
android:summary="@string/msg_enable_crashlytics"
android:key="@string/key_enable_crashlytics" />
Expand Down

0 comments on commit dbed8af

Please sign in to comment.