* gnus-util.el (gnus-select-frame-set-input-focus): Use
authorKatsumi Yamaoka <yamaoka@jpl.org>
Thu, 20 Apr 2006 01:08:38 +0000 (01:08 +0000)
committerKatsumi Yamaoka <yamaoka@jpl.org>
Thu, 20 Apr 2006 01:08:38 +0000 (01:08 +0000)
 select-frame-set-input-focus if it is available in XEmacs;
 use definition defined in Emacs 22 for old Emacsen.

* dgnushack.el: Autoload unmorse-region for XEmacs.

* lpath.el: Bind cursor-in-non-selected-windows and
 select-frame-set-input-focus for XEmacs.

lisp/ChangeLog
lisp/dgnushack.el
lisp/gnus-util.el
lisp/lpath.el

index f8bf778..20df819 100644 (file)
@@ -1,3 +1,14 @@
+2006-04-20  Katsumi Yamaoka  <yamaoka@jpl.org>
+
+       * gnus-util.el (gnus-select-frame-set-input-focus): Use
+       select-frame-set-input-focus if it is available in XEmacs; use
+       definition defined in Emacs 22 for old Emacsen.
+
+       * dgnushack.el: Autoload unmorse-region for XEmacs.
+
+       * lpath.el: Bind cursor-in-non-selected-windows and
+       select-frame-set-input-focus for XEmacs.
+
 2006-04-19  Katsumi Yamaoka  <yamaoka@jpl.org>
 
        * mm-view.el (mm-inline-text): Use equal instead of equalp.
index 4d6a119..5f3f807 100644 (file)
@@ -233,6 +233,7 @@ fixed in Emacs after 21.3."
     (autoload 'sort-numeric-fields "sort" nil t)
     (autoload 'sort-subr "sort")
     (autoload 'trace-function-background "trace" nil t)
+    (autoload 'unmorse-region "morse" nil t)
     (autoload 'w3-do-setup "w3")
     (autoload 'w3-prepare-buffer "w3-display")
     (autoload 'w3-region "w3-display" nil t)
index e9ab7d3..d29e238 100644 (file)
@@ -1419,22 +1419,19 @@ CHOICE is a list of the choice char and help message at IDX."
 (defun gnus-select-frame-set-input-focus (frame)
   "Select FRAME, raise it, and set input focus, if possible."
   (cond ((featurep 'xemacs)
-        (raise-frame frame)
-        (select-frame frame)
-        (focus-frame frame))
-       ;; The function `select-frame-set-input-focus' won't set
-       ;; the input focus under Emacs 21.2 and X window system.
-       ;;((fboundp 'select-frame-set-input-focus)
-       ;; (defalias 'gnus-select-frame-set-input-focus
-       ;;   'select-frame-set-input-focus)
-       ;; (select-frame-set-input-focus frame))
+        (if (fboundp 'select-frame-set-input-focus)
+            (select-frame-set-input-focus frame)
+          (raise-frame frame)
+          (select-frame frame)
+          (focus-frame frame)))
+       ;; `select-frame-set-input-focus' defined in Emacs 21 will not
+       ;; set the input focus.
        ((>= emacs-major-version 22)
         (select-frame-set-input-focus frame))
        (t
         (raise-frame frame)
         (select-frame frame)
-        (cond ((and (eq window-system 'x)
-                    (fboundp 'x-focus-frame))
+        (cond ((memq window-system '(x mac))
                (x-focus-frame frame))
               ((eq window-system 'w32)
                (w32-focus-frame frame)))
index 500852c..d8d880f 100644 (file)
                     find-coding-systems-region find-coding-systems-string
                     mail-abbrevs-setup mouse-minibuffer-check mouse-movement-p
                     mouse-scroll-subr overlay-lists posn-point posn-window
-                    read-event set-buffer-multibyte track-mouse window-edges))
+                    read-event set-buffer-multibyte
+                    select-frame-set-input-focus track-mouse window-edges))
       (maybe-bind '(adaptive-fill-first-line-regexp
                    buffer-display-table buffer-file-coding-system
-                   current-language-environment
+                   current-language-environment cursor-in-non-selected-windows
                    default-enable-multibyte-characters
                    enable-multibyte-characters gnus-agent-expire-current-dirs
                    language-info-alist mark-active mouse-selection-click-count