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

Side by Side Diff: third_party/WebKit/Source/core/svg/SVGFECompositeElement.cpp

Issue 2738863002: Replace ASSERT with DCHECK in core/svg/ (Closed)
Patch Set: static_cast<unsigned>(1) > 1u Created 3 years, 9 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) 2004, 2005, 2007 Nikolas Zimmermann <zimmermann@kde.org> 2 * Copyright (C) 2004, 2005, 2007 Nikolas Zimmermann <zimmermann@kde.org>
3 * Copyright (C) 2004, 2005, 2006 Rob Buis <buis@kde.org> 3 * Copyright (C) 2004, 2005, 2006 Rob Buis <buis@kde.org>
4 * 4 *
5 * This library is free software; you can redistribute it and/or 5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Library General Public 6 * modify it under the terms of the GNU Library General Public
7 * License as published by the Free Software Foundation; either 7 * License as published by the Free Software Foundation; either
8 * version 2 of the License, or (at your option) any later version. 8 * version 2 of the License, or (at your option) any later version.
9 * 9 *
10 * This library is distributed in the hope that it will be useful, 10 * This library is distributed in the hope that it will be useful,
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after
125 125
126 SVGFilterPrimitiveStandardAttributes::svgAttributeChanged(attrName); 126 SVGFilterPrimitiveStandardAttributes::svgAttributeChanged(attrName);
127 } 127 }
128 128
129 FilterEffect* SVGFECompositeElement::build(SVGFilterBuilder* filterBuilder, 129 FilterEffect* SVGFECompositeElement::build(SVGFilterBuilder* filterBuilder,
130 Filter* filter) { 130 Filter* filter) {
131 FilterEffect* input1 = filterBuilder->getEffectById( 131 FilterEffect* input1 = filterBuilder->getEffectById(
132 AtomicString(m_in1->currentValue()->value())); 132 AtomicString(m_in1->currentValue()->value()));
133 FilterEffect* input2 = filterBuilder->getEffectById( 133 FilterEffect* input2 = filterBuilder->getEffectById(
134 AtomicString(m_in2->currentValue()->value())); 134 AtomicString(m_in2->currentValue()->value()));
135 ASSERT(input1 && input2); 135 DCHECK(input1 && input2);
tkent 2017/03/14 22:33:14 Split it to two DCHECKs. DCHECK(input1); DCHEC
mrunal 2017/03/14 23:52:14 Done.
136 136
137 FilterEffect* effect = FEComposite::create( 137 FilterEffect* effect = FEComposite::create(
138 filter, m_svgOperator->currentValue()->enumValue(), 138 filter, m_svgOperator->currentValue()->enumValue(),
139 m_k1->currentValue()->value(), m_k2->currentValue()->value(), 139 m_k1->currentValue()->value(), m_k2->currentValue()->value(),
140 m_k3->currentValue()->value(), m_k4->currentValue()->value()); 140 m_k3->currentValue()->value(), m_k4->currentValue()->value());
141 FilterEffectVector& inputEffects = effect->inputEffects(); 141 FilterEffectVector& inputEffects = effect->inputEffects();
142 inputEffects.reserveCapacity(2); 142 inputEffects.reserveCapacity(2);
143 inputEffects.push_back(input1); 143 inputEffects.push_back(input1);
144 inputEffects.push_back(input2); 144 inputEffects.push_back(input2);
145 return effect; 145 return effect;
146 } 146 }
147 147
148 } // namespace blink 148 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698