This commit is contained in:
arm64v8a
2023-01-22 17:20:32 +09:00
parent 5e22651647
commit 8fa966aba4
3 changed files with 108 additions and 80 deletions

View File

@@ -81,10 +81,8 @@ void EditCustom::onStart(QSharedPointer<NekoRay::ProxyEntity> _ent) {
if (preset_core == "internal") {
ui->core->hide();
ui->core_l->setText(tr("Outbound JSON, please read the documentation."));
ui->command->hide();
ui->command_l->hide();
ui->config_suffix->hide();
ui->config_suffix_l->hide();
ui->w_ext1->hide();
ui->w_ext2->hide();
}
// Preview

View File

@@ -46,88 +46,116 @@
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_2">
<item>
<widget class="QLabel" name="command_l">
<property name="text">
<string>Command</string>
</property>
</widget>
</item>
<item>
<widget class="QLineEdit" name="command">
<property name="placeholderText">
<string notr="true">%config%</string>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="config_suffix_l">
<property name="text">
<string>Config Suffix</string>
</property>
</widget>
</item>
<item>
<widget class="QComboBox" name="config_suffix">
<property name="editable">
<bool>true</bool>
</property>
<item>
<widget class="QWidget" name="w_ext1" native="true">
<layout class="QHBoxLayout" name="horizontalLayout_2">
<property name="leftMargin">
<number>0</number>
</property>
<property name="topMargin">
<number>0</number>
</property>
<property name="rightMargin">
<number>0</number>
</property>
<property name="bottomMargin">
<number>0</number>
</property>
<item>
<widget class="QLabel" name="command_l">
<property name="text">
<string notr="true"/>
<string>Command</string>
</property>
</item>
<item>
</widget>
</item>
<item>
<widget class="QLineEdit" name="command">
<property name="placeholderText">
<string notr="true">%config%</string>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="config_suffix_l">
<property name="text">
<string notr="true">json</string>
<string>Config Suffix</string>
</property>
</item>
<item>
<property name="text">
<string notr="true">yml</string>
</widget>
</item>
<item>
<widget class="QComboBox" name="config_suffix">
<property name="editable">
<bool>true</bool>
</property>
</item>
</widget>
</item>
</layout>
<item>
<property name="text">
<string notr="true"/>
</property>
</item>
<item>
<property name="text">
<string notr="true">json</string>
</property>
</item>
<item>
<property name="text">
<string notr="true">yml</string>
</property>
</item>
</widget>
</item>
</layout>
</widget>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_3">
<item>
<widget class="QLabel" name="label">
<property name="toolTip">
<string>Random if it's empty or zero.</string>
</property>
<property name="text">
<string notr="true">Mapping Port</string>
</property>
</widget>
</item>
<item>
<widget class="QLineEdit" name="mapping_port"/>
</item>
<item>
<widget class="QLabel" name="label_2">
<property name="toolTip">
<string>Random if it's empty or zero.</string>
</property>
<property name="text">
<string notr="true">Socks Port</string>
</property>
</widget>
</item>
<item>
<widget class="QLineEdit" name="socks_port"/>
</item>
<item>
<widget class="QPushButton" name="preview">
<property name="text">
<string>Preview</string>
</property>
</widget>
</item>
</layout>
<widget class="QWidget" name="w_ext2" native="true">
<layout class="QHBoxLayout" name="horizontalLayout_3">
<property name="leftMargin">
<number>0</number>
</property>
<property name="topMargin">
<number>0</number>
</property>
<property name="rightMargin">
<number>0</number>
</property>
<property name="bottomMargin">
<number>0</number>
</property>
<item>
<widget class="QLabel" name="label">
<property name="toolTip">
<string>Random if it's empty or zero.</string>
</property>
<property name="text">
<string notr="true">Mapping Port</string>
</property>
</widget>
</item>
<item>
<widget class="QLineEdit" name="mapping_port"/>
</item>
<item>
<widget class="QLabel" name="label_2">
<property name="toolTip">
<string>Random if it's empty or zero.</string>
</property>
<property name="text">
<string notr="true">Socks Port</string>
</property>
</widget>
</item>
<item>
<widget class="QLineEdit" name="socks_port"/>
</item>
<item>
<widget class="QPushButton" name="preview">
<property name="text">
<string>Preview</string>
</property>
</widget>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QTextEdit" name="config_simple">

View File

@@ -1340,7 +1340,9 @@ void MainWindow::show_log_impl(const QString &log) {
}
}
#define ADD_TO_CURRENT_ROUTE(a, b) NekoRay::dataStore->routing->a = (SplitLines(NekoRay::dataStore->routing->a) << (b)).join("\n");
#define ADD_TO_CURRENT_ROUTE(a, b) \
NekoRay::dataStore->routing->a = (SplitLines(NekoRay::dataStore->routing->a) << (b)).join("\n"); \
NekoRay::dataStore->routing->Save();
void MainWindow::on_masterLogBrowser_customContextMenuRequested(const QPoint &pos) {
QMenu *menu = ui->masterLogBrowser->createStandardContextMenu();