We need a expose a preference which allows us to control the fps of web content updates.
Created attachment 295919 [details] Patch
Comment on attachment 295919 [details] Patch I think this should be a private WKWebViewConfiguration parameter instead. It's set-once, and shouldn't be adjustable by apps.
rdar://problem/27928609
Created attachment 296029 [details] Patch
Comment on attachment 296029 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=296029&action=review > Source/WebKit2/UIProcess/API/APIPageConfiguration.h:122 > + uint32_t m_contentUpdateFrequency = 0; modern style would be uint32_t m_contentUpdateFrequency { 0 } > Source/WebKit2/UIProcess/API/Cocoa/WKWebViewConfiguration.mm:480 > +- (NSNumber *)_contentUpdateFrequency Why is this still NSNumber? NSUInteger or unsigned or something, no need for the boxing. > Source/WebKit2/UIProcess/mac/RemoteLayerTreeDrawingAreaProxy.mm:139 > +uint32_t RemoteLayerTreeDrawingAreaProxy::contentUpdateFrequency() const Isn't this code compiled on Mac?
Created attachment 296031 [details] Patch
Comment on attachment 296029 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=296029&action=review >> Source/WebKit2/UIProcess/API/APIPageConfiguration.h:122 >> + uint32_t m_contentUpdateFrequency = 0; > > modern style would be uint32_t m_contentUpdateFrequency { 0 } Fixed. >> Source/WebKit2/UIProcess/API/Cocoa/WKWebViewConfiguration.mm:480 >> +- (NSNumber *)_contentUpdateFrequency > > Why is this still NSNumber? NSUInteger or unsigned or something, no need for the boxing. I changed it to NSUInteger. >> Source/WebKit2/UIProcess/mac/RemoteLayerTreeDrawingAreaProxy.mm:139 >> +uint32_t RemoteLayerTreeDrawingAreaProxy::contentUpdateFrequency() const > > Isn't this code compiled on Mac? Yes, you are right. I kept the function but I make it return a 0 for Mac. This is to avoid adding if the header file and WKOneShotDisplayLinkHandler initWithDrawingAreaProxy function.
(In reply to comment #7) > Comment on attachment 296029 [details] > Patch > > View in context: > https://bugs.webkit.org/attachment.cgi?id=296029&action=review > > >> Source/WebKit2/UIProcess/API/APIPageConfiguration.h:122 > >> + uint32_t m_contentUpdateFrequency = 0; > > > > modern style would be uint32_t m_contentUpdateFrequency { 0 } > > Fixed. > > >> Source/WebKit2/UIProcess/API/Cocoa/WKWebViewConfiguration.mm:480 > >> +- (NSNumber *)_contentUpdateFrequency > > > > Why is this still NSNumber? NSUInteger or unsigned or something, no need for the boxing. > > I changed it to NSUInteger. OK. > >> Source/WebKit2/UIProcess/mac/RemoteLayerTreeDrawingAreaProxy.mm:139 > >> +uint32_t RemoteLayerTreeDrawingAreaProxy::contentUpdateFrequency() const > > > > Isn't this code compiled on Mac? > > Yes, you are right. I kept the function but I make it return a 0 for Mac. > This is to avoid adding if the header file and WKOneShotDisplayLinkHandler > initWithDrawingAreaProxy function. WKOneShotDisplayLinkHandler is already #if'd
Created attachment 296032 [details] Patch
Comment on attachment 296032 [details] Patch Clearing flags on attachment: 296032 Committed r209294: <http://trac.webkit.org/changeset/209294>
All reviewed patches have been landed. Closing bug.