-
-
Notifications
You must be signed in to change notification settings - Fork 3.1k
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
Fix persistent hover overlay when in desktop/DeX mode or using a mouse/non-touch input #8316
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you, code looks almost good. But return directly ;-)
28f997d
to
dfe4594
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Considering NewPipe is designed for Android which is designed for touch input devices I'm not sure if we should implement this in the first place.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks good to me, thanks :-)
Let's wait for what @litetex has to say
I see the same problem on my random cheap android tv shitbox (X88 Pro 10) so I tried this patch. As it is it doesn't help, because edit: #4422 says that there are more devices / conditions where this overlay appears unwantedly. Maybe just disabling it unconditionally would be an option, since the player is highlighted by a border as well? |
I've added a check for devices with cursors: cybersphinx@e86a34b (full branch) With this it works on my tv box (and phone with attached mouse), I don't have any of the fancy devices mentioned in #4422 with stylus or finger hover detection. There's an SDK version check around it that can/should be removed if minSdk is raised to 21. |
The barrier has been lifted. |
Updated my branch to remove the check, and fix a silly oversight. |
@cybersphinx do you want me to add your commits here? Or do you want to open a new PR? |
If you can add them here I guess that's the best place. |
Done; @litetex could you review again? |
Kudos, SonarCloud Quality Gate passed! |
- Avoid NullPointerException crashes if there is no UiModeManager or desktop system service mode - Use final for every exception - Suppress missing fields warnings - Add missing NonNull annotation
e9e68b4
to
abf1cc5
Compare
I rebased the PR and pushed a commit to the branch which improves the code added, let me know if it is good for you :) |
Kudos, SonarCloud Quality Gate passed! |
Thanks @AudricV, looks good to me! |
What is it?
Description of the changes in your PR
A non-touch input device that supports hover events results in a persistent transparent overlay on top of the video player. When using an Android device in desktop mode or with a mouse, the content is obscured with said overlay.
The bug was first reported here: #4357
This PR adds an
isDesktopMode
check and removes the hover overlay for thedetailThumbnailRootLayout
only when in desktop mode (DeX, Android desktop, etc.)Before/After Screenshots/Screen Record
Before:
After:
Fixes the following issue(s)
APK testing
APK for testing: app-debug.apk.zip
Due diligence