[Cuis-dev] Strange behavior with stepping

Hilaire Fernandes hilaire at drgeo.eu
Sun Aug 22 00:53:15 PDT 2021


Le 21/08/2021 à 20:22, Juan Vuletich a écrit :
> Can you provide detailed instructions (setting up, etc) to reproduce 
> the problem?


It is very simple.

As I want to capture a 1.5s button still down event with the mouse 
cursor not moving. I do as following.

Whenever there is a mouse move event (button down, 
mouseMove:localPosition:), it is dispatched to the current DrGeo tool. 
When the context of the tool is dragging an object, at the end of the 
tool handler method I reset the mouseStillDown handle by calling this 
simple method:

resetMouseStillDownHandle "We reset the timer"     prevMousePos 
ifNotNil: [         self startStepping: #processMouseStillDown         
in: self mouseStillDownThreshold (1500)         stepTime: self 
mouseStillDownStepRate (1)]

The expected result is that when the user press down a button, without 
moving the cursor, the #mouseStillDown message is sent by the Morphic 
system after 1.5s.

There is really nothing special as changing the state of Morphic. I am 
only repeatedly stopping and starting the stepping.

Best

-- 
GNU Dr. Geo
http://drgeo.eu
http://blog.drgeo.eu

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.cuis.st/mailman/archives/cuis-dev/attachments/20210822/350779f8/attachment.htm>


More information about the Cuis-dev mailing list