chore: Fix several style lints (#17488)
It's not comprehensive enough to start linting on `style` group, but hey, it's a start. Release Notes: - N/A
This commit is contained in:
@@ -18,9 +18,8 @@ pub fn window_appearance(cx: &WindowContext) -> WindowBackgroundAppearance {
|
||||
/// Helps determine if you need to take extra steps to prevent
|
||||
/// transparent backgrounds.
|
||||
pub fn window_is_transparent(cx: &WindowContext) -> bool {
|
||||
match window_appearance(cx) {
|
||||
WindowBackgroundAppearance::Transparent => true,
|
||||
WindowBackgroundAppearance::Blurred => true,
|
||||
_ => false,
|
||||
}
|
||||
matches!(
|
||||
window_appearance(cx),
|
||||
WindowBackgroundAppearance::Transparent | WindowBackgroundAppearance::Blurred
|
||||
)
|
||||
}
|
||||
|
||||
@@ -9,9 +9,9 @@ pub enum Elevation {
|
||||
ElementIndex(ElementIndex),
|
||||
}
|
||||
|
||||
impl Into<Elevation> for ElevationIndex {
|
||||
fn into(self) -> Elevation {
|
||||
Elevation::ElevationIndex(self)
|
||||
impl From<ElevationIndex> for Elevation {
|
||||
fn from(val: ElevationIndex) -> Self {
|
||||
Elevation::ElevationIndex(val)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user