summaryrefslogtreecommitdiffstats
path: root/src/script/api
diff options
context:
space:
mode:
authorKent Hansen <kent.hansen@nokia.com>2010-03-10 11:27:32 (GMT)
committerKent Hansen <kent.hansen@nokia.com>2010-03-10 16:21:29 (GMT)
commit480ddc554870f261578982bd6bf7070a7477b862 (patch)
treed24fa63a08b344da8cb8a550a85bf17891fc9e3e /src/script/api
parent36dd6c9aea86da5cbba73669116e9d2aa49eac2b (diff)
downloadQt-480ddc554870f261578982bd6bf7070a7477b862.zip
Qt-480ddc554870f261578982bd6bf7070a7477b862.tar.gz
Qt-480ddc554870f261578982bd6bf7070a7477b862.tar.bz2
Add default argument values for QScriptValuePrivate property functions
Make them mirror the defaults of the public API, so that the QScriptValuePrivate property functions can be used internally in the same manner as the public API. Reviewed-by: Jedrzej Nowacki
Diffstat (limited to 'src/script/api')
-rw-r--r--src/script/api/qscriptengine_p.h6
-rw-r--r--src/script/api/qscriptvalue_p.h15
2 files changed, 11 insertions, 10 deletions
diff --git a/src/script/api/qscriptengine_p.h b/src/script/api/qscriptengine_p.h
index 63457af..47e5d8a 100644
--- a/src/script/api/qscriptengine_p.h
+++ b/src/script/api/qscriptengine_p.h
@@ -703,17 +703,17 @@ inline void QScriptEnginePrivate::setProperty(JSC::ExecState *exec, JSC::JSValue
setProperty(exec, objectValue, JSC::Identifier(exec, name), value, flags);
}
-inline JSC::JSValue QScriptValuePrivate::property(const JSC::Identifier &id, int resolveMode) const
+inline JSC::JSValue QScriptValuePrivate::property(const JSC::Identifier &id, const QScriptValue::ResolveFlags &resolveMode) const
{
return QScriptEnginePrivate::property(engine->currentFrame, jscValue, id, resolveMode);
}
-inline JSC::JSValue QScriptValuePrivate::property(quint32 index, int resolveMode) const
+inline JSC::JSValue QScriptValuePrivate::property(quint32 index, const QScriptValue::ResolveFlags &resolveMode) const
{
return QScriptEnginePrivate::property(engine->currentFrame, jscValue, index, resolveMode);
}
-inline JSC::JSValue QScriptValuePrivate::property(const JSC::UString &name, int resolveMode) const
+inline JSC::JSValue QScriptValuePrivate::property(const JSC::UString &name, const QScriptValue::ResolveFlags &resolveMode) const
{
JSC::ExecState *exec = engine->currentFrame;
return QScriptEnginePrivate::property(exec, jscValue, JSC::Identifier(exec, name), resolveMode);
diff --git a/src/script/api/qscriptvalue_p.h b/src/script/api/qscriptvalue_p.h
index 089b923..853c6c8 100644
--- a/src/script/api/qscriptvalue_p.h
+++ b/src/script/api/qscriptvalue_p.h
@@ -86,17 +86,18 @@ public:
return q.d_ptr->engine;
}
- inline JSC::JSValue property(const JSC::Identifier &id, int resolveMode) const;
- inline JSC::JSValue property(quint32 index, int resolveMode) const;
- inline JSC::JSValue property(const JSC::UString &, int resolveMode) const;
+ inline JSC::JSValue property(const JSC::Identifier &id,
+ const QScriptValue::ResolveFlags &mode = QScriptValue::ResolvePrototype) const;
+ inline JSC::JSValue property(quint32 index, const QScriptValue::ResolveFlags &mode = QScriptValue::ResolvePrototype) const;
+ inline JSC::JSValue property(const JSC::UString &, const QScriptValue::ResolveFlags &mode = QScriptValue::ResolvePrototype) const;
inline void setProperty(const JSC::UString &name, const JSC::JSValue &value,
- const QScriptValue::PropertyFlags &flags);
+ const QScriptValue::PropertyFlags &flags = QScriptValue::KeepExistingFlags);
inline void setProperty(const JSC::Identifier &id, const JSC::JSValue &value,
- const QScriptValue::PropertyFlags &flags);
+ const QScriptValue::PropertyFlags &flags = QScriptValue::KeepExistingFlags);
inline void setProperty(quint32 index, const JSC::JSValue &value,
- const QScriptValue::PropertyFlags &flags);
+ const QScriptValue::PropertyFlags &flags = QScriptValue::KeepExistingFlags);
inline QScriptValue::PropertyFlags propertyFlags(
- const JSC::Identifier &id, const QScriptValue::ResolveFlags &mode) const;
+ const JSC::Identifier &id, const QScriptValue::ResolveFlags &mode = QScriptValue::ResolvePrototype) const;
void detachFromEngine();