summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKent Hansen <kent.hansen@nokia.com>2011-09-28 09:57:04 +0200
committerQt by Nokia <qt-info@nokia.com>2011-09-28 11:43:47 +0200
commit85569dfdff1caec2efb714a1a9cdc64094893ec1 (patch)
treea8eff782686b348c8ed0a97730e16156133e80ea
parent9a8466839b030a4ffebf74a813737d7cc55aa1d0 (diff)
Build with qt-in-namespace
Change-Id: Ia57e4f14d94ad63194dad52892bedf316a58a79a Reviewed-on: http://codereview.qt-project.org/5693 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Roberto Raggi <roberto.raggi@nokia.com> Reviewed-by: Aaron Kennedy <aaron.kennedy@nokia.com>
-rw-r--r--src/declarative/items/context2d/qsgcontext2dcommandbuffer.cpp3
-rw-r--r--src/declarative/items/qsgdragtarget.cpp2
-rw-r--r--src/declarative/items/qsgvisualadaptormodel.cpp4
-rw-r--r--src/declarative/particles/qsgcumulativedirection_p.h5
-rw-r--r--src/declarative/particles/qsgparticlegroup_p.h4
-rw-r--r--src/declarative/qml/qdeclarativeguard_p.h4
-rw-r--r--src/declarative/qml/v8/qv8qobjectwrapper.cpp7
-rw-r--r--src/declarative/util/qdeclarativechangeset.cpp4
-rw-r--r--src/imports/testlib/main.cpp8
-rw-r--r--tools/qmlmin/main.cpp11
10 files changed, 46 insertions, 6 deletions
diff --git a/src/declarative/items/context2d/qsgcontext2dcommandbuffer.cpp b/src/declarative/items/context2d/qsgcontext2dcommandbuffer.cpp
index 224f640abc..550ad77515 100644
--- a/src/declarative/items/context2d/qsgcontext2dcommandbuffer.cpp
+++ b/src/declarative/items/context2d/qsgcontext2dcommandbuffer.cpp
@@ -46,6 +46,8 @@
#define HAS_SHADOW(offsetX, offsetY, blur, color) (color.isValid() && color.alpha() && (blur || offsetX || offsetY))
+QT_BEGIN_NAMESPACE
+
void qt_image_boxblur(QImage& image, int radius, bool quality);
static QImage makeShadowImage(const QImage& image, qreal offsetX, qreal offsetY, qreal blur, const QColor& color)
@@ -394,4 +396,5 @@ void QSGContext2DCommandBuffer::reset()
imageIdx = 0;
}
+QT_END_NAMESPACE
diff --git a/src/declarative/items/qsgdragtarget.cpp b/src/declarative/items/qsgdragtarget.cpp
index 9ccc8703d4..5b6d36ee11 100644
--- a/src/declarative/items/qsgdragtarget.cpp
+++ b/src/declarative/items/qsgdragtarget.cpp
@@ -43,6 +43,8 @@
#include "qsgitem_p.h"
#include "qsgcanvas.h"
+QT_BEGIN_NAMESPACE
+
/*!
\qmlclass DragEvent QSGDragEvent
\brief The DragEvent object provides information about a drag event.
diff --git a/src/declarative/items/qsgvisualadaptormodel.cpp b/src/declarative/items/qsgvisualadaptormodel.cpp
index 3eb6214e47..4e3a1a6dc3 100644
--- a/src/declarative/items/qsgvisualadaptormodel.cpp
+++ b/src/declarative/items/qsgvisualadaptormodel.cpp
@@ -64,10 +64,10 @@
#include <QtCore/qhash.h>
#include <QtCore/qlist.h>
-QT_BEGIN_NAMESPACE
-
Q_DECLARE_METATYPE(QModelIndex)
+QT_BEGIN_NAMESPACE
+
class VDMDelegateDataType : public QDeclarativeRefCount
{
public:
diff --git a/src/declarative/particles/qsgcumulativedirection_p.h b/src/declarative/particles/qsgcumulativedirection_p.h
index a77f50fd5b..651e21ae65 100644
--- a/src/declarative/particles/qsgcumulativedirection_p.h
+++ b/src/declarative/particles/qsgcumulativedirection_p.h
@@ -61,4 +61,9 @@ public:
private:
QList<QSGDirection*> m_directions;
};
+
+QT_END_NAMESPACE
+
+QT_END_HEADER
+
#endif // QSGCUMULATIVEDIRECTION_P_H
diff --git a/src/declarative/particles/qsgparticlegroup_p.h b/src/declarative/particles/qsgparticlegroup_p.h
index 346b4ab77e..d0ac41ca79 100644
--- a/src/declarative/particles/qsgparticlegroup_p.h
+++ b/src/declarative/particles/qsgparticlegroup_p.h
@@ -44,6 +44,8 @@
#include "qsgparticlesystem_p.h"
#include "qdeclarativeparserstatus.h"
+QT_BEGIN_NAMESPACE
+
class QSGParticleGroup : public QSGStochasticState, public QDeclarativeParserStatus
{
Q_OBJECT
@@ -104,4 +106,6 @@ private:
QList<QObject*> m_delayedRedirects;
};
+QT_END_NAMESPACE
+
#endif
diff --git a/src/declarative/qml/qdeclarativeguard_p.h b/src/declarative/qml/qdeclarativeguard_p.h
index 393f2b0ee7..0dc9a5a831 100644
--- a/src/declarative/qml/qdeclarativeguard_p.h
+++ b/src/declarative/qml/qdeclarativeguard_p.h
@@ -108,8 +108,12 @@ protected:
virtual void objectDestroyed(T *) {}
};
+QT_END_NAMESPACE
+
Q_DECLARE_METATYPE(QDeclarativeGuard<QObject>)
+QT_BEGIN_NAMESPACE
+
QDeclarativeGuardImpl::QDeclarativeGuardImpl()
: o(0), next(0), prev(0)
{
diff --git a/src/declarative/qml/v8/qv8qobjectwrapper.cpp b/src/declarative/qml/v8/qv8qobjectwrapper.cpp
index 5b5c8be435..2649976513 100644
--- a/src/declarative/qml/v8/qv8qobjectwrapper.cpp
+++ b/src/declarative/qml/v8/qv8qobjectwrapper.cpp
@@ -56,11 +56,11 @@
#include <QtCore/qtimer.h>
#include <QtCore/qatomic.h>
-QT_BEGIN_NAMESPACE
-
Q_DECLARE_METATYPE(QJSValue);
Q_DECLARE_METATYPE(QDeclarativeV8Handle);
+QT_BEGIN_NAMESPACE
+
#if defined(__GNUC__)
# if (__GNUC__ * 100 + __GNUC_MINOR__) >= 405
// The code in this file does not violate strict aliasing, but GCC thinks it does
@@ -2070,3 +2070,6 @@ v8::Handle<v8::Value> MetaCallArgument::toValue(QV8Engine *engine)
return v8::Undefined();
}
}
+
+QT_END_NAMESPACE
+
diff --git a/src/declarative/util/qdeclarativechangeset.cpp b/src/declarative/util/qdeclarativechangeset.cpp
index 9e875938da..c264ca011e 100644
--- a/src/declarative/util/qdeclarativechangeset.cpp
+++ b/src/declarative/util/qdeclarativechangeset.cpp
@@ -41,6 +41,8 @@
#include "qdeclarativechangeset_p.h"
+QT_BEGIN_NAMESPACE
+
QDeclarativeChangeSet::QDeclarativeChangeSet()
: m_moveCounter(0)
{
@@ -469,3 +471,5 @@ QDebug operator <<(QDebug debug, const QDeclarativeChangeSet::Change &change)
return (debug.nospace() << "Change(" << change.index << "," << change.count << ")").space();
}
+QT_END_NAMESPACE
+
diff --git a/src/imports/testlib/main.cpp b/src/imports/testlib/main.cpp
index c12b9423a9..a6fb992fed 100644
--- a/src/imports/testlib/main.cpp
+++ b/src/imports/testlib/main.cpp
@@ -48,13 +48,14 @@
#include "private/qtestoptions_p.h"
#include "QtDeclarative/qsgitem.h"
#include <QtDeclarative/private/qdeclarativeengine_p.h>
-QT_BEGIN_NAMESPACE
QML_DECLARE_TYPE(QuickTestResult)
QML_DECLARE_TYPE(QuickTestEvent)
#include <QtDebug>
+QT_BEGIN_NAMESPACE
+
class QuickTestUtil : public QObject
{
Q_OBJECT
@@ -145,8 +146,13 @@ public Q_SLOTS:
return -1;
}
};
+
+QT_END_NAMESPACE
+
QML_DECLARE_TYPE(QuickTestUtil)
+QT_BEGIN_NAMESPACE
+
class QTestQmlModule : public QDeclarativeExtensionPlugin
{
Q_OBJECT
diff --git a/tools/qmlmin/main.cpp b/tools/qmlmin/main.cpp
index 7a5b8f9457..753479a6e5 100644
--- a/tools/qmlmin/main.cpp
+++ b/tools/qmlmin/main.cpp
@@ -50,6 +50,8 @@
#include <iostream>
#include <cstdlib>
+QT_BEGIN_NAMESPACE
+
//
// QML/JS minifier
//
@@ -483,7 +485,7 @@ static void usage(bool showHelp = false)
}
}
-int main(int argc, char *argv[])
+int runQmlmin(int argc, char *argv[])
{
QCoreApplication app(argc, argv);
@@ -589,3 +591,10 @@ int main(int argc, char *argv[])
return 0;
}
+
+QT_END_NAMESPACE
+
+int main(int argc, char **argv)
+{
+ return QT_PREPEND_NAMESPACE(runQmlmin(argc, argv));
+}