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

Side by Side Diff: third_party/WebKit/Source/core/dom/custom/CustomElementCallbackInvocation.cpp

Issue 1854423002: ASSERT -> {DCHECK|DCHECK_XX}, ENABLE(ASSERT) -> DCHECK_IS_ON() in dom (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: mark svg/as-image/svg-nested.html crash on win Created 4 years, 8 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2013 Google Inc. All rights reserved. 2 * Copyright (C) 2013 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 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. 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 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
43 private: 43 private:
44 void dispatch(Element*) override; 44 void dispatch(Element*) override;
45 45
46 CustomElementLifecycleCallbacks::CallbackType m_which; 46 CustomElementLifecycleCallbacks::CallbackType m_which;
47 }; 47 };
48 48
49 AttachedDetachedInvocation::AttachedDetachedInvocation(RawPtr<CustomElementLifec ycleCallbacks> callbacks, CustomElementLifecycleCallbacks::CallbackType which) 49 AttachedDetachedInvocation::AttachedDetachedInvocation(RawPtr<CustomElementLifec ycleCallbacks> callbacks, CustomElementLifecycleCallbacks::CallbackType which)
50 : CustomElementCallbackInvocation(callbacks) 50 : CustomElementCallbackInvocation(callbacks)
51 , m_which(which) 51 , m_which(which)
52 { 52 {
53 ASSERT(m_which == CustomElementLifecycleCallbacks::AttachedCallback || m_whi ch == CustomElementLifecycleCallbacks::DetachedCallback); 53 DCHECK(m_which == CustomElementLifecycleCallbacks::AttachedCallback || m_whi ch == CustomElementLifecycleCallbacks::DetachedCallback);
54 } 54 }
55 55
56 void AttachedDetachedInvocation::dispatch(Element* element) 56 void AttachedDetachedInvocation::dispatch(Element* element)
57 { 57 {
58 switch (m_which) { 58 switch (m_which) {
59 case CustomElementLifecycleCallbacks::AttachedCallback: 59 case CustomElementLifecycleCallbacks::AttachedCallback:
60 callbacks()->attached(element); 60 callbacks()->attached(element);
61 break; 61 break;
62 case CustomElementLifecycleCallbacks::DetachedCallback: 62 case CustomElementLifecycleCallbacks::DetachedCallback:
63 callbacks()->detached(element); 63 callbacks()->detached(element);
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
131 return new AttributeChangedInvocation(callbacks, name, oldValue, newValue); 131 return new AttributeChangedInvocation(callbacks, name, oldValue, newValue);
132 } 132 }
133 133
134 DEFINE_TRACE(CustomElementCallbackInvocation) 134 DEFINE_TRACE(CustomElementCallbackInvocation)
135 { 135 {
136 visitor->trace(m_callbacks); 136 visitor->trace(m_callbacks);
137 CustomElementProcessingStep::trace(visitor); 137 CustomElementProcessingStep::trace(visitor);
138 } 138 }
139 139
140 } // namespace blink 140 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698