Changed the flowbox cover and banners size to 256x256 px.

This commit is contained in:
Jordan Petridis
2017-11-03 09:28:44 +02:00
parent 79fb8c2290
commit 02ae6b4aef
5 changed files with 13 additions and 9 deletions
+1 -1
View File
@@ -43,7 +43,7 @@ fn build_ui(app: &gtk::Application) {
// Get the main window
let window = gtk::ApplicationWindow::new(app);
window.set_default_size(1050, 600);
window.set_default_size(1150, 650);
// Setup the Stack that will manage the switch between podcasts_view and podcast_widget.
let stack = podcasts_view::setup_stack(&db);
window.add(&stack);
+2 -2
View File
@@ -150,7 +150,7 @@ pub fn create_flowbox_child(db: &Database, pd: &Podcast) -> gtk::FlowBoxChild {
}
fn configure_banner(db: &Database, pd: &Podcast, banner: &gtk::Image, banner_title: &gtk::Label) {
let bann = Pixbuf::new_from_file_at_scale("assets/banner.png", 100, 100, true);
let bann = Pixbuf::new_from_file_at_scale("assets/banner.png", 256, 256, true);
if let Ok(b) = bann {
banner.set_from_pixbuf(&b);
@@ -186,7 +186,7 @@ pub fn on_flowbox_child_activate(db: &Database, stack: &gtk::Stack, parent: &Pod
fn get_pixbuf_from_path(img_path: Option<&str>, pd_title: &str) -> Option<Pixbuf> {
let img_path = downloader::cache_image(pd_title, img_path);
if let Some(i) = img_path {
Pixbuf::new_from_file_at_scale(&i, 200, 200, true).ok()
Pixbuf::new_from_file_at_scale(&i, 256, 256, true).ok()
} else {
None
}