Add preference for showing TLS indicator in titlebar

Issue #616
This commit is contained in:
James Booth
2015-10-14 00:46:16 +01:00
parent c9165ef9d2
commit ef832ce526
6 changed files with 19 additions and 3 deletions

View File

@@ -602,6 +602,7 @@ _get_group(preference_t pref)
case PREF_RESOURCE_MESSAGE:
case PREF_ENC_WARN:
case PREF_INPBLOCK_DYNAMIC:
case PREF_TLS_SHOW:
return PREF_GROUP_UI;
case PREF_STATES:
case PREF_OUTTYPE:
@@ -781,6 +782,8 @@ _get_key(preference_t pref)
return "log";
case PREF_CERT_PATH:
return "certpath";
case PREF_TLS_SHOW:
return "tls.show";
default:
return NULL;
}
@@ -817,6 +820,7 @@ _get_default_boolean(preference_t pref)
case PREF_ROSTER_OFFLINE:
case PREF_ROSTER_RESOURCE:
case PREF_ROSTER_EMPTY:
case PREF_TLS_SHOW:
return TRUE;
default:
return FALSE;

View File

@@ -112,6 +112,7 @@ typedef enum {
PREF_ENC_WARN,
PREF_PGP_LOG,
PREF_CERT_PATH,
PREF_TLS_SHOW,
} preference_t;
typedef struct prof_alias_t {

View File

@@ -471,6 +471,7 @@ _load_preferences(void)
_set_boolean_preference("intype", PREF_INTYPE);
_set_boolean_preference("enc.warn", PREF_ENC_WARN);
_set_boolean_preference("tls.show", PREF_TLS_SHOW);
if (g_key_file_has_key(theme, "ui", "otr.char", NULL)) {
gchar *ch = g_key_file_get_string(theme, "ui", "otr.char", NULL);