summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--core/src/widget.rs2
-rw-r--r--core/src/widget/tree.rs6
-rw-r--r--graphics/src/geometry/fill.rs2
-rw-r--r--graphics/src/geometry/stroke.rs2
-rw-r--r--graphics/src/geometry/style.rs2
-rw-r--r--graphics/src/gradient.rs2
-rw-r--r--runtime/src/lib.rs2
-rw-r--r--runtime/src/window.rs2
8 files changed, 10 insertions, 10 deletions
diff --git a/core/src/widget.rs b/core/src/widget.rs
index 0d12deba..b17215bb 100644
--- a/core/src/widget.rs
+++ b/core/src/widget.rs
@@ -96,7 +96,7 @@ where
Vec::new()
}
- /// Reconciliates the [`Widget`] with the provided [`Tree`].
+ /// Reconciles the [`Widget`] with the provided [`Tree`].
fn diff(&self, _tree: &mut Tree) {}
/// Applies an [`Operation`] to the [`Widget`].
diff --git a/core/src/widget/tree.rs b/core/src/widget/tree.rs
index 6b1a1309..2600cfc6 100644
--- a/core/src/widget/tree.rs
+++ b/core/src/widget/tree.rs
@@ -46,7 +46,7 @@ impl Tree {
}
}
- /// Reconciliates the current tree with the provided [`Widget`].
+ /// Reconciles the current tree with the provided [`Widget`].
///
/// If the tag of the [`Widget`] matches the tag of the [`Tree`], then the
/// [`Widget`] proceeds with the reconciliation (i.e. [`Widget::diff`] is called).
@@ -81,7 +81,7 @@ impl Tree {
);
}
- /// Reconciliates the children of the tree with the provided list of widgets using custom
+ /// Reconciles the children of the tree with the provided list of widgets using custom
/// logic both for diffing and creating new widget state.
pub fn diff_children_custom<T>(
&mut self,
@@ -107,7 +107,7 @@ impl Tree {
}
}
-/// Reconciliates the `current_children` with the provided list of widgets using
+/// Reconciles the `current_children` with the provided list of widgets using
/// custom logic both for diffing and creating new widget state.
///
/// The algorithm will try to minimize the impact of diffing by querying the
diff --git a/graphics/src/geometry/fill.rs b/graphics/src/geometry/fill.rs
index 670fbc12..b79a2582 100644
--- a/graphics/src/geometry/fill.rs
+++ b/graphics/src/geometry/fill.rs
@@ -7,7 +7,7 @@ use crate::core::Color;
use crate::gradient::{self, Gradient};
/// The style used to fill geometry.
-#[derive(Debug, Clone)]
+#[derive(Debug, Clone, Copy)]
pub struct Fill {
/// The color or gradient of the fill.
///
diff --git a/graphics/src/geometry/stroke.rs b/graphics/src/geometry/stroke.rs
index aff49ab3..b8f4515e 100644
--- a/graphics/src/geometry/stroke.rs
+++ b/graphics/src/geometry/stroke.rs
@@ -6,7 +6,7 @@ pub use crate::geometry::Style;
use iced_core::Color;
/// The style of a stroke.
-#[derive(Debug, Clone)]
+#[derive(Debug, Clone, Copy)]
pub struct Stroke<'a> {
/// The color or gradient of the stroke.
///
diff --git a/graphics/src/geometry/style.rs b/graphics/src/geometry/style.rs
index a0f4b08a..de77eccc 100644
--- a/graphics/src/geometry/style.rs
+++ b/graphics/src/geometry/style.rs
@@ -2,7 +2,7 @@ use crate::core::Color;
use crate::geometry::Gradient;
/// The coloring style of some drawing.
-#[derive(Debug, Clone, PartialEq)]
+#[derive(Debug, Clone, Copy, PartialEq)]
pub enum Style {
/// A solid [`Color`].
Solid(Color),
diff --git a/graphics/src/gradient.rs b/graphics/src/gradient.rs
index 603f1b4a..54261721 100644
--- a/graphics/src/gradient.rs
+++ b/graphics/src/gradient.rs
@@ -9,7 +9,7 @@ use bytemuck::{Pod, Zeroable};
use half::f16;
use std::cmp::Ordering;
-#[derive(Debug, Clone, PartialEq)]
+#[derive(Debug, Clone, Copy, PartialEq)]
/// A fill which linearly interpolates colors along a direction.
///
/// For a gradient which can be used as a fill for a background of a widget, see [`crate::core::Gradient`].
diff --git a/runtime/src/lib.rs b/runtime/src/lib.rs
index b4a5e819..7e46593a 100644
--- a/runtime/src/lib.rs
+++ b/runtime/src/lib.rs
@@ -60,7 +60,7 @@ pub enum Action<T> {
},
/// Run a widget operation.
- Widget(Box<dyn widget::Operation<()> + Send>),
+ Widget(Box<dyn widget::Operation<()>>),
/// Run a clipboard action.
Clipboard(clipboard::Action),
diff --git a/runtime/src/window.rs b/runtime/src/window.rs
index b04e5d59..3e53dd55 100644
--- a/runtime/src/window.rs
+++ b/runtime/src/window.rs
@@ -175,7 +175,7 @@ pub fn events() -> Subscription<(Id, Event)> {
/// Subscribes to all [`Event::Closed`] occurrences in the running application.
pub fn open_events() -> Subscription<Id> {
event::listen_with(|event, _status, id| {
- if let crate::core::Event::Window(Event::Closed) = event {
+ if let crate::core::Event::Window(Event::Opened { .. }) = event {
Some(id)
} else {
None