Chromium Code Reviews| 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 209 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 220 return; | 220 return; |
| 221 case UnicodeRangeClass: | 221 case UnicodeRangeClass: |
| 222 static_cast<const CSSUnicodeRangeValue*>(this)->reportDescendantMemoryUs age(memoryObjectInfo); | 222 static_cast<const CSSUnicodeRangeValue*>(this)->reportDescendantMemoryUs age(memoryObjectInfo); |
| 223 return; | 223 return; |
| 224 case LineBoxContainClass: | 224 case LineBoxContainClass: |
| 225 static_cast<const CSSLineBoxContainValue*>(this)->reportDescendantMemory Usage(memoryObjectInfo); | 225 static_cast<const CSSLineBoxContainValue*>(this)->reportDescendantMemory Usage(memoryObjectInfo); |
| 226 return; | 226 return; |
| 227 case CalculationClass: | 227 case CalculationClass: |
| 228 static_cast<const CSSCalcValue*>(this)->reportDescendantMemoryUsage(memo ryObjectInfo); | 228 static_cast<const CSSCalcValue*>(this)->reportDescendantMemoryUsage(memo ryObjectInfo); |
| 229 return; | 229 return; |
| 230 #if ENABLE(CSS_FILTERS) && ENABLE(CSS_SHADERS) | |
|
eseidel
2013/04/09 18:30:08
CSS_FILTERS?
| |
| 231 case WebKitCSSArrayFunctionValueClass: | 230 case WebKitCSSArrayFunctionValueClass: |
| 232 static_cast<const WebKitCSSArrayFunctionValue*>(this)->reportDescendantM emoryUsage(memoryObjectInfo); | 231 static_cast<const WebKitCSSArrayFunctionValue*>(this)->reportDescendantM emoryUsage(memoryObjectInfo); |
| 233 return; | 232 return; |
| 234 case WebKitCSSMixFunctionValueClass: | 233 case WebKitCSSMixFunctionValueClass: |
| 235 static_cast<const WebKitCSSMixFunctionValue*>(this)->reportDescendantMem oryUsage(memoryObjectInfo); | 234 static_cast<const WebKitCSSMixFunctionValue*>(this)->reportDescendantMem oryUsage(memoryObjectInfo); |
| 236 return; | 235 return; |
| 237 case WebKitCSSShaderClass: | 236 case WebKitCSSShaderClass: |
| 238 static_cast<const WebKitCSSShaderValue*>(this)->reportDescendantMemoryUs age(memoryObjectInfo); | 237 static_cast<const WebKitCSSShaderValue*>(this)->reportDescendantMemoryUs age(memoryObjectInfo); |
| 239 return; | 238 return; |
| 240 #endif | |
| 241 case VariableClass: | 239 case VariableClass: |
| 242 static_cast<const CSSVariableValue*>(this)->reportDescendantMemoryUsage( memoryObjectInfo); | 240 static_cast<const CSSVariableValue*>(this)->reportDescendantMemoryUsage( memoryObjectInfo); |
| 243 return; | 241 return; |
| 244 #if ENABLE(SVG) | 242 #if ENABLE(SVG) |
| 245 case SVGColorClass: | 243 case SVGColorClass: |
| 246 static_cast<const SVGColor*>(this)->reportDescendantMemoryUsage(memoryOb jectInfo); | 244 static_cast<const SVGColor*>(this)->reportDescendantMemoryUsage(memoryOb jectInfo); |
| 247 return; | 245 return; |
| 248 case SVGPaintClass: | 246 case SVGPaintClass: |
| 249 static_cast<const SVGPaint*>(this)->reportDescendantMemoryUsage(memoryOb jectInfo); | 247 static_cast<const SVGPaint*>(this)->reportDescendantMemoryUsage(memoryOb jectInfo); |
| 250 return; | 248 return; |
| (...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 337 return compareCSSValues<CSSLineBoxContainValue>(*this, other); | 335 return compareCSSValues<CSSLineBoxContainValue>(*this, other); |
| 338 case CalculationClass: | 336 case CalculationClass: |
| 339 return compareCSSValues<CSSCalcValue>(*this, other); | 337 return compareCSSValues<CSSCalcValue>(*this, other); |
| 340 #if ENABLE(CSS_IMAGE_SET) | 338 #if ENABLE(CSS_IMAGE_SET) |
| 341 case ImageSetClass: | 339 case ImageSetClass: |
| 342 return compareCSSValues<CSSImageSetValue>(*this, other); | 340 return compareCSSValues<CSSImageSetValue>(*this, other); |
| 343 #endif | 341 #endif |
| 344 #if ENABLE(CSS_FILTERS) | 342 #if ENABLE(CSS_FILTERS) |
| 345 case WebKitCSSFilterClass: | 343 case WebKitCSSFilterClass: |
| 346 return compareCSSValues<WebKitCSSFilterValue>(*this, other); | 344 return compareCSSValues<WebKitCSSFilterValue>(*this, other); |
| 347 #if ENABLE(CSS_SHADERS) | |
| 348 case WebKitCSSArrayFunctionValueClass: | 345 case WebKitCSSArrayFunctionValueClass: |
| 349 return compareCSSValues<WebKitCSSArrayFunctionValue>(*this, other); | 346 return compareCSSValues<WebKitCSSArrayFunctionValue>(*this, other); |
| 350 case WebKitCSSMixFunctionValueClass: | 347 case WebKitCSSMixFunctionValueClass: |
| 351 return compareCSSValues<WebKitCSSMixFunctionValue>(*this, other); | 348 return compareCSSValues<WebKitCSSMixFunctionValue>(*this, other); |
| 352 case WebKitCSSShaderClass: | 349 case WebKitCSSShaderClass: |
| 353 return compareCSSValues<WebKitCSSShaderValue>(*this, other); | 350 return compareCSSValues<WebKitCSSShaderValue>(*this, other); |
| 354 #endif | 351 #endif |
| 355 #endif | |
| 356 case VariableClass: | 352 case VariableClass: |
| 357 return compareCSSValues<CSSVariableValue>(*this, other); | 353 return compareCSSValues<CSSVariableValue>(*this, other); |
| 358 #if ENABLE(SVG) | 354 #if ENABLE(SVG) |
| 359 case SVGColorClass: | 355 case SVGColorClass: |
| 360 return compareCSSValues<SVGColor>(*this, other); | 356 return compareCSSValues<SVGColor>(*this, other); |
| 361 case SVGPaintClass: | 357 case SVGPaintClass: |
| 362 return compareCSSValues<SVGPaint>(*this, other); | 358 return compareCSSValues<SVGPaint>(*this, other); |
| 363 case WebKitCSSSVGDocumentClass: | 359 case WebKitCSSSVGDocumentClass: |
| 364 return compareCSSValues<WebKitCSSSVGDocumentValue>(*this, other); | 360 return compareCSSValues<WebKitCSSSVGDocumentValue>(*this, other); |
| 365 #endif | 361 #endif |
| (...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 433 return static_cast<const CSSLineBoxContainValue*>(this)->customCssText() ; | 429 return static_cast<const CSSLineBoxContainValue*>(this)->customCssText() ; |
| 434 case CalculationClass: | 430 case CalculationClass: |
| 435 return static_cast<const CSSCalcValue*>(this)->customCssText(); | 431 return static_cast<const CSSCalcValue*>(this)->customCssText(); |
| 436 #if ENABLE(CSS_IMAGE_SET) | 432 #if ENABLE(CSS_IMAGE_SET) |
| 437 case ImageSetClass: | 433 case ImageSetClass: |
| 438 return static_cast<const CSSImageSetValue*>(this)->customCssText(); | 434 return static_cast<const CSSImageSetValue*>(this)->customCssText(); |
| 439 #endif | 435 #endif |
| 440 #if ENABLE(CSS_FILTERS) | 436 #if ENABLE(CSS_FILTERS) |
| 441 case WebKitCSSFilterClass: | 437 case WebKitCSSFilterClass: |
| 442 return static_cast<const WebKitCSSFilterValue*>(this)->customCssText(); | 438 return static_cast<const WebKitCSSFilterValue*>(this)->customCssText(); |
| 443 #if ENABLE(CSS_SHADERS) | |
| 444 case WebKitCSSArrayFunctionValueClass: | 439 case WebKitCSSArrayFunctionValueClass: |
| 445 return static_cast<const WebKitCSSArrayFunctionValue*>(this)->customCssT ext(); | 440 return static_cast<const WebKitCSSArrayFunctionValue*>(this)->customCssT ext(); |
| 446 case WebKitCSSMixFunctionValueClass: | 441 case WebKitCSSMixFunctionValueClass: |
| 447 return static_cast<const WebKitCSSMixFunctionValue*>(this)->customCssTex t(); | 442 return static_cast<const WebKitCSSMixFunctionValue*>(this)->customCssTex t(); |
| 448 case WebKitCSSShaderClass: | 443 case WebKitCSSShaderClass: |
| 449 return static_cast<const WebKitCSSShaderValue*>(this)->customCssText(); | 444 return static_cast<const WebKitCSSShaderValue*>(this)->customCssText(); |
| 450 #endif | 445 #endif |
| 451 #endif | |
| 452 case VariableClass: | 446 case VariableClass: |
| 453 return static_cast<const CSSVariableValue*>(this)->value(); | 447 return static_cast<const CSSVariableValue*>(this)->value(); |
| 454 #if ENABLE(SVG) | 448 #if ENABLE(SVG) |
| 455 case SVGColorClass: | 449 case SVGColorClass: |
| 456 return static_cast<const SVGColor*>(this)->customCssText(); | 450 return static_cast<const SVGColor*>(this)->customCssText(); |
| 457 case SVGPaintClass: | 451 case SVGPaintClass: |
| 458 return static_cast<const SVGPaint*>(this)->customCssText(); | 452 return static_cast<const SVGPaint*>(this)->customCssText(); |
| 459 case WebKitCSSSVGDocumentClass: | 453 case WebKitCSSSVGDocumentClass: |
| 460 return static_cast<const WebKitCSSSVGDocumentValue*>(this)->customCssTex t(); | 454 return static_cast<const WebKitCSSSVGDocumentValue*>(this)->customCssTex t(); |
| 461 #endif | 455 #endif |
| (...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 567 return; | 561 return; |
| 568 #if ENABLE(CSS_IMAGE_SET) | 562 #if ENABLE(CSS_IMAGE_SET) |
| 569 case ImageSetClass: | 563 case ImageSetClass: |
| 570 delete static_cast<CSSImageSetValue*>(this); | 564 delete static_cast<CSSImageSetValue*>(this); |
| 571 return; | 565 return; |
| 572 #endif | 566 #endif |
| 573 #if ENABLE(CSS_FILTERS) | 567 #if ENABLE(CSS_FILTERS) |
| 574 case WebKitCSSFilterClass: | 568 case WebKitCSSFilterClass: |
| 575 delete static_cast<WebKitCSSFilterValue*>(this); | 569 delete static_cast<WebKitCSSFilterValue*>(this); |
| 576 return; | 570 return; |
| 577 #if ENABLE(CSS_SHADERS) | |
| 578 case WebKitCSSArrayFunctionValueClass: | 571 case WebKitCSSArrayFunctionValueClass: |
| 579 delete static_cast<WebKitCSSArrayFunctionValue*>(this); | 572 delete static_cast<WebKitCSSArrayFunctionValue*>(this); |
| 580 return; | 573 return; |
| 581 case WebKitCSSMixFunctionValueClass: | 574 case WebKitCSSMixFunctionValueClass: |
| 582 delete static_cast<WebKitCSSMixFunctionValue*>(this); | 575 delete static_cast<WebKitCSSMixFunctionValue*>(this); |
| 583 return; | 576 return; |
| 584 case WebKitCSSShaderClass: | 577 case WebKitCSSShaderClass: |
| 585 delete static_cast<WebKitCSSShaderValue*>(this); | 578 delete static_cast<WebKitCSSShaderValue*>(this); |
| 586 return; | 579 return; |
| 587 #endif | 580 #endif |
| 588 #endif | |
| 589 case VariableClass: | 581 case VariableClass: |
| 590 delete static_cast<CSSVariableValue*>(this); | 582 delete static_cast<CSSVariableValue*>(this); |
| 591 return; | 583 return; |
| 592 #if ENABLE(SVG) | 584 #if ENABLE(SVG) |
| 593 case SVGColorClass: | 585 case SVGColorClass: |
| 594 delete static_cast<SVGColor*>(this); | 586 delete static_cast<SVGColor*>(this); |
| 595 return; | 587 return; |
| 596 case SVGPaintClass: | 588 case SVGPaintClass: |
| 597 delete static_cast<SVGPaint*>(this); | 589 delete static_cast<SVGPaint*>(this); |
| 598 return; | 590 return; |
| (...skipping 11 matching lines...) Expand all Loading... | |
| 610 case PrimitiveClass: | 602 case PrimitiveClass: |
| 611 return static_cast<const CSSPrimitiveValue*>(this)->cloneForCSSOM(); | 603 return static_cast<const CSSPrimitiveValue*>(this)->cloneForCSSOM(); |
| 612 case ValueListClass: | 604 case ValueListClass: |
| 613 return static_cast<const CSSValueList*>(this)->cloneForCSSOM(); | 605 return static_cast<const CSSValueList*>(this)->cloneForCSSOM(); |
| 614 case ImageClass: | 606 case ImageClass: |
| 615 case CursorImageClass: | 607 case CursorImageClass: |
| 616 return static_cast<const CSSImageValue*>(this)->cloneForCSSOM(); | 608 return static_cast<const CSSImageValue*>(this)->cloneForCSSOM(); |
| 617 #if ENABLE(CSS_FILTERS) | 609 #if ENABLE(CSS_FILTERS) |
| 618 case WebKitCSSFilterClass: | 610 case WebKitCSSFilterClass: |
| 619 return static_cast<const WebKitCSSFilterValue*>(this)->cloneForCSSOM(); | 611 return static_cast<const WebKitCSSFilterValue*>(this)->cloneForCSSOM(); |
| 620 #if ENABLE(CSS_SHADERS) | |
| 621 case WebKitCSSArrayFunctionValueClass: | 612 case WebKitCSSArrayFunctionValueClass: |
| 622 return static_cast<const WebKitCSSArrayFunctionValue*>(this)->cloneForCS SOM(); | 613 return static_cast<const WebKitCSSArrayFunctionValue*>(this)->cloneForCS SOM(); |
| 623 case WebKitCSSMixFunctionValueClass: | 614 case WebKitCSSMixFunctionValueClass: |
| 624 return static_cast<const WebKitCSSMixFunctionValue*>(this)->cloneForCSSO M(); | 615 return static_cast<const WebKitCSSMixFunctionValue*>(this)->cloneForCSSO M(); |
| 625 #endif | 616 #endif |
| 626 #endif | |
| 627 case WebKitCSSTransformClass: | 617 case WebKitCSSTransformClass: |
| 628 return static_cast<const WebKitCSSTransformValue*>(this)->cloneForCSSOM( ); | 618 return static_cast<const WebKitCSSTransformValue*>(this)->cloneForCSSOM( ); |
| 629 #if ENABLE(CSS_IMAGE_SET) | 619 #if ENABLE(CSS_IMAGE_SET) |
| 630 case ImageSetClass: | 620 case ImageSetClass: |
| 631 return static_cast<const CSSImageSetValue*>(this)->cloneForCSSOM(); | 621 return static_cast<const CSSImageSetValue*>(this)->cloneForCSSOM(); |
| 632 #endif | 622 #endif |
| 633 #if ENABLE(SVG) | 623 #if ENABLE(SVG) |
| 634 case SVGColorClass: | 624 case SVGColorClass: |
| 635 return static_cast<const SVGColor*>(this)->cloneForCSSOM(); | 625 return static_cast<const SVGColor*>(this)->cloneForCSSOM(); |
| 636 case SVGPaintClass: | 626 case SVGPaintClass: |
| 637 return static_cast<const SVGPaint*>(this)->cloneForCSSOM(); | 627 return static_cast<const SVGPaint*>(this)->cloneForCSSOM(); |
| 638 #endif | 628 #endif |
| 639 default: | 629 default: |
| 640 ASSERT(!isSubtypeExposedToCSSOM()); | 630 ASSERT(!isSubtypeExposedToCSSOM()); |
| 641 return TextCloneCSSValue::create(classType(), cssText()); | 631 return TextCloneCSSValue::create(classType(), cssText()); |
| 642 } | 632 } |
| 643 } | 633 } |
| 644 | 634 |
| 645 } | 635 } |
| OLD | NEW |