| 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 898 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 909 case CSSSelector::PseudoPastCue: | 909 case CSSSelector::PseudoPastCue: |
| 910 return element.isVTTElement() && toVTTElement(element).isPastNode(); | 910 return element.isVTTElement() && toVTTElement(element).isPastNode(); |
| 911 case CSSSelector::PseudoScope: | 911 case CSSSelector::PseudoScope: |
| 912 if (m_mode == SharingRules) | 912 if (m_mode == SharingRules) |
| 913 return true; | 913 return true; |
| 914 if (context.scope == &element.document()) | 914 if (context.scope == &element.document()) |
| 915 return element == element.document().documentElement(); | 915 return element == element.document().documentElement(); |
| 916 return context.scope == &element; | 916 return context.scope == &element; |
| 917 case CSSSelector::PseudoUnresolved: | 917 case CSSSelector::PseudoUnresolved: |
| 918 return element.isUnresolvedV0CustomElement(); | 918 return element.isUnresolvedV0CustomElement(); |
| 919 case CSSSelector::PseudoDefined: |
| 920 DCHECK(RuntimeEnabledFeatures::customElementsV1Enabled()); |
| 921 return element.isDefined(); |
| 919 case CSSSelector::PseudoHost: | 922 case CSSSelector::PseudoHost: |
| 920 case CSSSelector::PseudoHostContext: | 923 case CSSSelector::PseudoHostContext: |
| 921 return checkPseudoHost(context, result); | 924 return checkPseudoHost(context, result); |
| 922 case CSSSelector::PseudoSpatialNavigationFocus: | 925 case CSSSelector::PseudoSpatialNavigationFocus: |
| 923 return m_isUARule && matchesSpatialNavigationFocusPseudoClass(element); | 926 return m_isUARule && matchesSpatialNavigationFocusPseudoClass(element); |
| 924 case CSSSelector::PseudoListBox: | 927 case CSSSelector::PseudoListBox: |
| 925 return m_isUARule && matchesListBoxPseudoClass(element); | 928 return m_isUARule && matchesListBoxPseudoClass(element); |
| 926 case CSSSelector::PseudoHostHasAppearance: | 929 case CSSSelector::PseudoHostHasAppearance: |
| 927 if (!m_isUARule) | 930 if (!m_isUARule) |
| 928 return false; | 931 return false; |
| (...skipping 228 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1157 } | 1160 } |
| 1158 | 1161 |
| 1159 bool SelectorChecker::matchesFocusPseudoClass(const Element& element) | 1162 bool SelectorChecker::matchesFocusPseudoClass(const Element& element) |
| 1160 { | 1163 { |
| 1161 if (InspectorInstrumentation::forcePseudoState(const_cast<Element*>(&element
), CSSSelector::PseudoFocus)) | 1164 if (InspectorInstrumentation::forcePseudoState(const_cast<Element*>(&element
), CSSSelector::PseudoFocus)) |
| 1162 return true; | 1165 return true; |
| 1163 return element.focused() && isFrameFocused(element); | 1166 return element.focused() && isFrameFocused(element); |
| 1164 } | 1167 } |
| 1165 | 1168 |
| 1166 } // namespace blink | 1169 } // namespace blink |
| OLD | NEW |