From eaf87cc4a1f618bf73e38c41e3255680405a4b49 Mon Sep 17 00:00:00 2001 From: Roman Telezhynskyi Date: Sat, 24 Oct 2020 11:42:56 +0300 Subject: [PATCH] Remove pumpkin mode. --- src/app/tape/main.cpp | 11 ----------- src/app/valentina/main.cpp | 11 ----------- src/libs/fervor/fvupdater.cpp | 16 ---------------- src/libs/fervor/fvupdater.h | 3 --- 4 files changed, 41 deletions(-) diff --git a/src/app/tape/main.cpp b/src/app/tape/main.cpp index 95540bb60..b836d341d 100644 --- a/src/app/tape/main.cpp +++ b/src/app/tape/main.cpp @@ -71,17 +71,6 @@ int main(int argc, char *argv[]) MApplication app(argc, argv); app.InitOptions(); - if (FvUpdater::IsStaledTestBuild()) - { - qWarning() << QApplication::translate("Tape", - "This test build is older than %1 days. To provide you with better " - "quality service we restrict the lifetime you can use a test build. " - "To continue using Tape please update to newer test build. The " - "application will be shut down.") - .arg(FvUpdater::testBuildLifetime); - return V_EX_UNAVAILABLE; - } - QTimer::singleShot(0, &app, &MApplication::ProcessCMD); #if defined(APPIMAGE) && defined(Q_OS_LINUX) diff --git a/src/app/valentina/main.cpp b/src/app/valentina/main.cpp index c81cdc045..be6d5d33f 100644 --- a/src/app/valentina/main.cpp +++ b/src/app/valentina/main.cpp @@ -80,17 +80,6 @@ int main(int argc, char *argv[]) VApplication app(argc, argv); app.InitOptions(); - if (FvUpdater::IsStaledTestBuild()) - { - qWarning() << QApplication::translate("Valentina", - "This test build is older than %1 days. To provide you with better " - "quality service we restrict the lifetime you can use a test build. " - "To continue using Valentina please update to newer test build. The " - "application will be shut down.") - .arg(FvUpdater::testBuildLifetime); - return V_EX_UNAVAILABLE; - } - if (VApplication::IsGUIMode()) { // Set feed URL before doing anything else diff --git a/src/libs/fervor/fvupdater.cpp b/src/libs/fervor/fvupdater.cpp index e9ee9128c..a5703b469 100644 --- a/src/libs/fervor/fvupdater.cpp +++ b/src/libs/fervor/fvupdater.cpp @@ -53,8 +53,6 @@ #include "fvavailableupdate.h" #include "fvupdatewindow.h" -const int FvUpdater::testBuildLifetime = 90; - namespace { Q_GLOBAL_STATIC_WITH_ARGS(const QString, defaultFeedURL, @@ -134,20 +132,6 @@ bool FvUpdater::IsTestBuild() return (version != 0x0 && version != APP_VERSION); } -//--------------------------------------------------------------------------------------------------------------------- -bool FvUpdater::IsStaledTestBuild() -{ - if (IsTestBuild()) - { - QDate builtDate = QLocale::c().toDate(QStringLiteral(__DATE__).simplified(), QStringLiteral("MMM d yyyy")); - return builtDate.daysTo(QDate::currentDate()) > testBuildLifetime; - } - else - { - return false; - } -} - //--------------------------------------------------------------------------------------------------------------------- FvUpdater::FvUpdater() : QObject(nullptr), diff --git a/src/libs/fervor/fvupdater.h b/src/libs/fervor/fvupdater.h index 9ff720558..f02696a19 100644 --- a/src/libs/fervor/fvupdater.h +++ b/src/libs/fervor/fvupdater.h @@ -46,7 +46,6 @@ public: static QString CurrentFeedURL(); static int CurrentVersion(); static bool IsTestBuild(); - static bool IsStaledTestBuild(); // Set / get feed URL void SetFeedURL(const QUrl &feedURL); @@ -56,8 +55,6 @@ public: bool IsDropOnFinnish() const; void SetDropOnFinnish(bool value); - static const int testBuildLifetime; - public slots: // Check for updates bool CheckForUpdates(bool silentAsMuchAsItCouldGet = true);