OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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_view_impl.h" | 5 #include "content/renderer/render_view_impl.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 #include <cmath> | 8 #include <cmath> |
9 #include <memory> | 9 #include <memory> |
10 | 10 |
(...skipping 1029 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1040 // Force preload=none and disable autoplay on older Android | 1040 // Force preload=none and disable autoplay on older Android |
1041 // platforms because their media pipelines are not stable enough to handle | 1041 // platforms because their media pipelines are not stable enough to handle |
1042 // concurrent elements. See http://crbug.com/612909, http://crbug.com/622826. | 1042 // concurrent elements. See http://crbug.com/612909, http://crbug.com/622826. |
1043 const bool is_jelly_bean = | 1043 const bool is_jelly_bean = |
1044 base::android::BuildInfo::GetInstance()->sdk_int() <= | 1044 base::android::BuildInfo::GetInstance()->sdk_int() <= |
1045 base::android::SDK_VERSION_JELLY_BEAN_MR2; | 1045 base::android::SDK_VERSION_JELLY_BEAN_MR2; |
1046 settings->SetForcePreloadNoneForMediaElements(is_jelly_bean); | 1046 settings->SetForcePreloadNoneForMediaElements(is_jelly_bean); |
1047 | 1047 |
1048 WebRuntimeFeatures::EnableVideoFullscreenOrientationLock( | 1048 WebRuntimeFeatures::EnableVideoFullscreenOrientationLock( |
1049 prefs.video_fullscreen_orientation_lock_enabled); | 1049 prefs.video_fullscreen_orientation_lock_enabled); |
| 1050 WebRuntimeFeatures::EnableVideoRotateToFullscreen( |
| 1051 prefs.video_rotate_to_fullscreen_enabled); |
1050 WebRuntimeFeatures::EnableVideoFullscreenDetection( | 1052 WebRuntimeFeatures::EnableVideoFullscreenDetection( |
1051 prefs.video_fullscreen_detection_enabled); | 1053 prefs.video_fullscreen_detection_enabled); |
1052 settings->SetEmbeddedMediaExperienceEnabled( | 1054 settings->SetEmbeddedMediaExperienceEnabled( |
1053 prefs.embedded_media_experience_enabled); | 1055 prefs.embedded_media_experience_enabled); |
1054 settings->SetDoNotUpdateSelectionOnMutatingSelectionRange( | 1056 settings->SetDoNotUpdateSelectionOnMutatingSelectionRange( |
1055 prefs.do_not_update_selection_on_mutating_selection_range); | 1057 prefs.do_not_update_selection_on_mutating_selection_range); |
1056 #else // defined(OS_ANDROID) | 1058 #else // defined(OS_ANDROID) |
1057 settings->SetCrossOriginMediaPlaybackRequiresUserGesture( | 1059 settings->SetCrossOriginMediaPlaybackRequiresUserGesture( |
1058 prefs.cross_origin_media_playback_requires_user_gesture); | 1060 prefs.cross_origin_media_playback_requires_user_gesture); |
1059 #endif // defined(OS_ANDROID) | 1061 #endif // defined(OS_ANDROID) |
(...skipping 1612 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2672 INPUT_EVENT_ACK_STATE_NOT_CONSUMED); | 2674 INPUT_EVENT_ACK_STATE_NOT_CONSUMED); |
2673 } | 2675 } |
2674 | 2676 |
2675 std::unique_ptr<InputEventAck> ack(new InputEventAck( | 2677 std::unique_ptr<InputEventAck> ack(new InputEventAck( |
2676 InputEventAckSource::MAIN_THREAD, input_event->GetType(), | 2678 InputEventAckSource::MAIN_THREAD, input_event->GetType(), |
2677 INPUT_EVENT_ACK_STATE_NOT_CONSUMED)); | 2679 INPUT_EVENT_ACK_STATE_NOT_CONSUMED)); |
2678 OnInputEventAck(std::move(ack)); | 2680 OnInputEventAck(std::move(ack)); |
2679 } | 2681 } |
2680 | 2682 |
2681 } // namespace content | 2683 } // namespace content |
OLD | NEW |