summaryrefslogtreecommitdiffstats
path: root/examples/solar_system/src
diff options
context:
space:
mode:
authorLibravatar Héctor Ramón <hector0193@gmail.com>2023-01-13 20:33:59 +0100
committerLibravatar GitHub <noreply@github.com>2023-01-13 20:33:59 +0100
commit597af315af714f3ecadd195516e80506504dcb26 (patch)
tree200d0447efc60c9066b762c9f1a00ce55d66def7 /examples/solar_system/src
parentd2b66805b350b4bd2ca5cb2818a6c05e3cfb5235 (diff)
parent507820a8438cec25074f92b72e118e0931fa7f9f (diff)
downloadiced-597af315af714f3ecadd195516e80506504dcb26.tar.gz
iced-597af315af714f3ecadd195516e80506504dcb26.tar.bz2
iced-597af315af714f3ecadd195516e80506504dcb26.zip
Merge pull request #1647 from iced-rs/feature/widget-request-redraw
Widget-driven animations
Diffstat (limited to 'examples/solar_system/src')
-rw-r--r--examples/solar_system/src/main.rs3
1 files changed, 1 insertions, 2 deletions
diff --git a/examples/solar_system/src/main.rs b/examples/solar_system/src/main.rs
index 9e303576..9a4ee754 100644
--- a/examples/solar_system/src/main.rs
+++ b/examples/solar_system/src/main.rs
@@ -9,7 +9,6 @@
use iced::application;
use iced::executor;
use iced::theme::{self, Theme};
-use iced::time;
use iced::widget::canvas;
use iced::widget::canvas::gradient::{self, Gradient};
use iced::widget::canvas::stroke::{self, Stroke};
@@ -90,7 +89,7 @@ impl Application for SolarSystem {
}
fn subscription(&self) -> Subscription<Message> {
- time::every(time::Duration::from_millis(10)).map(Message::Tick)
+ window::frames().map(Message::Tick)
}
}