NEW 39789
Change ViewportArguments to use ChromeClient::platformScreenSize instead of ChromeClient::windowRect
https://bugs.webkit.org/show_bug.cgi?id=39789
Summary Change ViewportArguments to use ChromeClient::platformScreenSize instead of C...
Daniel Bates
Reported 2010-05-26 15:04:23 PDT
From my understanding of the viewport section of the Apple Safari HTML Reference <http://developer.apple.com/safari/library/documentation/appleapplications/reference/safarihtmlref/Articles/MetaTags.html#//apple_ref/doc/uid/TP40008193-SW6>, device-width and device-height are constants with respect to the width and height of the screen in direction north (e.g. portrait orientation for the iPhone). And the screen size for the device may not be equivalent to the size of the window rect We should add methods, say, ChromeClient::platformScreenSize, and ChromeClient::setPlatformScreenSize so that the client can provide the dimensions of the screen in direction north so that ViewportArguments can use these dimensions for the value of device-width and device-height.
Attachments
Patch (4.36 KB, patch)
2010-05-26 15:09 PDT, Daniel Bates
no flags
Patch (4.52 KB, patch)
2010-05-26 15:44 PDT, Daniel Bates
no flags
Daniel Bates
Comment 1 2010-05-26 15:09:13 PDT
Created attachment 57166 [details] Patch By default, platformScreenSize returns an empty IntSize(). Clients should override this is they are implementing support for the viewport meta tag.
Daniel Bates
Comment 2 2010-05-26 15:44:10 PDT
Created attachment 57174 [details] Patch Added missing #include ChromeClient.h
Eric Seidel (no email)
Comment 3 2010-05-26 15:45:50 PDT
Early Warning System Bot
Comment 4 2010-05-26 15:49:11 PDT
Eric Seidel (no email)
Comment 5 2010-06-04 23:05:25 PDT
Comment on attachment 57174 [details] Patch How do we test this?
Daniel Bates
Comment 6 2010-06-06 10:13:02 PDT
(In reply to comment #5) > (From update of attachment 57174 [details]) > How do we test this? We cannot test this at this time. We need to add DRT support. Notice, this patch is abstracting the platform screen size (which may be different from the dimensions of the window rectangle) and which will differ on each platform that chooses to implement ViewportArguments support (by implementing method ChromeClient::didReceiveViewportArguments).
Daniel Bates
Comment 7 2010-06-18 11:23:30 PDT
Comment on attachment 57174 [details] Patch Clearing review flag to think about this some more.
Note You need to log in before you can comment on or make changes to this bug.