UI: Minor fixes.

This commit is contained in:
Nodir Temirkhodjaev 2020-02-12 15:49:28 +05:00
parent de6f668be6
commit 6f12f97634
4 changed files with 18 additions and 16 deletions

View File

@ -1,11 +1,4 @@
[
{
"code": "tasix",
"title": "TAS-IX Addresses",
"zoneType": "bgp",
"url": "http://mrlg.tas-ix.uz/index.cgi",
"formData": "router=cisco&pass1=&query=1&arg="
},
{
"code": "file",
"title": "Addresses from Local File",
@ -19,5 +12,12 @@
"zoneType": "gen",
"url": "https://iplists.firehol.org/files/firehol_level1.netset",
"formData": ""
},
{
"code": "tasix",
"title": "TAS-IX Addresses",
"zoneType": "bgp",
"url": "http://mrlg.tas-ix.uz/index.cgi",
"formData": "router=cisco&pass1=&query=1&arg="
}
]

View File

@ -1,12 +1,4 @@
[
{
"code": "bgp",
"title": "BGP",
"description": "BGP table",
"sort": true,
"pattern": "^\\*\\D{2,5}(\\S+)",
"emptyNetMask": 24
},
{
"code": "gen",
"title": "Generic",
@ -14,5 +6,13 @@
"sort": true,
"pattern": "^\\D*(\\S+)",
"emptyNetMask": 32
},
{
"code": "bgp",
"title": "BGP",
"description": "BGP table",
"sort": true,
"pattern": "^\\*\\D{2,5}(\\S+)",
"emptyNetMask": 24
}
]

View File

@ -526,6 +526,8 @@ void ProgramsWindow::setupTableAppsChanged()
const auto refreshTableAppsChanged = [&] {
const int appIndex = appListCurrentIndex();
const bool appSelected = (appIndex >= 0);
m_actAllowApp->setEnabled(appSelected);
m_actBlockApp->setEnabled(appSelected);
m_actEditApp->setEnabled(appSelected);
m_actRemoveApp->setEnabled(appSelected);
m_btAllowApp->setEnabled(appSelected);

View File

@ -64,7 +64,7 @@ QVariant ZoneListModel::data(const QModelIndex &index, int role) const
const auto zoneRow = zoneRowAt(row);
switch (column) {
case 0: return QString("(%1) %2")
case 0: return QString("%1) %2")
.arg(QString::number(m_zoneRow.zoneId),
zoneRow.zoneName);
case 1: {