erc-commit
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Erc-commit] [commit][master] erc-track: Use the mode-line faces if no p


From: mwolson
Subject: [Erc-commit] [commit][master] erc-track: Use the mode-line faces if no priority face is found.
Date: Sun, 27 Jan 2008 23:30:27 -0500

commit d00667cf56bbef67dbecf22bd8d9323b11433f05
Author: Diane Murray <address@hidden>
Date:   Mon Jan 28 03:27:09 2008 +0100

    erc-track: Use the mode-line faces if no priority face is found.
    
    * erc-track.el (erc-track-find-face): If no choice was found
    return nil to use the default mode-line faces.

diff --git a/ChangeLog b/ChangeLog
index f69ed5f..dfd12a4 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2008-01-28  Diane Murray  <address@hidden>
+
+       * erc-track.el (erc-track-find-face): If no choice was found
+       return nil to use the default mode-line faces.
+
 2008-01-26  Michael Olson  <address@hidden>
 
        * erc.el (erc-version-string): Release ERC 5.3.
diff --git a/erc-track.el b/erc-track.el
index 360d92c..8f6f7aa 100644
--- a/erc-track.el
+++ b/erc-track.el
@@ -867,17 +867,16 @@ Use `erc-make-mode-line-buffer-name' to create buttons."
 
 (defun erc-track-find-face (faces)
   "Return the face to use in the modeline from the faces in FACES.
-If `erc-track-faces-priority-list' is set, the one from FACES who is
-first in that list will be used.
+If `erc-track-faces-priority-list' is set, the one from FACES who
+is first in that list will be used.  If nothing matches of if
+`erc-track-faces-priority-list' is not set, the default mode-line
+faces will be used.
 
 If `erc-track-faces-normal-list' is non-nil, use it to produce a
 blinking effect that indicates channel activity when the first
 element in FACES and the highest-ranking face among the rest of
 FACES are both members of `erc-track-faces-normal-list'.
 
-If `erc-track-faces-priority-list' is not set, the first element
-in FACES will be used.
-
 If one of the faces is a list, then it will be ranked according
 to its highest-tanking face member.  A list of faces including
 that member will take priority over just the single member
@@ -892,7 +891,7 @@ element."
                           (when (member candidate (cdr faces))
                             (throw 'face candidate)))))))
     (cond ((null choice)
-          (car faces))
+          nil)
          ((and (member choice erc-track-faces-normal-list)
                (member no-first erc-track-faces-normal-list))
           no-first)




reply via email to

[Prev in Thread] Current Thread [Next in Thread]