unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#36894: Stability issues in frameset sorting
@ 2019-08-01 21:34 Juri Linkov
  2019-08-05 21:17 ` Juri Linkov
  0 siblings, 1 reply; 23+ messages in thread
From: Juri Linkov @ 2019-08-01 21:34 UTC (permalink / raw)
  To: 36894

[-- Attachment #1: Type: text/plain, Size: 269 bytes --]

Tags: patch

Currently frameset sorting is not stable.  It changes the sorting order of equal
minibuffer-owning frames.  On closer inspection it becomes clear that
frameset--mini parameters are messed up in 'frameset--minibufferless-last-p'.
This patch should fix it:


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: frameset--minibufferless-last-p.patch --]
[-- Type: text/x-diff, Size: 756 bytes --]

diff --git a/lisp/frameset.el b/lisp/frameset.el
index 73b2071a5a..0d921421ad 100644
--- a/lisp/frameset.el
+++ b/lisp/frameset.el
@@ -1102,8 +1104,8 @@ frameset--minibufferless-last-p
   "Predicate to sort frame states in an order suitable for creating frames.
 It sorts minibuffer-owning frames before minibufferless ones.
 Internal use only."
-  (pcase-let ((`(,hasmini1 ,id-def1) (assq 'frameset--mini (car state1)))
-	      (`(,hasmini2 ,id-def2) (assq 'frameset--mini (car state2))))
+  (pcase-let ((`(,hasmini1 . ,id-def1) (cdr (assq 'frameset--mini (car state1))))
+	      (`(,hasmini2 . ,id-def2) (cdr (assq 'frameset--mini (car state2)))))
     (cond ((eq id-def1 t) t)
 	  ((eq id-def2 t) nil)
 	  ((not (eq hasmini1 hasmini2)) (eq hasmini1 t))

^ permalink raw reply related	[flat|nested] 23+ messages in thread

end of thread, other threads:[~2019-08-19  7:38 UTC | newest]

Thread overview: 23+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-08-01 21:34 bug#36894: Stability issues in frameset sorting Juri Linkov
2019-08-05 21:17 ` Juri Linkov
2019-08-06 15:14   ` Eli Zaretskii
2019-08-06 22:09     ` Juri Linkov
2019-08-07  2:29       ` Eli Zaretskii
2019-08-09 18:09         ` Juri Linkov
2019-08-09 19:04           ` Eli Zaretskii
2019-08-11 20:51             ` bug#36894: Restore frameset focus and selectedness Juri Linkov
2019-08-12 15:00               ` Eli Zaretskii
2019-08-13 21:29                 ` Juri Linkov
2019-08-14  8:58                   ` martin rudalics
2019-08-14 14:25                     ` Eli Zaretskii
2019-08-14 20:50                       ` Juri Linkov
2019-08-15  8:12                       ` martin rudalics
2019-08-15 18:36                         ` Juri Linkov
2019-08-15 19:37                           ` Eli Zaretskii
2019-08-16  7:29                           ` martin rudalics
2019-08-17  7:19                         ` Eli Zaretskii
2019-08-17  8:24                           ` martin rudalics
2019-08-17 10:12                             ` Eli Zaretskii
2019-08-17 22:40                               ` Juri Linkov
2019-08-19  7:38                               ` martin rudalics
2019-08-14 20:49                     ` Juri Linkov

Code repositories for project(s) associated with this public inbox

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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).