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 390 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
401 delete toCSSSVGDocumentValue(this); | 401 delete toCSSSVGDocumentValue(this); |
402 return; | 402 return; |
403 } | 403 } |
404 ASSERT_NOT_REACHED(); | 404 ASSERT_NOT_REACHED(); |
405 } | 405 } |
406 | 406 |
407 void CSSValue::finalizeGarbageCollectedObject() | 407 void CSSValue::finalizeGarbageCollectedObject() |
408 { | 408 { |
409 if (m_isTextClone) { | 409 if (m_isTextClone) { |
410 ASSERT(isCSSOMSafe()); | 410 ASSERT(isCSSOMSafe()); |
411 static_cast<TextCloneCSSValue*>(this)->~TextCloneCSSValue(); | 411 toTextCloneCSSValue(this)->~TextCloneCSSValue(); |
412 return; | 412 return; |
413 } | 413 } |
414 ASSERT(!isCSSOMSafe() || isSubtypeExposedToCSSOM()); | 414 ASSERT(!isCSSOMSafe() || isSubtypeExposedToCSSOM()); |
415 | 415 |
416 switch (classType()) { | 416 switch (classType()) { |
417 case AspectRatioClass: | 417 case AspectRatioClass: |
418 toCSSAspectRatioValue(this)->~CSSAspectRatioValue(); | 418 toCSSAspectRatioValue(this)->~CSSAspectRatioValue(); |
419 return; | 419 return; |
420 case BorderImageSliceClass: | 420 case BorderImageSliceClass: |
421 toCSSBorderImageSliceValue(this)->~CSSBorderImageSliceValue(); | 421 toCSSBorderImageSliceValue(this)->~CSSBorderImageSliceValue(); |
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
505 toCSSSVGDocumentValue(this)->~CSSSVGDocumentValue(); | 505 toCSSSVGDocumentValue(this)->~CSSSVGDocumentValue(); |
506 return; | 506 return; |
507 } | 507 } |
508 ASSERT_NOT_REACHED(); | 508 ASSERT_NOT_REACHED(); |
509 } | 509 } |
510 | 510 |
511 void CSSValue::trace(Visitor* visitor) | 511 void CSSValue::trace(Visitor* visitor) |
512 { | 512 { |
513 if (m_isTextClone) { | 513 if (m_isTextClone) { |
514 ASSERT(isCSSOMSafe()); | 514 ASSERT(isCSSOMSafe()); |
515 static_cast<TextCloneCSSValue*>(this)->traceAfterDispatch(visitor); | 515 toTextCloneCSSValue(this)->traceAfterDispatch(visitor); |
516 return; | 516 return; |
517 } | 517 } |
518 ASSERT(!isCSSOMSafe() || isSubtypeExposedToCSSOM()); | 518 ASSERT(!isCSSOMSafe() || isSubtypeExposedToCSSOM()); |
519 | 519 |
520 switch (classType()) { | 520 switch (classType()) { |
521 case AspectRatioClass: | 521 case AspectRatioClass: |
522 toCSSAspectRatioValue(this)->traceAfterDispatch(visitor); | 522 toCSSAspectRatioValue(this)->traceAfterDispatch(visitor); |
523 return; | 523 return; |
524 case BorderImageSliceClass: | 524 case BorderImageSliceClass: |
525 toCSSBorderImageSliceValue(this)->traceAfterDispatch(visitor); | 525 toCSSBorderImageSliceValue(this)->traceAfterDispatch(visitor); |
(...skipping 104 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
630 return toCSSTransformValue(this)->cloneForCSSOM(); | 630 return toCSSTransformValue(this)->cloneForCSSOM(); |
631 case ImageSetClass: | 631 case ImageSetClass: |
632 return toCSSImageSetValue(this)->cloneForCSSOM(); | 632 return toCSSImageSetValue(this)->cloneForCSSOM(); |
633 default: | 633 default: |
634 ASSERT(!isSubtypeExposedToCSSOM()); | 634 ASSERT(!isSubtypeExposedToCSSOM()); |
635 return TextCloneCSSValue::create(classType(), cssText()); | 635 return TextCloneCSSValue::create(classType(), cssText()); |
636 } | 636 } |
637 } | 637 } |
638 | 638 |
639 } | 639 } |
OLD | NEW |