diff options
| author | Felix Morgner <felix.morgner@gmail.com> | 2024-08-17 11:41:43 +0200 |
|---|---|---|
| committer | Felix Morgner <felix.morgner@gmail.com> | 2024-08-17 11:41:43 +0200 |
| commit | 97cb30337429a6849c276693ddf7fb40fec1aa14 (patch) | |
| tree | 5f42489d34deb3076677996ce10269d78af9cfa2 /include/turns/adw/dialog.hpp | |
| parent | 6fb8667b9848c8fe0989bb665e2f4ddc09179983 (diff) | |
| download | libadwaitamm-97cb30337429a6849c276693ddf7fb40fec1aa14.tar.xz libadwaitamm-97cb30337429a6849c276693ddf7fb40fec1aa14.zip | |
ui: add participant shading color preferences
Diffstat (limited to 'include/turns/adw/dialog.hpp')
| -rw-r--r-- | include/turns/adw/dialog.hpp | 64 |
1 files changed, 64 insertions, 0 deletions
diff --git a/include/turns/adw/dialog.hpp b/include/turns/adw/dialog.hpp new file mode 100644 index 0000000..af5f5da --- /dev/null +++ b/include/turns/adw/dialog.hpp @@ -0,0 +1,64 @@ +#ifndef TURNS_ADW_DIALOG_HPP +#define TURNS_ADW_DIALOG_HPP + +#include "helpers/gobj_mixin.hpp" + +#include <glibmm/class.h> +#include <glibmm/refptr.h> + +#include <gtkmm/widget.h> + +using AdwDialog = struct _AdwDialog; + +namespace turns::adw +{ + struct Dialog_Class; + + struct Dialog : Gtk::Widget, + helpers::gobj_mixin<Dialog, AdwDialog> + { + struct Class : Glib::Class + { + using BaseClassParent = GtkWidgetClass; + using BaseClassType = struct AdwDialogClass; + using BaseObjectType = AdwDialog; + using CppClassParent = struct Gtk::Widget_Class; + using CppObjectType = Dialog; + + auto init() -> Glib::Class const &; + auto static class_init_function(void * gclass, void * data) -> void; + auto static wrap_new(GObject * object) -> Glib::ObjectBase *; + }; + + using BaseObjectType = Class::BaseObjectType; + using BaseClassType = Class::BaseClassType; + using CppObjectType = Class::CppObjectType; + using CppClassType = Class; + + using helpers::gobj_mixin<CppObjectType, BaseObjectType>::gobj; + using helpers::gobj_mixin<CppObjectType, BaseObjectType>::gobj_copy; + + explicit Dialog(); + Dialog(Dialog const & other) = delete; + Dialog(Dialog && other) noexcept = default; + + auto operator=(Dialog const & other) noexcept -> Dialog & = delete; + auto operator=(Dialog && other) noexcept -> Dialog & = default; + + auto static get_type() -> GType; + auto static get_base_type() -> GType; + + auto present(Gtk::Widget * parent) -> void; + + protected: + explicit Dialog(Glib::ConstructParams const & params); + explicit Dialog(BaseObjectType * gobj); + }; +} // namespace turns::adw + +namespace Glib +{ + auto wrap(AdwDialog * object, bool copy = false) -> Glib::RefPtr<turns::adw::Dialog>; +} // namespace Glib + +#endif
\ No newline at end of file |
