qt -> tqt conversion:

QT_NO_ASCII_CAST -> TQT_NO_ASCII_CAST
QT_NO_STL -> TQT_NO_STL
QT_NO_COMPAT -> TQT_NO_COMPAT
QT_NO_TRANSLATION -> TQT_NO_TRANSLATION

Signed-off-by: Michele Calgaro <michele.calgaro@yahoo.it>
pull/2/head
Michele Calgaro hace 6 años
padre 7b9c011fa0
commit 65ff0e19f4
Firmado por: MicheleC
ID de clave GPG: 2A75B7CA8ADED5CF

@ -169,7 +169,7 @@ endif( )
# definitions
if( QT_VERSION STREQUAL "3" )
if( HAVE_REAL_TQT )
set( QT_DEFINITIONS "-DQT_NO_ASCII_CAST -DQT_NO_STL -DQT_NO_COMPAT -DQT_NO_TRANSLATION -DTQT_THREAD_SUPPORT -D_REENTRANT" )
set( QT_DEFINITIONS "-DTQT_NO_ASCII_CAST -DTQT_NO_STL -DTQT_NO_COMPAT -DTQT_NO_TRANSLATION -DTQT_THREAD_SUPPORT -D_REENTRANT" )
else( )
set( QT_DEFINITIONS "-DQT_NO_ASCII_CAST -DQT_NO_STL -DQT_NO_COMPAT -DQT_NO_TRANSLATION -DQT_THREAD_SUPPORT -D_REENTRANT" )
endif( )

@ -14,7 +14,7 @@ qguardedptr (TQGuardedPtr, weird compilation failure)
qinputdialog
qnetworkprotocol (QNetworkProtocolFactory, weird compilation failure)
qsessionmanager
qtranslator (QT_NO_TRANSLATION is set, MOC does not honor #ifdef)
qtranslator (TQT_NO_TRANSLATION is set, MOC does not honor #ifdef)
qwidgetplugin (TQWidgetContainerPlugin, weird compilation failure)
@ -57,4 +57,4 @@ All of Trinity now uses TQ<something>, e.g. QTimer is now TQTimer. Depending on
#define TQCString QCString (for Qt3)
#define TQCString Q3CString (for Qt4)
If needed, the TQ function can subclass the Q or Q3 function and reimplement the missing features. However, the vast majority of classes (those that have not changed much) will be handled with the simple #define statements, greatly simplifying and speeding implementation.
If needed, the TQ function can subclass the Q or Q3 function and reimplement the missing features. However, the vast majority of classes (those that have not changed much) will be handled with the simple #define statements, greatly simplifying and speeding implementation.

@ -12,7 +12,7 @@ if [ -f @BIN_INSTALL_DIR@/tqt-replace-stream ]; then
out_file="$3"
@BIN_INSTALL_DIR@/tqt-replace-stream "${input_file}" | \
@MOC_EXECUTABLE@ | \
sed "/#include <ntqmetaobject.h>/ i #undef QT_NO_COMPAT\n#include \"${input_file}\"" \
sed "/#include <ntqmetaobject.h>/ i #undef TQT_NO_COMPAT\n#include \"${input_file}\"" \
> "${out_file}"
fi
else

@ -130,11 +130,11 @@ class TQMapIterator
* Typedefs
*/
typedef TQMapNode< K, T >* NodePtr;
#ifndef QT_NO_STL
#ifndef TQT_NO_STL
typedef std::bidirectional_iterator_tag iterator_category;
#endif
typedef T value_type;
#ifndef QT_NO_STL
#ifndef TQT_NO_STL
typedef ptrdiff_t difference_type;
#else
typedef int difference_type;
@ -246,11 +246,11 @@ class TQMapConstIterator
* Typedefs
*/
typedef TQMapNode< K, T >* NodePtr;
#ifndef QT_NO_STL
#ifndef TQT_NO_STL
typedef std::bidirectional_iterator_tag iterator_category;
#endif
typedef T value_type;
#ifndef QT_NO_STL
#ifndef TQT_NO_STL
typedef ptrdiff_t difference_type;
#else
typedef int difference_type;
@ -631,7 +631,7 @@ public:
typedef const value_type* const_pointer;
typedef value_type& reference;
typedef const value_type& const_reference;
#ifndef QT_NO_STL
#ifndef TQT_NO_STL
typedef ptrdiff_t difference_type;
#else
typedef int difference_type;
@ -658,7 +658,7 @@ public:
sh = m.sh; sh->ref();
}
#ifndef QT_NO_STL
#ifndef TQT_NO_STL
TQMap( const std::map<Key,T>& m )
{
sh = new TQMapPrivate<Key,T>;
@ -675,7 +675,7 @@ public:
delete sh;
}
TQMap<Key,T>& operator= ( const TQMap<Key,T>& m );
#ifndef QT_NO_STL
#ifndef TQT_NO_STL
TQMap<Key,T>& operator= ( const std::map<Key,T>& m )
{
clear();
@ -787,7 +787,7 @@ public:
#if defined(Q_FULL_TEMPLATE_INSTANTIATION)
bool operator==( const TQMap<Key,T>& ) const { return FALSE; }
#ifndef QT_NO_STL
#ifndef TQT_NO_STL
bool operator==( const std::map<Key,T>& ) const { return FALSE; }
#endif
#endif

@ -245,7 +245,7 @@ public:
{ Q3GListIterator::operator=(it); return *this; }
};
#ifndef QT_NO_COMPAT
#ifndef TQT_NO_COMPAT
#define TQT_TQList TQPtrList
#define TQT_TQListIterator TQPtrListIterator
#endif

@ -110,12 +110,12 @@ class TQValueListIterator
* Typedefs
*/
typedef TQValueListNode<T>* NodePtr;
#ifndef QT_NO_STL
#ifndef TQT_NO_STL
typedef std::bidirectional_iterator_tag iterator_category;
#endif
typedef T value_type;
typedef size_t size_type;
#ifndef QT_NO_STL
#ifndef TQT_NO_STL
typedef ptrdiff_t difference_type;
#else
typedef int difference_type;
@ -186,12 +186,12 @@ class TQValueListConstIterator
* Typedefs
*/
typedef TQValueListNode<T>* NodePtr;
#ifndef QT_NO_STL
#ifndef TQT_NO_STL
typedef std::bidirectional_iterator_tag iterator_category;
#endif
typedef T value_type;
typedef size_t size_type;
#ifndef QT_NO_STL
#ifndef TQT_NO_STL
typedef ptrdiff_t difference_type;
#else
typedef int difference_type;
@ -451,7 +451,7 @@ public:
typedef value_type& reference;
typedef const value_type& const_reference;
typedef size_t size_type;
#ifndef QT_NO_STL
#ifndef TQT_NO_STL
typedef ptrdiff_t difference_type;
#else
typedef int difference_type;
@ -462,7 +462,7 @@ public:
*/
TQValueList() { sh = new TQValueListPrivate<T>; }
TQValueList( const TQValueList<T>& l ) { sh = l.sh; sh->ref(); }
#ifndef QT_NO_STL
#ifndef TQT_NO_STL
TQValueList( const std::list<T>& l )
{
sh = new TQValueListPrivate<T>;
@ -478,7 +478,7 @@ public:
sh = l.sh;
return *this;
}
#ifndef QT_NO_STL
#ifndef TQT_NO_STL
TQValueList<T>& operator= ( const std::list<T>& l )
{
detach();

@ -473,7 +473,7 @@ namespace QT_NAMESPACE {}
/* GCC 2.95 knows "using" but does not support it correctly */
# if __GNUC__ == 2 && __GNUC_MINOR__ <= 95
# define Q_NO_USING_KEYWORD
# define QT_NO_STL_WCHAR
# define TQT_NO_STL_WCHAR
# endif
# if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 95)
# define Q_ALIGNOF(type) __alignof__(type)
@ -2346,7 +2346,7 @@ template <typename Wrapper> static inline typename Wrapper::pointer qGetPtrHelpe
#define QT_TRANSLATE_NOOP3(scope, x, comment) {x, comment}
#define QT_TRANSLATE_NOOP3_UTF8(scope, x, comment) {x, comment}
#ifndef QT_NO_TRANSLATION // ### This should enclose the NOOPs above
#ifndef TQT_NO_TRANSLATION // ### This should enclose the NOOPs above
// Defined in qcoreapplication.cpp
// The better name qTrId() is reserved for an upcoming function which would
@ -2355,7 +2355,7 @@ Q_CORE_EXPORT QString qtTrId(const char *id, int n = -1);
#define QT_TRID_NOOP(id) id
#endif // QT_NO_TRANSLATION
#endif // TQT_NO_TRANSLATION
#define QDOC_PROPERTY(text)

@ -46,7 +46,7 @@
#include <QtCore/qatomic.h>
#include <QtCore/qalgorithms.h>
#ifndef QT_NO_STL
#ifndef TQT_NO_STL
#include <iterator>
#include <list>
#endif
@ -332,7 +332,7 @@ public:
static QList<T> fromVector(const QVector<T> &vector);
static QList<T> fromSet(const QSet<T> &set);
#ifndef QT_NO_STL
#ifndef TQT_NO_STL
static inline QList<T> fromStdList(const std::list<T> &list)
{ QList<T> tmp; qCopy(list.begin(), list.end(), std::back_inserter(tmp)); return tmp; }
inline std::list<T> toStdList() const

@ -137,7 +137,7 @@ public:
virtual const QMetaObject *metaObject() const;
static const QMetaObject staticMetaObject;
#endif
#ifdef QT_NO_TRANSLATION
#ifdef TQT_NO_TRANSLATION
static QString tr(const char *sourceText, const char *, int)
{ return QString::fromLatin1(sourceText); }
static QString tr(const char *sourceText, const char * = 0)
@ -148,7 +148,7 @@ public:
static QString trUtf8(const char *sourceText, const char * = 0)
{ return QString::fromUtf8(sourceText); }
#endif
#endif //QT_NO_TRANSLATION
#endif //TQT_NO_TRANSLATION
QString objectName() const;
void setObjectName(const QString &name);

@ -90,7 +90,7 @@ class QStringList;
#define Q_SIGNAL
#define Q_SLOT
#ifndef QT_NO_TRANSLATION
#ifndef TQT_NO_TRANSLATION
# ifndef QT_NO_TEXTCODEC
// full set of tr functions
// ### Qt 5: merge overloads
@ -290,13 +290,13 @@ struct Q_CORE_EXPORT QMetaObject
QObject *cast(QObject *obj) const;
#ifndef QT_NO_TRANSLATION
#ifndef TQT_NO_TRANSLATION
// ### Qt 4: Merge overloads
QString tr(const char *s, const char *c) const;
QString trUtf8(const char *s, const char *c) const;
QString tr(const char *s, const char *c, int n) const;
QString trUtf8(const char *s, const char *c, int n) const;
#endif // QT_NO_TRANSLATION
#endif // TQT_NO_TRANSLATION
int methodOffset() const;
int enumeratorOffset() const;

@ -50,7 +50,7 @@
#include <Qt3Support/q3cstring.h>
#endif
#ifndef QT_NO_STL
#ifndef TQT_NO_STL
# if defined (Q_CC_MSVC_NET) && _MSC_VER < 1310 // Avoids nasty warning for xlocale, line 450
# pragma warning (push)
# pragma warning (disable : 4189)
@ -60,12 +60,12 @@
# include <string>
# endif
# ifndef QT_NO_STL_WCHAR
# ifndef TQT_NO_STL_WCHAR
// workaround for some headers not typedef'ing std::wstring
typedef std::basic_string<wchar_t> QStdWString;
# endif // QT_NO_STL_WCHAR
# endif // TQT_NO_STL_WCHAR
#endif // QT_NO_STL
#endif // TQT_NO_STL
#include <stdarg.h>
@ -476,17 +476,17 @@ public:
inline void push_front(QChar c) { prepend(c); }
inline void push_front(const QString &s) { prepend(s); }
#ifndef QT_NO_STL
#ifndef TQT_NO_STL
static inline QString fromStdString(const std::string &s);
inline std::string toStdString() const;
# ifdef qdoc
static inline QString fromStdWString(const std::wstring &s);
inline std::wstring toStdWString() const;
# else
# ifndef QT_NO_STL_WCHAR
# ifndef TQT_NO_STL_WCHAR
static inline QString fromStdWString(const QStdWString &s);
inline QStdWString toStdWString() const;
# endif // QT_NO_STL_WCHAR
# endif // TQT_NO_STL_WCHAR
# endif // qdoc
#endif
@ -1031,14 +1031,14 @@ inline QT_ASCII_CAST_WARN const QString operator+(const QString &s, const QByteA
# endif // QT_USE_FAST_CONCATENATION
#endif // QT_USE_FAST_OPERATOR_PLUS
#ifndef QT_NO_STL
#ifndef TQT_NO_STL
inline std::string QString::toStdString() const
{ const QByteArray asc = toAscii(); return std::string(asc.constData(), asc.length()); }
inline QString QString::fromStdString(const std::string &s)
{ return fromAscii(s.data(), int(s.size())); }
# ifndef QT_NO_STL_WCHAR
# ifndef TQT_NO_STL_WCHAR
inline QStdWString QString::toStdWString() const
{
QStdWString str;

@ -47,7 +47,7 @@
#include <QtCore/qalgorithms.h>
#include <QtCore/qlist.h>
#ifndef QT_NO_STL
#ifndef TQT_NO_STL
#include <iterator>
#include <vector>
#endif
@ -292,7 +292,7 @@ public:
static QVector<T> fromList(const QList<T> &list);
#ifndef QT_NO_STL
#ifndef TQT_NO_STL
static inline QVector<T> fromStdVector(const std::vector<T> &vector)
{ QVector<T> tmp; qCopy(vector.begin(), vector.end(), std::back_inserter(tmp)); return tmp; }
inline std::vector<T> toStdVector() const

Cargando…
Cancelar
Guardar