summaryrefslogtreecommitdiff
path: root/adw/src/toast.cpp
diff options
context:
space:
mode:
authorFelix Morgner <felix.morgner@gmail.com>2025-04-04 22:15:41 +0200
committerFelix Morgner <felix.morgner@gmail.com>2025-04-04 22:15:41 +0200
commitb95258f419c62f7f38ec6128568df5897e4f5696 (patch)
treecb8a0820980b624a1e502a7a7500583242b536e7 /adw/src/toast.cpp
parentc563d8c5b0a4d46676ea21920381c32dbdd66159 (diff)
downloadturns-b95258f419c62f7f38ec6128568df5897e4f5696.tar.xz
turns-b95258f419c62f7f38ec6128568df5897e4f5696.zip
adw: clean up property definitions
Diffstat (limited to 'adw/src/toast.cpp')
-rw-r--r--adw/src/toast.cpp58
1 files changed, 48 insertions, 10 deletions
diff --git a/adw/src/toast.cpp b/adw/src/toast.cpp
index d5b372e..4d66c93 100644
--- a/adw/src/toast.cpp
+++ b/adw/src/toast.cpp
@@ -1,7 +1,6 @@
#include "adwaitamm/toast.hpp"
#include "adwaitamm/enums.hpp"
-#include "adwaitamm/helpers/properties.hpp"
#include <glibmm/class.h>
#include <glibmm/object.h>
@@ -43,7 +42,7 @@ namespace Adwaita
if (!gtype_)
{
class_init_func_ = &class_init_function;
- gtype_= adw_toast_get_type();
+ gtype_ = adw_toast_get_type();
}
return *this;
}
@@ -183,42 +182,81 @@ namespace Adwaita
auto Toast::property_action_name() -> Glib::PropertyProxy<Glib::ustring>
{
- return helpers::make_property_proxy<Glib::ustring>(*this, "action-name");
+ return Glib::PropertyProxy<Glib::ustring>(this, "action-name");
+ }
+
+ auto Toast::property_action_name() const -> Glib::PropertyProxy_ReadOnly<Glib::ustring>
+ {
+ return Glib::PropertyProxy_ReadOnly<Glib::ustring>(this, "action-name");
}
auto Toast::property_action_target() -> Glib::PropertyProxy<Glib::VariantBase>
{
- return helpers::make_property_proxy<Glib::VariantBase>(*this, "action-target");
+ return Glib::PropertyProxy<Glib::VariantBase>(this, "action-target");
+ }
+
+ auto Toast::property_action_target() const -> Glib::PropertyProxy_ReadOnly<Glib::VariantBase>
+ {
+ return Glib::PropertyProxy_ReadOnly<Glib::VariantBase>(this, "action-target");
}
auto Toast::property_button_label() -> Glib::PropertyProxy<Glib::ustring>
{
- return helpers::make_property_proxy<Glib::ustring>(*this, "button-label");
+ return Glib::PropertyProxy<Glib::ustring>(this, "button-label");
+ }
+
+ auto Toast::property_button_label() const -> Glib::PropertyProxy_ReadOnly<Glib::ustring>
+ {
+ return Glib::PropertyProxy_ReadOnly<Glib::ustring>(this, "button-label");
}
auto Toast::property_custom_title() -> Glib::PropertyProxy<Gtk::Widget *>
{
- return helpers::make_property_proxy<Gtk::Widget *>(*this, "custom-title");
+ return Glib::PropertyProxy<Gtk::Widget *>(this, "custom-title");
+ }
+
+ auto Toast::property_custom_title() const -> Glib::PropertyProxy_ReadOnly<Gtk::Widget *>
+ {
+ return Glib::PropertyProxy_ReadOnly<Gtk::Widget *>(this, "custom-title");
}
auto Toast::property_priority() -> Glib::PropertyProxy<ToastPriority>
{
- return helpers::make_property_proxy<ToastPriority>(*this, "priority");
+ return Glib::PropertyProxy<ToastPriority>(this, "priority");
}
+ auto Toast::property_priority() const -> Glib::PropertyProxy_ReadOnly<ToastPriority>
+ {
+ return Glib::PropertyProxy_ReadOnly<ToastPriority>(this, "priority");
+ }
auto Toast::property_timeout() -> Glib::PropertyProxy<unsigned>
{
- return helpers::make_property_proxy<unsigned>(*this, "timeout");
+ return Glib::PropertyProxy<unsigned>(this, "timeout");
+ }
+
+ auto Toast::property_timeout() const -> Glib::PropertyProxy_ReadOnly<unsigned>
+ {
+ return Glib::PropertyProxy_ReadOnly<unsigned>(this, "timeout");
}
auto Toast::property_title() -> Glib::PropertyProxy<Glib::ustring>
{
- return helpers::make_property_proxy<Glib::ustring>(*this, "title");
+ return Glib::PropertyProxy<Glib::ustring>(this, "title");
+ }
+
+ auto Toast::property_title() const -> Glib::PropertyProxy_ReadOnly<Glib::ustring>
+ {
+ return Glib::PropertyProxy_ReadOnly<Glib::ustring>(this, "title");
}
auto Toast::property_use_markup() -> Glib::PropertyProxy<bool>
{
- return helpers::make_property_proxy<bool>(*this, "use-markup");
+ return Glib::PropertyProxy<bool>(this, "use-markup");
+ }
+
+ auto Toast::property_use_markup() const -> Glib::PropertyProxy_ReadOnly<bool>
+ {
+ return Glib::PropertyProxy_ReadOnly<bool>(this, "use-markup");
}
auto Toast::signal_button_clicked() -> Glib::SignalProxy<void()>