Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(135)

Side by Side Diff: third_party/WebKit/Source/web/FrameLoaderClientImpl.cpp

Issue 1840563002: Revert of media: Enable Unified Media Pipeline for MSE and EME on Android (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
67 #include "platform/MIMETypeRegistry.h" 67 #include "platform/MIMETypeRegistry.h"
68 #include "platform/RuntimeEnabledFeatures.h" 68 #include "platform/RuntimeEnabledFeatures.h"
69 #include "platform/UserGestureIndicator.h" 69 #include "platform/UserGestureIndicator.h"
70 #include "platform/exported/WrappedResourceRequest.h" 70 #include "platform/exported/WrappedResourceRequest.h"
71 #include "platform/exported/WrappedResourceResponse.h" 71 #include "platform/exported/WrappedResourceResponse.h"
72 #include "platform/fonts/GlyphPageTreeNode.h" 72 #include "platform/fonts/GlyphPageTreeNode.h"
73 #include "platform/network/HTTPParsers.h" 73 #include "platform/network/HTTPParsers.h"
74 #include "platform/plugins/PluginData.h" 74 #include "platform/plugins/PluginData.h"
75 #include "public/platform/Platform.h" 75 #include "public/platform/Platform.h"
76 #include "public/platform/WebApplicationCacheHost.h" 76 #include "public/platform/WebApplicationCacheHost.h"
77 #include "public/platform/WebMediaPlayer.h"
77 #include "public/platform/WebMimeRegistry.h" 78 #include "public/platform/WebMimeRegistry.h"
78 #include "public/platform/WebRTCPeerConnectionHandler.h" 79 #include "public/platform/WebRTCPeerConnectionHandler.h"
79 #include "public/platform/WebSecurityOrigin.h" 80 #include "public/platform/WebSecurityOrigin.h"
80 #include "public/platform/WebURL.h" 81 #include "public/platform/WebURL.h"
81 #include "public/platform/WebURLError.h" 82 #include "public/platform/WebURLError.h"
82 #include "public/platform/WebVector.h" 83 #include "public/platform/WebVector.h"
83 #include "public/platform/modules/mediasession/WebMediaSession.h" 84 #include "public/platform/modules/mediasession/WebMediaSession.h"
84 #include "public/platform/modules/serviceworker/WebServiceWorkerProvider.h" 85 #include "public/platform/modules/serviceworker/WebServiceWorkerProvider.h"
85 #include "public/platform/modules/serviceworker/WebServiceWorkerProviderClient.h " 86 #include "public/platform/modules/serviceworker/WebServiceWorkerProviderClient.h "
86 #include "public/web/WebAutofillClient.h" 87 #include "public/web/WebAutofillClient.h"
(...skipping 725 matching lines...) Expand 10 before | Expand all | Expand 10 after
812 return nullptr; 813 return nullptr;
813 814
814 if (policy != AllowDetachedPlugin && !element->layoutObject()) 815 if (policy != AllowDetachedPlugin && !element->layoutObject())
815 return nullptr; 816 return nullptr;
816 817
817 return container; 818 return container;
818 } 819 }
819 820
820 PassOwnPtr<WebMediaPlayer> FrameLoaderClientImpl::createWebMediaPlayer( 821 PassOwnPtr<WebMediaPlayer> FrameLoaderClientImpl::createWebMediaPlayer(
821 HTMLMediaElement& htmlMediaElement, 822 HTMLMediaElement& htmlMediaElement,
823 WebMediaPlayer::LoadType loadType,
822 const WebURL& url, 824 const WebURL& url,
823 WebMediaPlayerClient* client) 825 WebMediaPlayerClient* client)
824 { 826 {
825 WebLocalFrameImpl* webFrame = WebLocalFrameImpl::fromFrame( 827 WebLocalFrameImpl* webFrame = WebLocalFrameImpl::fromFrame(
826 htmlMediaElement.document().frame()); 828 htmlMediaElement.document().frame());
827 829
828 if (!webFrame || !webFrame->client()) 830 if (!webFrame || !webFrame->client())
829 return nullptr; 831 return nullptr;
830 832
831 WebMediaSession* webMediaSession = nullptr; 833 WebMediaSession* webMediaSession = nullptr;
832 if (MediaSession* mediaSession = HTMLMediaElementMediaSession::session(htmlM ediaElement)) 834 if (MediaSession* mediaSession = HTMLMediaElementMediaSession::session(htmlM ediaElement))
833 webMediaSession = mediaSession->getWebMediaSession(); 835 webMediaSession = mediaSession->getWebMediaSession();
834 836
835 HTMLMediaElementEncryptedMedia& encryptedMedia = HTMLMediaElementEncryptedMe dia::from(htmlMediaElement); 837 HTMLMediaElementEncryptedMedia& encryptedMedia = HTMLMediaElementEncryptedMe dia::from(htmlMediaElement);
836 WebString sinkId(HTMLMediaElementAudioOutputDevice::sinkId(htmlMediaElement) ); 838 WebString sinkId(HTMLMediaElementAudioOutputDevice::sinkId(htmlMediaElement) );
837 return adoptPtr(webFrame->client()->createMediaPlayer(url, client, &encrypte dMedia, 839 return adoptPtr(webFrame->client()->createMediaPlayer(loadType, url,
840 client, &encryptedMedia,
838 encryptedMedia.contentDecryptionModule(), sinkId, webMediaSession)); 841 encryptedMedia.contentDecryptionModule(), sinkId, webMediaSession));
839 } 842 }
840 843
841 PassOwnPtr<WebMediaSession> FrameLoaderClientImpl::createWebMediaSession() 844 PassOwnPtr<WebMediaSession> FrameLoaderClientImpl::createWebMediaSession()
842 { 845 {
843 if (!m_webFrame->client()) 846 if (!m_webFrame->client())
844 return nullptr; 847 return nullptr;
845 848
846 return adoptPtr(m_webFrame->client()->createMediaSession()); 849 return adoptPtr(m_webFrame->client()->createMediaSession());
847 } 850 }
(...skipping 194 matching lines...) Expand 10 before | Expand all | Expand 10 after
1042 1045
1043 void FrameLoaderClientImpl::suddenTerminationDisablerChanged(bool present, Sudde nTerminationDisablerType type) 1046 void FrameLoaderClientImpl::suddenTerminationDisablerChanged(bool present, Sudde nTerminationDisablerType type)
1044 { 1047 {
1045 if (m_webFrame->client()) { 1048 if (m_webFrame->client()) {
1046 m_webFrame->client()->suddenTerminationDisablerChanged( 1049 m_webFrame->client()->suddenTerminationDisablerChanged(
1047 present, static_cast<WebFrameClient::SuddenTerminationDisablerType>( type)); 1050 present, static_cast<WebFrameClient::SuddenTerminationDisablerType>( type));
1048 } 1051 }
1049 } 1052 }
1050 1053
1051 } // namespace blink 1054 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/web/FrameLoaderClientImpl.h ('k') | third_party/WebKit/public/web/WebFrameClient.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698