summaryrefslogtreecommitdiff
path: root/noncore/settings/networksettings2/profile/profileedit.cpp
Unidiff
Diffstat (limited to 'noncore/settings/networksettings2/profile/profileedit.cpp') (more/less context) (show whitespace changes)
-rw-r--r--noncore/settings/networksettings2/profile/profileedit.cpp33
1 files changed, 28 insertions, 5 deletions
diff --git a/noncore/settings/networksettings2/profile/profileedit.cpp b/noncore/settings/networksettings2/profile/profileedit.cpp
index ad943fe..1713f0c 100644
--- a/noncore/settings/networksettings2/profile/profileedit.cpp
+++ b/noncore/settings/networksettings2/profile/profileedit.cpp
@@ -1,2 +1,4 @@
1#include <qlabel.h> 1#include <qlabel.h>
2#include <qgroupbox.h>
3#include <qpushbutton.h>
2#include <qframe.h> 4#include <qframe.h>
@@ -25,5 +27,6 @@ ProfileEdit::ProfileEdit( QWidget * Parent, ANetNodeInstance * TNNI ) :
25 Refresh_CB->setEnabled( TRUE ); 27 Refresh_CB->setEnabled( TRUE );
26 Snd_GB->setEnabled( TRUE ); 28 ResetODO_But->setEnabled( TRUE );
27 Rcv_GB->setEnabled( TRUE ); 29 Sending_GB->setEnabled( TRUE );
28 Collisions_FRM->setEnabled( TRUE ); 30 Receiving_GB->setEnabled( TRUE );
31 Misc_GB->setEnabled( TRUE );
29 32
@@ -32,2 +35,5 @@ ProfileEdit::ProfileEdit( QWidget * Parent, ANetNodeInstance * TNNI ) :
32 35
36 // initialize ODO
37 SLOT_ResetODO();
38
33 // fill in static data 39 // fill in static data
@@ -84,9 +90,19 @@ void ProfileEdit::SLOT_Refresh( void ) {
84 InterfaceInfo * II = NNI->networkSetup()->assignedInterface(); 90 InterfaceInfo * II = NNI->networkSetup()->assignedInterface();
91 QString S;
85 NSResources->system().refreshStatistics( *II ); 92 NSResources->system().refreshStatistics( *II );
93
86 RcvBytes_LBL->setText( II->RcvBytes ); 94 RcvBytes_LBL->setText( II->RcvBytes );
87 SndBytes_LBL->setText( II->SndBytes ); 95 RcvPackets_LBL->setText( II->RcvPackets );
88 RcvErrors_LBL->setText( II->RcvErrors ); 96 RcvErrors_LBL->setText( II->RcvErrors );
89 SndErrors_LBL->setText( II->SndErrors );
90 RcvDropped_LBL->setText( II->RcvDropped ); 97 RcvDropped_LBL->setText( II->RcvDropped );
98 S.setNum( II->RcvBytes.toLong() - RcvODO );
99 RcvODO_LBL->setText( S );
100
101 SndBytes_LBL->setText( II->SndBytes );
102 SndPackets_LBL->setText( II->SndPackets );
103 SndErrors_LBL->setText( II->SndErrors );
91 SndDropped_LBL->setText( II->SndDropped ); 104 SndDropped_LBL->setText( II->SndDropped );
105 S.setNum( II->SndBytes.toLong() - SndODO );
106 SndODO_LBL->setText( S );
107
92 Collisions_LBL->setText( II->Collisions ); 108 Collisions_LBL->setText( II->Collisions );
@@ -102 +118,8 @@ void ProfileEdit::SLOT_AutoRefresh( bool ar ) {
102} 118}
119
120void ProfileEdit::SLOT_ResetODO( void ) {
121 InterfaceInfo * II = NNI->networkSetup()->assignedInterface();
122 RcvODO = II->RcvBytes.toLong();
123 SndODO = II->SndBytes.toLong();
124 SLOT_Refresh();
125}