#ifndef LIBADWAITAMM_ALERT_DIALOG_HPP #define LIBADWAITAMM_ALERT_DIALOG_HPP #include "adwaitamm/dialog.hpp" #include "adwaitamm/helpers/gobj_mixin.hpp" #include #include #include #include #include #include #include #include #include using AdwAlertDialog = struct _AdwAlertDialog; using AdwAlertDialogClass = struct _AdwAlertDialogClass; namespace Adwaita { struct AlertDialog : Dialog, helpers::gobj_mixin { struct Class : Glib::Class { using BaseClassParent = AdwDialogClass; using BaseClassType = AdwAlertDialogClass; using BaseObjectType = AdwAlertDialog; using CppClassParent = Dialog::Class; using CppObjectType = AlertDialog; auto init() -> Glib::Class const &; auto static class_init_function(void * gclass, void * data) -> void; auto static wrap_new(GObject * object) -> Glib::ObjectBase *; }; enum struct ResponseAppearance : int { _default, suggested, destructive, }; using BaseObjectType = Class::BaseObjectType; using BaseClassType = Class::BaseClassType; using CppObjectType = Class::CppObjectType; using CppClassType = Class; using helpers::gobj_mixin::gobj; using helpers::gobj_mixin::gobj_copy; AlertDialog(Glib::ustring heading, Glib::ustring body); AlertDialog(AlertDialog const & other) = delete; AlertDialog(AlertDialog && other) noexcept = default; auto operator=(AlertDialog const & other) noexcept -> AlertDialog & = delete; auto operator=(AlertDialog && other) noexcept -> AlertDialog & = default; auto static create(Glib::ustring heading, Glib::ustring body) -> Glib::RefPtr; auto static get_type() -> GType; auto static get_base_type() -> GType; auto add_response(Glib::ustring id, Glib::ustring label) -> void; auto choose(Gtk::Widget & parent, Glib::RefPtr const & cancellable, Gio::SlotAsyncReady const & slot) -> void; auto choose_finish(Glib::RefPtr const & result) -> Glib::ustring; auto set_close_response(Glib::ustring id) -> void; auto set_default_response(Glib::ustring id) -> void; auto set_response_appearance(Glib::ustring id, ResponseAppearance value) -> void; protected: explicit AlertDialog(Glib::ConstructParams const & params); explicit AlertDialog(BaseObjectType * gobj); }; } // namespace Adwaita namespace Glib { auto wrap(AdwAlertDialog * object, bool copy = false) -> Adwaita::AlertDialog *; } // namespace Glib #endif