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

Side by Side Diff: third_party/WebKit/Source/modules/webgl/WebGLObject.h

Issue 2548273002: Addressed haraken's feedback on the removal of WebGLObject maps. (Closed)
Patch Set: Rebased. Created 4 years 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2009 Apple Inc. All rights reserved. 2 * Copyright (C) 2009 Apple 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 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after
84 // True if this object belongs to the group or context. 84 // True if this object belongs to the group or context.
85 virtual bool validate(const WebGLContextGroup*, 85 virtual bool validate(const WebGLContextGroup*,
86 const WebGLRenderingContextBase*) const = 0; 86 const WebGLRenderingContextBase*) const = 0;
87 virtual bool hasObject() const = 0; 87 virtual bool hasObject() const = 0;
88 88
89 // WebGLObjects are eagerly finalized, and the WebGLRenderingContextBase 89 // WebGLObjects are eagerly finalized, and the WebGLRenderingContextBase
90 // is specifically not. This is done in order to allow WebGLObjects to 90 // is specifically not. This is done in order to allow WebGLObjects to
91 // refer back to their owning context in their destructor to delete their 91 // refer back to their owning context in their destructor to delete their
92 // resources if they are GC'd before the context is. 92 // resources if they are GC'd before the context is.
93 EAGERLY_FINALIZE(); 93 EAGERLY_FINALIZE();
94 DECLARE_EAGER_FINALIZATION_OPERATOR_NEW();
95 94
96 DEFINE_INLINE_VIRTUAL_TRACE() {} 95 DEFINE_INLINE_VIRTUAL_TRACE() {}
97 96
98 DECLARE_VIRTUAL_TRACE_WRAPPERS(); 97 DECLARE_VIRTUAL_TRACE_WRAPPERS();
99 98
100 protected: 99 protected:
101 // To allow WebGL[2]RenderingContextBase to call visitChildDOMWrappers. 100 // To allow WebGL[2]RenderingContextBase to call visitChildDOMWrappers.
102 friend class WebGLRenderingContextBase; 101 friend class WebGLRenderingContextBase;
103 friend class WebGL2RenderingContextBase; 102 friend class WebGL2RenderingContextBase;
104 103
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
147 bool m_deleted; 146 bool m_deleted;
148 147
149 // Indicates whether the destructor has been entered and we therefore 148 // Indicates whether the destructor has been entered and we therefore
150 // need to be careful in subclasses to not touch other on-heap objects. 149 // need to be careful in subclasses to not touch other on-heap objects.
151 bool m_destructionInProgress; 150 bool m_destructionInProgress;
152 }; 151 };
153 152
154 } // namespace blink 153 } // namespace blink
155 154
156 #endif // WebGLObject_h 155 #endif // WebGLObject_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698