Title: [141948] trunk/Source/WebCore
Revision
141948
Author
[email protected]
Date
2013-02-05 16:28:34 -0800 (Tue, 05 Feb 2013)

Log Message

[V8] Remove deprecatedV8String() and deprecatedV8Integer()
https://bugs.webkit.org/show_bug.cgi?id=108919

Reviewed by Adam Barth.

No tests. No change in behavior.

* bindings/v8/V8Binding.cpp:
(WebCore::toXPathNSResolver):
* bindings/v8/V8Binding.h:
* bindings/v8/custom/V8CustomXPathNSResolver.cpp:
(WebCore::V8CustomXPathNSResolver::create):
(WebCore::V8CustomXPathNSResolver::V8CustomXPathNSResolver):
(WebCore::V8CustomXPathNSResolver::lookupNamespaceURI):
* bindings/v8/custom/V8CustomXPathNSResolver.h:
(V8CustomXPathNSResolver):

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (141947 => 141948)


--- trunk/Source/WebCore/ChangeLog	2013-02-06 00:05:31 UTC (rev 141947)
+++ trunk/Source/WebCore/ChangeLog	2013-02-06 00:28:34 UTC (rev 141948)
@@ -1,3 +1,22 @@
+2013-02-05  Kentaro Hara  <[email protected]>
+
+        [V8] Remove deprecatedV8String() and deprecatedV8Integer()
+        https://bugs.webkit.org/show_bug.cgi?id=108919
+
+        Reviewed by Adam Barth.
+
+        No tests. No change in behavior.
+
+        * bindings/v8/V8Binding.cpp:
+        (WebCore::toXPathNSResolver):
+        * bindings/v8/V8Binding.h:
+        * bindings/v8/custom/V8CustomXPathNSResolver.cpp:
+        (WebCore::V8CustomXPathNSResolver::create):
+        (WebCore::V8CustomXPathNSResolver::V8CustomXPathNSResolver):
+        (WebCore::V8CustomXPathNSResolver::lookupNamespaceURI):
+        * bindings/v8/custom/V8CustomXPathNSResolver.h:
+        (V8CustomXPathNSResolver):
+
 2013-02-05   Vineet Chaudhary  <[email protected]>
 
         formenctype to have empty string as default value.

Modified: trunk/Source/WebCore/bindings/v8/V8Binding.cpp (141947 => 141948)


--- trunk/Source/WebCore/bindings/v8/V8Binding.cpp	2013-02-06 00:05:31 UTC (rev 141947)
+++ trunk/Source/WebCore/bindings/v8/V8Binding.cpp	2013-02-06 00:28:34 UTC (rev 141948)
@@ -208,7 +208,7 @@
     if (V8XPathNSResolver::HasInstance(value, isolate))
         resolver = V8XPathNSResolver::toNative(v8::Handle<v8::Object>::Cast(value));
     else if (value->IsObject())
-        resolver = V8CustomXPathNSResolver::create(value->ToObject());
+        resolver = V8CustomXPathNSResolver::create(value->ToObject(), isolate);
     return resolver;
 }
 

Modified: trunk/Source/WebCore/bindings/v8/V8Binding.h (141947 => 141948)


--- trunk/Source/WebCore/bindings/v8/V8Binding.h	2013-02-06 00:05:31 UTC (rev 141947)
+++ trunk/Source/WebCore/bindings/v8/V8Binding.h	2013-02-06 00:28:34 UTC (rev 141948)
@@ -152,12 +152,6 @@
         return V8PerIsolateData::from(isolate)->stringCache()->v8ExternalString(string.impl(), handleType, isolate);
     }
 
-    // FIXME: All call sites of this method should use v8String().
-    inline v8::Handle<v8::String> deprecatedV8String(const String& string)
-    {
-        return v8String(string, v8::Isolate::GetCurrent());
-    }
-
     inline v8::Handle<v8::Value> v8StringOrNull(const String& string, v8::Isolate* isolate, ReturnHandleType handleType = ReturnLocalHandle)
     {
         ASSERT(isolate);
@@ -179,12 +173,6 @@
         return V8PerIsolateData::from(isolate)->integerCache()->v8Integer(value, isolate);
     }
 
-    // FIXME: All call sites of this method should use v8Integer().
-    inline v8::Handle<v8::Integer> deprecatedV8Integer(int value)
-    {
-        return v8Integer(value, v8::Isolate::GetCurrent());
-    }
-
     inline v8::Handle<v8::Integer> v8UnsignedInteger(unsigned value, v8::Isolate* isolate)
     {
         ASSERT(isolate);

Modified: trunk/Source/WebCore/bindings/v8/custom/V8CustomXPathNSResolver.cpp (141947 => 141948)


--- trunk/Source/WebCore/bindings/v8/custom/V8CustomXPathNSResolver.cpp	2013-02-06 00:05:31 UTC (rev 141947)
+++ trunk/Source/WebCore/bindings/v8/custom/V8CustomXPathNSResolver.cpp	2013-02-06 00:28:34 UTC (rev 141948)
@@ -41,13 +41,14 @@
 
 namespace WebCore {
 
-PassRefPtr<V8CustomXPathNSResolver> V8CustomXPathNSResolver::create(v8::Handle<v8::Object> resolver)
+PassRefPtr<V8CustomXPathNSResolver> V8CustomXPathNSResolver::create(v8::Handle<v8::Object> resolver, v8::Isolate* isolate)
 {
-    return adoptRef(new V8CustomXPathNSResolver(resolver));
+    return adoptRef(new V8CustomXPathNSResolver(resolver, isolate));
 }
 
-V8CustomXPathNSResolver::V8CustomXPathNSResolver(v8::Handle<v8::Object> resolver)
+V8CustomXPathNSResolver::V8CustomXPathNSResolver(v8::Handle<v8::Object> resolver, v8::Isolate* isolate)
     : m_resolver(resolver)
+    , m_isolate(isolate)
 {
 }
 
@@ -77,7 +78,7 @@
     tryCatch.SetVerbose(true); // Print exceptions to console.
 
     const int argc = 1;
-    v8::Handle<v8::Value> argv[argc] = { deprecatedV8String(prefix) };
+    v8::Handle<v8::Value> argv[argc] = { v8String(prefix, m_isolate) };
     v8::Handle<v8::Function> function = lookupNamespaceURIFunc.IsEmpty() ? v8::Handle<v8::Function>::Cast(m_resolver) : lookupNamespaceURIFunc;
 
     v8::Handle<v8::Value> retval = ScriptController::callFunctionWithInstrumentation(0, function, m_resolver, argc, argv);

Modified: trunk/Source/WebCore/bindings/v8/custom/V8CustomXPathNSResolver.h (141947 => 141948)


--- trunk/Source/WebCore/bindings/v8/custom/V8CustomXPathNSResolver.h	2013-02-06 00:05:31 UTC (rev 141947)
+++ trunk/Source/WebCore/bindings/v8/custom/V8CustomXPathNSResolver.h	2013-02-06 00:28:34 UTC (rev 141948)
@@ -44,15 +44,16 @@
 // must not exceed the lifetime of the passed handle.
 class V8CustomXPathNSResolver : public XPathNSResolver {
 public:
-    static PassRefPtr<V8CustomXPathNSResolver> create(v8::Handle<v8::Object> resolver);
+    static PassRefPtr<V8CustomXPathNSResolver> create(v8::Handle<v8::Object> resolver, v8::Isolate*);
 
     virtual ~V8CustomXPathNSResolver();
     virtual String lookupNamespaceURI(const String& prefix);
 
 private:
-    explicit V8CustomXPathNSResolver(v8::Handle<v8::Object> resolver);
+    V8CustomXPathNSResolver(v8::Handle<v8::Object> resolver, v8::Isolate*);
 
     v8::Handle<v8::Object> m_resolver;  // Handle to resolver object.
+    v8::Isolate* m_isolate;
 };
 
 } // namespace WebCore
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to