all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: martin rudalics <rudalics@gmx.at>
To: 1681@emacsbugs.donarmstrong.com
Subject: bug#1681: 23.0.60; list-processes - please reset focus to original frame when done
Date: Sun, 04 Jan 2009 20:35:22 +0100	[thread overview]
Message-ID: <49610F7A.3050902@gmx.at> (raw)

 > Please change `list-processes' so that it calls
 > `select-frame-set-input-focus' at the end to move focus back to the
 > frame that previously had the focus.
 >
 > This is a general problem. Perhaps a general fix could be found.
 >
 > It is at least a problem for functions that might display a buffer for
 > the first time, and especially those that then ask for user input
 > (e.g. `yes-or-no-p'). `list-processes' is a poster child for this kind
 > of function, and it has the added annoyance of being called
 > automatically by `C-x C-c'.

We might be able to make such behavior customizable for the case where
Emacs asks for user input.  Meanwhile you could try using a workaround
like

(defvar my-selected-frame nil)

(add-hook 'temp-buffer-setup-hook
	  (lambda ()
	    (setq my-selected-frame (selected-frame))))

(add-hook 'post-command-hook
	  (lambda ()
	    (when my-selected-frame
	      (select-frame-set-input-focus my-selected-frame)
	      (setq my-selected-frame nil))))

martin







             reply	other threads:[~2009-01-04 19:35 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-01-04 19:35 martin rudalics [this message]
     [not found] ` <CAAeL0SQbapGKXY70nwYDM0DUtw9fBEw1hBQV=1=fCSL-z2fYpg@mail.gmail.com>
2011-07-07 22:45   ` bug#1681: 23.0.60; list-processes - please reset focus to original frame when done Juanma Barranquero
  -- strict thread matches above, loose matches on Subject: below --
2008-12-23 16:48 Drew Adams
2012-10-04 18:52 ` martin rudalics
2012-10-04 20:18   ` Drew Adams

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=49610F7A.3050902@gmx.at \
    --to=rudalics@gmx.at \
    --cc=1681@emacsbugs.donarmstrong.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.