Mercurial > geeqie
changeset 837:f8c22438376c
use GtkSizeGroup to control initial size of split images
author | nadvornik |
---|---|
date | Sat, 14 Jun 2008 21:49:48 +0000 |
parents | 1af95bada7e7 |
children | 9bd49e725ad3 |
files | src/layout.c src/layout_image.c src/typedefs.h |
diffstat | 3 files changed, 8 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/src/layout.c Sat Jun 14 18:41:30 2008 +0000 +++ b/src/layout.c Sat Jun 14 21:49:48 2008 +0000 @@ -1809,6 +1809,8 @@ layout_bars_close(lw); gtk_widget_destroy(lw->window); + + if (lw->split_image_sizegroup) g_object_unref(lw->split_image_sizegroup); file_data_unregister_notify_func(layout_image_notify_cb, lw);
--- a/src/layout_image.c Sat Jun 14 18:41:30 2008 +0000 +++ b/src/layout_image.c Sat Jun 14 21:49:48 2008 +0000 @@ -1764,6 +1764,8 @@ GtkWidget *layout_image_new(LayoutWindow *lw, gint i) { + if (!lw->split_image_sizegroup) lw->split_image_sizegroup = gtk_size_group_new(GTK_SIZE_GROUP_BOTH); + if (!lw->split_images[i]) { lw->split_images[i] = image_new(TRUE); @@ -1780,6 +1782,8 @@ options->color_profile.screen_type, options->color_profile.use_image); image_color_profile_set_use(lw->split_images[i], options->color_profile.enabled); + + gtk_size_group_add_widget(lw->split_image_sizegroup, lw->split_images[i]->widget); } return lw->split_images[i]->widget; @@ -1875,7 +1879,7 @@ { GtkWidget *paned; gint i; - + lw->split_mode = horizontal ? SPLIT_HOR : SPLIT_VERT; if (!lw->split_images[0]) @@ -1934,7 +1938,6 @@ gtk_widget_show(lw->split_images[0]->widget); gtk_widget_show(lw->split_images[1]->widget); - lw->split_image_widget = paned; return lw->split_image_widget;