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

Side by Side Diff: sky/engine/core/rendering/style/StyleRareInheritedData.cpp

Issue 1078943002: remove 'widows' property because paged media support is gone so this does nothing now (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Created 5 years, 8 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
« no previous file with comments | « sky/engine/core/rendering/style/StyleRareInheritedData.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 1999 Antti Koivisto (koivisto@kde.org) 2 * Copyright (C) 1999 Antti Koivisto (koivisto@kde.org)
3 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights reserved. 3 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights reserved.
4 * 4 *
5 * This library is free software; you can redistribute it and/or 5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Library General Public 6 * modify it under the terms of the GNU Library General Public
7 * License as published by the Free Software Foundation; either 7 * License as published by the Free Software Foundation; either
8 * version 2 of the License, or (at your option) any later version. 8 * version 2 of the License, or (at your option) any later version.
9 * 9 *
10 * This library is distributed in the hope that it will be useful, 10 * This library is distributed in the hope that it will be useful,
(...skipping 14 matching lines...) Expand all
25 #include "sky/engine/core/rendering/style/AppliedTextDecoration.h" 25 #include "sky/engine/core/rendering/style/AppliedTextDecoration.h"
26 #include "sky/engine/core/rendering/style/DataEquivalency.h" 26 #include "sky/engine/core/rendering/style/DataEquivalency.h"
27 #include "sky/engine/core/rendering/style/QuotesData.h" 27 #include "sky/engine/core/rendering/style/QuotesData.h"
28 #include "sky/engine/core/rendering/style/RenderStyle.h" 28 #include "sky/engine/core/rendering/style/RenderStyle.h"
29 #include "sky/engine/core/rendering/style/RenderStyleConstants.h" 29 #include "sky/engine/core/rendering/style/RenderStyleConstants.h"
30 #include "sky/engine/core/rendering/style/ShadowList.h" 30 #include "sky/engine/core/rendering/style/ShadowList.h"
31 #include "sky/engine/core/rendering/style/StyleImage.h" 31 #include "sky/engine/core/rendering/style/StyleImage.h"
32 32
33 namespace blink { 33 namespace blink {
34 34
35 struct SameSizeAsStyleRareInheritedData : public RefCounted<SameSizeAsStyleRareI nheritedData> {
36 void* styleImage;
37 Color firstColor;
38 float firstFloat;
39 Color colors[2];
40 void* ownPtrs[1];
41 AtomicString atomicStrings[4];
42 void* refPtrs[1];
43 Length lengths[1];
44 unsigned m_bitfields[2];
45 unsigned unsigneds[1];
46 short pagedMediaShorts[1];
47 short hyphenationShorts[3];
48
49 Color touchColors;
50 };
51
52 COMPILE_ASSERT(sizeof(StyleRareInheritedData) == sizeof(SameSizeAsStyleRareInher itedData), StyleRareInheritedData_should_bit_pack);
53
54 StyleRareInheritedData::StyleRareInheritedData() 35 StyleRareInheritedData::StyleRareInheritedData()
55 : textStrokeWidth(RenderStyle::initialTextStrokeWidth()) 36 : textStrokeWidth(RenderStyle::initialTextStrokeWidth())
56 , indent(RenderStyle::initialTextIndent()) 37 , indent(RenderStyle::initialTextIndent())
57 , m_textStrokeColorIsCurrentColor(true) 38 , m_textStrokeColorIsCurrentColor(true)
58 , m_textFillColorIsCurrentColor(true) 39 , m_textFillColorIsCurrentColor(true)
59 , m_textEmphasisColorIsCurrentColor(true) 40 , m_textEmphasisColorIsCurrentColor(true)
60 , userModify(READ_ONLY) 41 , userModify(READ_ONLY)
61 , wordBreak(RenderStyle::initialWordBreak()) 42 , wordBreak(RenderStyle::initialWordBreak())
62 , overflowWrap(RenderStyle::initialOverflowWrap()) 43 , overflowWrap(RenderStyle::initialOverflowWrap())
63 , lineBreak(LineBreakAuto) 44 , lineBreak(LineBreakAuto)
64 , userSelect(RenderStyle::initialUserSelect()) 45 , userSelect(RenderStyle::initialUserSelect())
65 , hyphens(HyphensManual) 46 , hyphens(HyphensManual)
66 , textEmphasisFill(TextEmphasisFillFilled) 47 , textEmphasisFill(TextEmphasisFillFilled)
67 , textEmphasisMark(TextEmphasisMarkNone) 48 , textEmphasisMark(TextEmphasisMarkNone)
68 , textEmphasisPosition(TextEmphasisPositionOver) 49 , textEmphasisPosition(TextEmphasisPositionOver)
69 , m_textAlignLast(RenderStyle::initialTextAlignLast()) 50 , m_textAlignLast(RenderStyle::initialTextAlignLast())
70 , m_textJustify(RenderStyle::initialTextJustify()) 51 , m_textJustify(RenderStyle::initialTextJustify())
71 , m_textOrientation(TextOrientationVerticalRight) 52 , m_textOrientation(TextOrientationVerticalRight)
72 , m_textIndentLine(RenderStyle::initialTextIndentLine()) 53 , m_textIndentLine(RenderStyle::initialTextIndentLine())
73 , m_textIndentType(RenderStyle::initialTextIndentLine()) 54 , m_textIndentType(RenderStyle::initialTextIndentLine())
74 , m_lineBoxContain(RenderStyle::initialLineBoxContain()) 55 , m_lineBoxContain(RenderStyle::initialLineBoxContain())
75 , m_imageRendering(RenderStyle::initialImageRendering()) 56 , m_imageRendering(RenderStyle::initialImageRendering())
76 , m_textUnderlinePosition(RenderStyle::initialTextUnderlinePosition()) 57 , m_textUnderlinePosition(RenderStyle::initialTextUnderlinePosition())
77 , m_touchActionDelay(RenderStyle::initialTouchActionDelay()) 58 , m_touchActionDelay(RenderStyle::initialTouchActionDelay())
78 , m_subtreeWillChangeContents(false) 59 , m_subtreeWillChangeContents(false)
79 , m_hasAutoWidows(true)
80 , widows(RenderStyle::initialWidows())
81 , hyphenationLimitBefore(-1) 60 , hyphenationLimitBefore(-1)
82 , hyphenationLimitAfter(-1) 61 , hyphenationLimitAfter(-1)
83 , hyphenationLimitLines(-1) 62 , hyphenationLimitLines(-1)
84 , m_tabSize(RenderStyle::initialTabSize()) 63 , m_tabSize(RenderStyle::initialTabSize())
85 , tapHighlightColor(RenderStyle::initialTapHighlightColor()) 64 , tapHighlightColor(RenderStyle::initialTapHighlightColor())
86 { 65 {
87 } 66 }
88 67
89 StyleRareInheritedData::StyleRareInheritedData(const StyleRareInheritedData& o) 68 StyleRareInheritedData::StyleRareInheritedData(const StyleRareInheritedData& o)
90 : RefCounted<StyleRareInheritedData>() 69 : RefCounted<StyleRareInheritedData>()
(...skipping 19 matching lines...) Expand all
110 , m_textAlignLast(o.m_textAlignLast) 89 , m_textAlignLast(o.m_textAlignLast)
111 , m_textJustify(o.m_textJustify) 90 , m_textJustify(o.m_textJustify)
112 , m_textOrientation(o.m_textOrientation) 91 , m_textOrientation(o.m_textOrientation)
113 , m_textIndentLine(o.m_textIndentLine) 92 , m_textIndentLine(o.m_textIndentLine)
114 , m_textIndentType(o.m_textIndentType) 93 , m_textIndentType(o.m_textIndentType)
115 , m_lineBoxContain(o.m_lineBoxContain) 94 , m_lineBoxContain(o.m_lineBoxContain)
116 , m_imageRendering(o.m_imageRendering) 95 , m_imageRendering(o.m_imageRendering)
117 , m_textUnderlinePosition(o.m_textUnderlinePosition) 96 , m_textUnderlinePosition(o.m_textUnderlinePosition)
118 , m_touchActionDelay(o.m_touchActionDelay) 97 , m_touchActionDelay(o.m_touchActionDelay)
119 , m_subtreeWillChangeContents(o.m_subtreeWillChangeContents) 98 , m_subtreeWillChangeContents(o.m_subtreeWillChangeContents)
120 , m_hasAutoWidows(o.m_hasAutoWidows)
121 , widows(o.widows)
122 , hyphenationLimitBefore(o.hyphenationLimitBefore) 99 , hyphenationLimitBefore(o.hyphenationLimitBefore)
123 , hyphenationLimitAfter(o.hyphenationLimitAfter) 100 , hyphenationLimitAfter(o.hyphenationLimitAfter)
124 , hyphenationLimitLines(o.hyphenationLimitLines) 101 , hyphenationLimitLines(o.hyphenationLimitLines)
125 , hyphenationString(o.hyphenationString) 102 , hyphenationString(o.hyphenationString)
126 , locale(o.locale) 103 , locale(o.locale)
127 , textEmphasisCustomMark(o.textEmphasisCustomMark) 104 , textEmphasisCustomMark(o.textEmphasisCustomMark)
128 , m_tabSize(o.m_tabSize) 105 , m_tabSize(o.m_tabSize)
129 , tapHighlightColor(o.tapHighlightColor) 106 , tapHighlightColor(o.tapHighlightColor)
130 , appliedTextDecorations(o.appliedTextDecorations) 107 , appliedTextDecorations(o.appliedTextDecorations)
131 { 108 {
132 } 109 }
133 110
134 StyleRareInheritedData::~StyleRareInheritedData() 111 StyleRareInheritedData::~StyleRareInheritedData()
135 { 112 {
136 } 113 }
137 114
138 bool StyleRareInheritedData::operator==(const StyleRareInheritedData& o) const 115 bool StyleRareInheritedData::operator==(const StyleRareInheritedData& o) const
139 { 116 {
140 return m_textStrokeColor == o.m_textStrokeColor 117 return m_textStrokeColor == o.m_textStrokeColor
141 && textStrokeWidth == o.textStrokeWidth 118 && textStrokeWidth == o.textStrokeWidth
142 && m_textFillColor == o.m_textFillColor 119 && m_textFillColor == o.m_textFillColor
143 && m_textEmphasisColor == o.m_textEmphasisColor 120 && m_textEmphasisColor == o.m_textEmphasisColor
144 && tapHighlightColor == o.tapHighlightColor 121 && tapHighlightColor == o.tapHighlightColor
145 && shadowDataEquivalent(o) 122 && shadowDataEquivalent(o)
146 && highlight == o.highlight 123 && highlight == o.highlight
147 && indent == o.indent 124 && indent == o.indent
148 && widows == o.widows
149 && m_hasAutoWidows == o.m_hasAutoWidows
150 && m_textStrokeColorIsCurrentColor == o.m_textStrokeColorIsCurrentColor 125 && m_textStrokeColorIsCurrentColor == o.m_textStrokeColorIsCurrentColor
151 && m_textFillColorIsCurrentColor == o.m_textFillColorIsCurrentColor 126 && m_textFillColorIsCurrentColor == o.m_textFillColorIsCurrentColor
152 && m_textEmphasisColorIsCurrentColor == o.m_textEmphasisColorIsCurrentCo lor 127 && m_textEmphasisColorIsCurrentColor == o.m_textEmphasisColorIsCurrentCo lor
153 && userModify == o.userModify 128 && userModify == o.userModify
154 && wordBreak == o.wordBreak 129 && wordBreak == o.wordBreak
155 && overflowWrap == o.overflowWrap 130 && overflowWrap == o.overflowWrap
156 && lineBreak == o.lineBreak 131 && lineBreak == o.lineBreak
157 && userSelect == o.userSelect 132 && userSelect == o.userSelect
158 && hyphens == o.hyphens 133 && hyphens == o.hyphens
159 && hyphenationLimitBefore == o.hyphenationLimitBefore 134 && hyphenationLimitBefore == o.hyphenationLimitBefore
(...skipping 24 matching lines...) Expand all
184 { 159 {
185 return dataEquivalent(textShadow.get(), o.textShadow.get()); 160 return dataEquivalent(textShadow.get(), o.textShadow.get());
186 } 161 }
187 162
188 bool StyleRareInheritedData::quotesDataEquivalent(const StyleRareInheritedData& o) const 163 bool StyleRareInheritedData::quotesDataEquivalent(const StyleRareInheritedData& o) const
189 { 164 {
190 return dataEquivalent(quotes, o.quotes); 165 return dataEquivalent(quotes, o.quotes);
191 } 166 }
192 167
193 } // namespace blink 168 } // namespace blink
OLDNEW
« no previous file with comments | « sky/engine/core/rendering/style/StyleRareInheritedData.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698