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

Side by Side Diff: third_party/WebKit/Source/core/paint/SVGPaintContext.cpp

Issue 2640163004: Replace ENABLE(ASSERT) with DCHECK_IS_ON(). (Closed)
Patch Set: m_domTreeVersion initialization Created 3 years, 11 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) 2007, 2008 Rob Buis <buis@kde.org> 2 * Copyright (C) 2007, 2008 Rob Buis <buis@kde.org>
3 * Copyright (C) 2007 Nikolas Zimmermann <zimmermann@kde.org> 3 * Copyright (C) 2007 Nikolas Zimmermann <zimmermann@kde.org>
4 * Copyright (C) 2007 Eric Seidel <eric@webkit.org> 4 * Copyright (C) 2007 Eric Seidel <eric@webkit.org>
5 * Copyright (C) 2009 Google, Inc. All rights reserved. 5 * Copyright (C) 2009 Google, Inc. All rights reserved.
6 * Copyright (C) 2009 Dirk Schulze <krit@webkit.org> 6 * Copyright (C) 2009 Dirk Schulze <krit@webkit.org>
7 * Copyright (C) Research In Motion Limited 2009-2010. All rights reserved. 7 * Copyright (C) Research In Motion Limited 2009-2010. All rights reserved.
8 * 8 *
9 * This library is free software; you can redistribute it and/or 9 * This library is free software; you can redistribute it and/or
10 * modify it under the terms of the GNU Library General Public 10 * modify it under the terms of the GNU Library General Public
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
50 50
51 if (m_masker) { 51 if (m_masker) {
52 DCHECK(SVGResourcesCache::cachedResourcesForLayoutObject(&m_object)); 52 DCHECK(SVGResourcesCache::cachedResourcesForLayoutObject(&m_object));
53 DCHECK(SVGResourcesCache::cachedResourcesForLayoutObject(&m_object) 53 DCHECK(SVGResourcesCache::cachedResourcesForLayoutObject(&m_object)
54 ->masker() == m_masker); 54 ->masker() == m_masker);
55 SVGMaskPainter(*m_masker).finishEffect(m_object, paintInfo().context); 55 SVGMaskPainter(*m_masker).finishEffect(m_object, paintInfo().context);
56 } 56 }
57 } 57 }
58 58
59 bool SVGPaintContext::applyClipMaskAndFilterIfNecessary() { 59 bool SVGPaintContext::applyClipMaskAndFilterIfNecessary() {
60 #if ENABLE(ASSERT) 60 #if DCHECK_IS_ON()
61 DCHECK(!m_applyClipMaskAndFilterIfNecessaryCalled); 61 DCHECK(!m_applyClipMaskAndFilterIfNecessaryCalled);
62 m_applyClipMaskAndFilterIfNecessaryCalled = true; 62 m_applyClipMaskAndFilterIfNecessaryCalled = true;
63 #endif 63 #endif
64 // In SPv2 we should early exit once the paint property state has been 64 // In SPv2 we should early exit once the paint property state has been
65 // applied, because all meta (non-drawing) display items are ignored in 65 // applied, because all meta (non-drawing) display items are ignored in
66 // SPv2. However we can't simply omit them because there are still 66 // SPv2. However we can't simply omit them because there are still
67 // non-composited painting (e.g. SVG filters in particular) that rely on 67 // non-composited painting (e.g. SVG filters in particular) that rely on
68 // these meta display items. 68 // these meta display items.
69 applyPaintPropertyState(); 69 applyPaintPropertyState();
70 70
(...skipping 198 matching lines...) Expand 10 before | Expand all | Expand 10 after
269 // though. 269 // though.
270 // Additionally, it's not really safe/guaranteed to be correct, as 270 // Additionally, it's not really safe/guaranteed to be correct, as
271 // something down the paint pipe may want to farther tweak the color 271 // something down the paint pipe may want to farther tweak the color
272 // filter, which could yield incorrect results. (Consider just using 272 // filter, which could yield incorrect results. (Consider just using
273 // saveLayer() w/ this color filter explicitly instead.) 273 // saveLayer() w/ this color filter explicitly instead.)
274 paint.setColorFilter(sk_ref_sp(paintInfo.context.getColorFilter())); 274 paint.setColorFilter(sk_ref_sp(paintInfo.context.getColorFilter()));
275 return true; 275 return true;
276 } 276 }
277 277
278 } // namespace blink 278 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/paint/SVGPaintContext.h ('k') | third_party/WebKit/Source/core/style/GridArea.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698