- Revision
- 250142
- Author
- [email protected]
- Date
- 2019-09-20 13:10:37 -0700 (Fri, 20 Sep 2019)
Log Message
Remove some support for < iOS 13
https://bugs.webkit.org/show_bug.cgi?id=202032
<rdar://problem/55548468>
Reviewed by Alex Christensen.
Remove some support for iOS versions less than 13.0.
Update conditionals that reference __IPHONE_OS_VERSION_MIN_REQUIRED
and __IPHONE_OS_VERSION_MAX_ALLOWED, assuming that they both have
values >= 130000. This means that expressions like
"__IPHONE_OS_VERSION_MIN_REQUIRED < 101300" are always False and
"__IPHONE_OS_VERSION_MIN_REQUIRED >= 101300" are always True.
This removal is part of a series of patches effecting the removal of
dead code for old versions of iOS. This particular pass involves
changes in which Dan Bates was involved. These changes are isolated
from other similar changes in order to facilitate the reviewing
process.
Source/WebCore:
No new tests -- no new or changed functionality.
* platform/network/cf/ResourceRequestCFNet.cpp:
(WebCore::ResourceRequest::doUpdatePlatformRequest):
(WebCore::ResourceRequest::doUpdateResourceRequest):
* platform/network/cocoa/CookieCocoa.mm:
(WebCore::Cookie::operator NSHTTPCookie * _Nullable const):
* platform/network/cocoa/ResourceRequestCocoa.mm:
(WebCore::ResourceRequest::doUpdateResourceRequest):
(WebCore::ResourceRequest::doUpdatePlatformRequest):
Source/WebKit:
* UIProcess/ios/WKContentViewInteraction.mm:
(-[WKContentView _interpretKeyEvent:isCharEvent:]):
Source/WebKitLegacy/mac:
* WebView/WebHTMLView.mm:
(-[WebHTMLView _handleEditingKeyEvent:]):
Modified Paths
Diff
Modified: trunk/Source/WebCore/ChangeLog (250141 => 250142)
--- trunk/Source/WebCore/ChangeLog 2019-09-20 19:47:19 UTC (rev 250141)
+++ trunk/Source/WebCore/ChangeLog 2019-09-20 20:10:37 UTC (rev 250142)
@@ -1,3 +1,36 @@
+2019-09-20 Keith Rollin <[email protected]>
+
+ Remove some support for < iOS 13
+ https://bugs.webkit.org/show_bug.cgi?id=202032
+ <rdar://problem/55548468>
+
+ Reviewed by Alex Christensen.
+
+ Remove some support for iOS versions less than 13.0.
+
+ Update conditionals that reference __IPHONE_OS_VERSION_MIN_REQUIRED
+ and __IPHONE_OS_VERSION_MAX_ALLOWED, assuming that they both have
+ values >= 130000. This means that expressions like
+ "__IPHONE_OS_VERSION_MIN_REQUIRED < 101300" are always False and
+ "__IPHONE_OS_VERSION_MIN_REQUIRED >= 101300" are always True.
+
+ This removal is part of a series of patches effecting the removal of
+ dead code for old versions of iOS. This particular pass involves
+ changes in which Dan Bates was involved. These changes are isolated
+ from other similar changes in order to facilitate the reviewing
+ process.
+
+ No new tests -- no new or changed functionality.
+
+ * platform/network/cf/ResourceRequestCFNet.cpp:
+ (WebCore::ResourceRequest::doUpdatePlatformRequest):
+ (WebCore::ResourceRequest::doUpdateResourceRequest):
+ * platform/network/cocoa/CookieCocoa.mm:
+ (WebCore::Cookie::operator NSHTTPCookie * _Nullable const):
+ * platform/network/cocoa/ResourceRequestCocoa.mm:
+ (WebCore::ResourceRequest::doUpdateResourceRequest):
+ (WebCore::ResourceRequest::doUpdatePlatformRequest):
+
2019-09-20 Truitt Savell <[email protected]>
Unreviewed, rolling out r250114.
Modified: trunk/Source/WebCore/platform/network/cf/ResourceRequestCFNet.cpp (250141 => 250142)
--- trunk/Source/WebCore/platform/network/cf/ResourceRequestCFNet.cpp 2019-09-20 19:47:19 UTC (rev 250141)
+++ trunk/Source/WebCore/platform/network/cf/ResourceRequestCFNet.cpp 2019-09-20 20:10:37 UTC (rev 250142)
@@ -157,7 +157,7 @@
}
}
-#if PLATFORM(IOS_FAMILY) && __IPHONE_OS_VERSION_MIN_REQUIRED >= 120000
+#if PLATFORM(IOS_FAMILY)
static CFURLRef siteForCookies(ResourceRequest::SameSiteDisposition disposition, CFURLRef url)
{
switch (disposition) {
@@ -200,7 +200,7 @@
CFURLRequestSetShouldHandleHTTPCookies(cfRequest, allowCookies());
-#if PLATFORM(IOS_FAMILY) && __IPHONE_OS_VERSION_MIN_REQUIRED >= 120000
+#if PLATFORM(IOS_FAMILY)
_CFURLRequestSetProtocolProperty(cfRequest, CFSTR("_kCFHTTPCookiePolicyPropertySiteForCookies"), siteForCookies(m_sameSiteDisposition, url.get()));
int isTopSite = m_isTopSite;
@@ -285,7 +285,7 @@
if (resourcePrioritiesEnabled())
m_priority = toResourceLoadPriority(CFURLRequestGetRequestPriority(m_cfRequest.get()));
-#if PLATFORM(IOS_FAMILY) && __IPHONE_OS_VERSION_MIN_REQUIRED >= 120000
+#if PLATFORM(IOS_FAMILY)
RetainPtr<CFURLRef> siteForCookies = adoptCF(checked_cf_cast<CFURLRef>(_CFURLRequestCopyProtocolPropertyForKey(m_cfRequest.get(), CFSTR("_kCFHTTPCookiePolicyPropertySiteForCookies"))));
m_sameSiteDisposition = !siteForCookies ? SameSiteDisposition::Unspecified : (areRegistrableDomainsEqual(siteForCookies.get(), m_url) ? SameSiteDisposition::SameSite : SameSiteDisposition::CrossSite);
Modified: trunk/Source/WebCore/platform/network/cocoa/CookieCocoa.mm (250141 => 250142)
--- trunk/Source/WebCore/platform/network/cocoa/CookieCocoa.mm 2019-09-20 19:47:19 UTC (rev 250141)
+++ trunk/Source/WebCore/platform/network/cocoa/CookieCocoa.mm 2019-09-20 20:10:37 UTC (rev 250142)
@@ -29,7 +29,7 @@
// FIXME: Remove NS_ASSUME_NONNULL_BEGIN/END and all _Nullable annotations once we remove the NSHTTPCookie forward declaration below.
NS_ASSUME_NONNULL_BEGIN
-#if (PLATFORM(MAC) && __MAC_OS_X_VERSION_MIN_REQUIRED >= 101400 && __MAC_OS_X_VERSION_MAX_ALLOWED < 101500) || (PLATFORM(IOS_FAMILY) && __IPHONE_OS_VERSION_MIN_REQUIRED >= 120000 && __IPHONE_OS_VERSION_MAX_ALLOWED < 130000)
+#if (PLATFORM(MAC) && __MAC_OS_X_VERSION_MIN_REQUIRED >= 101400 && __MAC_OS_X_VERSION_MAX_ALLOWED < 101500)
typedef NSString * NSHTTPCookieStringPolicy;
@interface NSHTTPCookie (Staging)
@property (nullable, readonly, copy) NSHTTPCookieStringPolicy sameSitePolicy;
@@ -84,7 +84,7 @@
return 0;
}
-#if (PLATFORM(MAC) && __MAC_OS_X_VERSION_MIN_REQUIRED >= 101400) || (PLATFORM(IOS_FAMILY) && __IPHONE_OS_VERSION_MIN_REQUIRED >= 120000)
+#if (PLATFORM(MAC) && __MAC_OS_X_VERSION_MIN_REQUIRED >= 101400) || PLATFORM(IOS_FAMILY)
static Cookie::SameSitePolicy coreSameSitePolicy(NSHTTPCookieStringPolicy _Nullable policy)
{
if (!policy)
@@ -128,7 +128,7 @@
, commentURL { cookie.commentURL }
, ports { portVectorFromList(cookie.portList) }
{
-#if (PLATFORM(MAC) && __MAC_OS_X_VERSION_MIN_REQUIRED >= 101400) || (PLATFORM(IOS_FAMILY) && __IPHONE_OS_VERSION_MIN_REQUIRED >= 120000)
+#if (PLATFORM(MAC) && __MAC_OS_X_VERSION_MIN_REQUIRED >= 101400) || PLATFORM(IOS_FAMILY)
ALLOW_NEW_API_WITHOUT_GUARDS_BEGIN
if ([cookie respondsToSelector:@selector(sameSitePolicy)])
sameSite = coreSameSitePolicy(cookie.sameSitePolicy);
@@ -166,7 +166,7 @@
if (maxAge > 0)
[properties setObject:[NSString stringWithFormat:@"%f", maxAge] forKey:NSHTTPCookieMaximumAge];
-#if (PLATFORM(MAC) && __MAC_OS_X_VERSION_MIN_REQUIRED >= 101400) || (PLATFORM(IOS_FAMILY) && __IPHONE_OS_VERSION_MIN_REQUIRED >= 120000)
+#if (PLATFORM(MAC) && __MAC_OS_X_VERSION_MIN_REQUIRED >= 101400) || PLATFORM(IOS_FAMILY)
[properties setObject:[NSNumber numberWithDouble:created / 1000.0 - NSTimeIntervalSince1970] forKey:@"Created"];
#endif
Modified: trunk/Source/WebCore/platform/network/cocoa/ResourceRequestCocoa.mm (250141 => 250142)
--- trunk/Source/WebCore/platform/network/cocoa/ResourceRequestCocoa.mm 2019-09-20 19:47:19 UTC (rev 250141)
+++ trunk/Source/WebCore/platform/network/cocoa/ResourceRequestCocoa.mm 2019-09-20 20:10:37 UTC (rev 250142)
@@ -88,7 +88,7 @@
m_timeoutInterval = [m_nsRequest.get() timeoutInterval];
m_firstPartyForCookies = [m_nsRequest.get() mainDocumentURL];
-#if (PLATFORM(MAC) && __MAC_OS_X_VERSION_MIN_REQUIRED >= 101400) || (PLATFORM(IOS_FAMILY) && __IPHONE_OS_VERSION_MIN_REQUIRED >= 120000)
+#if (PLATFORM(MAC) && __MAC_OS_X_VERSION_MIN_REQUIRED >= 101400) || PLATFORM(IOS_FAMILY)
URL siteForCookies { [m_nsRequest.get() _propertyForKey:@"_kCFHTTPCookiePolicyPropertySiteForCookies"] };
m_sameSiteDisposition = siteForCookies.isNull() ? SameSiteDisposition::Unspecified : (areRegistrableDomainsEqual(siteForCookies, m_url) ? SameSiteDisposition::SameSite : SameSiteDisposition::CrossSite);
@@ -137,7 +137,7 @@
}
}
-#if (PLATFORM(MAC) && __MAC_OS_X_VERSION_MIN_REQUIRED >= 101400) || (PLATFORM(IOS_FAMILY) && __IPHONE_OS_VERSION_MIN_REQUIRED >= 120000)
+#if (PLATFORM(MAC) && __MAC_OS_X_VERSION_MIN_REQUIRED >= 101400) || PLATFORM(IOS_FAMILY)
static NSURL *siteForCookies(ResourceRequest::SameSiteDisposition disposition, NSURL *url)
{
switch (disposition) {
@@ -185,7 +185,7 @@
[nsRequest setHTTPMethod:httpMethod()];
[nsRequest setHTTPShouldHandleCookies:allowCookies()];
-#if (PLATFORM(MAC) && __MAC_OS_X_VERSION_MIN_REQUIRED >= 101400) || (PLATFORM(IOS_FAMILY) && __IPHONE_OS_VERSION_MIN_REQUIRED >= 120000)
+#if (PLATFORM(MAC) && __MAC_OS_X_VERSION_MIN_REQUIRED >= 101400) || PLATFORM(IOS_FAMILY)
[nsRequest _setProperty:siteForCookies(m_sameSiteDisposition, nsRequest.URL) forKey:@"_kCFHTTPCookiePolicyPropertySiteForCookies"];
[nsRequest _setProperty:[NSNumber numberWithBool:m_isTopSite] forKey:@"_kCFHTTPCookiePolicyPropertyIsTopLevelNavigation"];
#endif
Modified: trunk/Source/WebKit/ChangeLog (250141 => 250142)
--- trunk/Source/WebKit/ChangeLog 2019-09-20 19:47:19 UTC (rev 250141)
+++ trunk/Source/WebKit/ChangeLog 2019-09-20 20:10:37 UTC (rev 250142)
@@ -1,6 +1,31 @@
2019-09-20 Keith Rollin <[email protected]>
Remove some support for < iOS 13
+ https://bugs.webkit.org/show_bug.cgi?id=202032
+ <rdar://problem/55548468>
+
+ Reviewed by Alex Christensen.
+
+ Remove some support for iOS versions less than 13.0.
+
+ Update conditionals that reference __IPHONE_OS_VERSION_MIN_REQUIRED
+ and __IPHONE_OS_VERSION_MAX_ALLOWED, assuming that they both have
+ values >= 130000. This means that expressions like
+ "__IPHONE_OS_VERSION_MIN_REQUIRED < 101300" are always False and
+ "__IPHONE_OS_VERSION_MIN_REQUIRED >= 101300" are always True.
+
+ This removal is part of a series of patches effecting the removal of
+ dead code for old versions of iOS. This particular pass involves
+ changes in which Dan Bates was involved. These changes are isolated
+ from other similar changes in order to facilitate the reviewing
+ process.
+
+ * UIProcess/ios/WKContentViewInteraction.mm:
+ (-[WKContentView _interpretKeyEvent:isCharEvent:]):
+
+2019-09-20 Keith Rollin <[email protected]>
+
+ Remove some support for < iOS 13
https://bugs.webkit.org/show_bug.cgi?id=201973
<rdar://problem/55506966>
Modified: trunk/Source/WebKit/UIProcess/ios/WKContentViewInteraction.mm (250141 => 250142)
--- trunk/Source/WebKit/UIProcess/ios/WKContentViewInteraction.mm 2019-09-20 19:47:19 UTC (rev 250141)
+++ trunk/Source/WebKit/UIProcess/ios/WKContentViewInteraction.mm 2019-09-20 20:10:37 UTC (rev 250142)
@@ -4860,12 +4860,10 @@
UIKeyboardImpl *keyboard = [UIKeyboardImpl sharedInstance];
-#if __IPHONE_OS_VERSION_MIN_REQUIRED >= 130000
if (!isCharEvent && [keyboard respondsToSelector:@selector(handleKeyTextCommandForCurrentEvent)] && [keyboard handleKeyTextCommandForCurrentEvent])
return YES;
if (isCharEvent && [keyboard respondsToSelector:@selector(handleKeyAppCommandForCurrentEvent)] && [keyboard handleKeyAppCommandForCurrentEvent])
return YES;
-#endif
// Don't insert character for an unhandled Command-key key command. This matches iOS and Mac platform conventions.
if (event.modifierFlags & WebEventFlagMaskCommandKey)
Modified: trunk/Source/WebKitLegacy/mac/ChangeLog (250141 => 250142)
--- trunk/Source/WebKitLegacy/mac/ChangeLog 2019-09-20 19:47:19 UTC (rev 250141)
+++ trunk/Source/WebKitLegacy/mac/ChangeLog 2019-09-20 20:10:37 UTC (rev 250142)
@@ -1,3 +1,28 @@
+2019-09-20 Keith Rollin <[email protected]>
+
+ Remove some support for < iOS 13
+ https://bugs.webkit.org/show_bug.cgi?id=202032
+ <rdar://problem/55548468>
+
+ Reviewed by Alex Christensen.
+
+ Remove some support for iOS versions less than 13.0.
+
+ Update conditionals that reference __IPHONE_OS_VERSION_MIN_REQUIRED
+ and __IPHONE_OS_VERSION_MAX_ALLOWED, assuming that they both have
+ values >= 130000. This means that expressions like
+ "__IPHONE_OS_VERSION_MIN_REQUIRED < 101300" are always False and
+ "__IPHONE_OS_VERSION_MIN_REQUIRED >= 101300" are always True.
+
+ This removal is part of a series of patches effecting the removal of
+ dead code for old versions of iOS. This particular pass involves
+ changes in which Dan Bates was involved. These changes are isolated
+ from other similar changes in order to facilitate the reviewing
+ process.
+
+ * WebView/WebHTMLView.mm:
+ (-[WebHTMLView _handleEditingKeyEvent:]):
+
2019-09-18 Jer Noble <[email protected]>
Add -suspend and -resumeAllMediaPlayback to WebView
Modified: trunk/Source/WebKitLegacy/mac/WebView/WebHTMLView.mm (250141 => 250142)
--- trunk/Source/WebKitLegacy/mac/WebView/WebHTMLView.mm 2019-09-20 19:47:19 UTC (rev 250141)
+++ trunk/Source/WebKitLegacy/mac/WebView/WebHTMLView.mm 2019-09-20 20:10:37 UTC (rev 250142)
@@ -6070,12 +6070,10 @@
bool isCharEvent = platformEvent->type() == PlatformKeyboardEvent::Char;
-#if __IPHONE_OS_VERSION_MIN_REQUIRED >= 130000
if (!isCharEvent && [webView._UIKitDelegateForwarder handleKeyTextCommandForCurrentEvent])
return YES;
if (isCharEvent && [webView._UIKitDelegateForwarder handleKeyAppCommandForCurrentEvent])
return YES;
-#endif
NSString *s = [event characters];
if (!s.length)