From 1cf271f3a6c988aa91a62b8d552ddc523cc1d3fc Mon Sep 17 00:00:00 2001 From: acetone <63557806+freeacetone@users.noreply.github.com> Date: Sun, 24 Apr 2022 06:52:40 -0400 Subject: [PATCH] Update zerostoragecaptcha.h --- zerostoragecaptcha.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/zerostoragecaptcha.h b/zerostoragecaptcha.h index e75ed07..e13bc57 100644 --- a/zerostoragecaptcha.h +++ b/zerostoragecaptcha.h @@ -53,6 +53,7 @@ public: ZeroStorageCaptcha(); static bool validate(const QString& answer, const QString& token); static ZeroStorageCaptchaContainer getCaptcha(int length = 5, int difficulty = 3); + static void setOnlyNumbersMode(bool enabled = false) { m_onlyNumbers = enabled; } QString captchaText() const { return m_captchaText; } QString captchaToken() const; @@ -93,6 +94,8 @@ public: void updateCaptcha(); private: + static bool m_onlyNumbers; + qreal m_hmod1; qreal m_hmod2; @@ -117,4 +120,4 @@ private: int m_noisePointSize; }; -#endif // ZEROSTORAGECAPTCHA_H +#endif // ZEROSTORAGECAPTCHA_H