emacs-diffs
[Top][All Lists]
Advanced

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

[Emacs-diffs] /srv/bzr/emacs/trunk r108467: Improve ediff and which-func


From: Chong Yidong
Subject: [Emacs-diffs] /srv/bzr/emacs/trunk r108467: Improve ediff and which-func integration.
Date: Sun, 03 Jun 2012 19:10:44 +0800
User-agent: Bazaar (2.5.0)

------------------------------------------------------------
revno: 108467
fixes bug: http://debbugs.gnu.org/11478
author: Jack Duthen <address@hidden>
committer: Chong Yidong <address@hidden>
branch nick: trunk
timestamp: Sun 2012-06-03 19:10:44 +0800
message:
  Improve ediff and which-func integration.
  
  * lisp/progmodes/which-func.el (which-func-update-ediff-windows): New
  function.  Use it in ediff-select-hook.
modified:
  lisp/ChangeLog
  lisp/progmodes/which-func.el
=== modified file 'lisp/ChangeLog'
--- a/lisp/ChangeLog    2012-06-03 10:54:22 +0000
+++ b/lisp/ChangeLog    2012-06-03 11:10:44 +0000
@@ -1,3 +1,8 @@
+2012-06-03  Jack Duthen  <address@hidden>  (tiny change)
+
+       * progmodes/which-func.el (which-func-update-ediff-windows): New
+       function.  Use it in ediff-select-hook (Bug#11478).
+
 2012-06-03  Chong Yidong  <address@hidden>
 
        * bindings.el: Remove explicit help text from format-mode-line.

=== modified file 'lisp/progmodes/which-func.el'
--- a/lisp/progmodes/which-func.el      2012-06-02 10:56:09 +0000
+++ b/lisp/progmodes/which-func.el      2012-06-03 11:10:44 +0000
@@ -337,6 +337,22 @@
          (funcall which-func-cleanup-function name)
        name))))
 
+
+;;; Integration with other packages
+
+(defun which-func-update-ediff-windows ()
+  "Update Which-Function mode display for Ediff windows.
+This function is meant to be called from `ediff-select-hook'."
+  (when (eq major-mode 'ediff-mode)
+    (when ediff-window-A
+      (which-func-update-1 ediff-window-A))
+    (when ediff-window-B
+      (which-func-update-1 ediff-window-B))
+    (when ediff-window-C
+      (which-func-update-1 ediff-window-C))))
+
+(add-hook 'ediff-select-hook 'which-func-update-ediff-windows)
+
 (provide 'which-func)
 
 ;;; which-func.el ends here


reply via email to

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