<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[248578] branches/safari-608-branch/Source</title>
</head>
<body>
<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; }
#msg dl a { font-weight: bold}
#msg dl a:link { color:#fc3; }
#msg dl a:active { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://trac.webkit.org/projects/webkit/changeset/248578">248578</a></dd>
<dt>Author</dt> <dd>alancoon@apple.com</dd>
<dt>Date</dt> <dd>2019-08-12 16:42:52 -0700 (Mon, 12 Aug 2019)</dd>
</dl>
<h3>Log Message</h3>
<pre>Cherry-pick <a href="http://trac.webkit.org/projects/webkit/changeset/248501">r248501</a>. rdar://problem/54130614
[iOS] Add a quirk for gmail.com messages on iPhone iOS13
https://bugs.webkit.org/show_bug.cgi?id=200605
Patch by Said Abou-Hallawa <sabouhallawa@apple.com> on 2019-08-10
Reviewed by Maciej Stachowiak.
Source/WebCore:
Add a quirk which sets the user agent for gmail.com messages on iPhone
OS 13 to be iPhone OS 12. This is a workaround for a gmail.com bug till
it is fixed.
* page/Quirks.cpp:
(WebCore::Quirks::shouldAvoidUsingIOS13ForGmail const):
* page/Quirks.h:
* platform/UserAgent.h:
* platform/ios/UserAgentIOS.mm:
(WebCore::osNameForUserAgent):
(WebCore::standardUserAgentWithApplicationName):
* platform/mac/UserAgentMac.mm:
(WebCore::standardUserAgentWithApplicationName):
Source/WebKit:
Use WebPage::platformUserAgent() to add the gmail.com quirk.
* UIProcess/ios/WebPageProxyIOS.mm:
(WebKit::WebPageProxy::effectiveContentModeAfterAdjustingPolicies):
* WebProcess/WebPage/ios/WebPageIOS.mm:
(WebKit::WebPage::platformUserAgent const):
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@248501 268f45cc-cd09-0410-ab3c-d52691b4dbfc</pre>
<h3>Modified Paths</h3>
<ul>
<li><a href="#branchessafari608branchSourceWebCoreChangeLog">branches/safari-608-branch/Source/WebCore/ChangeLog</a></li>
<li><a href="#branchessafari608branchSourceWebCorepageQuirkscpp">branches/safari-608-branch/Source/WebCore/page/Quirks.cpp</a></li>
<li><a href="#branchessafari608branchSourceWebCorepageQuirksh">branches/safari-608-branch/Source/WebCore/page/Quirks.h</a></li>
<li><a href="#branchessafari608branchSourceWebCoreplatformUserAgenth">branches/safari-608-branch/Source/WebCore/platform/UserAgent.h</a></li>
<li><a href="#branchessafari608branchSourceWebCoreplatformiosUserAgentIOSmm">branches/safari-608-branch/Source/WebCore/platform/ios/UserAgentIOS.mm</a></li>
<li><a href="#branchessafari608branchSourceWebCoreplatformmacUserAgentMacmm">branches/safari-608-branch/Source/WebCore/platform/mac/UserAgentMac.mm</a></li>
<li><a href="#branchessafari608branchSourceWebKitChangeLog">branches/safari-608-branch/Source/WebKit/ChangeLog</a></li>
<li><a href="#branchessafari608branchSourceWebKitUIProcessiosWebPageProxyIOSmm">branches/safari-608-branch/Source/WebKit/UIProcess/ios/WebPageProxyIOS.mm</a></li>
<li><a href="#branchessafari608branchSourceWebKitWebProcessWebPageiosWebPageIOSmm">branches/safari-608-branch/Source/WebKit/WebProcess/WebPage/ios/WebPageIOS.mm</a></li>
</ul>
</div>
<div id="patch">
<h3>Diff</h3>
<a id="branchessafari608branchSourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: branches/safari-608-branch/Source/WebCore/ChangeLog (248577 => 248578)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-608-branch/Source/WebCore/ChangeLog 2019-08-12 23:42:48 UTC (rev 248577)
+++ branches/safari-608-branch/Source/WebCore/ChangeLog 2019-08-12 23:42:52 UTC (rev 248578)
</span><span class="lines">@@ -1,5 +1,63 @@
</span><span class="cx"> 2019-08-12 Alan Coon <alancoon@apple.com>
</span><span class="cx">
</span><ins>+ Cherry-pick r248501. rdar://problem/54130614
+
+ [iOS] Add a quirk for gmail.com messages on iPhone iOS13
+ https://bugs.webkit.org/show_bug.cgi?id=200605
+
+ Patch by Said Abou-Hallawa <sabouhallawa@apple.com> on 2019-08-10
+ Reviewed by Maciej Stachowiak.
+
+ Source/WebCore:
+
+ Add a quirk which sets the user agent for gmail.com messages on iPhone
+ OS 13 to be iPhone OS 12. This is a workaround for a gmail.com bug till
+ it is fixed.
+
+ * page/Quirks.cpp:
+ (WebCore::Quirks::shouldAvoidUsingIOS13ForGmail const):
+ * page/Quirks.h:
+ * platform/UserAgent.h:
+ * platform/ios/UserAgentIOS.mm:
+ (WebCore::osNameForUserAgent):
+ (WebCore::standardUserAgentWithApplicationName):
+ * platform/mac/UserAgentMac.mm:
+ (WebCore::standardUserAgentWithApplicationName):
+
+ Source/WebKit:
+
+ Use WebPage::platformUserAgent() to add the gmail.com quirk.
+
+ * UIProcess/ios/WebPageProxyIOS.mm:
+ (WebKit::WebPageProxy::effectiveContentModeAfterAdjustingPolicies):
+ * WebProcess/WebPage/ios/WebPageIOS.mm:
+ (WebKit::WebPage::platformUserAgent const):
+
+ git-svn-id: https://svn.webkit.org/repository/webkit/trunk@248501 268f45cc-cd09-0410-ab3c-d52691b4dbfc
+
+ 2019-08-10 Said Abou-Hallawa <sabouhallawa@apple.com>
+
+ [iOS] Add a quirk for gmail.com messages on iPhone iOS13
+ https://bugs.webkit.org/show_bug.cgi?id=200605
+
+ Reviewed by Maciej Stachowiak.
+
+ Add a quirk which sets the user agent for gmail.com messages on iPhone
+ OS 13 to be iPhone OS 12. This is a workaround for a gmail.com bug till
+ it is fixed.
+
+ * page/Quirks.cpp:
+ (WebCore::Quirks::shouldAvoidUsingIOS13ForGmail const):
+ * page/Quirks.h:
+ * platform/UserAgent.h:
+ * platform/ios/UserAgentIOS.mm:
+ (WebCore::osNameForUserAgent):
+ (WebCore::standardUserAgentWithApplicationName):
+ * platform/mac/UserAgentMac.mm:
+ (WebCore::standardUserAgentWithApplicationName):
+
+2019-08-12 Alan Coon <alancoon@apple.com>
+
</ins><span class="cx"> Cherry-pick r248494. rdar://problem/54171876
</span><span class="cx">
</span><span class="cx"> Universal XSS in JSObject::putInlineSlow and JSValue::putToPrimitive
</span></span></pre></div>
<a id="branchessafari608branchSourceWebCorepageQuirkscpp"></a>
<div class="modfile"><h4>Modified: branches/safari-608-branch/Source/WebCore/page/Quirks.cpp (248577 => 248578)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-608-branch/Source/WebCore/page/Quirks.cpp 2019-08-12 23:42:48 UTC (rev 248577)
+++ branches/safari-608-branch/Source/WebCore/page/Quirks.cpp 2019-08-12 23:42:52 UTC (rev 248578)
</span><span class="lines">@@ -35,6 +35,7 @@
</span><span class="cx"> #include "HTMLObjectElement.h"
</span><span class="cx"> #include "LayoutUnit.h"
</span><span class="cx"> #include "Settings.h"
</span><ins>+#include "UserAgent.h"
</ins><span class="cx">
</span><span class="cx"> namespace WebCore {
</span><span class="cx">
</span><span class="lines">@@ -230,6 +231,19 @@
</span><span class="cx"> #endif
</span><span class="cx"> }
</span><span class="cx">
</span><ins>+bool Quirks::shouldAvoidUsingIOS13ForGmail() const
+{
+#if PLATFORM(IOS_FAMILY)
+ if (!needsQuirks())
+ return false;
+
+ auto& url = m_document->topDocument().url();
+ return equalLettersIgnoringASCIICase(url.host(), "mail.google.com");
+#else
+ return false;
+#endif
+}
+
</ins><span class="cx"> bool Quirks::shouldSuppressAutocorrectionAndAutocaptializationInHiddenEditableAreas() const
</span><span class="cx"> {
</span><span class="cx"> if (!needsQuirks())
</span></span></pre></div>
<a id="branchessafari608branchSourceWebCorepageQuirksh"></a>
<div class="modfile"><h4>Modified: branches/safari-608-branch/Source/WebCore/page/Quirks.h (248577 => 248578)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-608-branch/Source/WebCore/page/Quirks.h 2019-08-12 23:42:48 UTC (rev 248577)
+++ branches/safari-608-branch/Source/WebCore/page/Quirks.h 2019-08-12 23:42:52 UTC (rev 248578)
</span><span class="lines">@@ -69,6 +69,8 @@
</span><span class="cx"> WEBCORE_EXPORT bool shouldAvoidScrollingWhenFocusedContentIsVisible() const;
</span><span class="cx">
</span><span class="cx"> WEBCORE_EXPORT bool needsYouTubeMouseOutQuirk() const;
</span><ins>+
+ WEBCORE_EXPORT bool shouldAvoidUsingIOS13ForGmail() const;
</ins><span class="cx">
</span><span class="cx"> bool needsGMailOverflowScrollQuirk() const;
</span><span class="cx"> bool needsYouTubeOverflowScrollQuirk() const;
</span></span></pre></div>
<a id="branchessafari608branchSourceWebCoreplatformUserAgenth"></a>
<div class="modfile"><h4>Modified: branches/safari-608-branch/Source/WebCore/platform/UserAgent.h (248577 => 248578)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-608-branch/Source/WebCore/platform/UserAgent.h 2019-08-12 23:42:48 UTC (rev 248577)
+++ branches/safari-608-branch/Source/WebCore/platform/UserAgent.h 2019-08-12 23:42:52 UTC (rev 248578)
</span><span class="lines">@@ -32,9 +32,10 @@
</span><span class="cx">
</span><span class="cx"> #if PLATFORM(COCOA)
</span><span class="cx"> enum class UserAgentType { Default, Desktop };
</span><del>-WEBCORE_EXPORT String standardUserAgentWithApplicationName(const String& applicationName, UserAgentType = UserAgentType::Default);
</del><ins>+WEBCORE_EXPORT String standardUserAgentWithApplicationName(const String& applicationName, const String& userAgentOSVersion = emptyString(), UserAgentType = UserAgentType::Default);
</ins><span class="cx">
</span><del>-String systemMarketingVersionForUserAgentString();
</del><ins>+WEBCORE_EXPORT String osNameForUserAgent();
+WEBCORE_EXPORT String systemMarketingVersionForUserAgentString();
</ins><span class="cx"> #else
</span><span class="cx">
</span><span class="cx"> WEBCORE_EXPORT String standardUserAgent(const String& applicationName = emptyString(), const String& applicationVersion = emptyString());
</span></span></pre></div>
<a id="branchessafari608branchSourceWebCoreplatformiosUserAgentIOSmm"></a>
<div class="modfile"><h4>Modified: branches/safari-608-branch/Source/WebCore/platform/ios/UserAgentIOS.mm (248577 => 248578)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-608-branch/Source/WebCore/platform/ios/UserAgentIOS.mm 2019-08-12 23:42:48 UTC (rev 248577)
+++ branches/safari-608-branch/Source/WebCore/platform/ios/UserAgentIOS.mm 2019-08-12 23:42:52 UTC (rev 248578)
</span><span class="lines">@@ -52,7 +52,7 @@
</span><span class="cx"> return isClassic() && [PAL::getUIApplicationClass() _classicMode] != UIApplicationSceneClassicModeOriginalPad;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-static inline String osNameForUserAgent()
</del><ins>+String osNameForUserAgent()
</ins><span class="cx"> {
</span><span class="cx"> if (deviceHasIPadCapability() && !isClassicPhone())
</span><span class="cx"> return "OS";
</span><span class="lines">@@ -79,7 +79,7 @@
</span><span class="cx"> return name;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-String standardUserAgentWithApplicationName(const String& applicationName, UserAgentType type)
</del><ins>+String standardUserAgentWithApplicationName(const String& applicationName, const String& userAgentOSVersion, UserAgentType type)
</ins><span class="cx"> {
</span><span class="cx"> if (type == UserAgentType::Desktop) {
</span><span class="cx"> String appNameSuffix = applicationName.isEmpty() ? "" : makeString(" ", applicationName);
</span><span class="lines">@@ -95,7 +95,7 @@
</span><span class="cx"> CFRelease(override);
</span><span class="cx"> }
</span><span class="cx">
</span><del>- String osVersion = systemMarketingVersionForUserAgentString();
</del><ins>+ String osVersion = userAgentOSVersion.isEmpty() ? systemMarketingVersionForUserAgentString() : userAgentOSVersion;
</ins><span class="cx"> String appNameSuffix = applicationName.isEmpty() ? "" : makeString(" ", applicationName);
</span><span class="cx">
</span><span class="cx"> return makeString("Mozilla/5.0 (", deviceNameForUserAgent(), "; CPU ", osNameForUserAgent(), " ", osVersion, " like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko)", appNameSuffix);
</span></span></pre></div>
<a id="branchessafari608branchSourceWebCoreplatformmacUserAgentMacmm"></a>
<div class="modfile"><h4>Modified: branches/safari-608-branch/Source/WebCore/platform/mac/UserAgentMac.mm (248577 => 248578)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-608-branch/Source/WebCore/platform/mac/UserAgentMac.mm 2019-08-12 23:42:48 UTC (rev 248577)
+++ branches/safari-608-branch/Source/WebCore/platform/mac/UserAgentMac.mm 2019-08-12 23:42:52 UTC (rev 248578)
</span><span class="lines">@@ -32,7 +32,7 @@
</span><span class="cx">
</span><span class="cx"> namespace WebCore {
</span><span class="cx">
</span><del>-String standardUserAgentWithApplicationName(const String& applicationName, UserAgentType)
</del><ins>+String standardUserAgentWithApplicationName(const String& applicationName, const String&, UserAgentType)
</ins><span class="cx"> {
</span><span class="cx"> String osVersion = systemMarketingVersionForUserAgentString();
</span><span class="cx"> String appNameSuffix = applicationName.isEmpty() ? "" : makeString(" ", applicationName);
</span></span></pre></div>
<a id="branchessafari608branchSourceWebKitChangeLog"></a>
<div class="modfile"><h4>Modified: branches/safari-608-branch/Source/WebKit/ChangeLog (248577 => 248578)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-608-branch/Source/WebKit/ChangeLog 2019-08-12 23:42:48 UTC (rev 248577)
+++ branches/safari-608-branch/Source/WebKit/ChangeLog 2019-08-12 23:42:52 UTC (rev 248578)
</span><span class="lines">@@ -1,5 +1,56 @@
</span><span class="cx"> 2019-08-12 Alan Coon <alancoon@apple.com>
</span><span class="cx">
</span><ins>+ Cherry-pick r248501. rdar://problem/54130614
+
+ [iOS] Add a quirk for gmail.com messages on iPhone iOS13
+ https://bugs.webkit.org/show_bug.cgi?id=200605
+
+ Patch by Said Abou-Hallawa <sabouhallawa@apple.com> on 2019-08-10
+ Reviewed by Maciej Stachowiak.
+
+ Source/WebCore:
+
+ Add a quirk which sets the user agent for gmail.com messages on iPhone
+ OS 13 to be iPhone OS 12. This is a workaround for a gmail.com bug till
+ it is fixed.
+
+ * page/Quirks.cpp:
+ (WebCore::Quirks::shouldAvoidUsingIOS13ForGmail const):
+ * page/Quirks.h:
+ * platform/UserAgent.h:
+ * platform/ios/UserAgentIOS.mm:
+ (WebCore::osNameForUserAgent):
+ (WebCore::standardUserAgentWithApplicationName):
+ * platform/mac/UserAgentMac.mm:
+ (WebCore::standardUserAgentWithApplicationName):
+
+ Source/WebKit:
+
+ Use WebPage::platformUserAgent() to add the gmail.com quirk.
+
+ * UIProcess/ios/WebPageProxyIOS.mm:
+ (WebKit::WebPageProxy::effectiveContentModeAfterAdjustingPolicies):
+ * WebProcess/WebPage/ios/WebPageIOS.mm:
+ (WebKit::WebPage::platformUserAgent const):
+
+ git-svn-id: https://svn.webkit.org/repository/webkit/trunk@248501 268f45cc-cd09-0410-ab3c-d52691b4dbfc
+
+ 2019-08-10 Said Abou-Hallawa <sabouhallawa@apple.com>
+
+ [iOS] Add a quirk for gmail.com messages on iPhone iOS13
+ https://bugs.webkit.org/show_bug.cgi?id=200605
+
+ Reviewed by Maciej Stachowiak.
+
+ Use WebPage::platformUserAgent() to add the gmail.com quirk.
+
+ * UIProcess/ios/WebPageProxyIOS.mm:
+ (WebKit::WebPageProxy::effectiveContentModeAfterAdjustingPolicies):
+ * WebProcess/WebPage/ios/WebPageIOS.mm:
+ (WebKit::WebPage::platformUserAgent const):
+
+2019-08-12 Alan Coon <alancoon@apple.com>
+
</ins><span class="cx"> Cherry-pick r248481. rdar://problem/54130658
</span><span class="cx">
</span><span class="cx"> [iOS WK2] Remove context menu hints on navigation
</span></span></pre></div>
<a id="branchessafari608branchSourceWebKitUIProcessiosWebPageProxyIOSmm"></a>
<div class="modfile"><h4>Modified: branches/safari-608-branch/Source/WebKit/UIProcess/ios/WebPageProxyIOS.mm (248577 => 248578)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-608-branch/Source/WebKit/UIProcess/ios/WebPageProxyIOS.mm 2019-08-12 23:42:48 UTC (rev 248577)
+++ branches/safari-608-branch/Source/WebKit/UIProcess/ios/WebPageProxyIOS.mm 2019-08-12 23:42:52 UTC (rev 248578)
</span><span class="lines">@@ -1409,7 +1409,7 @@
</span><span class="cx"> auto applicationName = policies.applicationNameForDesktopUserAgent();
</span><span class="cx"> if (applicationName.isEmpty())
</span><span class="cx"> applicationName = applicationNameForDesktopUserAgent();
</span><del>- policies.setCustomUserAgent(standardUserAgentWithApplicationName(applicationName, UserAgentType::Desktop));
</del><ins>+ policies.setCustomUserAgent(standardUserAgentWithApplicationName(applicationName, emptyString(), UserAgentType::Desktop));
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> if (policies.customNavigatorPlatform().isEmpty()) {
</span></span></pre></div>
<a id="branchessafari608branchSourceWebKitWebProcessWebPageiosWebPageIOSmm"></a>
<div class="modfile"><h4>Modified: branches/safari-608-branch/Source/WebKit/WebProcess/WebPage/ios/WebPageIOS.mm (248577 => 248578)</h4>
<pre class="diff"><span>
<span class="info">--- branches/safari-608-branch/Source/WebKit/WebProcess/WebPage/ios/WebPageIOS.mm 2019-08-12 23:42:48 UTC (rev 248577)
+++ branches/safari-608-branch/Source/WebKit/WebProcess/WebPage/ios/WebPageIOS.mm 2019-08-12 23:42:52 UTC (rev 248578)
</span><span class="lines">@@ -123,6 +123,7 @@
</span><span class="cx"> #import <WebCore/StyleProperties.h>
</span><span class="cx"> #import <WebCore/TextIndicator.h>
</span><span class="cx"> #import <WebCore/TextIterator.h>
</span><ins>+#import <WebCore/UserAgent.h>
</ins><span class="cx"> #import <WebCore/VisibleUnits.h>
</span><span class="cx"> #import <WebCore/WebEvent.h>
</span><span class="cx"> #import <wtf/MathExtras.h>
</span><span class="lines">@@ -3783,6 +3784,16 @@
</span><span class="cx">
</span><span class="cx"> String WebPage::platformUserAgent(const URL&) const
</span><span class="cx"> {
</span><ins>+ if (!m_page->settings().needsSiteSpecificQuirks())
+ return String();
+
+ auto document = m_mainFrame->coreFrame()->document();
+ if (!document)
+ return String();
+
+ if (document->quirks().shouldAvoidUsingIOS13ForGmail() && osNameForUserAgent() == "iPhone OS" && systemMarketingVersionForUserAgentString() == "13_1")
+ return standardUserAgentWithApplicationName({ }, "12_1_3");
+
</ins><span class="cx"> return String();
</span><span class="cx"> }
</span><span class="cx">
</span></span></pre>
</div>
</div>
</body>
</html>