diff --git a/src/views/dialog.rs b/src/views/dialog.rs index 5e6e4b3..b686725 100644 --- a/src/views/dialog.rs +++ b/src/views/dialog.rs @@ -44,6 +44,8 @@ pub struct Dialog { align: Align, } +new_default!(Dialog); + impl Dialog { /// Creates a new `Dialog` with empty content. /// diff --git a/src/views/radio.rs b/src/views/radio.rs index d1a5741..2385ae4 100644 --- a/src/views/radio.rs +++ b/src/views/radio.rs @@ -50,8 +50,7 @@ impl RadioGroup { -> RadioButton { let count = self.state.borrow().values.len(); self.state.borrow_mut().values.push(Rc::new(value)); - let result = RadioButton::new(self.state.clone(), count, label.into()); - result + RadioButton::new(self.state.clone(), count, label.into()) } /// Returns the id of the selected button. @@ -78,7 +77,7 @@ impl RadioGroup { /// Variant of `Checkbox` arranged in group. /// -/// RadioButton are managed by a [`RadioGroup`]. A single group can contain +/// `RadioButton`s are managed by a [`RadioGroup`]. A single group can contain /// several radio buttons, but only one button per group can be active at a /// time. ///