EpisodeView: Implement initial view update.

This commit is contained in:
Jordan Petridis 2017-12-20 13:13:32 +02:00
parent 914cad72f5
commit 632f011db5
No known key found for this signature in database
GPG Key ID: CEABAD9F5683B9A6
2 changed files with 12 additions and 1 deletions

View File

@ -173,6 +173,16 @@ impl EpisodeStack {
}
fn update(&self) {
// unimplemented!()
// FIXME: figure out if it should switch to empty view
let vis = self.stack.get_visible_child_name().unwrap();
let old = self.stack.get_child_by_name("episodes").unwrap();
let eps = EpisodesView::new();
self.stack.remove(&old);
self.stack.add_named(&eps.container, "episodes");
self.stack.set_visible_child_name(&vis);
old.destroy();
}
}

View File

@ -57,6 +57,7 @@ impl EpisodesView {
sep.show()
});
view.container.show_all();
Rc::new(view)
}
}