comparison mcabber/src/screen.c @ 1513:9d78b571e693

Show '#' for unread message per buddy on the buddy status line '~' is still displayed when chat mode is enabled. But when it is disabled '#' is shown if there is an unread message from the current buddy (including groups).
author Maxim Vuets <maxim.vuets@gmail.com>
date Sat, 06 Sep 2008 17:33:01 +0300
parents e1c34d251e39
children 939e2957f8a8
comparison
equal deleted inserted replaced
1512:6d36a36a01c6 1513:9d78b571e693
1605 scr_UpdateMainStatus(FALSE); 1605 scr_UpdateMainStatus(FALSE);
1606 1606
1607 // Clear the line 1607 // Clear the line
1608 werase(chatstatusWnd); 1608 werase(chatstatusWnd);
1609 1609
1610 if (chatmode)
1611 wprintw(chatstatusWnd, "~");
1612
1613 if (!current_buddy) { 1610 if (!current_buddy) {
1614 if (forceupdate) { 1611 if (forceupdate) {
1615 update_panels(); 1612 update_panels();
1616 } 1613 }
1617 return; 1614 return;
1632 btypetext = "Room"; 1629 btypetext = "Room";
1633 ismuc = 1; 1630 ismuc = 1;
1634 } else if (btype & ROSTER_TYPE_SPECIAL) { 1631 } else if (btype & ROSTER_TYPE_SPECIAL) {
1635 btypetext = "Special buffer"; 1632 btypetext = "Special buffer";
1636 isspe = 1; 1633 isspe = 1;
1634 }
1635
1636 if (chatmode) {
1637 wprintw(chatstatusWnd, "~");
1638 } else {
1639 unsigned short bflags = buddy_getflags(BUDDATA(current_buddy));
1640 if (bflags & ROSTER_FLAG_MSG) {
1641 // There is an unread message from the current buddy
1642 wprintw(chatstatusWnd, "#");
1643 }
1637 } 1644 }
1638 1645
1639 if (chatmode && !isgrp) { 1646 if (chatmode && !isgrp) {
1640 winbuf *win_entry; 1647 winbuf *win_entry;
1641 win_entry = scr_SearchWindow(buddy_getjid(BUDDATA(current_buddy)), isspe); 1648 win_entry = scr_SearchWindow(buddy_getjid(BUDDATA(current_buddy)), isspe);