diff options
-rw-r--r-- | irc_im.c | 4 | ||||
-rw-r--r-- | protocols/account.c | 1 |
2 files changed, 5 insertions, 0 deletions
@@ -112,6 +112,10 @@ static gboolean bee_irc_user_status(bee_t *bee, bee_user_t *bu, bee_user_t *old) irc_t *irc = bee->ui_data; irc_user_t *iu = bu->ui_data; + if (set_getbool(&bu->ic->acc->set, "offline_is_away") && !(bu->flags & BEE_USER_ONLINE)) { + bu->flags |= (BEE_USER_ONLINE | BEE_USER_AWAY); + } + /* Do this outside the if below since away state can change without the online state changing. */ iu->flags &= ~IRC_USER_AWAY; diff --git a/protocols/account.c b/protocols/account.c index 8fa196d0..aa14b0c3 100644 --- a/protocols/account.c +++ b/protocols/account.c @@ -75,6 +75,7 @@ account_t *account_add(bee_t *bee, struct prpl *prpl, char *user, char *pass) s->flags |= SET_NOSAVE | ACC_SET_OFFLINE_ONLY | ACC_SET_LOCKABLE; set_setstr(&a->set, "username", user); set_add(&a->set, "offline_user_quits", "true", set_eval_bool, a); + set_add(&a->set, "offline_is_away", "false", set_eval_bool, a); /* Hardcode some more clever tag guesses. */ strcpy(tag, prpl->name); |