Show human readable interface names (mostly affects Windows)

This commit is contained in:
Nick Tiskov
2013-01-13 17:44:14 +04:00
parent 186bbd7fc3
commit 3e98bd49e2
2 changed files with 26 additions and 0 deletions

View File

@@ -1042,6 +1042,16 @@ public:
QString getNetworkInterface() const {
return value(QString::fromUtf8("Preferences/Connection/Interface"), QString()).toString();
}
#if QT_VERSION >= QT_VERSION_CHECK(4,5,0)
void setNetworkInterfaceName(const QString& iface) {
setValue(QString::fromUtf8("Preferences/Connection/InterfaceName"), iface);
}
QString getNetworkInterfaceName() const {
return value(QString::fromUtf8("Preferences/Connection/InterfaceName"), QString()).toString();
}
#endif
void setNetworkAddress(const QString& addr) {
setValue(QString::fromUtf8("Preferences/Connection/InetAddress"), addr);