pub enum PowerMode {
Off,
On,
Doze,
DozeSuspend,
// some variants omitted
}
Expand description
The power mode of the display hardware.
Variants§
Off
The display is powered off. The hardware will not apply new display configs nor generate new VSync events.
All display devices must support this power mode.
On
The display is fully powered on.
All display devices must support this power mode.
Doze
The display is powered on and configured in a low power state that is suitable for presenting ambient information to the user, possibly with lower fidelity than ON, but with greater efficiency.
A display device must support both DOZE
and DOZE_SUSPEND
power
modes, or neither.
DozeSuspend
The display is configured as the same state in DOZE but may stop applying display updates from the client.
This is effectively a hint to the device that drawing to the display has been suspended and that the device must remain in a low power state and continue displaying its current contents indefinitely until the power mode changes.
A display device must support both DOZE
and DOZE_SUSPEND
power
modes, or neither. When both modes are supported, the display device
is allowed to not use the hint above, in which case DOZE_SUSPEND
is identical to DOZE
.
Implementations§
Trait Implementations§
Source§impl<D> Decode<PowerMode, D> for PowerModewhere
D: ResourceDialect,
impl<D> Decode<PowerMode, D> for PowerModewhere
D: ResourceDialect,
Source§impl Ord for PowerMode
impl Ord for PowerMode
Source§impl PartialOrd for PowerMode
impl PartialOrd for PowerMode
Source§impl TypeMarker for PowerMode
impl TypeMarker for PowerMode
Source§fn inline_align(_context: Context) -> usize
fn inline_align(_context: Context) -> usize
Source§fn inline_size(_context: Context) -> usize
fn inline_size(_context: Context) -> usize
inline_align
.Source§fn encode_is_copy() -> bool
fn encode_is_copy() -> bool
Self::Owned
matches the FIDL wire
format and encoding requires no validation. When true, we can optimize
encoding arrays and vectors of Self::Owned
to a single memcpy. Read moreSource§fn decode_is_copy() -> bool
fn decode_is_copy() -> bool
Self::Owned
matches the FIDL wire
format and decoding requires no validation. When true, we can optimize
decoding arrays and vectors of Self::Owned
to a single memcpy.Source§impl ValueTypeMarker for PowerMode
impl ValueTypeMarker for PowerMode
Source§type Borrowed<'a> = PowerMode
type Borrowed<'a> = PowerMode
Encode<Self>
type cheaply obtainable from &Self::Owned
. There are three cases: Read moreSource§fn borrow(
value: &<PowerMode as TypeMarker>::Owned,
) -> <PowerMode as ValueTypeMarker>::Borrowed<'_>
fn borrow( value: &<PowerMode as TypeMarker>::Owned, ) -> <PowerMode as ValueTypeMarker>::Borrowed<'_>
&Self::Owned
to Self::Borrowed
.