[Top][All Lists]

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

bug#16680: 24.3; select-frame-set-input-focus: not an in-range integer

From: joakim
Subject: bug#16680: 24.3; select-frame-set-input-focus: not an in-range integer
Date: Fri, 19 Sep 2014 23:53:28 +0200
User-agent: Gnus/5.130012 (Ma Gnus v0.12) Emacs/24.4.50 (gnu/linux)

I have this error:

select-frame-set-input-focus: Not an in-range integer, float, or cons of 

It happens for instanc3e in helm mode.

If I comment out     ;(x-focus-frame frame)
in the function below, the problem doesnt seem to occur.

I see that the bug is rather old, but my emacs is rather newly compiled,
so im not sure.

(defun select-frame-set-input-focus (frame &optional norecord)
  "Select FRAME, raise it, and set input focus, if possible.
If `mouse-autoselect-window' is non-nil, also move mouse pointer
to FRAME's selected window.  Otherwise, if `focus-follows-mouse'
is non-nil, move mouse cursor to FRAME.

Optional argument NORECORD means to neither change the order of
recently selected windows nor the buffer list."
  (select-frame frame norecord)
  (raise-frame frame)
  ;; Ensure, if possible, that FRAME gets input focus.
  (when (memq (window-system frame) '(x w32 ns))
    ;(x-focus-frame frame)
  ;; Move mouse cursor if necessary.
    (let ((edges (window-inside-edges (frame-selected-window frame))))
      ;; Move mouse cursor into FRAME's selected window to avoid that
      ;; Emacs mouse-autoselects another window.
      (set-mouse-position frame (nth 2 edges) (nth 1 edges))))
    ;; Move mouse cursor into FRAME to avoid that another frame gets
    ;; selected by the window manager.
    (set-mouse-position frame (1- (frame-width frame)) 0))))

Joakim Verona

reply via email to

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