summaryrefslogtreecommitdiffstats
path: root/src/tools/moc/moc.h
diff options
context:
space:
mode:
authorJoão Abecasis <joao.abecasis@nokia.com>2012-03-08 12:01:25 +0100
committerJoão Abecasis <joao.abecasis@nokia.com>2012-03-08 12:02:41 +0100
commit79f2480c868523a7d8ffc9fb15055e8eab3237ba (patch)
tree8336143e8c09810dc97324970fed61af27e26a97 /src/tools/moc/moc.h
parent7e4f32993498db0e06346e32458a1ec7d0c7b3ec (diff)
parent12f221410fbe41d0b2efda4cd3289dfcf9044aa8 (diff)
Merge remote-tracking branch 'origin/api_changes' into containters
Conflicts: src/corelib/kernel/qmetaobject.cpp src/corelib/kernel/qvariant.cpp src/tools/moc/moc.h Change-Id: I2cd3d95b41d2636738c6b98064864941e3b0b4e6
Diffstat (limited to 'src/tools/moc/moc.h')
-rw-r--r--src/tools/moc/moc.h13
1 files changed, 11 insertions, 2 deletions
diff --git a/src/tools/moc/moc.h b/src/tools/moc/moc.h
index e20e29acb8..b12ec492ff 100644
--- a/src/tools/moc/moc.h
+++ b/src/tools/moc/moc.h
@@ -43,6 +43,7 @@
#define MOC_H
#include "parser.h"
+#include "preprocessor.h"
#include <QStringList>
#include <QMap>
#include <QPair>
@@ -197,12 +198,14 @@ struct NamespaceDef {
class Moc : public Parser
{
public:
- Moc()
- : noInclude(false), generatedCode(false), mustIncludeQPluginH(false)
+ Moc(Preprocessor &p)
+ : preprocessor(p), noInclude(false), generatedCode(false),
+ mustIncludeQPluginH(false)
{}
QByteArray filename;
+ Preprocessor &preprocessor;
bool noInclude;
bool generatedCode;
bool mustIncludeQPluginH;
@@ -259,6 +262,12 @@ public:
void checkSuperClasses(ClassDef *def);
void checkProperties(ClassDef* cdef);
+
+ QByteArray getSubstitution(const QByteArray &token) const;
+ QByteArray getTokenSubstitution(const QByteArray &token) const;
+ QByteArray getWordSubstitution(const QByteArray &word) const;
+ QByteArray getNameSubstitution(const QByteArray &name) const;
+ QByteArray getTypeSubstitution(const QByteArray &typeName) const;
};
inline QByteArray noRef(const QByteArray &type)