Bug 181125

Summary: WKWebView's didMoveToWindow doesn't call it's super
Product: WebKit Reporter: Gabriel Banfalvi <gbanfalvi>
Component: WebKit2Assignee: Nobody <webkit-unassigned>
Status: NEW    
Severity: Normal CC: mitz, simon.fraser, thorton, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: Safari 11   
Hardware: iPhone / iPad   
OS: All   

Gabriel Banfalvi
Reported 2017-12-22 04:18:23 PST
WKWebView doesn't call UIView's (it's super-class') didMoveToWindow despite overriding it. It looks like this in UIProcess/API/Cocoa/WKWebView.mm - (void)didMoveToWindow { _page->activityStateDidChange(WebCore::ActivityState::AllFlags); } While in principle didMoveToWindow tends to be empty, I'm swizzling out will/didMoveToWindow on UIView to track hierarchy changes in UIViews (haven't found a better way to do that), and this breaks that.
Attachments
Radar WebKit Bug Importer
Comment 1 2017-12-22 12:44:02 PST
Note You need to log in before you can comment on or make changes to this bug.