summaryrefslogtreecommitdiff
path: root/noncore
authorandyq <andyq>2002-10-16 23:43:27 (UTC)
committer andyq <andyq>2002-10-16 23:43:27 (UTC)
commit5d28c61d84da1814d356540b557bbfe026da98aa (patch) (side-by-side diff)
tree2bf8beae274d59573898cead3fc925d2663348b8 /noncore
parent35a5fb97aa3cc92e626286285d22d8fbf9d61e3e (diff)
downloadopie-5d28c61d84da1814d356540b557bbfe026da98aa.zip
opie-5d28c61d84da1814d356540b557bbfe026da98aa.tar.gz
opie-5d28c61d84da1814d356540b557bbfe026da98aa.tar.bz2
Fixed bug in jump to package
Diffstat (limited to 'noncore') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/settings/aqpkg/networkpkgmgr.cpp22
1 files changed, 19 insertions, 3 deletions
diff --git a/noncore/settings/aqpkg/networkpkgmgr.cpp b/noncore/settings/aqpkg/networkpkgmgr.cpp
index 3ce7960..6f528a1 100644
--- a/noncore/settings/aqpkg/networkpkgmgr.cpp
+++ b/noncore/settings/aqpkg/networkpkgmgr.cpp
@@ -494,3 +494,18 @@ void NetworkPackageManager :: letterPushed( QString t )
{
- QCheckListItem *item = (QCheckListItem *)packagesList->firstChild();
+ QCheckListItem *top = (QCheckListItem *)packagesList->firstChild();
+ QCheckListItem *start = (QCheckListItem *)packagesList->currentItem();
+ if ( packagesList->firstChild() == 0 )
+ return;
+
+ QCheckListItem *item;
+ if ( start == 0 )
+ {
+ item = (QCheckListItem *)packagesList->firstChild();
+ start = top;
+ }
+ else
+ item = (QCheckListItem *)start->nextSibling();
+
+ if ( item == 0 )
+ item = (QCheckListItem *)packagesList->firstChild();
do
@@ -499,3 +514,2 @@ void NetworkPackageManager :: letterPushed( QString t )
{
- cout << "Found - item->text()" << endl;
packagesList->setSelected( item, true );
@@ -506,3 +520,5 @@ void NetworkPackageManager :: letterPushed( QString t )
item = (QCheckListItem *)item->nextSibling();
- } while ( item );
+ if ( !item )
+ item = (QCheckListItem *)packagesList->firstChild();
+ } while ( item != start);
}