<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
</head>
<body>
<p>Hi Luciano,</p>
<p>These are very neat. Thank you!</p>
<p>They are now at GitHub.</p>
<p>Cheers,</p>
<div class="moz-cite-prefix">On 2025-11-22 9:36 AM, Luciano
Notarfrancesco via Cuis-dev wrote:<br>
</div>
<blockquote type="cite"
cite="mid:CAL5GDyr4z_C3L4VL8Y8GAmYwqZnvjJeWA5ApY=2mWSC+Ef8WKQ@mail.gmail.com">
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<div dir="ltr">This is a little tweak intended to be applied on
top of the previous change set. When the preference
focusFollowsMouse is enabled, it prevents doing it while the
hand is dragging something.</div>
<br>
<div class="gmail_quote gmail_quote_container">
<div dir="ltr" class="gmail_attr">On Mon, Nov 17, 2025 at
3:10 PM Luciano Notarfrancesco <<a
href="mailto:luchiano@gmail.com" moz-do-not-send="true"
class="moz-txt-link-freetext">luchiano@gmail.com</a>>
wrote:<br>
</div>
<blockquote class="gmail_quote"
style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;border-left-color:rgb(204,204,204);padding-left:1ex">
<div dir="ltr">Here's the changes I recently made to Morphic
events to try and improve drag & drop. Let me know what
you think. The change set adds the following protocol:
<div>- Morph>>dragEnter: and dragLeave: analogous to
the existing mouseEnter:, mouseLeave: and
mouseHover:localPosition:, but they are only called when
the hand is dragging something (i.e., it's not empty, has
submorphs) and the morph answers true to handlesDragOver:
(analogous to the existing handlesMouseOver:);</div>
<div>- Morph>>dragHover:localPosition: and
handlesDragHover (parallel to the existing
mouseHover:localPosition: and handlesMouseHover);</div>
<div>- Morph>>dragCancel is called by the hand if the
user presses ESC while dragging this morph; this gives the
dragged morph an opportunity to cancel the drag, for
example by deleting itself or returning to its original
owner and position (but by default does nothing).</div>
<div><br>
</div>
<div>Also, I fixed a problem when creating
MouseScrollEvents: the vertical direction was given
priority, and horizontal scroll events were missed. And I
also added a delta instance variable to MouseScrollEvent,
instead of throwing it away, so a consumer of the event
has the opportunity to scroll in both directions
simultaneously and at the correct speed. This information
is optional, and might not be available in all platforms
(I tried only Mac), but from what I read it is now quite
standard (except in legacy Linux X11). It's very useful
for navigating a ZUI, which is what I'm doing.</div>
<div><br>
</div>
<div>Other systems also separate mouseEnter/etc from
dragEnter/etc, so I tried to do the same, I don't want to
reinvent anything. Let me know if anyone has any better or
different ideas.</div>
<div><br>
</div>
<div>The change set also includes some unrelated changes,
please review: a method to draw arcs that was missing in
AbstractVectorCanvas, and two methods to scale and
translate PlacedMorphs (I'm not sure if the best selector
is scaleBy:around: or scaleBy:about:).</div>
</div>
</blockquote>
</div>
<br>
<fieldset class="moz-mime-attachment-header"></fieldset>
</blockquote>
<pre class="moz-signature" cols="72">--
Juan Vuletich
<a class="moz-txt-link-abbreviated" href="http://www.cuis.st">www.cuis.st</a>
github.com/jvuletich
researchgate.net/profile/Juan-Vuletich
independent.academia.edu/JuanVuletich
patents.justia.com/inventor/juan-manuel-vuletich</pre>
</body>
</html>