Skip to content

remove mousemove callback when there's no longer a cat - fix #1158

What does this MR do?

This removes the mousemove event listener when removing the cat, so we're not leaking listeners.

While I was there, I marked the callback as "passive", which should improve performance (see https://developer.mozilla.org/en-US/docs/Web/API/EventTarget/addEventListener#using_passive_listeners )

Contribution Guidelines

By submitting this merge request, you agree to follow our Contribution Guidelines

  • I agree to follow this project's Contribution Guidelines
  • I have made sure to test this merge request

Closes #1158 (closed)

Merge request reports

Loading