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

Side by Side Diff: Source/bindings/core/v8/V8AbstractEventListener.h

Issue 1263953002: Eagerly finalize V8AbstractEventListeners. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 4 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2006, 2007, 2008, 2009 Google Inc. All rights reserved. 2 * Copyright (C) 2006, 2007, 2008, 2009 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 94 matching lines...) Expand 10 before | Expand all | Expand 10 after
105 105
106 void clearListenerObject() 106 void clearListenerObject()
107 { 107 {
108 m_listener.clear(); 108 m_listener.clear();
109 } 109 }
110 110
111 bool belongsToTheCurrentWorld() const final; 111 bool belongsToTheCurrentWorld() const final;
112 v8::Isolate* isolate() const { return m_isolate; } 112 v8::Isolate* isolate() const { return m_isolate; }
113 DOMWrapperWorld& world() const { return *m_world; } 113 DOMWrapperWorld& world() const { return *m_world; }
114 114
115 // Oilpan: promptly clear listener wrapper.
116 EAGERLY_FINALIZE();
117 #if ENABLE(OILPAN)
118 DECLARE_EAGER_FINALIZATION_OPERATOR_NEW();
119 #endif
115 DEFINE_INLINE_VIRTUAL_TRACE() 120 DEFINE_INLINE_VIRTUAL_TRACE()
116 { 121 {
117 EventListener::trace(visitor); 122 EventListener::trace(visitor);
118 } 123 }
119 124
120 protected: 125 protected:
121 V8AbstractEventListener(bool isAttribute, DOMWrapperWorld&, v8::Isolate*); 126 V8AbstractEventListener(bool isAttribute, DOMWrapperWorld&, v8::Isolate*);
122 127
123 virtual void prepareListenerObject(ExecutionContext*) { } 128 virtual void prepareListenerObject(ExecutionContext*) { }
124 129
(...skipping 21 matching lines...) Expand all
146 // Indicates if this is an HTML type listener. 151 // Indicates if this is an HTML type listener.
147 bool m_isAttribute; 152 bool m_isAttribute;
148 153
149 RefPtr<DOMWrapperWorld> m_world; 154 RefPtr<DOMWrapperWorld> m_world;
150 v8::Isolate* m_isolate; 155 v8::Isolate* m_isolate;
151 }; 156 };
152 157
153 } // namespace blink 158 } // namespace blink
154 159
155 #endif // V8AbstractEventListener_h 160 #endif // V8AbstractEventListener_h
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698