diff --git a/source/ubinstall-gtk.c b/source/ubinstall-gtk.c index bf2cbf8..697503e 100644 --- a/source/ubinstall-gtk.c +++ b/source/ubinstall-gtk.c @@ -234,8 +234,8 @@ int yon_image_resize_from_container(GtkImage *target, GdkPixbuf *pixbuf_unscaled int width = gtk_widget_get_allocated_width(gtk_widget_get_parent(gtk_widget_get_parent(GTK_WIDGET(target)))); int height = gtk_widget_get_allocated_height(gtk_widget_get_parent(gtk_widget_get_parent(GTK_WIDGET(target)))); - int newImgWidthDef = (width <= 217) ? width : width - 217; - int newImgHeightDef = (height <= 120) ? height : height - 217; + int newImgWidthDef = (width <= 50) ? width : width - 50; + int newImgHeightDef = (height <= 50) ? height : height - 30; GdkPixbuf *pixBuf = pixbuf_unscaled; int newImgHeight = (int)(gdk_pixbuf_get_height(pixBuf) / ((double) gdk_pixbuf_get_width(pixBuf) / newImgWidthDef)); if (newImgHeight > newImgHeightDef) { @@ -251,19 +251,9 @@ int yon_image_resize_from_container(GtkImage *target, GdkPixbuf *pixbuf_unscaled void on_region_resized(GtkWidget *,main_window *widgets); void on_region_resized(GtkWidget *,main_window *widgets){ - int page = gtk_notebook_get_current_page(GTK_NOTEBOOK(widgets->Notebook)); - switch(page){ - case YON_PAGE_INSTALLATION: { yon_image_resize_from_container(GTK_IMAGE(widgets->SlidesImage), widgets->slides_original); - } break; - case YON_PAGE_REGION: { yon_image_resize_from_container(GTK_IMAGE(widgets->RegionImage), widgets->regions_original); - - } break; - case YON_PAGE_KEYBOARD: { yon_image_resize_from_container(GTK_IMAGE(widgets->KeyboardImage), widgets->keyboard_original); - } break; - } } void on_toggle_block(GtkToggleButton *self); @@ -656,7 +646,7 @@ void on_page_navigation_clicked(GtkWidget *self, main_window *widgets){ char *device_name = (char*)gtk_entry_get_text(GTK_ENTRY(widgets->NextInstallationSectionNameEntry)); char *part; gtk_tree_model_get(model,&iter,0,&part,-1); - yon_config_register(AUTOINSTALL_TYPE_INSTALL,AUTOINSTALL_TYPE_INSTALL_command,"part"); + yon_config_register(AUTOINSTALL_TYPE_INSTALL,AUTOINSTALL_TYPE_INSTALL_command,"next"); yon_config_register(AUTOINSTALL_DEVICE,AUTOINSTALL_DEVICE_command,device); yon_config_register(AUTOSTART_PARTS,AUTOSTART_PARTS_command,part); yon_config_register(device_label_parameter,device_label_parameter_command,device_name); @@ -694,7 +684,7 @@ void on_page_navigation_clicked(GtkWidget *self, main_window *widgets){ char *device_name = (char*)gtk_entry_get_text(GTK_ENTRY(widgets->SameInstallationSectionNameEntry)); char *part; gtk_tree_model_get(model,&iter,0,&part,-1); - yon_config_register(AUTOINSTALL_TYPE_INSTALL,AUTOINSTALL_TYPE_INSTALL_command,"next"); + yon_config_register(AUTOINSTALL_TYPE_INSTALL,AUTOINSTALL_TYPE_INSTALL_command,"part"); yon_config_register(AUTOINSTALL_DEVICE,AUTOINSTALL_DEVICE_command,device); yon_config_register(AUTOSTART_PARTS,AUTOSTART_PARTS_command,part); yon_config_register(device_label_parameter,device_label_parameter_command,device_name);