[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Context menus and mouse-3
From: |
Eli Zaretskii |
Subject: |
Re: Context menus and mouse-3 |
Date: |
Mon, 12 Jul 2021 14:55:48 +0300 |
> From: Juri Linkov <juri@linkov.net>
> Date: Mon, 12 Jul 2021 02:38:19 +0300
> Cc: philipk@posteo.net, Richard Stallman <rms@gnu.org>, spacibba@aol.com,
> emacs-devel@gnu.org, arthur.miller@live.com, dgutov@yandex.ru, ghe@sdf.org,
> drew.adams@oracle.com
>
> >> > We don't need to choose, since we can get a context menu on
> >> > `down-mouse-3` and 'mouse-save-then-kill' on `mouse-3`.
> >
> > (defun mouse-maybe-context-menu (event)
> > "Bring up a context menu for a long click.
> > See `mouse-long-click-time' and `mouse-context-menu-function'."
> > (interactive "@e")
> > (if (let ((track-mouse t)) (sit-for (/ mouse-long-click-time 1000.0)))
> > (push (cons 'context-menu (cdr event)) unread-command-events)))
> >
> > It's not good enough for `master` (IIRC the sit-for tends to return nil
> > immediately in some circumstances), but I didn't pursue this any further
> > given the lack of interest at the time. I can't think of any reason why
> > it should be hard to fix.
>
> This is a much needed feature and it would nice to finish it one way or
> another.
> I tried to use timers, and the result works well in all test cases:
Could you please remind us the problem you are trying to solve here?
Thanks.
- Re: Context menus and mouse-3, Juri Linkov, 2021/07/11
- RE: [External] : Re: Context menus and mouse-3, Drew Adams, 2021/07/11
- Re: Context menus and mouse-3,
Eli Zaretskii <=
- Re: Context menus and mouse-3, Juri Linkov, 2021/07/12
- RE: [External] : Re: Context menus and mouse-3, Drew Adams, 2021/07/12
- Re: Context menus and mouse-3, Eli Zaretskii, 2021/07/13
- Re: Context menus and mouse-3, Juri Linkov, 2021/07/13
- Re: Context menus and mouse-3, Eli Zaretskii, 2021/07/14
- Re: Context menus and mouse-3, Juri Linkov, 2021/07/14
- Re: Context menus and mouse-3, Eli Zaretskii, 2021/07/15
- Re: Context menus and mouse-3, Juri Linkov, 2021/07/15
- Re: Context menus and mouse-3, Eli Zaretskii, 2021/07/16
- Re: Context menus and mouse-3, Juri Linkov, 2021/07/16