summaryrefslogtreecommitdiffstats
path: root/kdecore/kgenericfactory.tcc
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-01-03 04:12:51 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-01-03 04:12:51 +0000
commit560378aaca1784ba19806a0414a32b20c744de39 (patch)
treece0dfd7c3febf2a1adc7603d1019a8be2083c415 /kdecore/kgenericfactory.tcc
parentd4d5af1cdbd3cc65d095e0afc5b1f4260091cf5d (diff)
downloadtdelibs-560378aaca1784ba19806a0414a32b20c744de39.tar.gz
tdelibs-560378aaca1784ba19806a0414a32b20c744de39.zip
Automated conversion for enhanced compatibility with TQt for Qt4 3.4.0 TP1
NOTE: This will not compile with Qt4 (yet), however it does compile with Qt3 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdelibs@1211081 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kdecore/kgenericfactory.tcc')
-rw-r--r--kdecore/kgenericfactory.tcc66
1 files changed, 33 insertions, 33 deletions
diff --git a/kdecore/kgenericfactory.tcc b/kdecore/kgenericfactory.tcc
index 41cd77824..cee230b53 100644
--- a/kdecore/kgenericfactory.tcc
+++ b/kdecore/kgenericfactory.tcc
@@ -112,26 +112,26 @@ namespace KDEPrivate
// but not least the standard default constructor of parent/name .
// the choice of the right constructor is done using an ordered inheritance
// test.
- template <class Product, class ParentType = QObject>
+ template <class Product, class ParentType = TQObject>
class ConcreteFactory
{
public:
typedef typename If< PartInheritanceTest< Product >::Result,
KParts::Part,
typename If< QWidgetInheritanceTest< Product >::Result,
- QWidget, QObject >::Result >::Result BaseType;
+ QWidget, TQObject >::Result >::Result BaseType;
- static inline Product *create( QWidget *parentWidget, const char *widgetName,
- QObject *parent, const char *name,
+ static inline Product *create( QWidget *tqparentWidget, const char *widgetName,
+ TQObject *parent, const char *name,
const char *className, const QStringList &args )
{
- QMetaObject *metaObject = Product::staticMetaObject();
- while ( metaObject )
+ QMetaObject *tqmetaObject = Product::staticMetaObject();
+ while ( tqmetaObject )
{
- if ( !qstrcmp( className, metaObject->className() ) )
- return create( parentWidget, widgetName,
+ if ( !qstrcmp( className, tqmetaObject->className() ) )
+ return create( tqparentWidget, widgetName,
parent, name, args, Type2Type<BaseType>() );
- metaObject = metaObject->superClass();
+ tqmetaObject = tqmetaObject->superClass();
}
return 0;
}
@@ -139,15 +139,15 @@ namespace KDEPrivate
typedef typename If< QWidgetInheritanceTest<ParentType>::Result,
ParentType, QWidget >::Result WidgetParentType;
- static inline Product *create( QWidget *parentWidget, const char *widgetName,
- QObject *parent, const char *name,
+ static inline Product *create( QWidget *tqparentWidget, const char *widgetName,
+ TQObject *parent, const char *name,
const QStringList &args, Type2Type<KParts::Part> )
{
- return new Product( parentWidget, widgetName, parent, name, args );
+ return new Product( tqparentWidget, widgetName, parent, name, args );
}
- static inline Product *create( QWidget* /*parentWidget*/, const char* /*widgetName*/,
- QObject *parent, const char *name,
+ static inline Product *create( QWidget* /*tqparentWidget*/, const char* /*widgetName*/,
+ TQObject *parent, const char *name,
const QStringList &args, Type2Type<QWidget> )
{
@@ -157,9 +157,9 @@ namespace KDEPrivate
return new Product( p, name, args );
}
- static inline Product *create( QWidget* /*parentWidget*/, const char* /*widgetName*/,
- QObject *parent, const char *name,
- const QStringList &args, Type2Type<QObject> )
+ static inline Product *create( QWidget* /*tqparentWidget*/, const char* /*widgetName*/,
+ TQObject *parent, const char *name,
+ const QStringList &args, Type2Type<TQObject> )
{
ParentType *p = dynamic_cast<ParentType *>( parent );
if ( parent && !p )
@@ -171,16 +171,16 @@ namespace KDEPrivate
// this template is used to iterate through the typelist and call the
// concrete factory for each type. the specializations of this template
// are the ones actually being responsible for iterating, in fact.
- template <class Product, class ParentType = QObject>
+ template <class Product, class ParentType = TQObject>
class MultiFactory
{
public:
- inline static QObject *create( QWidget *parentWidget, const char *widgetName,
- QObject *parent, const char *name,
+ inline static TQObject *create( QWidget *tqparentWidget, const char *widgetName,
+ TQObject *parent, const char *name,
const char *className,
const QStringList &args )
{
- return ConcreteFactory<Product, ParentType>::create( parentWidget, widgetName,
+ return ConcreteFactory<Product, ParentType>::create( tqparentWidget, widgetName,
parent, name, className,
args );
}
@@ -193,7 +193,7 @@ namespace KDEPrivate
class MultiFactory<KDE::NullType>
{
public:
- inline static QObject *create( QWidget *, const char *, QObject *,
+ inline static TQObject *create( QWidget *, const char *, TQObject *,
const char *, const char *,
const QStringList & )
{ return 0; }
@@ -205,29 +205,29 @@ namespace KDEPrivate
class MultiFactory<KDE::NullType, KDE::NullType>
{
public:
- inline static QObject *create( QWidget *, const char *, QObject *,
+ inline static TQObject *create( QWidget *, const char *, TQObject *,
const char *, const char *,
const QStringList & )
{ return 0; }
};
template <class Product, class ProductListTail>
- class MultiFactory< KTypeList<Product, ProductListTail>, QObject >
+ class MultiFactory< KTypeList<Product, ProductListTail>, TQObject >
{
public:
- inline static QObject *create( QWidget *parentWidget, const char *widgetName,
- QObject *parent, const char *name,
+ inline static TQObject *create( QWidget *tqparentWidget, const char *widgetName,
+ TQObject *parent, const char *name,
const char *className,
const QStringList &args )
{
// try with the head of the typelist first. the head is always
// a concrete type.
- QObject *object = MultiFactory<Product>::create( parentWidget, widgetName,
+ TQObject *object = MultiFactory<Product>::create( tqparentWidget, widgetName,
parent, name, className,
args );
if ( !object )
- object = MultiFactory<ProductListTail>::create( parentWidget, widgetName,
+ object = MultiFactory<ProductListTail>::create( tqparentWidget, widgetName,
parent, name, className,
args );
@@ -241,15 +241,15 @@ namespace KDEPrivate
KTypeList<ParentType, ParentTypeListTail> >
{
public:
- inline static QObject *create( QWidget *parentWidget, const char *widgetName,
- QObject *parent, const char *name,
+ inline static TQObject *create( QWidget *tqparentWidget, const char *widgetName,
+ TQObject *parent, const char *name,
const char *className,
const QStringList &args )
{
// try with the head of the typelist first. the head is always
// a concrete type.
- QObject *object = MultiFactory<Product, ParentType>
- ::create( parentWidget, widgetName,
+ TQObject *object = MultiFactory<Product, ParentType>
+ ::create( tqparentWidget, widgetName,
parent, name, className, args );
// if that failed continue by advancing the typelist, calling this
@@ -257,7 +257,7 @@ namespace KDEPrivate
// at the end we reach the nulltype specialization.
if ( !object )
object = MultiFactory<ProductListTail, ParentTypeListTail>
- ::create( parentWidget, widgetName,
+ ::create( tqparentWidget, widgetName,
parent, name, className, args );
return object;