From fa7f0a8f6723dd2d7e00be20516bc8f6b7b8bfa7 Mon Sep 17 00:00:00 2001 From: Felix Morgner Date: Fri, 4 Apr 2025 21:23:36 +0200 Subject: adw: fix class derivations --- adw/src/breakpoint.cpp | 2 +- adw/src/dialog.cpp | 2 ++ adw/src/stylemanager.cpp | 2 +- adw/src/toast.cpp | 2 +- adw/src/toastoverlay.cpp | 2 +- 5 files changed, 6 insertions(+), 4 deletions(-) (limited to 'adw/src') diff --git a/adw/src/breakpoint.cpp b/adw/src/breakpoint.cpp index 3907a15..a1b20f9 100644 --- a/adw/src/breakpoint.cpp +++ b/adw/src/breakpoint.cpp @@ -97,7 +97,7 @@ namespace Adwaita if (!gtype_) { class_init_func_ = &class_init_function; - register_derived_type(adw_breakpoint_get_type()); + gtype_ = adw_breakpoint_get_type(); Gtk::Buildable::add_interface(get_type()); } return *this; diff --git a/adw/src/dialog.cpp b/adw/src/dialog.cpp index 2634002..e240d7f 100644 --- a/adw/src/dialog.cpp +++ b/adw/src/dialog.cpp @@ -13,6 +13,7 @@ #include #include #include +#include #include #include @@ -33,6 +34,7 @@ namespace Adwaita { class_init_func_ = &class_init_function; register_derived_type(adw_dialog_get_type()); + Gtk::ShortcutManager::add_interface(get_type()); } return *this; } diff --git a/adw/src/stylemanager.cpp b/adw/src/stylemanager.cpp index 1b7817a..09a966c 100644 --- a/adw/src/stylemanager.cpp +++ b/adw/src/stylemanager.cpp @@ -33,7 +33,7 @@ namespace Adwaita if (!gtype_) { class_init_func_ = &StyleManager::Class::class_init_function; - register_derived_type(adw_style_manager_get_type()); + gtype_ = adw_style_manager_get_type(); } return *this; } diff --git a/adw/src/toast.cpp b/adw/src/toast.cpp index 205e69f..d5b372e 100644 --- a/adw/src/toast.cpp +++ b/adw/src/toast.cpp @@ -43,7 +43,7 @@ namespace Adwaita if (!gtype_) { class_init_func_ = &class_init_function; - register_derived_type(adw_toast_get_type()); + gtype_= adw_toast_get_type(); } return *this; } diff --git a/adw/src/toastoverlay.cpp b/adw/src/toastoverlay.cpp index af24649..7d1493c 100644 --- a/adw/src/toastoverlay.cpp +++ b/adw/src/toastoverlay.cpp @@ -32,7 +32,7 @@ namespace Adwaita if (!gtype_) { class_init_func_ = &class_init_function; - register_derived_type(adw_toast_overlay_get_type()); + gtype_ = adw_toast_overlay_get_type(); } return *this; } -- cgit v1.2.3