From: Aaron Jensen <aaronjensen@gmail.com>
To: martin rudalics <rudalics@gmx.at>
Cc: 31546@debbugs.gnu.org, Alan Third <alan@idiocy.org>
Subject: bug#31546: 27.0.50; macOS child frames with no mode-line mouse click problem
Date: Thu, 24 May 2018 03:53:54 -0700 [thread overview]
Message-ID: <CAHyO48zDO4uDAXui211KbBULb7PD-_-vx4UZaKcy4h74AJv1Uw@mail.gmail.com> (raw)
In-Reply-To: <5B06679A.2020407@gmx.at>
[-- Attachment #1: Type: text/plain, Size: 899 bytes --]
> > I do not know what the command is that is scrolling the child frame. It
> > does not appear in view-lossage.
> And C-h k does not give any clue either?
Ah, C-h k does give a clue, thank you!
<down-mouse-1> at that spot runs the command mouse-drag-region
<mouse-1> at that spot runs the command mouse-set-point
The window selected in posn-set-point is the window in the child frame,
which is the window that scrolls (and that I do not want to scroll).
But, the thing doing the scrolling is 'mouse-drag-region', which calls
'mouse-drag-track', which calculates the bottom of the window incorrectly
if it does not have a mode-line.
The attached patch fixes this, which fixes my originally reported problem.
Given that it impacts a use of child-frames and it's relatively minor I'd
propose that it gets applied to emacs 26 (probably after 26.1 release?) if
it's acceptable.
Thanks,
[-- Attachment #2: 0001-Prevent-errant-scroll-on-mouse-click-Bug-31546.patch --]
[-- Type: application/octet-stream, Size: 916 bytes --]
From aac9eb369af382f4197d1ac9d1efaf3e384126a6 Mon Sep 17 00:00:00 2001
From: Aaron Jensen <aaronjensen@gmail.com>
Date: Thu, 24 May 2018 03:45:03 -0700
Subject: [PATCH] Prevent errant scroll on mouse click (Bug#31546)
* lisp/mouse.el (mouse-drag-track): Only account for mode-line height
if `mode-line-format' is non-nil.
---
lisp/mouse.el | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/lisp/mouse.el b/lisp/mouse.el
index 95aada9b15..6a45118de0 100644
--- a/lisp/mouse.el
+++ b/lisp/mouse.el
@@ -1219,7 +1219,8 @@ mouse-drag-track
(bounds (window-edges start-window))
(make-cursor-line-fully-visible nil)
(top (nth 1 bounds))
- (bottom (if (window-minibuffer-p start-window)
+ (bottom (if (or (window-minibuffer-p start-window)
+ (not mode-line-format))
(nth 3 bounds)
;; Don't count the mode line.
(1- (nth 3 bounds))))
--
2.17.0
next prev parent reply other threads:[~2018-05-24 10:53 UTC|newest]
Thread overview: 44+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-05-22 5:23 bug#31546: 27.0.50; macOS child frames with no mode-line mouse click problem Aaron Jensen
2018-05-22 7:25 ` martin rudalics
2018-05-22 7:33 ` Aaron Jensen
2018-05-22 8:40 ` martin rudalics
2018-05-22 12:51 ` Aaron Jensen
2018-05-22 19:33 ` Alan Third
2018-05-22 19:36 ` Aaron Jensen
2018-05-22 19:44 ` Alan Third
2018-05-22 19:51 ` Aaron Jensen
2018-05-23 6:36 ` martin rudalics
2018-05-23 11:14 ` Aaron Jensen
2018-05-23 21:31 ` Alan Third
2018-05-23 22:21 ` Aaron Jensen
2018-05-24 7:19 ` martin rudalics
2018-05-24 10:53 ` Aaron Jensen [this message]
2018-05-24 11:06 ` Aaron Jensen
2018-05-24 15:28 ` Eli Zaretskii
2018-05-24 15:58 ` Aaron Jensen
2018-05-25 6:34 ` martin rudalics
2018-05-26 16:38 ` Alan Third
2018-05-26 17:02 ` Aaron Jensen
2018-05-26 18:22 ` Alan Third
2018-05-26 20:15 ` Aaron Jensen
2018-05-27 6:22 ` martin rudalics
2018-05-27 15:57 ` Eli Zaretskii
2018-05-27 17:13 ` Aaron Jensen
2018-05-27 17:38 ` Eli Zaretskii
2018-05-27 17:52 ` Aaron Jensen
2018-05-27 18:52 ` Aaron Jensen
2018-05-27 21:24 ` Alan Third
2018-05-27 21:53 ` Aaron Jensen
2018-06-02 6:35 ` Aaron Jensen
2018-06-02 8:00 ` Eli Zaretskii
2018-06-02 15:41 ` Aaron Jensen
2018-06-14 16:37 ` Aaron Jensen
2018-06-14 20:40 ` Alan Third
2018-06-14 21:21 ` Aaron Jensen
2018-06-15 7:02 ` Eli Zaretskii
2018-06-17 11:08 ` Alan Third
2018-06-17 12:03 ` Aaron Jensen
2018-05-24 15:27 ` Eli Zaretskii
2018-05-24 7:19 ` martin rudalics
2018-05-23 6:36 ` martin rudalics
2018-05-23 6:36 ` martin rudalics
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=CAHyO48zDO4uDAXui211KbBULb7PD-_-vx4UZaKcy4h74AJv1Uw@mail.gmail.com \
--to=aaronjensen@gmail.com \
--cc=31546@debbugs.gnu.org \
--cc=alan@idiocy.org \
--cc=rudalics@gmx.at \
/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.