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 * | 7 * |
8 * This library is free software; you can redistribute it and/or | 8 * This library is free software; you can redistribute it and/or |
9 * modify it under the terms of the GNU Library General Public | 9 * modify it under the terms of the GNU Library General Public |
10 * License as published by the Free Software Foundation; either | 10 * License as published by the Free Software Foundation; either |
(...skipping 1153 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1164 | 1164 |
1165 bool RenderBox::backgroundIsKnownToBeOpaqueInRect(const LayoutRect& localRect) c
onst | 1165 bool RenderBox::backgroundIsKnownToBeOpaqueInRect(const LayoutRect& localRect) c
onst |
1166 { | 1166 { |
1167 if (isBody() && skipBodyBackground(this)) | 1167 if (isBody() && skipBodyBackground(this)) |
1168 return false; | 1168 return false; |
1169 | 1169 |
1170 Color backgroundColor = style()->visitedDependentColor(CSSPropertyBackground
Color); | 1170 Color backgroundColor = style()->visitedDependentColor(CSSPropertyBackground
Color); |
1171 if (!backgroundColor.isValid() || backgroundColor.hasAlpha()) | 1171 if (!backgroundColor.isValid() || backgroundColor.hasAlpha()) |
1172 return false; | 1172 return false; |
1173 | 1173 |
| 1174 // If the element has appearance, it might be painted by theme. |
| 1175 // We cannot be sure if theme paints the background opaque. |
| 1176 // In this case it is safe to not assume opaqueness. |
| 1177 // FIXME: May be ask theme if it paints opaque. |
| 1178 if (style()->hasAppearance()) |
| 1179 return false; |
1174 // FIXME: Check the opaqueness of background images. | 1180 // FIXME: Check the opaqueness of background images. |
1175 | 1181 |
1176 // FIXME: Use rounded rect if border radius is present. | 1182 // FIXME: Use rounded rect if border radius is present. |
1177 if (style()->hasBorderRadius()) | 1183 if (style()->hasBorderRadius()) |
1178 return false; | 1184 return false; |
1179 // FIXME: The background color clip is defined by the last layer. | 1185 // FIXME: The background color clip is defined by the last layer. |
1180 if (style()->backgroundLayers()->next()) | 1186 if (style()->backgroundLayers()->next()) |
1181 return false; | 1187 return false; |
1182 LayoutRect backgroundRect; | 1188 LayoutRect backgroundRect; |
1183 switch (style()->backgroundClip()) { | 1189 switch (style()->backgroundClip()) { |
(...skipping 3398 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4582 | 4588 |
4583 void RenderBox::reportStaticMembersMemoryUsage(MemoryInstrumentation* memoryInst
rumentation) | 4589 void RenderBox::reportStaticMembersMemoryUsage(MemoryInstrumentation* memoryInst
rumentation) |
4584 { | 4590 { |
4585 memoryInstrumentation->addRootObject(gOverrideHeightMap, WebCoreMemoryTypes:
:RenderingStructures); | 4591 memoryInstrumentation->addRootObject(gOverrideHeightMap, WebCoreMemoryTypes:
:RenderingStructures); |
4586 memoryInstrumentation->addRootObject(gOverrideWidthMap, WebCoreMemoryTypes::
RenderingStructures); | 4592 memoryInstrumentation->addRootObject(gOverrideWidthMap, WebCoreMemoryTypes::
RenderingStructures); |
4587 memoryInstrumentation->addRootObject(gOverrideContainingBlockLogicalHeightMa
p, WebCoreMemoryTypes::RenderingStructures); | 4593 memoryInstrumentation->addRootObject(gOverrideContainingBlockLogicalHeightMa
p, WebCoreMemoryTypes::RenderingStructures); |
4588 memoryInstrumentation->addRootObject(gOverrideContainingBlockLogicalWidthMap
, WebCoreMemoryTypes::RenderingStructures); | 4594 memoryInstrumentation->addRootObject(gOverrideContainingBlockLogicalWidthMap
, WebCoreMemoryTypes::RenderingStructures); |
4589 } | 4595 } |
4590 | 4596 |
4591 } // namespace WebCore | 4597 } // namespace WebCore |
OLD | NEW |