Use SmolStr for text field in KeyPressed event

This commit is contained in:
Héctor Ramón Jiménez 2024-01-16 13:31:02 +01:00
parent 64d1ce5532
commit 03f5a351c3
No known key found for this signature in database
GPG key ID: 7CC46565708259A7
4 changed files with 6 additions and 5 deletions

View file

@ -225,9 +225,7 @@ pub fn window_event(
key,
modifiers,
location,
text: text
.as_ref()
.map(winit::keyboard::SmolStr::to_string),
text,
}
}
winit::event::ElementState::Released => {