author | Michael Krelin <hacker@klever.net> | 2007-07-04 11:23:42 (UTC) |
---|---|---|
committer | Michael Krelin <hacker@klever.net> | 2007-07-04 11:23:42 (UTC) |
commit | a08aff328d4393031d5ba7d622c2b05705a89d73 (patch) (unidiff) | |
tree | 8ee90d686081c52e7c69b5ce946e9b1a7d690001 /microkde/kresources/managerimpl.cpp | |
parent | 11edc920afe4f274c0964436633aa632c8288a40 (diff) | |
download | kdepimpi-a08aff328d4393031d5ba7d622c2b05705a89d73.zip kdepimpi-a08aff328d4393031d5ba7d622c2b05705a89d73.tar.gz kdepimpi-a08aff328d4393031d5ba7d622c2b05705a89d73.tar.bz2 |
initial public commit of qt4 portp1
Diffstat (limited to 'microkde/kresources/managerimpl.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | microkde/kresources/managerimpl.cpp | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/microkde/kresources/managerimpl.cpp b/microkde/kresources/managerimpl.cpp index a6d2007..4c0751c 100644 --- a/microkde/kresources/managerimpl.cpp +++ b/microkde/kresources/managerimpl.cpp | |||
@@ -22,32 +22,34 @@ | |||
22 | */ | 22 | */ |
23 | 23 | ||
24 | /* | 24 | /* |
25 | Enhanced Version of the file for platform independent KDE tools. | 25 | Enhanced Version of the file for platform independent KDE tools. |
26 | Copyright (c) 2004 Ulf Schenk | 26 | Copyright (c) 2004 Ulf Schenk |
27 | 27 | ||
28 | $Id$ | 28 | $Id$ |
29 | */ | 29 | */ |
30 | 30 | ||
31 | #include <kglobal.h> | 31 | #include <kglobal.h> |
32 | 32 | ||
33 | #include <kapplication.h> | 33 | #include <kapplication.h> |
34 | #include <kdebug.h> | 34 | #include <kdebug.h> |
35 | #include <kconfig.h> | 35 | #include <kconfig.h> |
36 | #include <kstandarddirs.h> | 36 | #include <kstandarddirs.h> |
37 | #include <qfile.h> | 37 | #include <qfile.h> |
38 | //Added by qt3to4: | ||
39 | #include <Q3PtrList> | ||
38 | 40 | ||
39 | #include "resource.h" | 41 | #include "resource.h" |
40 | #include "factory.h" | 42 | #include "factory.h" |
41 | #include "managerimpl.h" | 43 | #include "managerimpl.h" |
42 | 44 | ||
43 | 45 | ||
44 | 46 | ||
45 | using namespace KRES; | 47 | using namespace KRES; |
46 | 48 | ||
47 | ManagerImpl::ManagerImpl( const QString &family ) | 49 | ManagerImpl::ManagerImpl( const QString &family ) |
48 | : mFamily( family ), mConfig( 0 ), mStdConfig( 0 ), mStandard( 0 ), | 50 | : mFamily( family ), mConfig( 0 ), mStdConfig( 0 ), mStandard( 0 ), |
49 | mFactory( 0 ) | 51 | mFactory( 0 ) |
50 | 52 | ||
51 | { | 53 | { |
52 | kdDebug(5650) << "ManagerImpl::ManagerImpl()" << endl; | 54 | kdDebug(5650) << "ManagerImpl::ManagerImpl()" << endl; |
53 | 55 | ||
@@ -219,46 +221,46 @@ void ManagerImpl::resourceChanged( Resource *resource ) | |||
219 | QStringList ManagerImpl::resourceNames() | 221 | QStringList ManagerImpl::resourceNames() |
220 | { | 222 | { |
221 | QStringList result; | 223 | QStringList result; |
222 | 224 | ||
223 | Resource::List::ConstIterator it; | 225 | Resource::List::ConstIterator it; |
224 | for ( it = mResources.begin(); it != mResources.end(); ++it ) { | 226 | for ( it = mResources.begin(); it != mResources.end(); ++it ) { |
225 | result.append( (*it)->resourceName() ); | 227 | result.append( (*it)->resourceName() ); |
226 | } | 228 | } |
227 | return result; | 229 | return result; |
228 | } | 230 | } |
229 | 231 | ||
230 | Resource::List *ManagerImpl::resourceList() | 232 | Resource::List *ManagerImpl::resourceList() |
231 | { | 233 | { |
232 | return &mResources; | 234 | return &mResources; |
233 | } | 235 | } |
234 | 236 | ||
235 | QPtrList<Resource> ManagerImpl::resources() | 237 | Q3PtrList<Resource> ManagerImpl::resources() |
236 | { | 238 | { |
237 | QPtrList<Resource> result; | 239 | Q3PtrList<Resource> result; |
238 | 240 | ||
239 | Resource::List::ConstIterator it; | 241 | Resource::List::ConstIterator it; |
240 | for ( it = mResources.begin(); it != mResources.end(); ++it ) { | 242 | for ( it = mResources.begin(); it != mResources.end(); ++it ) { |
241 | result.append( *it ); | 243 | result.append( *it ); |
242 | } | 244 | } |
243 | return result; | 245 | return result; |
244 | } | 246 | } |
245 | 247 | ||
246 | QPtrList<Resource> ManagerImpl::resources( bool active ) | 248 | Q3PtrList<Resource> ManagerImpl::resources( bool active ) |
247 | { | 249 | { |
248 | QPtrList<Resource> result; | 250 | Q3PtrList<Resource> result; |
249 | 251 | ||
250 | Resource::List::ConstIterator it; | 252 | Resource::List::ConstIterator it; |
251 | for ( it = mResources.begin(); it != mResources.end(); ++it ) { | 253 | for ( it = mResources.begin(); it != mResources.end(); ++it ) { |
252 | if ( (*it)->isActive() == active ) { | 254 | if ( (*it)->isActive() == active ) { |
253 | result.append( *it ); | 255 | result.append( *it ); |
254 | } | 256 | } |
255 | } | 257 | } |
256 | return result; | 258 | return result; |
257 | } | 259 | } |
258 | 260 | ||
259 | void ManagerImpl::setListener( ManagerImplListener *listener ) | 261 | void ManagerImpl::setListener( ManagerImplListener *listener ) |
260 | { | 262 | { |
261 | mListener = listener; | 263 | mListener = listener; |
262 | } | 264 | } |
263 | 265 | ||
264 | Resource* ManagerImpl::readResourceConfig( const QString& identifier, | 266 | Resource* ManagerImpl::readResourceConfig( const QString& identifier, |