WebKit Bugzilla
Attachment 339249 Details for
Bug 185175
: Get the WebKit.framework bundle by asking for WKWebView
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch for landing
bug-185175-20180501175841.patch (text/plain), 20.56 KB, created by
Jer Noble
on 2018-05-01 17:58:42 PDT
(
hide
)
Description:
Patch for landing
Filename:
MIME Type:
Creator:
Jer Noble
Created:
2018-05-01 17:58:42 PDT
Size:
20.56 KB
patch
obsolete
>Subversion Revision: 231157 >diff --git a/Source/WebKit/ChangeLog b/Source/WebKit/ChangeLog >index b45b9c8b7b0bf1893057b858c851d46fbe2c2b68..264f5ad2ac9aad9f5b6bfd9e5229be6d5890780f 100644 >--- a/Source/WebKit/ChangeLog >+++ b/Source/WebKit/ChangeLog >@@ -1,3 +1,26 @@ >+2018-05-01 Jer Noble <jer.noble@apple.com> >+ >+ Get the WebKit.framework bundle by asking for WKWebView >+ https://bugs.webkit.org/show_bug.cgi?id=185175 >+ >+ Reviewed by Tim Horton. >+ >+ * NetworkProcess/mac/NetworkProcessMac.mm: >+ (WebKit::NetworkProcess::initializeSandbox): >+ * Shared/mac/ChildProcessMac.mm: >+ (WebKit::ChildProcess::initializeSandbox): >+ * StorageProcess/mac/StorageProcessMac.mm: >+ (WebKit::StorageProcess::initializeSandbox): >+ >+2018-05-01 Jer Noble <jer.noble@apple.com> >+ >+ Production build error in Migrate Header phase when WK_ALTERNATE_FRAMEWORKS_DIR is set to non-empty value >+ https://bugs.webkit.org/show_bug.cgi?id=185171 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ * Configurations/BaseTarget.xcconfig: >+ > 2018-04-30 Andy Estes <aestes@apple.com> > > [iOS] Try to unlock PDF documents before printing them >diff --git a/Source/WebKit/Configurations/BaseTarget.xcconfig b/Source/WebKit/Configurations/BaseTarget.xcconfig >index 3285ae5af574c20157e18d27e78541cee815146f..0b91c178a8c3b9b89963227a657367ffa74e5e29 100644 >--- a/Source/WebKit/Configurations/BaseTarget.xcconfig >+++ b/Source/WebKit/Configurations/BaseTarget.xcconfig >@@ -81,7 +81,7 @@ UMBRELLA_FRAMEWORKS_DIR = $(UMBRELLA_FRAMEWORKS_DIR_$(CONFIGURATION)); > UMBRELLA_FRAMEWORKS_DIR_Debug = $(UMBRELLA_FRAMEWORKS_DIR_engineering); > UMBRELLA_FRAMEWORKS_DIR_Release = $(UMBRELLA_FRAMEWORKS_DIR_engineering); > UMBRELLA_FRAMEWORKS_DIR_Production = $(UMBRELLA_FRAMEWORKS_DIR_Production_COCOA_TOUCH_$(WK_IS_COCOA_TOUCH)); >-UMBRELLA_FRAMEWORKS_DIR_Production_COCOA_TOUCH_YES = $(SDKROOT)$(SYSTEM_LIBRARY_DIR)/PrivateFrameworks; >+UMBRELLA_FRAMEWORKS_DIR_Production_COCOA_TOUCH_YES = $(SDKROOT)$(WK_ALTERNATE_WEBKIT_SDK_PATH)$(SYSTEM_LIBRARY_DIR)/PrivateFrameworks; > UMBRELLA_FRAMEWORKS_DIR_Production_COCOA_TOUCH_NO = $(SDKROOT)$(UMBRELLA_FRAMEWORKS_DIR_Production_macosx_USE_OVERRIDE_FRAMEWORKS_DIR_$(WK_USE_OVERRIDE_FRAMEWORKS_DIR)); > UMBRELLA_FRAMEWORKS_DIR_Production_macosx_USE_OVERRIDE_FRAMEWORKS_DIR_NO = $(NEXT_ROOT)$(SYSTEM_LIBRARY_DIR)/Frameworks/WebKit.framework/Versions/A/Frameworks; > UMBRELLA_FRAMEWORKS_DIR_Production_macosx_USE_OVERRIDE_FRAMEWORKS_DIR_YES = $(WK_OVERRIDE_FRAMEWORKS_DIR); >diff --git a/Source/WebKit/NetworkProcess/mac/NetworkProcessMac.mm b/Source/WebKit/NetworkProcess/mac/NetworkProcessMac.mm >index 54ab302f7eff777efc5ee93a8dc52e5c44784adf..b99fa521054a64e973b6105f44b50b44a29145df 100644 >--- a/Source/WebKit/NetworkProcess/mac/NetworkProcessMac.mm >+++ b/Source/WebKit/NetworkProcess/mac/NetworkProcessMac.mm >@@ -36,6 +36,7 @@ > #import "SandboxInitializationParameters.h" > #import "SecItemShim.h" > #import "StringUtilities.h" >+#import "WKFoundation.h" > #import <WebCore/CertificateInfo.h> > #import <WebCore/FileSystem.h> > #import <WebCore/LocalizedStrings.h> >@@ -119,8 +120,13 @@ void NetworkProcess::allowSpecificHTTPSCertificateForHost(const CertificateInfo& > void NetworkProcess::initializeSandbox(const ChildProcessInitializationParameters& parameters, SandboxInitializationParameters& sandboxParameters) > { > // Need to overide the default, because service has a different bundle ID. >- NSBundle *webkit2Bundle = [NSBundle bundleForClass:NSClassFromString(@"WKView")]; >- sandboxParameters.setOverrideSandboxProfilePath([webkit2Bundle pathForResource:@"com.apple.WebKit.NetworkProcess" ofType:@"sb"]); >+#if WK_API_ENABLED >+ NSBundle *webKit2Bundle = [NSBundle bundleForClass:NSClassFromString(@"WKWebView")]; >+#else >+ NSBundle *webKit2Bundle = [NSBundle bundleForClass:NSClassFromString(@"WKView")]; >+#endif >+ >+ sandboxParameters.setOverrideSandboxProfilePath([webKit2Bundle pathForResource:@"com.apple.WebKit.NetworkProcess" ofType:@"sb"]); > > ChildProcess::initializeSandbox(parameters, sandboxParameters); > } >diff --git a/Source/WebKit/Shared/mac/ChildProcessMac.mm b/Source/WebKit/Shared/mac/ChildProcessMac.mm >index 0013c1079cf021ffe74f1f6a79e61efc6f35427c..aed5b9fd70960fe170d5026cc20e267a516f0204 100644 >--- a/Source/WebKit/Shared/mac/ChildProcessMac.mm >+++ b/Source/WebKit/Shared/mac/ChildProcessMac.mm >@@ -31,6 +31,7 @@ > #import "CodeSigning.h" > #import "QuarantineSPI.h" > #import "SandboxInitializationParameters.h" >+#import "WKFoundation.h" > #import "XPCServiceEntryPoint.h" > #import <WebCore/FileSystem.h> > #import <WebCore/SystemVersion.h> >@@ -111,8 +112,12 @@ static OSStatus enableSandboxStyleFileQuarantine() > > void ChildProcess::initializeSandbox(const ChildProcessInitializationParameters& parameters, SandboxInitializationParameters& sandboxParameters) > { >- NSBundle *webkit2Bundle = [NSBundle bundleForClass:NSClassFromString(@"WKView")]; >- String defaultProfilePath = [webkit2Bundle pathForResource:[[NSBundle mainBundle] bundleIdentifier] ofType:@"sb"]; >+#if WK_API_ENABLED >+ NSBundle *webKit2Bundle = [NSBundle bundleForClass:NSClassFromString(@"WKWebView")]; >+#else >+ NSBundle *webKit2Bundle = [NSBundle bundleForClass:NSClassFromString(@"WKView")]; >+#endif >+ String defaultProfilePath = [webKit2Bundle pathForResource:[[NSBundle mainBundle] bundleIdentifier] ofType:@"sb"]; > > if (sandboxParameters.userDirectorySuffix().isNull()) { > auto userDirectorySuffix = parameters.extraInitializationData.find("user-directory-suffix"); >@@ -146,7 +151,7 @@ void ChildProcess::initializeSandbox(const ChildProcessInitializationParameters& > } > setenv("TMPDIR", temporaryDirectory, 1); > >- sandboxParameters.addPathParameter("WEBKIT2_FRAMEWORK_DIR", [[webkit2Bundle bundlePath] stringByDeletingLastPathComponent]); >+ sandboxParameters.addPathParameter("WEBKIT2_FRAMEWORK_DIR", [[webKit2Bundle bundlePath] stringByDeletingLastPathComponent]); > sandboxParameters.addConfDirectoryParameter("DARWIN_USER_TEMP_DIR", _CS_DARWIN_USER_TEMP_DIR); > sandboxParameters.addConfDirectoryParameter("DARWIN_USER_CACHE_DIR", _CS_DARWIN_USER_CACHE_DIR); > >diff --git a/Source/WebKit/StorageProcess/mac/StorageProcessMac.mm b/Source/WebKit/StorageProcess/mac/StorageProcessMac.mm >index b4132935ace67b19d021909745773102cb9582a2..a1e0001b275506c7bc2a28f33bb893bc4f4d14bd 100644 >--- a/Source/WebKit/StorageProcess/mac/StorageProcessMac.mm >+++ b/Source/WebKit/StorageProcess/mac/StorageProcessMac.mm >@@ -53,7 +53,11 @@ void StorageProcess::initializeProcessName(const ChildProcessInitializationParam > void StorageProcess::initializeSandbox(const ChildProcessInitializationParameters& parameters, SandboxInitializationParameters& sandboxParameters) > { > // Need to overide the default, because service has a different bundle ID. >- NSBundle *webkit2Bundle = [NSBundle bundleForClass:NSClassFromString(@"WKView")]; >+#if WK_API_ENABLED >+ NSBundle *webKit2Bundle = [NSBundle bundleForClass:NSClassFromString(@"WKWebView")]; >+#else >+ NSBundle *webKit2Bundle = [NSBundle bundleForClass:NSClassFromString(@"WKView")]; >+#endif > sandboxParameters.setOverrideSandboxProfilePath([webkit2Bundle pathForResource:@"com.apple.WebKit.Storage" ofType:@"sb"]); > > ChildProcess::initializeSandbox(parameters, sandboxParameters); >diff --git a/Source/WebKit/UIProcess/Cocoa/PlaybackSessionManagerProxy.h b/Source/WebKit/UIProcess/Cocoa/PlaybackSessionManagerProxy.h >index d901ea793fb9ae206c8ce6218c06e9e15dd939d1..6c9ffceb8b1615c138037881f17f349a1499d3ea 100644 >--- a/Source/WebKit/UIProcess/Cocoa/PlaybackSessionManagerProxy.h >+++ b/Source/WebKit/UIProcess/Cocoa/PlaybackSessionManagerProxy.h >@@ -84,6 +84,7 @@ public: > void externalPlaybackChanged(bool, PlaybackSessionModel::ExternalPlaybackTargetType, const String&); > void wirelessVideoPlaybackDisabledChanged(bool); > void mutedChanged(bool); >+ void volumeChanged(float); > void pictureInPictureActiveChanged(bool); > > private: >@@ -111,6 +112,7 @@ private: > void togglePictureInPicture() final; > void toggleMuted() final; > void setMuted(bool) final; >+ void setVolume(float) final; > > double playbackStartedTime() const final { return m_playbackStartedTime; } > double duration() const final { return m_duration; } >@@ -132,6 +134,7 @@ private: > String externalPlaybackLocalizedDeviceName() const final { return m_externalPlaybackLocalizedDeviceName; } > bool wirelessVideoPlaybackDisabled() const final { return m_wirelessVideoPlaybackDisabled; } > bool isMuted() const final { return m_muted; } >+ float volume() const final { return m_volume; } > bool isPictureInPictureActive() const final { return m_pictureInPictureActive; } > > PlaybackSessionManagerProxy* m_manager; >@@ -158,6 +161,7 @@ private: > String m_externalPlaybackLocalizedDeviceName; > bool m_wirelessVideoPlaybackDisabled { false }; > bool m_muted { false }; >+ float m_volume { 0 }; > bool m_pictureInPictureActive { false }; > }; > >@@ -205,6 +209,7 @@ private: > void rateChanged(uint64_t contextId, bool isPlaying, double rate); > void handleControlledElementIDResponse(uint64_t, String) const; > void mutedChanged(uint64_t contextId, bool muted); >+ void volumeChanged(uint64_t contextId, float volume); > void pictureInPictureActiveChanged(uint64_t contextId, bool pictureInPictureActive); > > // Messages to PlaybackSessionManager >@@ -223,6 +228,7 @@ private: > void togglePictureInPicture(uint64_t contextId); > void toggleMuted(uint64_t contextId); > void setMuted(uint64_t contextId, bool); >+ void setVolume(uint64_t contextId, float); > > WebPageProxy* m_page; > HashMap<uint64_t, ModelInterfaceTuple> m_contextMap; >diff --git a/Source/WebKit/UIProcess/Cocoa/PlaybackSessionManagerProxy.messages.in b/Source/WebKit/UIProcess/Cocoa/PlaybackSessionManagerProxy.messages.in >index 5c0b68e6325de759ebd91ec9ae814e48df2ed7b4..adf9bd4fa73f99e646b10393744184dfebda405c 100644 >--- a/Source/WebKit/UIProcess/Cocoa/PlaybackSessionManagerProxy.messages.in >+++ b/Source/WebKit/UIProcess/Cocoa/PlaybackSessionManagerProxy.messages.in >@@ -37,6 +37,7 @@ messages -> PlaybackSessionManagerProxy { > PlaybackStartedTimeChanged(uint64_t contextId, double playbackStartedTime) > RateChanged(uint64_t contextId, bool isPlaying, double rate) > MutedChanged(uint64_t contextId, bool muted); >+ VolumeChanged(uint64_t contextId, bool volume); > PictureInPictureActiveChanged(uint64_t contextId, bool pictureInPictureActive) > SetUpPlaybackControlsManagerWithID(uint64_t contextId) > ClearPlaybackControlsManager() >diff --git a/Source/WebKit/UIProcess/Cocoa/PlaybackSessionManagerProxy.mm b/Source/WebKit/UIProcess/Cocoa/PlaybackSessionManagerProxy.mm >index c59953d2ec5355be1c450d70b97591176babb1a7..e7a760dcb4a9ccd15c7dd9e58e2dbb94257488bf 100644 >--- a/Source/WebKit/UIProcess/Cocoa/PlaybackSessionManagerProxy.mm >+++ b/Source/WebKit/UIProcess/Cocoa/PlaybackSessionManagerProxy.mm >@@ -146,6 +146,12 @@ void PlaybackSessionModelContext::setMuted(bool muted) > m_manager->setMuted(m_contextId, muted); > } > >+void PlaybackSessionModelContext::setVolume(float volume) >+{ >+ if (m_manager) >+ m_manager->setVolume(m_contextId, volume); >+} >+ > void PlaybackSessionModelContext::playbackStartedTimeChanged(double playbackStartedTime) > { > m_playbackStartedTime = playbackStartedTime; >@@ -258,6 +264,13 @@ void PlaybackSessionModelContext::mutedChanged(bool muted) > client->mutedChanged(muted); > } > >+void PlaybackSessionModelContext::volumeChanged(float volume) >+{ >+ m_volume = volume; >+ for (auto* client : m_clients) >+ client->volumeChanged(volume); >+} >+ > void PlaybackSessionModelContext::pictureInPictureActiveChanged(bool active) > { > m_pictureInPictureActive = active; >@@ -440,6 +453,11 @@ void PlaybackSessionManagerProxy::mutedChanged(uint64_t contextId, bool muted) > ensureModel(contextId).mutedChanged(muted); > } > >+void PlaybackSessionManagerProxy::volumeChanged(uint64_t contextId, float volume) >+{ >+ ensureModel(contextId).volumeChanged(volume); >+} >+ > void PlaybackSessionManagerProxy::durationChanged(uint64_t contextId, double duration) > { > ensureModel(contextId).durationChanged(duration); >@@ -549,6 +567,11 @@ void PlaybackSessionManagerProxy::setMuted(uint64_t contextId, bool muted) > m_page->send(Messages::PlaybackSessionManager::SetMuted(contextId, muted), m_page->pageID()); > } > >+void PlaybackSessionManagerProxy::setVolume(uint64_t contextId, float volume) >+{ >+ m_page->send(Messages::PlaybackSessionManager::SetVolume(contextId, volume), m_page->pageID()); >+} >+ > void PlaybackSessionManagerProxy::requestControlledElementID() > { > if (m_controlsManagerContextId) >diff --git a/Source/WebKit/WebKit.xcodeproj/project.pbxproj b/Source/WebKit/WebKit.xcodeproj/project.pbxproj >index 882bb8aadb2dc01184c4c3fb77fb7f36e5ff9ab4..3843b384f8e210d486ce4d6a65d41ac447a0b61b 100644 >--- a/Source/WebKit/WebKit.xcodeproj/project.pbxproj >+++ b/Source/WebKit/WebKit.xcodeproj/project.pbxproj >@@ -10385,7 +10385,7 @@ > ); > runOnlyForDeploymentPostprocessing = 0; > shellPath = /bin/sh; >- shellScript = "if [[ ${WK_PLATFORM_NAME} == macosx ]]; then\n ln -sf \"Versions/Current/XPCServices\" \"${BUILT_PRODUCTS_DIR}/WebKit.framework/XPCServices\";\nfi\n"; >+ shellScript = "if [[ ${WK_PLATFORM_NAME} == macosx || ${WK_PLATFORM_NAME} == iphoneminimalsimulator ]]; then\n ln -sf \"Versions/Current/XPCServices\" \"${BUILT_PRODUCTS_DIR}/WebKit.framework/XPCServices\";\nfi\n"; > }; > BCFFCA8B160D6E7B003DF315 /* Copy XPC services for engineering builds */ = { > isa = PBXShellScriptBuildPhase; >@@ -10411,7 +10411,7 @@ > ); > runOnlyForDeploymentPostprocessing = 0; > shellPath = /bin/sh; >- shellScript = "if [[ \"${CONFIGURATION}\" == \"Production\" ]]; then\n exit\nfi\n\nif [[ ${WK_PLATFORM_NAME} != \"macosx\" ]]; then\n XPC_SERVICES_PATH=\"${BUILT_PRODUCTS_DIR}/WebKit.framework/XPCServices\"\nelse\n XPC_SERVICES_PATH=\"${BUILT_PRODUCTS_DIR}/WebKit.framework/Versions/A/XPCServices\"\nfi\n\nmkdir -p \"${XPC_SERVICES_PATH}\"\nditto \"${BUILT_PRODUCTS_DIR}/com.apple.WebKit.WebContent.xpc\" \"${XPC_SERVICES_PATH}/com.apple.WebKit.WebContent.xpc\"\nditto \"${BUILT_PRODUCTS_DIR}/com.apple.WebKit.Networking.xpc\" \"${XPC_SERVICES_PATH}/com.apple.WebKit.Networking.xpc\"\nditto \"${BUILT_PRODUCTS_DIR}/${WK_STORAGE_SERVICE_PRODUCT_NAME}.xpc\" \"${XPC_SERVICES_PATH}/${WK_STORAGE_SERVICE_PRODUCT_NAME}.xpc\"\n\nif [[ ${WK_PLATFORM_NAME} == macosx ]]; then\n ditto \"${BUILT_PRODUCTS_DIR}/com.apple.WebKit.Plugin.32.xpc\" \"${XPC_SERVICES_PATH}/com.apple.WebKit.Plugin.xpc\"\n ditto \"${BUILT_PRODUCTS_DIR}/com.apple.WebKit.Plugin.64.xpc\" \"${XPC_SERVICES_PATH}/com.apple.WebKit.Plugin.64.xpc\"\nfi\n"; >+ shellScript = "if [[ \"${CONFIGURATION}\" == \"Production\" ]]; then\n exit\nfi\n\nif [[ ${WK_PLATFORM_NAME} != \"macosx\" && ${WK_PLATFORM_NAME} != iphoneminimalsimulator ]]; then\n XPC_SERVICES_PATH=\"${BUILT_PRODUCTS_DIR}/WebKit.framework/XPCServices\"\nelse\n XPC_SERVICES_PATH=\"${BUILT_PRODUCTS_DIR}/WebKit.framework/Versions/A/XPCServices\"\nfi\n\nmkdir -p \"${XPC_SERVICES_PATH}\"\nditto \"${BUILT_PRODUCTS_DIR}/com.apple.WebKit.WebContent.xpc\" \"${XPC_SERVICES_PATH}/com.apple.WebKit.WebContent.xpc\"\nditto \"${BUILT_PRODUCTS_DIR}/com.apple.WebKit.Networking.xpc\" \"${XPC_SERVICES_PATH}/com.apple.WebKit.Networking.xpc\"\nditto \"${BUILT_PRODUCTS_DIR}/${WK_STORAGE_SERVICE_PRODUCT_NAME}.xpc\" \"${XPC_SERVICES_PATH}/${WK_STORAGE_SERVICE_PRODUCT_NAME}.xpc\"\n\nif [[ ${WK_PLATFORM_NAME} == macosx || ${WK_PLATFORM_NAME} == iphoneminimalsimulator ]]; then\n ditto \"${BUILT_PRODUCTS_DIR}/com.apple.WebKit.Plugin.32.xpc\" \"${XPC_SERVICES_PATH}/com.apple.WebKit.Plugin.xpc\"\n ditto \"${BUILT_PRODUCTS_DIR}/com.apple.WebKit.Plugin.64.xpc\" \"${XPC_SERVICES_PATH}/com.apple.WebKit.Plugin.64.xpc\"\nfi\n"; > }; > C0CE72841247E66800BC0EC4 /* Generate Derived Sources */ = { > isa = PBXShellScriptBuildPhase; >@@ -10682,6 +10682,7 @@ > 2D50365E1BCC793F00E20BB3 /* NativeWebGestureEventMac.mm in Sources */, > 2DA9449E1884E4F000ED86DB /* NativeWebKeyboardEventIOS.mm in Sources */, > C02BFF1E1251502E009CCBEA /* NativeWebKeyboardEventMac.mm in Sources */, >+ 1C9EBA5C2087E74F00054429 /* NativeWebMouseEventIOS.mm in Sources */, > 31EA25D2134F78C0005B1452 /* NativeWebMouseEventMac.mm in Sources */, > 2DA9449F1884E4F000ED86DB /* NativeWebTouchEventIOS.mm in Sources */, > DF58C6361371ACA000F9A37C /* NativeWebWheelEventMac.mm in Sources */, >@@ -10708,7 +10709,6 @@ > 832AE2531BE2E8CD00FAAE10 /* NetworkCacheSpeculativeLoadManager.cpp in Sources */, > 83BDCCB91AC5FDB6003F6441 /* NetworkCacheStatistics.cpp in Sources */, > E4436ED01A0D040B00EAD204 /* NetworkCacheStorage.cpp in Sources */, >- 1C9EBA5C2087E74F00054429 /* NativeWebMouseEventIOS.mm in Sources */, > 8310428C1BD6B66F00A715E4 /* NetworkCacheSubresourcesEntry.cpp in Sources */, > 5302583D1DCBBD2200DA89C2 /* NetworkCaptureEvent.cpp in Sources */, > 530258401DCBBD2200DA89C2 /* NetworkCaptureManager.cpp in Sources */, >diff --git a/Source/WebKit/WebProcess/cocoa/PlaybackSessionManager.h b/Source/WebKit/WebProcess/cocoa/PlaybackSessionManager.h >index a844f0e1aaed8ce192fe96044aa072d9d5c87318..7036d6d851a28d5fe5067c7a3bea093cc1192016 100644 >--- a/Source/WebKit/WebProcess/cocoa/PlaybackSessionManager.h >+++ b/Source/WebKit/WebProcess/cocoa/PlaybackSessionManager.h >@@ -88,6 +88,7 @@ private: > void externalPlaybackChanged(bool enabled, WebCore::PlaybackSessionModel::ExternalPlaybackTargetType, const String& localizedDeviceName) final; > void wirelessVideoPlaybackDisabledChanged(bool) final; > void mutedChanged(bool) final; >+ void volumeChanged(float) final; > > PlaybackSessionInterfaceContext(PlaybackSessionManager&, uint64_t contextId); > >@@ -139,6 +140,7 @@ protected: > void externalPlaybackChanged(uint64_t contextId, bool enabled, WebCore::PlaybackSessionModel::ExternalPlaybackTargetType, String localizedDeviceName); > void wirelessVideoPlaybackDisabledChanged(uint64_t contextId, bool); > void mutedChanged(uint64_t contextId, bool); >+ void volumeChanged(uint64_t contextId, float); > > // Messages from PlaybackSessionManagerProxy > void play(uint64_t contextId); >@@ -157,6 +159,7 @@ protected: > void togglePictureInPicture(uint64_t contextId); > void toggleMuted(uint64_t contextId); > void setMuted(uint64_t contextId, bool muted); >+ void setVolume(uint64_t contextId, float volume); > > WebPage* m_page; > HashMap<WebCore::HTMLMediaElement*, uint64_t> m_mediaElements; >diff --git a/Source/WebKit/WebProcess/cocoa/PlaybackSessionManager.messages.in b/Source/WebKit/WebProcess/cocoa/PlaybackSessionManager.messages.in >index b6e166f69c990ab7ae82c3d81c616b017936dba9..66841b0064d0a78f8ba856a084e18447fc0e9aac 100644 >--- a/Source/WebKit/WebProcess/cocoa/PlaybackSessionManager.messages.in >+++ b/Source/WebKit/WebProcess/cocoa/PlaybackSessionManager.messages.in >@@ -39,5 +39,6 @@ messages -> PlaybackSessionManager { > TogglePictureInPicture(uint64_t contextId) > ToggleMuted(uint64_t contextId) > SetMuted(uint64_t contextId, bool muted) >+ SetVolume(uint64_t contextId, bool volume) > } > #endif >diff --git a/Source/WebKit/WebProcess/cocoa/PlaybackSessionManager.mm b/Source/WebKit/WebProcess/cocoa/PlaybackSessionManager.mm >index acf52f600de6c3155816363c7d7040f8e6621d32..5f69d0f2cd5cf135485959489ad78e75f7c6bc4c 100644 >--- a/Source/WebKit/WebProcess/cocoa/PlaybackSessionManager.mm >+++ b/Source/WebKit/WebProcess/cocoa/PlaybackSessionManager.mm >@@ -155,6 +155,12 @@ void PlaybackSessionInterfaceContext::mutedChanged(bool muted) > m_manager->mutedChanged(m_contextId, muted); > } > >+void PlaybackSessionInterfaceContext::volumeChanged(float volume) >+{ >+ if (m_manager) >+ m_manager->volumeChanged(m_contextId, volume); >+} >+ > #pragma mark - PlaybackSessionManager > > Ref<PlaybackSessionManager> PlaybackSessionManager::create(WebPage& page) >@@ -378,6 +384,11 @@ void PlaybackSessionManager::mutedChanged(uint64_t contextId, bool muted) > m_page->send(Messages::PlaybackSessionManagerProxy::MutedChanged(contextId, muted)); > } > >+void PlaybackSessionManager::volumeChanged(uint64_t contextId, float volume) >+{ >+ m_page->send(Messages::PlaybackSessionManagerProxy::VolumeChanged(contextId, volume)); >+} >+ > #pragma mark Messages from PlaybackSessionManagerProxy: > > void PlaybackSessionManager::play(uint64_t contextId) >@@ -477,6 +488,12 @@ void PlaybackSessionManager::setMuted(uint64_t contextId, bool muted) > ensureModel(contextId).setMuted(muted); > } > >+void PlaybackSessionManager::setVolume(uint64_t contextId, float volume) >+{ >+ UserGestureIndicator indicator(ProcessingUserGesture); >+ ensureModel(contextId).setVolume(volume); >+} >+ > } // namespace WebKit > > #endif // PLATFORM(IOS) || (PLATFORM(MAC) && ENABLE(VIDEO_PRESENTATION_MODE))
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 185175
:
339243
|
339246
|
339249
|
339270
|
339274
|
339302