diff --git a/CHANGELOG.md b/CHANGELOG.md index a8749ecf..95f8e54b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,7 +8,8 @@ This project adheres to [Semantic Versioning](http://semver.org/). ## [1.13.7 / 5.68.7] - 2024-04- ### Added -- Added DropAdmin and improved related checkboxes #3851 https://github.com/sandboxie-plus/Sandboxie/pull/3851 (thanks offhub) +- added DropAdmin and improved related checkboxes #3851 https://github.com/sandboxie-plus/Sandboxie/pull/3851 (thanks offhub) +- added file version info doe SbieDll.dll and SbieSvc.exe to the Plus About dialog ### Fixed - fixed issue with start agent option [#3844](https://github.com/sandboxie-plus/Sandboxie/pull/3844) (thanks offhub) diff --git a/Sandboxie/common/my_version.h b/Sandboxie/common/my_version.h index bde9e8ea..cc410258 100644 --- a/Sandboxie/common/my_version.h +++ b/Sandboxie/common/my_version.h @@ -21,9 +21,22 @@ #ifndef _MY_VERSION_H #define _MY_VERSION_H -#define MY_VERSION_BINARY 5,68,7 -#define MY_VERSION_STRING "5.68.7" -#define MY_ABI_VERSION 0x56800 +#define STR2(X) #X +#define STR(X) STR2(X) + +#define VERSION_MJR 5 +#define VERSION_MIN 70 +#define VERSION_REV 0 +#define VERSION_UPD 0 + +#if VERSION_UPD > 0 + #define MY_VERSION_BINARY VERSION_MJR,VERSION_MIN,VERSION_REV,VERSION_UPD + #define MY_VERSION_STRING STR(VERSION_MJR.VERSION_MIN.VERSION_REV.VERSION_UPD) +#else + #define MY_VERSION_BINARY VERSION_MJR,VERSION_MIN,VERSION_REV + #define MY_VERSION_STRING STR(VERSION_MJR.VERSION_MIN.VERSION_REV) +#endif +#define MY_ABI_VERSION 0x56800 // These #defines are used by either Resource Compiler or NSIS installer #define SBIE_INSTALLER_PATH "..\\Bin\\" diff --git a/SandboxiePlus/SandMan/SandMan.cpp b/SandboxiePlus/SandMan/SandMan.cpp index 9a84071d..9b446df3 100644 --- a/SandboxiePlus/SandMan/SandMan.cpp +++ b/SandboxiePlus/SandMan/SandMan.cpp @@ -4101,16 +4101,18 @@ bool CSandMan::IsWFPEnabled() const return (g_FeatureFlags & CSbieAPI::eSbieFeatureWFP) != 0; } -QString CSandMan::GetVersion() +QString CSandMan::GetVersion(bool bWithUpdates) { - QString Version = QString::number(VERSION_MJR) + "." + QString::number(VERSION_MIN) //.rightJustified(2, '0') -//#if VERSION_REV > 0 || VERSION_MJR == 0 - + "." + QString::number(VERSION_REV) -//#endif + QString Version = QString::number(VERSION_MJR) + "." + QString::number(VERSION_MIN) + "." + QString::number(VERSION_REV); + if (bWithUpdates) { + int iUpdate = COnlineUpdater::GetCurrentUpdate(); + if (iUpdate) + Version += QChar('a' + (iUpdate - 1)); + } #if VERSION_UPD > 0 - + QChar('a' + VERSION_UPD - 1) + else + Version += QChar('a' + VERSION_UPD - 1); #endif - ; return Version; } @@ -4293,30 +4295,39 @@ void CSandMan::OnAbout() { if (sender() == m_pAbout) { + if ((QGuiApplication::queryKeyboardModifiers() & Qt::ControlModifier) != 0){ + CSupportDialog::CheckSupport(); + return; + } + QString AboutCaption = tr( "
Version %1
" - "Copyright (c) 2020-2024 by DavidXanatos
" - ).arg(theGUI->GetVersion()); + "" MY_COPYRIGHT_STRING "
" + ).arg(theGUI->GetVersion(true)); QString CertInfo; - if (!g_Certificate.isEmpty()) { - CertInfo = tr("This copy of Sandboxie+ is certified for: %1").arg(GetArguments(g_Certificate, L'\n', L':').value("NAME")); - } else { - CertInfo = tr("Sandboxie+ is free for personal and non-commercial use."); - } + if (!g_Certificate.isEmpty()) + CertInfo = tr("This copy of Sandboxie-Plus is certified for: %1").arg(GetArguments(g_Certificate, L'\n', L':').value("NAME")); + else + CertInfo = tr("Sandboxie-Plus is free for personal and non-commercial use."); + + QString SbiePath = theAPI->GetSbiePath(); QString AboutText = tr( "Sandboxie-Plus is an open source continuation of Sandboxie.