diff --git a/CHANGELOG.md b/CHANGELOG.md index a7866cd0..9bbfcbdf 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,6 +9,9 @@ This project adheres to [Semantic Versioning](http://semver.org/). ## [1.4.2 / 5.59.2] - 2022-10-?? +### Added +- added tooltips to resource access modes [#2300](https://github.com/sandboxie-plus/Sandboxie/issues/2300) + ### Fixed - fixed wrong button captions in the breakout process page - fixed issue with saving box recovery options diff --git a/SandboxiePlus/SandMan/Windows/OptionsAccess.cpp b/SandboxiePlus/SandMan/Windows/OptionsAccess.cpp index c6d962df..cc930858 100644 --- a/SandboxiePlus/SandMan/Windows/OptionsAccess.cpp +++ b/SandboxiePlus/SandMan/Windows/OptionsAccess.cpp @@ -312,6 +312,23 @@ QString COptionsWindow::GetAccessModeStr(EAccessMode Mode) return tr("Unknown"); } +QString COptionsWindow::GetAccessModeTip(EAccessMode Mode) +{ + switch (Mode) + { + case eNormal: return tr("Regular sandboxie behaviore, allow read and copy on write."); + case eOpen: return tr("Allow write access outside the sandbox."); + case eOpen4All: return tr("Allow write access outside the sandbox, also for applciations installed inside the sandbox."); + case eNoRename: return tr("Don't rename window classes."); + case eClosed: return tr("Deny access to host location and prevetn creation of boxed copy."); + case eClosedRT: return tr("Block access to WinRT class."); + case eReadOnly: return tr("Allow read only access only."); + case eBoxOnly: return tr("Hide host files, folders or registry keys from sandboxed processes."); + case eIgnoreUIPI: return tr("Ignore UIPI restrictions for processes."); + } + return tr("Unknown"); +} + QString COptionsWindow::GetAccessTypeStr(EAccessType Type) { switch (Type) @@ -616,8 +633,10 @@ void COptionsWindow::OnAccessItemDoubleClicked(QTreeWidgetItem* pItem, int Colum pTree->setItemWidget(pItem, 1, pProgram); QComboBox* pMode = new QComboBox(); - foreach(EAccessMode Mode, GetAccessModes((EAccessType)Type)) + foreach(EAccessMode Mode, GetAccessModes((EAccessType)Type)) { pMode->addItem(GetAccessModeStr(Mode), (int)Mode); + pMode->setItemData(pMode->count() - 1, GetAccessModeTip(Mode), Qt::ToolTipRole); + } pMode->setCurrentIndex(pMode->findData(pItem->data(2, Qt::UserRole))); pTree->setItemWidget(pItem, 2, pMode); diff --git a/SandboxiePlus/SandMan/Windows/OptionsWindow.h b/SandboxiePlus/SandMan/Windows/OptionsWindow.h index 89e061f6..52b0822a 100644 --- a/SandboxiePlus/SandMan/Windows/OptionsWindow.h +++ b/SandboxiePlus/SandMan/Windows/OptionsWindow.h @@ -384,6 +384,7 @@ protected: void LoadAccessListTmpl(EAccessType Type, bool bChecked, bool bUpdate = false); QString GetAccessTypeStr(EAccessType Type); QString GetAccessModeStr(EAccessMode Mode); + QString GetAccessModeTip(EAccessMode Mode); void ParseAndAddAccessEntry(EAccessEntry EntryType, const QString& Value, bool disabled = false, const QString& Template = QString()); void ParseAndAddAccessEntry(EAccessType Type, EAccessMode Mode, const QString& Value, bool disabled = false, const QString& Template = QString()); void AddAccessEntry(EAccessType Type, EAccessMode Mode, QString Program, const QString& Path, bool disabled = false, const QString& Template = QString());