The change should be adopted for WebKit 1 as well: http://trac.webkit.org/changeset/107017 Without this, deviceScaleFactor will not be initialized until viewDidMoveToWindow, which is quite late for a background tab. <rdar://problem/11322716> Patch forthcoming.
Created attachment 138907 [details] Patch
Comment on attachment 138907 [details] Patch OK
One difference with WebKit1 is that we have the “host window” concept. The host window should be set quite early for a background tab. I’d think we could change things so that a WebView that gets a host window could set its scale factor appropriately based on the host window.
Created attachment 138913 [details] Patch that uses hostWindow instead
Comment on attachment 138913 [details] Patch that uses hostWindow instead This looks good. But for applications that don’t use a host window, I think we want the union of your previous patch and this one. I think we need both!
Committed both: http://trac.webkit.org/changeset/115271