pub struct SCShareableContentOptions { /* private fields */ }Implementations§
Sourcepub fn with_exclude_desktop_windows(self, exclude: bool) -> Self
pub fn with_exclude_desktop_windows(self, exclude: bool) -> Self
Exclude desktop windows from the shareable content.
When set to true, desktop-level windows (like the desktop background)
are excluded from the returned window list.
Sourcepub fn with_on_screen_windows_only(self, on_screen_only: bool) -> Self
pub fn with_on_screen_windows_only(self, on_screen_only: bool) -> Self
Include only on-screen windows in the shareable content.
When set to true, only windows that are currently visible on screen
are included. Minimized or off-screen windows are excluded.
Sourcepub fn exclude_desktop_windows(self, exclude: bool) -> Self
👎Deprecated since 1.5.0: Use with_exclude_desktop_windows() instead
pub fn exclude_desktop_windows(self, exclude: bool) -> Self
Exclude desktop windows from the shareable content.
Sourcepub fn on_screen_windows_only(self, on_screen_only: bool) -> Self
👎Deprecated since 1.5.0: Use with_on_screen_windows_only() instead
pub fn on_screen_windows_only(self, on_screen_only: bool) -> Self
Include only on-screen windows in the shareable content.
Sourcepub fn get(self) -> Result<SCShareableContent, SCError>
pub fn get(self) -> Result<SCShareableContent, SCError>
Get shareable content synchronously
This blocks until the content is retrieved.
§Errors
Returns an error if screen recording permission is not granted or retrieval fails.
Sourcepub fn below_window(
self,
reference_window: &SCWindow,
) -> Result<SCShareableContent, SCError>
pub fn below_window( self, reference_window: &SCWindow, ) -> Result<SCShareableContent, SCError>
Get shareable content with only windows below a reference window
This returns windows that are stacked below the specified reference window in the window layering order.
§Arguments
reference_window- The window to use as the reference point
§Errors
Returns an error if screen recording permission is not granted or retrieval fails.
Sourcepub fn above_window(
self,
reference_window: &SCWindow,
) -> Result<SCShareableContent, SCError>
pub fn above_window( self, reference_window: &SCWindow, ) -> Result<SCShareableContent, SCError>
Get shareable content with only windows above a reference window
This returns windows that are stacked above the specified reference window in the window layering order.
§Arguments
reference_window- The window to use as the reference point
§Errors
Returns an error if screen recording permission is not granted or retrieval fails.
Trait Implementations§
Source§fn clone(&self) -> SCShareableContentOptions
fn clone(&self) -> SCShareableContentOptions
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more