OLD | NEW |
1 /* | 1 /* |
2 Copyright (C) 2004, 2005, 2007 Nikolas Zimmermann <zimmermann@kde.org> | 2 Copyright (C) 2004, 2005, 2007 Nikolas Zimmermann <zimmermann@kde.org> |
3 2004, 2005, 2007 Rob Buis <buis@kde.org> | 3 2004, 2005, 2007 Rob Buis <buis@kde.org> |
4 Copyright (C) Research In Motion Limited 2010. All rights reserved. | 4 Copyright (C) Research In Motion Limited 2010. All rights reserved. |
5 | 5 |
6 Based on khtml code by: | 6 Based on khtml code by: |
7 Copyright (C) 1999 Antti Koivisto (koivisto@kde.org) | 7 Copyright (C) 1999 Antti Koivisto (koivisto@kde.org) |
8 Copyright (C) 1999-2003 Lars Knoll (knoll@kde.org) | 8 Copyright (C) 1999-2003 Lars Knoll (knoll@kde.org) |
9 Copyright (C) 2002-2003 Dirk Mueller (mueller@kde.org) | 9 Copyright (C) 2002-2003 Dirk Mueller (mueller@kde.org) |
10 Copyright (C) 2002 Apple Computer, Inc. | 10 Copyright (C) 2002 Apple Computer, Inc. |
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
79 , visitedLinkPaintType(SVGRenderStyle::initialStrokePaintType()) | 79 , visitedLinkPaintType(SVGRenderStyle::initialStrokePaintType()) |
80 , visitedLinkPaintColor(SVGRenderStyle::initialStrokePaintColor()) | 80 , visitedLinkPaintColor(SVGRenderStyle::initialStrokePaintColor()) |
81 , visitedLinkPaintUri(SVGRenderStyle::initialStrokePaintUri()) | 81 , visitedLinkPaintUri(SVGRenderStyle::initialStrokePaintUri()) |
82 { | 82 { |
83 } | 83 } |
84 | 84 |
85 StyleStrokeData::StyleStrokeData(const StyleStrokeData& other) | 85 StyleStrokeData::StyleStrokeData(const StyleStrokeData& other) |
86 : RefCounted<StyleStrokeData>() | 86 : RefCounted<StyleStrokeData>() |
87 , opacity(other.opacity) | 87 , opacity(other.opacity) |
88 , miterLimit(other.miterLimit) | 88 , miterLimit(other.miterLimit) |
89 , width(other.width) | 89 , width(other.width->clone()) |
90 , dashOffset(other.dashOffset) | 90 , dashOffset(other.dashOffset->clone()) |
91 , dashArray(other.dashArray) | 91 , dashArray(other.dashArray->clone()) |
92 , paintType(other.paintType) | 92 , paintType(other.paintType) |
93 , paintColor(other.paintColor) | 93 , paintColor(other.paintColor) |
94 , paintUri(other.paintUri) | 94 , paintUri(other.paintUri) |
95 , visitedLinkPaintType(other.visitedLinkPaintType) | 95 , visitedLinkPaintType(other.visitedLinkPaintType) |
96 , visitedLinkPaintColor(other.visitedLinkPaintColor) | 96 , visitedLinkPaintColor(other.visitedLinkPaintColor) |
97 , visitedLinkPaintUri(other.visitedLinkPaintUri) | 97 , visitedLinkPaintUri(other.visitedLinkPaintUri) |
98 { | 98 { |
99 } | 99 } |
100 | 100 |
101 bool StyleStrokeData::operator==(const StyleStrokeData& other) const | 101 bool StyleStrokeData::operator==(const StyleStrokeData& other) const |
102 { | 102 { |
103 return width == other.width | 103 return *width == *other.width |
104 && opacity == other.opacity | 104 && opacity == other.opacity |
105 && miterLimit == other.miterLimit | 105 && miterLimit == other.miterLimit |
106 && dashOffset == other.dashOffset | 106 && *dashOffset == *other.dashOffset |
107 && dashArray == other.dashArray | 107 && *dashArray == *other.dashArray |
108 && paintType == other.paintType | 108 && paintType == other.paintType |
109 && paintColor == other.paintColor | 109 && paintColor == other.paintColor |
110 && paintUri == other.paintUri | 110 && paintUri == other.paintUri |
111 && visitedLinkPaintType == other.visitedLinkPaintType | 111 && visitedLinkPaintType == other.visitedLinkPaintType |
112 && visitedLinkPaintColor == other.visitedLinkPaintColor | 112 && visitedLinkPaintColor == other.visitedLinkPaintColor |
113 && visitedLinkPaintUri == other.visitedLinkPaintUri; | 113 && visitedLinkPaintUri == other.visitedLinkPaintUri; |
114 } | 114 } |
115 | 115 |
116 StyleStopData::StyleStopData() | 116 StyleStopData::StyleStopData() |
117 : opacity(SVGRenderStyle::initialStopOpacity()) | 117 : opacity(SVGRenderStyle::initialStopOpacity()) |
(...skipping 14 matching lines...) Expand all Loading... |
132 && opacity == other.opacity; | 132 && opacity == other.opacity; |
133 } | 133 } |
134 | 134 |
135 StyleTextData::StyleTextData() | 135 StyleTextData::StyleTextData() |
136 : kerning(SVGRenderStyle::initialKerning()) | 136 : kerning(SVGRenderStyle::initialKerning()) |
137 { | 137 { |
138 } | 138 } |
139 | 139 |
140 StyleTextData::StyleTextData(const StyleTextData& other) | 140 StyleTextData::StyleTextData(const StyleTextData& other) |
141 : RefCounted<StyleTextData>() | 141 : RefCounted<StyleTextData>() |
142 , kerning(other.kerning) | 142 , kerning(other.kerning->clone()) |
143 { | 143 { |
144 } | 144 } |
145 | 145 |
146 bool StyleTextData::operator==(const StyleTextData& other) const | 146 bool StyleTextData::operator==(const StyleTextData& other) const |
147 { | 147 { |
148 return kerning == other.kerning; | 148 return *kerning == *other.kerning; |
149 } | 149 } |
150 | 150 |
151 StyleMiscData::StyleMiscData() | 151 StyleMiscData::StyleMiscData() |
152 : floodColor(SVGRenderStyle::initialFloodColor()) | 152 : floodColor(SVGRenderStyle::initialFloodColor()) |
153 , floodOpacity(SVGRenderStyle::initialFloodOpacity()) | 153 , floodOpacity(SVGRenderStyle::initialFloodOpacity()) |
154 , lightingColor(SVGRenderStyle::initialLightingColor()) | 154 , lightingColor(SVGRenderStyle::initialLightingColor()) |
155 , baselineShiftValue(SVGRenderStyle::initialBaselineShiftValue()) | 155 , baselineShiftValue(SVGRenderStyle::initialBaselineShiftValue()) |
156 { | 156 { |
157 } | 157 } |
158 | 158 |
159 StyleMiscData::StyleMiscData(const StyleMiscData& other) | 159 StyleMiscData::StyleMiscData(const StyleMiscData& other) |
160 : RefCounted<StyleMiscData>() | 160 : RefCounted<StyleMiscData>() |
161 , floodColor(other.floodColor) | 161 , floodColor(other.floodColor) |
162 , floodOpacity(other.floodOpacity) | 162 , floodOpacity(other.floodOpacity) |
163 , lightingColor(other.lightingColor) | 163 , lightingColor(other.lightingColor) |
164 , baselineShiftValue(other.baselineShiftValue) | 164 , baselineShiftValue(other.baselineShiftValue->clone()) |
165 { | 165 { |
166 } | 166 } |
167 | 167 |
168 bool StyleMiscData::operator==(const StyleMiscData& other) const | 168 bool StyleMiscData::operator==(const StyleMiscData& other) const |
169 { | 169 { |
170 return floodOpacity == other.floodOpacity | 170 return floodOpacity == other.floodOpacity |
171 && floodColor == other.floodColor | 171 && floodColor == other.floodColor |
172 && lightingColor == other.lightingColor | 172 && lightingColor == other.lightingColor |
173 && baselineShiftValue == other.baselineShiftValue; | 173 && *baselineShiftValue == *other.baselineShiftValue; |
174 } | 174 } |
175 | 175 |
176 StyleResourceData::StyleResourceData() | 176 StyleResourceData::StyleResourceData() |
177 : clipper(SVGRenderStyle::initialClipperResource()) | 177 : clipper(SVGRenderStyle::initialClipperResource()) |
178 , filter(SVGRenderStyle::initialFilterResource()) | 178 , filter(SVGRenderStyle::initialFilterResource()) |
179 , masker(SVGRenderStyle::initialMaskerResource()) | 179 , masker(SVGRenderStyle::initialMaskerResource()) |
180 { | 180 { |
181 } | 181 } |
182 | 182 |
183 StyleResourceData::StyleResourceData(const StyleResourceData& other) | 183 StyleResourceData::StyleResourceData(const StyleResourceData& other) |
(...skipping 27 matching lines...) Expand all Loading... |
211 } | 211 } |
212 | 212 |
213 bool StyleInheritedResourceData::operator==(const StyleInheritedResourceData& ot
her) const | 213 bool StyleInheritedResourceData::operator==(const StyleInheritedResourceData& ot
her) const |
214 { | 214 { |
215 return markerStart == other.markerStart | 215 return markerStart == other.markerStart |
216 && markerMid == other.markerMid | 216 && markerMid == other.markerMid |
217 && markerEnd == other.markerEnd; | 217 && markerEnd == other.markerEnd; |
218 } | 218 } |
219 | 219 |
220 } | 220 } |
OLD | NEW |