mirror of
https://github.com/gsantner/dandelion
synced 2024-11-22 04:12:08 +01:00
Merge branch 'master' of github.com:Diaspora-for-Android/diaspora-android
This commit is contained in:
commit
f2fd4e4c4d
10 changed files with 226 additions and 190 deletions
|
@ -39,7 +39,7 @@
|
|||
android:name=".activity.SettingsActivity"
|
||||
android:launchMode="singleInstance"
|
||||
android:theme="@style/AppTheme"
|
||||
android:label="@string/pref_title_personal_settings">
|
||||
android:label="@string/pref_title__personal_settings">
|
||||
</activity>
|
||||
|
||||
<activity
|
||||
|
|
|
@ -538,10 +538,10 @@ public class MainActivity extends AppCompatActivity
|
|||
@Override
|
||||
public void onReceive(Context context, Intent intent) {
|
||||
String url = intent.getStringExtra(EXTRA_URL);
|
||||
Log.d(App.TAG, "BroadcastReceiver: Received setTitleIntent: "+url);
|
||||
// Log.d(App.TAG, "BroadcastReceiver: Received setTitleIntent: "+url);
|
||||
if (url != null && url.startsWith("https://" + podDomain)) {
|
||||
String subUrl = url.substring(("https://" + podDomain).length());
|
||||
Log.d(App.TAG, "LocalBroadcastReceiver: SubUrl: "+subUrl);
|
||||
//Log.d(App.TAG, "LocalBroadcastReceiver: SubUrl: "+subUrl); // Spams!
|
||||
if (subUrl.startsWith("/stream")) {
|
||||
setTitle(R.string.title_stream);
|
||||
} else if (subUrl.startsWith("/posts/")) {
|
||||
|
|
|
@ -31,7 +31,6 @@ import android.preference.PreferenceScreen;
|
|||
|
||||
import com.github.dfa.diaspora_android.App;
|
||||
import com.github.dfa.diaspora_android.R;
|
||||
import com.github.dfa.diaspora_android.data.AppSettings;
|
||||
|
||||
/**
|
||||
* @author vanitas
|
||||
|
@ -48,12 +47,14 @@ public class SettingsActivity extends PreferenceActivity implements SharedPrefer
|
|||
sharedPreferences = getPreferenceScreen().getSharedPreferences();
|
||||
sharedPreferences.registerOnSharedPreferenceChangeListener(this);
|
||||
setPreferenceSummaries();
|
||||
sharedPreferences.edit().putBoolean(AppSettings.PREF.PROXY_WAS_ENABLED,
|
||||
sharedPreferences.getBoolean(AppSettings.PREF.PROXY_ENABLED, false)).apply();
|
||||
sharedPreferences.edit().putBoolean(getString(R.string.pref_key__proxy_was_enabled),
|
||||
sharedPreferences.getBoolean(getString(R.string.pref_key__proxy_enabled), false)).apply();
|
||||
}
|
||||
|
||||
private void setPreferenceSummaries() {
|
||||
String[] editTextKeys = new String[]{AppSettings.PREF.PROXY_HOST, AppSettings.PREF.PROXY_PORT};
|
||||
String[] editTextKeys = new String[]{
|
||||
getString(R.string.pref_key__proxy_host), getString(R.string.pref_key__proxy_port)
|
||||
};
|
||||
for (String key : editTextKeys) {
|
||||
EditTextPreference p = (EditTextPreference) findPreference(key);
|
||||
p.setSummary(p.getText());
|
||||
|
@ -66,7 +67,9 @@ public class SettingsActivity extends PreferenceActivity implements SharedPrefer
|
|||
}
|
||||
|
||||
private void updatePreference(Preference preference, String key) {
|
||||
if (preference == null) return;
|
||||
if (preference == null) {
|
||||
return;
|
||||
}
|
||||
if (preference instanceof EditTextPreference) {
|
||||
EditTextPreference textPref = (EditTextPreference) preference;
|
||||
textPref.setSummary(textPref.getText());
|
||||
|
@ -83,23 +86,27 @@ public class SettingsActivity extends PreferenceActivity implements SharedPrefer
|
|||
public boolean onPreferenceTreeClick(PreferenceScreen screen, Preference preference) {
|
||||
Intent intent = new Intent(this, MainActivity.class);
|
||||
String podDomain = ((App) getApplication()).getSettings().getPodDomain();
|
||||
switch(preference.getKey()) {
|
||||
case "pref_key_personal_settings":
|
||||
|
||||
switch (preference.getTitleRes()) {
|
||||
case R.string.pref_title__personal_settings: {
|
||||
intent.setAction(MainActivity.ACTION_OPEN_URL);
|
||||
intent.putExtra(MainActivity.URL_MESSAGE, "https://" + podDomain + "/user/edit");
|
||||
break;
|
||||
case "pref_key_manage_tags":
|
||||
}
|
||||
case R.string.pref_title__manage_tags: {
|
||||
intent.setAction(MainActivity.ACTION_OPEN_URL);
|
||||
intent.putExtra(MainActivity.URL_MESSAGE, "https://" + podDomain + "/tag_followings/manage");
|
||||
break;
|
||||
case "pref_key_manage_contacts":
|
||||
}
|
||||
case R.string.pref_title__manage_contacts: {
|
||||
intent.setAction(MainActivity.ACTION_OPEN_URL);
|
||||
intent.putExtra(MainActivity.URL_MESSAGE, "https://" + podDomain + "/contacts");
|
||||
break;
|
||||
case "pref_key_change_account":
|
||||
}
|
||||
case R.string.pref_title__change_account: {
|
||||
new AlertDialog.Builder(SettingsActivity.this)
|
||||
.setTitle(getString(R.string.confirmation))
|
||||
.setMessage(getString(R.string.pref_warning_change_account))
|
||||
.setMessage(getString(R.string.pref_warning__change_account))
|
||||
.setNegativeButton(android.R.string.no, null)
|
||||
.setPositiveButton(android.R.string.yes,
|
||||
new DialogInterface.OnClickListener() {
|
||||
|
@ -112,13 +119,16 @@ public class SettingsActivity extends PreferenceActivity implements SharedPrefer
|
|||
})
|
||||
.show();
|
||||
return true;
|
||||
case "pref_key_clear_cache":
|
||||
}
|
||||
case R.string.pref_title__clear_cache: {
|
||||
intent.setAction(MainActivity.ACTION_CLEAR_CACHE);
|
||||
break;
|
||||
default:
|
||||
}
|
||||
default: {
|
||||
intent = null;
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (intent != null) {
|
||||
startActivity(intent);
|
||||
finish();
|
||||
|
|
|
@ -22,6 +22,8 @@ import android.annotation.SuppressLint;
|
|||
import android.content.Context;
|
||||
import android.content.SharedPreferences;
|
||||
|
||||
import com.github.dfa.diaspora_android.R;
|
||||
|
||||
/**
|
||||
* Created by gsantner (https://gsantner.github.io/) on 20.03.16. Part of Diaspora for Android.
|
||||
*/
|
||||
|
@ -48,53 +50,41 @@ public class AppSettings {
|
|||
prefApp.edit().clear().apply();
|
||||
}
|
||||
|
||||
private void setString(SharedPreferences pref, String key, String value) {
|
||||
pref.edit().putString(key, value).apply();
|
||||
private void setString(SharedPreferences pref, int keyRessourceId, String value) {
|
||||
pref.edit().putString(context.getString(keyRessourceId), value).apply();
|
||||
}
|
||||
|
||||
private void setInt(SharedPreferences pref, String key, int value) {
|
||||
pref.edit().putInt(key, value).apply();
|
||||
private void setInt(SharedPreferences pref, int keyRessourceId, int value) {
|
||||
pref.edit().putInt(context.getString(keyRessourceId), value).apply();
|
||||
}
|
||||
|
||||
private void setBool(SharedPreferences pref, String key, boolean value) {
|
||||
pref.edit().putBoolean(key, value).apply();
|
||||
private void setBool(SharedPreferences pref, int keyRessourceId, boolean value) {
|
||||
pref.edit().putBoolean(context.getString(keyRessourceId), value).apply();
|
||||
}
|
||||
|
||||
private void setStringArray(SharedPreferences pref, String key, Object[] values) {
|
||||
private void setStringArray(SharedPreferences pref, int keyRessourceId, Object[] values) {
|
||||
StringBuffer sb = new StringBuffer();
|
||||
for (Object value : values) {
|
||||
sb.append("%%%");
|
||||
sb.append(value.toString());
|
||||
}
|
||||
setString(pref, key, sb.toString().replaceFirst("%%%", ""));
|
||||
setString(pref, keyRessourceId, sb.toString().replaceFirst("%%%", ""));
|
||||
}
|
||||
|
||||
private String[] getStringArray(SharedPreferences pref, String key) {
|
||||
String value = pref.getString(key, "%%%");
|
||||
private String[] getStringArray(SharedPreferences pref, int keyRessourceId) {
|
||||
String value = pref.getString(context.getString(keyRessourceId), "%%%");
|
||||
if (value.equals("%%%")) {
|
||||
return new String[0];
|
||||
}
|
||||
return value.split("%%%");
|
||||
}
|
||||
|
||||
/*
|
||||
// Preferences
|
||||
*/
|
||||
public static class PREF {
|
||||
public static final String PREVIOUS_PODLIST = "previousPodlist";
|
||||
public static final String IS_LOAD_IMAGES = "pref_key_load_images";
|
||||
public static final String MINIMUM_FONT_SIZE = "pref_key_font_size";
|
||||
public static final String PODUSERPROFILE_AVATAR_URL = "podUserProfile_avatar";
|
||||
public static final String PODUSERPROFILE_NAME = "podUserProfile_name";
|
||||
public static final String PODUSERPROFILE_ID = "podUserProfile_guid";
|
||||
public static final String PODDOMAIN = "podDomain";
|
||||
public static final String PODUSERPROFILE_ASPECTS = "podUserProfile_aspects";
|
||||
public static final String PODUSERPROFILE_FOLLOWED_TAGS = "podUserProfile_followedTags";
|
||||
public static final String PROXY_ENABLED = "pref_key_proxy_enabled";
|
||||
public static final String PROXY_WAS_ENABLED = "wasProxyEnabled";
|
||||
public static final String PROXY_HOST = "pref_key_proxy_host";
|
||||
public static final String PROXY_PORT = "pref_key_proxy_port";
|
||||
public static final String UI_INTELLIHIDE_TOOLBARS ="pref_key_intellihide_toolbars";
|
||||
private String getString(SharedPreferences pref, int ressourceId, String defaultValue) {
|
||||
return pref.getString(context.getString(ressourceId), defaultValue);
|
||||
}
|
||||
|
||||
private boolean getBoolean(SharedPreferences pref, int ressourceId, boolean defaultValue) {
|
||||
return pref.getBoolean(context.getString(ressourceId), defaultValue);
|
||||
}
|
||||
|
||||
|
||||
|
@ -102,19 +92,19 @@ public class AppSettings {
|
|||
// Setters & Getters
|
||||
*/
|
||||
public String getProfileId() {
|
||||
return prefPod.getString(PREF.PODUSERPROFILE_ID, "");
|
||||
return getString(prefPod, R.string.pref_key__podprofile_id, "");
|
||||
}
|
||||
|
||||
public void setProfileId(String profileId) {
|
||||
setString(prefPod, PREF.PODUSERPROFILE_ID, profileId);
|
||||
setString(prefPod, R.string.pref_key__podprofile_id, profileId);
|
||||
}
|
||||
|
||||
public boolean isLoadImages() {
|
||||
return prefApp.getBoolean(PREF.IS_LOAD_IMAGES, true);
|
||||
return getBoolean(prefApp, R.string.pref_key__load_images, true);
|
||||
}
|
||||
|
||||
public int getMinimumFontSize() {
|
||||
switch (prefApp.getString(PREF.MINIMUM_FONT_SIZE, "")) {
|
||||
switch (getString(prefApp, R.string.pref_key__font_size, "")) {
|
||||
case "huge":
|
||||
return 20;
|
||||
case "large":
|
||||
|
@ -122,53 +112,53 @@ public class AppSettings {
|
|||
case "normal":
|
||||
return 8;
|
||||
default:
|
||||
prefApp.edit().putString(PREF.MINIMUM_FONT_SIZE, "normal").apply();
|
||||
setString(prefApp, R.string.pref_key__font_size, "normal");
|
||||
return 8;
|
||||
}
|
||||
}
|
||||
|
||||
public String getAvatarUrl() {
|
||||
return prefPod.getString(PREF.PODUSERPROFILE_AVATAR_URL, "");
|
||||
return getString(prefPod, R.string.pref_key__podprofile_avatar_url, "");
|
||||
}
|
||||
|
||||
public void setAvatarUrl(String avatarUrl) {
|
||||
setString(prefPod, PREF.PODUSERPROFILE_AVATAR_URL, avatarUrl);
|
||||
setString(prefPod, R.string.pref_key__podprofile_avatar_url, avatarUrl);
|
||||
}
|
||||
|
||||
public String getName() {
|
||||
return prefPod.getString(PREF.PODUSERPROFILE_NAME, "");
|
||||
return getString(prefPod, R.string.pref_key__podprofile_name, "");
|
||||
}
|
||||
|
||||
public void setName(String name) {
|
||||
setString(prefPod, PREF.PODUSERPROFILE_NAME, name);
|
||||
setString(prefPod, R.string.pref_key__podprofile_name, name);
|
||||
}
|
||||
|
||||
public String getPodDomain() {
|
||||
return prefPod.getString(PREF.PODDOMAIN, "");
|
||||
return getString(prefPod, R.string.pref_key__poddomain, "");
|
||||
}
|
||||
|
||||
public void setPodDomain(String podDomain) {
|
||||
setString(prefPod, PREF.PODDOMAIN, podDomain);
|
||||
setString(prefPod, R.string.pref_key__poddomain, podDomain);
|
||||
}
|
||||
|
||||
public boolean hasPodDomain() {
|
||||
return !prefPod.getString(PREF.PODDOMAIN, "").equals("");
|
||||
return !getString(prefPod, R.string.pref_key__poddomain, "").equals("");
|
||||
}
|
||||
|
||||
public String[] getPreviousPodlist() {
|
||||
return getStringArray(prefApp, PREF.PREVIOUS_PODLIST);
|
||||
return getStringArray(prefApp, R.string.pref_key__previous_podlist);
|
||||
}
|
||||
|
||||
public void setPreviousPodlist(String[] pods) {
|
||||
setStringArray(prefApp, PREF.PREVIOUS_PODLIST, pods);
|
||||
setStringArray(prefApp, R.string.pref_key__previous_podlist, pods);
|
||||
}
|
||||
|
||||
public void setPodAspects(PodAspect[] aspects) {
|
||||
setStringArray(prefPod, PREF.PODUSERPROFILE_ASPECTS, aspects);
|
||||
setStringArray(prefPod, R.string.pref_key__podprofile_aspects, aspects);
|
||||
}
|
||||
|
||||
public PodAspect[] getPodAspects() {
|
||||
String[] s= getStringArray(prefPod, PREF.PODUSERPROFILE_ASPECTS);
|
||||
String[] s = getStringArray(prefPod, R.string.pref_key__podprofile_aspects);
|
||||
PodAspect[] aspects = new PodAspect[s.length];
|
||||
for (int i = 0; i < aspects.length; i++) {
|
||||
aspects[i] = new PodAspect(s[i]);
|
||||
|
@ -177,63 +167,67 @@ public class AppSettings {
|
|||
}
|
||||
|
||||
public String[] getFollowedTags() {
|
||||
return getStringArray(prefPod, PREF.PODUSERPROFILE_FOLLOWED_TAGS);
|
||||
return getStringArray(prefPod, R.string.pref_key__podprofile_followed_tags);
|
||||
}
|
||||
|
||||
public void setFollowedTags(String[] tags) {
|
||||
setStringArray(prefPod, PREF.PODUSERPROFILE_FOLLOWED_TAGS, tags);
|
||||
setStringArray(prefPod, R.string.pref_key__podprofile_followed_tags, tags);
|
||||
}
|
||||
|
||||
@SuppressLint("CommitPrefEdits")
|
||||
public void setProxyEnabled(boolean enabled) {
|
||||
//commit instead of apply because the app is likely to be killed before apply is called.
|
||||
prefApp.edit().putBoolean(PREF.PROXY_ENABLED, enabled).commit();
|
||||
prefApp.edit().putBoolean(context.getString(R.string.pref_key__proxy_enabled), enabled).commit();
|
||||
}
|
||||
|
||||
/**
|
||||
* Default return value: false
|
||||
*
|
||||
* @return whether proxy is enabled or not
|
||||
*/
|
||||
public boolean isProxyEnabled() {
|
||||
return prefApp.getBoolean(PREF.PROXY_ENABLED, false);
|
||||
return getBoolean(prefApp, R.string.pref_key__proxy_enabled, false);
|
||||
}
|
||||
|
||||
public boolean wasProxyEnabled() {
|
||||
return prefApp.getBoolean(PREF.PROXY_WAS_ENABLED, false);
|
||||
return getBoolean(prefApp, R.string.pref_key__proxy_was_enabled, false);
|
||||
}
|
||||
|
||||
/**
|
||||
* Needed in order to determine, whether the proxy has just been disabled (trigger app restart)
|
||||
* or if proxy was disabled before (do not restart app)
|
||||
*
|
||||
* @param b new value
|
||||
*/
|
||||
@SuppressLint("CommitPrefEdits")
|
||||
public void setProxyWasEnabled(boolean b) {
|
||||
prefApp.edit().putBoolean(PREF.PROXY_WAS_ENABLED, b).commit();
|
||||
prefApp.edit().putBoolean(context.getString(R.string.pref_key__proxy_was_enabled), b).commit();
|
||||
}
|
||||
|
||||
/**
|
||||
* Default value: ""
|
||||
*
|
||||
* @return proxy host
|
||||
*/
|
||||
public String getProxyHost() {
|
||||
return prefApp.getString(PREF.PROXY_HOST, "");
|
||||
return getString(prefApp, R.string.pref_key__proxy_host, "");
|
||||
}
|
||||
|
||||
/**
|
||||
* Default value: 0
|
||||
*
|
||||
* @return proxy port
|
||||
*/
|
||||
public int getProxyPort() {
|
||||
try {
|
||||
return Integer.parseInt(prefApp.getString(PREF.PROXY_PORT, "0"));
|
||||
return Integer.parseInt(getString(prefApp, R.string.pref_key__proxy_port, "0"));
|
||||
} catch (Exception e) {
|
||||
prefApp.edit().putString(PREF.PROXY_PORT, "0").apply();
|
||||
setString(prefApp, R.string.pref_key__proxy_port, "0");
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
public boolean isIntellihideToolbars() {
|
||||
return prefApp.getBoolean(PREF.UI_INTELLIHIDE_TOOLBARS, true);
|
||||
return getBoolean(prefApp, R.string.pref_key__intellihide_toolbars, true);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,41 +1,47 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
<!-- Categories -->
|
||||
<string name="pref_category_visuals">Erscheinungsbild</string>
|
||||
<string name="pref_category_network">Netzwerk</string>
|
||||
<string name="pref_category_pod_settings">Pod Einstellungen</string>
|
||||
<string name="pref_cat__visuals">Erscheinungsbild</string>
|
||||
<string name="pref_cat__network">Netzwerk</string>
|
||||
<string name="pref_cat__pod_settings">Pod Einstellungen</string>
|
||||
|
||||
<!-- Visuals -->
|
||||
<!-- Font size -->
|
||||
<string name="pref_title_font_size">Schriftgröße</string>
|
||||
<array name="pref_entries_font_size">
|
||||
<string name="pref_title__font_size">Schriftgröße</string>
|
||||
<array name="pref_entries__font_size">
|
||||
<item>Normal</item>
|
||||
<item>Groß</item>
|
||||
<item>Riesig</item>
|
||||
</array>
|
||||
|
||||
<!-- Load images -->
|
||||
<string name="pref_title_load_images">Lade Bilder</string>
|
||||
<string name="pref_desc_load_images">Deaktiviere das Laden von Bildern, um den Datenverbrauch zu verringern</string>
|
||||
<string name="pref_title__load_images">Lade Bilder</string>
|
||||
<string name="pref_desc__load_images">Deaktiviere das Laden von Bildern, um den Datenverbrauch zu verringern</string>
|
||||
|
||||
<!-- Proxy -->
|
||||
<string name="pref_title_proxy_enabled">Aktiviere Proxy</string>
|
||||
<string name="pref_desc_proxy_enabled">Nutze einen Proxyserver um Firewalls zu umgehen</string>
|
||||
<string name="pref_title_proxy_host">Host</string>
|
||||
<string name="pref_title_proxy_port">Port</string>
|
||||
<string name="pref_title__proxy_enabled">Aktiviere Proxy</string>
|
||||
<string name="pref_desc__proxy_enabled">Nutze einen Proxyserver um Firewalls zu umgehen</string>
|
||||
<string name="pref_title__proxy_host">Host</string>
|
||||
<string name="pref_title__proxy_port">Port</string>
|
||||
|
||||
<!-- Diaspora Settings -->
|
||||
<string name="pref_title_personal_settings">Persönliche Einstellungen</string>
|
||||
<string name="pref_desc_personal_settings">Öffne die Einstellungen deines Diaspora Accounts</string>
|
||||
<string name="pref_title__personal_settings">Persönliche Einstellungen</string>
|
||||
<string name="pref_desc__personal_settings">Öffne die Einstellungen deines Diaspora Accounts</string>
|
||||
|
||||
<string name="pref_title_manage_contacts">Kontakte</string>
|
||||
<string name="pref_desc_manage_contacts">Bearbeite deine Kontaktliste</string>
|
||||
<string name="pref_title__manage_contacts">Kontakte</string>
|
||||
<string name="pref_desc__manage_contacts">Bearbeite deine Kontaktliste</string>
|
||||
|
||||
<string name="pref_title_manage_tags">Tags verwalten</string>
|
||||
<string name="pref_desc_manage_tags">Verwalte die Liste der Hashtags, denen du folgst</string>
|
||||
<string name="pref_title__manage_tags">Tags verwalten</string>
|
||||
<string name="pref_desc__manage_tags">Verwalte die Liste der Hashtags, denen du folgst</string>
|
||||
|
||||
<string name="pref_title_change_account">Account wechseln</string>
|
||||
<string name="pref_desc_change_account">Lösche lokale Sitzungsdaten und wechsle zu einem anderen Pod/Account</string>
|
||||
<string name="pref_warning_change_account">Das wird alle Cookies und Session-Daten löschen. Willst du wirklich den Account wechseln?</string>
|
||||
<string name="pref_title__change_account">Account wechseln</string>
|
||||
<string name="pref_desc__change_account">Lösche lokale Sitzungsdaten und wechsle zu einem anderen Pod/Account</string>
|
||||
<string name="pref_warning__change_account">Das wird alle Cookies und Session-Daten löschen. Willst du wirklich den Account wechseln?</string>
|
||||
|
||||
|
||||
<string name="pref_desc__clear_cache">WebView Cache leeren</string>
|
||||
<string name="pref_title__clear_cache">Cache leeren</string>
|
||||
<string name="pref_title__intellihide_toolbars">Toolbars intelligent verstecken</string>
|
||||
<string name="pref_desc__intellihide_toolbars">Obere und untere Toolbar verstecken während des Scrollens von Inhalt</string>
|
||||
|
||||
</resources>
|
||||
|
|
|
@ -158,9 +158,5 @@ along with this program. If not, see http://www.gnu.org/licenses.<br> <br
|
|||
|
||||
<string name="toggle_desktop_page">Mobil-/Desktopansicht umschalten</string>
|
||||
<string name="all_tags">Alle Tags</string>
|
||||
<string name="pref_desc_clear_cache">WebView Cache leeren</string>
|
||||
<string name="pref_title_clear_cache">Cache leeren</string>
|
||||
<string name="pref_title_intellihide_toolbars">Toolbars intelligent verstecken</string>
|
||||
<string name="pref_desc_intellihide_toolbars">Obere und untere Toolbar verstecken während des Scrollens von Inhalt</string>
|
||||
|
||||
</resources>
|
||||
|
|
|
@ -1,43 +1,43 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
<!-- Categories -->
|
||||
<string name="pref_category_visuals">Apparance</string>
|
||||
<string name="pref_category_network">Paramètres du réseau</string>
|
||||
<string name="pref_category_pod_settings">Paramètres du pod</string>
|
||||
<string name="pref_cat__visuals">Apparance</string>
|
||||
<string name="pref_cat__network">Paramètres du réseau</string>
|
||||
<string name="pref_cat__pod_settings">Paramètres du pod</string>
|
||||
|
||||
<!-- Visuals -->
|
||||
<!-- Font size -->
|
||||
<string name="pref_title_font_size">Taille de la police</string>
|
||||
<array name="pref_entries_font_size">
|
||||
<string name="pref_title__font_size">Taille de la police</string>
|
||||
<array name="pref_entries__font_size">
|
||||
<item>Normal</item>
|
||||
<item>Grand</item>
|
||||
<item>Énorme</item>
|
||||
</array>
|
||||
|
||||
<!-- Load images -->
|
||||
<string name="pref_title_load_images">Charger les images</string>
|
||||
<string name="pref_desc_load_images">Disable image loading to safe mobile data</string>
|
||||
<string name="pref_title__load_images">Charger les images</string>
|
||||
<string name="pref_desc__load_images">Disable image loading to safe mobile data</string>
|
||||
|
||||
<!-- Proxy -->
|
||||
<string name="pref_title_proxy_enabled">Activer Proxy</string>
|
||||
<string name="pref_desc_proxy_enabled">Proxy Diaspora\'s traffic to circumvent firewalls.\nMay require restart</string>
|
||||
<string name="pref_title__proxy_enabled">Activer Proxy</string>
|
||||
<string name="pref_desc__proxy_enabled">Proxy Diaspora\'s traffic to circumvent firewalls.\nMay require restart</string>
|
||||
|
||||
<string name="pref_title_proxy_host">Hôte</string>
|
||||
<string name="pref_title__proxy_host">Hôte</string>
|
||||
|
||||
<string name="pref_title_proxy_port">Port</string>
|
||||
<string name="pref_title__proxy_port">Port</string>
|
||||
|
||||
<!-- Diaspora Settings -->
|
||||
<string name="pref_title_personal_settings">Paramètres personnels</string>
|
||||
<string name="pref_desc_personal_settings">Open your diaspora account settings</string>
|
||||
<string name="pref_title__personal_settings">Paramètres personnels</string>
|
||||
<string name="pref_desc__personal_settings">Open your diaspora account settings</string>
|
||||
|
||||
<string name="pref_title_manage_contacts">Contacts</string>
|
||||
<string name="pref_desc_manage_contacts">Gérer votre liste des contacts</string>
|
||||
<string name="pref_title__manage_contacts">Contacts</string>
|
||||
<string name="pref_desc__manage_contacts">Gérer votre liste des contacts</string>
|
||||
|
||||
<string name="pref_title_manage_tags">Gérer les Hashtags</string>
|
||||
<string name="pref_desc_manage_tags">Add and delete the hashtags you are following</string>
|
||||
<string name="pref_title__manage_tags">Gérer les Hashtags</string>
|
||||
<string name="pref_desc__manage_tags">Add and delete the hashtags you are following</string>
|
||||
|
||||
<string name="pref_title_change_account">Changer de compte</string>
|
||||
<string name="pref_desc_change_account">Erase local session data and switch to another Diaspora pod/account</string>
|
||||
<string name="pref_warning_change_account">Cette opération va effacer les cookies et données de session. Voulez-vous vraiment changer de compte/pod?</string>
|
||||
<string name="pref_title__change_account">Changer de compte</string>
|
||||
<string name="pref_desc__change_account">Erase local session data and switch to another Diaspora pod/account</string>
|
||||
<string name="pref_warning__change_account">Cette opération va effacer les cookies et données de session. Voulez-vous vraiment changer de compte/pod?</string>
|
||||
|
||||
</resources>
|
|
@ -1,52 +1,84 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
<!-- Categories -->
|
||||
<string name="pref_category_visuals">Appearance</string>
|
||||
<string name="pref_category_network">Network</string>
|
||||
<string name="pref_category_pod_settings">Pod settings</string>
|
||||
<!-- Key Names (Untranslateable) -->
|
||||
<string name="pref_key__poddomain" translatable="false">podDomain</string>
|
||||
<string name="pref_key__previous_podlist" translatable="false">previousPodlist</string>
|
||||
<string name="pref_key__font_size" translatable="false">pref_key_font_size</string>
|
||||
<string name="pref_key__intellihide_toolbars" translatable="false">pref_key_intellihide_toolbars</string>
|
||||
<string name="pref_catkey__pod_settings" translatable="false">pref_key_category_pod_settings</string>
|
||||
<string name="pref_catkey__category_visuals" translatable="false">pref_key_category_visuals</string>
|
||||
<string name="pref_key__personal_settings" translatable="false">pref_key_personal_settings</string>
|
||||
<string name="pref_key__manage_tags" translatable="false">pref_key_manage_tags</string>
|
||||
<string name="pref_key__manage_contacts" translatable="false">pref_key_manage_contacts</string>
|
||||
<string name="pref_key__change_account" translatable="false">pref_key_change_account</string>
|
||||
<string name="pref_catkey__network" translatable="false">pref_key_category_network</string>
|
||||
<string name="pref_key__load_images" translatable="false">pref_key_load_images</string>
|
||||
<string name="pref_key__clear_cache" translatable="false">pref_key_clear_cache</string>
|
||||
|
||||
<string name="pref_key__proxy_enabled" translatable="false">pref_key_proxy_enabled</string>
|
||||
<string name="pref_key__proxy_host" translatable="false">pref_key_proxy_host</string>
|
||||
<string name="pref_key__proxy_port" translatable="false">pref_key_proxy_port</string>
|
||||
<string name="pref_key__proxy_was_enabled" translatable="false">wasProxyEnabled</string>
|
||||
|
||||
|
||||
<string name="pref_key__podprofile_avatar_url" translatable="false">podUserProfile_avatar</string>
|
||||
<string name="pref_key__podprofile_name" translatable="false">podUserProfile_name</string>
|
||||
<string name="pref_key__podprofile_id" translatable="false">podUserProfile_guid</string>
|
||||
<string name="pref_key__podprofile_aspects" translatable="false">podUserProfile_aspects</string>
|
||||
<string name="pref_key__podprofile_followed_tags" translatable="false">podUserProfile_followedTags</string>
|
||||
|
||||
|
||||
<!-- Category Titles -->
|
||||
<string name="pref_cat__visuals">Appearance</string>
|
||||
<string name="pref_cat__network">Network</string>
|
||||
<string name="pref_cat__pod_settings">Pod settings</string>
|
||||
|
||||
<!-- Visuals -->
|
||||
<!-- Font size -->
|
||||
<string name="pref_title_font_size">Font size</string>
|
||||
<array name="pref_entries_font_size">
|
||||
<string name="pref_title__font_size">Font size</string>
|
||||
<array name="pref_entries__font_size">
|
||||
<item>Normal</item>
|
||||
<item>Large</item>
|
||||
<item>Huge</item>
|
||||
</array>
|
||||
<!-- prefix 's' is needed to make this a string array. Otherwise ListPreference would crash -->
|
||||
<array name="pref_entry_values_font_size" translatable="false">
|
||||
<array name="pref_entries_values__font_size" translatable="false">
|
||||
<item>normal</item>
|
||||
<item>large</item>
|
||||
<item>huge</item>
|
||||
</array>
|
||||
|
||||
<!-- Load images -->
|
||||
<string name="pref_title_load_images">Load images</string>
|
||||
<string name="pref_desc_load_images">Disable image loading to safe mobile data</string>
|
||||
<string name="pref_title__load_images">Load images</string>
|
||||
<string name="pref_desc__load_images">Disable image loading to safe mobile data</string>
|
||||
|
||||
<!-- Proxy -->
|
||||
<string name="pref_title_proxy_enabled">Enable Proxy</string>
|
||||
<string name="pref_desc_proxy_enabled">Proxy Diaspora\'s traffic to circumvent firewalls.\nMay require restart</string>
|
||||
<string name="pref_title__proxy_enabled">Enable Proxy</string>
|
||||
<string name="pref_desc__proxy_enabled">Proxy Diaspora\'s traffic to circumvent firewalls.\nMay require restart</string>
|
||||
|
||||
<string name="pref_title_proxy_host">Host</string>
|
||||
<string name="pref_title__proxy_host">Host</string>
|
||||
|
||||
<string name="pref_title_proxy_port">Port</string>
|
||||
<string name="pref_title__proxy_port">Port</string>
|
||||
|
||||
<!-- Diaspora Settings -->
|
||||
<string name="pref_title_personal_settings">Personal settings</string>
|
||||
<string name="pref_desc_personal_settings">Open your diaspora account settings</string>
|
||||
<string name="pref_title__personal_settings">Personal settings</string>
|
||||
<string name="pref_desc__personal_settings">Open your diaspora account settings</string>
|
||||
|
||||
<string name="pref_title_manage_contacts">Contacts</string>
|
||||
<string name="pref_desc_manage_contacts">Manage your contact list</string>
|
||||
<string name="pref_title__manage_contacts">Contacts</string>
|
||||
<string name="pref_desc__manage_contacts">Manage your contact list</string>
|
||||
|
||||
<string name="pref_title_manage_tags">Manage Hashtags</string>
|
||||
<string name="pref_desc_manage_tags">Add and delete the hashtags you are following</string>
|
||||
<string name="pref_title__manage_tags">Manage Hashtags</string>
|
||||
<string name="pref_desc__manage_tags">Add and delete the hashtags you are following</string>
|
||||
|
||||
<string name="pref_title_change_account">Change Account</string>
|
||||
<string name="pref_desc_change_account">Erase local session data and switch to another Diaspora pod/account</string>
|
||||
<string name="pref_warning_change_account">This will erase all cookies and session data. Do you really want to change your account?</string>
|
||||
<string name="pref_title__change_account">Change Account</string>
|
||||
<string name="pref_desc__change_account">Erase local session data and switch to another Diaspora pod/account</string>
|
||||
<string name="pref_warning__change_account">This will erase all cookies and session data. Do you really want to change your account?</string>
|
||||
|
||||
<string name="pref_title_clear_cache">Clear cache</string>
|
||||
<string name="pref_desc_clear_cache">Clear WebView cache</string>
|
||||
<string name="pref_title__clear_cache">Clear cache</string>
|
||||
<string name="pref_desc__clear_cache">Clear WebView cache</string>
|
||||
|
||||
|
||||
<string name="pref_desc__intellihide_toolbars" translatable="false">Hide top and bottom toolbars automatically while scrolling</string>
|
||||
<string name="pref_title__intellihide_toolbars">Intellihide Toolbars</string>
|
||||
|
||||
</resources>
|
|
@ -175,6 +175,4 @@
|
|||
<string name="toast_set_proxy_failed">Warning: Could not set network proxy…</string>
|
||||
|
||||
<string name="all_tags">All tags</string>
|
||||
<string name="pref_desc_intellihide_toolbars">Hide top and bottom toolbars automatically while scrolling</string>
|
||||
<string name="pref_title_intellihide_toolbars">Intellihide Toolbars</string>
|
||||
</resources>
|
||||
|
|
|
@ -2,83 +2,83 @@
|
|||
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<!-- Appearance -->
|
||||
<PreferenceCategory
|
||||
android:key="pref_key_category_visuals"
|
||||
android:title="@string/pref_category_visuals">
|
||||
android:key="@string/pref_catkey__category_visuals"
|
||||
android:title="@string/pref_cat__visuals">
|
||||
<ListPreference
|
||||
android:dialogTitle="@string/pref_title_font_size"
|
||||
android:entries="@array/pref_entries_font_size"
|
||||
android:entryValues="@array/pref_entry_values_font_size"
|
||||
android:key="pref_key_font_size"
|
||||
android:dialogTitle="@string/pref_title__font_size"
|
||||
android:entries="@array/pref_entries__font_size"
|
||||
android:entryValues="@array/pref_entries_values__font_size"
|
||||
android:key="@string/pref_key__font_size"
|
||||
android:summary="%s"
|
||||
android:title="@string/pref_title_font_size"/>
|
||||
android:title="@string/pref_title__font_size"/>
|
||||
|
||||
<CheckBoxPreference
|
||||
android:defaultValue="true"
|
||||
android:key="pref_key_intellihide_toolbars"
|
||||
android:summary="@string/pref_desc_intellihide_toolbars"
|
||||
android:title="@string/pref_title_intellihide_toolbars"/>
|
||||
android:key="@string/pref_key__intellihide_toolbars"
|
||||
android:summary="@string/pref_desc__intellihide_toolbars"
|
||||
android:title="@string/pref_title__intellihide_toolbars"/>
|
||||
|
||||
</PreferenceCategory>
|
||||
|
||||
<!-- Diaspora Pod Settings -->
|
||||
<PreferenceCategory
|
||||
android:key="pref_key_category_pod_settings"
|
||||
android:title="@string/pref_category_pod_settings">
|
||||
android:key="@string/pref_catkey__pod_settings"
|
||||
android:title="@string/pref_cat__pod_settings">
|
||||
<Preference
|
||||
android:key="pref_key_personal_settings"
|
||||
android:summary="@string/pref_desc_personal_settings"
|
||||
android:title="@string/pref_title_personal_settings">
|
||||
android:key="@string/pref_key__personal_settings"
|
||||
android:summary="@string/pref_desc__personal_settings"
|
||||
android:title="@string/pref_title__personal_settings">
|
||||
</Preference>
|
||||
|
||||
<Preference
|
||||
android:key="pref_key_manage_tags"
|
||||
android:summary="@string/pref_desc_manage_tags"
|
||||
android:title="@string/pref_title_manage_tags">
|
||||
android:key="@string/pref_key__manage_tags"
|
||||
android:summary="@string/pref_desc__manage_tags"
|
||||
android:title="@string/pref_title__manage_tags">
|
||||
</Preference>
|
||||
|
||||
<Preference
|
||||
android:key="pref_key_manage_contacts"
|
||||
android:summary="@string/pref_desc_manage_contacts"
|
||||
android:title="@string/pref_title_manage_contacts">
|
||||
android:key="@string/pref_key__manage_contacts"
|
||||
android:summary="@string/pref_desc__manage_contacts"
|
||||
android:title="@string/pref_title__manage_contacts">
|
||||
</Preference>
|
||||
|
||||
<Preference
|
||||
android:key="pref_key_change_account"
|
||||
android:summary="@string/pref_desc_change_account"
|
||||
android:title="@string/pref_title_change_account">
|
||||
android:key="@string/pref_key__change_account"
|
||||
android:summary="@string/pref_desc__change_account"
|
||||
android:title="@string/pref_title__change_account">
|
||||
</Preference>
|
||||
</PreferenceCategory>
|
||||
|
||||
<!-- Networking -->
|
||||
<PreferenceCategory
|
||||
android:key="pref_key_category_network"
|
||||
android:title="@string/pref_category_network">
|
||||
android:key="@string/pref_catkey__network"
|
||||
android:title="@string/pref_cat__network">
|
||||
<CheckBoxPreference
|
||||
android:defaultValue="true"
|
||||
android:key="pref_key_load_images"
|
||||
android:summary="@string/pref_desc_load_images"
|
||||
android:title="@string/pref_title_load_images"/>
|
||||
android:key="@string/pref_key__load_images"
|
||||
android:summary="@string/pref_desc__load_images"
|
||||
android:title="@string/pref_title__load_images"/>
|
||||
|
||||
<Preference
|
||||
android:key="pref_key_clear_cache"
|
||||
android:summary="@string/pref_desc_clear_cache"
|
||||
android:title="@string/pref_title_clear_cache">
|
||||
android:key="@string/pref_key__clear_cache"
|
||||
android:summary="@string/pref_desc__clear_cache"
|
||||
android:title="@string/pref_title__clear_cache">
|
||||
</Preference>
|
||||
|
||||
<CheckBoxPreference
|
||||
android:defaultValue="false"
|
||||
android:key="pref_key_proxy_enabled"
|
||||
android:summary="@string/pref_desc_proxy_enabled"
|
||||
android:title="@string/pref_title_proxy_enabled"/>
|
||||
android:key="@string/pref_key__proxy_enabled"
|
||||
android:summary="@string/pref_desc__proxy_enabled"
|
||||
android:title="@string/pref_title__proxy_enabled"/>
|
||||
<EditTextPreference
|
||||
android:dependency="pref_key_proxy_enabled"
|
||||
android:dependency="@string/pref_key__proxy_enabled"
|
||||
android:inputType="textNoSuggestions"
|
||||
android:key="pref_key_proxy_host"
|
||||
android:title="@string/pref_title_proxy_host"/>
|
||||
android:key="@string/pref_key__proxy_host"
|
||||
android:title="@string/pref_title__proxy_host"/>
|
||||
<EditTextPreference
|
||||
android:dependency="pref_key_proxy_enabled"
|
||||
android:dependency="@string/pref_key__proxy_enabled"
|
||||
android:inputType="number"
|
||||
android:key="pref_key_proxy_port"
|
||||
android:title="@string/pref_title_proxy_port"/>
|
||||
android:key="@string/pref_key__proxy_port"
|
||||
android:title="@string/pref_title__proxy_port"/>
|
||||
</PreferenceCategory>
|
||||
</PreferenceScreen>
|
Loading…
Reference in a new issue