[Webkit-unassigned] [Bug 126103] New: StyleResolver::pseudoStyleForElement don't call initElement(0) before return
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Fri Dec 20 18:24:55 PST 2013
https://bugs.webkit.org/show_bug.cgi?id=126103
Summary: StyleResolver::pseudoStyleForElement don't call
initElement(0) before return
Product: WebKit
Version: 528+ (Nightly build)
Platform: All
OS/Version: All
Status: NEW
Severity: Minor
Priority: P4
Component: WebCore Misc.
AssignedTo: webkit-unassigned at lists.webkit.org
ReportedBy: xxhforest at gmail.com
1, Summary
this may cause EInsideLink status of RenderStyle generated by StyleResolver::styleForElement be incorrect
2, Simple Example
<head>
<style>
a:after {
content:""
}
</style>
</head>
<body>
<a id="test" href="#test" style="overflow:hidden">
click me
</a>
3, Steps
1) open the above simple example in a mobile browser
2) click the anchor element in the above example
4, Issue
the anchor element will not be marked as visited
5, Conclusion
At first, WebCore recieve a touch event, and StyleResolver::pseudoStyleForElement was triggered.
Before pseudoStyleForElement return, initElement(0) is not called, so the anchor element is cached
in StyleResolver
Then, WebCore receive a mouse click event, so it is added to visited link list in PageGroup, and its
RenderStyle is recalculate. StyleResolver::styleForElement is call to give the RenderStyle, but initElement(element)
will do nothing, because the element is cached. so the anchor element's visited status will not be detected, and m_elementLinkState
will not be set to InsideVisitedLink.
finially the anchor element will not be marked as visited
6, Expect
call initElement(0) before StyleResolver::pseudoStyleForElement return to clear cache to element
--
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
More information about the webkit-unassigned
mailing list