diff options
| author | 2024-02-14 04:09:33 +0100 | |
|---|---|---|
| committer | 2024-02-14 04:09:33 +0100 | |
| commit | 75b19646d3d17b9b44bb495e239cbbc2d139c0e9 (patch) | |
| tree | bb6ef840b8b81367c83e1bc97150ae21e88d65e5 /examples/styling | |
| parent | 52e207b89bb79dba210c581b790f794e6e0c94e8 (diff) | |
| parent | 06973d31c6b7655f6f6fb0dfb17e621052b810e6 (diff) | |
| download | iced-75b19646d3d17b9b44bb495e239cbbc2d139c0e9.tar.gz iced-75b19646d3d17b9b44bb495e239cbbc2d139c0e9.tar.bz2 iced-75b19646d3d17b9b44bb495e239cbbc2d139c0e9.zip  | |
Merge pull request #2251 from iced-rs/borrow-pick-list-values
Use `Borrow` for both `options` and `selected` in `PickList`
Diffstat (limited to 'examples/styling')
| -rw-r--r-- | examples/styling/src/main.rs | 8 | 
1 files changed, 2 insertions, 6 deletions
diff --git a/examples/styling/src/main.rs b/examples/styling/src/main.rs index cf2dcb8a..c26215b6 100644 --- a/examples/styling/src/main.rs +++ b/examples/styling/src/main.rs @@ -55,12 +55,8 @@ impl Sandbox for Styling {      fn view(&self) -> Element<Message> {          let choose_theme = column![              text("Theme:"), -            pick_list( -                Theme::ALL, -                Some(self.theme.clone()), -                Message::ThemeChanged -            ) -            .width(Length::Fill), +            pick_list(Theme::ALL, Some(&self.theme), Message::ThemeChanged) +                .width(Length::Fill),          ]          .spacing(10);  | 
