aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/qml/qqmlengine_p.h
diff options
context:
space:
mode:
authorOswald Buddenhagen <oswald.buddenhagen@digia.com>2014-01-15 22:01:15 +0100
committerThe Qt Project <gerrit-noreply@qt-project.org>2014-01-22 21:01:53 +0100
commite2ea0a83cc876fb54a2a8bf6f1350dbfa52f596b (patch)
tree36ec4b74aa50b9355e74e5d186039c3cdbd38acd /src/qml/qml/qqmlengine_p.h
parent2ce7959eb9e69cd68013fc6a0f77a9556a84365b (diff)
fix whitespace
remove trailing spaces and expand tabs Change-Id: Ieacb9d096b612c45d1a64700044c114d1f7522bc Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Diffstat (limited to 'src/qml/qml/qqmlengine_p.h')
-rw-r--r--src/qml/qml/qqmlengine_p.h50
1 files changed, 25 insertions, 25 deletions
diff --git a/src/qml/qml/qqmlengine_p.h b/src/qml/qml/qqmlengine_p.h
index 19eb320fbe..e292dbf6c0 100644
--- a/src/qml/qml/qqmlengine_p.h
+++ b/src/qml/qml/qqmlengine_p.h
@@ -271,16 +271,16 @@ public:
mutable QMutex mutex;
private:
- // Locker locks the QQmlEnginePrivate data structures for read and write, if necessary.
- // Currently, locking is only necessary if the threaded loader is running concurrently. If it is
+ // Locker locks the QQmlEnginePrivate data structures for read and write, if necessary.
+ // Currently, locking is only necessary if the threaded loader is running concurrently. If it is
// either idle, or is running with the main thread blocked, no locking is necessary. This way
// we only pay for locking when we have to.
- // Consequently, this class should only be used to protect simple accesses or modifications of the
+ // Consequently, this class should only be used to protect simple accesses or modifications of the
// QQmlEnginePrivate structures or operations that can be guaranteed not to start activity
// on the loader thread.
- // The Locker API is identical to QMutexLocker. Locker reuses the QQmlEnginePrivate::mutex
+ // The Locker API is identical to QMutexLocker. Locker reuses the QQmlEnginePrivate::mutex
// QMutex instance and multiple Lockers are recursive in the same thread.
- class Locker
+ class Locker
{
public:
inline Locker(const QQmlEngine *);
@@ -333,7 +333,7 @@ QQmlEnginePrivate::Locker::~Locker()
void QQmlEnginePrivate::Locker::unlock()
{
- if (m_locked) {
+ if (m_locked) {
m_ep->mutex.unlock();
m_locked = false;
}
@@ -373,7 +373,7 @@ thread, \a value will be deleted immediately.
This method should be used for *any* type that has resources that need to
be freed in the engine thread. This is generally types that use V8 handles.
As there is some small overhead in checking the current thread, it is best
-practice to check if any V8 handles actually need to be freed and delete
+practice to check if any V8 handles actually need to be freed and delete
the instance directly if not.
*/
template<typename T>
@@ -384,7 +384,7 @@ void QQmlEnginePrivate::deleteInEngineThread(T *value)
Q_ASSERT(value);
if (isEngineThread()) {
delete value;
- } else {
+ } else {
struct I : public Deletable {
I(T *value) : value(value) {}
~I() { delete value; }
@@ -420,10 +420,10 @@ is returned.
The returned cache is not referenced, so if it is to be stored, call addref().
XXX thread There is a potential future race condition in this and all the cache()
-functions. As the QQmlPropertyCache is returned unreferenced, when called
-from the loader thread, it is possible that the cache will have been dereferenced
+functions. As the QQmlPropertyCache is returned unreferenced, when called
+from the loader thread, it is possible that the cache will have been dereferenced
and deleted before the loader thread has a chance to use or reference it. This
-can't currently happen as the cache holds a reference to the
+can't currently happen as the cache holds a reference to the
QQmlPropertyCache until the QQmlEngine is destroyed.
*/
QQmlPropertyCache *QQmlEnginePrivate::cache(QObject *obj)
@@ -475,8 +475,8 @@ QQmlPropertyCache *QQmlEnginePrivate::cache(QQmlType *type, int minorVersion, QQ
return rv;
}
-QV8Engine *QQmlEnginePrivate::getV8Engine(QQmlEngine *e)
-{
+QV8Engine *QQmlEnginePrivate::getV8Engine(QQmlEngine *e)
+{
Q_ASSERT(e);
return e->d_func()->v8engine();
@@ -489,32 +489,32 @@ QV4::ExecutionEngine *QQmlEnginePrivate::getV4Engine(QQmlEngine *e)
return e->d_func()->v4engine();
}
-QQmlEnginePrivate *QQmlEnginePrivate::get(QQmlEngine *e)
-{
+QQmlEnginePrivate *QQmlEnginePrivate::get(QQmlEngine *e)
+{
Q_ASSERT(e);
return e->d_func();
}
-const QQmlEnginePrivate *QQmlEnginePrivate::get(const QQmlEngine *e)
-{
+const QQmlEnginePrivate *QQmlEnginePrivate::get(const QQmlEngine *e)
+{
Q_ASSERT(e);
return e->d_func();
}
-QQmlEnginePrivate *QQmlEnginePrivate::get(QQmlContext *c)
-{
- return (c && c->engine()) ? QQmlEnginePrivate::get(c->engine()) : 0;
+QQmlEnginePrivate *QQmlEnginePrivate::get(QQmlContext *c)
+{
+ return (c && c->engine()) ? QQmlEnginePrivate::get(c->engine()) : 0;
}
-QQmlEnginePrivate *QQmlEnginePrivate::get(QQmlContextData *c)
-{
- return (c && c->engine) ? QQmlEnginePrivate::get(c->engine) : 0;
+QQmlEnginePrivate *QQmlEnginePrivate::get(QQmlContextData *c)
+{
+ return (c && c->engine) ? QQmlEnginePrivate::get(c->engine) : 0;
}
-QQmlEngine *QQmlEnginePrivate::get(QQmlEnginePrivate *p)
-{
+QQmlEngine *QQmlEnginePrivate::get(QQmlEnginePrivate *p)
+{
Q_ASSERT(p);
return p->q_func();