diff --git a/CHANGELOG.md b/CHANGELOG.md index dd0db09b..c525ac40 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -24,6 +24,11 @@ - On X11, generate synthetic key events for keys held when a window gains or loses focus. - On X11, issue a `CursorMoved` event when a `Touch` event occurs, as X11 implicitly moves the cursor for such events. +- Changes to the `RedrawRequested` event (#1041): + - `RedrawRequested` has been moved from `WindowEvent` to `Event`. + - `EventsCleared` has been renamed to `MainEventsCleared`. + - `RedrawRequested` is now issued only after `MainEventsCleared`. + - `RedrawEventsCleared` is issued after each set of `RedrawRequested` events. # 0.20.0 Alpha 4 (2019-10-18) @@ -100,11 +105,6 @@ - On iOS, fix DPI sent out by views on creation was `0.0` - now it gives a reasonable number. - On iOS, RedrawRequested now works for gl/metal backed views. - On iOS, RedrawRequested is generally ordered after EventsCleared. -- Changes to the `RedrawRequested` event (#1041): - - `RedrawRequested` has been moved from `WindowEvent` to `Event`. - - `EventsCleared` has been renamed to `MainEventsCleared`. - - `RedrawRequested` is now issued only after `MainEventsCleared`. - - `RedrawEventsCleared` is issued after each set of `RedrawRequested` events. # 0.20.0 Alpha 2 (2019-07-09) diff --git a/examples/window_run_return.rs b/examples/window_run_return.rs index 5096ef31..05f50e9d 100644 --- a/examples/window_run_return.rs +++ b/examples/window_run_return.rs @@ -40,7 +40,7 @@ fn main() { quit = true; *control_flow = ControlFlow::Exit; } - Event::EventsCleared => { + Event::MainEventsCleared => { *control_flow = ControlFlow::Exit; } _ => *control_flow = ControlFlow::Wait, diff --git a/src/event_loop.rs b/src/event_loop.rs index 146412cd..105af242 100644 --- a/src/event_loop.rs +++ b/src/event_loop.rs @@ -59,7 +59,7 @@ impl fmt::Debug for EventLoopWindowTarget { /// Set by the user callback given to the `EventLoop::run` method. /// -/// Indicates the desired behavior of the event loop after [`Event::EventsCleared`][events_cleared] +/// Indicates the desired behavior of the event loop after [`Event::RedrawEventsCleared`][events_cleared] /// is emitted. Defaults to `Poll`. /// /// ## Persistency @@ -68,7 +68,7 @@ impl fmt::Debug for EventLoopWindowTarget { /// are **not** persistent between multiple calls to `run_return` - issuing a new call will reset /// the control flow to `Poll`. /// -/// [events_cleared]: crate::event::Event::EventsCleared +/// [events_cleared]: crate::event::Event::RedrawEventsCleared #[derive(Copy, Clone, Debug, PartialEq, Eq)] pub enum ControlFlow { /// When the current loop iteration finishes, immediately begin a new iteration regardless of