[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Erc-commit] [commit][emacs22] Temporarily enable iswitchb mode
From: |
mwolson |
Subject: |
[Erc-commit] [commit][emacs22] Temporarily enable iswitchb mode |
Date: |
Sun, 14 Oct 2007 00:48:35 -0400 |
commit f32cb85f0a6a1565bbbbe857273eaec17dbfbba7
Author: Michael Olson <address@hidden>
Date: Wed Dec 13 02:03:26 2006 +0000
Temporarily enable iswitchb mode
2006-12-13 Leo <address@hidden>
* erc.el (erc-iswitchb): Temporarily enable iswitchb mode if it
isn't active already, instead of leaving it on.
git-archimport-id: address@hidden/erc--main--0--patch-69
diff --git a/CREDITS b/CREDITS
index 064d8fb..0e6856b 100644
--- a/CREDITS
+++ b/CREDITS
@@ -154,6 +154,11 @@ Andrea Russo <address@hidden>:
Juanma Barranquero <address@hidden>:
* Vetted the inline documentation and provided many fixes.
+Leo <sdl.web AT gmail.com>:
+ * Fixed the erc-iswitchb function to only temporarily enable
+ iswitchb mode if it isn't active already (4 lines changed).
+
+
----
P.S.: Many people contributed small bits to ERC whose names I probably
diff --git a/ChangeLog b/ChangeLog
index e1dcb12..d6e8709 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2006-12-13 Leo <address@hidden>
+
+ * erc.el (erc-iswitchb): Temporarily enable iswitchb mode if it
+ isn't active already, instead of leaving it on.
+
2006-12-08 Michael Olson <address@hidden>
* CREDITS: Add Juanma Barranquero.
diff --git a/erc.el b/erc.el
index fe010e7..3918fdb 100644
--- a/erc.el
+++ b/erc.el
@@ -1685,22 +1685,25 @@ If `erc-track-mode' is in enabled, put the last element
of
Due to some yet unresolved reason, global function `iswitchb-mode'
needs to be active for this function to work."
(interactive "P")
- (eval-and-compile
+ (eval-when-compile
(require 'iswitchb))
- (let ((iswitchb-make-buflist-hook
- (lambda ()
- (setq iswitchb-temp-buflist
- (mapcar 'buffer-name
- (erc-buffer-list
- nil
- (when arg erc-server-process)))))))
- (switch-to-buffer
- (iswitchb-read-buffer
- "Switch-to: "
- (if (boundp 'erc-modified-channels-alist)
- (buffer-name (caar (last erc-modified-channels-alist)))
- nil)
- t))))
+ (let ((enabled iswitchb-mode))
+ (or enabled (iswitchb-mode 1))
+ (let ((iswitchb-make-buflist-hook
+ (lambda ()
+ (setq iswitchb-temp-buflist
+ (mapcar 'buffer-name
+ (erc-buffer-list
+ nil
+ (when arg erc-server-process)))))))
+ (switch-to-buffer
+ (iswitchb-read-buffer
+ "Switch-to: "
+ (if (boundp 'erc-modified-channels-alist)
+ (buffer-name (caar (last erc-modified-channels-alist)))
+ nil)
+ t)))
+ (or enabled (iswitchb-mode -1))))
(defun erc-channel-list (proc)
"Return a list of channel buffers.
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Erc-commit] [commit][emacs22] Temporarily enable iswitchb mode,
mwolson <=