changeset 874:293e8955075c

Display a flag in the chat status line when the buffer is locked When chat mode is enabled and scrolling is locked, the "~" is replaced with a "*" in the chat status line.
author Mikael Berthe <mikael@lilotux.net>
date Fri, 26 May 2006 22:59:02 +0200
parents ee39f6d94d43
children fcf82bc5037c
files mcabber/src/screen.c
diffstat 1 files changed, 8 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/mcabber/src/screen.c	Fri May 26 22:51:19 2006 +0200
+++ b/mcabber/src/screen.c	Fri May 26 22:59:02 2006 +0200
@@ -598,8 +598,8 @@
     if (!win_entry->lock)
       roster_msg_setflag(winId, FALSE);
     roster_setflags(winId, ROSTER_FLAG_LOCK, TRUE);
-    update_roster = TRUE;
   }
+  update_roster = TRUE;
 
   // Refresh the window
   scr_UpdateWindow(win_entry);
@@ -970,6 +970,13 @@
   ismuc = btype & ROSTER_TYPE_ROOM;
   isspe = btype  & ROSTER_TYPE_SPECIAL;
 
+  if (chatmode && !isgrp) {
+    winbuf *win_entry;
+    win_entry = scr_SearchWindow(buddy_getjid(BUDDATA(current_buddy)), isspe);
+    if (win_entry && win_entry->lock)
+      mvwprintw(chatstatusWnd, 0, 0, "*");
+  }
+
   if (isgrp || isspe) {
     buf_locale = from_utf8(fullname);
     if (isgrp)