From 5317e4bc07b8b2767eca77ea96568609993daedf Mon Sep 17 00:00:00 2001 From: Matthias Clasen Date: Mon, 25 May 2020 14:14:28 -0400 Subject: [PATCH] constraint-editor: Don't use g_type_ensure This isn't necessary if we export the get_type function. --- demos/constraint-editor/constraint-editor-window.c | 2 -- demos/constraint-editor/constraint-view.h | 1 + 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/demos/constraint-editor/constraint-editor-window.c b/demos/constraint-editor/constraint-editor-window.c index 001eab3ba2..ac724993e4 100644 --- a/demos/constraint-editor/constraint-editor-window.c +++ b/demos/constraint-editor/constraint-editor-window.c @@ -487,8 +487,6 @@ constraint_editor_window_class_init (ConstraintEditorWindowClass *class) GObjectClass *object_class = G_OBJECT_CLASS (class); GtkWidgetClass *widget_class = GTK_WIDGET_CLASS (class); - g_type_ensure (CONSTRAINT_VIEW_TYPE); - object_class->finalize = constraint_editor_window_finalize; gtk_widget_class_set_template_from_resource (widget_class, diff --git a/demos/constraint-editor/constraint-view.h b/demos/constraint-editor/constraint-view.h index 40e80c8c43..834e606eb7 100644 --- a/demos/constraint-editor/constraint-view.h +++ b/demos/constraint-editor/constraint-view.h @@ -23,6 +23,7 @@ #define CONSTRAINT_VIEW_TYPE (constraint_view_get_type ()) +G_MODULE_EXPORT G_DECLARE_FINAL_TYPE (ConstraintView, constraint_view, CONSTRAINT, VIEW, GtkWidget) ConstraintView * constraint_view_new (void);