OLD | NEW |
1 {# http://www.chromium.org/blink/coding-style#TOC-License #} | 1 {# http://www.chromium.org/blink/coding-style#TOC-License #} |
2 /* | 2 /* |
3 * Copyright (C) 2013 Google Inc. All rights reserved. | 3 * Copyright (C) 2013 Google Inc. All rights reserved. |
4 * | 4 * |
5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
6 * modification, are permitted provided that the following conditions are | 6 * modification, are permitted provided that the following conditions are |
7 * met: | 7 * met: |
8 * | 8 * |
9 * * Redistributions of source code must retain the above copyright | 9 * * Redistributions of source code must retain the above copyright |
10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
(...skipping 26 matching lines...) Expand all Loading... |
37 | 37 |
38 {% filter conditional(conditional_string) %} | 38 {% filter conditional(conditional_string) %} |
39 {% for filename in header_includes %} | 39 {% for filename in header_includes %} |
40 #include "{{filename}}" | 40 #include "{{filename}}" |
41 {% endfor %} | 41 {% endfor %} |
42 | 42 |
43 namespace WebCore { | 43 namespace WebCore { |
44 | 44 |
45 class ExecutionContext; | 45 class ExecutionContext; |
46 | 46 |
47 class {{v8_class}} : public {{cpp_class}}, public ActiveDOMCallback { | 47 class {{v8_class}} FINAL : public {{cpp_class}}, public ActiveDOMCallback { |
48 public: | 48 public: |
49 static PassOwnPtr<{{v8_class}}> create(v8::Handle<v8::Function> callback, Ex
ecutionContext* context) | 49 static PassOwnPtr<{{v8_class}}> create(v8::Handle<v8::Function> callback, Ex
ecutionContext* context) |
50 { | 50 { |
51 ASSERT(context); | 51 ASSERT(context); |
52 return adoptPtr(new {{v8_class}}(callback, context)); | 52 return adoptPtr(new {{v8_class}}(callback, context)); |
53 } | 53 } |
54 | 54 |
55 virtual ~{{v8_class}}(); | 55 virtual ~{{v8_class}}(); |
56 | 56 |
57 {% for method in methods %} | 57 {% for method in methods %} |
58 virtual {{method.return_cpp_type}} {{method.name}}({{method.argument_declara
tions | join(', ')}}); | 58 virtual {{method.return_cpp_type}} {{method.name}}({{method.argument_declara
tions | join(', ')}}) OVERRIDE; |
59 {% endfor %} | 59 {% endfor %} |
60 private: | 60 private: |
61 {{v8_class}}(v8::Handle<v8::Function>, ExecutionContext*); | 61 {{v8_class}}(v8::Handle<v8::Function>, ExecutionContext*); |
62 | 62 |
63 ScopedPersistent<v8::Function> m_callback; | 63 ScopedPersistent<v8::Function> m_callback; |
64 RefPtr<DOMWrapperWorld> m_world; | 64 RefPtr<DOMWrapperWorld> m_world; |
65 }; | 65 }; |
66 | 66 |
67 } | 67 } |
68 {% endfilter %} | 68 {% endfilter %} |
69 #endif // {{v8_class}}_h | 69 #endif // {{v8_class}}_h |
OLD | NEW |