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

Side by Side 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, 3 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2000 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 2000 Lars Knoll (knoll@kde.org)
3 * (C) 2000 Antti Koivisto (koivisto@kde.org) 3 * (C) 2000 Antti Koivisto (koivisto@kde.org)
4 * (C) 2000 Dirk Mueller (mueller@kde.org) 4 * (C) 2000 Dirk Mueller (mueller@kde.org)
5 * Copyright (C) 2003, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All r ights reserved. 5 * Copyright (C) 2003, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All r ights reserved.
6 * Copyright (C) 2006 Graham Dennis (graham.dennis@gmail.com) 6 * Copyright (C) 2006 Graham Dennis (graham.dennis@gmail.com)
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 397 matching lines...) Expand 10 before | Expand all | Expand 10 after
408 bool hasMarginBeforeQuirk() const { return marginBefore().quirk(); } 408 bool hasMarginBeforeQuirk() const { return marginBefore().quirk(); }
409 bool hasMarginAfterQuirk() const { return marginAfter().quirk(); } 409 bool hasMarginAfterQuirk() const { return marginAfter().quirk(); }
410 410
411 bool hasBackgroundImage() const { return m_background->background().hasImage (); } 411 bool hasBackgroundImage() const { return m_background->background().hasImage (); }
412 bool hasFixedBackgroundImage() const { return m_background->background().has FixedImage(); } 412 bool hasFixedBackgroundImage() const { return m_background->background().has FixedImage(); }
413 413
414 bool hasEntirelyFixedBackground() const; 414 bool hasEntirelyFixedBackground() const;
415 415
416 bool hasAppearance() const { return appearance() != NoControlPart; } 416 bool hasAppearance() const { return appearance() != NoControlPart; }
417 417
418 bool isBackgroundColorCurrentColor() const
419 {
420 return backgroundColor().isCurrentColor() || visitedLinkBackgroundColor( ).isCurrentColor();
421 }
422
418 bool hasBackground() const 423 bool hasBackground() const
419 { 424 {
420 Color color = visitedDependentColor(CSSPropertyBackgroundColor); 425 Color color = visitedDependentColor(CSSPropertyBackgroundColor);
421 if (color.alpha()) 426 if (color.alpha()) {
422 return true; 427 return true;
428 }
423 return hasBackgroundImage(); 429 return hasBackgroundImage();
424 } 430 }
425 431
426 LayoutRectOutsets imageOutsets(const NinePieceImage&) const; 432 LayoutRectOutsets imageOutsets(const NinePieceImage&) const;
427 bool hasBorderImageOutsets() const 433 bool hasBorderImageOutsets() const
428 { 434 {
429 return borderImage().hasImage() && borderImage().outset().nonZero(); 435 return borderImage().hasImage() && borderImage().outset().nonZero();
430 } 436 }
431 LayoutRectOutsets borderImageOutsets() const 437 LayoutRectOutsets borderImageOutsets() const
432 { 438 {
(...skipping 1508 matching lines...) Expand 10 before | Expand all | Expand 10 after
1941 } 1947 }
1942 1948
1943 inline bool ComputedStyle::hasPseudoElementStyle() const 1949 inline bool ComputedStyle::hasPseudoElementStyle() const
1944 { 1950 {
1945 return noninherited_flags.pseudoBits & PSEUDO_ELEMENT_MASK; 1951 return noninherited_flags.pseudoBits & PSEUDO_ELEMENT_MASK;
1946 } 1952 }
1947 1953
1948 } // namespace blink 1954 } // namespace blink
1949 1955
1950 #endif // ComputedStyle_h 1956 #endif // ComputedStyle_h
OLDNEW
« 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