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

Android built-in cursor displayed on top of the game's own cursor #4373

Closed
ravCraft opened this issue Apr 17, 2021 · 11 comments · Fixed by #4989
Closed

Android built-in cursor displayed on top of the game's own cursor #4373

ravCraft opened this issue Apr 17, 2021 · 11 comments · Fixed by #4989

Comments

@ravCraft
Copy link

Describe the bug:
I'm playing osu Lazer with keyboard and mouse on android. But there's a problem at the cursor ( Android cursor won't dissapear, The cursor will overlap with the game default cursor)
Screenshots or videos showing encountered issue:
Screenshot_20210417_123341_25a1a32208bbcdc1d450b7aa854bb161
Screenshot_20210417_123423_25a1a32208bbcdc1d450b7aa854bb161
And also, i can't drag with my cursor and game cursor, both cursor are useless.
Disable mouse button in gameplay aren't working
osu!Lazer version:
2021.416.0
Logs:
runtime.log

@frenzibyte frenzibyte transferred this issue from ppy/osu Apr 17, 2021
@frenzibyte frenzibyte changed the title Android cursor won't disappeared Android built-in cursor displayed on top of the game's own cursor Apr 17, 2021
@peppy
Copy link
Member

peppy commented Apr 17, 2021

Can you confirm

  • what device you are using
  • what input method you are using
  • whether the cursor disappears in other apps or games

@ravCraft
Copy link
Author

ravCraft commented May 9, 2021

well it was too late, but just telling you.
Device I'm using : Vivo Y20
Input Method : Keyboard and mouse ( using otg, well you maybe know about that)
Cursor on other app : Minecraft ( my cursor not duplicates on minecraft, just like playing on pc)

Once agai sorry, whatever u reading this or not, and my english was bad

@sr229
Copy link
Contributor

sr229 commented May 10, 2021

AFAIK there's no proper way to hide the cursor in Android, there isn't any API for it. I guess this may be a wontfix due to the lack of APIs to hide the cursor. It doesn't work like generic Linux where it acknowledges that it needs to hide the cursor when the game tells it to, it'll draw the cursor no matter what.

@frenzibyte
Copy link
Member

The fact that the other game they tested hides the cursor means there may be some sort of way for this, but I'm not sure whether that statement is correct nor I can confirm it at the moment.

@LeNitrous
Copy link
Contributor

Tested on Redmi 5A. Games such as Minecraft and Unity games like Arknights and Azur Lane show the pointer is present.

Screenshot_20210510-144423_Minecraft

As said by @sr229, there's lack of proper APIs to be able to hide the system cursor.

@Susko3
Copy link
Member

Susko3 commented May 10, 2021

It's possible to hide the cursor: https://developer.android.com/training/gestures/movement#pointer-capture

I currently have a WIP branch that has pointer capture
https://github.com/Susko3/osu-framework/tree/android-captured-pointer-handler

It should be mostly working. I think there are some bugs, such as rhe mouse not working if absolute input was never received (eg. touch input).

@ravCraft

This comment has been minimized.

@sr229
Copy link
Contributor

sr229 commented May 10, 2021

It's possible to hide the cursor: https://developer.android.com/training/gestures/movement#pointer-capture

I currently have a WIP branch that has pointer capture
https://github.com/Susko3/osu-framework/tree/android-captured-pointer-handler

It should be mostly working. I think there are some bugs, such as rhe mouse not working if absolute input was never received (eg. touch input).

This is only for API level 26, we should be supporting Android N as well since it's still supported?

@bdach
Copy link
Collaborator

bdach commented May 10, 2021

The enable can be conditional if the functionality is not available via lower Android APIs. But it should not crash on devices that don't support it.

@ravCraft

This comment has been minimized.

@frenzibyte frenzibyte reopened this May 10, 2021
@bdach
Copy link
Collaborator

bdach commented May 10, 2021

@ravCraft no further input is required from you here. please wait for a fix to arrive.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

7 participants