Skip to main content

FakeDesktopInner

Struct FakeDesktopInner 

Source
pub struct FakeDesktopInner {
Show 16 fields pub icons: HashMap<IconId, IconSnapshot>, pub flags: u32, pub commit_log: Vec<Vec<(IconId, Point)>>, pub flag_ops: Vec<(u32, u32)>, pub next_list_error: Option<DesktopError>, pub monitors: Vec<MonitorInfo>, pub desktop_info: Option<DesktopInfo>, pub next_overlay_error: Option<DesktopError>, pub overlay_active: bool, pub real_icons_visible: bool, pub last_overlay_plans: Vec<IconRenderPlan>, pub last_overlay_render_options: OverlayRenderOptions, pub overlay_frame_log: Vec<Vec<(IconId, Point)>>, pub visual_frame_log: Vec<Vec<IconFrame>>, pub overlay_finalize_log: Vec<Vec<(IconId, Point)>>, pub next_commit_errors: VecDeque<DesktopError>,
}

Fields§

§icons: HashMap<IconId, IconSnapshot>

All icons currently on the fake desktop.

§flags: u32

Current folder-view flags word.

§commit_log: Vec<Vec<(IconId, Point)>>

Log of every set_positions batch, in order. Each entry is the list of (id, new_pos) pairs that were actually applied (missing ids are excluded).

§flag_ops: Vec<(u32, u32)>

Log of every apply_flags(mask, values) call.

§next_list_error: Option<DesktopError>

If set, list_icons will fail with this error the next time it is called. Cleared after the failing call.

§monitors: Vec<MonitorInfo>

Simulated monitor layout. Defaults to a single 1920x1080 primary monitor at the origin so tests that don’t care about multi- monitor behaviour keep working.

§desktop_info: Option<DesktopInfo>§next_overlay_error: Option<DesktopError>

If set, begin_overlay_session will fail with this error the next time it is called. Cleared after the failing call.

§overlay_active: bool

Whether an overlay session is currently open on this fake backend.

§real_icons_visible: bool§last_overlay_plans: Vec<IconRenderPlan>

The IconRenderPlan list passed to the most recent successful begin_overlay_session call.

§last_overlay_render_options: OverlayRenderOptions

The OverlayRenderOptions passed to the most recent successful begin_overlay_session call. Initialised to OverlayRenderOptions::all_enabled until a session opens.

§overlay_frame_log: Vec<Vec<(IconId, Point)>>

Log of every commit_overlay_frame call, in order.

§visual_frame_log: Vec<Vec<IconFrame>>§overlay_finalize_log: Vec<Vec<(IconId, Point)>>

Log of every finalize_overlay_session call — the final positions committed to the Shell.

§next_commit_errors: VecDeque<DesktopError>

Queue of pending errors to return from the next commit_overlay_frame calls (one per call, in order). Populated by tests via FakeDesktop::queue_commit_error so the engine’s cancellation / error branches can be exercised deterministically.

Trait Implementations§

Source§

impl Debug for FakeDesktopInner

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for FakeDesktopInner

Source§

fn default() -> Self

Returns the “default value” for a type. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self> ⓘ

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self> ⓘ

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> ⓘ
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self> ⓘ

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more