| 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 800 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 811 return 0; | 811 return 0; |
| 812 | 812 |
| 813 // If the element has inline style it is probably unique. | 813 // If the element has inline style it is probably unique. |
| 814 if (state.styledElement()->inlineStyle()) | 814 if (state.styledElement()->inlineStyle()) |
| 815 return 0; | 815 return 0; |
| 816 if (state.styledElement()->isSVGElement() && toSVGElement(state.styledElemen
t())->animatedSMILStyleProperties()) | 816 if (state.styledElement()->isSVGElement() && toSVGElement(state.styledElemen
t())->animatedSMILStyleProperties()) |
| 817 return 0; | 817 return 0; |
| 818 // Ids stop style sharing if they show up in the stylesheets. | 818 // Ids stop style sharing if they show up in the stylesheets. |
| 819 if (state.styledElement()->hasID() && m_features.idsInRules.contains(state.s
tyledElement()->idForStyleResolution().impl())) | 819 if (state.styledElement()->hasID() && m_features.idsInRules.contains(state.s
tyledElement()->idForStyleResolution().impl())) |
| 820 return 0; | 820 return 0; |
| 821 // Active and hovered elements always make a chain towards the document node |
| 822 // and no siblings or cousins will have the same state. |
| 823 if (state.styledElement()->hovered()) |
| 824 return 0; |
| 825 if (state.styledElement()->active()) |
| 826 return 0; |
| 827 // There is always only one focused element. |
| 828 if (state.styledElement()->focused()) |
| 829 return 0; |
| 821 if (parentElementPreventsSharing(state.element()->parentElement())) | 830 if (parentElementPreventsSharing(state.element()->parentElement())) |
| 822 return 0; | 831 return 0; |
| 823 if (state.styledElement()->hasScopedHTMLStyleChild()) | 832 if (state.styledElement()->hasScopedHTMLStyleChild()) |
| 824 return 0; | 833 return 0; |
| 825 if (state.element() == state.document()->cssTarget()) | 834 if (state.element() == state.document()->cssTarget()) |
| 826 return 0; | 835 return 0; |
| 827 if (elementHasDirectionAuto(state.element())) | 836 if (elementHasDirectionAuto(state.element())) |
| 828 return 0; | 837 return 0; |
| 829 if (state.element()->hasActiveAnimations()) | 838 if (state.element()->hasActiveAnimations()) |
| 830 return 0; | 839 return 0; |
| (...skipping 2648 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3479 info.addMember(m_state, "state"); | 3488 info.addMember(m_state, "state"); |
| 3480 | 3489 |
| 3481 // FIXME: move this to a place where it would be called only once? | 3490 // FIXME: move this to a place where it would be called only once? |
| 3482 info.addMember(CSSDefaultStyleSheets::defaultStyle, "defaultStyle"); | 3491 info.addMember(CSSDefaultStyleSheets::defaultStyle, "defaultStyle"); |
| 3483 info.addMember(CSSDefaultStyleSheets::defaultQuirksStyle, "defaultQuirksStyl
e"); | 3492 info.addMember(CSSDefaultStyleSheets::defaultQuirksStyle, "defaultQuirksStyl
e"); |
| 3484 info.addMember(CSSDefaultStyleSheets::defaultPrintStyle, "defaultPrintStyle"
); | 3493 info.addMember(CSSDefaultStyleSheets::defaultPrintStyle, "defaultPrintStyle"
); |
| 3485 info.addMember(CSSDefaultStyleSheets::defaultViewSourceStyle, "defaultViewSo
urceStyle"); | 3494 info.addMember(CSSDefaultStyleSheets::defaultViewSourceStyle, "defaultViewSo
urceStyle"); |
| 3486 } | 3495 } |
| 3487 | 3496 |
| 3488 } // namespace WebCore | 3497 } // namespace WebCore |
| OLD | NEW |