This commit is contained in:
amrbashir 2024-10-25 15:52:22 +03:00
parent c0d529a836
commit 5c1b613b39
No known key found for this signature in database
GPG Key ID: BBD7A47A2003FF33
1 changed files with 12 additions and 11 deletions

View File

@ -656,17 +656,6 @@ impl<'a, R: Runtime, M: Manager<R>> WindowBuilder<'a, R, M> {
self self
} }
/// Set the window and webview background color.
///
/// ## Platform-specific:
///
/// - **Windows**: alpha channel is ignored.
#[must_use]
pub fn background_color(mut self, color: Color) -> Self {
self.window_builder = self.window_builder.background_color(color);
self
}
/// Sets a parent to the window to be created. /// Sets a parent to the window to be created.
/// ///
/// ## Platform-specific /// ## Platform-specific
@ -846,6 +835,18 @@ impl<'a, R: Runtime, M: Manager<R>> WindowBuilder<'a, R, M> {
} }
} }
impl<'a, R: Runtime, M: Manager<R>> WindowBuilder<'a, R, M> {
/// Set the window and webview background color.
///
/// ## Platform-specific:
///
/// - **Windows**: alpha channel is ignored.
#[must_use]
pub fn background_color(mut self, color: Color) -> Self {
self.window_builder = self.window_builder.background_color(color);
self
}
}
/// A wrapper struct to hold the window menu state /// A wrapper struct to hold the window menu state
/// and whether it is global per-app or specific to this window. /// and whether it is global per-app or specific to this window.
#[cfg(desktop)] #[cfg(desktop)]