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 1083 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1094 settings->setShowContextMenuOnMouseUp(prefs.context_menu_on_mouse_up); | 1094 settings->setShowContextMenuOnMouseUp(prefs.context_menu_on_mouse_up); |
1095 settings->setAlwaysShowContextMenuOnTouch( | 1095 settings->setAlwaysShowContextMenuOnTouch( |
1096 prefs.always_show_context_menu_on_touch); | 1096 prefs.always_show_context_menu_on_touch); |
1097 | 1097 |
1098 settings->setHideDownloadUI(prefs.hide_download_ui); | 1098 settings->setHideDownloadUI(prefs.hide_download_ui); |
1099 WebRuntimeFeatures::enableBackgroundVideoTrackOptimization( | 1099 WebRuntimeFeatures::enableBackgroundVideoTrackOptimization( |
1100 prefs.background_video_track_optimization_enabled); | 1100 prefs.background_video_track_optimization_enabled); |
1101 | 1101 |
1102 settings->setPresentationReceiver(prefs.presentation_receiver); | 1102 settings->setPresentationReceiver(prefs.presentation_receiver); |
1103 | 1103 |
| 1104 settings->setMediaControlsEnabled(prefs.media_controls_enabled); |
| 1105 |
1104 #if defined(OS_MACOSX) | 1106 #if defined(OS_MACOSX) |
1105 settings->setDoubleTapToZoomEnabled(true); | 1107 settings->setDoubleTapToZoomEnabled(true); |
1106 web_view->setMaximumLegibleScale(prefs.default_maximum_page_scale_factor); | 1108 web_view->setMaximumLegibleScale(prefs.default_maximum_page_scale_factor); |
1107 #endif | 1109 #endif |
1108 | 1110 |
1109 #if defined(OS_WIN) | 1111 #if defined(OS_WIN) |
1110 WebRuntimeFeatures::enableMiddleClickAutoscroll(true); | 1112 WebRuntimeFeatures::enableMiddleClickAutoscroll(true); |
1111 #endif | 1113 #endif |
1112 } | 1114 } |
1113 | 1115 |
(...skipping 1602 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2716 INPUT_EVENT_ACK_STATE_NOT_CONSUMED); | 2718 INPUT_EVENT_ACK_STATE_NOT_CONSUMED); |
2717 } | 2719 } |
2718 | 2720 |
2719 std::unique_ptr<InputEventAck> ack( | 2721 std::unique_ptr<InputEventAck> ack( |
2720 new InputEventAck(InputEventAckSource::MAIN_THREAD, input_event->type(), | 2722 new InputEventAck(InputEventAckSource::MAIN_THREAD, input_event->type(), |
2721 INPUT_EVENT_ACK_STATE_NOT_CONSUMED)); | 2723 INPUT_EVENT_ACK_STATE_NOT_CONSUMED)); |
2722 OnInputEventAck(std::move(ack)); | 2724 OnInputEventAck(std::move(ack)); |
2723 } | 2725 } |
2724 | 2726 |
2725 } // namespace content | 2727 } // namespace content |
OLD | NEW |