mirror of
https://github.com/profanity-im/profanity.git
synced 2025-02-02 15:08:15 -05:00
statusbar: dont query setting twice
We already got that just a couple of lines above..
This commit is contained in:
parent
42876619ec
commit
c32aac7644
@ -565,17 +565,15 @@ _status_bar_draw_maintext(int pos)
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (statusbar->fulljid) {
|
if (statusbar->fulljid) {
|
||||||
auto_gchar gchar* pref = prefs_get_string(PREF_STATUSBAR_SELF);
|
if (g_strcmp0(self, "off") == 0) {
|
||||||
|
|
||||||
if (g_strcmp0(pref, "off") == 0) {
|
|
||||||
return pos;
|
return pos;
|
||||||
}
|
}
|
||||||
if (g_strcmp0(pref, "user") == 0) {
|
if (g_strcmp0(self, "user") == 0) {
|
||||||
auto_jid Jid* jidp = jid_create(statusbar->fulljid);
|
auto_jid Jid* jidp = jid_create(statusbar->fulljid);
|
||||||
mvwprintw(statusbar_win, 0, pos, "%s", jidp->localpart);
|
mvwprintw(statusbar_win, 0, pos, "%s", jidp->localpart);
|
||||||
return pos;
|
return pos;
|
||||||
}
|
}
|
||||||
if (g_strcmp0(pref, "barejid") == 0) {
|
if (g_strcmp0(self, "barejid") == 0) {
|
||||||
auto_jid Jid* jidp = jid_create(statusbar->fulljid);
|
auto_jid Jid* jidp = jid_create(statusbar->fulljid);
|
||||||
mvwprintw(statusbar_win, 0, pos, "%s", jidp->barejid);
|
mvwprintw(statusbar_win, 0, pos, "%s", jidp->barejid);
|
||||||
return pos;
|
return pos;
|
||||||
|
Loading…
Reference in New Issue
Block a user