WidgetExt::hide_on_delete useless in current form
sophie-h opened this issue · comments
fn hide_on_delete(&self) -> bool
should be connectable to
fn connect_delete_event<F: Fn(&Self, &Event) -> Inhibit + 'static>(
&self,
f: F
) -> SignalHandlerId
which doesn't work out that well.
Yes it should return an Inhibit
, needs a manual implementation for that. Do you want to create a PR?
As workaround for now you can do
window.connect_delete_event(|window| Inhibit(window.hide_on_delete(window)))
Actually, |window, _|
:)
I will have a look at the manual implementations tomorrow. Doesn't sound that complicated
Ok :) Let me know if you have questions