Chromium Code Reviews| Index: cc/layers/delegated_renderer_layer_impl.cc |
| diff --git a/cc/layers/delegated_renderer_layer_impl.cc b/cc/layers/delegated_renderer_layer_impl.cc |
| index 8a95b9e9137f26dbb68ad2241011a5132fc9cde2..dfeb080513b1b5dc4d464883815a588e82d29f2f 100644 |
| --- a/cc/layers/delegated_renderer_layer_impl.cc |
| +++ b/cc/layers/delegated_renderer_layer_impl.cc |
| @@ -349,32 +349,42 @@ void DelegatedRendererLayerImpl::AppendRainbowDebugBorder( |
| break; |
| if (!top.IsEmpty()) { |
| + bool force_anti_aliasing_off = false; |
| SolidColorDrawQuad* top_quad = |
| render_pass->CreateAndAppendDrawQuad<SolidColorDrawQuad>(); |
| - top_quad->SetNew( |
| - shared_quad_state, top, top, colors[i % kNumColors], false); |
| + top_quad->SetNew(shared_quad_state, top, top, colors[i % kNumColors], |
| + force_anti_aliasing_off); |
| SolidColorDrawQuad* bottom_quad = |
| render_pass->CreateAndAppendDrawQuad<SolidColorDrawQuad>(); |
| - bottom_quad->SetNew(shared_quad_state, |
| - bottom, |
| - bottom, |
| + bottom_quad->SetNew(shared_quad_state, bottom, bottom, |
| colors[kNumColors - 1 - (i % kNumColors)], |
| - false); |
| + force_anti_aliasing_off); |
| + |
| + if (contents_opaque()) { |
| + SolidColorDrawQuad* solid_quad = |
| + render_pass->CreateAndAppendDrawQuad<SolidColorDrawQuad>(); |
| + // The inner fill is more transparent then the border. |
| + SkColor fill_color = SkColorSetA( |
| + colors[i % kNumColors], |
| + static_cast<uint8_t>(SkColorGetA(colors[i % kNumColors]) * 0.1f)); |
|
vmpstr
2015/02/11 22:22:22
nit: make 0.1 a kConstant above? maybe?
danakj
2015/02/11 23:44:01
Done.
|
| + gfx::Rect fill_rect(x, 0, width, content_bounds().height()); |
|
vmpstr
2015/02/11 22:22:22
Can you put a comment saying that blah blah vertic
danakj
2015/02/11 23:44:01
Done.
|
| + solid_quad->SetNew(shared_quad_state, fill_rect, fill_rect, fill_color, |
| + force_anti_aliasing_off); |
| + } |
| } |
| if (!left.IsEmpty()) { |
| + bool force_anti_aliasing_off = false; |
| SolidColorDrawQuad* left_quad = |
| render_pass->CreateAndAppendDrawQuad<SolidColorDrawQuad>(); |
| - left_quad->SetNew(shared_quad_state, |
| - left, |
| - left, |
| + left_quad->SetNew(shared_quad_state, left, left, |
| colors[kNumColors - 1 - (i % kNumColors)], |
| - false); |
| + force_anti_aliasing_off); |
| SolidColorDrawQuad* right_quad = |
| render_pass->CreateAndAppendDrawQuad<SolidColorDrawQuad>(); |
| - right_quad->SetNew( |
| - shared_quad_state, right, right, colors[i % kNumColors], false); |
| + right_quad->SetNew(shared_quad_state, right, right, |
| + colors[i % kNumColors], force_anti_aliasing_off); |
| } |
| } |
| } |