This commit is contained in:
love-code-yeyixiao 2024-05-04 21:13:02 +08:00
parent d0ece79771
commit a2601c0682
2 changed files with 214 additions and 208 deletions

View File

@ -7,7 +7,7 @@
<x>0</x> <x>0</x>
<y>0</y> <y>0</y>
<width>695</width> <width>695</width>
<height>508</height> <height>565</height>
</rect> </rect>
</property> </property>
<property name="sizePolicy"> <property name="sizePolicy">
@ -1941,218 +1941,222 @@ Unlike the preview channel, it does not include untested, potentially breaking,
<item row="0" column="0"> <item row="0" column="0">
<widget class="QTabWidget" name="tabsAdvanced"> <widget class="QTabWidget" name="tabsAdvanced">
<property name="currentIndex"> <property name="currentIndex">
<number>1</number> <number>0</number>
</property> </property>
<widget class="QWidget" name="tabSandbox"> <widget class="QWidget" name="tabSandbox">
<attribute name="title"> <attribute name="title">
<string>Sandboxie Config</string> <string>Sandboxie Config</string>
</attribute> </attribute>
<layout class="QGridLayout" name="gridLayout_20"> <layout class="QGridLayout" name="gridLayout_18">
<item row="0" column="0"> <item row="0" column="0">
<layout class="QGridLayout" name="gridLayout_18"> <widget class="QLabel" name="lblBoxRoot">
<item row="4" column="2" colspan="5"> <property name="font">
<widget class="QLineEdit" name="ipcRoot"/> <font>
</item> <weight>75</weight>
<item row="5" column="2"> <bold>true</bold>
<spacer name="horizontalSpacer_12"> <kerning>true</kerning>
<property name="orientation"> </font>
<enum>Qt::Horizontal</enum> </property>
</property> <property name="text">
<property name="sizeHint" stdset="0"> <string>Sandbox default</string>
<size> </property>
<width>40</width> </widget>
<height>20</height> </item>
</size> <item row="1" column="0">
</property> <widget class="QLabel" name="label_7">
</spacer> <property name="text">
</item> <string>Default sandbox:</string>
<item row="1" column="2" colspan="2"> </property>
<widget class="QComboBox" name="cmbDefault"/> <property name="alignment">
</item> <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
<item row="2" column="7"> </property>
<widget class="QPushButton" name="btnBrowse"> </widget>
<property name="maximumSize"> </item>
<size> <item row="1" column="2">
<width>23</width> <widget class="QComboBox" name="cmbDefault"/>
<height>16777215</height> </item>
</size> <item row="1" column="5">
</property> <widget class="QCheckBox" name="chkAutoRoot">
<property name="text"> <property name="text">
<string>...</string> <string>Portable root folder</string>
</property> </property>
</widget> </widget>
</item> </item>
<item row="2" column="2" colspan="5"> <item row="2" column="0" colspan="2">
<widget class="QLineEdit" name="fileRoot"/> <widget class="QLabel" name="label_15">
</item> <property name="text">
<item row="0" column="0"> <string>Sandbox &lt;a href=&quot;sbie://docs/filerootpath&quot;&gt;file system root&lt;/a&gt;: </string>
<widget class="QLabel" name="lblBoxRoot"> </property>
<property name="font"> <property name="alignment">
<font> <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
<weight>75</weight> </property>
<bold>true</bold> <property name="openExternalLinks">
<kerning>true</kerning> <bool>true</bool>
</font> </property>
</property> </widget>
<property name="text"> </item>
<string>Sandbox default</string> <item row="2" column="2" colspan="2">
</property> <widget class="QLineEdit" name="fileRoot"/>
</widget> </item>
</item> <item row="2" column="6">
<item row="3" column="2" colspan="5"> <widget class="QPushButton" name="btnBrowse">
<widget class="QLineEdit" name="regRoot"/> <property name="maximumSize">
</item> <size>
<item row="1" column="5" colspan="2"> <width>23</width>
<widget class="QCheckBox" name="chkAutoRoot"> <height>16777215</height>
<property name="text"> </size>
<string>Portable root folder</string> </property>
</property> <property name="text">
</widget> <string>...</string>
</item> </property>
<item row="4" column="0" colspan="2"> </widget>
<widget class="QLabel" name="label_17"> </item>
<property name="text"> <item row="3" column="0" colspan="2">
<string>Sandbox &lt;a href=&quot;sbie://docs/ipcrootpath&quot;&gt;ipc root&lt;/a&gt;: </string> <widget class="QLabel" name="label_16">
</property> <property name="text">
<property name="alignment"> <string>Sandbox &lt;a href=&quot;sbie://docs/keyrootpath&quot;&gt;registry root&lt;/a&gt;: </string>
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> </property>
</property> <property name="alignment">
<property name="openExternalLinks"> <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
<bool>true</bool> </property>
</property> <property name="openExternalLinks">
</widget> <bool>true</bool>
</item> </property>
<item row="1" column="0" colspan="2"> </widget>
<widget class="QLabel" name="label_7"> </item>
<property name="text"> <item row="3" column="2" colspan="2">
<string>Default sandbox:</string> <widget class="QLineEdit" name="regRoot"/>
</property> </item>
<property name="alignment"> <item row="4" column="0">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> <widget class="QLabel" name="label_17">
</property> <property name="text">
</widget> <string>Sandbox &lt;a href=&quot;sbie://docs/ipcrootpath&quot;&gt;ipc root&lt;/a&gt;: </string>
</item> </property>
<item row="6" column="1" colspan="6"> <property name="alignment">
<widget class="QCheckBox" name="chkWFP"> <set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
<property name="text"> </property>
<string>Use Windows Filtering Platform to restrict network access</string> <property name="openExternalLinks">
</property> <bool>true</bool>
</widget> </property>
</item> </widget>
<item row="2" column="0" colspan="2"> </item>
<widget class="QLabel" name="label_15"> <item row="4" column="2" colspan="2">
<property name="text"> <widget class="QLineEdit" name="ipcRoot"/>
<string>Sandbox &lt;a href=&quot;sbie://docs/filerootpath&quot;&gt;file system root&lt;/a&gt;: </string> </item>
</property> <item row="5" column="0" colspan="2">
<property name="alignment"> <widget class="QLabel" name="lblBoxFeatures">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> <property name="font">
</property> <font>
<property name="openExternalLinks"> <weight>75</weight>
<bool>true</bool> <bold>true</bold>
</property> <kerning>true</kerning>
</widget> </font>
</item> </property>
<item row="7" column="1" colspan="6"> <property name="text">
<widget class="QCheckBox" name="chkObjCb"> <string>Sandboxing features</string>
<property name="text"> </property>
<string>Activate Kernel Mode Object Filtering</string> </widget>
</property> </item>
</widget> <item row="5" column="2">
</item> <spacer name="horizontalSpacer_12">
<item row="3" column="0" colspan="2"> <property name="orientation">
<widget class="QLabel" name="label_16"> <enum>Qt::Horizontal</enum>
<property name="text"> </property>
<string>Sandbox &lt;a href=&quot;sbie://docs/keyrootpath&quot;&gt;registry root&lt;/a&gt;: </string> <property name="sizeHint" stdset="0">
</property> <size>
<property name="alignment"> <width>77</width>
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set> <height>20</height>
</property> </size>
<property name="openExternalLinks"> </property>
<bool>true</bool> </spacer>
</property> </item>
</widget> <item row="6" column="1" colspan="5">
</item> <widget class="QCheckBox" name="chkWFP">
<item row="10" column="2"> <property name="text">
<spacer name="verticalSpacer_2"> <string>Use Windows Filtering Platform to restrict network access</string>
<property name="orientation"> </property>
<enum>Qt::Vertical</enum> </widget>
</property> </item>
<property name="sizeHint" stdset="0"> <item row="7" column="1" colspan="3">
<size> <widget class="QCheckBox" name="chkObjCb">
<width>20</width> <property name="text">
<height>40</height> <string>Activate Kernel Mode Object Filtering</string>
</size> </property>
</property> </widget>
</spacer> </item>
</item> <item row="8" column="1" colspan="5">
<item row="10" column="4"> <widget class="QCheckBox" name="chkWin32k">
<spacer name="horizontalSpacer_5"> <property name="text">
<property name="orientation"> <string>Hook selected Win32k system calls to enable GPU acceleration (experimental)</string>
<enum>Qt::Horizontal</enum> </property>
</property> </widget>
<property name="sizeHint" stdset="0"> </item>
<size> <item row="9" column="1" colspan="4">
<width>40</width> <widget class="QCheckBox" name="chkSbieLogon">
<height>20</height> <property name="text">
</size> <string>Use a Sandboxie login instead of an anonymous token</string>
</property> </property>
</spacer> </widget>
</item> </item>
<item row="5" column="0" colspan="2"> <item row="10" column="1" colspan="6">
<widget class="QLabel" name="lblBoxFeatures"> <widget class="QCheckBox" name="chkForceExplorerChild">
<property name="font"> <property name="text">
<font> <string>Let the child processes of the default File Explorer automatically enter
<weight>75</weight> the default sandbox</string>
<bold>true</bold> </property>
<kerning>true</kerning> </widget>
</font> </item>
</property> <item row="11" column="1">
<property name="text"> <spacer name="horizontalSpacer_4">
<string>Sandboxing features</string> <property name="orientation">
</property> <enum>Qt::Horizontal</enum>
</widget> </property>
</item> <property name="sizeHint" stdset="0">
<item row="8" column="1" colspan="6"> <size>
<widget class="QCheckBox" name="chkWin32k"> <width>76</width>
<property name="text"> <height>20</height>
<string>Hook selected Win32k system calls to enable GPU acceleration (experimental)</string> </size>
</property> </property>
</widget> </spacer>
</item> </item>
<item row="9" column="1" colspan="6"> <item row="11" column="2">
<widget class="QCheckBox" name="chkSbieLogon"> <spacer name="verticalSpacer_2">
<property name="text"> <property name="orientation">
<string>Use a Sandboxie login instead of an anonymous token</string> <enum>Qt::Vertical</enum>
</property> </property>
</widget> <property name="sizeHint" stdset="0">
</item> <size>
<item row="10" column="1"> <width>20</width>
<spacer name="horizontalSpacer_4"> <height>147</height>
<property name="orientation"> </size>
<enum>Qt::Horizontal</enum> </property>
</property> </spacer>
<property name="sizeHint" stdset="0"> </item>
<size> <item row="11" column="3">
<width>40</width> <spacer name="horizontalSpacer_15">
<height>20</height> <property name="orientation">
</size> <enum>Qt::Horizontal</enum>
</property> </property>
</spacer> <property name="sizeHint" stdset="0">
</item> <size>
<item row="10" column="3"> <width>76</width>
<spacer name="horizontalSpacer_15"> <height>20</height>
<property name="orientation"> </size>
<enum>Qt::Horizontal</enum> </property>
</property> </spacer>
<property name="sizeHint" stdset="0"> </item>
<size> <item row="11" column="4">
<width>40</width> <spacer name="horizontalSpacer_5">
<height>20</height> <property name="orientation">
</size> <enum>Qt::Horizontal</enum>
</property> </property>
</spacer> <property name="sizeHint" stdset="0">
</item> <size>
</layout> <width>76</width>
<height>20</height>
</size>
</property>
</spacer>
</item> </item>
</layout> </layout>
</widget> </widget>

View File

@ -418,6 +418,7 @@ CSettingsWindow::CSettingsWindow(QWidget* parent)
connect(ui.chkObjCb, SIGNAL(stateChanged(int)), this, SLOT(OnFeaturesChanged())); connect(ui.chkObjCb, SIGNAL(stateChanged(int)), this, SLOT(OnFeaturesChanged()));
if (CurrentVersion.value("CurrentBuild").toInt() < 14393) // Windows 10 RS1 and later if (CurrentVersion.value("CurrentBuild").toInt() < 14393) // Windows 10 RS1 and later
ui.chkWin32k->setEnabled(false); ui.chkWin32k->setEnabled(false);
connect(ui.chkForceExplorerChild, SIGNAL(stateChanged(int)), this, SLOT(OnFeaturesChanged()));
//connect(ui.chkWin32k, SIGNAL(stateChanged(int)), this, SLOT(OnFeaturesChanged())); //connect(ui.chkWin32k, SIGNAL(stateChanged(int)), this, SLOT(OnFeaturesChanged()));
m_FeaturesChanged = false; m_FeaturesChanged = false;
connect(ui.chkWin32k, SIGNAL(stateChanged(int)), this, SLOT(OnGeneralChanged())); connect(ui.chkWin32k, SIGNAL(stateChanged(int)), this, SLOT(OnGeneralChanged()));
@ -948,6 +949,7 @@ void CSettingsWindow::LoadSettings()
ui.chkMinimize->setChecked(theConf->GetBool("Options/MinimizeToTray", false)); ui.chkMinimize->setChecked(theConf->GetBool("Options/MinimizeToTray", false));
ui.chkSingleShow->setChecked(theConf->GetBool("Options/TraySingleClick", false)); ui.chkSingleShow->setChecked(theConf->GetBool("Options/TraySingleClick", false));
ui.chkForceExplorerChild->setChecked(strcmp(theAPI->GetGlobalSettings()->GetText("ForceExplorerChild").toStdString().c_str(), theAPI->GetGlobalSettings()->GetText("DefalutBox").toStdString().c_str())==0);
OnLoadAddon(); OnLoadAddon();
bool bImDiskReady = theGUI->IsImDiskReady(); bool bImDiskReady = theGUI->IsImDiskReady();
@ -1633,7 +1635,7 @@ void CSettingsWindow::SaveSettings()
theConf->SetValue("Options/OnClose", ui.cmbOnClose->currentData()); theConf->SetValue("Options/OnClose", ui.cmbOnClose->currentData());
theConf->SetValue("Options/MinimizeToTray", ui.chkMinimize->isChecked()); theConf->SetValue("Options/MinimizeToTray", ui.chkMinimize->isChecked());
theConf->SetValue("Options/TraySingleClick", ui.chkSingleShow->isChecked()); theConf->SetValue("Options/TraySingleClick", ui.chkSingleShow->isChecked());
theAPI->GetGlobalSettings()->SetText("ForceExplorerChild", theAPI->GetGlobalSettings()->GetText("DefaultBox"));
if (theAPI->IsConnected()) if (theAPI->IsConnected())
{ {
try try