Title: [220429] trunk/Source/WebKitLegacy/mac
- Revision
- 220429
- Author
- beid...@apple.com
- Date
- 2017-08-08 16:53:04 -0700 (Tue, 08 Aug 2017)
Log Message
Don't enable default icon loading in WK1 for apps linked against old SDKs.
<rdar://problem/33724060> and https://bugs.webkit.org/show_bug.cgi?id=175342
Reviewed by Andy Estes.
* Misc/WebKitVersionChecks.h:
* WebCoreSupport/WebFrameLoaderClient.mm:
(WebFrameLoaderClient::getLoadDecisionForIcons): Don't do any icon loading unless
the app is linked against new WebKit with the new behavior.
Modified Paths
Diff
Modified: trunk/Source/WebKitLegacy/mac/ChangeLog (220428 => 220429)
--- trunk/Source/WebKitLegacy/mac/ChangeLog 2017-08-08 23:36:49 UTC (rev 220428)
+++ trunk/Source/WebKitLegacy/mac/ChangeLog 2017-08-08 23:53:04 UTC (rev 220429)
@@ -1,3 +1,15 @@
+2017-08-08 Brady Eidson <beid...@apple.com>
+
+ Don't enable default icon loading in WK1 for apps linked against old SDKs.
+ <rdar://problem/33724060> and https://bugs.webkit.org/show_bug.cgi?id=175342
+
+ Reviewed by Andy Estes.
+
+ * Misc/WebKitVersionChecks.h:
+ * WebCoreSupport/WebFrameLoaderClient.mm:
+ (WebFrameLoaderClient::getLoadDecisionForIcons): Don't do any icon loading unless
+ the app is linked against new WebKit with the new behavior.
+
2017-08-07 Devin Rousso <drou...@apple.com>
Web Inspector: Preview Canvas path when viewing a recording
Modified: trunk/Source/WebKitLegacy/mac/Misc/WebKitVersionChecks.h (220428 => 220429)
--- trunk/Source/WebKitLegacy/mac/Misc/WebKitVersionChecks.h 2017-08-08 23:36:49 UTC (rev 220428)
+++ trunk/Source/WebKitLegacy/mac/Misc/WebKitVersionChecks.h 2017-08-08 23:53:04 UTC (rev 220429)
@@ -61,6 +61,8 @@
#define WEBKIT_FIRST_VERSION_WITH_CSS_ATTRIBUTE_SETTERS_IGNORING_PRIORITY 0x02170D00 // 535.13.0
#define WEBKIT_FIRST_VERSION_WITHOUT_LEGACY_BACKGROUNDSIZE_SHORTHAND_BEHAVIOR 0x02190100 // 537.1.0
#define WEBKIT_FIRST_VERSION_WITH_INSECURE_CONTENT_BLOCKING 0x02590116 // 601.1.22
+#define WEBKIT_FIRST_VERSION_WITH_DEFAULT_ICON_LOADING 0x025C0126 // 604.1.38
+
#else
// <rdar://problem/6627758> Need to implement WebKitLinkedOnOrAfter
// Actually UIKit version numbers, since applications don't link against WebKit
Modified: trunk/Source/WebKitLegacy/mac/WebCoreSupport/WebFrameLoaderClient.mm (220428 => 220429)
--- trunk/Source/WebKitLegacy/mac/WebCoreSupport/WebFrameLoaderClient.mm 2017-08-08 23:36:49 UTC (rev 220428)
+++ trunk/Source/WebKitLegacy/mac/WebCoreSupport/WebFrameLoaderClient.mm 2017-08-08 23:53:04 UTC (rev 220429)
@@ -54,6 +54,7 @@
#import "WebKitErrorsPrivate.h"
#import "WebKitLogging.h"
#import "WebKitNSStringExtras.h"
+#import "WebKitVersionChecks.h"
#import "WebNSURLExtras.h"
#import "WebNavigationData.h"
#import "WebNetscapePluginPackage.h"
@@ -142,7 +143,6 @@
#import <WebCore/WAKScrollView.h>
#import <WebCore/WAKWindow.h>
#import <WebCore/WebCoreThreadMessage.h>
-#import "WebKitVersionChecks.h"
#import "WebMailDelegate.h"
#import "WebUIKitDelegate.h"
#endif
@@ -2280,6 +2280,15 @@
DocumentLoader* documentLoader = frame->loader().documentLoader();
ASSERT(documentLoader);
+#if PLATFORM(MAC)
+ if (!WebKitLinkedOnOrAfter(WEBKIT_FIRST_VERSION_WITH_DEFAULT_ICON_LOADING)) {
+ for (auto& icon : icons)
+ documentLoader->didGetLoadDecisionForIcon(false, icon.second, 0);
+
+ return;
+ }
+#endif
+
bool disallowedDueToImageLoadSettings = false;
if (!frame->settings().loadsImagesAutomatically() && !frame->settings().loadsSiteIconsIgnoringImageLoadingSetting())
disallowedDueToImageLoadSettings = true;
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes