Multiple File Input Icon Set Regardless of File List
[WebKit-https.git] / Source / WebCore / ChangeLog
index 6c0b2f0..d63878f 100644 (file)
@@ -1,3 +1,322 @@
+2019-04-23  Guy Lewin  <guy@lewin.co.il>
+
+        Multiple File Input Icon Set Regardless of File List
+        https://bugs.webkit.org/show_bug.cgi?id=195537
+
+        Reviewed by Alexey Proskuryakov.
+
+        File input elements display icon with an empty file list after
+        resetting the file list in 'change' event handler - on iOS
+
+        Test: fast/forms/file/file-reset-in-change-using-open-panel-with-icon.html
+
+        * html/FileInputType.cpp:
+        (WebCore::FileInputType::filesChosen):
+
+2019-04-23  Eric Carlson  <eric.carlson@apple.com>
+
+        Create AVFoundationSoftLink.{h,mm} to reduce duplicate code
+        https://bugs.webkit.org/show_bug.cgi?id=197171
+        <rdar://problem/47454979>
+
+        Reviewed by Youenn Fablet.
+
+        Tests: TestWebKitAPI/Tests/WebCore/cocoa/AVFoundationSoftLinkTest.mm
+
+        * Modules/plugins/QuickTimePluginReplacement.mm:
+        (WebCore::jsValueWithValueInContext):
+        (WebCore::jsValueWithAVMetadataItemInContext):
+        * WebCore.xcodeproj/project.pbxproj:
+        * platform/audio/ios/AudioSessionIOS.mm:
+        (WebCore::AudioSession::setCategory):
+        (WebCore::AudioSession::category const):
+        (WebCore::AudioSession::routeSharingPolicy const):
+        (WebCore::AudioSession::routingContextUID const):
+        (WebCore::AudioSession::sampleRate const):
+        (WebCore::AudioSession::bufferSize const):
+        (WebCore::AudioSession::numberOfOutputChannels const):
+        (WebCore::AudioSession::tryToSetActiveInternal):
+        (WebCore::AudioSession::preferredBufferSize const):
+        (WebCore::AudioSession::setPreferredBufferSize):
+        * platform/audio/ios/MediaSessionManagerIOS.mm:
+        (-[WebMediaSessionHelper initWithCallback:]):
+        (-[WebMediaSessionHelper startMonitoringAirPlayRoutes]):
+        * platform/graphics/avfoundation/AVTrackPrivateAVFObjCImpl.mm:
+        (WebCore::AVTrackPrivateAVFObjCImpl::audioKind const):
+        (WebCore::AVTrackPrivateAVFObjCImpl::videoKind const):
+        (WebCore::AVTrackPrivateAVFObjCImpl::label const):
+        * platform/graphics/avfoundation/AudioSourceProviderAVFObjC.mm:
+        (WebCore::AudioSourceProviderAVFObjC::createMix):
+        * platform/graphics/avfoundation/MediaPlaybackTargetMac.mm:
+        * platform/graphics/avfoundation/MediaSelectionGroupAVFObjC.mm:
+        (WebCore::MediaSelectionGroupAVFObjC::updateOptions):
+        * platform/graphics/avfoundation/objc/AVFoundationMIMETypeCache.mm:
+        (WebCore::AVFoundationMIMETypeCache::canDecodeType):
+        (WebCore::AVFoundationMIMETypeCache::loadMIMETypes):
+        * platform/graphics/avfoundation/objc/CDMInstanceFairPlayStreamingAVFObjC.mm:
+        (WebCore::CDMInstanceFairPlayStreamingAVFObjC::supportsPersistableState):
+        (WebCore::CDMInstanceFairPlayStreamingAVFObjC::supportsPersistentKeys):
+        (WebCore::CDMInstanceFairPlayStreamingAVFObjC::supportsMediaCapability):
+        (WebCore::CDMInstanceFairPlayStreamingAVFObjC::initializeWithConfiguration):
+        (WebCore::CDMInstanceSessionFairPlayStreamingAVFObjC::updateLicense):
+        (WebCore::CDMInstanceSessionFairPlayStreamingAVFObjC::loadSession):
+        (WebCore::CDMInstanceSessionFairPlayStreamingAVFObjC::removeSessionData):
+        (WebCore::CDMInstanceSessionFairPlayStreamingAVFObjC::ensureSession):
+        * platform/graphics/avfoundation/objc/CDMSessionAVContentKeySession.mm:
+        (WebCore::CDMSessionAVContentKeySession::isAvailable):
+        (WebCore::CDMSessionAVContentKeySession::releaseKeys):
+        (WebCore::CDMSessionAVContentKeySession::update):
+        (WebCore::CDMSessionAVContentKeySession::generateKeyReleaseMessage):
+        (WebCore::CDMSessionAVContentKeySession::contentKeySession):
+        * platform/graphics/avfoundation/objc/CDMSessionAVFoundationObjC.mm:
+        * platform/graphics/avfoundation/objc/CDMSessionAVStreamSession.mm:
+        (WebCore::CDMSessionAVStreamSession::releaseKeys):
+        (WebCore::CDMSessionAVStreamSession::update):
+        (WebCore::CDMSessionAVStreamSession::setStreamSession):
+        (WebCore::CDMSessionAVStreamSession::generateKeyReleaseMessage):
+        * platform/graphics/avfoundation/objc/ImageDecoderAVFObjC.mm:
+        (WebCore::imageDecoderAssetOptions):
+        (WebCore::ImageDecoderAVFObjC::ImageDecoderAVFObjC):
+        (WebCore::ImageDecoderAVFObjC::firstEnabledTrack):
+        (WebCore::ImageDecoderAVFObjC::readSamples):
+        (SOFT_LINK_CONSTANT_MAY_FAIL): Deleted.
+        * platform/graphics/avfoundation/objc/InbandTextTrackPrivateAVFObjC.mm:
+        (WebCore::InbandTextTrackPrivateAVFObjC::label const):
+        * platform/graphics/avfoundation/objc/InbandTextTrackPrivateLegacyAVFObjC.mm:
+        (WebCore::InbandTextTrackPrivateLegacyAVFObjC::label const):
+        * platform/graphics/avfoundation/objc/MediaPlaybackTargetPickerMac.mm:
+        (WebCore::MediaPlaybackTargetPickerMac::devicePicker):
+        * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
+        (WebCore::assetCacheForPath):
+        (WebCore::MediaPlayerPrivateAVFoundationObjC::clearMediaCache):
+        (WebCore::MediaPlayerPrivateAVFoundationObjC::clearMediaCacheForOrigins):
+        (WebCore::MediaPlayerPrivateAVFoundationObjC::cancelLoad):
+        (WebCore::MediaPlayerPrivateAVFoundationObjC::createImageGenerator):
+        (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayerLayer):
+        (WebCore::MediaPlayerPrivateAVFoundationObjC::synchronizeTextTrackState):
+        (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVAssetForURL):
+        (WebCore::MediaPlayerPrivateAVFoundationObjC::setAVPlayerItem):
+        (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayer):
+        (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayerItem):
+        (WebCore::MediaPlayerPrivateAVFoundationObjC::supportsType):
+        (WebCore::MediaPlayerPrivateAVFoundationObjC::isAvailable):
+        (WebCore::MediaPlayerPrivateAVFoundationObjC::tracksChanged):
+        (WebCore::determineChangedTracksFromNewTracksAndOldItems):
+        (WebCore::MediaPlayerPrivateAVFoundationObjC::updateAudioTracks):
+        (WebCore::MediaPlayerPrivateAVFoundationObjC::updateVideoTracks):
+        (WebCore::MediaPlayerPrivateAVFoundationObjC::createVideoOutput):
+        (WebCore::MediaPlayerPrivateAVFoundationObjC::outputMediaDataWillChange):
+        (WebCore::MediaPlayerPrivateAVFoundationObjC::safeMediaSelectionGroupForLegibleMedia):
+        (WebCore::MediaPlayerPrivateAVFoundationObjC::safeMediaSelectionGroupForAudibleMedia):
+        (WebCore::MediaPlayerPrivateAVFoundationObjC::safeMediaSelectionGroupForVisualMedia):
+        (WebCore::MediaPlayerPrivateAVFoundationObjC::processMediaSelectionOptions):
+        (WebCore::MediaPlayerPrivateAVFoundationObjC::setCurrentTextTrack):
+        (WebCore::MediaPlayerPrivateAVFoundationObjC::languageOfPrimaryAudioTrack const):
+        (WebCore::MediaPlayerPrivateAVFoundationObjC::wirelessPlaybackTargetType const):
+        (WebCore::exernalDeviceDisplayNameForPlayer):
+        (WebCore::metadataType):
+        (WebCore::MediaPlayerPrivateAVFoundationObjC::metadataDidArrive):
+        (-[WebCoreAVFMovieObserver observeValueForKeyPath:ofObject:change:context:]):
+        (-[WebCoreAVFPullDelegate outputMediaDataWillChange:]):
+        (-[WebCoreAVFPullDelegate outputSequenceWasFlushed:]):
+        (WebCore::MediaPlayerPrivateAVFoundationObjC::processLegacyClosedCaptionsTracks): Deleted.
+        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaSourceAVFObjC.mm:
+        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::MediaPlayerPrivateMediaSourceAVFObjC):
+        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::isAvailable):
+        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::supportsType):
+        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::ensureLayer):
+        (WebCore::MediaPlayerPrivateMediaSourceAVFObjC::streamSession):
+        * platform/graphics/avfoundation/objc/MediaPlayerPrivateMediaStreamAVFObjC.mm:
+        (-[WebAVSampleBufferStatusChangeListener observeValueForKeyPath:ofObject:change:context:]):
+        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::isAvailable):
+        (WebCore::MediaPlayerPrivateMediaStreamAVFObjC::ensureLayers):
+        * platform/graphics/avfoundation/objc/SourceBufferPrivateAVFObjC.mm:
+        (-[WebAVSampleBufferErrorListener observeValueForKeyPath:ofObject:change:context:]):
+        (WebCore::SourceBufferPrivateAVFObjC::SourceBufferPrivateAVFObjC):
+        (WebCore::SourceBufferPrivateAVFObjC::~SourceBufferPrivateAVFObjC):
+        (WebCore::SourceBufferPrivateAVFObjC::trackDidChangeEnabled):
+        (WebCore::SourceBufferPrivateAVFObjC::enqueueSample):
+        * platform/graphics/ca/cocoa/PlatformCALayerCocoa.mm:
+        (WebCore::PlatformCALayerCocoa::layerTypeForPlatformLayer):
+        (WebCore::PlatformCALayerCocoa::PlatformCALayerCocoa):
+        (WebCore::PlatformCALayerCocoa::clone const):
+        (WebCore::PlatformCALayerCocoa::avPlayerLayer const):
+        * platform/graphics/cocoa/HEVCUtilitiesCocoa.mm:
+        (WebCore::validateHEVCParameters):
+        * platform/ios/PlatformSpeechSynthesizerIOS.mm:
+        (getAVSpeechUtteranceDefaultSpeechRate):
+        (getAVSpeechUtteranceMaximumSpeechRate):
+        (-[WebSpeechSynthesisWrapper speakUtterance:]):
+        (WebCore::PlatformSpeechSynthesizer::initializeVoiceList):
+        (SOFT_LINK_CONSTANT): Deleted.
+        * platform/ios/VideoFullscreenInterfaceAVKit.mm:
+        (-[WebAVPlayerLayer init]):
+        (-[WebAVPlayerLayer layoutSublayers]):
+        (-[WebAVPlayerLayer setVideoGravity:]):
+        (-[WebAVPlayerLayer videoRect]):
+        (WebAVPlayerLayerView_startRoutingVideoToPictureInPicturePlayerLayerView):
+        * platform/mac/SerializedPlatformRepresentationMac.mm:
+        (WebCore::jsValueWithValueInContext):
+        (WebCore::jsValueWithAVMetadataItemInContext):
+        * platform/mediarecorder/cocoa/MediaRecorderPrivateWriterCocoa.mm:
+        (WebCore::getAVFormatIDKeyWithFallback):
+        (WebCore::getAVNumberOfChannelsKeyWithFallback):
+        (WebCore::getAVSampleRateKeyWithFallback):
+        (WebCore::getAVEncoderBitRateKeyWithFallback):
+        (WebCore::MediaRecorderPrivateWriter::create):
+        (WebCore::MediaRecorderPrivateWriter::setVideoInput):
+        (WebCore::MediaRecorderPrivateWriter::setAudioInput):
+        * platform/mediastream/RealtimeVideoSource.h:
+        * platform/mediastream/VideoPreset.h:
+        * platform/mediastream/ios/AVAudioSessionCaptureDeviceManager.mm:
+        (WebCore::AVAudioSessionCaptureDeviceManager::refreshAudioCaptureDevices):
+        * platform/mediastream/ios/CoreAudioCaptureSourceIOS.mm:
+        (-[WebCoreAudioCaptureSourceIOSListener initWithCallback:]):
+        (-[WebCoreAudioCaptureSourceIOSListener handleInterruption:]):
+        * platform/mediastream/mac/AVCaptureDeviceManager.mm:
+        (WebCore::deviceIsAvailable):
+        (WebCore::AVCaptureDeviceManager::updateCachedAVCaptureDevices):
+        (WebCore::AVCaptureDeviceManager::refreshCaptureDevices):
+        (WebCore::AVCaptureDeviceManager::isAvailable):
+        (WebCore::AVCaptureDeviceManager::~AVCaptureDeviceManager):
+        * platform/mediastream/mac/AVVideoCaptureSource.mm:
+        (WebCore::AVVideoPreset::create):
+        (WebCore::AVVideoPreset::AVVideoPreset):
+        (WebCore::AVVideoCaptureSource::create):
+        (WebCore::AVVideoCaptureSource::AVVideoCaptureSource):
+        (WebCore::AVVideoCaptureSource::capabilities):
+        (WebCore::sensorOrientationFromVideoOutput):
+        (WebCore::AVVideoCaptureSource::setupSession):
+        (WebCore::AVVideoCaptureSource::frameDurationForFrameRate):
+        (WebCore::AVVideoCaptureSource::setupCaptureSession):
+        (WebCore::AVVideoCaptureSource::captureOutputDidOutputSampleBufferFromConnection):
+        (WebCore::AVVideoCaptureSource::generatePresets):
+        (-[WebCoreAVVideoCaptureSourceObserver addNotificationObservers]):
+        (-[WebCoreAVVideoCaptureSourceObserver captureOutput:didOutputSampleBuffer:fromConnection:]):
+
+2019-04-23  Timothy Hatcher  <timothy@apple.com>
+
+        Speed up RenderTheme::systemColor on Speedometer2.
+        https://bugs.webkit.org/show_bug.cgi?id=197203
+        rdar://problem/50056756
+
+        Reviewed by Tim Horton.
+
+        * rendering/RenderThemeIOS.mm:
+        (WebCore::RenderThemeIOS::systemColor const): Remove some unused code. And fetch the cache after an early return.
+        * rendering/RenderThemeMac.mm:
+        (WebCore::RenderThemeMac::systemColor const): Avoid some allocations in LocalDefaultSystemAppearance
+        when a CSS color is in the system color cache.
+
+2019-04-23  Ryosuke Niwa  <rniwa@webkit.org>
+
+        [iOS] element.focus() sometimes fails to reveal the focused element when it becomes editable dynamically
+        https://bugs.webkit.org/show_bug.cgi?id=197188
+
+        Reviewed by Wenson Hsieh.
+
+        The bug was caused by the scroll-to-reveal code triggered by Element::updateFocusAppearance updating
+        the scroll position via scrolling tree update in a layer tree commit which happens after
+        _zoomToRevealFocusedElement in WKContentView had already scrolled the frame view.
+
+        To fix this problem, we need to defer the editor state update until the layer commit (see r244494),
+        and update the scrolling tree before invoking WebPageProxy::editorStateChanged which brings up
+        the keyboard and scroll-to-reveal the caret in the UI process side.
+
+        We also avoid revealing the focus for the second time via Document::scheduleScrollToFocusedElement
+        in Element::updateFocusAppearance as this timer based scrolling also happens after we had already
+        revealed the caret in _zoomToRevealFocusedElement. This is a bit hacky but works for most cases since
+        we wouldn't bring up a keyboard if the focused element was not editable anyway.
+
+        Test: editing/selection/ios/scrolling-to-focused-element-inside-iframe.html
+
+        * dom/Element.cpp:
+        (WebCore::Element::updateFocusAppearance): Avoid scheduling a timer based reavel of the focused element
+        when we're already revealing the element via selection change.
+
+2019-04-23  Remy Demarest  <rdemarest@apple.com>
+
+        Fix layout issues occuring when entering full screen mode.
+        https://bugs.webkit.org/show_bug.cgi?id=197086
+        <rdar://problem/47733671>.
+
+        Reviewed by Darin Adler.
+
+        This issue is the result of changing the style mask of the window after entering
+        full screen mode. Safari adds an invisible toolbar to display the URL of the page
+        which ends up breaking the layout. Having that window use a style that includes a
+        titlebar fixes the bug.
+
+        * platform/mac/WebCoreFullScreenWindow.mm:
+        (-[WebCoreFullScreenWindow constrainFrameRect:toScreen:]): Ensure that the window
+        can fill the entire screen including the underlapping the menu bar, so that the
+        window does not resize when the animation is done.
+        (-[WebCoreFullScreenWindow canBecomeMainWindow]): Borderless windows cannot become
+        main by default, adding the titlebar allows it to become main, prevent this from
+        happening at all to preserve the existing behavior.
+
+2019-04-23  Chris Dumez  <cdumez@apple.com>
+
+        [Process-Swap-On-Navigation] WebKit hangs when going back to a form submission's page due to Process-Swap-On-Navigation on iOS 12.2 and higher
+        https://bugs.webkit.org/show_bug.cgi?id=197097
+        <rdar://problem/50048318>
+
+        Reviewed by Alex Christensen.
+
+        * loader/EmptyFrameLoaderClient.h:
+        * loader/FrameLoader.cpp:
+        (WebCore::FrameLoader::checkLoadCompleteForThisFrame):
+        If we still have a provisional item (new load has been started or we did not clear it because we're about to retry),
+        then let the client know the load will continue by passing an extra flag with the didFailProvisionalLoad.
+
+        * loader/FrameLoaderClient.h:
+        * loader/FrameLoaderTypes.h:
+
+2019-04-23  Carlos Garcia Campos  <cgarcia@igalia.com>
+
+        [ATK] Implement AtkComponentIface scroll_to methods
+        https://bugs.webkit.org/show_bug.cgi?id=196856
+
+        Reviewed by Michael Catanzaro.
+
+        Implement scroll_to and scroll_to_point when ATK >= 2.30.
+
+        Fixes: accessibility/scroll-to-global-point-iframe-nested.html
+               accessibility/scroll-to-global-point-iframe.html
+               accessibility/scroll-to-global-point-main-window.html
+               accessibility/scroll-to-global-point-nested.html
+               accessibility/scroll-to-make-visible-div-overflow.html
+               accessibility/scroll-to-make-visible-iframe.html
+               accessibility/scroll-to-make-visible-nested-2.html
+               accessibility/scroll-to-make-visible-nested.html
+
+        * accessibility/AccessibilityObject.cpp:
+        (WebCore::AccessibilityObject::scrollToMakeVisible const): Add new method receiving the
+        ScrollRectToVisibleOptions since ATK interface has a parameter to decide how to scroll.
+        * accessibility/AccessibilityObject.h:
+        * accessibility/atk/WebKitAccessibleInterfaceComponent.cpp:
+        (atkToContents):
+        (webkitAccessibleComponentRefAccessibleAtPoint):
+        (webkitAccessibleComponentGetExtents):
+        (webkitAccessibleComponentGrabFocus):
+        (webkitAccessibleComponentScrollTo):
+        (webkitAccessibleComponentScrollToPoint):
+        (webkitAccessibleComponentInterfaceInit):
+        (core): Deleted.
+
+2019-04-22  Youenn Fablet  <youenn@apple.com>
+
+        Update libwebrtc logging when WebCore WebRTC logging is updated
+        https://bugs.webkit.org/show_bug.cgi?id=197166
+        <rdar://problem/50107696>
+
+        Unreviewed.
+
+        Build fix after https://trac.webkit.org/changeset/244511.
+
+        * page/Page.cpp:
+        (WebCore::Page::configureLoggingChannel):
+
 2019-04-22  Youenn Fablet  <youenn@apple.com>
 
         Cache API should return Abort error in case of putting an aborted fetch