summaryrefslogtreecommitdiffstats
path: root/kparts
diff options
context:
space:
mode:
Diffstat (limited to 'kparts')
-rw-r--r--kparts/factory.cpp4
-rw-r--r--kparts/factory.h8
-rw-r--r--kparts/genericfactory.h34
-rw-r--r--kparts/part.cpp6
-rw-r--r--kparts/part.h14
-rw-r--r--kparts/partmanager.cpp2
-rw-r--r--kparts/partmanager.h4
-rw-r--r--kparts/plugin.cpp12
-rw-r--r--kparts/plugin.h12
-rw-r--r--kparts/tests/notepad.cpp4
-rw-r--r--kparts/tests/notepad.h4
-rw-r--r--kparts/tests/parts.cpp4
-rw-r--r--kparts/tests/parts.h4
13 files changed, 56 insertions, 56 deletions
diff --git a/kparts/factory.cpp b/kparts/factory.cpp
index 7d04b43d1..a3985fd05 100644
--- a/kparts/factory.cpp
+++ b/kparts/factory.cpp
@@ -47,7 +47,7 @@ Part *Factory::createPart( TQWidget *parentWidget, const char *widgetName, TQObj
return part;
}
-const KInstance *Factory::partInstance()
+const TDEInstance *Factory::partInstance()
{
QueryInstanceParams params;
params.instance = 0;
@@ -55,7 +55,7 @@ const KInstance *Factory::partInstance()
return params.instance;
}
-const KInstance *Factory::partInstanceFromLibrary( const TQCString &libraryName )
+const TDEInstance *Factory::partInstanceFromLibrary( const TQCString &libraryName )
{
KLibrary *library = KLibLoader::self()->library( libraryName );
if ( !library )
diff --git a/kparts/factory.h b/kparts/factory.h
index 26c53b9dc..05b23d9d9 100644
--- a/kparts/factory.h
+++ b/kparts/factory.h
@@ -75,12 +75,12 @@ public:
/**
* If you have a part contained in a shared library you might want to query
- * for meta-information like the about-data, or the KInstance in general.
+ * for meta-information like the about-data, or the TDEInstance in general.
* If the part is exported using KParts::GenericFactory then this method will
* return the instance that belongs to the part without the need to instantiate
* the part component.
*/
- const KInstance *partInstance();
+ const TDEInstance *partInstance();
/**
* A convenience method for partInstance() that takes care of retrieving
@@ -88,7 +88,7 @@ public:
*
* @param libraryName name of the library to query the instance from
*/
- static const KInstance *partInstanceFromLibrary( const TQCString &libraryName );
+ static const TDEInstance *partInstanceFromLibrary( const TQCString &libraryName );
protected:
@@ -129,7 +129,7 @@ protected:
enum { VIRTUAL_QUERY_INSTANCE_PARAMS = 0x10 };
struct QueryInstanceParams
{
- const KInstance *instance;
+ const TDEInstance *instance;
};
};
diff --git a/kparts/genericfactory.h b/kparts/genericfactory.h
index f4ab3be16..7deea1248 100644
--- a/kparts/genericfactory.h
+++ b/kparts/genericfactory.h
@@ -32,13 +32,13 @@ namespace KParts
s_self = 0;
}
- static KInstance *instance();
- static KAboutData *aboutData();
+ static TDEInstance *instance();
+ static TDEAboutData *aboutData();
protected:
- virtual KInstance *createInstance()
+ virtual TDEInstance *createInstance()
{
- return new KInstance( aboutData() );
+ return new TDEInstance( aboutData() );
}
virtual void virtual_hook( int id, void *data )
@@ -54,30 +54,30 @@ namespace KParts
private:
static GenericFactoryBase<T> *s_self;
- static KInstance *s_instance;
- static KAboutData *s_aboutData;
+ static TDEInstance *s_instance;
+ static TDEAboutData *s_aboutData;
};
/**
* A template for a KParts::Factory implementation. It implements the pure virtual
* createPartObject method by instantiating the template argument when requested
- * through the className field. In addition it is a container for a part's KInstance
- * object, by providing a static KInstance *instance() method.
+ * through the className field. In addition it is a container for a part's TDEInstance
+ * object, by providing a static TDEInstance *instance() method.
*
* The template argument has to inherit from KParts::Part and has to implement two methods:
* 1) There needs to be a public constructor with the following signature:
* MyPart( TQWidget *parentWidget, const char *widgetName, TQObject *parent, const char *name, const TQStringList& args )
*
- * 2) It needs to provide one static method to create a KAboutData object per
+ * 2) It needs to provide one static method to create a TDEAboutData object per
* request, holding information about the component's name, its authors, license, etc.
* The signature of that static method has to be
- * KAboutData *createAboutData()
+ * TDEAboutData *createAboutData()
*
- * The template will take care of memory management of the KInstance and the KAboutData object,
+ * The template will take care of memory management of the TDEInstance and the TDEAboutData object,
* meaning ownership of what createAboutData returns is passed to the caller (this template) .
*
* For advanced use you can also inherit from the template and re-implement additionally the
- * virtual KInstance *createInstance() method, for example in case you want to extend the
+ * virtual TDEInstance *createInstance() method, for example in case you want to extend the
* paths of your instance's KStandardDirs object.
*
* If a KParts::ReadOnlyPart is requested through this factory and the template argument
@@ -159,26 +159,26 @@ namespace KParts
* @internal
*/
template <class T>
- KInstance *GenericFactoryBase<T>::s_instance = 0;
+ TDEInstance *GenericFactoryBase<T>::s_instance = 0;
/**
* @internal
*/
template <class T>
- KAboutData *GenericFactoryBase<T>::s_aboutData = 0;
+ TDEAboutData *GenericFactoryBase<T>::s_aboutData = 0;
/**
* @internal
*/
template <class T>
- KInstance *GenericFactoryBase<T>::instance()
+ TDEInstance *GenericFactoryBase<T>::instance()
{
if ( !s_instance )
{
if ( s_self )
s_instance = s_self->createInstance();
else
- s_instance = new KInstance( aboutData() );
+ s_instance = new TDEInstance( aboutData() );
}
return s_instance;
}
@@ -187,7 +187,7 @@ namespace KParts
* @internal
*/
template <class T>
- KAboutData *GenericFactoryBase<T>::aboutData()
+ TDEAboutData *GenericFactoryBase<T>::aboutData()
{
if ( !s_aboutData )
s_aboutData = T::createAboutData();
diff --git a/kparts/part.cpp b/kparts/part.cpp
index a76fce282..d2efbeeac 100644
--- a/kparts/part.cpp
+++ b/kparts/part.cpp
@@ -102,12 +102,12 @@ TQObject *PartBase::partObject() const
return m_obj;
}
-void PartBase::setInstance( KInstance *inst )
+void PartBase::setInstance( TDEInstance *inst )
{
setInstance( inst, true );
}
-void PartBase::setInstance( KInstance *inst, bool bLoadPlugins )
+void PartBase::setInstance( TDEInstance *inst, bool bLoadPlugins )
{
KXMLGUIClient::setInstance( inst );
KGlobal::locale()->insertCatalogue( inst->instanceName() );
@@ -119,7 +119,7 @@ void PartBase::setInstance( KInstance *inst, bool bLoadPlugins )
loadPlugins( m_obj, this, instance() );
}
-void PartBase::loadPlugins( TQObject *parent, KXMLGUIClient *parentGUIClient, KInstance *instance )
+void PartBase::loadPlugins( TQObject *parent, KXMLGUIClient *parentGUIClient, TDEInstance *instance )
{
if( d->m_pluginLoadingMode != DoNotLoadPlugins )
Plugin::loadPlugins( parent, parentGUIClient, instance, d->m_pluginLoadingMode == LoadPlugins );
diff --git a/kparts/part.h b/kparts/part.h
index 0c4023f6c..8a58063af 100644
--- a/kparts/part.h
+++ b/kparts/part.h
@@ -27,7 +27,7 @@
#include <kxmlguiclient.h>
-class KInstance;
+class TDEInstance;
class TQWidget;
class KAction;
class KActionCollection;
@@ -79,24 +79,24 @@ public:
protected:
/**
- * Set the instance ( KInstance) for this part.
+ * Set the instance ( TDEInstance) for this part.
*
* Call this *first* in the inherited class constructor,
* because it loads the i18n catalogues.
*/
- virtual void setInstance( KInstance *instance );
+ virtual void setInstance( TDEInstance *instance );
/**
- * Set the instance ( KInstance) for this part.
+ * Set the instance ( TDEInstance) for this part.
*
* Call this *first* in the inherited class constructor,
* because it loads the i18n catalogues.
*/
- virtual void setInstance( KInstance *instance, bool loadPlugins );
+ virtual void setInstance( TDEInstance *instance, bool loadPlugins );
/**
* We have three different policies, whether to load new plugins or not. The
- * value in the KConfig object of the KInstance object always overrides
+ * value in the KConfig object of the TDEInstance object always overrides
* LoadPlugins and LoadPluginsIfEnabled.
*/
enum PluginLoadingMode {
@@ -140,7 +140,7 @@ protected:
* }
* \endcode
*/
- void loadPlugins( TQObject *parent, KXMLGUIClient *parentGUIClient, KInstance *instance );
+ void loadPlugins( TQObject *parent, KXMLGUIClient *parentGUIClient, TDEInstance *instance );
/**
* For a KParts::Part: call this before setInstance().
diff --git a/kparts/partmanager.cpp b/kparts/partmanager.cpp
index 97a8b9961..8d9ff1994 100644
--- a/kparts/partmanager.cpp
+++ b/kparts/partmanager.cpp
@@ -486,7 +486,7 @@ void PartManager::setActivePart( Part *part, TQWidget *widget )
emit activePartChanged( d->m_activePart );
}
-void PartManager::setActiveInstance( KInstance * instance )
+void PartManager::setActiveInstance( TDEInstance * instance )
{
// It's a separate method to allow redefining this behavior
KGlobal::_activeInstance = instance;
diff --git a/kparts/partmanager.h b/kparts/partmanager.h
index 33c13d3ed..604e5ff92 100644
--- a/kparts/partmanager.h
+++ b/kparts/partmanager.h
@@ -27,7 +27,7 @@
#include <tdelibs_export.h>
-class KInstance;
+class TDEInstance;
namespace KParts
{
@@ -256,7 +256,7 @@ protected:
* The active instance is used by KBugReport and KAboutDialog.
* Override if you really need to - usually you don't need to.
*/
- virtual void setActiveInstance( KInstance * instance );
+ virtual void setActiveInstance( TDEInstance * instance );
protected slots:
/**
diff --git a/kparts/plugin.cpp b/kparts/plugin.cpp
index b5c50be2c..1e5ca9008 100644
--- a/kparts/plugin.cpp
+++ b/kparts/plugin.cpp
@@ -45,7 +45,7 @@ class Plugin::PluginPrivate
public:
PluginPrivate() : m_parentInstance( 0 ) {}
- const KInstance *m_parentInstance;
+ const TDEInstance *m_parentInstance;
TQString m_library; // filename of the library
};
@@ -86,7 +86,7 @@ TQString Plugin::localXMLFile() const
}
//static
-TQValueList<Plugin::PluginInfo> Plugin::pluginInfos( const KInstance * instance )
+TQValueList<Plugin::PluginInfo> Plugin::pluginInfos( const TDEInstance * instance )
{
if ( !instance )
kdError(1000) << "No instance ???" << endl;
@@ -138,12 +138,12 @@ TQValueList<Plugin::PluginInfo> Plugin::pluginInfos( const KInstance * instance
return plugins;
}
-void Plugin::loadPlugins( TQObject *parent, const KInstance *instance )
+void Plugin::loadPlugins( TQObject *parent, const TDEInstance *instance )
{
loadPlugins( parent, pluginInfos( instance ), instance );
}
-void Plugin::loadPlugins( TQObject *parent, const TQValueList<PluginInfo> &pluginInfos, const KInstance *instance )
+void Plugin::loadPlugins( TQObject *parent, const TQValueList<PluginInfo> &pluginInfos, const TDEInstance *instance )
{
TQValueList<PluginInfo>::ConstIterator pIt = pluginInfos.begin();
TQValueList<PluginInfo>::ConstIterator pEnd = pluginInfos.end();
@@ -218,13 +218,13 @@ bool Plugin::hasPlugin( TQObject* parent, const TQString& library )
return false;
}
-void Plugin::setInstance( KInstance *instance )
+void Plugin::setInstance( TDEInstance *instance )
{
KGlobal::locale()->insertCatalogue( instance->instanceName() );
KXMLGUIClient::setInstance( instance );
}
-void Plugin::loadPlugins( TQObject *parent, KXMLGUIClient* parentGUIClient, KInstance* instance, bool enableNewPluginsByDefault )
+void Plugin::loadPlugins( TQObject *parent, KXMLGUIClient* parentGUIClient, TDEInstance* instance, bool enableNewPluginsByDefault )
{
KConfigGroup cfgGroup( instance->config(), "KParts Plugins" );
TQValueList<PluginInfo> plugins = pluginInfos( instance );
diff --git a/kparts/plugin.h b/kparts/plugin.h
index 0da0a46e0..efebf5af4 100644
--- a/kparts/plugin.h
+++ b/kparts/plugin.h
@@ -24,7 +24,7 @@
#include <kaction.h>
#include <kxmlguiclient.h>
-class KInstance;
+class TDEInstance;
namespace KParts
{
@@ -86,7 +86,7 @@ public:
* It is recommended to use the last loadPlugins method instead,
* to support enabling and disabling of plugins.
*/
- static void loadPlugins( TQObject *parent, const KInstance * instance );
+ static void loadPlugins( TQObject *parent, const TDEInstance * instance );
/**
* Load the plugin libraries specified by the list @p docs and make the
@@ -104,7 +104,7 @@ public:
* It is recommended to use the last loadPlugins method instead,
* to support enabling and disabling of plugins.
*/
- static void loadPlugins( TQObject *parent, const TQValueList<PluginInfo> &pluginInfos, const KInstance * instance );
+ static void loadPlugins( TQObject *parent, const TQValueList<PluginInfo> &pluginInfos, const TDEInstance * instance );
/**
* Load the plugin libraries for the given @p instance, make the
@@ -140,7 +140,7 @@ public:
* }
* \endcode
*/
- static void loadPlugins( TQObject *parent, KXMLGUIClient* parentGUIClient, KInstance* instance, bool enableNewPluginsByDefault = true );
+ static void loadPlugins( TQObject *parent, KXMLGUIClient* parentGUIClient, TDEInstance* instance, bool enableNewPluginsByDefault = true );
/**
* Returns a list of plugin objects loaded for @p parent. This
@@ -156,7 +156,7 @@ protected:
*
* @return A list of TQDomDocument s, containing the parsed xml documents returned by plugins.
*/
- static TQValueList<Plugin::PluginInfo> pluginInfos( const KInstance * instance );
+ static TQValueList<Plugin::PluginInfo> pluginInfos( const TDEInstance * instance );
/**
* @internal
@@ -164,7 +164,7 @@ protected:
*/
static Plugin* loadPlugin( TQObject * parent, const char* libname );
- virtual void setInstance( KInstance *instance );
+ virtual void setInstance( TDEInstance *instance );
private:
static bool hasPlugin( TQObject* parent, const TQString& library );
diff --git a/kparts/tests/notepad.cpp b/kparts/tests/notepad.cpp
index e0857a51e..844a4ba17 100644
--- a/kparts/tests/notepad.cpp
+++ b/kparts/tests/notepad.cpp
@@ -46,9 +46,9 @@ void NotepadPart::setReadWrite( bool rw )
ReadWritePart::setReadWrite( rw );
}
-KAboutData* NotepadPart::createAboutData()
+TDEAboutData* NotepadPart::createAboutData()
{
- return new KAboutData( "notepadpart", I18N_NOOP( "Notepad" ), "2.0" );
+ return new TDEAboutData( "notepadpart", I18N_NOOP( "Notepad" ), "2.0" );
}
bool NotepadPart::openFile()
diff --git a/kparts/tests/notepad.h b/kparts/tests/notepad.h
index d192d42ec..9cc4f2d9a 100644
--- a/kparts/tests/notepad.h
+++ b/kparts/tests/notepad.h
@@ -5,7 +5,7 @@
#include <kparts/genericfactory.h>
#include <kparts/part.h>
-class KAboutData;
+class TDEAboutData;
class TQMultiLineEdit;
/**
@@ -24,7 +24,7 @@ public:
virtual void setReadWrite( bool rw );
- static KAboutData* createAboutData();
+ static TDEAboutData* createAboutData();
protected:
virtual bool openFile();
diff --git a/kparts/tests/parts.cpp b/kparts/tests/parts.cpp
index d932a168f..97ebdd4fb 100644
--- a/kparts/tests/parts.cpp
+++ b/kparts/tests/parts.cpp
@@ -21,7 +21,7 @@
Part1::Part1( TQObject *parent, TQWidget * parentWidget )
: KParts::ReadOnlyPart( parent, "Part1" )
{
- m_instance = new KInstance( "kpartstestpart" );
+ m_instance = new TDEInstance( "kpartstestpart" );
setInstance( m_instance );
m_edit = new TQMultiLineEdit( parentWidget );
setWidget( m_edit );
@@ -59,7 +59,7 @@ bool Part1::openFile()
Part2::Part2( TQObject *parent, TQWidget * parentWidget )
: KParts::Part( parent, "Part2" )
{
- m_instance = new KInstance( "part2" );
+ m_instance = new TDEInstance( "part2" );
setInstance( m_instance );
TQWidget * w = new TQWidget( parentWidget, "Part2Widget" );
setWidget( w );
diff --git a/kparts/tests/parts.h b/kparts/tests/parts.h
index 6f373a85c..0d4e6480a 100644
--- a/kparts/tests/parts.h
+++ b/kparts/tests/parts.h
@@ -21,7 +21,7 @@ protected:
protected:
TQMultiLineEdit * m_edit;
- KInstance *m_instance;
+ TDEInstance *m_instance;
};
class Part2 : public KParts::Part
@@ -37,7 +37,7 @@ protected:
// (i.e. in a part manager)
// There is a default impl for ReadOnlyPart...
virtual void guiActivateEvent( KParts::GUIActivateEvent * );
- KInstance *m_instance;
+ TDEInstance *m_instance;
};
#endif