pub struct GraphicsCapturePicker;Expand description
Helper for prompting the user to pick a window or monitor using the system Graphics Capture Picker.
Implementations§
Source§impl GraphicsCapturePicker
impl GraphicsCapturePicker
Sourcepub fn pick_item() -> Result<Option<PickedGraphicsCaptureItem>, Error>
pub fn pick_item() -> Result<Option<PickedGraphicsCaptureItem>, Error>
Shows the system Graphics Capture Picker dialog and returns the chosen item.
A tiny, off-screen tool window is created as the picker owner and initialized
via IInitializeWithWindow. While the picker is visible, a minimal message
pump is run to keep the UI responsive.
§Returns
Ok(Some(PickedGraphicsCaptureItem))if the user selects a targetOk(None)if the picker completes without a result
§Errors
Error::Canceledwhen the user cancels the pickerError::WindowsErrorfor underlying Windows API failures
Auto Trait Implementations§
impl Freeze for GraphicsCapturePicker
impl RefUnwindSafe for GraphicsCapturePicker
impl Send for GraphicsCapturePicker
impl Sync for GraphicsCapturePicker
impl Unpin for GraphicsCapturePicker
impl UnsafeUnpin for GraphicsCapturePicker
impl UnwindSafe for GraphicsCapturePicker
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> 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