Skip to content

Commit

Permalink
fix clippy::pedantic lint
Browse files Browse the repository at this point in the history
  • Loading branch information
GyulyVGC committed Nov 22, 2024
1 parent d36d3b4 commit 9b071e5
Showing 1 changed file with 2 additions and 7 deletions.
9 changes: 2 additions & 7 deletions src/gui/styles/scrollbar.rs
Original file line number Diff line number Diff line change
Expand Up @@ -50,17 +50,12 @@ impl ScrollbarType {
}

#[allow(clippy::unused_self)]
fn hovered(
&self,
style: &StyleType,
is_mouse_over_x_scrollbar: bool,
is_mouse_over_y_scrollbar: bool,
) -> Style {
fn hovered(&self, style: &StyleType, is_mouse_over_x: bool, is_mouse_over_y: bool) -> Style {
let colors = style.get_palette();
let ext = style.get_extension();

let [horizontal_rail, vertical_rail] =
[is_mouse_over_x_scrollbar, is_mouse_over_y_scrollbar].map(|is_over| Rail {
[is_mouse_over_x, is_mouse_over_y].map(|is_over| Rail {
background: Some(Background::Color(Color {
a: ext.alpha_round_borders,
..ext.buttons_color
Expand Down

0 comments on commit 9b071e5

Please sign in to comment.