mirror of
https://codeberg.org/Freeyourgadget/Gadgetbridge
synced 2024-09-27 16:56:57 +02:00
Make sure strings can be translated
This commit is contained in:
parent
ec32b17813
commit
ee5d1f473f
@ -290,7 +290,7 @@ public class MainActivity extends AppCompatActivity implements NavigationView.On
|
||||
try {
|
||||
cl.getMaterialLogDialog().show();
|
||||
} catch (Exception ignored) {
|
||||
GB.toast(this, "Error showing Changelog", Toast.LENGTH_LONG, GB.ERROR);
|
||||
GB.toast(this, getString(R.string.error_showing_changelog), Toast.LENGTH_LONG, GB.ERROR);
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -355,7 +355,7 @@ public class MainActivity extends AppCompatActivity implements NavigationView.On
|
||||
cl.getMaterialFullLogDialog().show();
|
||||
}
|
||||
} catch (Exception ignored) {
|
||||
GB.toast(getBaseContext(), "Error showing Changelog", Toast.LENGTH_LONG, GB.ERROR);
|
||||
GB.toast(getBaseContext(), getString(R.string.error_showing_changelog), Toast.LENGTH_LONG, GB.ERROR);
|
||||
}
|
||||
return false;
|
||||
case R.id.about:
|
||||
|
@ -106,7 +106,7 @@ public class DashboardTodayWidget extends AbstractDashboardWidget {
|
||||
TextView legend = todayView.findViewById(R.id.dashboard_piechart_legend);
|
||||
SpannableString l_not_worn = new SpannableString("■ " + getString(R.string.abstract_chart_fragment_kind_not_worn));
|
||||
l_not_worn.setSpan(new ForegroundColorSpan(color_not_worn), 0, 1, Spannable.SPAN_EXCLUSIVE_EXCLUSIVE);
|
||||
SpannableString l_worn = new SpannableString("■ " + "Worn");
|
||||
SpannableString l_worn = new SpannableString("■ " + getString(R.string.activity_type_worn));
|
||||
l_worn.setSpan(new ForegroundColorSpan(color_worn), 0, 1, Spannable.SPAN_EXCLUSIVE_EXCLUSIVE);
|
||||
SpannableString l_activity = new SpannableString("■ " + getString(R.string.activity_type_activity));
|
||||
l_activity.setSpan(new ForegroundColorSpan(color_activity), 0, 1, Spannable.SPAN_EXCLUSIVE_EXCLUSIVE);
|
||||
|
@ -2,11 +2,11 @@
|
||||
<menu xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
|
||||
<item
|
||||
android:title="Dashboard"
|
||||
android:title="@string/bottom_nav_dashboard"
|
||||
android:id="@+id/bottom_nav_dashboard"
|
||||
android:icon="@drawable/ic_dashboard"/>
|
||||
<item
|
||||
android:title="Devices"
|
||||
android:title="@string/bottom_nav_devices"
|
||||
android:id="@+id/bottom_nav_devices"
|
||||
android:icon="@drawable/ic_devices_other"/>
|
||||
|
||||
|
@ -2725,7 +2725,6 @@
|
||||
<string name="warning_missing_notification_permission">Could not post ongoing notification due to missing permission</string>
|
||||
<string name="pref_test_features_title">Features</string>
|
||||
<string name="pref_test_features_summary">Enabled features for this test device</string>
|
||||
<string name="dashboard_settings">Dashboard settings</string>
|
||||
<string name="device_state_waiting_scan">Waiting for device scan</string>
|
||||
<string name="auto_reconnect_ble_scan_title">Reconnect by BLE scan</string>
|
||||
<string name="auto_reconnect_ble_scan_summary">Wait for device scan instead of blind connection attempts</string>
|
||||
@ -2749,4 +2748,22 @@
|
||||
<string name="devicesetting_scannable_debounce_summary">After being scanned, the device will stick as scanned and ignored for the specified amount of time</string>
|
||||
<string name="devicesetting_scannable_minimum_unseen_summary">After being scanned, the device has to be unseen for this amount of time before being registered again</string>
|
||||
<string name="devicesetting_scannable_rssi_summary">The minimum RSSI threshold for detection</string>
|
||||
<string name="error_showing_changelog">Error showing Changelog</string>
|
||||
<string name="activity_type_worn">Worn</string>
|
||||
<string name="dashboard_settings">Dashboard settings</string>
|
||||
<string name="bottom_nav_dashboard">Dashboard</string>
|
||||
<string name="bottom_nav_devices">Devices</string>
|
||||
<string name="pref_dashboard_first_title">Show Dashboard first</string>
|
||||
<string name="pref_dashboard_first_summary">Show the Dashboard when Gadgetbridge starts, instead of the Devices screen</string>
|
||||
<string name="pref_dashboard_cards_title">Show widgets on cards</string>
|
||||
<string name="pref_dashboard_cards_summary">Draw cards around the widgets on the Dashboard</string>
|
||||
<string name="pref_dashboard_widget_settings">Widget settings</string>
|
||||
<string name="pref_dashboard_widget_today_title">Activity chart</string>
|
||||
<string name="pref_dashboard_widget_today_24h">24h mode</string>
|
||||
<string name="pref_dashboard_widget_double_size">Double size</string>
|
||||
<string name="pref_dashboard_widget_show_legend">Show legend</string>
|
||||
<string name="pref_dashboard_widget_goals_chart_title">Goals chart</string>
|
||||
<string name="pref_dashboard_devices_to_include">Devices to include</string>
|
||||
<string name="pref_dashboard_all_devices">All devices</string>
|
||||
<string name="pref_dashboard_select_devices">Select devices...</string>
|
||||
</resources>
|
||||
|
@ -60,7 +60,7 @@
|
||||
|
||||
<PreferenceScreen
|
||||
android:key="pref_category_dashboard"
|
||||
android:title="Dashboard"
|
||||
android:title="@string/bottom_nav_dashboard"
|
||||
app:iconSpaceReserved="false">
|
||||
|
||||
<PreferenceCategory
|
||||
@ -71,25 +71,25 @@
|
||||
android:defaultValue="true"
|
||||
android:key="dashboard_as_default_view"
|
||||
android:layout="@layout/preference_checkbox"
|
||||
android:title="Show Dashboard first"
|
||||
android:summary="Show the Dashboard when Gadgetbridge starts, instead of the Devices screen"
|
||||
android:title="@string/pref_dashboard_first_title"
|
||||
android:summary="@string/pref_dashboard_first_summary"
|
||||
app:iconSpaceReserved="false" />
|
||||
<SwitchPreferenceCompat
|
||||
android:defaultValue="true"
|
||||
android:key="dashboard_cards_enabled"
|
||||
android:layout="@layout/preference_checkbox"
|
||||
android:title="Show widgets on cards"
|
||||
android:summary="Draw cards around the widgets on the Dashboard"
|
||||
android:title="@string/pref_dashboard_cards_title"
|
||||
android:summary="@string/pref_dashboard_cards_summary"
|
||||
app:iconSpaceReserved="false" />
|
||||
</PreferenceCategory>
|
||||
|
||||
<PreferenceCategory
|
||||
android:key="pref_key_dashboard_widgets"
|
||||
android:title="Widget settings"
|
||||
android:title="@string/pref_dashboard_widget_settings"
|
||||
app:iconSpaceReserved="false">
|
||||
<PreferenceScreen
|
||||
android:key="pref_key_dashboard_today"
|
||||
android:title="Activity chart"
|
||||
android:title="@string/pref_dashboard_widget_today_title"
|
||||
app:iconSpaceReserved="false">
|
||||
<SwitchPreferenceCompat
|
||||
android:defaultValue="true"
|
||||
@ -101,24 +101,24 @@
|
||||
android:defaultValue="false"
|
||||
android:key="dashboard_widget_today_24h"
|
||||
android:layout="@layout/preference_checkbox"
|
||||
android:title="24h mode"
|
||||
android:title="@string/pref_dashboard_widget_today_24h"
|
||||
app:iconSpaceReserved="false" />
|
||||
<SwitchPreferenceCompat
|
||||
android:defaultValue="true"
|
||||
android:key="dashboard_widget_today_2columns"
|
||||
android:layout="@layout/preference_checkbox"
|
||||
android:title="Double size"
|
||||
android:title="@string/pref_dashboard_widget_double_size"
|
||||
app:iconSpaceReserved="false" />
|
||||
<SwitchPreferenceCompat
|
||||
android:defaultValue="true"
|
||||
android:key="dashboard_widget_today_legend"
|
||||
android:layout="@layout/preference_checkbox"
|
||||
android:title="Show legend"
|
||||
android:title="@string/pref_dashboard_widget_show_legend"
|
||||
app:iconSpaceReserved="false" />
|
||||
</PreferenceScreen>
|
||||
<PreferenceScreen
|
||||
android:key="pref_key_dashboard_goals"
|
||||
android:title="Goals chart"
|
||||
android:title="@string/pref_dashboard_widget_goals_chart_title"
|
||||
app:iconSpaceReserved="false">
|
||||
<SwitchPreferenceCompat
|
||||
android:defaultValue="true"
|
||||
@ -130,13 +130,13 @@
|
||||
android:defaultValue="true"
|
||||
android:key="dashboard_widget_goals_2columns"
|
||||
android:layout="@layout/preference_checkbox"
|
||||
android:title="Double size"
|
||||
android:title="@string/pref_dashboard_widget_double_size"
|
||||
app:iconSpaceReserved="false" />
|
||||
<SwitchPreferenceCompat
|
||||
android:defaultValue="true"
|
||||
android:key="dashboard_widget_goals_legend"
|
||||
android:layout="@layout/preference_checkbox"
|
||||
android:title="Show legend"
|
||||
android:title="@string/pref_dashboard_widget_show_legend"
|
||||
app:iconSpaceReserved="false" />
|
||||
</PreferenceScreen>
|
||||
<SwitchPreferenceCompat
|
||||
@ -167,13 +167,13 @@
|
||||
|
||||
<PreferenceCategory
|
||||
android:key="pref_key_dashboard_devices"
|
||||
android:title="Devices to include"
|
||||
android:title="@string/pref_dashboard_devices_to_include"
|
||||
app:iconSpaceReserved="false">
|
||||
<SwitchPreferenceCompat
|
||||
android:defaultValue="true"
|
||||
android:key="dashboard_devices_all"
|
||||
android:layout="@layout/preference_checkbox"
|
||||
android:title="All devices"
|
||||
android:title="@string/pref_dashboard_all_devices"
|
||||
android:disableDependentsState="true"
|
||||
app:iconSpaceReserved="false" />
|
||||
<MultiSelectListPreference
|
||||
@ -182,7 +182,7 @@
|
||||
android:entries="@array/empty_array"
|
||||
android:entryValues="@array/empty_array"
|
||||
android:key="dashboard_devices_multiselect"
|
||||
android:title="Select devices..."
|
||||
android:title="@string/pref_dashboard_select_devices"
|
||||
app:iconSpaceReserved="false" />
|
||||
</PreferenceCategory>
|
||||
</PreferenceScreen>
|
||||
|
Loading…
Reference in New Issue
Block a user