mirror of
https://git.jabber.space/devs/cproof.git
synced 2026-07-21 02:06:21 +00:00
Added account theme property
This commit is contained in:
@@ -851,6 +851,9 @@ cons_show_account(ProfAccount *account)
|
||||
if (account->startscript) {
|
||||
cons_show ("Start script : %s", account->startscript);
|
||||
}
|
||||
if (account->theme) {
|
||||
cons_show ("Theme : %s", account->theme);
|
||||
}
|
||||
if (account->otr_policy) {
|
||||
cons_show ("OTR policy : %s", account->otr_policy);
|
||||
}
|
||||
|
||||
@@ -353,6 +353,25 @@ ui_group_removed(const char *const contact, const char *const group)
|
||||
void
|
||||
ui_handle_login_account_success(ProfAccount *account, int secured)
|
||||
{
|
||||
if (account->theme) {
|
||||
if (theme_load(account->theme)) {
|
||||
ui_load_colours();
|
||||
if (prefs_get_boolean(PREF_ROSTER)) {
|
||||
ui_show_roster();
|
||||
} else {
|
||||
ui_hide_roster();
|
||||
}
|
||||
if (prefs_get_boolean(PREF_OCCUPANTS)) {
|
||||
ui_show_all_room_rosters();
|
||||
} else {
|
||||
ui_hide_all_room_rosters();
|
||||
}
|
||||
ui_redraw();
|
||||
} else {
|
||||
cons_show("Couldn't find account theme: %s", account->theme);
|
||||
}
|
||||
}
|
||||
|
||||
resource_presence_t resource_presence = accounts_get_login_presence(account->name);
|
||||
contact_presence_t contact_presence = contact_presence_from_resource_presence(resource_presence);
|
||||
cons_show_login_success(account, secured);
|
||||
|
||||
Reference in New Issue
Block a user