- riece-unread-channels))
- (riece-unread-update-channel-list-buffer))
-
-(defun riece-unread-update-channel-list-buffer ()
- (if riece-channel-list-buffer-mode
- (save-excursion
- (set-buffer riece-channel-list-buffer)
- (let ((inhibit-read-only t)
- buffer-read-only)
- (goto-char (point-min))
- (while (not (eobp))
- (if (looking-at "\\( ?[0-9]+:\\)\\(.\\)")
- (let ((channel (get-text-property (match-end 0)
- 'riece-identity)))
- (replace-match
- (concat "\\1"
- (if (riece-identity-member channel
- riece-unread-channels)
- "!"
- "\\2")))))
- (forward-line))))))
-
+ riece-unread-channels)))
+
+(defun riece-unread-format-channel-list-line (index channel)
+ (if (riece-identity-member channel riece-unread-channels)
+ (concat (format "%2d:!" index)
+ (riece-format-identity channel)
+ "\n")))
+