.MouseEnter/.MouseLeave not fired on UI Frames when scrolled

Description

  • If you hover your mouse over any UI Frame that supports MouseEnter/MouseLeave signals in ScrollingFrame, and then scroll using your scrolling wheel with out moving the mouse, .MouseLeave signal will not be fired on that frame. Same with .MouseEnter signal, where if you scroll in a ScrollingFrame with out moving the mouse and happen to hover over a Frame, .MouseEnter signal will not be fired.

Expected Behaviour

  • .MouseEnter/.MouseLeave signals should be fired in a ScrollingFrame on frames if you only move the scrolling wheel and not change the mouse position

Reproduction Steps

  1. Create a ScrollingFrame in ScreenGui
  2. Parent 2 Frames to ScrollingFrame with different positions
  3. Set up a script which would print โ€œEnteredโ€ for .MouseEnter signal and โ€œLeftโ€ for .MouseLeave for both frames
  4. Position your cursor/mouse so that it hovers over 1st frame, and when scrolling wheel used, it would hover over another frame
  5. Scroll 1 time using your scrolling wheel with out moving your mouse
  6. โ€œLeftโ€ or โ€œEnteredโ€ will not be printed in the output, meaning that signals did not fire.

Impact

  • Small
6 Likes

Weโ€™ve filed a ticket into our internal database for this issue and will start investigating, we will update you when we have further information.

Thanks for flagging!

1 Like

Even if this topic is old, nothing has changed since then.

This is a really annoying problem, all modern engines and even browsers trigger this event as expected. Itโ€™s such a simple thing to fix, but it reduces the user experience a lot (at least for me). The Frames get stuck in place and itโ€™s just feels not intuitive. The Roblox Engine should update the mouse not only when moving, but also when scrolling. Please fix this, 9 months have passed and the bug still exists.

2 Likes

I would like to see an update on this issue, as of today im still having the same issue with my GUI and it would only add more clutter if i had to program my own solution.

idk why this randomly got bumped but this is intended behavior since MouseEnter/MouseLeave are intended to fire when the user voluntarily hovers over it and this will not fire if a gui is moved under the userโ€™s cursor without the cursor moving to trigger the event

if you want this to work just use PlayerGui:GetGuiObjectsAtPosition() and check if the first object is the button you want to use

how are they not voluntarily hovering over it by scrolling the frame? genuine question

1 Like

CanvasPosition is writable ๓ €€๓ €€๓ €€๓ €€๓ €€๓ €€๓ €€๓ €€๓ €€๓ €€๓ €€๓ €€๓ €€๓ €€๓ €€๓ €€๓ €€๓ €€๓ €€๓ €€๓ €€๓ €€๓ €€๓ €€๓ €€๓ €€๓ €€๓ €€๓ €€๓ €€๓ €€๓ €€๓ €€๓ €€๓ €€๓ €€๓ €€๓ €€๓ €€๓ €€๓ €€

so the grand question being, why not simply just ignore when itโ€™s being written? this issue is annoying and deals a lot more inconvenience

2 Likes

mouseenter/mouseleave are based on mouse movement not ui movement. if they fired whenever the ui moved that would cause them to be fired excessively killing performance

tldr: they dont fire with idle cursor

1 Like

It would be great if this issue could get solved, Iโ€™m making an inventory system with a scroll frame and it just feels really low quality when scrolling doesnโ€™t show any response

This feature is intended.

The engine only checks wether the mouse is over every time it moves, not every frame. Since the mouse doesnโ€™t move when youโ€™re scrolling, the events arenโ€™t checked.

I actually created a module for this a bit agoโ€ฆ itโ€™s very useful. Iโ€™ll put it under Resources > Community Resources whenever I have a chance