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

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

Issue 14022022: FINALizing of the Node hierarchy. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Action review comments. Created 7 years, 7 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
« no previous file with comments | « no previous file | Source/core/dom/Attr.h » ('j') | 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) 2010 Google Inc. All rights reserved. 2 * Copyright (C) 2010 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 20 matching lines...) Expand all
31 #ifndef ScriptWrappable_h 31 #ifndef ScriptWrappable_h
32 #define ScriptWrappable_h 32 #define ScriptWrappable_h
33 33
34 #include "bindings/v8/V8Utilities.h" 34 #include "bindings/v8/V8Utilities.h"
35 #include "bindings/v8/WrapperTypeInfo.h" 35 #include "bindings/v8/WrapperTypeInfo.h"
36 #include "core/dom/WebCoreMemoryInstrumentation.h" 36 #include "core/dom/WebCoreMemoryInstrumentation.h"
37 #include <v8.h> 37 #include <v8.h>
38 38
39 namespace WebCore { 39 namespace WebCore {
40 40
41 class ScriptWrappable { 41 class ScriptWrappable : public MemoryReporterTag {
42 friend class WeakHandleListener<ScriptWrappable>; 42 friend class WeakHandleListener<ScriptWrappable>;
43 public: 43 public:
44 ScriptWrappable() : m_maskedStorage(0) { } 44 ScriptWrappable() : m_maskedStorage(0) { }
45 45
46 // Wrappables need to be initialized with their most derrived type for which 46 // Wrappables need to be initialized with their most derrived type for which
47 // bindings exist, in much the same way that certain other types need to be 47 // bindings exist, in much the same way that certain other types need to be
48 // adopted and so forth. The overloaded initializeScriptWrappableForInterfac e() 48 // adopted and so forth. The overloaded initializeScriptWrappableForInterfac e()
49 // functions are implemented by the generated V8 bindings code. Declaring th e 49 // functions are implemented by the generated V8 bindings code. Declaring th e
50 // extern function in the template avoids making a centralized header of all 50 // extern function in the template avoids making a centralized header of all
51 // the bindings in the universe. C++11's extern template feature may provide 51 // the bindings in the universe. C++11's extern template feature may provide
(...skipping 145 matching lines...) Expand 10 before | Expand all | Expand 10 after
197 key->disposeWrapper(value, isolate, info); 197 key->disposeWrapper(value, isolate, info);
198 // FIXME: I noticed that 50%~ of minor GC cycle times can be consumed 198 // FIXME: I noticed that 50%~ of minor GC cycle times can be consumed
199 // inside key->deref(), which causes Node destructions. We should 199 // inside key->deref(), which causes Node destructions. We should
200 // make Node destructions incremental. 200 // make Node destructions incremental.
201 info->derefObject(object); 201 info->derefObject(object);
202 } 202 }
203 203
204 } // namespace WebCore 204 } // namespace WebCore
205 205
206 #endif // ScriptWrappable_h 206 #endif // ScriptWrappable_h
OLDNEW
« no previous file with comments | « no previous file | Source/core/dom/Attr.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698