changeset 44296:915a76139f37

(handle-select-window): New function.
author Pavel Janík <Pavel@Janik.cz>
date Mon, 01 Apr 2002 13:38:34 +0000
parents ea6a55176423
children f98d54034759
files lisp/window.el
diffstat 1 files changed, 8 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/window.el	Mon Apr 01 13:38:09 2002 +0000
+++ b/lisp/window.el	Mon Apr 01 13:38:34 2002 +0000
@@ -578,6 +578,14 @@
     (and window (not window-handled) (not window-solitary)
 	 (delete-window window))))
 
+(defun handle-select-window (event)
+  "Handle select-window events."
+  (interactive "e")
+  (let ((window (posn-window (event-start event))))
+    (if (or (not (window-minibuffer-p window))
+	    (minibuffer-window-active-p window))
+	(select-window window))))
+
 (define-key ctl-x-map "2" 'split-window-vertically)
 (define-key ctl-x-map "3" 'split-window-horizontally)
 (define-key ctl-x-map "}" 'enlarge-window-horizontally)