Helper struct to reduce function argument count.
| 14 | |
| 15 | /// Helper struct to reduce function argument count. |
| 16 | pub struct ButtonData<'a, Message: 'a + Clone> { |
| 17 | /// The [`State`](button::State) of the [`Button`](Button). |
| 18 | pub state: &'a mut button::State, |
| 19 | /// The icon of the [`Button`](Button). |
| 20 | pub icon: Icon, |
| 21 | /// The text of the [`Button`](Button). |
| 22 | pub text: &'a str, |
| 23 | /// The kind of a [`Button`](Button). |
| 24 | pub kind: ButtonKind, |
| 25 | /// The optional message that is send by the [`Button`](Button). |
| 26 | pub on_press: Option<Message>, |
| 27 | } |
| 28 | |
| 29 | impl<'a, Message: 'a + Clone> ButtonData<'a, Message> { |
| 30 | /// Create the element containing only the icon. |
nothing calls this directly
no outgoing calls
no test coverage detected