diff --git a/CMakeLists.txt b/CMakeLists.txt index 22c7d17b08b72856cad57929e6b60e4fec74d2c5..57d50759be6d18bccc63dc8519921c50a7885f54 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -798,7 +798,6 @@ else() MACOSX_BUNDLE_COPYRIGHT "${PROJ_COPYRIGHT}") if(APPSTORE) message(STATUS "app store version") - add_definitions(-DAPPSTORE) set_target_properties(${PROJECT_NAME} PROPERTIES XCODE_ATTRIBUTE_CODE_SIGN_ENTITLEMENTS "${CMAKE_CURRENT_SOURCE_DIR}/resources/entitlements/appstore/Jami.entitlements") else() diff --git a/src/app/appsettingsmanager.h b/src/app/appsettingsmanager.h index 9ed4984d46fc38fbc25098b3388d56dbfb7c9e98..9e81c98ae65bb605de68fea6ec405a8fb4124fbd 100644 --- a/src/app/appsettingsmanager.h +++ b/src/app/appsettingsmanager.h @@ -33,41 +33,6 @@ extern const QString defaultDownloadPath; // clang-format off -#ifdef APPSTORE -#define KEYS \ - X(MinimizeOnClose, false) \ - X(DownloadPath, defaultDownloadPath) \ - X(ScreenshotPath, {}) \ - X(EnableNotifications, true) \ - X(EnableTypingIndicator, true) \ - X(EnableReadReceipt, true) \ - X(AcceptTransferBelow, 20) \ - X(AutoAcceptFiles, true) \ - X(DisplayHyperlinkPreviews, true) \ - X(AppTheme, "System") \ - X(BaseZoom, 1.0) \ - X(ParticipantsSide, false) \ - X(HideSelf, true) \ - X(HideSpectators, false) \ - X(AutoUpdate, true) \ - X(PluginAutoUpdate, false) \ - X(StartMinimized, false) \ - X(ShowChatviewHorizontally, true) \ - X(NeverShowMeAgain, false) \ - X(WindowGeometry, QRectF(qQNaN(), qQNaN(), 0., 0.)) \ - X(WindowState, QWindow::AutomaticVisibility) \ - X(EnableExperimentalSwarm, false) \ - X(LANG, "SYSTEM") \ - X(PluginStoreEndpoint, "https://plugins.jami.net") \ - X(PositionShareDuration, 15) \ - X(PositionShareLimit, true) \ - X(FlipSelf, true) \ - X(ShowMardownOption, false) \ - X(ChatViewEnterIsNewLine, false) \ - X(ShowSendOption, false) \ - X(EnablePtt, false) \ - X(pttKey, 36) -#else #define KEYS \ X(MinimizeOnClose, false) \ X(DownloadPath, defaultDownloadPath) \ @@ -104,8 +69,6 @@ extern const QString defaultDownloadPath; X(Donation2023EndDate, "2024-01-31 00:00") \ X(EnablePtt, false) \ X(pttKey, 36) -#endif - /* * A class to expose settings keys in both c++ and QML. * Note: this is using a non-constructable class instead of a diff --git a/src/app/mainapplication.cpp b/src/app/mainapplication.cpp index 94fcb6921af6ffd395571eb93d1ad74e50b6300b..d94b0f27c273936b576b8f987814a4d61e0b4447 100644 --- a/src/app/mainapplication.cpp +++ b/src/app/mainapplication.cpp @@ -105,8 +105,7 @@ ScreenInfo::onPhysicalDotsPerInchChanged() } MainApplication::MainApplication(int& argc, char** argv) - : QApplication(argc, argv) - , isCleanupped(false) + : QApplication(argc, argv), isCleanupped(false) { const char* qtVersion = qVersion(); qInfo() << "Using Qt runtime version:" << qtVersion; @@ -197,12 +196,6 @@ MainApplication::init() engine_.get()->rootContext()->setContextProperty("WITH_WEBENGINE", QVariant(false)); #endif -#ifdef APPSTORE - engine_.get()->rootContext()->setContextProperty("APPSTORE", QVariant(true)); -#else - engine_.get()->rootContext()->setContextProperty("APPSTORE", QVariant(false)); -#endif - initQmlLayer(); settingsManager_->setValue(Settings::Key::StartMinimized, diff --git a/src/app/settingsview/components/SystemSettingsPage.qml b/src/app/settingsview/components/SystemSettingsPage.qml index 5d0c9873359c002f946b42f42e4e118f0954f22e..abc4721362a144979bee2ff9b0ad2c277ee1a4d1 100644 --- a/src/app/settingsview/components/SystemSettingsPage.qml +++ b/src/app/settingsview/components/SystemSettingsPage.qml @@ -84,7 +84,7 @@ SettingsPageBase { ToggleSwitch { id: enableDonation width: parent.width - visible: (new Date() >= new Date(Date.parse("2023-11-01")) && !APPSTORE) + visible: new Date() >= new Date(Date.parse("2023-11-01")) checked: UtilsAdapter.getAppValue(Settings.Key.IsDonationVisible) labelText: JamiStrings.enableDonation diff --git a/src/app/tipsmodel.cpp b/src/app/tipsmodel.cpp index 516a77bca3acf7c1d869945536ade335664aa8a1..914713a61abf00274e41b113a355ae867aca6d0f 100644 --- a/src/app/tipsmodel.cpp +++ b/src/app/tipsmodel.cpp @@ -75,13 +75,10 @@ TipsModel::reset() beginResetModel(); tips_.clear(); -#ifndef APPSTORE QDate date = QDate::currentDate(); if (date >= QDate::fromString("2023-11-27", "yyyy-MM-dd")) { tips_.append({{"id", "14"}, {"title", tr("Donate")}, {"desc", ""}, {"type", "donation"}}); } -#endif - tips_.append({{"id", "0"}, {"title", tr("Customize")}, {"desc", ""}, {"type", "customize"}}); tips_.append({{"id", "13"}, {"title", tr("Backup account")}, {"desc", ""}, {"type", "backup"}}); tips_.append({{"id", "1"},