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

Side by Side Diff: Source/build/scripts/templates/InternalRuntimeFlags.h.tmpl

Issue 478243002: bindings: Adds virtual ScriptWrappable::wrap method. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Synced. Created 6 years, 3 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 {% from 'macros.tmpl' import license %} 1 {% from 'macros.tmpl' import license %}
2 {{license()}} 2 {{license()}}
3 3
4 #ifndef InternalRuntimeFlags_h 4 #ifndef InternalRuntimeFlags_h
5 #define InternalRuntimeFlags_h 5 #define InternalRuntimeFlags_h
6 6
7 #include "bindings/core/v8/ScriptWrappable.h" 7 #include "bindings/core/v8/ScriptWrappable.h"
8 #include "platform/RuntimeEnabledFeatures.h" 8 #include "platform/RuntimeEnabledFeatures.h"
9 #include "platform/heap/Handle.h" 9 #include "platform/heap/Handle.h"
10 #include "wtf/PassRefPtr.h" 10 #include "wtf/PassRefPtr.h"
11 #include "wtf/RefPtr.h" 11 #include "wtf/RefPtr.h"
12 #include "wtf/RefCounted.h" 12 #include "wtf/RefCounted.h"
13 13
14 namespace blink { 14 namespace blink {
15 15
16 class InternalRuntimeFlags : public RefCountedWillBeGarbageCollected<InternalRun timeFlags>, public ScriptWrappable { 16 class InternalRuntimeFlags : public RefCountedWillBeGarbageCollected<InternalRun timeFlags>, public ScriptWrappable {
17 DEFINE_WRAPPERTYPEINFO();
17 public: 18 public:
18 static PassRefPtrWillBeRawPtr<InternalRuntimeFlags> create() 19 static PassRefPtrWillBeRawPtr<InternalRuntimeFlags> create()
19 { 20 {
20 return adoptRefWillBeNoop(new InternalRuntimeFlags); 21 return adoptRefWillBeNoop(new InternalRuntimeFlags);
21 } 22 }
22 23
23 {# 24 {#
24 Setting after startup does not work for most runtime flags, but we 25 Setting after startup does not work for most runtime flags, but we
25 could add an option to print setters for ones which do: 26 could add an option to print setters for ones which do:
26 void set{{feature.name}}Enabled(bool isEnabled) { RuntimeEnabledFeatures::se t{{feature.name}}Enabled(isEnabled); } 27 void set{{feature.name}}Enabled(bool isEnabled) { RuntimeEnabledFeatures::se t{{feature.name}}Enabled(isEnabled); }
(...skipping 10 matching lines...) Expand all
37 private: 38 private:
38 InternalRuntimeFlags() 39 InternalRuntimeFlags()
39 { 40 {
40 ScriptWrappable::init(this); 41 ScriptWrappable::init(this);
41 } 42 }
42 }; 43 };
43 44
44 } // namespace blink 45 } // namespace blink
45 46
46 #endif // InternalRuntimeFlags_h 47 #endif // InternalRuntimeFlags_h
OLDNEW
« no previous file with comments | « Source/bindings/tests/results/V8TestTypedefs.cpp ('k') | Source/build/scripts/templates/InternalSettingsGenerated.h.tmpl » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698