Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
[PluginProxy] Add a setting to disable video plugin proxy support in …
…HTMLMediaElement. https://bugs.webkit.org/show_bug.cgi?id=123621 Reviewed by Eric Carlson. Source/WebCore: Add a new Setting which will disable the video plugin proxy. Enable support for AVFoundation in iOS (which requries fixing a few compile errors resulting from classes and methods which are not available on iOS. * WebCore.exp.in: Export wkAVAssetResolvedURL. * css/StyleResolver.cpp: (WebCore::StyleResolver::canShareStyleWithElement): Make conditional upon new isVideoPluginProxyEnabled() setting. * html/HTMLMediaElement.cpp: (WebCore::HTMLMediaElement::parseAttribute): Ditto. * html/HTMLMediaElement.h: * html/HTMLVideoElement.cpp: (WebCore::HTMLVideoElement::createRenderer): Ditto. (WebCore::HTMLVideoElement::attach): Ditto. (WebCore::HTMLVideoElement::parseAttribute): Ditto. (HTMLVideoElement::setDisplayMode): Ditto. * html/HTMLVideoElement.h: * page/Settings.cpp: (WebCore::Settings::setVideoPluginProxyEnabled): Simple setter. * page/Settings.h: (WebCore::Settings::isVideoPluginProxyEnabled): Simple getter. * platform/graphics/MediaPlayer.cpp: (WebCore::installedMediaEngines): Conditionally add MediaPlayerPrivateIOS and always add MediaPlayerPriateAVFoundationObjC. * platform/graphics/MediaPlayerPrivate.h: (WebCore::MediaPlayerPrivateInterface::deliverNotification): Add default implementation. (WebCore::MediaPlayerPrivateInterface::setMediaPlayerProxy): Ditto. * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h: * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm: (WebCore::MediaPlayerPrivateAVFoundationObjC::MediaPlayerPrivateAVFoundationObjC): Use new HAS_ and USE_ macros instead of __MAC_OS_MIN_VERNSION_REQUIRED. (WebCore::MediaPlayerPrivateAVFoundationObjC::~MediaPlayerPrivateAVFoundationObjC): Ditto. (WebCore::MediaPlayerPrivateAVFoundationObjC::hasContextRenderer): Ditto. (WebCore::MediaPlayerPrivateAVFoundationObjC::createContextVideoRenderer): Ditto. (WebCore::MediaPlayerPrivateAVFoundationObjC::destroyContextVideoRenderer): Ditto. (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVAssetForURL): Ditto. (WebCore::MediaPlayerPrivateAVFoundationObjC::paint): Ditto. (WebCore::MediaPlayerPrivateAVFoundationObjC::createVideoLayer): Use cachedCGColor instead of CGColorGetConstantColor. (WebCore::MediaPlayerPrivateAVFoundationObjC::createVideoOutput): Use CVPixelBuffer pixel format constant instead of QuickDraw constant. (WebCore::MediaPlayerPrivateAVFoundationObjC::createPixelBuffer): Ditto. (WebCore::MediaPlayerPrivateAVFoundationObjC::paintWithVideoOutput): Draw to intermediary CGImage on iOS. * platform/graphics/avfoundation/objc/WebCoreAVFResourceLoader.h: * platform/graphics/avfoundation/objc/WebCoreAVFResourceLoader.mm: * platform/ios/WebCoreSystemInterfaceIOS.mm: * platform/mac/WebCoreSystemInterface.h: Source/WebKit/mac: Add a new isVideoPluginProxyEnabled setting. * WebView/WebPreferenceKeysPrivate.h: * WebView/WebPreferences.mm: (+[WebPreferences initialize]): Set isVideoPluginProxyEnabled preference. (-[WebPreferences isVideoPluginProxyEnabled]): Pass through to Settings. * WebView/WebPreferencesPrivate.h: * WebView/WebView.mm: (-[WebView _preferencesChanged:]): Set isVideoPluginProxyEnabled preference. Source/WebKit2: Add WebKit2 functions for setting then new isVideoPluginProxyEnabled preference. * Shared/WebPreferencesStore.h: * UIProcess/API/C/WKPreferences.cpp: (WKPreferencesSetVideoPluginProxyEnabled): (WKPreferencesGetVideoPluginProxyEnabled): * UIProcess/API/C/WKPreferences.h: * WebProcess/WebPage/WebPage.cpp: (WebKit::WebPage::updatePreferences): Source/WTF: Enable WTF_USE_AVFOUNDATION and add some HAVE_AVFOUNDATION_* defines to replace the existing __MAC_OS_X_VERSION_MIN_REQUIRED macros in MediaPlayerPrivateAVFoundationObjC.mm. * wtf/Platform.h: Canonical link: https://commits.webkit.org/141945@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@158599 268f45cc-cd09-0410-ab3c-d52691b4dbfc
- Loading branch information
Showing
27 changed files
with
354 additions
and
112 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.