Fix clippy::default_trait_access
This commit is contained in:
parent
6c386e90a1
commit
42ed90bc6f
19 changed files with 30 additions and 28 deletions
|
|
@ -37,7 +37,7 @@ impl Application for Arc {
|
|||
(
|
||||
Arc {
|
||||
start: Instant::now(),
|
||||
cache: Default::default(),
|
||||
cache: Cache::default(),
|
||||
},
|
||||
Command::none(),
|
||||
)
|
||||
|
|
|
|||
|
|
@ -35,7 +35,7 @@ impl Application for Clock {
|
|||
Clock {
|
||||
now: time::OffsetDateTime::now_local()
|
||||
.unwrap_or_else(|_| time::OffsetDateTime::now_utc()),
|
||||
clock: Default::default(),
|
||||
clock: Cache::default(),
|
||||
},
|
||||
Command::none(),
|
||||
)
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@ impl Controls {
|
|||
pub fn new() -> Controls {
|
||||
Controls {
|
||||
background_color: Color::BLACK,
|
||||
text: Default::default(),
|
||||
text: String::default(),
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -27,7 +27,7 @@ impl Default for App {
|
|||
.into_iter()
|
||||
.map(From::from)
|
||||
.collect(),
|
||||
input: Default::default(),
|
||||
input: String::default(),
|
||||
order: Order::Ascending,
|
||||
}
|
||||
}
|
||||
|
|
@ -107,7 +107,7 @@ impl From<&str> for Item {
|
|||
fn from(s: &str) -> Self {
|
||||
Self {
|
||||
name: s.to_owned(),
|
||||
color: Default::default(),
|
||||
color: Color::default(),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -228,7 +228,9 @@ mod modal {
|
|||
use iced::alignment::Alignment;
|
||||
use iced::event;
|
||||
use iced::mouse;
|
||||
use iced::{Color, Element, Event, Length, Point, Rectangle, Size};
|
||||
use iced::{
|
||||
BorderRadius, Color, Element, Event, Length, Point, Rectangle, Size,
|
||||
};
|
||||
|
||||
/// A widget that centers a modal element over some base element
|
||||
pub struct Modal<'a, Message, Renderer> {
|
||||
|
|
@ -474,7 +476,7 @@ mod modal {
|
|||
renderer.fill_quad(
|
||||
renderer::Quad {
|
||||
bounds: layout.bounds(),
|
||||
border_radius: Default::default(),
|
||||
border_radius: BorderRadius::default(),
|
||||
border_width: 0.0,
|
||||
border_color: Color::TRANSPARENT,
|
||||
},
|
||||
|
|
|
|||
|
|
@ -391,12 +391,12 @@ impl scrollable::StyleSheet for ScrollbarCustomStyle {
|
|||
.background,
|
||||
border_radius: 2.0.into(),
|
||||
border_width: 0.0,
|
||||
border_color: Default::default(),
|
||||
border_color: Color::default(),
|
||||
scroller: Scroller {
|
||||
color: Color::from_rgb8(250, 85, 134),
|
||||
border_radius: 2.0.into(),
|
||||
border_width: 0.0,
|
||||
border_color: Default::default(),
|
||||
border_color: Color::default(),
|
||||
},
|
||||
}
|
||||
} else {
|
||||
|
|
|
|||
|
|
@ -117,8 +117,8 @@ impl State {
|
|||
let (width, height) = window::Settings::default().size;
|
||||
|
||||
State {
|
||||
space_cache: Default::default(),
|
||||
system_cache: Default::default(),
|
||||
space_cache: canvas::Cache::default(),
|
||||
system_cache: canvas::Cache::default(),
|
||||
start: now,
|
||||
now,
|
||||
stars: Self::generate_stars(width, height),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue