summaryrefslogtreecommitdiffstats
path: root/quanta/plugins/quantaplugininterface.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'quanta/plugins/quantaplugininterface.cpp')
-rw-r--r--quanta/plugins/quantaplugininterface.cpp58
1 files changed, 29 insertions, 29 deletions
diff --git a/quanta/plugins/quantaplugininterface.cpp b/quanta/plugins/quantaplugininterface.cpp
index 45fb8caa..098c7828 100644
--- a/quanta/plugins/quantaplugininterface.cpp
+++ b/quanta/plugins/quantaplugininterface.cpp
@@ -25,10 +25,10 @@
#include <kmessagebox.h>
/* QT INCLUDES */
-#include <qdict.h>
-#include <qstring.h>
-#include <qstringlist.h>
-#include <qfileinfo.h>
+#include <tqdict.h>
+#include <tqstring.h>
+#include <tqstringlist.h>
+#include <tqfileinfo.h>
/* OTHER INCLUDES */
#include "quantaplugininterface.h"
@@ -38,11 +38,11 @@
#include "resource.h"
#include "quantacommon.h"
-QuantaPluginInterface::QuantaPluginInterface(QWidget *parent)
+QuantaPluginInterface::QuantaPluginInterface(TQWidget *parent)
{
m_parent = parent;
(void) new KAction( i18n( "Configure &Plugins..." ), 0, 0,
- this, SLOT( slotPluginsEdit() ),
+ this, TQT_SLOT( slotPluginsEdit() ),
((KMainWindow*)parent)->actionCollection(), "configure_plugins" );
m_pluginMenu = 0L;
// m_plugins.setAutoDelete(true);
@@ -54,33 +54,33 @@ QuantaPluginInterface::~QuantaPluginInterface()
// TODO : free plugins
}
-void QuantaPluginInterface::readConfigFile(const QString& configFile)
+void QuantaPluginInterface::readConfigFile(const TQString& configFile)
{
KConfig *config = new KConfig(configFile);
config->setGroup("General");
- QStringList pList = config->readListEntry("Plugins");
- for(QStringList::Iterator it = pList.begin();it != pList.end(); ++it)
+ TQStringList pList = config->readListEntry("Plugins");
+ for(TQStringList::Iterator it = pList.begin();it != pList.end(); ++it)
(*it) = (*it).stripWhiteSpace();
//setPluginNames(pList);
- QStringList paths = QuantaCommon::readPathListEntry(config, "SearchPaths");
- for(QStringList::Iterator it = paths.begin();it != paths.end(); ++it)
+ TQStringList paths = QuantaCommon::readPathListEntry(config, "SearchPaths");
+ for(TQStringList::Iterator it = paths.begin();it != paths.end(); ++it)
(*it) = (*it).stripWhiteSpace();
qConfig.pluginSearchPaths = paths;
// now that we have a list of the plugins, go through and get the details of them
- for(QStringList::Iterator it = pList.begin();it != pList.end();++it)
+ for(TQStringList::Iterator it = pList.begin();it != pList.end();++it)
{
if (m_plugins.find(*it))
continue;
config->setGroup(*it);
QuantaPlugin *newPlugin = 0;
- QString pluginType = config->readEntry("Type", "KPart");
+ TQString pluginType = config->readEntry("Type", "KPart");
bool isStandard = config->readBoolEntry("Standard",false);
/* if (isStandard)
{
- QString stdName = config->readEntry("Standard Name");
+ TQString stdName = config->readEntry("Standard Name");
if (newPlugin)
{
newPlugin->setStandardName(stdName);
@@ -101,7 +101,7 @@ void QuantaPluginInterface::readConfigFile(const QString& configFile)
newPlugin->setFileName(config->readEntry("FileName"));
newPlugin->setLocation(config->readEntry("Location"));
newPlugin->setIcon(config->readEntry("Icon"));
- QString type = config->readEntry("OutputWindow");
+ TQString type = config->readEntry("OutputWindow");
if (type == "Message Frame" || type == "Separate Toolview")
type = i18n("Separate Toolview");
else
@@ -121,8 +121,8 @@ void QuantaPluginInterface::readConfig()
m_plugins.clear();
// read the local plugins.rc
- QString configFile = locateLocal("appdata", "plugins.rc");
- if (QFileInfo(configFile).exists())
+ TQString configFile = locateLocal("appdata", "plugins.rc");
+ if (TQFileInfo(configFile).exists())
readConfigFile(configFile);
// read the global plugins.rc
configFile = qConfig.globalDataDir + resourceDir + "plugins.rc";
@@ -135,13 +135,13 @@ void QuantaPluginInterface::writeConfig()
// write the plugin settings to the rc file
KConfig *config = new KConfig(locateLocal("appdata", "plugins.rc"));
- QStringList names = pluginNames();
+ TQStringList names = pluginNames();
config->setGroup("General");
config->writeEntry("Plugins", names);
config->writePathEntry("SearchPaths", qConfig.pluginSearchPaths);
- for(QStringList::Iterator it = names.begin();it != names.end(); ++it)
+ for(TQStringList::Iterator it = names.begin();it != names.end(); ++it)
{
config->setGroup(*it);
@@ -152,7 +152,7 @@ void QuantaPluginInterface::writeConfig()
config->writeEntry("Type", "KPart"); //not used, but just to be compatible
config->writeEntry("Location", curPlugin->location());
config->writeEntry("Icon", curPlugin->icon());
- QString type = curPlugin->outputWindow();
+ TQString type = curPlugin->outputWindow();
if (type == i18n("Editor Tab")) type = "Editor Tab";
if (type == i18n("Separate Toolview")) type = "Separate Toolview";
config->writeEntry("OutputWindow", type);
@@ -172,7 +172,7 @@ void QuantaPluginInterface::writeConfig()
/** Returns true if the plugin is available */
-bool QuantaPluginInterface::pluginAvailable(const QString &a_name)
+bool QuantaPluginInterface::pluginAvailable(const TQString &a_name)
{
if (a_name.isEmpty())
return false;
@@ -184,10 +184,10 @@ bool QuantaPluginInterface::pluginAvailable(const QString &a_name)
}
/** Gets the plugin names */
-QStringList QuantaPluginInterface::pluginNames() const
+TQStringList QuantaPluginInterface::pluginNames() const
{
- QStringList names;
- QDictIterator<QuantaPlugin> it(m_plugins);
+ TQStringList names;
+ TQDictIterator<QuantaPlugin> it(m_plugins);
for(;it.current();++it)
{
names << (*it)->pluginName();
@@ -197,7 +197,7 @@ QStringList QuantaPluginInterface::pluginNames() const
/** Gets the plugin specified by a_name */
-QuantaPlugin *QuantaPluginInterface::plugin(const QString &a_name)
+QuantaPlugin *QuantaPluginInterface::plugin(const TQString &a_name)
{
if (a_name.isEmpty())
return 0L;
@@ -210,7 +210,7 @@ void QuantaPluginInterface::buildPluginMenu()
m_pluginMenu->clear();
// m_pluginMenu->setCheckable(true);
- QDictIterator<QuantaPlugin> it(m_plugins);
+ TQDictIterator<QuantaPlugin> it(m_plugins);
for(;it.current() != 0;++it)
{
QuantaPlugin *curPlugin = it.current();
@@ -240,8 +240,8 @@ void QuantaPluginInterface::slotPluginsEdit()
void QuantaPluginInterface::slotPluginsValidate()
{
- QValueList<QuantaPlugin*> invalidPlugins;
- QDictIterator<QuantaPlugin> it(m_plugins);
+ TQValueList<QuantaPlugin*> invalidPlugins;
+ TQDictIterator<QuantaPlugin> it(m_plugins);
for(;it.current();++it)
{
if(!QuantaPlugin::validatePlugin(it.current()))
@@ -252,7 +252,7 @@ void QuantaPluginInterface::slotPluginsValidate()
uint invalidCount = invalidPlugins.count();
if (invalidCount > 0)
{
- QString invalidNames;
+ TQString invalidNames;
for (uint i=0; i < invalidCount; i++)
{
invalidNames += "<br>" + invalidPlugins[i]->name();