-
-
Notifications
You must be signed in to change notification settings - Fork 21.2k
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: Add support for cursor icons #44201
Conversation
e469e78
to
0c273e0
Compare
0c273e0
to
b51a615
Compare
Anythinhg else on this? @m4gr3d |
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.
The PR looks good. I've added a few pieces of feedback.
On the java side, the same logic is repeated both in the GodotGLRenderView
and GodotVulkanRenderView
. Move that logic into a helper class (e.g: GodotPointerIconHandler
), and have both instances of GodotRenderView
forward the necessary calls to that class instead.
Let's move support for custom cursor shape into another PR. From the look of the Android api, only passing Bitmap
is supported for custom pointer icon. The Godot native api has a matching Bitmap
resource class so we may be able to add a conversion utility between the two (and any other matching Godot resource types).
platform/android/java/lib/src/org/godotengine/godot/GodotVulkanRenderView.java
Show resolved
Hide resolved
Yeah, that what I was going to do I already tried a way to convert native bitmap to java bitmap but jni didn't like that, the best way I can think of is sending bitmap as array, but Ill think of a way when well get there For now Ill try to fix the code this week, thanks for the cr |
ea88d25
to
12ec200
Compare
@m4gr3d tried fixing the comment, while doing this I rebased buy it looks like android build stop working, trying to fix |
12ec200
to
4d67b06
Compare
looks like it's broken on master |
4d67b06
to
2b1efd3
Compare
084940a
to
802fc71
Compare
802fc71
to
85c81dc
Compare
71e0c60
to
ad0bf30
Compare
ad0bf30
to
e825673
Compare
e825673
to
94d11e9
Compare
Code looks good to me, is this ready to merge @thebestnom @m4gr3d? |
Last time I tested that it worked, but I can't run master on phone for about 4 month (can't remember exactly) so I haven't tested that since |
94d11e9
to
6f32c4f
Compare
@akien-mga ok, finally could test today and looks like it is still working! |
Great! Are all the requested changes addressed? |
Looked at the pr comments and the changes to refresh my memories and looks like I already addressed the comments, yep |
8fbec58
to
2631517
Compare
2631517
to
f5b5e00
Compare
ok, finally fixed static checks... I think this is ready for merge |
Thanks! |
Adds support for cursor shapes on Android
Custom cursor shape is way harder, there need to be a way to move image from native to java by jni and I can't seem to find any way to do it, any help would be appriciated
I'll add a branch for 3.2 with #43249 together once this is ready
@m4gr3d