Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mouse cursor only hidden when placed at the center of the video player #7394

Closed
FiberOnePL opened this issue Oct 3, 2024 · 13 comments · Fixed by #7458 or #7464
Closed

Mouse cursor only hidden when placed at the center of the video player #7394

FiberOnePL opened this issue Oct 3, 2024 · 13 comments · Fixed by #7458 or #7464
Assignees
Labels
component: UI The issue involves the Shaka Player UI priority: P2 Smaller impact or easy workaround status: archived Archived and locked; will not be updated type: bug Something isn't working correctly
Milestone

Comments

@FiberOnePL
Copy link

When playing a video, the cursor remains visible when being placed on the left or the right side of the video player, it is hidden when being place in the center of the video player. These positions seem to be related to the div.shake-rewind-container and div.shaka-fast-forward-container seen in the (edited) screenshot (the green area is the one where the cursor is hidden).
337990817-874fa1af-40d9-4b98-ab6a-48948e506a1f

@FiberOnePL FiberOnePL added the type: bug Something isn't working correctly label Oct 3, 2024
@joeyparrish joeyparrish added component: UI The issue involves the Shaka Player UI priority: P2 Smaller impact or easy workaround labels Oct 3, 2024
@joeyparrish
Copy link
Member

Great find! This probably has to do with which elements get mouse interactions, who receives mouseover events, how the timer to hide the mouse is started, etc.

@shaka-bot shaka-bot added this to the v4.12 milestone Oct 3, 2024
@FiberOnePL
Copy link
Author

@joeyparrish

After commenting out the cursor tracking everything works fine. So you're right.

@OothecaPickle
Copy link

OothecaPickle commented Oct 6, 2024

@FiberOnePL which lines did you comment out?

@joeyparrish
Copy link
Member

Would you please consider sending a PR?

@OothecaPickle
Copy link

OothecaPickle commented Oct 6, 2024

The cursor is also not hidden along with the rest of the UI if it's placed over other elements such as the center play button, if enabled, or the progress bar area.

@OothecaPickle
Copy link

OothecaPickle commented Oct 9, 2024

When the cursor is placed over the big play button, the DevTools debugger does break if the breakpoint is set to the line that sets the cursor style to 'none' , but the cursor does not disappear.

OothecaPickle added a commit to OothecaPickle/shaka-player that referenced this issue Oct 10, 2024
when hiding and showing the cursor

partially fixes shaka-project#7394
OothecaPickle added a commit to OothecaPickle/shaka-player that referenced this issue Oct 10, 2024
when hiding and showing the cursor

partially fixes shaka-project#7394
@avelad
Copy link
Member

avelad commented Oct 18, 2024

@joeyparrish

After commenting out the cursor tracking everything works fine. So you're right.

Can you create a PR with your change? Thanks!

@FiberOnePL
Copy link
Author

FiberOnePL commented Oct 18, 2024

@joeyparrish @avelad

Yes, the problem is caused by cursor tracking

@OothecaPickle
Copy link

OothecaPickle commented Oct 21, 2024

@avelad #7458 doesn't resolve the issue, the cursor is still not hidden if it's placed over other UI elements such as the center play button or the video controls. My solution was to update the cursor style for all descendant elements of the video container acbc006

@joeyparrish joeyparrish reopened this Oct 21, 2024
@joeyparrish
Copy link
Member

Recursively changing the cursor feels hacky. Shouldn't elements below the container inherit the cursor style instead?

@OothecaPickle
Copy link

Recursively changing the cursor feels hacky. Shouldn't elements below the container inherit the cursor style instead?

cursor styles with more specificity (that take precedence) are defined in CSS for many of those elements
cursor-styles

@OothecaPickle
Copy link

in the case of the big play button, the user agent stylesheet overrides its cursor style
bigplaybutton-cursor

@joeyparrish
Copy link
Member

Hrm... then maybe we should adjust those as well. Maybe some of them are not needed?

avelad added a commit that referenced this issue Oct 23, 2024
avelad added a commit that referenced this issue Oct 24, 2024
avelad added a commit that referenced this issue Oct 24, 2024
avelad added a commit that referenced this issue Oct 24, 2024
joeyparrish pushed a commit that referenced this issue Nov 12, 2024
@shaka-bot shaka-bot added the status: archived Archived and locked; will not be updated label Dec 22, 2024
@shaka-project shaka-project locked as resolved and limited conversation to collaborators Dec 22, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
component: UI The issue involves the Shaka Player UI priority: P2 Smaller impact or easy workaround status: archived Archived and locked; will not be updated type: bug Something isn't working correctly
Projects
None yet
5 participants