diff -up easystroke-0.6.0/cellrenderertextish.c.privatefix easystroke-0.6.0/cellrenderertextish.c
--- easystroke-0.6.0/cellrenderertextish.c.privatefix 2013-03-27 11:52:38.000000000 -0400
+++ easystroke-0.6.0/cellrenderertextish.c 2019-10-18 16:28:14.234822157 -0400
@@ -135,20 +135,18 @@ struct _Block1Data {
gchar* path;
};
-
-static gpointer cell_renderer_textish_parent_class = NULL;
-static gpointer cell_editable_dummy_parent_class = NULL;
-static GtkCellEditableIface* cell_editable_dummy_gtk_cell_editable_parent_iface = NULL;
-static gpointer cell_editable_accel_parent_class = NULL;
static GtkCellEditableIface* cell_editable_accel_gtk_cell_editable_parent_iface = NULL;
-static gpointer cell_editable_combo_parent_class = NULL;
-GType cell_renderer_textish_get_type (void) G_GNUC_CONST;
GType cell_renderer_textish_mode_get_type (void) G_GNUC_CONST;
-#define CELL_RENDERER_TEXTISH_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), TYPE_CELL_RENDERER_TEXTISH, CellRendererTextishPrivate))
enum {
CELL_RENDERER_TEXTISH_DUMMY_PROPERTY
};
+
+G_DEFINE_TYPE_WITH_PRIVATE (CellRendererTextish, cell_renderer_textish, G_TYPE_OBJECT);
+G_DEFINE_TYPE_WITH_PRIVATE (CellEditableAccel, cell_editable_accel, G_TYPE_OBJECT);
+G_DEFINE_TYPE_WITH_PRIVATE (CellEditableDummy, cell_editable_dummy, G_TYPE_OBJECT);
+G_DEFINE_TYPE_WITH_PRIVATE (CellEditableCombo, cell_editable_combo, G_TYPE_OBJECT);
+
CellRendererTextish* cell_renderer_textish_new (void);
CellRendererTextish* cell_renderer_textish_construct (GType object_type);
CellRendererTextish* cell_renderer_textish_new_with_items (gchar** items, int items_length1);
@@ -157,17 +155,14 @@ static gchar** _vala_array_dup1 (gchar**
static GtkCellEditable* cell_renderer_textish_real_start_editing (GtkCellRenderer* base, GdkEvent* event, GtkWidget* widget, const gchar* path, GdkRectangle* background_area, GdkRectangle* cell_area, GtkCellRendererState flags);
CellEditableAccel* cell_editable_accel_new (CellRendererTextish* parent, const gchar* path, GtkWidget* widget);
CellEditableAccel* cell_editable_accel_construct (GType object_type, CellRendererTextish* parent, const gchar* path, GtkWidget* widget);
-GType cell_editable_accel_get_type (void) G_GNUC_CONST;
CellEditableCombo* cell_editable_combo_new (CellRendererTextish* parent, const gchar* path, GtkWidget* widget, gchar** items, int items_length1);
CellEditableCombo* cell_editable_combo_construct (GType object_type, CellRendererTextish* parent, const gchar* path, GtkWidget* widget, gchar** items, int items_length1);
-GType cell_editable_combo_get_type (void) G_GNUC_CONST;
CellEditableDummy* cell_editable_dummy_new (void);
CellEditableDummy* cell_editable_dummy_construct (GType object_type);
-GType cell_editable_dummy_get_type (void) G_GNUC_CONST;
static void g_cclosure_user_marshal_VOID__STRING_FLAGS_UINT (GClosure * closure, GValue * return_value, guint n_param_values, const GValue * param_values, gpointer invocation_hint, gpointer marshal_data);
static void g_cclosure_user_marshal_VOID__STRING_UINT (GClosure * closure, GValue * return_value, guint n_param_values, const GValue * param_values, gpointer invocation_hint, gpointer marshal_data);
static void cell_renderer_textish_finalize (GObject* obj);
-#define CELL_EDITABLE_DUMMY_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), TYPE_CELL_EDITABLE_DUMMY, CellEditableDummyPrivate))
+
enum {
CELL_EDITABLE_DUMMY_DUMMY_PROPERTY,
CELL_EDITABLE_DUMMY_EDITING_CANCELED
@@ -179,7 +174,6 @@ void cell_editable_dummy_set_editing_can
static void cell_editable_dummy_finalize (GObject* obj);
static void _vala_cell_editable_dummy_get_property (GObject * object, guint property_id, GValue * value, GParamSpec * pspec);
static void _vala_cell_editable_dummy_set_property (GObject * object, guint property_id, const GValue * value, GParamSpec * pspec);
-#define CELL_EDITABLE_ACCEL_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), TYPE_CELL_EDITABLE_ACCEL, CellEditableAccelPrivate))
enum {
CELL_EDITABLE_ACCEL_DUMMY_PROPERTY,
CELL_EDITABLE_ACCEL_EDITING_CANCELED
@@ -195,7 +189,6 @@ void cell_editable_accel_set_editing_can
static void cell_editable_accel_finalize (GObject* obj);
static void _vala_cell_editable_accel_get_property (GObject * object, guint property_id, GValue * value, GParamSpec * pspec);
static void _vala_cell_editable_accel_set_property (GObject * object, guint property_id, const GValue * value, GParamSpec * pspec);
-#define CELL_EDITABLE_COMBO_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), TYPE_CELL_EDITABLE_COMBO, CellEditableComboPrivate))
enum {
CELL_EDITABLE_COMBO_DUMMY_PROPERTY
};
@@ -232,7 +225,6 @@ CellRendererTextish* cell_renderer_texti
return self;
}
-
CellRendererTextish* cell_renderer_textish_new (void) {
return cell_renderer_textish_construct (TYPE_CELL_RENDERER_TEXTISH);
}
@@ -418,7 +410,6 @@ static void g_cclosure_user_marshal_VOID
static void cell_renderer_textish_class_init (CellRendererTextishClass * klass) {
cell_renderer_textish_parent_class = g_type_class_peek_parent (klass);
- g_type_class_add_private (klass, sizeof (CellRendererTextishPrivate));
GTK_CELL_RENDERER_CLASS (klass)->start_editing = cell_renderer_textish_real_start_editing;
G_OBJECT_CLASS (klass)->finalize = cell_renderer_textish_finalize;
g_signal_new ("key_edited", TYPE_CELL_RENDERER_TEXTISH, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_user_marshal_VOID__STRING_FLAGS_UINT, G_TYPE_NONE, 3, G_TYPE_STRING, gdk_modifier_type_get_type (), G_TYPE_UINT);
@@ -426,8 +417,8 @@ static void cell_renderer_textish_class_
}
-static void cell_renderer_textish_instance_init (CellRendererTextish * self) {
- self->priv = CELL_RENDERER_TEXTISH_GET_PRIVATE (self);
+static void cell_renderer_textish_init (CellRendererTextish * self) {
+ self->priv = cell_renderer_textish_get_instance_private (self);
}
@@ -439,7 +430,7 @@ static void cell_renderer_textish_finali
G_OBJECT_CLASS (cell_renderer_textish_parent_class)->finalize (obj);
}
-
+/*
GType cell_renderer_textish_get_type (void) {
static volatile gsize cell_renderer_textish_type_id__volatile = 0;
if (g_once_init_enter (&cell_renderer_textish_type_id__volatile)) {
@@ -450,7 +441,7 @@ GType cell_renderer_textish_get_type (vo
}
return cell_renderer_textish_type_id__volatile;
}
-
+*/
static void cell_editable_dummy_real_start_editing (CellEditableDummy* self, GdkEvent* event) {
gtk_cell_editable_editing_done ((GtkCellEditable*) self);
@@ -497,7 +488,6 @@ void cell_editable_dummy_set_editing_can
static void cell_editable_dummy_class_init (CellEditableDummyClass * klass) {
cell_editable_dummy_parent_class = g_type_class_peek_parent (klass);
- g_type_class_add_private (klass, sizeof (CellEditableDummyPrivate));
CELL_EDITABLE_DUMMY_CLASS (klass)->start_editing = cell_editable_dummy_real_start_editing;
G_OBJECT_CLASS (klass)->get_property = _vala_cell_editable_dummy_get_property;
G_OBJECT_CLASS (klass)->set_property = _vala_cell_editable_dummy_set_property;
@@ -505,15 +495,8 @@ static void cell_editable_dummy_class_in
g_object_class_install_property (G_OBJECT_CLASS (klass), CELL_EDITABLE_DUMMY_EDITING_CANCELED, g_param_spec_boolean ("editing-canceled", "editing-canceled", "editing-canceled", FALSE, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE | G_PARAM_WRITABLE));
}
-
-static void cell_editable_dummy_gtk_cell_editable_interface_init (GtkCellEditableIface * iface) {
- cell_editable_dummy_gtk_cell_editable_parent_iface = g_type_interface_peek_parent (iface);
- iface->start_editing = (void (*)(GtkCellEditable*, GdkEvent*)) cell_editable_dummy_start_editing;
-}
-
-
-static void cell_editable_dummy_instance_init (CellEditableDummy * self) {
- self->priv = CELL_EDITABLE_DUMMY_GET_PRIVATE (self);
+static void cell_editable_dummy_init (CellEditableDummy * self) {
+ self->priv = cell_editable_dummy_get_instance_private (self);
}
@@ -523,7 +506,7 @@ static void cell_editable_dummy_finalize
G_OBJECT_CLASS (cell_editable_dummy_parent_class)->finalize (obj);
}
-
+/*
GType cell_editable_dummy_get_type (void) {
static volatile gsize cell_editable_dummy_type_id__volatile = 0;
if (g_once_init_enter (&cell_editable_dummy_type_id__volatile)) {
@@ -536,6 +519,7 @@ GType cell_editable_dummy_get_type (void
}
return cell_editable_dummy_type_id__volatile;
}
+*/
static void _vala_cell_editable_dummy_get_property (GObject * object, guint property_id, GValue * value, GParamSpec * pspec) {
@@ -742,7 +726,6 @@ void cell_editable_accel_set_editing_can
static void cell_editable_accel_class_init (CellEditableAccelClass * klass) {
cell_editable_accel_parent_class = g_type_class_peek_parent (klass);
- g_type_class_add_private (klass, sizeof (CellEditableAccelPrivate));
CELL_EDITABLE_ACCEL_CLASS (klass)->start_editing = cell_editable_accel_real_start_editing;
G_OBJECT_CLASS (klass)->get_property = _vala_cell_editable_accel_get_property;
G_OBJECT_CLASS (klass)->set_property = _vala_cell_editable_accel_set_property;
@@ -757,8 +740,8 @@ static void cell_editable_accel_gtk_cell
}
-static void cell_editable_accel_instance_init (CellEditableAccel * self) {
- self->priv = CELL_EDITABLE_ACCEL_GET_PRIVATE (self);
+static void cell_editable_accel_init (CellEditableAccel * self) {
+ self->priv = cell_editable_accel_get_instance_private (self);
}
@@ -770,7 +753,7 @@ static void cell_editable_accel_finalize
G_OBJECT_CLASS (cell_editable_accel_parent_class)->finalize (obj);
}
-
+/*
GType cell_editable_accel_get_type (void) {
static volatile gsize cell_editable_accel_type_id__volatile = 0;
if (g_once_init_enter (&cell_editable_accel_type_id__volatile)) {
@@ -783,7 +766,7 @@ GType cell_editable_accel_get_type (void
}
return cell_editable_accel_type_id__volatile;
}
-
+*/
static void _vala_cell_editable_accel_get_property (GObject * object, guint property_id, GValue * value, GParamSpec * pspec) {
CellEditableAccel * self;
@@ -927,13 +910,12 @@ CellEditableCombo* cell_editable_combo_n
static void cell_editable_combo_class_init (CellEditableComboClass * klass) {
cell_editable_combo_parent_class = g_type_class_peek_parent (klass);
- g_type_class_add_private (klass, sizeof (CellEditableComboPrivate));
G_OBJECT_CLASS (klass)->finalize = cell_editable_combo_finalize;
}
-static void cell_editable_combo_instance_init (CellEditableCombo * self) {
- self->priv = CELL_EDITABLE_COMBO_GET_PRIVATE (self);
+static void cell_editable_combo_init (CellEditableCombo * self) {
+ self->priv = cell_editable_combo_get_instance_private (self);
}
@@ -945,7 +927,7 @@ static void cell_editable_combo_finalize
G_OBJECT_CLASS (cell_editable_combo_parent_class)->finalize (obj);
}
-
+/*
GType cell_editable_combo_get_type (void) {
static volatile gsize cell_editable_combo_type_id__volatile = 0;
if (g_once_init_enter (&cell_editable_combo_type_id__volatile)) {
@@ -956,7 +938,7 @@ GType cell_editable_combo_get_type (void
}
return cell_editable_combo_type_id__volatile;
}
-
+*/
static void _vala_array_destroy (gpointer array, gint array_length, GDestroyNotify destroy_func) {
if ((array != NULL) && (destroy_func != NULL)) {