[Cuis-dev] Small change in PluggableScrollPane

Juan Vuletich juan at cuis.st
Mon May 20 11:58:28 PDT 2024


On 5/17/2024 10:39 PM, Alan Ferrise via Cuis-dev wrote:
> Hi, I noted a small bug when I was doing some exercises in Cuis so I 
> tried to fix it:
> image.png
> When the mouse is over a button and you scroll, it ends up scrolling 
> the text that sits behind the active window, which in this case is the 
> Terse Guide.
>
> I started looking how to fix this and I found that PluggableScrollPane 
> is the class responsible for modeling scrolling windows. I noted that 
> it doesn't listen to mouseOver events, so I did it and added an 
> instance collaborator named mouseIsOver, whose value is checked when 
> the mouseScroll event is called. This seems to have fixed the problem.
> I then looked its sibling class, PluggableButtonMorph, that listens to 
> the mouseOver events in the same manner that I end up implementing it 
> in PluggableScrollPane, which make me wonder if I had to put 
> mouseIsOver in their superclass, however, I ended up discarding the idea.
> I include the ChangeSet with the changes.
>
> Thanks in advance.
>

Hi Alan,

While I agree on the problem, I don't really agree on the suggested 
solution. The problem is in the event dispatching logic that decides to 
which morph deliver the scroll events. This should be solved without 
adding new ivars at all. If nobody beats me to it, I'll do it in a few days.

Thanks,

-- 
Juan Vuletich
cuis.st
github.com/jvuletich
researchgate.net/profile/Juan-Vuletich
independent.academia.edu/JuanVuletich
patents.justia.com/inventor/juan-manuel-vuletich
linkedin.com/in/juan-vuletich-75611b3
twitter.com/JuanVuletich

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.cuis.st/mailman/archives/cuis-dev/attachments/20240520/ded8e839/attachment-0001.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: image/png
Size: 210152 bytes
Desc: not available
URL: <http://lists.cuis.st/mailman/archives/cuis-dev/attachments/20240520/ded8e839/attachment-0001.png>


More information about the Cuis-dev mailing list