Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(193)

Unified Diff: third_party/WebKit/Source/bindings/core/v8/ScriptWrappable.h

Issue 2808403007: Remove ScriptWrappable::FromNode (Closed)
Patch Set: Rebase Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | third_party/WebKit/Source/bindings/core/v8/V8BindingForCore.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/bindings/core/v8/ScriptWrappable.h
diff --git a/third_party/WebKit/Source/bindings/core/v8/ScriptWrappable.h b/third_party/WebKit/Source/bindings/core/v8/ScriptWrappable.h
index 66e7deaf68b67db8dfeb46cd23081e3cd0c060e9..420ce172c38f2e476ac58e4d63af9bc1bfe4241e 100644
--- a/third_party/WebKit/Source/bindings/core/v8/ScriptWrappable.h
+++ b/third_party/WebKit/Source/bindings/core/v8/ScriptWrappable.h
@@ -142,23 +142,6 @@ class CORE_EXPORT ScriptWrappable : public TraceWrapperBase {
return main_world_wrapper_ == other;
}
- // Provides a way to convert Node* to ScriptWrappable* without including
- // "core/dom/Node.h".
- //
- // Example:
- // void foo(const void*) { ... } // [1]
- // void foo(ScriptWrappable*) { ... } // [2]
- // class Node;
- // Node* node;
- // foo(node); // This calls [1] because there is no definition of Node
- // // and compilers do not know that Node is a subclass of
- // // ScriptWrappable.
- // foo(ScriptWrappable::fromNode(node)); // This calls [2] as expected.
- //
- // The definition of fromNode is placed in Node.h because we'd like to
- // inline calls to fromNode as much as possible.
- static ScriptWrappable* FromNode(Node*);
-
bool SetReturnValue(v8::ReturnValue<v8::Value> return_value) {
return_value.Set(main_world_wrapper_);
return ContainsWrapper();
« no previous file with comments | « no previous file | third_party/WebKit/Source/bindings/core/v8/V8BindingForCore.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698