diff --git a/CHANGELOG.md b/CHANGELOG.md index 94f08d8..d3ee39f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -34,6 +34,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - `Window::focused` now accepts an `IntoValue` implementor instead of `IntoDynamic`. Additionally, the initial value is now used to control whether the OS should initially activate the window when it is opened. +- `WrapperWidget::root_behavior`'s provided implementation now returns + `Some(RootBehavior::PassThrough)` to reflect the general intention of what + `WrapperWidget` implementors are generally doing. Previously, `None` was + returned. ### Changed diff --git a/src/widget.rs b/src/widget.rs index 17c7331..007957e 100644 --- a/src/widget.rs +++ b/src/widget.rs @@ -532,9 +532,13 @@ pub trait WrapperWidget: Debug + Send + 'static { /// Returns the behavior this widget should apply when positioned at the /// root of the window. + /// + /// The provided implementation for `WrapperWidget` returns + /// [`RootBehavior::PassThrough`]. This is different from the provided + /// implementation for [`Widget`]. #[allow(unused_variables)] fn root_behavior(&mut self, context: &mut EventContext<'_>) -> Option { - None + Some(RootBehavior::PassThrough) } /// Draws the background of the widget.