diff mcabber/src/screen.c @ 123:1bdf882bed98

[/trunk] Changeset 136 by mikael * Fix a display problem when there is only one buddy connected and hide_offline is set and this buddy goes offline.
author mikael
date Tue, 26 Apr 2005 10:11:57 +0000
parents 94b251102069
children d3ee9abe9ca6
line wrap: on
line diff
--- a/mcabber/src/screen.c	Tue Apr 26 09:37:05 2005 +0000
+++ b/mcabber/src/screen.c	Tue Apr 26 10:11:57 2005 +0000
@@ -446,6 +446,9 @@
   int i, n;
   int rOffset;
 
+  // We can reset update_roster
+  update_roster = FALSE;
+
   getmaxyx(rosterWnd, maxy, maxx);
   maxx --;  // last char is for vertical border
   name[ROSTER_WIDTH-7] = 0;
@@ -461,6 +464,8 @@
   // Leave now if buddylist is empty
   if (!buddylist) {
     offset = 0;
+    update_panels();
+    doupdate();
     return;
   }
 
@@ -468,6 +473,8 @@
   i = g_list_position(buddylist, current_buddy);
   if (i == -1) { // This is bad
     scr_LogPrint("Doh! Can't find current selected buddy!!");
+    update_panels();
+    doupdate();
     return;
   } else if (i < offset) {
     offset = i;
@@ -516,7 +523,6 @@
 
   update_panels();
   doupdate();
-  update_roster = FALSE;
 }
 
 void scr_WriteMessage(const char *jid, const char *text, char *prefix)