From f15f00e260ab07873df94563f34d7eca4327a1c3 Mon Sep 17 00:00:00 2001 From: Cacodemon345 Date: Tue, 1 Feb 2022 01:46:31 +0600 Subject: [PATCH] qt_settingsnetwork: Disable Configure button when network card has no configurable parameters --- src/qt/qt_settingsnetwork.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/qt/qt_settingsnetwork.cpp b/src/qt/qt_settingsnetwork.cpp index 64b60b55e..a8a6dd2fc 100644 --- a/src/qt/qt_settingsnetwork.cpp +++ b/src/qt/qt_settingsnetwork.cpp @@ -18,7 +18,7 @@ static void enableElements(Ui::SettingsNetwork *ui) { bool adaptersEnabled = netType == NET_TYPE_SLIRP || (netType == NET_TYPE_PCAP && ui->comboBoxPcap->currentData().toInt() > 0); ui->comboBoxAdapter->setEnabled(adaptersEnabled); - ui->pushButtonConfigure->setEnabled(adaptersEnabled && ui->comboBoxAdapter->currentIndex() > 0); + ui->pushButtonConfigure->setEnabled(adaptersEnabled && ui->comboBoxAdapter->currentIndex() > 0 && network_card_has_config(ui->comboBoxAdapter->currentData().toInt())); } SettingsNetwork::SettingsNetwork(QWidget *parent) :