warp-to-window-enabled



I would like to modify the "warp-to-window-enabled" behavior,
specifically only warp the pointer when i switch window using the
keyboard.

I'm using the "enter-only" focus mode, so i've grossly hacked in
focus.jl the "enter-only" definition:

 (define-focus-mode 'enter-only
   (lambda (w action)
     (case action
	((pointer-in)
	 (when (window-really-wants-input-p w)
	   (set-input-focus w)))
	((warp-if-necessary)
	 ;;(let ((current (query-pointer-window)))
	   ;;(unless (or (eq current w) (desktop-window-p current))
	   ;;  (warp-cursor-to-window w)))
        ))))

i.e. i've commented out the last check and included in x-cycle.jl a
conditional against the "warp-to-window-enabled" symbol if the pointer
needs to be moved, something like the old "cycle-warp-pointer" option.

I'm quite happy on how Sawfish works now and seems i haven't broken it
yet, but i was wondering if there could be a cleaner way to do the
same, without modifying original source code...


--
Andrea



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