Commit 6e4a379e authored by Matthias Clasen's avatar Matthias Clasen Committed by Matthias Clasen

Fix crashes in connection with pathbar scrolling (#321560, Bogdan Nicula)

2005-11-18  Matthias Clasen  <mclasen@redhat.com>

	Fix crashes in connection with pathbar scrolling (#321560,
	Bogdan Nicula)

	* gtk/gtkpathbar.c (gtk_path_bar_update_slider_buttons):
	Stop scrolling when desensitising slider buttons.
	(gtk_path_bar_scroll_timeout, gtk_path_bar_slider_button_press):
	And use it here.

	* gtk/gtkpathbar.h (struct _GtkPathBar): Add a separate
	scrolling_down flag.
parent 478043a1
2005-11-18 Matthias Clasen <mclasen@redhat.com>
Fix crashes in connection with pathbar scrolling (#321560,
Bogdan Nicula)
* gtk/gtkpathbar.c (gtk_path_bar_update_slider_buttons):
Stop scrolling when desensitising slider buttons.
(gtk_path_bar_scroll_timeout, gtk_path_bar_slider_button_press):
And use it here.
* gtk/gtkpathbar.h (struct _GtkPathBar): Add a separate
scrolling_down flag.
2005-11-18 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkpathbar.c (button_clicked_cb): Fix a C99ism.
......
2005-11-18 Matthias Clasen <mclasen@redhat.com>
Fix crashes in connection with pathbar scrolling (#321560,
Bogdan Nicula)
* gtk/gtkpathbar.c (gtk_path_bar_update_slider_buttons):
Stop scrolling when desensitising slider buttons.
(gtk_path_bar_scroll_timeout, gtk_path_bar_slider_button_press):
And use it here.
* gtk/gtkpathbar.h (struct _GtkPathBar): Add a separate
scrolling_down flag.
2005-11-18 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkpathbar.c (button_clicked_cb): Fix a C99ism.
......
......@@ -734,7 +734,7 @@ gtk_path_bar_scroll_timeout (GtkPathBar *path_bar)
{
if (path_bar->scrolling_up)
gtk_path_bar_scroll_up (path_bar->up_slider_button, path_bar);
else
else if (path_bar->scrolling_down)
gtk_path_bar_scroll_down (path_bar->down_slider_button, path_bar);
if (path_bar->need_timer)
......@@ -779,12 +779,14 @@ gtk_path_bar_slider_button_press (GtkWidget *widget,
if (widget == path_bar->up_slider_button)
{
path_bar->scrolling_down = FALSE;
path_bar->scrolling_up = TRUE;
gtk_path_bar_scroll_up (path_bar->up_slider_button, path_bar);
}
else if (widget == path_bar->down_slider_button)
{
path_bar->scrolling_up = FALSE;
path_bar->scrolling_down = TRUE;
gtk_path_bar_scroll_down (path_bar->down_slider_button, path_bar);
}
......
......@@ -61,9 +61,10 @@ struct _GtkPathBar
gint16 button_offset;
guint timer;
guint slider_visible : 1;
guint need_timer : 1;
guint ignore_click : 1;
guint scrolling_up : 1;
guint need_timer : 1;
guint ignore_click : 1;
guint scrolling_up : 1;
guint scrolling_down : 1;
};
struct _GtkPathBarClass
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment