Add getters for the scrollbars. (#167181, Billy Biggs)

2005-05-03  Matthias Clasen  <mclasen@redhat.com>

	* gtk/gtkscrolledwindow.h:
	* gtk/gtkscrolledwindow.c (gtk_scrolled_window_get_vscrollbar):
	* gtk/gtk.symbols: Add getters for the scrollbars.  (#167181,
	Billy Biggs)
This commit is contained in:
Matthias Clasen 2005-05-03 05:01:04 +00:00 committed by Matthias Clasen
parent 90f9ff75f6
commit 968f80dfab
6 changed files with 59 additions and 3 deletions

View File

@ -1,6 +1,10 @@
2005-05-03 Matthias Clasen <mclasen@redhat.com>
* gtk/gtk.symbols:
* gtk/gtkscrolledwindow.h:
* gtk/gtkscrolledwindow.c (gtk_scrolled_window_get_vscrollbar):
* gtk/gtk.symbols: Add getters for the scrollbars. (#167181,
Billy Biggs)
* gtk/gtkdialog.h:
* gtk/gtkdialog.c (gtk_dialog_get_response_for_widget):
Make this function public. (#170748, Morten Welinder)

View File

@ -1,6 +1,10 @@
2005-05-03 Matthias Clasen <mclasen@redhat.com>
* gtk/gtk.symbols:
* gtk/gtkscrolledwindow.h:
* gtk/gtkscrolledwindow.c (gtk_scrolled_window_get_vscrollbar):
* gtk/gtk.symbols: Add getters for the scrollbars. (#167181,
Billy Biggs)
* gtk/gtkdialog.h:
* gtk/gtkdialog.c (gtk_dialog_get_response_for_widget):
Make this function public. (#170748, Morten Welinder)

View File

@ -1,6 +1,10 @@
2005-05-03 Matthias Clasen <mclasen@redhat.com>
* gtk/gtk.symbols:
* gtk/gtkscrolledwindow.h:
* gtk/gtkscrolledwindow.c (gtk_scrolled_window_get_vscrollbar):
* gtk/gtk.symbols: Add getters for the scrollbars. (#167181,
Billy Biggs)
* gtk/gtkdialog.h:
* gtk/gtkdialog.c (gtk_dialog_get_response_for_widget):
Make this function public. (#170748, Morten Welinder)

View File

@ -2525,11 +2525,13 @@ gtk_scrollbar_get_type G_GNUC_CONST
#if IN_FILE(__GTK_SCROLLED_WINDOW_C__)
gtk_scrolled_window_add_with_viewport
gtk_scrolled_window_get_hadjustment
gtk_scrolled_window_get_hscrollbar
gtk_scrolled_window_get_placement
gtk_scrolled_window_get_policy
gtk_scrolled_window_get_shadow_type
gtk_scrolled_window_get_type G_GNUC_CONST
gtk_scrolled_window_get_vadjustment
gtk_scrolled_window_get_vscrollbar
gtk_scrolled_window_new
gtk_scrolled_window_set_hadjustment
gtk_scrolled_window_set_placement

View File

@ -495,6 +495,44 @@ gtk_scrolled_window_get_vadjustment (GtkScrolledWindow *scrolled_window)
NULL);
}
/**
* gtk_scrolled_window_get_hscrollbar:
* @scrolled_window: a #GtkScrolledWindow
*
* Returns the horizontal scrollbar of @scrolled_window.
*
* Returns: the horizontal scrollbar of the scrolled window, or
* %NULL if it does not have one.
*
* Since: 2.8
*/
GtkHScrollbar*
gtk_scrolled_window_get_hscrollbar (GtkScrolledWindow *scrolled_window)
{
g_return_val_if_fail (GTK_IS_SCROLLED_WINDOW (scrolled_window), NULL);
return scrolled_window->hscrollbar;
}
/**
* gtk_scrolled_window_get_vscrollbar:
* @scrolled_window: a #GtkScrolledWindow
*
* Returns the vertical scrollbar of @scrolled_window.
*
* Returns: the vertical scrollbar of the scrolled window, or
* %NULL if it does not have one.
*
* Since: 2.8
*/
GtkVScrollbar*
gtk_scrolled_window_get_vscrollbar (GtkScrolledWindow *scrolled_window)
{
g_return_val_if_fail (GTK_IS_SCROLLED_WINDOW (scrolled_window), NULL);
return scrolled_window->vscrollbar;
}
void
gtk_scrolled_window_set_policy (GtkScrolledWindow *scrolled_window,
GtkPolicyType hscrollbar_policy,

View File

@ -55,9 +55,11 @@ struct _GtkScrolledWindow
{
GtkBin container;
/*< public >*/
GtkWidget *hscrollbar;
GtkWidget *vscrollbar;
/*< private >*/
guint hscrollbar_policy : 2;
guint vscrollbar_policy : 2;
guint hscrollbar_visible : 1;
@ -105,6 +107,8 @@ void gtk_scrolled_window_set_vadjustment (GtkScrolledWindow *scrolle
GtkAdjustment *hadjustment);
GtkAdjustment* gtk_scrolled_window_get_hadjustment (GtkScrolledWindow *scrolled_window);
GtkAdjustment* gtk_scrolled_window_get_vadjustment (GtkScrolledWindow *scrolled_window);
GtkHScrollbar* gtk_scrolled_window_get_hscrollbar (GtkScrolledWindow *scrolled_window);
GtkVScrollbar* gtk_scrolled_window_get_vscrollbar (GtkScrolledWindow *scrolled_window);
void gtk_scrolled_window_set_policy (GtkScrolledWindow *scrolled_window,
GtkPolicyType hscrollbar_policy,
GtkPolicyType vscrollbar_policy);