From 6b1b516f42036cf9eff691dba3fd6e9eab82a7e1 Mon Sep 17 00:00:00 2001 From: tpearson Date: Fri, 1 Jul 2011 23:15:51 +0000 Subject: TQt4 port soundkonverter This enables compilation under both Qt3 and Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/soundkonverter@1239038 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- src/pluginloader/convertpluginloader.cpp | 30 ++++---- src/pluginloader/convertpluginloader.h | 113 ++++++++++++++-------------- src/pluginloader/formatinfoloader.cpp | 32 ++++---- src/pluginloader/formatinfoloader.h | 23 +++--- src/pluginloader/pluginloaderbase.cpp | 4 +- src/pluginloader/pluginloaderbase.h | 19 ++--- src/pluginloader/replaygainpluginloader.cpp | 22 +++--- src/pluginloader/replaygainpluginloader.h | 43 +++++------ src/pluginloader/ripperpluginloader.cpp | 20 ++--- src/pluginloader/ripperpluginloader.h | 33 ++++---- 10 files changed, 172 insertions(+), 167 deletions(-) (limited to 'src/pluginloader') diff --git a/src/pluginloader/convertpluginloader.cpp b/src/pluginloader/convertpluginloader.cpp index 89996ba..0631c19 100755 --- a/src/pluginloader/convertpluginloader.cpp +++ b/src/pluginloader/convertpluginloader.cpp @@ -1,7 +1,7 @@ #include "convertpluginloader.h" -#include +#include #include #include @@ -21,9 +21,9 @@ ConvertPluginLoader::ConvertPluginLoader() ConvertPluginLoader::~ConvertPluginLoader() {} -int ConvertPluginLoader::verifyFile( QString fileName ) +int ConvertPluginLoader::verifyFile( TQString fileName ) { - QFile opmlFile( fileName ); + TQFile opmlFile( fileName ); if( !opmlFile.open( IO_ReadOnly ) ) { return -1; } @@ -32,10 +32,10 @@ int ConvertPluginLoader::verifyFile( QString fileName ) } opmlFile.close(); - QDomElement root = domTree.documentElement(); + TQDomElement root = domTree.documentElement(); if( root.attribute("type") != "converter" ) return -1; int version; - QDomNode node; + TQDomNode node; node = root.firstChild(); while( !node.isNull() ) { if( node.isElement() && node.nodeName() == "info" ) { @@ -47,17 +47,17 @@ int ConvertPluginLoader::verifyFile( QString fileName ) return version; } -ConvertPlugin* ConvertPluginLoader::loadFile( QString fileName ) +ConvertPlugin* ConvertPluginLoader::loadFile( TQString fileName ) { int t_int; float t_float; - QString t_str; + TQString t_str; ConvertPlugin* plugin = new ConvertPlugin(); plugin->info.version = -1; // if something goes wrong, we can see that by looking at plugin->info.version plugin->filePathName = fileName; - QFile opmlFile( fileName ); + TQFile opmlFile( fileName ); if( !opmlFile.open( IO_ReadOnly ) ) { return plugin; } @@ -66,11 +66,11 @@ ConvertPlugin* ConvertPluginLoader::loadFile( QString fileName ) } opmlFile.close(); - QString language = KGlobal::locale()->languagesTwoAlpha().first(); + TQString language = KGlobal::locale()->languagesTwoAlpha().first(); - QDomElement root = domTree.documentElement(); + TQDomElement root = domTree.documentElement(); if( root.attribute("type") != "converter" ) return plugin; - QDomNode node, sub1Node, sub2Node, sub3Node, sub4Node; + TQDomNode node, sub1Node, sub2Node, sub3Node, sub4Node; node = root.firstChild(); plugin->enc.enabled = false; @@ -110,7 +110,7 @@ ConvertPlugin* ConvertPluginLoader::loadFile( QString fileName ) plugin->enc.bin = node.toElement().attribute( "bin" ); plugin->enc.param = node.toElement().attribute("param"); plugin->enc.silent_param = node.toElement().attribute("silent_param"); - plugin->enc.mime_types = QStringList::split( ',', node.toElement().attribute("mime_types","application/octet-stream") ); + plugin->enc.mime_types = TQStringList::split( ',', node.toElement().attribute("mime_types","application/octet-stream") ); plugin->enc.in_out_files = node.toElement().attribute("in_out_files"); plugin->enc.overwrite = node.toElement().attribute("overwrite"); @@ -124,7 +124,7 @@ ConvertPlugin* ConvertPluginLoader::loadFile( QString fileName ) plugin->enc.strength.separator = sub1Node.toElement().attribute("separator").at(0); plugin->enc.strength.param = sub1Node.toElement().attribute("param"); plugin->enc.strength.step = sub1Node.toElement().attribute("step").toFloat(); - plugin->enc.strength.profiles = QStringList::split( ',', sub1Node.toElement().attribute("profiles") ); + plugin->enc.strength.profiles = TQStringList::split( ',', sub1Node.toElement().attribute("profiles") ); plugin->enc.strength.default_value = sub1Node.toElement().attribute("default_value").toFloat(); } @@ -144,7 +144,7 @@ ConvertPlugin* ConvertPluginLoader::loadFile( QString fileName ) plugin->enc.lossy.quality.output = sub2Node.toElement().attribute("output"); plugin->enc.lossy.quality.param = sub2Node.toElement().attribute("param"); plugin->enc.lossy.quality.step = sub2Node.toElement().attribute("step").toFloat(); - plugin->enc.lossy.quality.profiles = QStringList::split( ',', sub2Node.toElement().attribute("profiles") ); + plugin->enc.lossy.quality.profiles = TQStringList::split( ',', sub2Node.toElement().attribute("profiles") ); } else if( sub2Node.isElement() && sub2Node.nodeName() == "bitrate" ) { @@ -252,7 +252,7 @@ ConvertPlugin* ConvertPluginLoader::loadFile( QString fileName ) plugin->dec.output = node.toElement().attribute("output"); plugin->dec.param = node.toElement().attribute("param"); plugin->dec.overwrite = node.toElement().attribute("overwrite"); - plugin->dec.mime_types = QStringList::split( ',', node.toElement().attribute("mime_types","application/octet-stream") ); + plugin->dec.mime_types = TQStringList::split( ',', node.toElement().attribute("mime_types","application/octet-stream") ); plugin->dec.in_out_files = node.toElement().attribute("in_out_files"); plugin->dec.silent_param = node.toElement().attribute("silent_param"); diff --git a/src/pluginloader/convertpluginloader.h b/src/pluginloader/convertpluginloader.h index ad09e12..52c2374 100755 --- a/src/pluginloader/convertpluginloader.h +++ b/src/pluginloader/convertpluginloader.h @@ -24,35 +24,35 @@ public: */ virtual ~ConvertPlugin(); - QString filePathName; // the file name of th plugin (needed to detect write permissions) + TQString filePathName; // the file name of th plugin (needed to detect write permissions) struct Info { int version; // the version of our plugin (v0.2.1 = 201, v11.3 = 110300) - QString name; // the name of our plugin - QString author; // the author of the plugin - QString about; // a short information aboue the plugin + TQString name; // the name of our plugin + TQString author; // the author of the plugin + TQString about; // a short information aboue the plugin } info; struct Enc { bool enabled; int rank; - QString bin; - QString param; - QString silent_param; - QStringList mime_types; - QString in_out_files; - QString overwrite; + TQString bin; + TQString param; + TQString silent_param; + TQStringList mime_types; + TQString in_out_files; + TQString overwrite; struct Strength { bool enabled; - QString param; + TQString param; float range_min; float range_max; float step; - QChar separator; - QStringList profiles; + TQChar separator; + TQStringList profiles; float default_value; } strength; @@ -61,104 +61,104 @@ public: struct Quality { bool enabled; - QString param; + TQString param; float range_min; float range_max; float step; - QChar separator; - QString help; - QString output; - QStringList profiles; // NOTE when using profiles, step must be 1 and range_min 0 + TQChar separator; + TQString help; + TQString output; + TQStringList profiles; // NOTE when using profiles, step must be 1 and range_min 0 } quality; struct Bitrate { struct Abr { bool enabled; - QString param; - QString output; + TQString param; + TQString output; struct BitrateRange { bool enabled; - QString param_min; - QString param_max; + TQString param_min; + TQString param_max; } bitrate_range; } abr; struct Cbr { bool enabled; - QString param; - QString output; + TQString param; + TQString output; } cbr; } bitrate; struct Samplingrate { bool enabled; - QString param; + TQString param; PluginLoaderBase::Unit unit; } samplingrate; struct Channels { bool stereo_enabled; - QString stereo_param; + TQString stereo_param; bool joint_stereo_enabled; - QString joint_stereo_param; + TQString joint_stereo_param; bool forced_joint_stereo_enabled; - QString forced_joint_stereo_param; + TQString forced_joint_stereo_param; bool dual_channels_enabled; - QString dual_channels_param; + TQString dual_channels_param; bool mono_enabled; - QString mono_param; + TQString mono_param; } channels; } lossy; struct Lossless { bool enabled; - QString param; - QString output; + TQString param; + TQString output; } lossless; struct Hybrid { bool enabled; - QString param; - QString output; - QString correction_file_mime_type; + TQString param; + TQString output; + TQString correction_file_mime_type; } hybrid; struct ReplayGain { bool enabled; - QString use; - QString avoid; + TQString use; + TQString avoid; int rank; } replaygain; struct Tag { bool enabled; - QString param; - QString artist; - QString composer; - QString album; - QString disc; - QString title; - QString genre; - QString comment; - QString track; - QString year; + TQString param; + TQString artist; + TQString composer; + TQString album; + TQString disc; + TQString title; + TQString genre; + TQString comment; + TQString track; + TQString year; } tag; } enc; struct Dec { bool enabled; int rank; - QString bin; - QString param; - QString silent_param; - QStringList mime_types; - QString output; - QString in_out_files; - QString overwrite; + TQString bin; + TQString param; + TQString silent_param; + TQStringList mime_types; + TQString output; + TQString in_out_files; + TQString overwrite; } dec; }; @@ -170,6 +170,7 @@ public: class ConvertPluginLoader : public PluginLoaderBase { Q_OBJECT + TQ_OBJECT public: /** * Constructor @@ -182,9 +183,9 @@ public: virtual ~ConvertPluginLoader(); /** is this file a converter plugin and loadable? */ - int verifyFile( QString ); + int verifyFile( TQString ); /** load a given file */ - ConvertPlugin* loadFile( QString ); + ConvertPlugin* loadFile( TQString ); }; #endif // CONVERTPLUGINLOADER_H diff --git a/src/pluginloader/formatinfoloader.cpp b/src/pluginloader/formatinfoloader.cpp index c585ed6..8a559bb 100755 --- a/src/pluginloader/formatinfoloader.cpp +++ b/src/pluginloader/formatinfoloader.cpp @@ -1,7 +1,7 @@ #include "formatinfoloader.h" -#include +#include #include #include @@ -19,9 +19,9 @@ FormatInfoLoader::FormatInfoLoader() FormatInfoLoader::~FormatInfoLoader() {} -bool FormatInfoLoader::verifyFile( QString fileName ) +bool FormatInfoLoader::verifyFile( TQString fileName ) { - QFile opmlFile( fileName ); + TQFile opmlFile( fileName ); if( !opmlFile.open( IO_ReadOnly ) ) { return false; } @@ -30,22 +30,22 @@ bool FormatInfoLoader::verifyFile( QString fileName ) } opmlFile.close(); - QDomElement root = domTree.documentElement(); + TQDomElement root = domTree.documentElement(); if( root.attribute("type") == "format_info" ) return true; return false; } -FormatInfo* FormatInfoLoader::loadFile( QString fileName ) +FormatInfo* FormatInfoLoader::loadFile( TQString fileName ) { int t_int; float t_float; - QString t_str; + TQString t_str; FormatInfo* plugin = new FormatInfo(); plugin->mime_types = "application/octet-stream"; // if something goes wrong, we can see that by looking at plugin->mimetype - QFile opmlFile( fileName ); + TQFile opmlFile( fileName ); if( !opmlFile.open( IO_ReadOnly ) ) { return plugin; } @@ -54,25 +54,25 @@ FormatInfo* FormatInfoLoader::loadFile( QString fileName ) } opmlFile.close(); - QString language = KGlobal::locale()->languagesTwoAlpha().first(); + TQString language = KGlobal::locale()->languagesTwoAlpha().first(); - QDomElement root = domTree.documentElement(); + TQDomElement root = domTree.documentElement(); if( root.attribute("type") != "format_info" ) return plugin; - QDomNode node; + TQDomNode node; node = root.firstChild(); while( !node.isNull() ) { if( node.isElement() && node.nodeName() == "data" ) { - plugin->mime_types = QStringList::split( ',',node.toElement().attribute("mime_types","application/octet-stream") ); - plugin->extensions = QStringList::split( ',',node.toElement().attribute("extensions") ); + plugin->mime_types = TQStringList::split( ',',node.toElement().attribute("mime_types","application/octet-stream") ); + plugin->extensions = TQStringList::split( ',',node.toElement().attribute("extensions") ); plugin->description = node.toElement().attribute("description_"+language); if( plugin->description.isEmpty() ) plugin->description = node.toElement().attribute("description"); - plugin->urls = QStringList::split( ',',node.toElement().attribute("urls_"+language) ); - if( plugin->urls.isEmpty() ) plugin->urls = QStringList::split( ',',node.toElement().attribute("urls") ); - QStringList compressionTypeList = QStringList::split( ',',node.toElement().attribute("compression_type") ); + plugin->urls = TQStringList::split( ',',node.toElement().attribute("urls_"+language) ); + if( plugin->urls.isEmpty() ) plugin->urls = TQStringList::split( ',',node.toElement().attribute("urls") ); + TQStringList compressionTypeList = TQStringList::split( ',',node.toElement().attribute("compression_type") ); plugin->compressionType = (FormatInfo::CompressionType)0x0000; - for( QStringList::Iterator it = compressionTypeList.begin(); it != compressionTypeList.end(); ++it ) { + for( TQStringList::Iterator it = compressionTypeList.begin(); it != compressionTypeList.end(); ++it ) { if( *it == "lossy" ) plugin->compressionType = FormatInfo::CompressionType( plugin->compressionType | FormatInfo::lossy ); else if( *it == "lossless" ) plugin->compressionType = FormatInfo::CompressionType( plugin->compressionType | FormatInfo::lossless ); else if( *it == "hybrid" ) plugin->compressionType = FormatInfo::CompressionType( plugin->compressionType | FormatInfo::hybrid ); diff --git a/src/pluginloader/formatinfoloader.h b/src/pluginloader/formatinfoloader.h index f36f7fe..583cb9c 100755 --- a/src/pluginloader/formatinfoloader.h +++ b/src/pluginloader/formatinfoloader.h @@ -3,9 +3,9 @@ #ifndef FORMATINFOLOADER_H #define FORMATINFOLOADER_H -#include -#include -#include +#include +#include +#include /** * @short The complete information about that format @@ -25,10 +25,10 @@ public: */ virtual ~FormatInfo(); - QStringList mime_types; - QStringList extensions; - QString description; - QStringList urls; + TQStringList mime_types; + TQStringList extensions; + TQString description; + TQStringList urls; enum CompressionType { lossy = 0x0001, // encode with loss lossless = 0x0002, // encode without loss @@ -42,9 +42,10 @@ public: * @author Daniel Faust * @version 0.3 */ -class FormatInfoLoader : public QObject +class FormatInfoLoader : public TQObject { Q_OBJECT + TQ_OBJECT public: /** * Constructor @@ -57,11 +58,11 @@ public: virtual ~FormatInfoLoader(); /** is this file a converter plugin and loadable? */ - bool verifyFile( QString ); + bool verifyFile( TQString ); /** load a given file */ - FormatInfo* loadFile( QString ); + FormatInfo* loadFile( TQString ); /** the dom tree for loading the xml file */ - QDomDocument domTree; + TQDomDocument domTree; }; #endif // FORMATINFOLOADER_H diff --git a/src/pluginloader/pluginloaderbase.cpp b/src/pluginloader/pluginloaderbase.cpp index d9a8413..f55a8e4 100755 --- a/src/pluginloader/pluginloaderbase.cpp +++ b/src/pluginloader/pluginloaderbase.cpp @@ -10,8 +10,8 @@ PluginLoaderBase::~PluginLoaderBase() void PluginLoaderBase::unloadAll() {} -void PluginLoaderBase::unload( QString pluginName ) +void PluginLoaderBase::unload( TQString pluginName ) {} -void PluginLoaderBase::remove( QString pluginName ) +void PluginLoaderBase::remove( TQString pluginName ) {} diff --git a/src/pluginloader/pluginloaderbase.h b/src/pluginloader/pluginloaderbase.h index c35bebe..4b85563 100755 --- a/src/pluginloader/pluginloaderbase.h +++ b/src/pluginloader/pluginloaderbase.h @@ -3,9 +3,9 @@ #ifndef PLUGINLOADERBASE_H #define PLUGINLOADERBASE_H -#include -#include -#include +#include +#include +#include #include "config.h" @@ -16,9 +16,10 @@ * @author Daniel Faust * @version 0.3 */ -class PluginLoaderBase : public QObject +class PluginLoaderBase : public TQObject { Q_OBJECT + TQ_OBJECT public: /** * Do we recommend this backend to the user @@ -50,10 +51,10 @@ public: virtual ~PluginLoaderBase(); /** a list of all plugin files that are loaded at the moment */ -// QStringList openPluginFiles; +// TQStringList openPluginFiles; /** the dom tree for loading the xml file */ - QDomDocument domTree; + TQDomDocument domTree; public slots: /** @@ -64,12 +65,12 @@ public slots: /** * Unoad a specific plugin with name @p pluginName */ - void unload( QString pluginName ); + void unload( TQString pluginName ); /** * Unoad a specific plugin with name @p pluginName and delete the plugin file */ - void remove( QString pluginName ); + void remove( TQString pluginName ); }; #endif // PLUGINLOADERBASE_H @@ -77,7 +78,7 @@ public slots: /** -Each plugin package contains 3 files: +Each plugin package tqcontains 3 files: - The plugin file ( $KDE_DIR/share/apps/soundkonverter/plugins/'filename' ) - The format info file ( $KDE_DIR/share/apps/soundkonverter/format_infos/'lang'/'plugin'_'filename' ) - The service menu ( $KDE_DIR/share/apps/konqueror/servicemenus/'filename' ) diff --git a/src/pluginloader/replaygainpluginloader.cpp b/src/pluginloader/replaygainpluginloader.cpp index 7ac11f6..2e37081 100755 --- a/src/pluginloader/replaygainpluginloader.cpp +++ b/src/pluginloader/replaygainpluginloader.cpp @@ -1,7 +1,7 @@ #include "replaygainpluginloader.h" -#include +#include #include @@ -19,9 +19,9 @@ ReplayGainPluginLoader::ReplayGainPluginLoader() ReplayGainPluginLoader::~ReplayGainPluginLoader() {} -int ReplayGainPluginLoader::verifyFile( QString fileName ) +int ReplayGainPluginLoader::verifyFile( TQString fileName ) { - QFile opmlFile( fileName ); + TQFile opmlFile( fileName ); if( !opmlFile.open( IO_ReadOnly ) ) { return -1; } @@ -30,10 +30,10 @@ int ReplayGainPluginLoader::verifyFile( QString fileName ) } opmlFile.close(); - QDomElement root = domTree.documentElement(); + TQDomElement root = domTree.documentElement(); if( root.attribute("type") != "replaygain" ) return -1; int version; - QDomNode node; + TQDomNode node; node = root.firstChild(); while( !node.isNull() ) { if( node.isElement() && node.nodeName() == "info" ) { @@ -45,17 +45,17 @@ int ReplayGainPluginLoader::verifyFile( QString fileName ) return version; } -ReplayGainPlugin* ReplayGainPluginLoader::loadFile( QString fileName ) +ReplayGainPlugin* ReplayGainPluginLoader::loadFile( TQString fileName ) { //int t_int; //float t_float; - //QString t_str; + //TQString t_str; ReplayGainPlugin* plugin = new ReplayGainPlugin(); plugin->info.version = -1; // if something goes wrong, we can see that by looking at plugin->info.version plugin->filePathName = fileName; - QFile opmlFile( fileName ); + TQFile opmlFile( fileName ); if( !opmlFile.open( IO_ReadOnly ) ) { return plugin; } @@ -64,9 +64,9 @@ ReplayGainPlugin* ReplayGainPluginLoader::loadFile( QString fileName ) } opmlFile.close(); - QDomElement root = domTree.documentElement(); + TQDomElement root = domTree.documentElement(); if( root.attribute("type") != "replaygain" ) return plugin; - QDomNode node;//, sub1Node; + TQDomNode node;//, sub1Node; node = root.firstChild(); while( !node.isNull() ) { @@ -87,7 +87,7 @@ ReplayGainPlugin* ReplayGainPluginLoader::loadFile( QString fileName ) plugin->replaygain.in_files = node.toElement().attribute("in_files"); plugin->replaygain.output_single = node.toElement().attribute("output_single"); plugin->replaygain.output_multiple = node.toElement().attribute("output_multiple"); - plugin->replaygain.mime_types = QStringList::split( ',', node.toElement().attribute("mime_types","application/octet-stream") ); + plugin->replaygain.mime_types = TQStringList::split( ',', node.toElement().attribute("mime_types","application/octet-stream") ); plugin->replaygain.force = node.toElement().attribute("force"); plugin->replaygain.skip = node.toElement().attribute("skip"); plugin->replaygain.track = node.toElement().attribute("track"); diff --git a/src/pluginloader/replaygainpluginloader.h b/src/pluginloader/replaygainpluginloader.h index d1c1237..639514f 100755 --- a/src/pluginloader/replaygainpluginloader.h +++ b/src/pluginloader/replaygainpluginloader.h @@ -24,39 +24,39 @@ public: */ virtual ~ReplayGainPlugin(); - QString filePathName; // the file name of th plugin (needed to detect write permissions) + TQString filePathName; // the file name of th plugin (needed to detect write permissions) struct Info { int version; // the version of our plugin (v0.2.1 = 201, v11.3 = 110300) - QString name; // the name of our plugin - QString author; // the author of the plugin - QString about; // a short information aboue the plugin + TQString name; // the name of our plugin + TQString author; // the author of the plugin + TQString about; // a short information aboue the plugin } info; struct ReplayGain { //PluginLoaderBase::FeatureLevel level; int rank; - QString bin; - QString param; - QString silent_param; - QStringList mime_types; - QString in_files; - QString output_single; - QString output_multiple; - QString force; - QString skip; - QString track; // TODO remove track and album (put them into param) - QString album; - QString remove; + TQString bin; + TQString param; + TQString silent_param; + TQStringList mime_types; + TQString in_files; + TQString output_single; + TQString output_multiple; + TQString force; + TQString skip; + TQString track; // TODO remove track and album (put them into param) + TQString album; + TQString remove; /*struct Test // obsolete { bool enabled; - QString param; - QString output_track; - QString output_album; + TQString param; + TQString output_track; + TQString output_album; } test;*/ } replaygain; }; @@ -69,6 +69,7 @@ public: class ReplayGainPluginLoader : public PluginLoaderBase { Q_OBJECT + TQ_OBJECT public: /** * Constructor @@ -81,9 +82,9 @@ public: virtual ~ReplayGainPluginLoader(); /** is this file a replaygain plugin and loadable? */ - int verifyFile( QString ); + int verifyFile( TQString ); /** load a given file */ - ReplayGainPlugin* loadFile( QString ); + ReplayGainPlugin* loadFile( TQString ); }; #endif // REPLAYGAINPLUGINLOADER_H diff --git a/src/pluginloader/ripperpluginloader.cpp b/src/pluginloader/ripperpluginloader.cpp index 9c1f9d4..780efc8 100755 --- a/src/pluginloader/ripperpluginloader.cpp +++ b/src/pluginloader/ripperpluginloader.cpp @@ -1,7 +1,7 @@ #include "ripperpluginloader.h" -#include +#include #include @@ -19,9 +19,9 @@ RipperPluginLoader::RipperPluginLoader() RipperPluginLoader::~RipperPluginLoader() {} -int RipperPluginLoader::verifyFile( QString fileName ) +int RipperPluginLoader::verifyFile( TQString fileName ) { - QFile opmlFile( fileName ); + TQFile opmlFile( fileName ); if( !opmlFile.open( IO_ReadOnly ) ) { return -1; } @@ -30,10 +30,10 @@ int RipperPluginLoader::verifyFile( QString fileName ) } opmlFile.close(); - QDomElement root = domTree.documentElement(); + TQDomElement root = domTree.documentElement(); if( root.attribute("type") != "ripper" ) return -1; int version; - QDomNode node; + TQDomNode node; node = root.firstChild(); while( !node.isNull() ) { if( node.isElement() && node.nodeName() == "info" ) { @@ -45,17 +45,17 @@ int RipperPluginLoader::verifyFile( QString fileName ) return version; } -RipperPlugin* RipperPluginLoader::loadFile( QString fileName ) +RipperPlugin* RipperPluginLoader::loadFile( TQString fileName ) { int t_int; float t_float; - QString t_str; + TQString t_str; RipperPlugin* plugin = new RipperPlugin(); plugin->info.version = -1; // if something goes wrong, we can see that by looking at plugin->info.version plugin->filePathName = fileName; - QFile opmlFile( fileName ); + TQFile opmlFile( fileName ); if( !opmlFile.open( IO_ReadOnly ) ) { return plugin; } @@ -64,9 +64,9 @@ RipperPlugin* RipperPluginLoader::loadFile( QString fileName ) } opmlFile.close(); - QDomElement root = domTree.documentElement(); + TQDomElement root = domTree.documentElement(); if( root.attribute("type") != "ripper" ) return plugin; - QDomNode node, sub1Node; + TQDomNode node, sub1Node; node = root.firstChild(); while( !node.isNull() ) { diff --git a/src/pluginloader/ripperpluginloader.h b/src/pluginloader/ripperpluginloader.h index 6cf965e..7221d54 100755 --- a/src/pluginloader/ripperpluginloader.h +++ b/src/pluginloader/ripperpluginloader.h @@ -24,34 +24,34 @@ public: */ virtual ~RipperPlugin(); - QString filePathName; // the file name of th plugin (needed to detect write permissions) + TQString filePathName; // the file name of th plugin (needed to detect write permissions) struct Info { int version; // the version of our plugin (v0.2.1 = 201, v11.3 = 110300) - QString name; // the name of our plugin - QString author; // the author of the plugin - QString about; // a short information aboue the plugin + TQString name; // the name of our plugin + TQString author; // the author of the plugin + TQString about; // a short information aboue the plugin } info; struct Rip { //PluginLoaderBase::FeatureLevel level; int rank; - QString bin; - QString param; - QString silent_param; - QString out_file; - QString track; - QString device; - QString overwrite; - QString output; + TQString bin; + TQString param; + TQString silent_param; + TQString out_file; + TQString track; + TQString device; + TQString overwrite; + TQString output; struct FullDisc { bool enabled; - QString param; - QString output; + TQString param; + TQString output; } full_disc; } rip; }; @@ -64,6 +64,7 @@ public: class RipperPluginLoader : public PluginLoaderBase { Q_OBJECT + TQ_OBJECT public: /** * Constructor @@ -76,9 +77,9 @@ public: virtual ~RipperPluginLoader(); /** is this file a ripper plugin and loadable? */ - int verifyFile( QString ); + int verifyFile( TQString ); /** load a given file */ - RipperPlugin* loadFile( QString ); + RipperPlugin* loadFile( TQString ); }; #endif // RIPPERPLUGINLOADER_H -- cgit v1.2.1