[Cuis-dev] Discarded mouse trail

Hilaire Fernandes hfern at free.fr
Sun Aug 4 07:32:58 PDT 2024


Hi Juan,

I have observed you discard trail mouse positions:

HandMorph>>generateMouseEvent: evtBuf 
...
type == #mouseMove 
	ifTrue: [
		trail := self mouseTrailFrom: evtBuf.
		^MouseMoveEvent new 
			setType: type
			position: trail last
			buttons: buttons
			hand: self
			stamp: stamp].


In the Squeak implementation, it is still taken in consideration in the 
MouseMoveEvent instance.

I am porting the 1Dollar recognizer from Squeak and I can observed a far 
greater amount of mouse positions taken in consideration in the original 
package, because of the trail array:

HandMorph>>generateMouseEvent: evtBuf 
...
type == #mouseMove ifTrue: 
	[trail := self mouseTrailFrom: evtBuf.
	^MouseMoveEvent new 
		setType: type
		startPoint: self position
		endPoint: trail last
*trail: trail*
		buttons: buttons
		hand: self
		stamp: stamp].

I have experimented putting back the trail in the MouseMoveEvent, and 
indead it provide more information.

I ma likely need the trail too in my PaperMorph for the Dynabook.

What do you think?

Hilaire
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.cuis.st/mailman/archives/cuis-dev/attachments/20240804/7298228d/attachment.htm>


More information about the Cuis-dev mailing list