Summary: | [iOS][WK2] Add SPI to handle animated resize | ||||||
---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Benjamin Poulain <benjamin> | ||||
Component: | New Bugs | Assignee: | Benjamin Poulain <benjamin> | ||||
Status: | RESOLVED FIXED | ||||||
Severity: | Normal | CC: | andersca, mitz, sam, simon.fraser, thorton | ||||
Priority: | P2 | ||||||
Version: | 528+ (Nightly build) | ||||||
Hardware: | Unspecified | ||||||
OS: | Unspecified | ||||||
Attachments: |
|
Description
Benjamin Poulain
2014-04-02 18:35:16 PDT
Created attachment 228453 [details]
Patch
Comment on attachment 228453 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=228453&action=review > Source/WebKit2/UIProcess/API/Cocoa/WKWebView.mm:181 > + [self _frameOrBoundsChangedFrom:self.bounds]; This is a bit weird. Maybe from:CGZeroRect? > Source/WebKit2/UIProcess/API/Cocoa/WKWebView.mm:447 > + // FIXME: animated resize is gonna be a lot of fun. Some properties need to be updated live, others need to be stored > + // for the end of the animation. I don't think this comment is useful. > Source/WebKit2/UIProcess/API/Cocoa/WKWebView.mm:683 > + CGFloat oldWebViewWidhtInContentCoordinate = oldBounds.size.width / contentZoomScale(self); "Widht". Coordinates. > Source/WebKit2/UIProcess/API/Cocoa/WKWebView.mm:686 > + CGFloat visibleWebPageWidthInContentCoordinate = std::min([_contentView bounds].size.width, oldWebViewWidhtInContentCoordinate); > + CGFloat targetScale = bounds.size.width / visibleWebPageWidthInContentCoordinate; > + [_scrollView setZoomScale:targetScale]; I'm not really sure what you're trying to do here. Comment on attachment 228453 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=228453&action=review > Source/WebKit2/UIProcess/API/Cocoa/WKWebView.mm:683 > + CGFloat oldWebViewWidhtInContentCoordinate = oldBounds.size.width / contentZoomScale(self); typo "Widht" > Source/WebKit2/UIProcess/API/Cocoa/WKWebView.mm:684 > + CGFloat visibleWebPageWidthInContentCoordinate = std::min([_contentView bounds].size.width, oldWebViewWidhtInContentCoordinate); "WebPage"? > Source/WebKit2/UIProcess/API/Cocoa/WKWebView.mm:1160 > + // FIXME: send a single message to the WebProcess to layout and repaint instead. capitals at the beginning of a sentence Committed r166750: <http://trac.webkit.org/changeset/166750> |