author | andyq <andyq> | 2002-10-16 23:08:56 (UTC) |
---|---|---|
committer | andyq <andyq> | 2002-10-16 23:08:56 (UTC) |
commit | b1d16660979fa8bb767fa0a6fe2d966e5633abdc (patch) (unidiff) | |
tree | 42390cc528f61bd44c0de7084d0fed8000bc10c4 | |
parent | 593fe744126a398e2714070137b6f19e398d2c9d (diff) | |
download | opie-b1d16660979fa8bb767fa0a6fe2d966e5633abdc.zip opie-b1d16660979fa8bb767fa0a6fe2d966e5633abdc.tar.gz opie-b1d16660979fa8bb767fa0a6fe2d966e5633abdc.tar.bz2 |
Handles commented servers nicely
-rw-r--r-- | noncore/settings/aqpkg/networkpkgmgr.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/noncore/settings/aqpkg/networkpkgmgr.cpp b/noncore/settings/aqpkg/networkpkgmgr.cpp index 318b26d..3ce7960 100644 --- a/noncore/settings/aqpkg/networkpkgmgr.cpp +++ b/noncore/settings/aqpkg/networkpkgmgr.cpp | |||
@@ -83,11 +83,17 @@ void NetworkPackageManager :: updateData() | |||
83 | serversList->clear(); | 83 | serversList->clear(); |
84 | packagesList->clear(); | 84 | packagesList->clear(); |
85 | 85 | ||
86 | |||
86 | vector<Server>::iterator it; | 87 | vector<Server>::iterator it; |
87 | int activeItem = -1; | 88 | int activeItem = -1; |
88 | int i; | 89 | int i; |
89 | for ( i = 0, it = dataMgr->getServerList().begin() ; it != dataMgr->getServerList().end() ; ++it, ++i ) | 90 | for ( i = 0, it = dataMgr->getServerList().begin() ; it != dataMgr->getServerList().end() ; ++it, ++i ) |
90 | { | 91 | { |
92 | if ( !it->isServerActive() ) | ||
93 | { | ||
94 | i--; | ||
95 | continue; | ||
96 | } | ||
91 | serversList->insertItem( it->getServerName() ); | 97 | serversList->insertItem( it->getServerName() ); |
92 | if ( it->getServerName() == currentlySelectedServer ) | 98 | if ( it->getServerName() == currentlySelectedServer ) |
93 | activeItem = i; | 99 | activeItem = i; |