OLD | NEW |
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 23 matching lines...) Expand all Loading... |
34 #include "core/rendering/style/DataRef.h" | 34 #include "core/rendering/style/DataRef.h" |
35 #include "core/rendering/style/LineClampValue.h" | 35 #include "core/rendering/style/LineClampValue.h" |
36 #include "core/rendering/style/NinePieceImage.h" | 36 #include "core/rendering/style/NinePieceImage.h" |
37 #include "core/rendering/style/OutlineValue.h" | 37 #include "core/rendering/style/OutlineValue.h" |
38 #include "core/rendering/style/RenderStyleConstants.h" | 38 #include "core/rendering/style/RenderStyleConstants.h" |
39 #include "core/rendering/style/SVGRenderStyle.h" | 39 #include "core/rendering/style/SVGRenderStyle.h" |
40 #include "core/rendering/style/ShapeValue.h" | 40 #include "core/rendering/style/ShapeValue.h" |
41 #include "core/rendering/style/StyleBackgroundData.h" | 41 #include "core/rendering/style/StyleBackgroundData.h" |
42 #include "core/rendering/style/StyleBoxData.h" | 42 #include "core/rendering/style/StyleBoxData.h" |
43 #include "core/rendering/style/StyleDeprecatedFlexibleBoxData.h" | 43 #include "core/rendering/style/StyleDeprecatedFlexibleBoxData.h" |
| 44 #include "core/rendering/style/StyleDifference.h" |
44 #include "core/rendering/style/StyleFilterData.h" | 45 #include "core/rendering/style/StyleFilterData.h" |
45 #include "core/rendering/style/StyleFlexibleBoxData.h" | 46 #include "core/rendering/style/StyleFlexibleBoxData.h" |
46 #include "core/rendering/style/StyleGridData.h" | 47 #include "core/rendering/style/StyleGridData.h" |
47 #include "core/rendering/style/StyleGridItemData.h" | 48 #include "core/rendering/style/StyleGridItemData.h" |
48 #include "core/rendering/style/StyleMarqueeData.h" | 49 #include "core/rendering/style/StyleMarqueeData.h" |
49 #include "core/rendering/style/StyleMultiColData.h" | 50 #include "core/rendering/style/StyleMultiColData.h" |
50 #include "core/rendering/style/StyleRareInheritedData.h" | 51 #include "core/rendering/style/StyleRareInheritedData.h" |
51 #include "core/rendering/style/StyleRareNonInheritedData.h" | 52 #include "core/rendering/style/StyleRareNonInheritedData.h" |
52 #include "core/rendering/style/StyleReflection.h" | 53 #include "core/rendering/style/StyleReflection.h" |
53 #include "core/rendering/style/StyleSurroundData.h" | 54 #include "core/rendering/style/StyleSurroundData.h" |
(...skipping 299 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
353 public: | 354 public: |
354 static PassRefPtr<RenderStyle> create(); | 355 static PassRefPtr<RenderStyle> create(); |
355 static PassRefPtr<RenderStyle> createDefaultStyle(); | 356 static PassRefPtr<RenderStyle> createDefaultStyle(); |
356 static PassRefPtr<RenderStyle> createAnonymousStyleWithDisplay(const RenderS
tyle* parentStyle, EDisplay); | 357 static PassRefPtr<RenderStyle> createAnonymousStyleWithDisplay(const RenderS
tyle* parentStyle, EDisplay); |
357 static PassRefPtr<RenderStyle> clone(const RenderStyle*); | 358 static PassRefPtr<RenderStyle> clone(const RenderStyle*); |
358 | 359 |
359 // Computes how the style change should be propagated down the tree. | 360 // Computes how the style change should be propagated down the tree. |
360 static StyleRecalcChange stylePropagationDiff(const RenderStyle* oldStyle, c
onst RenderStyle* newStyle); | 361 static StyleRecalcChange stylePropagationDiff(const RenderStyle* oldStyle, c
onst RenderStyle* newStyle); |
361 | 362 |
362 // Computes how much visual invalidation the style change causes: layout, re
paint or recomposite. | 363 // Computes how much visual invalidation the style change causes: layout, re
paint or recomposite. |
363 StyleDifference visualInvalidationDiff(const RenderStyle&, unsigned& changed
ContextSensitiveProperties) const; | 364 StyleDifference visualInvalidationDiff(const RenderStyle&) const; |
364 | 365 |
365 enum IsAtShadowBoundary { | 366 enum IsAtShadowBoundary { |
366 AtShadowBoundary, | 367 AtShadowBoundary, |
367 NotAtShadowBoundary, | 368 NotAtShadowBoundary, |
368 }; | 369 }; |
369 | 370 |
370 void inheritFrom(const RenderStyle* inheritParent, IsAtShadowBoundary = NotA
tShadowBoundary); | 371 void inheritFrom(const RenderStyle* inheritParent, IsAtShadowBoundary = NotA
tShadowBoundary); |
371 void copyNonInheritedFrom(const RenderStyle*); | 372 void copyNonInheritedFrom(const RenderStyle*); |
372 | 373 |
373 PseudoId styleType() const { return static_cast<PseudoId>(noninherited_flags
._styleType); } | 374 PseudoId styleType() const { return static_cast<PseudoId>(noninherited_flags
._styleType); } |
(...skipping 1395 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1769 StyleColor visitedLinkTextFillColor() const { return rareInheritedData->visi
tedLinkTextFillColor(); } | 1770 StyleColor visitedLinkTextFillColor() const { return rareInheritedData->visi
tedLinkTextFillColor(); } |
1770 StyleColor visitedLinkTextStrokeColor() const { return rareInheritedData->vi
sitedLinkTextStrokeColor(); } | 1771 StyleColor visitedLinkTextStrokeColor() const { return rareInheritedData->vi
sitedLinkTextStrokeColor(); } |
1771 | 1772 |
1772 Color colorIncludingFallback(int colorProperty, bool visitedLink) const; | 1773 Color colorIncludingFallback(int colorProperty, bool visitedLink) const; |
1773 | 1774 |
1774 Color stopColor() const { return svgStyle()->stopColor(); } | 1775 Color stopColor() const { return svgStyle()->stopColor(); } |
1775 Color floodColor() const { return svgStyle()->floodColor(); } | 1776 Color floodColor() const { return svgStyle()->floodColor(); } |
1776 Color lightingColor() const { return svgStyle()->lightingColor(); } | 1777 Color lightingColor() const { return svgStyle()->lightingColor(); } |
1777 | 1778 |
1778 void appendContent(PassOwnPtr<ContentData>); | 1779 void appendContent(PassOwnPtr<ContentData>); |
1779 StyleDifference repaintOnlyDiff(const RenderStyle& other, unsigned& changedC
ontextSensitiveProperties) const; | 1780 |
| 1781 StyleDifferenceLegacy visualInvalidationDiffLegacy(const RenderStyle&, unsig
ned& changedContextSensitiveProperties) const; |
| 1782 StyleDifferenceLegacy repaintOnlyDiff(const RenderStyle& other, unsigned& ch
angedContextSensitiveProperties) const; |
1780 }; | 1783 }; |
1781 | 1784 |
1782 inline int adjustForAbsoluteZoom(int value, float zoomFactor) | 1785 inline int adjustForAbsoluteZoom(int value, float zoomFactor) |
1783 { | 1786 { |
1784 if (zoomFactor == 1) | 1787 if (zoomFactor == 1) |
1785 return value; | 1788 return value; |
1786 // Needed because computeLengthInt truncates (rather than rounds) when scali
ng up. | 1789 // Needed because computeLengthInt truncates (rather than rounds) when scali
ng up. |
1787 if (zoomFactor > 1) { | 1790 if (zoomFactor > 1) { |
1788 if (value < 0) | 1791 if (value < 0) |
1789 value--; | 1792 value--; |
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1866 inline bool RenderStyle::hasPseudoElementStyle() const | 1869 inline bool RenderStyle::hasPseudoElementStyle() const |
1867 { | 1870 { |
1868 return noninherited_flags._pseudoBits & PSEUDO_ELEMENT_MASK; | 1871 return noninherited_flags._pseudoBits & PSEUDO_ELEMENT_MASK; |
1869 } | 1872 } |
1870 | 1873 |
1871 float calcBorderRadiiConstraintScaleFor(const FloatRect&, const FloatRoundedRect
::Radii&); | 1874 float calcBorderRadiiConstraintScaleFor(const FloatRect&, const FloatRoundedRect
::Radii&); |
1872 | 1875 |
1873 } // namespace WebCore | 1876 } // namespace WebCore |
1874 | 1877 |
1875 #endif // RenderStyle_h | 1878 #endif // RenderStyle_h |
OLD | NEW |