summaryrefslogtreecommitdiffstats
path: root/libkdepim/pluginloaderbase.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'libkdepim/pluginloaderbase.cpp')
-rw-r--r--libkdepim/pluginloaderbase.cpp36
1 files changed, 18 insertions, 18 deletions
diff --git a/libkdepim/pluginloaderbase.cpp b/libkdepim/pluginloaderbase.cpp
index 03c397799..40a4beb2f 100644
--- a/libkdepim/pluginloaderbase.cpp
+++ b/libkdepim/pluginloaderbase.cpp
@@ -28,8 +28,8 @@
#include <kglobal.h>
#include <kdebug.h>
-#include <qfile.h>
-#include <qstringlist.h>
+#include <tqfile.h>
+#include <tqstringlist.h>
static kdbgstream warning() {
return kdWarning( 5300 ) << "PluginLoaderBase: ";
@@ -49,15 +49,15 @@ namespace KPIM {
PluginLoaderBase::~PluginLoaderBase() {}
- QStringList PluginLoaderBase::types() const {
- QStringList result;
- for ( QMap< QString, PluginMetaData >::const_iterator it = mPluginMap.begin();
+ TQStringList PluginLoaderBase::types() const {
+ TQStringList result;
+ for ( TQMap< TQString, PluginMetaData >::const_iterator it = mPluginMap.begin();
it != mPluginMap.end() ; ++it )
result.push_back( it.key() );
return result;
}
- const PluginMetaData * PluginLoaderBase::infoForName( const QString & type ) const {
+ const PluginMetaData * PluginLoaderBase::infoForName( const TQString & type ) const {
return mPluginMap.contains( type ) ? &(mPluginMap[type]) : 0 ;
}
@@ -65,22 +65,22 @@ namespace KPIM {
void PluginLoaderBase::doScan( const char * path ) {
mPluginMap.clear();
- const QStringList list =
+ const TQStringList list =
KGlobal::dirs()->findAllResources( "data", path, true, true );
- for ( QStringList::const_iterator it = list.begin() ;
+ for ( TQStringList::const_iterator it = list.begin() ;
it != list.end() ; ++it ) {
KSimpleConfig config( *it, true );
if ( config.hasGroup( "Misc" ) && config.hasGroup( "Plugin" ) ) {
config.setGroup( "Plugin" );
- const QString type = config.readEntry( "Type" ).lower();
+ const TQString type = config.readEntry( "Type" ).lower();
if ( type.isEmpty() ) {
warning() << "missing or empty [Plugin]Type value in \""
<< *it << "\" - skipping" << endl;
continue;
}
- const QString library = config.readEntry( "X-KDE-Library" );
+ const TQString library = config.readEntry( "X-KDE-Library" );
if ( library.isEmpty() ) {
warning() << "missing or empty [Plugin]X-KDE-Library value in \""
<< *it << "\" - skipping" << endl;
@@ -89,14 +89,14 @@ namespace KPIM {
config.setGroup( "Misc" );
- QString name = config.readEntry( "Name" );
+ TQString name = config.readEntry( "Name" );
if ( name.isEmpty() ) {
warning() << "missing or empty [Misc]Name value in \""
<< *it << "\" - inserting default name" << endl;
name = i18n("Unnamed plugin");
}
- QString comment = config.readEntry( "Comment" );
+ TQString comment = config.readEntry( "Comment" );
if ( comment.isEmpty() ) {
warning() << "missing or empty [Misc]Comment value in \""
<< *it << "\" - inserting default name" << endl;
@@ -112,12 +112,12 @@ namespace KPIM {
}
}
- void * PluginLoaderBase::mainFunc( const QString & type,
+ void * PluginLoaderBase::mainFunc( const TQString & type,
const char * mf_name ) const {
if ( type.isEmpty() || !mPluginMap.contains( type ) )
return 0;
- const QString libName = mPluginMap[ type ].library;
+ const TQString libName = mPluginMap[ type ].library;
if ( libName.isEmpty() )
return 0;
@@ -127,7 +127,7 @@ namespace KPIM {
mPluginMap[ type ].loaded = true;
- const QString factory_name = libName + '_' + mf_name;
+ const TQString factory_name = libName + '_' + mf_name;
if ( !lib->hasSymbol( factory_name.latin1() ) ) {
warning() << "No symbol named \"" << factory_name.latin1() << "\" ("
<< factory_name << ") was found in library \"" << libName
@@ -138,9 +138,9 @@ namespace KPIM {
return lib->symbol( factory_name.latin1() );
}
- const KLibrary * PluginLoaderBase::openLibrary( const QString & libName ) const {
+ const KLibrary * PluginLoaderBase::openLibrary( const TQString & libName ) const {
- const QString path = KLibLoader::findLibrary( QFile::encodeName( libName ) );
+ const TQString path = KLibLoader::findLibrary( TQFile::encodeName( libName ) );
if ( path.isEmpty() ) {
warning() << "No plugin library named \"" << libName
@@ -148,7 +148,7 @@ namespace KPIM {
return 0;
}
- const KLibrary * library = KLibLoader::self()->library( QFile::encodeName( path ) );
+ const KLibrary * library = KLibLoader::self()->library( TQFile::encodeName( path ) );
debug( !library ) << "Could not load library '" << libName << "'" << endl;