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

Unified Diff: Source/core/style/ComputedStyle.h

Issue 1320553004: LayoutObject::adjustStyleDifference doesn't check backgroundColor when repainting (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: With fixed layout test Created 5 years, 4 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 side-by-side diff with in-line comments
Download patch
« Source/core/layout/LayoutObject.cpp ('K') | « Source/core/layout/LayoutObject.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/style/ComputedStyle.h
diff --git a/Source/core/style/ComputedStyle.h b/Source/core/style/ComputedStyle.h
index e8f1dd447b7c3da63b8cea7aa1f136bd3b89779c..d04e35e75b77e583c5d133110a67cc44c71b8ff3 100644
--- a/Source/core/style/ComputedStyle.h
+++ b/Source/core/style/ComputedStyle.h
@@ -415,11 +415,17 @@ public:
bool hasAppearance() const { return appearance() != NoControlPart; }
+ bool isBackgroundColorCurrentColor() const
+ {
+ return backgroundColor().isCurrentColor() || visitedLinkBackgroundColor().isCurrentColor();
+ }
+
bool hasBackground() const
{
Color color = visitedDependentColor(CSSPropertyBackgroundColor);
- if (color.alpha())
+ if (color.alpha()) {
return true;
+ }
return hasBackgroundImage();
}
« Source/core/layout/LayoutObject.cpp ('K') | « Source/core/layout/LayoutObject.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698