Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "content/renderer/render_frame_impl.h" | 5 #include "content/renderer/render_frame_impl.h" |
| 6 | 6 |
| 7 #include <map> | 7 #include <map> |
| 8 #include <string> | 8 #include <string> |
| 9 #include <utility> | 9 #include <utility> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 812 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 823 if (base::EndsWith(url.path(), ".mp4", | 823 if (base::EndsWith(url.path(), ".mp4", |
| 824 base::CompareCase::INSENSITIVE_ASCII) && | 824 base::CompareCase::INSENSITIVE_ASCII) && |
| 825 !media::HasPlatformDecoderSupport()) { | 825 !media::HasPlatformDecoderSupport()) { |
| 826 return false; | 826 return false; |
| 827 } | 827 } |
| 828 | 828 |
| 829 // Indicates if the Android MediaPlayer should be used instead of WMPI. | 829 // Indicates if the Android MediaPlayer should be used instead of WMPI. |
| 830 if (GetContentClient()->renderer()->ShouldUseMediaPlayerForURL(url)) | 830 if (GetContentClient()->renderer()->ShouldUseMediaPlayerForURL(url)) |
| 831 return false; | 831 return false; |
| 832 | 832 |
| 833 // Blacklist the following domains since they are sending content that we | |
| 834 // can't identify as HLS until redirects are followed. | |
| 835 // TODO(tguibert): Remove once http://crbug.com/619729 is fixed. | |
| 836 if (url.DomainIs("once.unicornmedia.com")) | |
|
ncarter (slow)
2016/06/13 23:19:04
My gut reaction is that this is too hacky to appro
DaleCurtis
2016/06/13 23:25:47
Does your opinion change if you think of this more
| |
| 837 return false; | |
| 838 | |
| 833 // Otherwise enable WMPI if indicated via experiment or command line. | 839 // Otherwise enable WMPI if indicated via experiment or command line. |
| 834 return media::IsUnifiedMediaPipelineEnabled(); | 840 return media::IsUnifiedMediaPipelineEnabled(); |
| 835 } | 841 } |
| 836 #endif // defined(OS_ANDROID) | 842 #endif // defined(OS_ANDROID) |
| 837 | 843 |
| 838 #if defined(ENABLE_MOJO_CDM) | 844 #if defined(ENABLE_MOJO_CDM) |
| 839 // Returns whether mojo CDM should be used at runtime. Note that even when mojo | 845 // Returns whether mojo CDM should be used at runtime. Note that even when mojo |
| 840 // CDM is enabled at compile time (ENABLE_MOJO_CDM is defined), there are cases | 846 // CDM is enabled at compile time (ENABLE_MOJO_CDM is defined), there are cases |
| 841 // where we want to choose other CDM types. For example, on Android when we use | 847 // where we want to choose other CDM types. For example, on Android when we use |
| 842 // WebMediaPlayerAndroid, we still want to use ProxyMediaKeys. In the future, | 848 // WebMediaPlayerAndroid, we still want to use ProxyMediaKeys. In the future, |
| (...skipping 5392 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 6235 // event target. Potentially a Pepper plugin will receive the event. | 6241 // event target. Potentially a Pepper plugin will receive the event. |
| 6236 // In order to tell whether a plugin gets the last mouse event and which it | 6242 // In order to tell whether a plugin gets the last mouse event and which it |
| 6237 // is, we set |pepper_last_mouse_event_target_| to null here. If a plugin gets | 6243 // is, we set |pepper_last_mouse_event_target_| to null here. If a plugin gets |
| 6238 // the event, it will notify us via DidReceiveMouseEvent() and set itself as | 6244 // the event, it will notify us via DidReceiveMouseEvent() and set itself as |
| 6239 // |pepper_last_mouse_event_target_|. | 6245 // |pepper_last_mouse_event_target_|. |
| 6240 pepper_last_mouse_event_target_ = nullptr; | 6246 pepper_last_mouse_event_target_ = nullptr; |
| 6241 #endif | 6247 #endif |
| 6242 } | 6248 } |
| 6243 | 6249 |
| 6244 } // namespace content | 6250 } // namespace content |
| OLD | NEW |