summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLibravatar Héctor Ramón Jiménez <hector0193@gmail.com>2022-08-17 16:09:25 +0200
committerLibravatar Héctor Ramón Jiménez <hector0193@gmail.com>2022-08-17 16:09:25 +0200
commitb0705d2f4c06c13bcc4397ae1d4f29264c3e08c2 (patch)
tree5d5d707d4b44481e0c19e7d260176b529af62cda
parent4425839aa421a80a8a0612ee2e15ece57b2c62b9 (diff)
downloadiced-b0705d2f4c06c13bcc4397ae1d4f29264c3e08c2.tar.gz
iced-b0705d2f4c06c13bcc4397ae1d4f29264c3e08c2.tar.bz2
iced-b0705d2f4c06c13bcc4397ae1d4f29264c3e08c2.zip
Fix latest `clippy` lints
-rw-r--r--core/src/keyboard/event.rs2
-rw-r--r--core/src/length.rs2
-rw-r--r--core/src/size.rs2
-rw-r--r--core/src/vector.rs2
-rw-r--r--native/src/event.rs4
-rw-r--r--native/src/window/event.rs2
6 files changed, 7 insertions, 7 deletions
diff --git a/core/src/keyboard/event.rs b/core/src/keyboard/event.rs
index 38777536..016761af 100644
--- a/core/src/keyboard/event.rs
+++ b/core/src/keyboard/event.rs
@@ -6,7 +6,7 @@ use super::{KeyCode, Modifiers};
/// additional events, feel free to [open an issue] and share your use case!_
///
/// [open an issue]: https://github.com/iced-rs/iced/issues
-#[derive(Debug, Clone, Copy, PartialEq)]
+#[derive(Debug, Clone, Copy, PartialEq, Eq)]
pub enum Event {
/// A keyboard key was pressed.
KeyPressed {
diff --git a/core/src/length.rs b/core/src/length.rs
index 186411a5..95ea6e0e 100644
--- a/core/src/length.rs
+++ b/core/src/length.rs
@@ -1,5 +1,5 @@
/// The strategy used to fill space in a specific dimension.
-#[derive(Debug, Clone, Copy, PartialEq, Hash)]
+#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)]
pub enum Length {
/// Fill all the remaining space
Fill,
diff --git a/core/src/size.rs b/core/src/size.rs
index 6745c6c8..2db33a88 100644
--- a/core/src/size.rs
+++ b/core/src/size.rs
@@ -2,7 +2,7 @@ use crate::{Padding, Vector};
use std::f32;
/// An amount of space in 2 dimensions.
-#[derive(Debug, Clone, Copy, PartialEq)]
+#[derive(Debug, Clone, Copy, PartialEq, Eq)]
pub struct Size<T = f32> {
/// The width.
pub width: T,
diff --git a/core/src/vector.rs b/core/src/vector.rs
index 92bb7648..b550869c 100644
--- a/core/src/vector.rs
+++ b/core/src/vector.rs
@@ -1,5 +1,5 @@
/// A 2D vector.
-#[derive(Debug, Clone, Copy, PartialEq)]
+#[derive(Debug, Clone, Copy, PartialEq, Eq)]
pub struct Vector<T = f32> {
/// The X component of the [`Vector`]
pub x: T,
diff --git a/native/src/event.rs b/native/src/event.rs
index 27540a25..bcfaf891 100644
--- a/native/src/event.rs
+++ b/native/src/event.rs
@@ -29,14 +29,14 @@ pub enum Event {
}
/// A platform specific event
-#[derive(Debug, Clone, PartialEq)]
+#[derive(Debug, Clone, PartialEq, Eq)]
pub enum PlatformSpecific {
/// A MacOS specific event
MacOS(MacOS),
}
/// Describes an event specific to MacOS
-#[derive(Debug, Clone, PartialEq)]
+#[derive(Debug, Clone, PartialEq, Eq)]
pub enum MacOS {
/// Triggered when the app receives an URL from the system
///
diff --git a/native/src/window/event.rs b/native/src/window/event.rs
index 691af29a..86321ac0 100644
--- a/native/src/window/event.rs
+++ b/native/src/window/event.rs
@@ -1,7 +1,7 @@
use std::path::PathBuf;
/// A window-related event.
-#[derive(PartialEq, Clone, Debug)]
+#[derive(PartialEq, Eq, Clone, Debug)]
pub enum Event {
/// A window was moved.
Moved {