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

Side by Side Diff: Source/core/paint/BoxBorderPainter.cpp

Issue 1173663003: BoxBorderPainter should use computed color alpha (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 6 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 | Annotate | Revision Log
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "config.h" 5 #include "config.h"
6 #include "core/paint/BoxBorderPainter.h" 6 #include "core/paint/BoxBorderPainter.h"
7 7
8 #include "core/paint/BoxPainter.h" 8 #include "core/paint/BoxPainter.h"
9 #include "core/paint/PaintInfo.h" 9 #include "core/paint/PaintInfo.h"
10 #include "core/style/BorderEdge.h" 10 #include "core/style/BorderEdge.h"
(...skipping 528 matching lines...) Expand 10 before | Expand all | Expand 10 after
539 539
540 if (!edge.shouldRender()) { 540 if (!edge.shouldRender()) {
541 if (edge.presentButInvisible()) { 541 if (edge.presentButInvisible()) {
542 m_isUniformWidth = false; 542 m_isUniformWidth = false;
543 m_isUniformColor = false; 543 m_isUniformColor = false;
544 } 544 }
545 545
546 continue; 546 continue;
547 } 547 }
548 548
549 ASSERT(edge.color.alpha() > 0);
550
549 m_visibleEdgeCount++; 551 m_visibleEdgeCount++;
550 m_visibleEdgeSet |= edgeFlagForSide(static_cast<BoxSide>(i)); 552 m_visibleEdgeSet |= edgeFlagForSide(static_cast<BoxSide>(i));
551 553
552 m_hasAlpha |= edge.color.hasAlpha(); 554 m_hasAlpha |= edge.color.hasAlpha();
553 555
554 if (m_visibleEdgeCount == 1) { 556 if (m_visibleEdgeCount == 1) {
555 m_firstVisibleEdge = i; 557 m_firstVisibleEdge = i;
556 continue; 558 continue;
557 } 559 }
558 560
(...skipping 628 matching lines...) Expand 10 before | Expand all | Expand 10 after
1187 FloatPoint secondQuad[4]; 1189 FloatPoint secondQuad[4];
1188 secondQuad[0] = quad[0]; 1190 secondQuad[0] = quad[0];
1189 secondQuad[1] = FloatPoint(quad[0].x() - r1 * cx, quad[0].y() - r1 * cy) ; 1191 secondQuad[1] = FloatPoint(quad[0].x() - r1 * cx, quad[0].y() - r1 * cy) ;
1190 secondQuad[2] = quad[2]; 1192 secondQuad[2] = quad[2];
1191 secondQuad[3] = quad[3]; 1193 secondQuad[3] = quad[3];
1192 graphicsContext->clipPolygon(4, secondQuad, secondMiter == SoftMiter); 1194 graphicsContext->clipPolygon(4, secondQuad, secondMiter == SoftMiter);
1193 } 1195 }
1194 } 1196 }
1195 1197
1196 } // namespace blink 1198 } // namespace blink
OLDNEW
« no previous file with comments | « LayoutTests/fast/borders/transparent-currentcolor-crash-expected.txt ('k') | Source/core/style/BorderEdge.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698