From 77a4d6f3ca3a506f24a64262f09456058247b1bb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EA=A6=8C=EA=A6=AB=EA=A6=B6=EA=A6=8F=EA=A7=80=EA=A6=A6?= =?UTF-8?q?=EA=A6=BF=EA=A6=A7=EA=A6=AE=EA=A6=91=EA=A6=A9=EA=A6=AD=EA=A7=80?= Date: Tue, 4 Apr 2023 19:38:06 +0800 Subject: Initial commit, draft that compiles --- bootstrap.cxx | 37 +++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 bootstrap.cxx (limited to 'bootstrap.cxx') diff --git a/bootstrap.cxx b/bootstrap.cxx new file mode 100644 index 0000000..22ba9cd --- /dev/null +++ b/bootstrap.cxx @@ -0,0 +1,37 @@ +#include "bootstrap.hxx" + +Bootstrap::Bootstrap(QObject *parent): + QObject(parent), + m_theme(Theme::Light), + m_purpose(Purpose::None) +{ +} + +Bootstrap *Bootstrap::qmlAttachedProperties(QObject *object) +{ + return new Bootstrap(object); +} + +Bootstrap::Theme Bootstrap::theme() const +{ + return m_theme; +} + +void Bootstrap::setTheme(Bootstrap::Theme theme) +{ + if (theme == m_theme) return; + m_theme = theme; + emit themeChanged(); +} + +Bootstrap::Purpose Bootstrap::purpose() const +{ + return m_purpose; +} + +void Bootstrap::setPurpose(Bootstrap::Purpose purpose) +{ + if (purpose == m_purpose) return; + m_purpose = purpose; + emit purposeChanged(); +} -- cgit v1.2.3