1
0
mirror of https://github.com/profanity-im/profanity.git synced 2024-12-04 14:46:46 -05:00

Added roster rooms preference

This commit is contained in:
James Booth 2016-01-02 01:29:12 +00:00
parent 22a14e1240
commit cf80fdc329
7 changed files with 12 additions and 1 deletions

View File

@ -1046,6 +1046,7 @@ _get_group(preference_t pref)
case PREF_ROSTER_PRIORITY:
case PREF_ROSTER_WRAP:
case PREF_ROSTER_RESOURCE_JOIN:
case PREF_ROSTER_ROOMS:
case PREF_RESOURCE_TITLE:
case PREF_RESOURCE_MESSAGE:
case PREF_ENC_WARN:
@ -1240,6 +1241,8 @@ _get_key(preference_t pref)
return "roster.wrap";
case PREF_ROSTER_RESOURCE_JOIN:
return "roster.resource.join";
case PREF_ROSTER_ROOMS:
return "roster.rooms";
case PREF_RESOURCE_TITLE:
return "resource.title";
case PREF_RESOURCE_MESSAGE:
@ -1297,6 +1300,7 @@ _get_default_boolean(preference_t pref)
case PREF_ROSTER_COUNT:
case PREF_ROSTER_PRIORITY:
case PREF_ROSTER_RESOURCE_JOIN:
case PREF_ROSTER_ROOMS:
case PREF_TLS_SHOW:
case PREF_LASTACTIVITY:
return TRUE;

View File

@ -73,6 +73,7 @@ typedef enum {
PREF_ROSTER_PRIORITY,
PREF_ROSTER_WRAP,
PREF_ROSTER_RESOURCE_JOIN,
PREF_ROSTER_ROOMS,
PREF_MUC_PRIVILEGES,
PREF_PRESENCE,
PREF_WRAP,

View File

@ -467,6 +467,7 @@ _load_preferences(void)
_set_string_preference("roster.order", PREF_ROSTER_ORDER);
_set_boolean_preference("roster.count", PREF_ROSTER_COUNT);
_set_boolean_preference("roster.priority", PREF_ROSTER_PRIORITY);
_set_boolean_preference("roster.rooms", PREF_ROSTER_ROOMS);
if (g_key_file_has_key(theme, "ui", "roster.size", NULL)) {
gint roster_size = g_key_file_get_integer(theme, "ui", "roster.size", NULL);
prefs_set_roster_size(roster_size);

View File

@ -512,5 +512,7 @@ rosterwin_roster(void)
}
prefs_free_string(by);
_rosterwin_rooms(layout, TRUE);
if (prefs_get_boolean(PREF_ROSTER_ROOMS)) {
_rosterwin_rooms(layout, TRUE);
}
}

View File

@ -89,6 +89,7 @@ roster.resource.join=true
roster.presence=true
roster.presence.indent=-1
roster.status=true
roster.rooms=true
occupants=true
occupants.size=15
occupants.jid=false

View File

@ -37,6 +37,7 @@ roster.resource.join=false
roster.presence=true
roster.presence.indent=1
roster.status=true
roster.rooms=true
privileges=true
presence=true
intype=true

View File

@ -30,6 +30,7 @@ roster.contact.indent=0
roster.resource=false
roster.presence=false
roster.status=false
roster.rooms=false
privileges=false
presence=false
intype=false