GNU bug report logs - #15029
24.3; feature-request: add window-focus-lost-hook

Previous Next

Package: emacs;

Reported by: Ivan Baidakou <dmol <at> gmx.com>

Date: Mon, 5 Aug 2013 20:35:01 UTC

Severity: wishlist

Tags: patch

Found in version 24.3

Fixed in version 24.4

Done: Glenn Morris <rgm <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


Message #44 received at 15029 <at> debbugs.gnu.org (full text, mbox):

From: Stefan Monnier <monnier <at> iro.umontreal.ca>
To: Richard Stallman <rms <at> gnu.org>
Cc: 15029 <at> debbugs.gnu.org, dmol <at> gmx.com
Subject: Re: bug#15029: 24.3; feature-request: add window-focus-lost-hook
Date: Fri, 09 Aug 2013 09:54:56 -0400
> post-command-hook is also used in narrow ways, and it doesn't
> cause anything strange to happen just because you move the mouse.

When I move the mouse from one frame to another, it generates
a `switch-frame' event, which is run by the perfectly normal command
handle-switch-frame, including running pre/post-command-hook.

> If I understand what mouse-autoselect-window does, it only causes
> switching windows -- it does not run Lisp code.

Same as above: runs pre/post-command-hook etc...

> What is a very useful application for running code when the mouse
> moves out of the Emacs frame?

Currently used to turn off the blink-cursor timer.
Other users want it to (auto-)save a file when its buffer/frame
loses focus.
Yet others want to change the frame's background color to indicate that
it has focus.


        Stefan




This bug report was last modified 11 years and 246 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.