diff options
Diffstat (limited to 'examples/qr_code')
| -rw-r--r-- | examples/qr_code/src/main.rs | 12 | 
1 files changed, 5 insertions, 7 deletions
| diff --git a/examples/qr_code/src/main.rs b/examples/qr_code/src/main.rs index d8041745..867ebfa4 100644 --- a/examples/qr_code/src/main.rs +++ b/examples/qr_code/src/main.rs @@ -49,13 +49,11 @@ impl Sandbox for QRGenerator {              .size(70)              .style(Color::from([0.5, 0.5, 0.5])); -        let input = text_input( -            "Type the data of your QR code here...", -            &self.data, -            Message::DataChanged, -        ) -        .size(30) -        .padding(15); +        let input = +            text_input("Type the data of your QR code here...", &self.data) +                .on_input(Message::DataChanged) +                .size(30) +                .padding(15);          let mut content = column![title, input]              .width(700) | 
