Title: [226452] trunk/Source
Revision
226452
Author
m...@apple.com
Date
2018-01-05 10:43:41 -0800 (Fri, 05 Jan 2018)

Log Message

Fixed the build following AppKit API deprecations in a recent SDKs

Source/WebCore:

* platform/mac/PasteboardMac.mm:
(WebCore::setDragImageImpl): Suppressed deprecation warnings.
* platform/mac/WidgetMac.mm:
(WebCore::Widget::paint): Ditto.

Source/WebKitLegacy/mac:

* WebView/WebFullScreenController.mm:
(-[WebFullScreenController enterFullScreen:]): Suppressed deprecation warnings.
(-[WebFullScreenController exitFullScreen]): Ditto.
(-[WebFullScreenController _startEnterFullScreenAnimationWithDuration:]): Ditto.
(-[WebFullScreenController _startExitFullScreenAnimationWithDuration:]): Ditto.
* WebView/WebHTMLView.mm:
(-[WebHTMLView drawRect:]): Ditto.
(-[WebHTMLView _endPrintModeAndRestoreWindowAutodisplay]): Ditto.
(-[WebHTMLView knowsPageRange:]): Ditto.
* WebView/WebView.mm:
(LayerFlushController::flushLayers): Ditto.

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (226451 => 226452)


--- trunk/Source/WebCore/ChangeLog	2018-01-05 18:14:15 UTC (rev 226451)
+++ trunk/Source/WebCore/ChangeLog	2018-01-05 18:43:41 UTC (rev 226452)
@@ -1,3 +1,12 @@
+2018-01-05  Dan Bernstein  <m...@apple.com>
+
+        Fixed the build following AppKit API deprecations in a recent SDKs
+
+        * platform/mac/PasteboardMac.mm:
+        (WebCore::setDragImageImpl): Suppressed deprecation warnings.
+        * platform/mac/WidgetMac.mm:
+        (WebCore::Widget::paint): Ditto.
+
 2018-01-05  Joseph Pecoraro  <pecor...@apple.com>
 
         ServiceWorkers: Enable UserTiming / ResourceTiming

Modified: trunk/Source/WebCore/platform/mac/PasteboardMac.mm (226451 => 226452)


--- trunk/Source/WebCore/platform/mac/PasteboardMac.mm	2018-01-05 18:14:15 UTC (rev 226451)
+++ trunk/Source/WebCore/platform/mac/PasteboardMac.mm	2018-01-05 18:43:41 UTC (rev 226452)
@@ -596,7 +596,10 @@
     RetainPtr<NSBitmapImageRep> bitmapImage;
     if (!imageRep || ![imageRep isKindOfClass:[NSBitmapImageRep class]] || !NSEqualSizes(imageRep.size, imageSize)) {
         [image lockFocus];
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wdeprecated-declarations"
         bitmapImage = adoptNS([[NSBitmapImageRep alloc] initWithFocusedViewRect:*(NSRect*)&imageRect]);
+#pragma clang diagnostic pop
         [image unlockFocus];
         
         // we may have to flip the bits we just read if the image was flipped since it means the cache was also

Modified: trunk/Source/WebCore/platform/mac/WidgetMac.mm (226451 => 226452)


--- trunk/Source/WebCore/platform/mac/WidgetMac.mm	2018-01-05 18:14:15 UTC (rev 226451)
+++ trunk/Source/WebCore/platform/mac/WidgetMac.mm	2018-01-05 18:43:41 UTC (rev 226452)
@@ -206,7 +206,10 @@
     Ref<Widget> protectedThis(*this);
 
     NSGraphicsContext *currentContext = [NSGraphicsContext currentContext];
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wdeprecated-declarations"
     if (currentContext == [[view window] graphicsContext] || ![currentContext isDrawingToScreen]) {
+#pragma clang diagnostic pop
         // This is the common case of drawing into a window or an inclusive layer, or printing.
         BEGIN_BLOCK_OBJC_EXCEPTIONS;
         [view displayRectIgnoringOpacity:[view convertRect:r fromView:[view superview]]];

Modified: trunk/Source/WebKitLegacy/mac/ChangeLog (226451 => 226452)


--- trunk/Source/WebKitLegacy/mac/ChangeLog	2018-01-05 18:14:15 UTC (rev 226451)
+++ trunk/Source/WebKitLegacy/mac/ChangeLog	2018-01-05 18:43:41 UTC (rev 226452)
@@ -1,3 +1,19 @@
+2018-01-05  Dan Bernstein  <m...@apple.com>
+
+        Fixed the build following AppKit API deprecations in a recent SDKs
+
+        * WebView/WebFullScreenController.mm:
+        (-[WebFullScreenController enterFullScreen:]): Suppressed deprecation warnings.
+        (-[WebFullScreenController exitFullScreen]): Ditto.
+        (-[WebFullScreenController _startEnterFullScreenAnimationWithDuration:]): Ditto.
+        (-[WebFullScreenController _startExitFullScreenAnimationWithDuration:]): Ditto.
+        * WebView/WebHTMLView.mm:
+        (-[WebHTMLView drawRect:]): Ditto.
+        (-[WebHTMLView _endPrintModeAndRestoreWindowAutodisplay]): Ditto.
+        (-[WebHTMLView knowsPageRange:]): Ditto.
+        * WebView/WebView.mm:
+        (LayerFlushController::flushLayers): Ditto.
+
 2018-01-03  Wenson Hsieh  <wenson_hs...@apple.com>
 
         [Attachment Support] Create attachment elements when dropping files on iOS

Modified: trunk/Source/WebKitLegacy/mac/WebView/WebFullScreenController.mm (226451 => 226452)


--- trunk/Source/WebKitLegacy/mac/WebView/WebFullScreenController.mm	2018-01-05 18:14:15 UTC (rev 226451)
+++ trunk/Source/WebKitLegacy/mac/WebView/WebFullScreenController.mm	2018-01-05 18:43:41 UTC (rev 226452)
@@ -208,8 +208,11 @@
     
     // Screen updates to be re-enabled in beganEnterFullScreenWithInitialFrame:finalFrame:
     NSDisableScreenUpdates();
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wdeprecated-declarations"
     [[self window] setAutodisplay:NO];
-    
+#pragma clang diagnostic pop
+
     NSResponder *webWindowFirstResponder = [[_webView window] firstResponder];
     [[self window] setFrame:screenFrame display:NO];
 
@@ -308,7 +311,10 @@
     
     // Screen updates to be re-enabled in beganExitFullScreenWithInitialFrame:finalFrame:
     NSDisableScreenUpdates();
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wdeprecated-declarations"
     [[self window] setAutodisplay:NO];
+#pragma clang diagnostic pop
 
     _finalFrame = screenRectOfContents(_element.get());
 
@@ -525,7 +531,10 @@
     
     [_backgroundWindow.get() orderWindow:NSWindowBelow relativeTo:[[self window] windowNumber]];
     
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wdeprecated-declarations"
     [[self window] setAutodisplay:YES];
+#pragma clang diagnostic pop
     [[self window] displayIfNeeded];
     // Screen updates disabled in enterFullScreen:
     NSEnableScreenUpdates();
@@ -573,7 +582,10 @@
 #pragma clang diagnostic pop
     setClipRectForWindow(self.window, finalBounds);
     
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wdeprecated-declarations"
     [[self window] setAutodisplay:YES];
+#pragma clang diagnostic pop
     [[self window] displayIfNeeded];
 
     // Screen updates disabled in exitFullScreen:

Modified: trunk/Source/WebKitLegacy/mac/WebView/WebHTMLView.mm (226451 => 226452)


--- trunk/Source/WebKitLegacy/mac/WebView/WebHTMLView.mm	2018-01-05 18:14:15 UTC (rev 226451)
+++ trunk/Source/WebKitLegacy/mac/WebView/WebHTMLView.mm	2018-01-05 18:43:41 UTC (rev 226452)
@@ -3975,7 +3975,10 @@
 #if PLATFORM(MAC)
     // Only do the synchronization dance if we're drawing into the window, otherwise
     // we risk disabling screen updates when no flush is pending.
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wdeprecated-declarations"
     if ([NSGraphicsContext currentContext] == [[self window] graphicsContext] && [webView _needsOneShotDrawingSynchronization]) {
+#pragma clang diagnostic pop
         // Disable screen updates to minimize the chances of the race between the CA
         // display link and AppKit drawing causing flashes.
         [[self window] disableScreenUpdatesUntilFlush];
@@ -4794,7 +4797,10 @@
 - (void)_endPrintModeAndRestoreWindowAutodisplay
 {
     [self _endPrintMode];
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wdeprecated-declarations"
     [[self window] setAutodisplay:YES];
+#pragma clang diagnostic pop
 }
 
 - (void)_delayedEndPrintMode:(NSPrintOperation *)initiatingOperation
@@ -4829,7 +4835,10 @@
     // Must do this explicit display here, because otherwise the view might redisplay while the print
     // sheet was up, using printer fonts (and looking different).
     [self displayIfNeeded];
-    [[self window] setAutodisplay:NO];    
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wdeprecated-declarations"
+    [[self window] setAutodisplay:NO];
+#pragma clang diagnostic pop
 
     [[self _webView] _adjustPrintingMarginsForHeaderAndFooter];
     NSPrintOperation *printOperation = [NSPrintOperation currentOperation];

Modified: trunk/Source/WebKitLegacy/mac/WebView/WebView.mm (226451 => 226452)


--- trunk/Source/WebKitLegacy/mac/WebView/WebView.mm	2018-01-05 18:14:15 UTC (rev 226451)
+++ trunk/Source/WebKitLegacy/mac/WebView/WebView.mm	2018-01-05 18:43:41 UTC (rev 226452)
@@ -9182,7 +9182,10 @@
         // AppKit may have disabled screen updates, thinking an upcoming window flush will re-enable them.
         // In case setNeedsDisplayInRect() has prevented the window from needing to be flushed, re-enable screen
         // updates here.
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wdeprecated-declarations"
         if (![window isFlushWindowDisabled])
+#pragma clang diagnostic pop
             [window _enableScreenUpdatesIfNeeded];
 #endif
 
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to