summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/plugins/script/qtdbus/qtdbus.pro2
-rw-r--r--src/script/api/qscriptcontextinfo.cpp5
-rw-r--r--src/script/api/qscriptengine.cpp6
-rw-r--r--src/script/api/qscriptprogram.cpp1
-rw-r--r--src/script/api/qscriptprogram_p.h5
-rw-r--r--src/script/api/qscriptstring_p.h5
-rw-r--r--src/script/api/qscriptvalue_p.h6
-rw-r--r--src/script/script.pro2
-rw-r--r--src/scripttools/debugging/qscriptdebuggerconsolecommandgroupdata.cpp6
-rw-r--r--src/scripttools/debugging/qscriptdebuggervalue.cpp6
-rw-r--r--src/scripttools/debugging/qscriptdebuggervalueproperty.cpp7
-rw-r--r--src/scripttools/debugging/qscriptscriptdata.cpp6
-rw-r--r--src/scripttools/debugging/qscriptvalueproperty.cpp7
-rw-r--r--src/scripttools/scripttools.pro2
14 files changed, 24 insertions, 42 deletions
diff --git a/src/plugins/script/qtdbus/qtdbus.pro b/src/plugins/script/qtdbus/qtdbus.pro
index d3b5dfd..5db52ab 100644
--- a/src/plugins/script/qtdbus/qtdbus.pro
+++ b/src/plugins/script/qtdbus/qtdbus.pro
@@ -1,7 +1,7 @@
load(qt_module)
TARGET = qtscriptdbus
-include($$QT_SOURCE_TREE/src/plugins/qpluginbase.pri)
+load(qt_plugin)
QT = core gui script
CONFIG += qdbus
diff --git a/src/script/api/qscriptcontextinfo.cpp b/src/script/api/qscriptcontextinfo.cpp
index 182bc4a..41f4f83 100644
--- a/src/script/api/qscriptcontextinfo.cpp
+++ b/src/script/api/qscriptcontextinfo.cpp
@@ -30,6 +30,7 @@
#include "../bridge/qscriptqobject_p.h"
#include <QtCore/qdatastream.h>
#include <QtCore/qmetaobject.h>
+#include <QtCore/qshareddata.h>
#include "CodeBlock.h"
#include "JSFunction.h"
#if ENABLE(JIT)
@@ -81,7 +82,7 @@ QT_BEGIN_NAMESPACE
\value NativeFunction The function is a built-in Qt Script function, or it was defined through a call to QScriptEngine::newFunction().
*/
-class QScriptContextInfoPrivate
+class QScriptContextInfoPrivate : public QSharedData
{
Q_DECLARE_PUBLIC(QScriptContextInfo)
public:
@@ -103,8 +104,6 @@ public:
QStringList parameterNames;
- QBasicAtomicInt ref;
-
QScriptContextInfo *q_ptr;
};
diff --git a/src/script/api/qscriptengine.cpp b/src/script/api/qscriptengine.cpp
index 1c4f110..cbf48a9 100644
--- a/src/script/api/qscriptengine.cpp
+++ b/src/script/api/qscriptengine.cpp
@@ -38,6 +38,7 @@
#include "qdebug.h"
#include <QtCore/qstringlist.h>
+#include <QtCore/qshareddata.h>
#include <QtCore/qmetaobject.h>
#include <math.h>
@@ -326,17 +327,16 @@ QT_BEGIN_NAMESPACE
\value SkipMethodsInEnumeration Don't include methods (signals and slots) when enumerating the object's properties.
*/
-class QScriptSyntaxCheckResultPrivate
+class QScriptSyntaxCheckResultPrivate : public QSharedData
{
public:
- QScriptSyntaxCheckResultPrivate() { ref = 0; }
+ QScriptSyntaxCheckResultPrivate() {}
~QScriptSyntaxCheckResultPrivate() {}
QScriptSyntaxCheckResult::State state;
int errorColumnNumber;
int errorLineNumber;
QString errorMessage;
- QBasicAtomicInt ref;
};
class QScriptTypeInfo
diff --git a/src/script/api/qscriptprogram.cpp b/src/script/api/qscriptprogram.cpp
index c0e2656..b641a5a 100644
--- a/src/script/api/qscriptprogram.cpp
+++ b/src/script/api/qscriptprogram.cpp
@@ -57,7 +57,6 @@ QScriptProgramPrivate::QScriptProgramPrivate(const QString &src,
: sourceCode(src), fileName(fn), firstLineNumber(ln),
engine(0), _executable(0), sourceId(-1), isCompiled(false)
{
- ref = 0;
}
QScriptProgramPrivate::~QScriptProgramPrivate()
diff --git a/src/script/api/qscriptprogram_p.h b/src/script/api/qscriptprogram_p.h
index e7809ab..ce9fb08 100644
--- a/src/script/api/qscriptprogram_p.h
+++ b/src/script/api/qscriptprogram_p.h
@@ -36,6 +36,7 @@
//
#include <QtCore/qobjectdefs.h>
+#include <QtCore/qshareddata.h>
#include "RefPtr.h"
@@ -49,7 +50,7 @@ QT_BEGIN_NAMESPACE
class QScriptEnginePrivate;
-class QScriptProgramPrivate
+class QScriptProgramPrivate : public QSharedData
{
public:
QScriptProgramPrivate(const QString &sourceCode,
@@ -63,8 +64,6 @@ public:
QScriptEnginePrivate *engine);
void detachFromEngine();
- QBasicAtomicInt ref;
-
QString sourceCode;
QString fileName;
int firstLineNumber;
diff --git a/src/script/api/qscriptstring_p.h b/src/script/api/qscriptstring_p.h
index b632140..bb361c7 100644
--- a/src/script/api/qscriptstring_p.h
+++ b/src/script/api/qscriptstring_p.h
@@ -36,13 +36,14 @@
//
#include <QtCore/qobjectdefs.h>
+#include <QtCore/qshareddata.h>
#include "Identifier.h"
QT_BEGIN_NAMESPACE
class QScriptEnginePrivate;
-class QScriptStringPrivate
+class QScriptStringPrivate : public QSharedData
{
public:
enum AllocationType {
@@ -61,7 +62,6 @@ public:
static inline bool isValid(const QScriptString &q);
- QBasicAtomicInt ref;
QScriptEnginePrivate *engine;
JSC::Identifier identifier;
AllocationType type;
@@ -75,7 +75,6 @@ inline QScriptStringPrivate::QScriptStringPrivate(QScriptEnginePrivate *e, const
AllocationType tp)
: engine(e), identifier(id), type(tp), prev(0), next(0)
{
- ref = 0;
}
inline QScriptStringPrivate::~QScriptStringPrivate()
diff --git a/src/script/api/qscriptvalue_p.h b/src/script/api/qscriptvalue_p.h
index c996ed3..d6b76c2 100644
--- a/src/script/api/qscriptvalue_p.h
+++ b/src/script/api/qscriptvalue_p.h
@@ -36,6 +36,7 @@
//
#include <QtCore/qobjectdefs.h>
+#include <QtCore/qshareddata.h>
#include "wtf/Platform.h"
#include "JSValue.h"
@@ -46,7 +47,7 @@ class QString;
class QScriptEnginePrivate;
class QScriptValue;
-class QScriptValuePrivate
+class QScriptValuePrivate : public QSharedData
{
Q_DISABLE_COPY(QScriptValuePrivate)
public:
@@ -118,14 +119,11 @@ public:
// linked list of engine's script values
QScriptValuePrivate *prev;
QScriptValuePrivate *next;
-
- QBasicAtomicInt ref;
};
inline QScriptValuePrivate::QScriptValuePrivate(QScriptEnginePrivate *e)
: engine(e), prev(0), next(0)
{
- ref = 0;
}
inline bool QScriptValuePrivate::isJSC() const
diff --git a/src/script/script.pro b/src/script/script.pro
index 95a9b79..80e9b8a 100644
--- a/src/script/script.pro
+++ b/src/script/script.pro
@@ -15,7 +15,7 @@ DEFINES += QLALR_NO_QSCRIPTGRAMMAR_DEBUG_INFO
unix|win32-g++*:QMAKE_PKGCONFIG_REQUIRES = QtCore
-include($$QT_SOURCE_TREE/src/qbase.pri)
+load(qt_module_config)
HEADERS += qtscriptversion.h
diff --git a/src/scripttools/debugging/qscriptdebuggerconsolecommandgroupdata.cpp b/src/scripttools/debugging/qscriptdebuggerconsolecommandgroupdata.cpp
index 672372e..4d9c041 100644
--- a/src/scripttools/debugging/qscriptdebuggerconsolecommandgroupdata.cpp
+++ b/src/scripttools/debugging/qscriptdebuggerconsolecommandgroupdata.cpp
@@ -42,6 +42,7 @@
#include "qscriptdebuggerconsolecommandgroupdata_p.h"
#include <QtCore/qstring.h>
+#include <QtCore/qshareddata.h>
QT_BEGIN_NAMESPACE
@@ -53,7 +54,7 @@ QT_BEGIN_NAMESPACE
\brief The QScriptDebuggerConsoleCommandGroupData class holds data associated with a console command group.
*/
-class QScriptDebuggerConsoleCommandGroupDataPrivate
+class QScriptDebuggerConsoleCommandGroupDataPrivate : public QSharedData
{
public:
QScriptDebuggerConsoleCommandGroupDataPrivate();
@@ -61,13 +62,10 @@ public:
QString shortDescription;
QString longDescription;
-
- QBasicAtomicInt ref;
};
QScriptDebuggerConsoleCommandGroupDataPrivate::QScriptDebuggerConsoleCommandGroupDataPrivate()
{
- ref = 0;
}
QScriptDebuggerConsoleCommandGroupDataPrivate::~QScriptDebuggerConsoleCommandGroupDataPrivate()
diff --git a/src/scripttools/debugging/qscriptdebuggervalue.cpp b/src/scripttools/debugging/qscriptdebuggervalue.cpp
index 3882070..a19a190 100644
--- a/src/scripttools/debugging/qscriptdebuggervalue.cpp
+++ b/src/scripttools/debugging/qscriptdebuggervalue.cpp
@@ -45,6 +45,7 @@
#include <QtScript/qscriptengine.h>
#include <QtCore/qdatastream.h>
#include <QtCore/qdebug.h>
+#include <QtCore/qshareddata.h>
QT_BEGIN_NAMESPACE
@@ -56,7 +57,7 @@ QT_BEGIN_NAMESPACE
\brief The QScriptDebuggerValue class represents a script value.
*/
-class QScriptDebuggerValuePrivate
+class QScriptDebuggerValuePrivate : public QSharedData
{
public:
QScriptDebuggerValuePrivate();
@@ -69,14 +70,11 @@ public:
double numberValue;
qint64 objectId;
};
-
- QBasicAtomicInt ref;
};
QScriptDebuggerValuePrivate::QScriptDebuggerValuePrivate()
: type(QScriptDebuggerValue::NoValue)
{
- ref = 0;
}
QScriptDebuggerValuePrivate::~QScriptDebuggerValuePrivate()
diff --git a/src/scripttools/debugging/qscriptdebuggervalueproperty.cpp b/src/scripttools/debugging/qscriptdebuggervalueproperty.cpp
index ab8f040..d06f34f 100644
--- a/src/scripttools/debugging/qscriptdebuggervalueproperty.cpp
+++ b/src/scripttools/debugging/qscriptdebuggervalueproperty.cpp
@@ -43,7 +43,7 @@
#include "qscriptdebuggervalue_p.h"
#include "qscriptdebuggerobjectsnapshotdelta_p.h"
-#include <QtCore/qatomic.h>
+#include <QtCore/qshareddata.h>
#include <QtCore/qdatastream.h>
#include <QtCore/qstring.h>
@@ -54,7 +54,7 @@ QT_BEGIN_NAMESPACE
\class QScriptDebuggerValueProperty
*/
-class QScriptDebuggerValuePropertyPrivate
+class QScriptDebuggerValuePropertyPrivate : public QSharedData
{
public:
QScriptDebuggerValuePropertyPrivate();
@@ -64,13 +64,10 @@ public:
QScriptDebuggerValue value;
QString valueAsString;
QScriptValue::PropertyFlags flags;
-
- QBasicAtomicInt ref;
};
QScriptDebuggerValuePropertyPrivate::QScriptDebuggerValuePropertyPrivate()
{
- ref = 0;
}
QScriptDebuggerValuePropertyPrivate::~QScriptDebuggerValuePropertyPrivate()
diff --git a/src/scripttools/debugging/qscriptscriptdata.cpp b/src/scripttools/debugging/qscriptscriptdata.cpp
index f58d754..074c1e5 100644
--- a/src/scripttools/debugging/qscriptscriptdata.cpp
+++ b/src/scripttools/debugging/qscriptscriptdata.cpp
@@ -44,6 +44,7 @@
#include <QtCore/qdatastream.h>
#include <QtCore/qstring.h>
#include <QtCore/qstringlist.h>
+#include <QtCore/qshareddata.h>
QT_BEGIN_NAMESPACE
@@ -55,7 +56,7 @@ QT_BEGIN_NAMESPACE
\brief The QScriptScriptData class holds data associated with a script.
*/
-class QScriptScriptDataPrivate
+class QScriptScriptDataPrivate : public QSharedData
{
public:
QScriptScriptDataPrivate();
@@ -65,13 +66,10 @@ public:
QString fileName;
int baseLineNumber;
QDateTime timeStamp;
-
- QBasicAtomicInt ref;
};
QScriptScriptDataPrivate::QScriptScriptDataPrivate()
{
- ref = 0;
}
QScriptScriptDataPrivate::~QScriptScriptDataPrivate()
diff --git a/src/scripttools/debugging/qscriptvalueproperty.cpp b/src/scripttools/debugging/qscriptvalueproperty.cpp
index 91a59e5..4e16f9c 100644
--- a/src/scripttools/debugging/qscriptvalueproperty.cpp
+++ b/src/scripttools/debugging/qscriptvalueproperty.cpp
@@ -41,12 +41,12 @@
#include "qscriptvalueproperty_p.h"
-#include <QtCore/qatomic.h>
+#include <QtCore/qshareddata.h>
#include <QtCore/qstring.h>
QT_BEGIN_NAMESPACE
-class QScriptValuePropertyPrivate
+class QScriptValuePropertyPrivate : public QSharedData
{
public:
QScriptValuePropertyPrivate();
@@ -55,13 +55,10 @@ public:
QString name;
QScriptValue value;
QScriptValue::PropertyFlags flags;
-
- QBasicAtomicInt ref;
};
QScriptValuePropertyPrivate::QScriptValuePropertyPrivate()
{
- ref = 0;
}
QScriptValuePropertyPrivate::~QScriptValuePropertyPrivate()
diff --git a/src/scripttools/scripttools.pro b/src/scripttools/scripttools.pro
index 9ced50b..4384ed4 100644
--- a/src/scripttools/scripttools.pro
+++ b/src/scripttools/scripttools.pro
@@ -13,7 +13,7 @@ DEFINES += QT_NO_USING_NAMESPACE
unix|win32-g++*:QMAKE_PKGCONFIG_REQUIRES = QtCore QtGui QtScript
-include($$QT_SOURCE_TREE/src/qbase.pri)
+load(qt_module_config)
HEADERS += qtscripttoolsversion.h