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

Side by Side Diff: Source/bindings/v8/V8HiddenPropertyName.h

Issue 16708002: Simplify Custom Element constructors to be functions, not wrappers (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebased Created 7 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2012 Google Inc. All rights reserved. 2 * Copyright (C) 2012 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 18 matching lines...) Expand all
29 */ 29 */
30 30
31 #ifndef V8HiddenPropertyName_h 31 #ifndef V8HiddenPropertyName_h
32 #define V8HiddenPropertyName_h 32 #define V8HiddenPropertyName_h
33 33
34 #include <v8.h> 34 #include <v8.h>
35 35
36 namespace WebCore { 36 namespace WebCore {
37 37
38 #define V8_HIDDEN_PROPERTIES(V) \ 38 #define V8_HIDDEN_PROPERTIES(V) \
39 V(adaptorFunctionPeer) \
39 V(attributeListener) \ 40 V(attributeListener) \
40 V(callback) \ 41 V(callback) \
41 V(detail) \ 42 V(detail) \
42 V(document) \ 43 V(document) \
43 V(event) \ 44 V(event) \
44 V(listener) \ 45 V(listener) \
46 V(name) \
47 V(namespaceURI) \
45 V(scriptState) \ 48 V(scriptState) \
46 V(sleepFunction) \ 49 V(sleepFunction) \
47 V(state) \ 50 V(state) \
48 V(adaptorFunctionPeer) \
49 V(toStringString) \ 51 V(toStringString) \
52 V(type) \
50 V(typedArrayHiddenCopyMethod) 53 V(typedArrayHiddenCopyMethod)
51 54
52 class V8HiddenPropertyName { 55 class V8HiddenPropertyName {
53 public: 56 public:
54 V8HiddenPropertyName() { } 57 V8HiddenPropertyName() { }
55 #define V8_DECLARE_PROPERTY(name) static v8::Handle<v8::String> name(); 58 #define V8_DECLARE_PROPERTY(name) static v8::Handle<v8::String> name();
56 V8_HIDDEN_PROPERTIES(V8_DECLARE_PROPERTY); 59 V8_HIDDEN_PROPERTIES(V8_DECLARE_PROPERTY);
57 #undef V8_DECLARE_PROPERTY 60 #undef V8_DECLARE_PROPERTY
58 61
59 static void setNamedHiddenReference(v8::Handle<v8::Object> parent, const cha r* name, v8::Handle<v8::Value> child); 62 static void setNamedHiddenReference(v8::Handle<v8::Object> parent, const cha r* name, v8::Handle<v8::Value> child);
60 63
61 private: 64 private:
62 static void createString(const char* key, v8::Persistent<v8::String>* handle ); 65 static void createString(const char* key, v8::Persistent<v8::String>* handle );
63 #define V8_DECLARE_FIELD(name) v8::Persistent<v8::String> m_##name; 66 #define V8_DECLARE_FIELD(name) v8::Persistent<v8::String> m_##name;
64 V8_HIDDEN_PROPERTIES(V8_DECLARE_FIELD); 67 V8_HIDDEN_PROPERTIES(V8_DECLARE_FIELD);
65 #undef V8_DECLARE_FIELD 68 #undef V8_DECLARE_FIELD
66 }; 69 };
67 70
68 } 71 }
69 72
70 #endif // V8HiddenPropertyName_h 73 #endif // V8HiddenPropertyName_h
OLDNEW
« no previous file with comments | « Source/bindings/v8/V8DOMWrapper.cpp ('k') | Source/bindings/v8/custom/V8CustomElementConstructorCustom.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698