Commit c85e1b6d25 added a workaround for a
winit issue, which has been fixed upstream. Until a new release is
available, let's patch in winit from a branch that has the fix
cherry-picked.
This way we don't have to remember to remove the workaround with the
next update and this has been verified on the device.
I only tested on X11 plasma, and there this doesn't have any effect,
But this might be needed because i removed it a few commit ago in another
function.
I think the reason it is there is that it allow changing from a fixed size
to a custom size
When a second canvas is visible, only animations in the first canvas
resulted in updates and visible animation. An animation in the second
canvas wouldn't result in repaints.
When we start an animation, we request a redraw on all windows and
return with `ControlFlow::Poll` to winit.
Winit then schedules an animation frame request, and in the callback the
redraw request events are delivered. For the first window we call
`update_animations()`, a new tick is detected (different than the
previous one) and animated properties are dirty and yield new windows.
Then right away we get called again with a redraw request for the second
window. update_animations() determines that the instant::now() is the
same, and has_animations() returns false. So at the end of the event
handler we return fail to return `Poll` and therefore no animation frame
request is created, which means the animations just stop.
Fix this by calling update_animations() only once, when all input events
have been processed and the redraw events are up for delivery next.
This is visible in the preview canvases in the documentation, if a
canvas other than the first has animations.
cc #215
Handle Input event from the input directly instead of going through winit
for the TextInput.
Note that this doesn't handle the composition event well, so the text is
only considered written when it is accepted
When "combining" information from winit's ReceiveCharacter and
KeyboardInput events, then do not create a second KeyPress event
when the KeyboardInput contained a control character.
This makes us not send duplicate events for `Tab`, but leaves the
handling for e.g. `Ctrl-C` unchanged.
The README.md contains the warning that used to be in lib.rs.
Add README.md files to all internal crates
... pointing to the official public crate to use instead.
Rename internal crates
fixup: README files
fixup rename