Skip to main content

PathTargetInfoExt

Trait PathTargetInfoExt 

Source
pub trait PathTargetInfoExt {
    // Required methods
    fn target_mode_idx(&self, path_support_virtual_mode: bool) -> Option<usize>;
    fn desktop_mode_idx(&self, path_support_virtual_mode: bool) -> Option<usize>;
    fn set_target_mode_idx(
        &mut self,
        idx: Option<usize>,
        path_support_virtual_mode: bool,
    );
    fn set_desktop_mode_idx(
        &mut self,
        idx: Option<usize>,
        path_support_virtual_mode: bool,
    );
}
Expand description

Convenience extension methods for DISPLAYCONFIG_PATH_TARGET_INFO.

Required Methods§

Source

fn target_mode_idx(&self, path_support_virtual_mode: bool) -> Option<usize>

Obtains the target mode index.

It handles the bits, including testing against DISPLAYCONFIG_PATH_TARGET_MODE_IDX_INVALID or DISPLAYCONFIG_PATH_MODE_IDX_INVALID appropriately.

Source

fn desktop_mode_idx(&self, path_support_virtual_mode: bool) -> Option<usize>

Obtains the desktop mode id.

Source

fn set_target_mode_idx( &mut self, idx: Option<usize>, path_support_virtual_mode: bool, )

Sets the target mode index.

It handles the bits, including using DISPLAYCONFIG_PATH_TARGET_MODE_IDX_INVALID or DISPLAYCONFIG_PATH_MODE_IDX_INVALID appropriately.

Source

fn set_desktop_mode_idx( &mut self, idx: Option<usize>, path_support_virtual_mode: bool, )

Sets the desktop mode id.

It panics if path_support_virtual_mode is false and id is not None.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§