⚠ Archived content — this site is no longer maintained.   Current WebKit documentation is at docs.webkit.org.

Timeline



Jun 10, 2018:

11:43 PM Changeset in webkit [232670] by Carlos Garcia Campos
  • 20 edits
    2 copies
    10 adds
    1 delete in trunk

[WPE] Add a MiniBrowser and use it to run WebDriver tests
https://bugs.webkit.org/show_bug.cgi?id=186345

Reviewed by Žan Doberšek.

.:

Add an option to enable building the MiniBrowser.

  • Source/cmake/FindWaylandProtocols.cmake: Added.
  • Source/cmake/OptionsWPE.cmake:

Source/WebDriver:

Use MiniBrowser instead of dyz as the default WebDriver browser for WPE.

  • wpe/WebDriverServiceWPE.cpp:

(WebDriver::WebDriverService::platformParseCapabilities const):

Tools:

Most of the code is based on dyz and gtk MiniBrowser. This patch adds a new internal library WPEToolingBackends,
including the headless view backend and a new window backend to be used by the MiniBrowser. MiniBrowser can also
run in headless mode, by using the headless backend instead of the window one, which will allow us to run the
WebDriver tests in the bots.

  • CMakeLists.txt:
  • MiniBrowser/wpe/CMakeLists.txt: Added.
  • MiniBrowser/wpe/main.cpp: Added.

(automationStartedCallback):
(createViewBackend):
(main):

  • Scripts/run-minibrowser: Remove WPE specific code.
  • Scripts/run-webdriver-tests: Add headless display-server option.
  • Scripts/webkitdirs.pm:

(launcherName): Remove WPE specific code.

  • Scripts/webkitpy/webdriver_tests/webdriver_driver_wpe.py:

(WebDriverWPE.browser_name): Return MiniBrowser.
(WebDriverWPE.browser_path): Return the path to the MiniBrowser in build dir.
(WebDriverWPE.browser_args): Add --headless when running in headless mode.
(WebDriverWPE.capabilities): Use the full browser path.

  • Scripts/webkitpy/webdriver_tests/webdriver_test_runner_selenium.py:

(WebDriverTestRunnerSelenium.collect_tests): Fix early return value.

  • TestWebKitAPI/PlatformWPE.cmake: Use WPEToolingBackends instead of HeadlessViewBackend.
  • TestWebKitAPI/PlatformWebView.h: Ditto.
  • TestWebKitAPI/glib/PlatformWPE.cmake: Ditto
  • TestWebKitAPI/glib/WebKitGLib/TestMain.h:

(Test::createWebViewBackend): Ditto.

  • TestWebKitAPI/wpe/PlatformWebViewWPE.cpp:

(TestWebKitAPI::PlatformWebView::initialize): Ditto.

  • WebKitTestRunner/PlatformWPE.cmake: Ditto.
  • WebKitTestRunner/PlatformWebView.h: Ditto.
  • WebKitTestRunner/wpe/PlatformWebViewWPE.cpp:

(WTR::PlatformWebView::PlatformWebView): Ditto.

  • wpe/HeadlessViewBackend/CMakeLists.txt: Removed.
  • wpe/backends/CMakeLists.txt: Added.
  • wpe/backends/HeadlessViewBackend.cpp: Renamed from Tools/wpe/HeadlessViewBackend/HeadlessViewBackend.cpp.

(WPEToolingBackends::getEGLDisplay):
(WPEToolingBackends::HeadlessViewBackend::HeadlessViewBackend):
(WPEToolingBackends::HeadlessViewBackend::~HeadlessViewBackend):
(WPEToolingBackends::HeadlessViewBackend::createSnapshot):
(WPEToolingBackends::HeadlessViewBackend::performUpdate):
(WPEToolingBackends::HeadlessViewBackend::displayBuffer):

  • wpe/backends/HeadlessViewBackend.h: Renamed from Tools/wpe/HeadlessViewBackend/HeadlessViewBackend.h.
  • wpe/backends/ViewBackend.cpp: Added.

(WPEToolingBackends::ViewBackend::ViewBackend):
(WPEToolingBackends::ViewBackend::~ViewBackend):
(WPEToolingBackends::ViewBackend::initialize):
(WPEToolingBackends::ViewBackend::setInputClient):
(WPEToolingBackends::ViewBackend::backend const):
(WPEToolingBackends::ViewBackend::dispatchInputPointerEvent):
(WPEToolingBackends::ViewBackend::dispatchInputAxisEvent):
(WPEToolingBackends::ViewBackend::dispatchInputKeyboardEvent):

  • wpe/backends/ViewBackend.h: Added.
  • wpe/backends/WindowViewBackend.cpp: Added.

(WPEToolingBackends::WindowViewBackend::WindowViewBackend):
(WPEToolingBackends::WindowViewBackend::~WindowViewBackend):
(WPEToolingBackends::WindowViewBackend::displayBuffer):
(WPEToolingBackends::WindowViewBackend::handleKeyEvent):

  • wpe/backends/WindowViewBackend.h: Added.
  • wpe/jhbuild.modules: Remove dyz and add wayland-protocols.
7:44 PM Changeset in webkit [232669] by Fujii Hironori
  • 17 edits
    2 moves in trunk/Tools

[Win][MiniBrowser] MiniBrowser class should be renamed to WebKitLegacyBrowserWindow
https://bugs.webkit.org/show_bug.cgi?id=186427

Reviewed by Ryosuke Niwa.

  • MiniBrowser/win/AccessibilityDelegate.cpp:
  • MiniBrowser/win/AccessibilityDelegate.h:

(AccessibilityDelegate::AccessibilityDelegate):

  • MiniBrowser/win/CMakeLists.txt: Removed MiniBrowser.cpp. Added WebKitLegacyBrowserWindow.cpp.
  • MiniBrowser/win/Common.h:
  • MiniBrowser/win/MainWindow.cpp:

(MainWindow::init):

  • MiniBrowser/win/MainWindow.h:
  • MiniBrowser/win/MiniBrowserWebHost.cpp:
  • MiniBrowser/win/MiniBrowserWebHost.h:

(MiniBrowserWebHost::MiniBrowserWebHost):

  • MiniBrowser/win/PageLoadTestClient.cpp:

(PageLoadTestClient::PageLoadTestClient):

  • MiniBrowser/win/PageLoadTestClient.h:
  • MiniBrowser/win/PrintWebUIDelegate.cpp:

(PrintWebUIDelegate::createWebViewWithRequest):

  • MiniBrowser/win/PrintWebUIDelegate.h:

(PrintWebUIDelegate::PrintWebUIDelegate):

  • MiniBrowser/win/ResourceLoadDelegate.cpp:
  • MiniBrowser/win/ResourceLoadDelegate.h:

(ResourceLoadDelegate::ResourceLoadDelegate):

  • MiniBrowser/win/WebKitLegacyBrowserWindow.cpp: Renamed from Tools/MiniBrowser/win/MiniBrowser.cpp.
  • MiniBrowser/win/WebKitLegacyBrowserWindow.h: Renamed from Tools/MiniBrowser/win/MiniBrowser.h.
  • MiniBrowser/win/WebDownloadDelegate.cpp:

(WebDownloadDelegate::WebDownloadDelegate):

  • MiniBrowser/win/WebDownloadDelegate.h:
3:39 PM Changeset in webkit [232668] by Chris Dumez
  • 12 edits in trunk

Reload the Web view in case of crash if the client does not implement webViewWebContentProcessDidTerminate delegate
https://bugs.webkit.org/show_bug.cgi?id=186468

Reviewed by Geoffrey Garen.

Source/WebKit:

We now attempt to reload the Web view if the web content process crashes and the client
does not implement the webViewWebContentProcessDidTerminate delegate (or any of the similar
delegates in our SPI).

  • UIProcess/API/APILoaderClient.h:

(API::LoaderClient::processDidCrash):

  • UIProcess/API/APINavigationClient.h:

(API::NavigationClient::processDidTerminate):

  • UIProcess/API/C/WKPage.cpp:

(WKPageSetPageLoaderClient):
(WKPageSetPageNavigationClient):

  • UIProcess/API/Cocoa/WKWebViewPrivate.h:
  • UIProcess/API/glib/WebKitNavigationClient.cpp:
  • UIProcess/Cocoa/NavigationState.h:
  • UIProcess/Cocoa/NavigationState.mm:

(WebKit::NavigationState::NavigationClient::processDidTerminate):

  • UIProcess/WebPageProxy.cpp:

(WebKit::m_resetRecentCrashCountTimer):
(WebKit::WebPageProxy::didFinishLoadForFrame):
(WebKit::shouldReloadAfterProcessTermination):
(WebKit::WebPageProxy::dispatchProcessDidTerminate):
(WebKit::WebPageProxy::tryReloadAfterProcessTermination):
(WebKit::WebPageProxy::resetRecentCrashCountSoon):
(WebKit::WebPageProxy::resetRecentCrashCount):
(WebKit::m_configurationPreferenceValues): Deleted.

  • UIProcess/WebPageProxy.h:

Tools:

Add API test coverage.

  • TestWebKitAPI/Tests/WebKitCocoa/WebContentProcessDidTerminate.mm:

(-[BasicNavigationDelegateWithoutCrashHandler webView:didStartProvisionalNavigation:]):
(-[BasicNavigationDelegateWithoutCrashHandler webView:didFinishNavigation:]):
(TEST):

9:12 AM WebKitGTK/2.20.x edited by Michael Catanzaro
(diff)
2:23 AM Changeset in webkit [232667] by Michael Catanzaro
  • 4 edits in trunk

[WPE][GTK] paypal.com requires user agent quirk
https://bugs.webkit.org/show_bug.cgi?id=186466

Reviewed by Carlos Garcia Campos.

Source/WebCore:

  • platform/UserAgentQuirks.cpp:

(WebCore::urlRequiresMacintoshPlatform):

Tools:

  • TestWebKitAPI/Tests/WebCore/UserAgentQuirks.cpp:

(TestWebKitAPI::TEST):

12:36 AM Changeset in webkit [232666] by Yusuke Suzuki
  • 6 edits
    1 delete in trunk

[JSC] Array.prototype.sort should rejects null comparator
https://bugs.webkit.org/show_bug.cgi?id=186458

Reviewed by Keith Miller.

JSTests:

  • ChakraCore/test/Array/array_sort.baseline-jsc:
  • stress/array-sort-bad-comparator.js:

(test):

  • stress/sort-null-comparator.js: Removed.
  • test262/expectations.yaml:

Source/JavaScriptCore:

This relaxed behavior is once introduced in r216169 to fix some pages by aligning
the behavior to Chrome and Firefox.

However, now Chrome, Firefox and Edge reject a null comparator. So only JavaScriptCore
accepts it. This patch reverts r216169 to align JSC to the other engines and fix
the spec issue.

  • builtins/ArrayPrototype.js:

(sort):

Jun 9, 2018:

10:18 PM Changeset in webkit [232665] by mitz@apple.com
  • 64 edits in trunk

[Xcode] Clean up and modernize some build setting definitions
https://bugs.webkit.org/show_bug.cgi?id=186463

Reviewed by Sam Weinig.

Source/bmalloc:

  • Configurations/Base.xcconfig: Removed definition for macOS 10.11.
  • Configurations/DebugRelease.xcconfig: Ditto.

Source/JavaScriptCore:

  • Configurations/Base.xcconfig: Removed definition for macOS 10.11. Simplified the definition of WK_PRIVATE_FRAMEWORK_STUBS_DIR now that WK_XCODE_SUPPORTS_TEXT_BASED_STUBS is true for all supported Xcode versions.
  • Configurations/DebugRelease.xcconfig: Removed definition for macOS 10.11.
  • Configurations/FeatureDefines.xcconfig: Simplified the definitions of ENABLE_APPLE_PAY and ENABLE_VIDEO_PRESENTATION_MODE now macOS 10.12 is the earliest supported version.
  • Configurations/Version.xcconfig: Removed definition for macOS 10.11.
  • Configurations/WebKitTargetConditionals.xcconfig: Removed definitions for macOS 10.11.

Source/ThirdParty/ANGLE:

  • Configurations/Base.xcconfig: Removed definition for macOS 10.11.
  • Configurations/DebugRelease.xcconfig: Ditto.

Source/ThirdParty/libwebrtc:

  • Configurations/Base.xcconfig: Removed definition for macOS 10.11.
  • Configurations/DebugRelease.xcconfig: Ditto.
  • Configurations/Version.xcconfig: Removed definitions for macOS 10.10 and 10.11, and added definitions for later versions.
  • Configurations/WebKitTargetConditionals.xcconfig: Removed definitions for macOS 10.11.
  • Configurations/opus.xcconfig: Simplified the definition of SSE4_FLAG now that macOS 10.12 is the earliest supported version.

Source/WebCore:

  • Configurations/Base.xcconfig: Removed definition for macOS 10.11.
  • Configurations/DebugRelease.xcconfig: Ditto.
  • Configurations/FeatureDefines.xcconfig: Simplified the definitions of ENABLE_APPLE_PAY and ENABLE_VIDEO_PRESENTATION_MODE now macOS 10.12 is the earliest supported version.
  • Configurations/Version.xcconfig: Removed definition for macOS 10.11.
  • Configurations/WebCore.xcconfig: Simplified the definition of WK_PRIVATE_FRAMEWORKS_DIR now that WK_XCODE_SUPPORTS_TEXT_BASED_STUBS is true for all supported Xcode versions.
  • Configurations/WebKitTargetConditionals.xcconfig: Removed definitions for macOS 10.11.

Source/WebCore/PAL:

  • Configurations/Base.xcconfig: Removed definition for macOS 10.11.
  • Configurations/DebugRelease.xcconfig: Ditto.
  • Configurations/FeatureDefines.xcconfig: Simplified the definitions of ENABLE_APPLE_PAY and ENABLE_VIDEO_PRESENTATION_MODE now macOS 10.12 is the earliest supported version.
  • Configurations/PAL.xcconfig: Removed WK_PRIVATE_FRAMEWORKS_DIR, because the private framework stubs aren’t used when linking PAL.
  • Configurations/Version.xcconfig: Removed definition for macOS 10.11.
  • Configurations/WebKitTargetConditionals.xcconfig: Ditto.

Source/WebInspectorUI:

  • Configurations/Base.xcconfig: Removed definition for macOS 10.11.
  • Configurations/DebugRelease.xcconfig: Ditto.
  • Configurations/Version.xcconfig: Ditto.

Source/WebKit:

  • Configurations/Base.xcconfig: Removed definition for macOS 10.11.
  • Configurations/BaseTarget.xcconfig: Simplified the definition of WK_PRIVATE_FRAMEWORKS_DIR now that WK_XCODE_SUPPORTS_TEXT_BASED_STUBS is true for all supported Xcode versions.
  • Configurations/DebugRelease.xcconfig: Removed definition for macOS 10.11.
  • Configurations/FeatureDefines.xcconfig: Simplified the definitions of ENABLE_APPLE_PAY and ENABLE_VIDEO_PRESENTATION_MODE now macOS 10.12 is the earliest supported version.
  • Configurations/Version.xcconfig: Removed definition for macOS 10.11.
  • Configurations/WebKitTargetConditionals.xcconfig: Removed definitions for macOS 10.11.

Source/WebKitLegacy/mac:

  • Configurations/Base.xcconfig: Removed definition for macOS 10.11.
  • Configurations/DebugRelease.xcconfig: Ditto.
  • Configurations/FeatureDefines.xcconfig: Simplified the definitions of ENABLE_APPLE_PAY and ENABLE_VIDEO_PRESENTATION_MODE now macOS 10.12 is the earliest supported version.
  • Configurations/Version.xcconfig: Removed definition for macOS 10.11.
  • Configurations/WebKitLegacy.xcconfig: Simplified the definition of WK_PRIVATE_FRAMEWORKS_DIR now that WK_XCODE_SUPPORTS_TEXT_BASED_STUBS is true for all supported Xcode versions.
  • Configurations/WebKitTargetConditionals.xcconfig: Removed definitions for macOS 10.11.

Source/WTF:

  • Configurations/Base.xcconfig: Removed definition for macOS 10.11.
  • Configurations/DebugRelease.xcconfig: Ditto.

Tools:

  • DumpRenderTree/mac/Configurations/Base.xcconfig: Removed definition for macOS 10.11. Simplified the definition of WK_PRIVATE_FRAMEWORK_STUBS_DIR now that WK_XCODE_SUPPORTS_TEXT_BASED_STUBS is true for all supported Xcode versions.
  • DumpRenderTree/mac/Configurations/DebugRelease.xcconfig: Removed definition for macOS 10.11.
  • MiniBrowser/Configurations/Base.xcconfig: Ditto.
  • MiniBrowser/Configurations/DebugRelease.xcconfig: Ditto.
  • TestWebKitAPI/Configurations/Base.xcconfig: Ditto.
  • TestWebKitAPI/Configurations/DebugRelease.xcconfig: Ditto.
  • TestWebKitAPI/Configurations/FeatureDefines.xcconfig: Simplified the definitions of ENABLE_APPLE_PAY and ENABLE_VIDEO_PRESENTATION_MODE now macOS 10.12 is the earliest supported version.
  • TestWebKitAPI/Configurations/WebKitTargetConditionals.xcconfig: Removed definitions for macOS 10.11.
  • WebKitTestRunner/Configurations/Base.xcconfig: Ditto. Also simplified the definition of WK_PRIVATE_FRAMEWORK_STUBS_DIR now that WK_XCODE_SUPPORTS_TEXT_BASED_STUBS is true for all supported Xcode versions
  • WebKitTestRunner/Configurations/DebugRelease.xcconfig: Removed definition for macOS 10.11.
6:33 PM Changeset in webkit [232664] by mitz@apple.com
  • 14 edits in trunk

Added missing file references to the Configuration group.

Source/JavaScriptCore:

Source/ThirdParty/libwebrtc:

  • libwebrtc.xcodeproj/project.pbxproj:

Source/WebCore:

  • WebCore.xcodeproj/project.pbxproj:

Source/WebCore/PAL:

  • PAL.xcodeproj/project.pbxproj:

Source/WebKit:

  • WebKit.xcodeproj/project.pbxproj:

Source/WebKitLegacy:

  • WebKitLegacy.xcodeproj/project.pbxproj:

Tools:

  • TestWebKitAPI/TestWebKitAPI.xcodeproj/project.pbxproj:
6:26 PM Changeset in webkit [232663] by Alan Bujtas
  • 4 edits
    2 adds in trunk

REGRESSION (r230480): Cannot adjust photo position on LinkedIn's profile page
https://bugs.webkit.org/show_bug.cgi?id=186464
<rdar://problem/40369448>

Reviewed by Simon Fraser.

Source/WebCore:

The optimization logic for skipping image layout when we only need overflow computation should check if the image actually needs
simplified layout only. The needsSimplifiedNormalFlowLayout() flag means that the overflow information needs to be updated but
it does not mean that overflow is the only property that we need to recompute.

Test: fast/images/positioned-image-when-transform-is-present.html

  • rendering/RenderImage.cpp:

(WebCore::RenderImage::layout):

  • rendering/RenderObject.h:

(WebCore::RenderObject::needsSimplifiedNormalFlowLayoutOnly const):

LayoutTests:

  • fast/images/positioned-image-when-transform-is-present-expected.html: Added.
  • fast/images/positioned-image-when-transform-is-present.html: Added.
1:15 PM Changeset in webkit [232662] by rniwa@webkit.org
  • 7 edits in trunk

REGRESSION(macOS Mojave): move-by-word-visually-multi-line.html fails
https://bugs.webkit.org/show_bug.cgi?id=186454

Reviewed by Darin Adler.

Source/WebCore:

Like r232635, this patch fixes a selection test failure caused by the change in ICU's behavior in macOS Mojave,
which caused isWordTextBreak to return true in more cases.

In this particular failing test case, previousTextOrLineBreakBox and nextTextOrLineBreakBox were failing to find
an inline text box when it found an inline box for a BR, which was mentioned by an existing FIXME comment.
Consequently, visualWordPosition were erroneously detecting the end of a word followed by a blank line created by
a BR as a valid word boundary to move when the Windows editing behavior is enacted.

Addressed the FIXME comment by finding the next inline text box skipping all inline boxes for BRs. Renamed
misleadingly named previousBoxInDifferentBlock and nextBoxInDifferentBlock to previousBoxInDifferentLine and
nextBoxInDifferentLine respectively, and set them to true as they're really indicating whether line boxes
belong to a distinct line or not; whether an inline box belong to two (render) blocks or not is irrelevant.

Finally, this patch fixes a bug in visualWordPosition that it was failing to skip blank lines when a word break is
found as we traversed past a line break. In those cases, we must skip all line breaks before stopping.

Tests: editing/selection/move-by-word-visually-mac.html

editing/selection/move-by-word-visually-multi-line.htm

  • editing/VisibleUnits.cpp:

(WebCore::CachedLogicallyOrderedLeafBoxes::previousTextOrLineBreakBox):
(WebCore::CachedLogicallyOrderedLeafBoxes::nextTextOrLineBreakBox):
(WebCore::CachedLogicallyOrderedLeafBoxes::boxIndexInLeaves const):
(WebCore::logicallyPreviousBox):
(WebCore::logicallyNextBox):
(WebCore::wordBreakIteratorForMinOffsetBoundary):
(WebCore::wordBreakIteratorForMaxOffsetBoundary):
(WebCore::visualWordPosition):

LayoutTests:

Added a multi-line test case which causes a failure under Mac editing behavior. The test case is symmetric to ml_1.

  • editing/selection/move-by-word-visually-mac-expected.txt:
  • editing/selection/move-by-word-visually-mac.html:
  • editing/selection/move-by-word-visually-multi-line-expected.txt:
  • editing/selection/move-by-word-visually-multi-line.html:
12:35 PM Changeset in webkit [232661] by Alan Bujtas
  • 3 edits in trunk/Source/WebCore

[LFC] MarginCollapse functions should be able to resolve non-fixed margin values
https://bugs.webkit.org/show_bug.cgi?id=186461

Reviewed by Antti Koivisto.

We need the containing block's computed width to resolve vertical and horizontal margins.

  • layout/blockformatting/BlockFormattingContext.h:
  • layout/blockformatting/BlockMarginCollapse.cpp:

(WebCore::Layout::BlockFormattingContext::MarginCollapse::collapsedMarginTopFromFirstChild):
(WebCore::Layout::BlockFormattingContext::MarginCollapse::nonCollapsedMarginTop):
(WebCore::Layout::BlockFormattingContext::MarginCollapse::computedNonCollapsedMarginTop):
(WebCore::Layout::BlockFormattingContext::MarginCollapse::computedNonCollapsedMarginBottom):
(WebCore::Layout::BlockFormattingContext::MarginCollapse::marginTop):
(WebCore::Layout::BlockFormattingContext::MarginCollapse::marginBottom):
(WebCore::Layout::BlockFormattingContext::MarginCollapse::collapsedMarginBottomFromLastChild):
(WebCore::Layout::BlockFormattingContext::MarginCollapse::nonCollapsedMarginBottom):
(WebCore::Layout::collapsedMarginTopFromFirstChild): Deleted.
(WebCore::Layout::nonCollapsedMarginTop): Deleted.

9:27 AM Changeset in webkit [232660] by Darin Adler
  • 26 edits
    2 moves in trunk

[Cocoa] Remove all uses of NSAutoreleasePool as part of preparation for ARC
https://bugs.webkit.org/show_bug.cgi?id=186436

Reviewed by Anders Carlsson.

Source/JavaScriptCore:

  • heap/Heap.cpp: Include FoundationSPI.h rather than directly including

objc-internal.h and explicitly declaring the alternative.

Source/WebCore:

  • bridge/objc/objc_class.mm: Use import instead of include.
  • bridge/objc/objc_instance.h: Replaced _pool member to hold an object with

m_autoreleasePool member to hold a token from objc_autoreleasePoolPush. Also
initialize all data members here in the class definition.

  • bridge/objc/objc_instance.mm:

(ObjcInstance::ObjcInstance): Moved most initialization to class definition.
(ObjcInstance::virtualBegin): Use objc_autoreleasePoolPush instead of
NSAutoreleasePool class.
(ObjcInstance::virtualEnd): Use objc_autoreleasePoolPop.

  • bridge/objc/objc_runtime.mm: Use import instead of include.
  • bridge/objc/objc_utility.mm: Ditto.
  • platform/audio/mac/AudioBusMac.mm:

(WebCore::AudioBus::loadPlatformResource): Use @autoreleasepool.

  • platform/ios/wak/WebCoreThread.mm: Re-sorted includes. Removed declaration of

autorelease pool SPI and use FoundationSPI.h instead.

  • platform/network/cocoa/ResourceResponseCocoa.mm:

(WebCore::ResourceResponse::platformLazyInit): Use @autoreleasepool.

Source/WebCore/PAL:

  • PAL.xcodeproj/project.pbxproj: Removed FoundationSPI.h.
  • pal/PlatformMac.cmake: Ditto.
  • pal/spi/cocoa/FoundationSPI.h: Moved into WTF project.

Source/WebKitLegacy/mac:

  • Carbon/CarbonUtils.m: Updated include location of FoundationSPI.h.

(getNSAutoreleasePoolCount): Use objc_autoreleasePoolPush/Pop.
(WebInitForCarbon): Use objc_autoreleasePoolPush/Pop instead of NSAutoreleasePool object.
(PoolCleaner): Ditto.

  • History/WebHistory.mm:

(-[WebHistoryPrivate loadHistoryGutsFromURL:savedItemsCount:collectDiscardedItemsInto:error:]):
Use @autoreleasepool instead of NSAutoreleasePool object. No need to do the "drain pool only
every 50 times"; the -[WebHistory loadFromURL] family of methods were once used by Safari, and
now hardly used if at all.

  • WebView/WebView.mm:

(-[WebView rectsForTextMatches]): Ditto.

Source/WTF:

  • WTF.xcodeproj/project.pbxproj: Added FoundationSPI.h.
  • wtf/AutodrainedPool.h: Streamlined header a bit, added some comments.
  • wtf/PlatformMac.cmake: Added FoundationSPI.h.
  • wtf/cocoa/AutodrainedPool.cpp: Moved here from AutodrainedPoolMac.mm.

(WTF::AutodrainedPool::AutodrainedPool): Use objc_autoreleasePoolPush/Pop instead of
the NSAutoreleasePool class.
(WTF::AutodrainedPool::~AutodrainedPool): Ditto.

  • wtf/spi/cocoa/FoundationSPI.h: Moved from Source/WebCore/PAL/pal/spi/cocoa/FoundationSPI.h. Changed both include and declarations so it's the objc_autoreleasePoolPush/Pop instead of the higher level NS functions that call them.

Tools:

  • TestWebKitAPI/Tests/WebKitObjC/CustomProtocolsTest.mm:

(TestWebKitAPI::WebKit2CustomProtocolsTest_ProcessPoolDestroyedDuringLoading):
Use @autoreleasepool.

  • TestWebKitAPI/Tests/mac/MenuTypesForMouseEvents.mm:

(TestWebKitAPI::buildAndPerformTest): Ditto.

  • TestWebKitAPI/Tests/mac/StopLoadingFromDidFinishLoading.mm:

(TestWebKitAPI::WebKitLegacy_StopLoadingFromDidFinishLoading): Ditto.

Note: See TracTimeline for information about the timeline view.