author | tille <tille> | 2002-04-24 19:15:02 (UTC) |
---|---|---|
committer | tille <tille> | 2002-04-24 19:15:02 (UTC) |
commit | 17eb865ad8248b1f47c565b074b9b6bbbd44935b (patch) (unidiff) | |
tree | c494b5050ce910df3c74e2a21c5579571792d926 /noncore/unsupported/oipkg/packagelist.cpp | |
parent | 997b7685dcc48cc36737240ca53331f83b66dbeb (diff) | |
download | opie-17eb865ad8248b1f47c565b074b9b6bbbd44935b.zip opie-17eb865ad8248b1f47c565b074b9b6bbbd44935b.tar.gz opie-17eb865ad8248b1f47c565b074b9b6bbbd44935b.tar.bz2 |
added find
Diffstat (limited to 'noncore/unsupported/oipkg/packagelist.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/unsupported/oipkg/packagelist.cpp | 23 |
1 files changed, 15 insertions, 8 deletions
diff --git a/noncore/unsupported/oipkg/packagelist.cpp b/noncore/unsupported/oipkg/packagelist.cpp index 5f6934d..944bb83 100644 --- a/noncore/unsupported/oipkg/packagelist.cpp +++ b/noncore/unsupported/oipkg/packagelist.cpp | |||
@@ -26,6 +26,4 @@ PackageList::PackageList() | |||
26 | } | 26 | } |
27 | } | 27 | } |
28 | pvDebug( 5, "PackageList::PackageList statusDir "+statusDir); | ||
29 | pvDebug( 5, "PackageList::PackageList listsDir "+listsDir); | ||
30 | sections << "All"; | 28 | sections << "All"; |
31 | subSections.insert("All", new QStringList() ); | 29 | subSections.insert("All", new QStringList() ); |
@@ -64,5 +62,5 @@ void PackageList::insertPackage( Package* pack ) | |||
64 | } | 62 | } |
65 | 63 | ||
66 | void PackageList::filterPackages() | 64 | void PackageList::filterPackages( QString f ) |
67 | { | 65 | { |
68 | packageList.clear(); | 66 | packageList.clear(); |
@@ -72,9 +70,12 @@ void PackageList::filterPackages() | |||
72 | while ( pack ) | 70 | while ( pack ) |
73 | { | 71 | { |
74 | if ( ((aktSection=="All")||(pack->getSection()==aktSection)) && | 72 | if ( |
75 | ((aktSubSection=="All")||(pack->getSubSection()==aktSubSection)) ) | 73 | ((aktSection=="All")||(pack->getSection()==aktSection)) && |
76 | { | 74 | ((aktSubSection=="All")||(pack->getSubSection()==aktSubSection)) && |
77 | packageList.insert( pack->name(), pack ); | 75 | pack->name().contains( f ) |
78 | } | 76 | ) |
77 | { | ||
78 | packageList.insert( pack->name(), pack ); | ||
79 | } | ||
79 | ++filterIter; | 80 | ++filterIter; |
80 | pack = filterIter.current(); | 81 | pack = filterIter.current(); |
@@ -215,2 +216,8 @@ Package* PackageList::getByName( QString n ) | |||
215 | origPackageList[n]; | 216 | origPackageList[n]; |
216 | } | 217 | } |
218 | |||
219 | void PackageList::clear() | ||
220 | { | ||
221 | origPackageList.clear(); | ||
222 | packageList.clear(); | ||
223 | } | ||