| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
| 3 * (C) 2004-2005 Allan Sandfeld Jensen (kde@carewolf.com) | 3 * (C) 2004-2005 Allan Sandfeld Jensen (kde@carewolf.com) |
| 4 * Copyright (C) 2006, 2007 Nicholas Shanks (webkit@nickshanks.com) | 4 * Copyright (C) 2006, 2007 Nicholas Shanks (webkit@nickshanks.com) |
| 5 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013 Apple Inc.
All rights reserved. | 5 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012, 2013 Apple Inc.
All rights reserved. |
| 6 * Copyright (C) 2007 Alexey Proskuryakov <ap@webkit.org> | 6 * Copyright (C) 2007 Alexey Proskuryakov <ap@webkit.org> |
| 7 * Copyright (C) 2007, 2008 Eric Seidel <eric@webkit.org> | 7 * Copyright (C) 2007, 2008 Eric Seidel <eric@webkit.org> |
| 8 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t
orchmobile.com/) | 8 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t
orchmobile.com/) |
| 9 * Copyright (c) 2011, Code Aurora Forum. All rights reserved. | 9 * Copyright (c) 2011, Code Aurora Forum. All rights reserved. |
| 10 * Copyright (C) Research In Motion Limited 2011. All rights reserved. | 10 * Copyright (C) Research In Motion Limited 2011. All rights reserved. |
| (...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 71 #include "core/css/StylePropertySet.h" | 71 #include "core/css/StylePropertySet.h" |
| 72 #include "core/css/StylePropertyShorthand.h" | 72 #include "core/css/StylePropertyShorthand.h" |
| 73 #include "core/css/StyleRule.h" | 73 #include "core/css/StyleRule.h" |
| 74 #include "core/css/StyleRuleImport.h" | 74 #include "core/css/StyleRuleImport.h" |
| 75 #include "core/css/StyleSheetContents.h" | 75 #include "core/css/StyleSheetContents.h" |
| 76 #include "core/css/StyleSheetList.h" | 76 #include "core/css/StyleSheetList.h" |
| 77 #include "core/css/WebKitCSSKeyframeRule.h" | 77 #include "core/css/WebKitCSSKeyframeRule.h" |
| 78 #include "core/css/WebKitCSSKeyframesRule.h" | 78 #include "core/css/WebKitCSSKeyframesRule.h" |
| 79 #include "core/css/WebKitCSSRegionRule.h" | 79 #include "core/css/WebKitCSSRegionRule.h" |
| 80 #include "core/css/resolver/FilterOperationResolver.h" | 80 #include "core/css/resolver/FilterOperationResolver.h" |
| 81 #include "core/css/resolver/StyleBuilder.h" |
| 81 #include "core/css/resolver/TransformBuilder.h" | 82 #include "core/css/resolver/TransformBuilder.h" |
| 82 #include "core/css/resolver/ViewportStyleResolver.h" | 83 #include "core/css/resolver/ViewportStyleResolver.h" |
| 83 #include "core/dom/Attribute.h" | 84 #include "core/dom/Attribute.h" |
| 84 #include "core/dom/ContextFeatures.h" | 85 #include "core/dom/ContextFeatures.h" |
| 85 #include "core/dom/DocumentStyleSheetCollection.h" | 86 #include "core/dom/DocumentStyleSheetCollection.h" |
| 86 #include "core/dom/NodeRenderStyle.h" | 87 #include "core/dom/NodeRenderStyle.h" |
| 87 #include "core/dom/NodeRenderingContext.h" | 88 #include "core/dom/NodeRenderingContext.h" |
| 88 #include "core/dom/Text.h" | 89 #include "core/dom/Text.h" |
| 89 #include "core/dom/VisitedLinkState.h" | 90 #include "core/dom/VisitedLinkState.h" |
| 90 #include "core/dom/WebCoreMemoryInstrumentation.h" | 91 #include "core/dom/WebCoreMemoryInstrumentation.h" |
| (...skipping 2368 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2459 if (handler.isValid()) { | 2460 if (handler.isValid()) { |
| 2460 if (isInherit) | 2461 if (isInherit) |
| 2461 handler.applyInheritValue(id, this); | 2462 handler.applyInheritValue(id, this); |
| 2462 else if (isInitial) | 2463 else if (isInitial) |
| 2463 handler.applyInitialValue(id, this); | 2464 handler.applyInitialValue(id, this); |
| 2464 else | 2465 else |
| 2465 handler.applyValue(id, this, value); | 2466 handler.applyValue(id, this, value); |
| 2466 return; | 2467 return; |
| 2467 } | 2468 } |
| 2468 | 2469 |
| 2470 // Use the new StyleBuilder. |
| 2471 if (StyleBuilder::applyProperty(id, this, value, isInitial, isInherit)) |
| 2472 return; |
| 2473 |
| 2469 CSSPrimitiveValue* primitiveValue = value->isPrimitiveValue() ? toCSSPrimiti
veValue(value) : 0; | 2474 CSSPrimitiveValue* primitiveValue = value->isPrimitiveValue() ? toCSSPrimiti
veValue(value) : 0; |
| 2470 | 2475 |
| 2471 float zoomFactor = state.style()->effectiveZoom(); | 2476 float zoomFactor = state.style()->effectiveZoom(); |
| 2472 | 2477 |
| 2473 // What follows is a list that maps the CSS properties into their correspond
ing front-end | 2478 // What follows is a list that maps the CSS properties into their correspond
ing front-end |
| 2474 // RenderStyle values. | 2479 // RenderStyle values. |
| 2475 switch (id) { | 2480 switch (id) { |
| 2476 // lists | 2481 // lists |
| 2477 case CSSPropertyContent: | 2482 case CSSPropertyContent: |
| 2478 // list of string, uri, counter, attr, i | 2483 // list of string, uri, counter, attr, i |
| (...skipping 569 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3048 state.style()->setGridAfter(afterPosition); | 3053 state.style()->setGridAfter(afterPosition); |
| 3049 return; | 3054 return; |
| 3050 } | 3055 } |
| 3051 | 3056 |
| 3052 // These properties are aliased and DeprecatedStyleBuilder already applied t
he property on the prefixed version. | 3057 // These properties are aliased and DeprecatedStyleBuilder already applied t
he property on the prefixed version. |
| 3053 case CSSPropertyTransitionDelay: | 3058 case CSSPropertyTransitionDelay: |
| 3054 case CSSPropertyTransitionDuration: | 3059 case CSSPropertyTransitionDuration: |
| 3055 case CSSPropertyTransitionProperty: | 3060 case CSSPropertyTransitionProperty: |
| 3056 case CSSPropertyTransitionTimingFunction: | 3061 case CSSPropertyTransitionTimingFunction: |
| 3057 return; | 3062 return; |
| 3058 // These properties are implemented in the DeprecatedStyleBuilder lookup tab
le. | 3063 // These properties are implemented in the DeprecatedStyleBuilder lookup tab
le or in the new StyleBuilder. |
| 3059 case CSSPropertyBackgroundAttachment: | 3064 case CSSPropertyBackgroundAttachment: |
| 3060 case CSSPropertyBackgroundBlendMode: | 3065 case CSSPropertyBackgroundBlendMode: |
| 3061 case CSSPropertyBackgroundClip: | 3066 case CSSPropertyBackgroundClip: |
| 3062 case CSSPropertyBackgroundColor: | 3067 case CSSPropertyBackgroundColor: |
| 3063 case CSSPropertyBackgroundImage: | 3068 case CSSPropertyBackgroundImage: |
| 3064 case CSSPropertyBackgroundOrigin: | 3069 case CSSPropertyBackgroundOrigin: |
| 3065 case CSSPropertyBackgroundPositionX: | 3070 case CSSPropertyBackgroundPositionX: |
| 3066 case CSSPropertyBackgroundPositionY: | 3071 case CSSPropertyBackgroundPositionY: |
| 3067 case CSSPropertyBackgroundRepeatX: | 3072 case CSSPropertyBackgroundRepeatX: |
| 3068 case CSSPropertyBackgroundRepeatY: | 3073 case CSSPropertyBackgroundRepeatY: |
| (...skipping 786 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3855 info.addMember(m_state, "state"); | 3860 info.addMember(m_state, "state"); |
| 3856 | 3861 |
| 3857 // FIXME: move this to a place where it would be called only once? | 3862 // FIXME: move this to a place where it would be called only once? |
| 3858 info.addMember(CSSDefaultStyleSheets::defaultStyle, "defaultStyle"); | 3863 info.addMember(CSSDefaultStyleSheets::defaultStyle, "defaultStyle"); |
| 3859 info.addMember(CSSDefaultStyleSheets::defaultQuirksStyle, "defaultQuirksStyl
e"); | 3864 info.addMember(CSSDefaultStyleSheets::defaultQuirksStyle, "defaultQuirksStyl
e"); |
| 3860 info.addMember(CSSDefaultStyleSheets::defaultPrintStyle, "defaultPrintStyle"
); | 3865 info.addMember(CSSDefaultStyleSheets::defaultPrintStyle, "defaultPrintStyle"
); |
| 3861 info.addMember(CSSDefaultStyleSheets::defaultViewSourceStyle, "defaultViewSo
urceStyle"); | 3866 info.addMember(CSSDefaultStyleSheets::defaultViewSourceStyle, "defaultViewSo
urceStyle"); |
| 3862 } | 3867 } |
| 3863 | 3868 |
| 3864 } // namespace WebCore | 3869 } // namespace WebCore |
| OLD | NEW |