Skip to content

Add documentation for JavaClassWrapper and AndroidRuntime plugin #10979

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

m4gr3d
Copy link
Contributor

@m4gr3d m4gr3d commented May 30, 2025

As the title mentions, this adds documentation for the JavaClassWrapper singleton and the AndroidRuntime plugin.
These capabilities were introduced in Godot 4.4, so the PR will need to be pick against the 4.4 documentation as well.

@m4gr3d m4gr3d added this to the 4.5 milestone May 30, 2025
@m4gr3d m4gr3d added enhancement area:manual Issues and PRs related to the Manual/Tutorials section of the documentation topic:plugin platform:android cherrypick:4.4 labels May 30, 2025
@m4gr3d m4gr3d force-pushed the add_documentation_javaclasswrapper branch from 0e2a08f to 72093ed Compare May 30, 2025 16:21
m4gr3d added a commit to m4gr3d/godot that referenced this pull request May 30, 2025
@m4gr3d m4gr3d force-pushed the add_documentation_javaclasswrapper branch 2 times, most recently from b11eb4c to 79bb866 Compare May 30, 2025 21:17
Copy link
Contributor

@dsnopek dsnopek left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me!

Copy link
Member

@Alex2782 Alex2782 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The examples worked.

On my Samsung Tab, I had reduced the system vibration level, and after increasing it, the example worked as well.

- Analytics
- Login
- Ads
- etc...
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe this list should be just part of the previous paragraph, to keep it shorter? "..diverse functionality, like push notifications, analytics, authentication, ads etc."? Or similar. Don't care strongly about this however.

Copy link
Member

@syntaxerror247 syntaxerror247 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's also add a line about inner classes with an example.
You can use this example:

var version = JavaClassWrapper.wrap("android.os.Build$VERSION")
var sdk_int = version.SDK_INT
If sdk_int == 30:
    # Do something specific on android 11 devices.
else:
    # All other devices

@m4gr3d m4gr3d force-pushed the add_documentation_javaclasswrapper branch 2 times, most recently from 52ead2f to a49ded3 Compare June 2, 2025 19:12
@AThousandShips AThousandShips removed this from the 4.5 milestone Jun 3, 2025
@m4gr3d m4gr3d force-pushed the add_documentation_javaclasswrapper branch from a49ded3 to 1be5d1d Compare June 4, 2025 12:38
DuartePonce pushed a commit to DuartePonce/godot that referenced this pull request Jun 6, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:manual Issues and PRs related to the Manual/Tutorials section of the documentation cherrypick:4.4 enhancement platform:android topic:plugin
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants