Subject: Re: bug#50993: 29.0.50; Problems when dragging the mouse over the toolbar

From: martin rudalics <[email-masked]>
Date: Mon, 11 Oct 2021 14:31:08 +0200

>> Yes, but how does 'mouse-minibuffer-check' enter this picture?
 >
 > It's called by mouse-drag-track, with START-EVENT as its argument.

But is START-EVENT the problem here?

 >> I see.  Dragging the secondary selection seems to work here with the
 >> trivial patch below.  Can you try it?
 >
 > I'm sorry, but it doesn't resolve the problem.

The purpose of the patch is to allow dragging the secondary selection
with the mouse when the cursor crosses the tool bar on Lucid.  When,
during mouse tracking, we leave the initial window, we use an exit
strategy that samples the mouse position and scrolls the window
accordingly.  I'd first like to know whether it works for the secondary
selection.  If so, we should be able to fix 'mouse-drag-track' in a
similar way.

 > Binding [tool-bar mouse-movement] to mouse-drag-region still results in
 > the same error from mouse-minibuffer-track when the mouse is dragged
 > over the toolbar.

I'm afraid such binding won't help.  We just have to be able to enter
the part in 'mouse-drag-track' starting with

                (let ((mouse-row (cdr (cdr (mouse-position)))))

to be able to compare mouse-row with the top of the start window,
ignoring any binding.

martin