[sysprof/wip/gtk4-port: 48/132] failedstateview: port to GTK 4
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [sysprof/wip/gtk4-port: 48/132] failedstateview: port to GTK 4
- Date: Tue, 7 Dec 2021 08:29:11 +0000 (UTC)
commit bbce3ce93008941ac5eab8485e6f6e78ab664692
Author: Christian Hergert <chergert redhat com>
Date: Tue Sep 28 17:13:30 2021 -0700
failedstateview: port to GTK 4
src/libsysprof-ui/sysprof-failed-state-view.c | 3 ++-
src/libsysprof-ui/sysprof-failed-state-view.h | 6 ++----
src/libsysprof-ui/sysprof-failed-state-view.ui | 2 +-
3 files changed, 5 insertions(+), 6 deletions(-)
---
diff --git a/src/libsysprof-ui/sysprof-failed-state-view.c b/src/libsysprof-ui/sysprof-failed-state-view.c
index 239eb425..b2c5e9a7 100644
--- a/src/libsysprof-ui/sysprof-failed-state-view.c
+++ b/src/libsysprof-ui/sysprof-failed-state-view.c
@@ -22,7 +22,7 @@
#include "sysprof-failed-state-view.h"
-G_DEFINE_TYPE (SysprofFailedStateView, sysprof_failed_state_view, GTK_TYPE_BIN)
+G_DEFINE_TYPE (SysprofFailedStateView, sysprof_failed_state_view, GTK_TYPE_WIDGET)
GtkWidget *
sysprof_failed_state_view_new (void)
@@ -35,6 +35,7 @@ sysprof_failed_state_view_class_init (SysprofFailedStateViewClass *klass)
{
GtkWidgetClass *widget_class = GTK_WIDGET_CLASS (klass);
+ gtk_widget_class_set_layout_manager_type (widget_class, GTK_TYPE_BIN_LAYOUT);
gtk_widget_class_set_template_from_resource (widget_class,
"/org/gnome/sysprof/ui/sysprof-failed-state-view.ui");
}
diff --git a/src/libsysprof-ui/sysprof-failed-state-view.h b/src/libsysprof-ui/sysprof-failed-state-view.h
index 91ed603f..4657abe1 100644
--- a/src/libsysprof-ui/sysprof-failed-state-view.h
+++ b/src/libsysprof-ui/sysprof-failed-state-view.h
@@ -27,13 +27,11 @@ G_BEGIN_DECLS
#define SYSPROF_TYPE_FAILED_STATE_VIEW (sysprof_failed_state_view_get_type())
-G_DECLARE_DERIVABLE_TYPE (SysprofFailedStateView, sysprof_failed_state_view, SYSPROF, FAILED_STATE_VIEW,
GtkBin)
+G_DECLARE_DERIVABLE_TYPE (SysprofFailedStateView, sysprof_failed_state_view, SYSPROF, FAILED_STATE_VIEW,
GtkWidget)
struct _SysprofFailedStateViewClass
{
- GtkBinClass parent;
-
- gpointer padding[4];
+ GtkWidgetClass parent;
};
GtkWidget *sysprof_failed_state_view_new (void);
diff --git a/src/libsysprof-ui/sysprof-failed-state-view.ui b/src/libsysprof-ui/sysprof-failed-state-view.ui
index c91c2398..9a80e0a5 100644
--- a/src/libsysprof-ui/sysprof-failed-state-view.ui
+++ b/src/libsysprof-ui/sysprof-failed-state-view.ui
@@ -1,6 +1,6 @@
<?xml version="1.0"?>
<interface>
- <template class="SysprofFailedStateView" parent="GtkBin">
+ <template class="SysprofFailedStateView" parent="GtkWidget">
<child>
<object class="GtkBox">
<property name="border-width">36</property>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]