Manuscript (Case [Issue]22705) Morphic - We can get two times the mouseEnter/mouseLeave event when subscribing to the eventHandler of a Morph

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Manuscript (Case [Issue]22705) Morphic - We can get two times the mouseEnter/mouseLeave event when subscribing to the eventHandler of a Morph

Pharo Issue Tracker
Manuscript Notification
avatar
Bug in Project:  Morphic: 1. Pharo Image  •  You are subscribed to this case
Here is the fix that should be integrated in Pharo 8:

handleMouseEnter: anEvent
"System level event handling."

anEvent isDraggingEvent
ifTrue: [ (self handlesMouseOverDragging: anEvent)
ifTrue: [ anEvent wasHandled: true.
self mouseEnterDragging: anEvent ].
^ self eventHandler ifNotNil: [ :handler | handler mouseEnterDragging: anEvent fromMorph: self ] ].
self wantsBalloon
ifTrue: [ anEvent hand triggerBalloonFor: self after: self balloonHelpDelayTime ].
^ (self handlesMouseOver: anEvent)
ifTrue: [ anEvent wasHandled: true.
self mouseEnter: anEvent ]
ifFalse: [ self eventHandler ifNotNil: [ :handler | handler mouseEnter: anEvent fromMorph: self ] ]

===================

handleMouseLeave: anEvent
"System level event handling."

anEvent hand removePendingBalloonFor: self.
anEvent isDraggingEvent
ifTrue: [ (self handlesMouseOverDragging: anEvent)
ifTrue: [ anEvent wasHandled: true.
self mouseLeaveDragging: anEvent ].
^ self eventHandler ifNotNil: [ :handler | handler mouseLeave: anEvent fromMorph: self ] ].
^ (self handlesMouseOver: anEvent)
ifTrue: [ anEvent wasHandled: true.
self mouseLeave: anEvent ]
ifFalse: [ self eventHandler ifNotNil: [ :handler | handler mouseLeave: anEvent fromMorph: self ] ]
Priority Priority: 3 – Must Fix Status Status: Work Needed
Assigned To Assigned to: Everyone Milestone Milestone: Pharo8.0

Go to Case
No longer need updates? Unsubscribe from this case.

Don't want Manuscript notifications anymore? Update your preferences.

Manuscript

_______________________________________________
Pharo-bugtracker mailing list
[hidden email]
https://lists.gforge.inria.fr/mailman/listinfo/pharo-bugtracker