-
kov@webkit.org authored
https://bugs.webkit.org/show_bug.cgi?id=63994 Patch by Gustavo Noronha Silva <gns@gnome.org> on 2011-07-11 Reviewed by Xan Lopez. Further special-case Google Calendar, for it thinks WebKit+Linux means mobile, so we also have to spoof the OS. * WebCoreSupport/FrameLoaderClientGtk.cpp: (WebKit::FrameLoaderClient::userAgent): use the new WebKitGTK+ private API that centralizes the logic now. * tests/testwebsettings.c: Add tests to make sure the Google special-cases only apply for the expected domains and when quirks special-casing is enabled. (test_non_quirky_user_agents): (test_webkit_web_settings_user_agent): * webkit/webkitwebsettings.cpp: (webkitUserAgent): make it static. (safariUserAgent): returns a fake Safari in Mac OS X User-Agent. (initializeDomainsList): moved from FrameLoaderClientGtk. (isGoogleDomain):ditto. (isGoogleCalendar): ditto. (userAgentForURL): ditto. (webkitWebSettingsUserAgentForUri): centralize the whole user agent spoofing logic in this new private API that can be used by the browser to know what's going to happen for a specific URI and also allows our API testing. * webkit/webkitwebsettingsprivate.h: git-svn-id: http://svn.webkit.org/repository/webkit/trunk@91253 268f45cc-cd09-0410-ab3c-d52691b4dbfc
adab7955