diff options
author | yetist <[email protected]> | 2018-11-13 14:46:01 +0800 |
---|---|---|
committer | raveit65 <[email protected]> | 2018-11-13 14:55:57 +0100 |
commit | 7ecf16d43388b4547126cd0b1d441f29f9be27c5 (patch) | |
tree | f013667be7617b5a289c613627d69ed1600ec070 /src/gsm_color_button.h | |
parent | 9883224a76adb80faa5000362e548a5dc08919ec (diff) | |
download | mate-system-monitor-7ecf16d43388b4547126cd0b1d441f29f9be27c5.tar.bz2 mate-system-monitor-7ecf16d43388b4547126cd0b1d441f29f9be27c5.tar.xz |
Avoid compile warning for g_type_class_add_private
Fixes the issue with GLib >= 2.58, list of modified files:
- src/gsm_color_button.c
- src/gsm_color_button.h
Diffstat (limited to 'src/gsm_color_button.h')
-rw-r--r-- | src/gsm_color_button.h | 20 |
1 files changed, 2 insertions, 18 deletions
diff --git a/src/gsm_color_button.h b/src/gsm_color_button.h index 5f1bcb1..adb34dd 100644 --- a/src/gsm_color_button.h +++ b/src/gsm_color_button.h @@ -27,29 +27,14 @@ #include <gtk/gtk.h> G_BEGIN_DECLS + /* The GtkColorSelectionButton widget is a simple color picker in a button. * The button displays a sample of the currently selected color. When * the user clicks on the button, a color selection dialog pops up. * The color picker emits the "color_set" signal when the color is set. */ #define GSM_TYPE_COLOR_BUTTON (gsm_color_button_get_type ()) -#define GSM_COLOR_BUTTON(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GSM_TYPE_COLOR_BUTTON, GSMColorButton)) -#define GSM_COLOR_BUTTON_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GSM_TYPE_COLOR_BUTTON, GSMColorButtonClass)) -#define GSM_IS_COLOR_BUTTON(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GSM_TYPE_COLOR_BUTTON)) -#define GSM_IS_COLOR_BUTTON_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GSM_TYPE_COLOR_BUTTON)) -#define GSM_COLOR_BUTTON_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GSM_TYPE_COLOR_BUTTON, GSMColorButtonClass)) -typedef struct _GSMColorButton GSMColorButton; -typedef struct _GSMColorButtonClass GSMColorButtonClass; -typedef struct _GSMColorButtonPrivate GSMColorButtonPrivate; - -struct _GSMColorButton -{ - GtkDrawingArea widget; - - /*< private > */ - - GSMColorButtonPrivate *priv; -}; +G_DECLARE_DERIVABLE_TYPE (GSMColorButton, gsm_color_button, GSM, COLOR_BUTTON, GtkDrawingArea) /* Widget types */ enum @@ -74,7 +59,6 @@ struct _GSMColorButtonClass void (*_gtk_reserved4) (void); }; -GType gsm_color_button_get_type (void) G_GNUC_CONST; GtkWidget *gsm_color_button_new (const GdkRGBA * color, guint type); void gsm_color_button_set_color (GSMColorButton * color_button, const GdkRGBA * color); void gsm_color_button_set_fraction (GSMColorButton * color_button, const gdouble fraction); |