ndk
ndk copied to clipboard
Rust bindings to the Android NDK
Depends on #495 `android/api-levels.h` from the NDK defines constants for all (NDK-supported) API levels and both a getter for the "current apps' target API level" as well as the API...
`android-activity` open-codes a lot of `ndk`-provided API, directly on top of native functions and symbols from `ndk-sys`. While attempting to remove most of it to simplify and clear up the...
This address is currently invalid: Please change it to: PS: I don't know where `ndk-context` crate is located in the repositories.
And "correct" their ABI to match how it is used in the actual NDK getter functions. Also add missing aliases and upstream documentation where sensible. --- CC @rib, I've been...
In https://github.com/rust-mobile/ndk/pull/412 @spencercw neatly added a wrapper to catch panics instead of **unsoundly** unwinding them across an `extern "C"` boundary. Rust 1.81 now plugged that hole and always aborts already:...
This now uses compile-time assertions rather than runtime `#[test]`s.
CC @rib for https://github.com/rust-mobile/android-activity/pull/163
Since the callback is leaking into memory, should we add a 'static constraint to it to make sure it's always valid, otherwise a JNIEnv
Currently InputEventJava doesn't have any available methods, can we modify it to an enumeration? ```rust pub enum InputEventJava { MotionEvent(MotionEventJava), KeyEvent(KeyEventJava) } pub struct MotionEventJava(MotionEvent); impl Deref for MotionEventJava {...
Fixes #502 When I implemented the `from_java()` constructors for `MotionEvent` and `KeyEvent` in #456, I used a single `InputEventJava` wrapper since that could wrap the existing `enum InputEvent` and only...