summaryrefslogtreecommitdiffstats
path: root/Source/WebCore/bridge/qt/qt_runtime.cpp
diff options
context:
space:
mode:
authorMarius Storm-Olsen <marius.storm-olsen@nokia.com>2012-08-20 11:15:48 -0400
committerMarius Storm-Olsen <marius.storm-olsen@nokia.com>2012-08-20 11:24:06 -0400
commitdecad929f578d8db641febc8740649ca6c574638 (patch)
treef8ba3379fd3fce512a40efee7a187e0f98b9eb7f /Source/WebCore/bridge/qt/qt_runtime.cpp
parent3749d61e1f7a59f5ec5067e560af1eb610c82015 (diff)
Remove the use of QWidgetStar
We can now properly convert any QObject-derived object to the QObject*, so we don't need to use the QWidgetStar.
Diffstat (limited to 'Source/WebCore/bridge/qt/qt_runtime.cpp')
-rw-r--r--Source/WebCore/bridge/qt/qt_runtime.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/Source/WebCore/bridge/qt/qt_runtime.cpp b/Source/WebCore/bridge/qt/qt_runtime.cpp
index 951a7598e..0f47643d8 100644
--- a/Source/WebCore/bridge/qt/qt_runtime.cpp
+++ b/Source/WebCore/bridge/qt/qt_runtime.cpp
@@ -785,7 +785,6 @@ JSValue convertQVariantToValue(ExecState* exec, PassRefPtr<RootObject> root, con
if (variant.isNull() &&
type != QMetaType::QObjectStar &&
type != QMetaType::VoidStar &&
- type != QMetaType::QWidgetStar &&
type != QMetaType::QString) {
return jsNull();
}
@@ -845,7 +844,7 @@ JSValue convertQVariantToValue(ExecState* exec, PassRefPtr<RootObject> root, con
return toJS(exec, static_cast<JSDOMGlobalObject*>(exec->lexicalGlobalObject()), wtfByteArray.get());
}
- if (type == QMetaType::QObjectStar || type == QMetaType::QWidgetStar) {
+ if (type == QMetaType::QObjectStar || variant.canConvert<QObject*>()) {
QObject* obj = variant.value<QObject*>();
if (!obj)
return jsNull();