OLD | NEW |
---|---|
1 /* | 1 /* |
2 * Copyright (C) 2009, 2012 Google Inc. All rights reserved. | 2 * Copyright (C) 2009, 2012 Google Inc. All rights reserved. |
3 * Copyright (C) 2011 Apple Inc. All rights reserved. | 3 * Copyright (C) 2011 Apple Inc. All rights reserved. |
4 * | 4 * |
5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
6 * modification, are permitted provided that the following conditions are | 6 * modification, are permitted provided that the following conditions are |
7 * met: | 7 * met: |
8 * | 8 * |
9 * * Redistributions of source code must retain the above copyright | 9 * * Redistributions of source code must retain the above copyright |
10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
49 #include "core/loader/FrameLoadRequest.h" | 49 #include "core/loader/FrameLoadRequest.h" |
50 #include "core/loader/FrameLoader.h" | 50 #include "core/loader/FrameLoader.h" |
51 #include "core/loader/HistoryItem.h" | 51 #include "core/loader/HistoryItem.h" |
52 #include "core/page/Page.h" | 52 #include "core/page/Page.h" |
53 #include "core/page/WindowFeatures.h" | 53 #include "core/page/WindowFeatures.h" |
54 #include "modules/device_light/DeviceLightController.h" | 54 #include "modules/device_light/DeviceLightController.h" |
55 #include "modules/device_orientation/DeviceMotionController.h" | 55 #include "modules/device_orientation/DeviceMotionController.h" |
56 #include "modules/device_orientation/DeviceOrientationController.h" | 56 #include "modules/device_orientation/DeviceOrientationController.h" |
57 #include "modules/encryptedmedia/HTMLMediaElementEncryptedMedia.h" | 57 #include "modules/encryptedmedia/HTMLMediaElementEncryptedMedia.h" |
58 #include "modules/gamepad/NavigatorGamepad.h" | 58 #include "modules/gamepad/NavigatorGamepad.h" |
59 #include "modules/mediasession/MediaSession.h" | |
59 #include "modules/serviceworkers/NavigatorServiceWorker.h" | 60 #include "modules/serviceworkers/NavigatorServiceWorker.h" |
60 #include "modules/storage/DOMWindowStorageController.h" | 61 #include "modules/storage/DOMWindowStorageController.h" |
61 #include "modules/vr/NavigatorVRDevice.h" | 62 #include "modules/vr/NavigatorVRDevice.h" |
62 #include "platform/MIMETypeRegistry.h" | 63 #include "platform/MIMETypeRegistry.h" |
63 #include "platform/RuntimeEnabledFeatures.h" | 64 #include "platform/RuntimeEnabledFeatures.h" |
64 #include "platform/UserGestureIndicator.h" | 65 #include "platform/UserGestureIndicator.h" |
65 #include "platform/exported/WrappedResourceRequest.h" | 66 #include "platform/exported/WrappedResourceRequest.h" |
66 #include "platform/exported/WrappedResourceResponse.h" | 67 #include "platform/exported/WrappedResourceResponse.h" |
67 #include "platform/network/HTTPParsers.h" | 68 #include "platform/network/HTTPParsers.h" |
68 #include "platform/plugins/PluginData.h" | 69 #include "platform/plugins/PluginData.h" |
69 #include "public/platform/Platform.h" | 70 #include "public/platform/Platform.h" |
70 #include "public/platform/WebApplicationCacheHost.h" | 71 #include "public/platform/WebApplicationCacheHost.h" |
71 #include "public/platform/WebMimeRegistry.h" | 72 #include "public/platform/WebMimeRegistry.h" |
72 #include "public/platform/WebRTCPeerConnectionHandler.h" | 73 #include "public/platform/WebRTCPeerConnectionHandler.h" |
73 #include "public/platform/WebSecurityOrigin.h" | 74 #include "public/platform/WebSecurityOrigin.h" |
74 #include "public/platform/WebURL.h" | 75 #include "public/platform/WebURL.h" |
75 #include "public/platform/WebURLError.h" | 76 #include "public/platform/WebURLError.h" |
76 #include "public/platform/WebVector.h" | 77 #include "public/platform/WebVector.h" |
78 #include "public/platform/modules/mediasession/WebMediaSession.h" | |
77 #include "public/platform/modules/serviceworker/WebServiceWorkerProvider.h" | 79 #include "public/platform/modules/serviceworker/WebServiceWorkerProvider.h" |
78 #include "public/platform/modules/serviceworker/WebServiceWorkerProviderClient.h " | 80 #include "public/platform/modules/serviceworker/WebServiceWorkerProviderClient.h " |
79 #include "public/web/WebAutofillClient.h" | 81 #include "public/web/WebAutofillClient.h" |
80 #include "public/web/WebContentSettingsClient.h" | 82 #include "public/web/WebContentSettingsClient.h" |
81 #include "public/web/WebDOMEvent.h" | 83 #include "public/web/WebDOMEvent.h" |
82 #include "public/web/WebDocument.h" | 84 #include "public/web/WebDocument.h" |
83 #include "public/web/WebFormElement.h" | 85 #include "public/web/WebFormElement.h" |
84 #include "public/web/WebFrameClient.h" | 86 #include "public/web/WebFrameClient.h" |
85 #include "public/web/WebNode.h" | 87 #include "public/web/WebNode.h" |
86 #include "public/web/WebPlugin.h" | 88 #include "public/web/WebPlugin.h" |
(...skipping 687 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
774 | 776 |
775 if (!webFrame || !webFrame->client()) | 777 if (!webFrame || !webFrame->client()) |
776 return nullptr; | 778 return nullptr; |
777 | 779 |
778 HTMLMediaElementEncryptedMedia& encryptedMedia = HTMLMediaElementEncryptedMe dia::from(htmlMediaElement); | 780 HTMLMediaElementEncryptedMedia& encryptedMedia = HTMLMediaElementEncryptedMe dia::from(htmlMediaElement); |
779 return adoptPtr(webFrame->client()->createMediaPlayer(webFrame, url, | 781 return adoptPtr(webFrame->client()->createMediaPlayer(webFrame, url, |
780 client, &encryptedMedia, | 782 client, &encryptedMedia, |
781 encryptedMedia.contentDecryptionModule())); | 783 encryptedMedia.contentDecryptionModule())); |
782 } | 784 } |
783 | 785 |
786 PassOwnPtr<WebMediaSession> FrameLoaderClientImpl::createWebMediaSession() | |
787 { | |
788 if (!m_webFrame->client()) | |
789 return nullptr; | |
philipj_slow
2015/10/19 14:22:55
Note to the future: If this is actually reachable,
| |
790 | |
791 return adoptPtr(m_webFrame->client()->createMediaSession()); | |
792 } | |
793 | |
784 ObjectContentType FrameLoaderClientImpl::objectContentType( | 794 ObjectContentType FrameLoaderClientImpl::objectContentType( |
785 const KURL& url, | 795 const KURL& url, |
786 const String& explicitMimeType, | 796 const String& explicitMimeType, |
787 bool shouldPreferPlugInsForImages) | 797 bool shouldPreferPlugInsForImages) |
788 { | 798 { |
789 // This code is based on Apple's implementation from | 799 // This code is based on Apple's implementation from |
790 // WebCoreSupport/WebFrameBridge.mm. | 800 // WebCoreSupport/WebFrameBridge.mm. |
791 | 801 |
792 String mimeType = explicitMimeType; | 802 String mimeType = explicitMimeType; |
793 if (mimeType.isEmpty()) { | 803 if (mimeType.isEmpty()) { |
(...skipping 162 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
956 | 966 |
957 void FrameLoaderClientImpl::suddenTerminationDisablerChanged(bool present, Sudde nTerminationDisablerType type) | 967 void FrameLoaderClientImpl::suddenTerminationDisablerChanged(bool present, Sudde nTerminationDisablerType type) |
958 { | 968 { |
959 if (m_webFrame->client()) { | 969 if (m_webFrame->client()) { |
960 m_webFrame->client()->suddenTerminationDisablerChanged( | 970 m_webFrame->client()->suddenTerminationDisablerChanged( |
961 present, static_cast<WebFrameClient::SuddenTerminationDisablerType>( type)); | 971 present, static_cast<WebFrameClient::SuddenTerminationDisablerType>( type)); |
962 } | 972 } |
963 } | 973 } |
964 | 974 |
965 } // namespace blink | 975 } // namespace blink |
OLD | NEW |