Subject: bug#8996: Set PRIMARY from last selection, not last selected window

From: David De La Harpe Golden <[email-masked]>
Date: Tue, 27 Mar 2012 01:16:38 +0100

On 26/03/12 05:06, Chong Yidong wrote:

> OK, I've committed a variable selection-inhibit-update-commands.

Right so, thanks. Seems to work fine, and it is useful to me to be able
to add entries, anyway:

FWIW, in the past day of emacs use, apart from 'handle-select-window and 
'handle-switch-frame, 'other-window was indeed the main case I ran into, 
but 'other-frame got added too.

'delete-window (and 'delete-frame too) also got pushed onto the list 
quickly: I was sometimes selecting something in a window then deleting 
that window immediately afterward, and then of course, without 
'delete-window on the list, primary would then be replaced by whatever 
region in whatever remaining window got (re)activated, losing whatever I 
had expected to be in primary.

Haven't felt an urge to add anything else as yet, but I guess I only
use a fairly small working set of emacs commands, and of course in turn 
the issue will only apply to a few of them. I suppose more 
emacs-idiomatic use of the kill-ring would have meant I didn't encounter 
as many problems, so my own usage quirks aren't blameless.