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

[WIP] Clean up StarboardBridge #4632

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

Conversation

haozheng-cobalt
Copy link
Contributor

@haozheng-cobalt haozheng-cobalt commented Jan 2, 2025

Remove @UsedByNative annotations for beforeStartOrResume and beforeSuspend, for they are no longer needed in ApplicationAndroid. Reference b/377042903.

Remove getLocalInterfaceAddressAndNetmask and isCurrentNetworkWireless, for it's not used in Chrobalt.

Remove @UsedByNative annotations for getDisplaySize, for it's never used in native code.

Change UA related fields getIsAmatiDevice, getBuildFingerprint, getPlayServicesVersion to @CalledByNative, we are currently not using them in UserAgentPlatformInfo::ToString(), but might need them for cobalt/browser/client_hint_headers.cc in the future.

Migrate the rest of JNI calls in starboard/android/shared/android_main.cc to Chromium standard JNI,
When testing locally:
startDeepLink is set with empty string.
GetArgs retrieves url.
01-02 22:06:07.303 13993 13993 I starboard: [dev.cobalt.coat/13993:0103/060607.300538(UTC):INFO:android_main.cc(76)] Test GetArgs: android_main--url=https://www.youtube.com/tv

@haozheng-cobalt haozheng-cobalt force-pushed the jni-1227 branch 3 times, most recently from 270b2a3 to cefa499 Compare January 3, 2025 06:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant