OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) | 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) |
4 * (C) 2005 Allan Sandfeld Jensen (kde@carewolf.com) | 4 * (C) 2005 Allan Sandfeld Jensen (kde@carewolf.com) |
5 * (C) 2005, 2006 Samuel Weinig (sam.weinig@gmail.com) | 5 * (C) 2005, 2006 Samuel Weinig (sam.weinig@gmail.com) |
6 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights reserv
ed. | 6 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights reserv
ed. |
7 * Copyright (C) 2013 Adobe Systems Incorporated. All rights reserved. | 7 * Copyright (C) 2013 Adobe Systems Incorporated. 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 1419 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1430 while (curLayer) { | 1430 while (curLayer) { |
1431 layers.append(curLayer); | 1431 layers.append(curLayer); |
1432 // Stop traversal when an opaque layer is encountered. | 1432 // Stop traversal when an opaque layer is encountered. |
1433 // FIXME : It would be possible for the following occlusion culling test
to be more aggressive | 1433 // FIXME : It would be possible for the following occlusion culling test
to be more aggressive |
1434 // on layers with no repeat by testing whether the image covers the layo
ut rect. | 1434 // on layers with no repeat by testing whether the image covers the layo
ut rect. |
1435 // Testing that here would imply duplicating a lot of calculations that
are currently done in | 1435 // Testing that here would imply duplicating a lot of calculations that
are currently done in |
1436 // RenderBoxModelObject::paintFillLayerExtended. A more efficient soluti
on might be to move | 1436 // RenderBoxModelObject::paintFillLayerExtended. A more efficient soluti
on might be to move |
1437 // the layer recursion into paintFillLayerExtended, or to compute the la
yer geometry here | 1437 // the layer recursion into paintFillLayerExtended, or to compute the la
yer geometry here |
1438 // and pass it down. | 1438 // and pass it down. |
1439 | 1439 |
1440 if (!shouldDrawBackgroundInSeparateBuffer && curLayer->blendMode() != bl
ink::WebBlendModeNormal) | 1440 if (!shouldDrawBackgroundInSeparateBuffer && curLayer->blendMode() != We
bBlendModeNormal) |
1441 shouldDrawBackgroundInSeparateBuffer = true; | 1441 shouldDrawBackgroundInSeparateBuffer = true; |
1442 | 1442 |
1443 // The clipOccludesNextLayers condition must be evaluated first to avoid
short-circuiting. | 1443 // The clipOccludesNextLayers condition must be evaluated first to avoid
short-circuiting. |
1444 if (curLayer->clipOccludesNextLayers(curLayer == &fillLayer) && curLayer
->hasOpaqueImage(this) && curLayer->image()->canRender(*this, style()->effective
Zoom()) && curLayer->hasRepeatXY() && curLayer->blendMode() == blink::WebBlendMo
deNormal && !boxShadowShouldBeAppliedToBackground(bleedAvoidance)) | 1444 if (curLayer->clipOccludesNextLayers(curLayer == &fillLayer) && curLayer
->hasOpaqueImage(this) && curLayer->image()->canRender(*this, style()->effective
Zoom()) && curLayer->hasRepeatXY() && curLayer->blendMode() == WebBlendModeNorma
l && !boxShadowShouldBeAppliedToBackground(bleedAvoidance)) |
1445 break; | 1445 break; |
1446 curLayer = curLayer->next(); | 1446 curLayer = curLayer->next(); |
1447 } | 1447 } |
1448 | 1448 |
1449 GraphicsContext* context = paintInfo.context; | 1449 GraphicsContext* context = paintInfo.context; |
1450 if (!context) | 1450 if (!context) |
1451 shouldDrawBackgroundInSeparateBuffer = false; | 1451 shouldDrawBackgroundInSeparateBuffer = false; |
1452 if (shouldDrawBackgroundInSeparateBuffer) | 1452 if (shouldDrawBackgroundInSeparateBuffer) |
1453 context->beginTransparencyLayer(1); | 1453 context->beginTransparencyLayer(1); |
1454 | 1454 |
(...skipping 3244 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4699 RenderBox::BoxDecorationData::BoxDecorationData(const RenderStyle& style) | 4699 RenderBox::BoxDecorationData::BoxDecorationData(const RenderStyle& style) |
4700 { | 4700 { |
4701 backgroundColor = style.visitedDependentColor(CSSPropertyBackgroundColor); | 4701 backgroundColor = style.visitedDependentColor(CSSPropertyBackgroundColor); |
4702 hasBackground = backgroundColor.alpha() || style.hasBackgroundImage(); | 4702 hasBackground = backgroundColor.alpha() || style.hasBackgroundImage(); |
4703 ASSERT(hasBackground == style.hasBackground()); | 4703 ASSERT(hasBackground == style.hasBackground()); |
4704 hasBorder = style.hasBorder(); | 4704 hasBorder = style.hasBorder(); |
4705 hasAppearance = style.hasAppearance(); | 4705 hasAppearance = style.hasAppearance(); |
4706 } | 4706 } |
4707 | 4707 |
4708 } // namespace blink | 4708 } // namespace blink |
OLD | NEW |