diff options
author | 2022-02-11 22:07:21 +0700 | |
---|---|---|
committer | 2022-02-11 22:07:21 +0700 | |
commit | 01c5004959c9b11f2580840f4553ad7d706f4564 (patch) | |
tree | d3955f88244005d063d54dbfdb6d4db0cccc7dc7 /src/pure/application.rs | |
parent | 43a7ad72ef070929278e6d03d98077ac267fe2a6 (diff) | |
download | iced-01c5004959c9b11f2580840f4553ad7d706f4564.tar.gz iced-01c5004959c9b11f2580840f4553ad7d706f4564.tar.bz2 iced-01c5004959c9b11f2580840f4553ad7d706f4564.zip |
Allow pure widgets to borrow from `Application` data :tada:
Diffstat (limited to 'src/pure/application.rs')
-rw-r--r-- | src/pure/application.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/pure/application.rs b/src/pure/application.rs index 973af9f7..395eba9a 100644 --- a/src/pure/application.rs +++ b/src/pure/application.rs @@ -66,7 +66,7 @@ pub trait Application: Sized { /// Returns the widgets to display in the [`Application`]. /// /// These widgets can produce __messages__ based on user interaction. - fn view(&self) -> pure::Element<Self::Message>; + fn view(&self) -> pure::Element<'_, Self::Message>; /// Returns the current [`Application`] mode. /// @@ -126,7 +126,7 @@ pub trait Application: Sized { struct Instance<A: Application> { application: A, - state: pure::State<A::Message, crate::Renderer>, + state: pure::State, } impl<A> crate::Application for Instance<A> |