summaryrefslogtreecommitdiff
path: root/noncore/settings/networksettings2/ppp/PPPDNSedit.cpp
Side-by-side diff
Diffstat (limited to 'noncore/settings/networksettings2/ppp/PPPDNSedit.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/settings/networksettings2/ppp/PPPDNSedit.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/noncore/settings/networksettings2/ppp/PPPDNSedit.cpp b/noncore/settings/networksettings2/ppp/PPPDNSedit.cpp
index 22f8e59..270f695 100644
--- a/noncore/settings/networksettings2/ppp/PPPDNSedit.cpp
+++ b/noncore/settings/networksettings2/ppp/PPPDNSedit.cpp
@@ -14,25 +14,25 @@ PPPDNSEdit::PPPDNSEdit( QWidget * Parent ) : PPPDNSGUI( Parent ){
}
QString PPPDNSEdit::acceptable( void ) {
if( DNSFixed_RB->isChecked() ) {
if( DomainName_LE->text().isEmpty() )
tr("Domainname needed");
if( Servers_LB->count() == 0 )
tr("DNS Servers needed");
}
return QString();
}
-bool PPPDNSEdit::commit( PPPData_t & D ) {
+bool PPPDNSEdit::commit( PPPData & D ) {
bool SM = 0;
CBM( D.DNS.ServerAssigned, DNSServerAssigned_RB, SM );
TXTM( D.DNS.DomainName, DomainName_LE, SM );
// new items in old ?
for ( unsigned i = 0; i < Servers_LB->count(); i++ ) {
QString S;
bool Found;
Found = 0;
S = Servers_LB->text(i);
for ( unsigned j = 0; j < D.DNS.Servers.size(); j++ ) {
@@ -66,25 +66,25 @@ bool PPPDNSEdit::commit( PPPData_t & D ) {
delete D.DNS.Servers[j];
for( unsigned i = j+1; i < D.DNS.Servers.size(); i ++ ) {
// compress array
D.DNS.Servers[i-1] = D.DNS.Servers[i];
}
// shrink
D.DNS.Servers.resize( D.DNS.Servers.size()-1 );
}
}
return SM;
}
-void PPPDNSEdit::showData( PPPData_t & D) {
+void PPPDNSEdit::showData( PPPData & D) {
DNSServerAssigned_RB->setChecked( D.DNS.ServerAssigned );
DomainName_LE->setText( D.DNS.DomainName );
for( unsigned i = 0; i < D.DNS.Servers.size(); i ++ ) {
Servers_LB->insertItem( *(D.DNS.Servers[i]) );
}
}
void PPPDNSEdit::SLOT_AddServer( void ) {
if( ServerAddress_LE->text().isEmpty() )
return;