sliding_view: Unparent all children on dispose
This is something all GtkWidget subclasses are supposed to do with all direct children.
This commit is contained in:
parent
d6fc93df6c
commit
34b3fb12de
1 changed files with 7 additions and 0 deletions
|
|
@ -137,6 +137,13 @@ mod imp {
|
|||
|
||||
obj.add_controller(scroll_controller);
|
||||
}
|
||||
|
||||
fn dispose(&self) {
|
||||
let obj = self.obj();
|
||||
while let Some(child) = obj.first_child() {
|
||||
child.unparent();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
impl WidgetImpl for LpSlidingView {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue