Use ToString for Text::new instead of Into<String>

This commit is contained in:
Héctor Ramón Jiménez 2022-07-27 06:56:09 +02:00
parent ff2519b1d4
commit a1c5f8839d
No known key found for this signature in database
GPG key ID: 140CC052C94F138E
5 changed files with 13 additions and 12 deletions

View file

@ -40,7 +40,7 @@ impl Sandbox for Counter {
fn view(&self) -> Element<Message> {
column![
button("Increment").on_press(Message::IncrementPressed),
text(self.value.to_string()).size(50),
text(self.value).size(50),
button("Decrement").on_press(Message::DecrementPressed)
]
.padding(20)