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

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

Issue 2401523002: Replace ASSERT family with DCHECK and so on in core/dom/. (Closed)
Patch Set: Created 4 years, 2 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 86 matching lines...) Expand 10 before | Expand all | Expand 10 after
97 } 97 }
98 98
99 return false; 99 return false;
100 } 100 }
101 101
102 void V0CustomElement::define(Element* element, 102 void V0CustomElement::define(Element* element,
103 V0CustomElementDefinition* definition) { 103 V0CustomElementDefinition* definition) {
104 switch (element->getV0CustomElementState()) { 104 switch (element->getV0CustomElementState()) {
105 case Element::V0NotCustomElement: 105 case Element::V0NotCustomElement:
106 case Element::V0Upgraded: 106 case Element::V0Upgraded:
107 ASSERT_NOT_REACHED(); 107 NOTREACHED();
108 break; 108 break;
109 109
110 case Element::V0WaitingForUpgrade: 110 case Element::V0WaitingForUpgrade:
111 element->v0SetCustomElementDefinition(definition); 111 element->v0SetCustomElementDefinition(definition);
112 V0CustomElementScheduler::scheduleCallback( 112 V0CustomElementScheduler::scheduleCallback(
113 definition->callbacks(), element, 113 definition->callbacks(), element,
114 V0CustomElementLifecycleCallbacks::CreatedCallback); 114 V0CustomElementLifecycleCallbacks::CreatedCallback);
115 break; 115 break;
116 } 116 }
117 } 117 }
(...skipping 22 matching lines...) Expand all
140 if (!document.domWindow()) 140 if (!document.domWindow())
141 return; 141 return;
142 V0CustomElementScheduler::scheduleCallback( 142 V0CustomElementScheduler::scheduleCallback(
143 element->v0CustomElementDefinition()->callbacks(), element, 143 element->v0CustomElementDefinition()->callbacks(), element,
144 V0CustomElementLifecycleCallbacks::DetachedCallback); 144 V0CustomElementLifecycleCallbacks::DetachedCallback);
145 } 145 }
146 146
147 void V0CustomElement::wasDestroyed(Element* element) { 147 void V0CustomElement::wasDestroyed(Element* element) {
148 switch (element->getV0CustomElementState()) { 148 switch (element->getV0CustomElementState()) {
149 case Element::V0NotCustomElement: 149 case Element::V0NotCustomElement:
150 ASSERT_NOT_REACHED(); 150 NOTREACHED();
151 break; 151 break;
152 152
153 case Element::V0WaitingForUpgrade: 153 case Element::V0WaitingForUpgrade:
154 case Element::V0Upgraded: 154 case Element::V0Upgraded:
155 V0CustomElementObserver::notifyElementWasDestroyed(element); 155 V0CustomElementObserver::notifyElementWasDestroyed(element);
156 break; 156 break;
157 } 157 }
158 } 158 }
159 159
160 } // namespace blink 160 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698