Bug 539944 – Add GtkScaleButton API so struct fields can be marked as

2008-07-04  Michael Natterer  <mitch@imendio.com>

	Bug 539944 – Add GtkScaleButton API so struct fields can be marked
	as private

	* gtk/gtk.symbols
	* gtk/gtkscalebutton.[ch]: add gtk_scale_button_get_plus_button()
	and _get_minus_button(). Patch by Christian Dywan.


svn path=/trunk/; revision=20757
This commit is contained in:
Michael Natterer 2008-07-04 09:02:20 +00:00 committed by Michael Natterer
parent 4f56813d00
commit 89da90a6cd
4 changed files with 64 additions and 19 deletions

View File

@ -1,3 +1,12 @@
2008-07-04 Michael Natterer <mitch@imendio.com>
Bug 539944 Add GtkScaleButton API so struct fields can be marked
as private
* gtk/gtk.symbols
* gtk/gtkscalebutton.[ch]: add gtk_scale_button_get_plus_button()
and _get_minus_button(). Patch by Christian Dywan.
2008-07-04 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkscalebutton.c:

View File

@ -3311,6 +3311,8 @@ gtk_scale_button_get_adjustment
gtk_scale_button_set_adjustment
gtk_scale_button_get_orientation
gtk_scale_button_set_orientation
gtk_scale_button_get_plus_button
gtk_scale_button_get_minus_button
gtk_scale_button_get_popup
#endif
#endif

View File

@ -758,6 +758,38 @@ gtk_scale_button_set_orientation (GtkScaleButton *button,
}
}
/**
* gtk_scale_button_get_plus_button:
* @button: a #GtkScaleButton
*
* Retrieves the plus button of the #GtkScaleButton.
*
* Since: 2.14
*/
GtkWidget *
gtk_scale_button_get_plus_button (GtkScaleButton *button)
{
g_return_val_if_fail (GTK_IS_SCALE_BUTTON (button), NULL);
return button->plus_button;
}
/**
* gtk_scale_button_get_minus_button:
* @button: a #GtkScaleButton
*
* Retrieves the minus button of the #GtkScaleButton.
*
* Since: 2.14
*/
GtkWidget *
gtk_scale_button_get_minus_button (GtkScaleButton *button)
{
g_return_val_if_fail (GTK_IS_SCALE_BUTTON (button), NULL);
return button->minus_button;
}
/**
* gtk_scale_button_get_popup:
* @button: a #GtkScaleButton
@ -766,7 +798,7 @@ gtk_scale_button_set_orientation (GtkScaleButton *button,
*
* Since: 2.14
*/
GtkWidget*
GtkWidget *
gtk_scale_button_get_popup (GtkScaleButton *button)
{
g_return_val_if_fail (GTK_IS_SCALE_BUTTON (button), NULL);

View File

@ -81,24 +81,26 @@ struct _GtkScaleButtonClass
void (*_gtk_reserved4) (void);
};
GType gtk_scale_button_get_type (void) G_GNUC_CONST;
GtkWidget * gtk_scale_button_new (GtkIconSize size,
gdouble min,
gdouble max,
gdouble step,
const gchar **icons);
void gtk_scale_button_set_icons (GtkScaleButton *button,
const gchar **icons);
gdouble gtk_scale_button_get_value (GtkScaleButton *button);
void gtk_scale_button_set_value (GtkScaleButton *button,
gdouble value);
GtkAdjustment * gtk_scale_button_get_adjustment (GtkScaleButton *button);
void gtk_scale_button_set_adjustment (GtkScaleButton *button,
GtkAdjustment *adjustment);
GtkOrientation gtk_scale_button_get_orientation (GtkScaleButton *button);
void gtk_scale_button_set_orientation (GtkScaleButton *button,
GtkOrientation orientation);
GtkWidget * gtk_scale_button_get_popup (GtkScaleButton *button);
GType gtk_scale_button_get_type (void) G_GNUC_CONST;
GtkWidget * gtk_scale_button_new (GtkIconSize size,
gdouble min,
gdouble max,
gdouble step,
const gchar **icons);
void gtk_scale_button_set_icons (GtkScaleButton *button,
const gchar **icons);
gdouble gtk_scale_button_get_value (GtkScaleButton *button);
void gtk_scale_button_set_value (GtkScaleButton *button,
gdouble value);
GtkAdjustment * gtk_scale_button_get_adjustment (GtkScaleButton *button);
void gtk_scale_button_set_adjustment (GtkScaleButton *button,
GtkAdjustment *adjustment);
GtkOrientation gtk_scale_button_get_orientation (GtkScaleButton *button);
void gtk_scale_button_set_orientation (GtkScaleButton *button,
GtkOrientation orientation);
GtkWidget * gtk_scale_button_get_plus_button (GtkScaleButton *button);
GtkWidget * gtk_scale_button_get_minus_button (GtkScaleButton *button);
GtkWidget * gtk_scale_button_get_popup (GtkScaleButton *button);
G_END_DECLS