pub struct OhosSurfaceDescriptor {
pub logical_size: LogicalSize,
pub window: *mut c_void,
pub surface_id: u64,
}Expand description
An OpenHarmony window to present to, for MapHandle::attach_ohos_surface().
Name the window by window or by surface_id. The session takes its own
reference to the window, so you can release yours once the call returns.
See mln_ohos_surface_descriptor in the
C API reference.
Fields§
§logical_size: LogicalSize§window: *mut c_voidYour OHNativeWindow*, or null to name the window by surface_id.
surface_id: u64The surface ID of a surface in this process, such as the one that
XComponentController.getXComponentSurfaceId() reports, or 0 to name
the window by window.
Implementations§
Source§impl OhosSurfaceDescriptor
impl OhosSurfaceDescriptor
pub fn new(logical_size: LogicalSize) -> Self
Trait Implementations§
Source§impl Clone for OhosSurfaceDescriptor
impl Clone for OhosSurfaceDescriptor
Source§fn clone(&self) -> OhosSurfaceDescriptor
fn clone(&self) -> OhosSurfaceDescriptor
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for OhosSurfaceDescriptor
Source§impl Debug for OhosSurfaceDescriptor
impl Debug for OhosSurfaceDescriptor
Source§impl PartialEq for OhosSurfaceDescriptor
impl PartialEq for OhosSurfaceDescriptor
impl StructuralPartialEq for OhosSurfaceDescriptor
Auto Trait Implementations§
impl !Send for OhosSurfaceDescriptor
impl !Sync for OhosSurfaceDescriptor
impl Freeze for OhosSurfaceDescriptor
impl RefUnwindSafe for OhosSurfaceDescriptor
impl Unpin for OhosSurfaceDescriptor
impl UnsafeUnpin for OhosSurfaceDescriptor
impl UnwindSafe for OhosSurfaceDescriptor
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> ErasedDestructor for Twhere
T: 'static,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more