diff options
Diffstat (limited to 'src/repeatrule.h')
| -rw-r--r-- | src/repeatrule.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/repeatrule.h b/src/repeatrule.h index 59dfceb..f686197 100644 --- a/src/repeatrule.h +++ b/src/repeatrule.h @@ -18,6 +18,7 @@ #pragma once +#include <QCoreApplication> #include <QDate> #include <QList> #include <QString> @@ -29,6 +30,13 @@ /// is what lets every row of the spec's repeat table be tested as a string. struct RepeatRule { + // describe() formats the rule in words, and lupdate needs the class's own + // context to extract them (AGENTS.md: a class needs this macro, an array + // needs QT_TRANSLATE_NOOP on the literal). The macro ends in a private: + // section, so the explicit public: restores the fields below. + Q_DECLARE_TR_FUNCTIONS(RepeatRule) +public: + enum class Freq { None, Daily, Weekly, Monthly, Yearly }; /// Monthly and Yearly only: on a day of the month, or on the Nth weekday. enum class By { MonthDay, Weekday }; |
