#[repr(C)]pub struct VirtualViewCallback {
pub cb: VirtualViewCallbackType,
pub ctx: OptionRefAny,
}Expand description
Callback that, given a rectangle area on the screen, returns the DOM appropriate for that bounds (useful for infinite lists)
Fields§
§cb: VirtualViewCallbackType§ctx: OptionRefAnyFor FFI: stores the foreign callable (e.g., PyFunction) Native Rust code sets this to None
Implementations§
Source§impl VirtualViewCallback
impl VirtualViewCallback
Sourcepub fn create_from_host_handle(handle: u64) -> Self
pub fn create_from_host_handle(handle: u64) -> Self
Build a wrapper whose cb is the static thunk above and
whose ctx carries the host’s u64 handle. The host
language is responsible for keeping its id→callable table
in sync with the releaser registered via
AzApp_setHostHandleReleaser.
Source§impl VirtualViewCallback
impl VirtualViewCallback
pub fn create(cb: VirtualViewCallbackType) -> Self
Trait Implementations§
Source§impl Clone for VirtualViewCallback
impl Clone for VirtualViewCallback
Source§impl Debug for VirtualViewCallback
impl Debug for VirtualViewCallback
Source§impl Display for VirtualViewCallback
impl Display for VirtualViewCallback
Source§impl From<extern "C" fn(RefAny, VirtualViewCallbackInfo) -> VirtualViewReturn> for VirtualViewCallback
Allow creating callback from a raw function pointer
Sets callable to None (for native Rust/C usage)
impl From<extern "C" fn(RefAny, VirtualViewCallbackInfo) -> VirtualViewReturn> for VirtualViewCallback
Allow creating callback from a raw function pointer Sets callable to None (for native Rust/C usage)
Source§fn from(cb: VirtualViewCallbackType) -> Self
fn from(cb: VirtualViewCallbackType) -> Self
Converts to this type from the input type.
Source§impl Hash for VirtualViewCallback
impl Hash for VirtualViewCallback
Source§impl Ord for VirtualViewCallback
impl Ord for VirtualViewCallback
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialEq for VirtualViewCallback
impl PartialEq for VirtualViewCallback
Source§impl PartialOrd for VirtualViewCallback
impl PartialOrd for VirtualViewCallback
impl Eq for VirtualViewCallback
Auto Trait Implementations§
impl Freeze for VirtualViewCallback
impl RefUnwindSafe for VirtualViewCallback
impl Send for VirtualViewCallback
impl Sync for VirtualViewCallback
impl Unpin for VirtualViewCallback
impl UnsafeUnpin for VirtualViewCallback
impl UnwindSafe for VirtualViewCallback
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more