bug-gnu-emacs
[Top][All Lists]
Advanced

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

bug#11672: 23.3; info menu-bar acts on wrong window


From: martin rudalics
Subject: bug#11672: 23.3; info menu-bar acts on wrong window
Date: Tue, 12 Jun 2012 08:54:11 +0200

> Steps to reproduce the bug:
>
> -start emacs
> -start info
> -clone-buffer
> -activate the 1st window (e.g by clicking in the window)
> -open a node in the first window (e.g by hitting '3')
> -activate the 2nd window (e.g. by clicking in the window)
> -open a node in the 2nd window (e.g. by clicking '5')
> -click the "Up: (dir)" link in the menu-bar of the first window
>  without activating the window first
>
> As you see, the node changes in the second window, not in the first one.
>
> The same happens with emacs started in a text mode terminal with gpm
> mouse support.

I'd define things like

(defun Info-header-up ()
  (interactive)
  (let* ((mouse-position (mouse-position))
         (window
          (ignore-errors
            (window-at (cadr mouse-position) (cddr mouse-position)
                       (car mouse-position)))))
    (if window
        (with-selected-window window
          (Info-up))
      (Info-up))))

together with

    (define-key keymap [header-line mouse-1] 'Info-header-up)
    (define-key keymap [header-line mouse-2] 'Info-header-up)

martin





reply via email to

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