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

Unified Diff: Source/core/dom/Node.h

Issue 327633004: Apply DEFINE/DECLARE_NODE_FACTORY(T) macro to element factories with single Document& argument. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 6 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 | Source/core/html/HTMLAreaElement.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/dom/Node.h
diff --git a/Source/core/dom/Node.h b/Source/core/dom/Node.h
index 03df9b855ae706d4d4cf1e5345eddc3c5955ccdb..a198eef92d504a6b29f220594101678ec1d4ee7f 100644
--- a/Source/core/dom/Node.h
+++ b/Source/core/dom/Node.h
@@ -898,11 +898,13 @@ DEFINE_COMPARISON_OPERATORS_WITH_REFERENCES_REFCOUNTED(Node)
template<typename T> inline thisType* to##thisType(const RefPtr<T>& node) { return to##thisType(node.get()); } \
DEFINE_TYPE_CASTS(thisType, Node, node, is##thisType(*node), is##thisType(node))
+#define DECLARE_NODE_FACTORY(T) \
+ static PassRefPtrWillBeRawPtr<T> create(Document&)
#define DEFINE_NODE_FACTORY(T) \
- inline static PassRefPtrWillBeRawPtr<T> create(Document& document) \
- { \
- return adoptRefWillBeRefCountedGarbageCollected(new T(document)); \
- }
+PassRefPtrWillBeRawPtr<T> T::create(Document& document) \
+{ \
+ return adoptRefWillBeRefCountedGarbageCollected(new T(document)); \
+}
} // namespace WebCore
« no previous file with comments | « no previous file | Source/core/html/HTMLAreaElement.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698