#[non_exhaustive]pub enum PresentationUnavailableReason {
ZeroExtent,
SurfaceLost,
NoCompatibleSurface,
HostUnavailable,
}Expand description
Reason a native presentation cannot currently be used.
The enum is non-exhaustive. It provides diagnosis only; recovery occurs by
applying PresentationEvent::Retry or allowing creation again.
§Examples
use ailloli_ui_runtime::app::PresentationUnavailableReason;
assert_ne!(PresentationUnavailableReason::ZeroExtent, PresentationUnavailableReason::SurfaceLost);Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
ZeroExtent
Logical width or height was zero/non-positive for surface creation.
SurfaceLost
A previously usable rendering surface was lost.
NoCompatibleSurface
No surface/configuration compatible with the host was available.
The native presentation provider itself is unavailable.
Trait Implementations§
Source§fn clone(&self) -> PresentationUnavailableReason
fn clone(&self) -> PresentationUnavailableReason
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§fn eq(&self, other: &PresentationUnavailableReason) -> bool
fn eq(&self, other: &PresentationUnavailableReason) -> bool
Tests for
self and other values to be equal, and is used by ==.Auto Trait Implementations§
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<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.Source§impl<A> IntoClickAction<A> for Awhere
A: Clone + 'static,
impl<A> IntoClickAction<A> for Awhere
A: Clone + 'static,
Source§fn into_click_action(self) -> ClickAction<A>
fn into_click_action(self) -> ClickAction<A>
Implements the into_click_action helper used by this module.