summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCody Russell <bratsche@gnome.org>2007-06-04 18:21:04 +0000
committerCody Russell <bratsche@src.gnome.org>2007-06-04 18:21:04 +0000
commit484d13e3132ed45e729df49c813a1b88b0c14852 (patch)
treef3a3d62dd1d1cc12b98df62d8240a4bbe37fa2fe
parent7f330fe2dc365a2a875756465d849c1cd097f77c (diff)
downloadgdk-pixbuf-484d13e3132ed45e729df49c813a1b88b0c14852.tar.gz
Merge from trunk:
2007-06-04 Cody Russell <bratsche@gnome.org> Merge from trunk: * gtk/gtkpathbar.c (gtk_path_bar_scroll_down): Check if down_button is NULL. This happens when the pathbar button for the current directory is too large to fit in the space, e.g. on Windows for directories named something like "My Documents and Settings". (#389603) svn path=/branches/gtk-2-10/; revision=18032
-rw-r--r--ChangeLog10
-rw-r--r--gtk/gtkpathbar.c5
2 files changed, 14 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index 6cd149bf7..a321ed810 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,13 @@
+2007-06-04 Cody Russell <bratsche@gnome.org>
+
+ Merge from trunk:
+
+ * gtk/gtkpathbar.c (gtk_path_bar_scroll_down): Check
+ if down_button is NULL. This happens when the pathbar button
+ for the current directory is too large to fit in the
+ space, e.g. on Windows for directories named something like
+ "My Documents and Settings". (#389603)
+
2007-06-01 Michael Natterer <mitch@imendio.com>
Merge from trunk:
diff --git a/gtk/gtkpathbar.c b/gtk/gtkpathbar.c
index d384d6558..f77c8b366 100644
--- a/gtk/gtkpathbar.c
+++ b/gtk/gtkpathbar.c
@@ -707,7 +707,10 @@ gtk_path_bar_scroll_down (GtkWidget *button, GtkPathBar *path_bar)
}
}
- space_needed = BUTTON_DATA (down_button->data)->button->allocation.width + path_bar->spacing;
+ /* We check if down_button might be NULL in cases where the pathbar's horizontal size is smaller
+ * than the button and it doesn't get displayed. e.g., on Windows it might be "My Documents and Settings"
+ */
+ space_needed = down_button ? BUTTON_DATA (down_button->data)->button->allocation.width : 0 + path_bar->spacing;
if (direction == GTK_TEXT_DIR_RTL)
space_available = path_bar->down_slider_button->allocation.x - GTK_WIDGET (path_bar)->allocation.x;
else