Fix Message type to Never in UpdateFn for ()
This commit is contained in:
parent
92d08bcc10
commit
31fcaccf7d
4 changed files with 11 additions and 9 deletions
|
|
@ -36,8 +36,8 @@ use crate::shell;
|
|||
use crate::theme;
|
||||
use crate::window;
|
||||
use crate::{
|
||||
Element, Executor, Font, Preset, Result, Settings, Size, Subscription,
|
||||
Task, Theme,
|
||||
Element, Executor, Font, Never, Preset, Result, Settings, Size,
|
||||
Subscription, Task, Theme,
|
||||
};
|
||||
|
||||
use iced_debug as debug;
|
||||
|
|
@ -600,8 +600,8 @@ pub trait UpdateFn<State, Message> {
|
|||
fn update(&self, state: &mut State, message: Message) -> Task<Message>;
|
||||
}
|
||||
|
||||
impl<State, Message> UpdateFn<State, Message> for () {
|
||||
fn update(&self, _state: &mut State, _message: Message) -> Task<Message> {
|
||||
impl<State> UpdateFn<State, Never> for () {
|
||||
fn update(&self, _state: &mut State, _message: Never) -> Task<Never> {
|
||||
Task::none()
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -533,8 +533,9 @@ pub use crate::core::padding;
|
|||
pub use crate::core::theme;
|
||||
pub use crate::core::{
|
||||
Alignment, Animation, Background, Border, Color, ContentFit, Degrees,
|
||||
Function, Gradient, Length, Padding, Pixels, Point, Radians, Rectangle,
|
||||
Rotation, Settings, Shadow, Size, Theme, Transformation, Vector, never,
|
||||
Function, Gradient, Length, Never, Padding, Pixels, Point, Radians,
|
||||
Rectangle, Rotation, Settings, Shadow, Size, Theme, Transformation, Vector,
|
||||
never,
|
||||
};
|
||||
pub use crate::program::Preset;
|
||||
pub use crate::program::message;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue