OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2011 Andreas Kling (kling@webkit.org) | 2 * Copyright (C) 2011 Andreas Kling (kling@webkit.org) |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
6 * are met: | 6 * are met: |
7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
46 #include "core/css/CSSInheritedValue.h" | 46 #include "core/css/CSSInheritedValue.h" |
47 #include "core/css/CSSInitialValue.h" | 47 #include "core/css/CSSInitialValue.h" |
48 #include "core/css/CSSLineBoxContainValue.h" | 48 #include "core/css/CSSLineBoxContainValue.h" |
49 #include "core/css/CSSPrimitiveValue.h" | 49 #include "core/css/CSSPrimitiveValue.h" |
50 #include "core/css/CSSReflectValue.h" | 50 #include "core/css/CSSReflectValue.h" |
51 #include "core/css/CSSSVGDocumentValue.h" | 51 #include "core/css/CSSSVGDocumentValue.h" |
52 #include "core/css/CSSShadowValue.h" | 52 #include "core/css/CSSShadowValue.h" |
53 #include "core/css/CSSTimingFunctionValue.h" | 53 #include "core/css/CSSTimingFunctionValue.h" |
54 #include "core/css/CSSTransformValue.h" | 54 #include "core/css/CSSTransformValue.h" |
55 #include "core/css/CSSUnicodeRangeValue.h" | 55 #include "core/css/CSSUnicodeRangeValue.h" |
56 #include "core/css/CSSUnsetValue.h" | |
57 #include "core/css/CSSValueList.h" | 56 #include "core/css/CSSValueList.h" |
58 | 57 |
59 namespace blink { | 58 namespace blink { |
60 | 59 |
61 struct SameSizeAsCSSValue : public RefCountedWillBeGarbageCollectedFinalized<Sam
eSizeAsCSSValue> | 60 struct SameSizeAsCSSValue : public RefCountedWillBeGarbageCollectedFinalized<Sam
eSizeAsCSSValue> |
62 { | 61 { |
63 uint32_t bitfields; | 62 uint32_t bitfields; |
64 }; | 63 }; |
65 | 64 |
66 COMPILE_ASSERT(sizeof(CSSValue) <= sizeof(SameSizeAsCSSValue), CSS_value_should_
stay_small); | 65 COMPILE_ASSERT(sizeof(CSSValue) <= sizeof(SameSizeAsCSSValue), CSS_value_should_
stay_small); |
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
115 case RadialGradientClass: | 114 case RadialGradientClass: |
116 return compareCSSValues<CSSRadialGradientValue>(*this, other); | 115 return compareCSSValues<CSSRadialGradientValue>(*this, other); |
117 case CrossfadeClass: | 116 case CrossfadeClass: |
118 return compareCSSValues<CSSCrossfadeValue>(*this, other); | 117 return compareCSSValues<CSSCrossfadeValue>(*this, other); |
119 case ImageClass: | 118 case ImageClass: |
120 return compareCSSValues<CSSImageValue>(*this, other); | 119 return compareCSSValues<CSSImageValue>(*this, other); |
121 case InheritedClass: | 120 case InheritedClass: |
122 return compareCSSValues<CSSInheritedValue>(*this, other); | 121 return compareCSSValues<CSSInheritedValue>(*this, other); |
123 case InitialClass: | 122 case InitialClass: |
124 return compareCSSValues<CSSInitialValue>(*this, other); | 123 return compareCSSValues<CSSInitialValue>(*this, other); |
125 case UnsetClass: | |
126 return compareCSSValues<CSSUnsetValue>(*this, other); | |
127 case GridLineNamesClass: | 124 case GridLineNamesClass: |
128 return compareCSSValues<CSSGridLineNamesValue>(*this, other); | 125 return compareCSSValues<CSSGridLineNamesValue>(*this, other); |
129 case GridTemplateAreasClass: | 126 case GridTemplateAreasClass: |
130 return compareCSSValues<CSSGridTemplateAreasValue>(*this, other); | 127 return compareCSSValues<CSSGridTemplateAreasValue>(*this, other); |
131 case PrimitiveClass: | 128 case PrimitiveClass: |
132 return compareCSSValues<CSSPrimitiveValue>(*this, other); | 129 return compareCSSValues<CSSPrimitiveValue>(*this, other); |
133 case ReflectClass: | 130 case ReflectClass: |
134 return compareCSSValues<CSSReflectValue>(*this, other); | 131 return compareCSSValues<CSSReflectValue>(*this, other); |
135 case ShadowClass: | 132 case ShadowClass: |
136 return compareCSSValues<CSSShadowValue>(*this, other); | 133 return compareCSSValues<CSSShadowValue>(*this, other); |
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
187 case LinearGradientClass: | 184 case LinearGradientClass: |
188 return toCSSLinearGradientValue(this)->customCSSText(); | 185 return toCSSLinearGradientValue(this)->customCSSText(); |
189 case RadialGradientClass: | 186 case RadialGradientClass: |
190 return toCSSRadialGradientValue(this)->customCSSText(); | 187 return toCSSRadialGradientValue(this)->customCSSText(); |
191 case CrossfadeClass: | 188 case CrossfadeClass: |
192 return toCSSCrossfadeValue(this)->customCSSText(); | 189 return toCSSCrossfadeValue(this)->customCSSText(); |
193 case ImageClass: | 190 case ImageClass: |
194 return toCSSImageValue(this)->customCSSText(); | 191 return toCSSImageValue(this)->customCSSText(); |
195 case InheritedClass: | 192 case InheritedClass: |
196 return toCSSInheritedValue(this)->customCSSText(); | 193 return toCSSInheritedValue(this)->customCSSText(); |
197 case UnsetClass: | |
198 return toCSSUnsetValue(this)->customCSSText(); | |
199 case InitialClass: | 194 case InitialClass: |
200 return toCSSInitialValue(this)->customCSSText(); | 195 return toCSSInitialValue(this)->customCSSText(); |
201 case GridLineNamesClass: | 196 case GridLineNamesClass: |
202 return toCSSGridLineNamesValue(this)->customCSSText(); | 197 return toCSSGridLineNamesValue(this)->customCSSText(); |
203 case GridTemplateAreasClass: | 198 case GridTemplateAreasClass: |
204 return toCSSGridTemplateAreasValue(this)->customCSSText(); | 199 return toCSSGridTemplateAreasValue(this)->customCSSText(); |
205 case PrimitiveClass: | 200 case PrimitiveClass: |
206 return toCSSPrimitiveValue(this)->customCSSText(); | 201 return toCSSPrimitiveValue(this)->customCSSText(); |
207 case ReflectClass: | 202 case ReflectClass: |
208 return toCSSReflectValue(this)->customCSSText(); | 203 return toCSSReflectValue(this)->customCSSText(); |
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
270 return; | 265 return; |
271 case ImageClass: | 266 case ImageClass: |
272 delete toCSSImageValue(this); | 267 delete toCSSImageValue(this); |
273 return; | 268 return; |
274 case InheritedClass: | 269 case InheritedClass: |
275 delete toCSSInheritedValue(this); | 270 delete toCSSInheritedValue(this); |
276 return; | 271 return; |
277 case InitialClass: | 272 case InitialClass: |
278 delete toCSSInitialValue(this); | 273 delete toCSSInitialValue(this); |
279 return; | 274 return; |
280 case UnsetClass: | |
281 delete toCSSUnsetValue(this); | |
282 return; | |
283 case GridLineNamesClass: | 275 case GridLineNamesClass: |
284 delete toCSSGridLineNamesValue(this); | 276 delete toCSSGridLineNamesValue(this); |
285 return; | 277 return; |
286 case GridTemplateAreasClass: | 278 case GridTemplateAreasClass: |
287 delete toCSSGridTemplateAreasValue(this); | 279 delete toCSSGridTemplateAreasValue(this); |
288 return; | 280 return; |
289 case PrimitiveClass: | 281 case PrimitiveClass: |
290 delete toCSSPrimitiveValue(this); | 282 delete toCSSPrimitiveValue(this); |
291 return; | 283 return; |
292 case ReflectClass: | 284 case ReflectClass: |
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
367 return; | 359 return; |
368 case ImageClass: | 360 case ImageClass: |
369 toCSSImageValue(this)->~CSSImageValue(); | 361 toCSSImageValue(this)->~CSSImageValue(); |
370 return; | 362 return; |
371 case InheritedClass: | 363 case InheritedClass: |
372 toCSSInheritedValue(this)->~CSSInheritedValue(); | 364 toCSSInheritedValue(this)->~CSSInheritedValue(); |
373 return; | 365 return; |
374 case InitialClass: | 366 case InitialClass: |
375 toCSSInitialValue(this)->~CSSInitialValue(); | 367 toCSSInitialValue(this)->~CSSInitialValue(); |
376 return; | 368 return; |
377 case UnsetClass: | |
378 toCSSUnsetValue(this)->~CSSUnsetValue(); | |
379 return; | |
380 case GridLineNamesClass: | 369 case GridLineNamesClass: |
381 toCSSGridLineNamesValue(this)->~CSSGridLineNamesValue(); | 370 toCSSGridLineNamesValue(this)->~CSSGridLineNamesValue(); |
382 return; | 371 return; |
383 case GridTemplateAreasClass: | 372 case GridTemplateAreasClass: |
384 toCSSGridTemplateAreasValue(this)->~CSSGridTemplateAreasValue(); | 373 toCSSGridTemplateAreasValue(this)->~CSSGridTemplateAreasValue(); |
385 return; | 374 return; |
386 case PrimitiveClass: | 375 case PrimitiveClass: |
387 toCSSPrimitiveValue(this)->~CSSPrimitiveValue(); | 376 toCSSPrimitiveValue(this)->~CSSPrimitiveValue(); |
388 return; | 377 return; |
389 case ReflectClass: | 378 case ReflectClass: |
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
464 return; | 453 return; |
465 case ImageClass: | 454 case ImageClass: |
466 toCSSImageValue(this)->traceAfterDispatch(visitor); | 455 toCSSImageValue(this)->traceAfterDispatch(visitor); |
467 return; | 456 return; |
468 case InheritedClass: | 457 case InheritedClass: |
469 toCSSInheritedValue(this)->traceAfterDispatch(visitor); | 458 toCSSInheritedValue(this)->traceAfterDispatch(visitor); |
470 return; | 459 return; |
471 case InitialClass: | 460 case InitialClass: |
472 toCSSInitialValue(this)->traceAfterDispatch(visitor); | 461 toCSSInitialValue(this)->traceAfterDispatch(visitor); |
473 return; | 462 return; |
474 case UnsetClass: | |
475 toCSSUnsetValue(this)->traceAfterDispatch(visitor); | |
476 return; | |
477 case GridLineNamesClass: | 463 case GridLineNamesClass: |
478 toCSSGridLineNamesValue(this)->traceAfterDispatch(visitor); | 464 toCSSGridLineNamesValue(this)->traceAfterDispatch(visitor); |
479 return; | 465 return; |
480 case GridTemplateAreasClass: | 466 case GridTemplateAreasClass: |
481 toCSSGridTemplateAreasValue(this)->traceAfterDispatch(visitor); | 467 toCSSGridTemplateAreasValue(this)->traceAfterDispatch(visitor); |
482 return; | 468 return; |
483 case PrimitiveClass: | 469 case PrimitiveClass: |
484 toCSSPrimitiveValue(this)->traceAfterDispatch(visitor); | 470 toCSSPrimitiveValue(this)->traceAfterDispatch(visitor); |
485 return; | 471 return; |
486 case ReflectClass: | 472 case ReflectClass: |
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
520 toCSSSVGDocumentValue(this)->traceAfterDispatch(visitor); | 506 toCSSSVGDocumentValue(this)->traceAfterDispatch(visitor); |
521 return; | 507 return; |
522 case CSSContentDistributionClass: | 508 case CSSContentDistributionClass: |
523 toCSSContentDistributionValue(this)->traceAfterDispatch(visitor); | 509 toCSSContentDistributionValue(this)->traceAfterDispatch(visitor); |
524 return; | 510 return; |
525 } | 511 } |
526 ASSERT_NOT_REACHED(); | 512 ASSERT_NOT_REACHED(); |
527 } | 513 } |
528 | 514 |
529 } | 515 } |
OLD | NEW |