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

Side by Side Diff: content/renderer/render_view_impl.cc

Issue 2487373003: Disable background video track behind a feature flag (Closed)
Patch Set: Updated test files Created 4 years, 1 month 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 // 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 1038 matching lines...) Expand 10 before | Expand all | Expand 10 after
1049 settings->setMainFrameResizesAreOrientationChanges( 1049 settings->setMainFrameResizesAreOrientationChanges(
1050 prefs.main_frame_resizes_are_orientation_changes); 1050 prefs.main_frame_resizes_are_orientation_changes);
1051 1051
1052 settings->setUseSolidColorScrollbars(prefs.use_solid_color_scrollbars); 1052 settings->setUseSolidColorScrollbars(prefs.use_solid_color_scrollbars);
1053 1053
1054 settings->setShowContextMenuOnMouseUp(prefs.context_menu_on_mouse_up); 1054 settings->setShowContextMenuOnMouseUp(prefs.context_menu_on_mouse_up);
1055 settings->setAlwaysShowContextMenuOnTouch( 1055 settings->setAlwaysShowContextMenuOnTouch(
1056 prefs.always_show_context_menu_on_touch); 1056 prefs.always_show_context_menu_on_touch);
1057 1057
1058 settings->setHideDownloadUI(prefs.hide_download_ui); 1058 settings->setHideDownloadUI(prefs.hide_download_ui);
1059 WebRuntimeFeatures::enableBackgroundVideoTrackOptimization(
1060 prefs.background_video_track_optimization_enabled);
1059 1061
1060 #if defined(OS_MACOSX) 1062 #if defined(OS_MACOSX)
1061 settings->setDoubleTapToZoomEnabled(true); 1063 settings->setDoubleTapToZoomEnabled(true);
1062 web_view->setMaximumLegibleScale(prefs.default_maximum_page_scale_factor); 1064 web_view->setMaximumLegibleScale(prefs.default_maximum_page_scale_factor);
1063 #endif 1065 #endif
1064 1066
1065 #if defined(OS_WIN) 1067 #if defined(OS_WIN)
1066 WebRuntimeFeatures::enableMiddleClickAutoscroll(true); 1068 WebRuntimeFeatures::enableMiddleClickAutoscroll(true);
1067 #endif 1069 #endif
1068 } 1070 }
(...skipping 1713 matching lines...) Expand 10 before | Expand all | Expand 10 after
2782 INPUT_EVENT_ACK_STATE_NOT_CONSUMED); 2784 INPUT_EVENT_ACK_STATE_NOT_CONSUMED);
2783 } 2785 }
2784 2786
2785 std::unique_ptr<InputEventAck> ack( 2787 std::unique_ptr<InputEventAck> ack(
2786 new InputEventAck(InputEventAckSource::MAIN_THREAD, input_event->type, 2788 new InputEventAck(InputEventAckSource::MAIN_THREAD, input_event->type,
2787 INPUT_EVENT_ACK_STATE_NOT_CONSUMED)); 2789 INPUT_EVENT_ACK_STATE_NOT_CONSUMED));
2788 OnInputEventAck(std::move(ack)); 2790 OnInputEventAck(std::move(ack));
2789 } 2791 }
2790 2792
2791 } // namespace content 2793 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698