From 95dc7e43a23300b3eacbb7e1e0a9d4f31a8bd5a0 Mon Sep 17 00:00:00 2001 From: Felix Morgner Date: Thu, 24 Apr 2025 20:12:26 +0200 Subject: adw: extract class definitions --- adw/src/preferencespage.cpp | 25 +++---------------------- 1 file changed, 3 insertions(+), 22 deletions(-) (limited to 'adw/src/preferencespage.cpp') diff --git a/adw/src/preferencespage.cpp b/adw/src/preferencespage.cpp index e2b3e80..0c10d97 100644 --- a/adw/src/preferencespage.cpp +++ b/adw/src/preferencespage.cpp @@ -1,5 +1,7 @@ #include "adwaitamm/preferencespage.hpp" +#include "adwaitamm/private/preferencespage_p.hpp" + #include #include #include @@ -21,30 +23,9 @@ namespace Adwaita { namespace { - auto constinit _class = PreferencesPage::Class{}; + auto constinit _class = PreferencesPage_Class{}; } // namespace - auto PreferencesPage::Class::init() -> Glib::Class const & - { - if (!gtype_) - { - class_init_func_ = &class_init_function; - register_derived_type(adw_preferences_page_get_type()); - } - return *this; - } - - auto PreferencesPage::Class::class_init_function(void * gclass, void * data) -> void - { - auto const klass = static_cast(gclass); - CppClassParent::class_init_function(klass, data); - } - - auto PreferencesPage::Class::wrap_new(GObject * object) -> Glib::ObjectBase * - { - return Gtk::manage(new PreferencesPage(ADW_PREFERENCES_PAGE(object))); - } - auto PreferencesPage::get_type() -> GType { return _class.init().get_type(); -- cgit v1.2.3