Title: [117650] trunk/Source/WebCore
Revision
117650
Author
[email protected]
Date
2012-05-18 15:49:33 -0700 (Fri, 18 May 2012)

Log Message

Fix remaining uses of JSValue::toBoolean()
https://bugs.webkit.org/show_bug.cgi?id=86912

Reviewed by Filip Pizlo.

And unbreak Qt build.

* bindings/scripts/test/JS/JSTestEventTarget.cpp:
(WebCore::jsTestEventTargetPrototypeFunctionAddEventListener):
(WebCore::jsTestEventTargetPrototypeFunctionRemoveEventListener):
* bindings/scripts/test/JS/JSTestObj.cpp:
(WebCore::setJSTestObjCreate):
(WebCore::setJSTestObjReflectedBooleanAttr):
(WebCore::setJSTestObjReflectedCustomBooleanAttr):
(WebCore::jsTestObjPrototypeFunctionAddEventListener):
(WebCore::jsTestObjPrototypeFunctionRemoveEventListener):
* bridge/qt/qt_runtime.cpp:
(JSC::Bindings::convertValueToQVariant):
* bridge/qt/qt_runtime_qt4.cpp:
(JSC::Bindings::convertValueToQVariant):

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (117649 => 117650)


--- trunk/Source/WebCore/ChangeLog	2012-05-18 22:48:44 UTC (rev 117649)
+++ trunk/Source/WebCore/ChangeLog	2012-05-18 22:49:33 UTC (rev 117650)
@@ -1,3 +1,26 @@
+2012-05-18  Caio Marcelo de Oliveira Filho  <[email protected]>
+
+        Fix remaining uses of JSValue::toBoolean()
+        https://bugs.webkit.org/show_bug.cgi?id=86912
+
+        Reviewed by Filip Pizlo.
+
+        And unbreak Qt build.
+
+        * bindings/scripts/test/JS/JSTestEventTarget.cpp:
+        (WebCore::jsTestEventTargetPrototypeFunctionAddEventListener):
+        (WebCore::jsTestEventTargetPrototypeFunctionRemoveEventListener):
+        * bindings/scripts/test/JS/JSTestObj.cpp:
+        (WebCore::setJSTestObjCreate):
+        (WebCore::setJSTestObjReflectedBooleanAttr):
+        (WebCore::setJSTestObjReflectedCustomBooleanAttr):
+        (WebCore::jsTestObjPrototypeFunctionAddEventListener):
+        (WebCore::jsTestObjPrototypeFunctionRemoveEventListener):
+        * bridge/qt/qt_runtime.cpp:
+        (JSC::Bindings::convertValueToQVariant):
+        * bridge/qt/qt_runtime_qt4.cpp:
+        (JSC::Bindings::convertValueToQVariant):
+
 2012-04-27  Filip Pizlo  <[email protected]>
 
         DFG should have control flow graph simplification

Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEventTarget.cpp (117649 => 117650)


--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEventTarget.cpp	2012-05-18 22:48:44 UTC (rev 117649)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestEventTarget.cpp	2012-05-18 22:49:33 UTC (rev 117650)
@@ -253,7 +253,7 @@
     JSValue listener = exec->argument(1);
     if (!listener.isObject())
         return JSValue::encode(jsUndefined());
-    impl->addEventListener(ustringToAtomicString(exec->argument(0).toString(exec)->value(exec)), JSEventListener::create(asObject(listener), castedThis, false, currentWorld(exec)), exec->argument(2).toBoolean(exec));
+    impl->addEventListener(ustringToAtomicString(exec->argument(0).toString(exec)->value(exec)), JSEventListener::create(asObject(listener), castedThis, false, currentWorld(exec)), exec->argument(2).toBoolean());
     return JSValue::encode(jsUndefined());
 }
 
@@ -268,7 +268,7 @@
     JSValue listener = exec->argument(1);
     if (!listener.isObject())
         return JSValue::encode(jsUndefined());
-    impl->removeEventListener(ustringToAtomicString(exec->argument(0).toString(exec)->value(exec)), JSEventListener::create(asObject(listener), castedThis, false, currentWorld(exec)).get(), exec->argument(2).toBoolean(exec));
+    impl->removeEventListener(ustringToAtomicString(exec->argument(0).toString(exec)->value(exec)), JSEventListener::create(asObject(listener), castedThis, false, currentWorld(exec)).get(), exec->argument(2).toBoolean());
     return JSValue::encode(jsUndefined());
 }
 

Modified: trunk/Source/WebCore/bindings/scripts/test/JS/JSTestObj.cpp (117649 => 117650)


--- trunk/Source/WebCore/bindings/scripts/test/JS/JSTestObj.cpp	2012-05-18 22:48:44 UTC (rev 117649)
+++ trunk/Source/WebCore/bindings/scripts/test/JS/JSTestObj.cpp	2012-05-18 22:49:33 UTC (rev 117650)
@@ -1246,7 +1246,7 @@
 {
     JSTestObj* castedThis = jsCast<JSTestObj*>(thisObject);
     TestObj* impl = static_cast<TestObj*>(castedThis->impl());
-    impl->setCreate(value.toBoolean(exec));
+    impl->setCreate(value.toBoolean());
 }
 
 
@@ -1278,7 +1278,7 @@
 {
     JSTestObj* castedThis = jsCast<JSTestObj*>(thisObject);
     TestObj* impl = static_cast<TestObj*>(castedThis->impl());
-    impl->setBooleanAttribute(WebCore::HTMLNames::reflectedbooleanattrAttr, value.toBoolean(exec));
+    impl->setBooleanAttribute(WebCore::HTMLNames::reflectedbooleanattrAttr, value.toBoolean());
 }
 
 
@@ -1310,7 +1310,7 @@
 {
     JSTestObj* castedThis = jsCast<JSTestObj*>(thisObject);
     TestObj* impl = static_cast<TestObj*>(castedThis->impl());
-    impl->setBooleanAttribute(WebCore::HTMLNames::customContentBooleanAttrAttr, value.toBoolean(exec));
+    impl->setBooleanAttribute(WebCore::HTMLNames::customContentBooleanAttrAttr, value.toBoolean());
 }
 
 
@@ -1829,7 +1829,7 @@
     JSValue listener = exec->argument(1);
     if (!listener.isObject())
         return JSValue::encode(jsUndefined());
-    impl->addEventListener(ustringToAtomicString(exec->argument(0).toString(exec)->value(exec)), JSEventListener::create(asObject(listener), castedThis, false, currentWorld(exec)), exec->argument(2).toBoolean(exec));
+    impl->addEventListener(ustringToAtomicString(exec->argument(0).toString(exec)->value(exec)), JSEventListener::create(asObject(listener), castedThis, false, currentWorld(exec)), exec->argument(2).toBoolean());
     return JSValue::encode(jsUndefined());
 }
 
@@ -1844,7 +1844,7 @@
     JSValue listener = exec->argument(1);
     if (!listener.isObject())
         return JSValue::encode(jsUndefined());
-    impl->removeEventListener(ustringToAtomicString(exec->argument(0).toString(exec)->value(exec)), JSEventListener::create(asObject(listener), castedThis, false, currentWorld(exec)).get(), exec->argument(2).toBoolean(exec));
+    impl->removeEventListener(ustringToAtomicString(exec->argument(0).toString(exec)->value(exec)), JSEventListener::create(asObject(listener), castedThis, false, currentWorld(exec)).get(), exec->argument(2).toBoolean());
     return JSValue::encode(jsUndefined());
 }
 

Modified: trunk/Source/WebCore/bridge/qt/qt_runtime.cpp (117649 => 117650)


--- trunk/Source/WebCore/bridge/qt/qt_runtime.cpp	2012-05-18 22:48:44 UTC (rev 117649)
+++ trunk/Source/WebCore/bridge/qt/qt_runtime.cpp	2012-05-18 22:49:33 UTC (rev 117650)
@@ -287,9 +287,9 @@
     switch (hint) {
         case QMetaType::Bool:
             if (type == Object && object->inherits(&BooleanObject::s_info))
-                ret = QVariant(asBooleanObject(value)->internalValue().toBoolean(exec));
+                ret = QVariant(asBooleanObject(value)->internalValue().toBoolean());
             else
-                ret = QVariant(value.toBoolean(exec));
+                ret = QVariant(value.toBoolean());
             if (type == Boolean)
                 dist = 0;
             else

Modified: trunk/Source/WebCore/bridge/qt/qt_runtime_qt4.cpp (117649 => 117650)


--- trunk/Source/WebCore/bridge/qt/qt_runtime_qt4.cpp	2012-05-18 22:48:44 UTC (rev 117649)
+++ trunk/Source/WebCore/bridge/qt/qt_runtime_qt4.cpp	2012-05-18 22:49:33 UTC (rev 117650)
@@ -287,9 +287,9 @@
     switch (hint) {
         case QMetaType::Bool:
             if (type == Object && object->inherits(&BooleanObject::s_info))
-                ret = QVariant(asBooleanObject(value)->internalValue().toBoolean(exec));
+                ret = QVariant(asBooleanObject(value)->internalValue().toBoolean());
             else
-                ret = QVariant(value.toBoolean(exec));
+                ret = QVariant(value.toBoolean());
             if (type == Boolean)
                 dist = 0;
             else
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to