#[non_exhaustive]pub struct WindowSummary {Show 13 fields
pub id: WindowId,
pub title: String,
pub title_prefix: Option<String>,
pub is_focused: bool,
pub is_last_focused: bool,
pub state: WindowState,
pub window_type: Option<WindowType>,
pub incognito: bool,
pub width: Option<u32>,
pub height: Option<u32>,
pub left: Option<i32>,
pub top: Option<i32>,
pub tabs: Vec<TabSummary>,
}Expand description
A summary of a browser window including its tabs.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.id: WindowIdThe window’s unique identifier within the browser.
title: StringThe full window title as displayed in the title bar.
title_prefix: Option<String>An optional prefix prepended to the window title (Firefox-only, via titlePreface).
is_focused: boolWhether this window currently has input focus.
is_last_focused: boolWhether this is the most recently focused window.
This differs from is_focused when no window currently has OS-level focus
(e.g. all browser windows are on an inactive Wayland workspace). Firefox tracks
last-focused state internally and uses it as the fallback target when creating
a tab without a specific window.
state: WindowStateThe current visual state of the window.
window_type: Option<WindowType>The type of this window (normal, popup, panel, devtools).
incognito: boolWhether this window is in private/incognito mode.
width: Option<u32>Window width in pixels.
height: Option<u32>Window height in pixels.
left: Option<i32>Left edge of the window in pixels from the screen left.
May be negative on multi-monitor setups where a monitor is to the left of the primary monitor’s origin.
top: Option<i32>Top edge of the window in pixels from the screen top.
May be negative on multi-monitor setups where a monitor is above the primary monitor’s origin.
tabs: Vec<TabSummary>Brief summaries of the tabs open in this window.
Implementations§
Source§impl WindowSummary
impl WindowSummary
Sourcepub const fn new(
id: WindowId,
title: String,
title_prefix: Option<String>,
is_focused: bool,
is_last_focused: bool,
state: WindowState,
window_type: Option<WindowType>,
incognito: bool,
width: Option<u32>,
height: Option<u32>,
left: Option<i32>,
top: Option<i32>,
tabs: Vec<TabSummary>,
) -> Self
pub const fn new( id: WindowId, title: String, title_prefix: Option<String>, is_focused: bool, is_last_focused: bool, state: WindowState, window_type: Option<WindowType>, incognito: bool, width: Option<u32>, height: Option<u32>, left: Option<i32>, top: Option<i32>, tabs: Vec<TabSummary>, ) -> Self
Create a new WindowSummary.
Trait Implementations§
Source§impl Clone for WindowSummary
impl Clone for WindowSummary
Source§fn clone(&self) -> WindowSummary
fn clone(&self) -> WindowSummary
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more