| 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_thread_impl.h" | 5 #include "content/renderer/render_thread_impl.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <limits> | 8 #include <limits> |
| 9 #include <map> | 9 #include <map> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 72 #include "content/renderer/render_process_impl.h" | 72 #include "content/renderer/render_process_impl.h" |
| 73 #include "content/renderer/render_view_impl.h" | 73 #include "content/renderer/render_view_impl.h" |
| 74 #include "content/renderer/renderer_webkitplatformsupport_impl.h" | 74 #include "content/renderer/renderer_webkitplatformsupport_impl.h" |
| 75 #include "content/renderer/skia_benchmarking_extension.h" | 75 #include "content/renderer/skia_benchmarking_extension.h" |
| 76 #include "grit/content_resources.h" | 76 #include "grit/content_resources.h" |
| 77 #include "ipc/ipc_channel_handle.h" | 77 #include "ipc/ipc_channel_handle.h" |
| 78 #include "ipc/ipc_forwarding_message_filter.h" | 78 #include "ipc/ipc_forwarding_message_filter.h" |
| 79 #include "ipc/ipc_platform_file.h" | 79 #include "ipc/ipc_platform_file.h" |
| 80 #include "media/base/audio_hardware_config.h" | 80 #include "media/base/audio_hardware_config.h" |
| 81 #include "media/base/media.h" | 81 #include "media/base/media.h" |
| 82 #include "media/base/media_switches.h" | |
| 83 #include "net/base/net_errors.h" | 82 #include "net/base/net_errors.h" |
| 84 #include "net/base/net_util.h" | 83 #include "net/base/net_util.h" |
| 85 #include "third_party/WebKit/public/platform/WebString.h" | 84 #include "third_party/WebKit/public/platform/WebString.h" |
| 86 #include "third_party/WebKit/Source/WebKit/chromium/public/WebColorName.h" | 85 #include "third_party/WebKit/Source/WebKit/chromium/public/WebColorName.h" |
| 87 #include "third_party/WebKit/Source/WebKit/chromium/public/WebDatabase.h" | 86 #include "third_party/WebKit/Source/WebKit/chromium/public/WebDatabase.h" |
| 88 #include "third_party/WebKit/Source/WebKit/chromium/public/WebDocument.h" | 87 #include "third_party/WebKit/Source/WebKit/chromium/public/WebDocument.h" |
| 89 #include "third_party/WebKit/Source/WebKit/chromium/public/WebFrame.h" | 88 #include "third_party/WebKit/Source/WebKit/chromium/public/WebFrame.h" |
| 90 #include "third_party/WebKit/Source/WebKit/chromium/public/WebKit.h" | 89 #include "third_party/WebKit/Source/WebKit/chromium/public/WebKit.h" |
| 91 #include "third_party/WebKit/Source/WebKit/chromium/public/WebNetworkStateNotifi
er.h" | 90 #include "third_party/WebKit/Source/WebKit/chromium/public/WebNetworkStateNotifi
er.h" |
| 92 #include "third_party/WebKit/Source/WebKit/chromium/public/WebPopupMenu.h" | 91 #include "third_party/WebKit/Source/WebKit/chromium/public/WebPopupMenu.h" |
| (...skipping 544 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 637 if (!GetContentClient()->renderer()->RunIdleHandlerWhenWidgetsHidden()) { | 636 if (!GetContentClient()->renderer()->RunIdleHandlerWhenWidgetsHidden()) { |
| 638 return; | 637 return; |
| 639 } | 638 } |
| 640 | 639 |
| 641 ScheduleIdleHandler(kLongIdleHandlerDelayMs); | 640 ScheduleIdleHandler(kLongIdleHandlerDelayMs); |
| 642 } | 641 } |
| 643 | 642 |
| 644 static void AdjustRuntimeFeatureDefaultsForPlatform() { | 643 static void AdjustRuntimeFeatureDefaultsForPlatform() { |
| 645 #if defined(OS_ANDROID) && !defined(GOOGLE_TV) | 644 #if defined(OS_ANDROID) && !defined(GOOGLE_TV) |
| 646 WebRuntimeFeatures::enableWebKitMediaSource(false); | 645 WebRuntimeFeatures::enableWebKitMediaSource(false); |
| 646 WebRuntimeFeatures::enableLegacyEncryptedMedia(false); |
| 647 WebRuntimeFeatures::enableEncryptedMedia(false); |
| 647 #endif | 648 #endif |
| 648 | 649 |
| 649 #if defined(OS_ANDROID) | 650 #if defined(OS_ANDROID) |
| 650 WebRuntimeFeatures::enableWebAudio(false); | 651 WebRuntimeFeatures::enableWebAudio(false); |
| 651 // Android does not support the Gamepad API. | 652 // Android does not support the Gamepad API. |
| 652 WebRuntimeFeatures::enableGamepad(false); | 653 WebRuntimeFeatures::enableGamepad(false); |
| 653 // input[type=week] in Android is incomplete. crbug.com/135938 | 654 // input[type=week] in Android is incomplete. crbug.com/135938 |
| 654 WebRuntimeFeatures::enableInputTypeWeek(false); | 655 WebRuntimeFeatures::enableInputTypeWeek(false); |
| 655 // Android does not have support for PagePopup | 656 // Android does not have support for PagePopup |
| 656 WebRuntimeFeatures::enablePagePopup(false); | 657 WebRuntimeFeatures::enablePagePopup(false); |
| (...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 698 if (command_line.HasSwitch(switches::kEnableWebAudio)) | 699 if (command_line.HasSwitch(switches::kEnableWebAudio)) |
| 699 WebRuntimeFeatures::enableWebAudio(true); | 700 WebRuntimeFeatures::enableWebAudio(true); |
| 700 #else | 701 #else |
| 701 if (command_line.HasSwitch(switches::kDisableWebAudio)) | 702 if (command_line.HasSwitch(switches::kDisableWebAudio)) |
| 702 WebRuntimeFeatures::enableWebAudio(false); | 703 WebRuntimeFeatures::enableWebAudio(false); |
| 703 #endif | 704 #endif |
| 704 | 705 |
| 705 if (command_line.HasSwitch(switches::kDisableFullScreen)) | 706 if (command_line.HasSwitch(switches::kDisableFullScreen)) |
| 706 WebRuntimeFeatures::enableFullscreen(false); | 707 WebRuntimeFeatures::enableFullscreen(false); |
| 707 | 708 |
| 708 if (command_line.HasSwitch(switches::kDisableEncryptedMedia)) | 709 if (command_line.HasSwitch(switches::kEnableEncryptedMedia)) |
| 709 WebRuntimeFeatures::enableEncryptedMedia(false); | 710 WebRuntimeFeatures::enableEncryptedMedia(true); |
| 711 |
| 712 if (command_line.HasSwitch(switches::kDisableLegacyEncryptedMedia)) |
| 713 WebRuntimeFeatures::enableLegacyEncryptedMedia(false); |
| 710 | 714 |
| 711 if (command_line.HasSwitch(switches::kEnableWebMIDI)) | 715 if (command_line.HasSwitch(switches::kEnableWebMIDI)) |
| 712 WebRuntimeFeatures::enableWebMIDI(true); | 716 WebRuntimeFeatures::enableWebMIDI(true); |
| 713 | 717 |
| 714 if (command_line.HasSwitch(switches::kEnableDeviceMotion)) | 718 if (command_line.HasSwitch(switches::kEnableDeviceMotion)) |
| 715 WebRuntimeFeatures::enableDeviceMotion(true); | 719 WebRuntimeFeatures::enableDeviceMotion(true); |
| 716 | 720 |
| 717 if (command_line.HasSwitch(switches::kDisableDeviceOrientation)) | 721 if (command_line.HasSwitch(switches::kDisableDeviceOrientation)) |
| 718 WebRuntimeFeatures::enableDeviceOrientation(false); | 722 WebRuntimeFeatures::enableDeviceOrientation(false); |
| 719 | 723 |
| (...skipping 621 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1341 | 1345 |
| 1342 void RenderThreadImpl::SetFlingCurveParameters( | 1346 void RenderThreadImpl::SetFlingCurveParameters( |
| 1343 const std::vector<float>& new_touchpad, | 1347 const std::vector<float>& new_touchpad, |
| 1344 const std::vector<float>& new_touchscreen) { | 1348 const std::vector<float>& new_touchscreen) { |
| 1345 webkit_platform_support_->SetFlingCurveParameters(new_touchpad, | 1349 webkit_platform_support_->SetFlingCurveParameters(new_touchpad, |
| 1346 new_touchscreen); | 1350 new_touchscreen); |
| 1347 | 1351 |
| 1348 } | 1352 } |
| 1349 | 1353 |
| 1350 } // namespace content | 1354 } // namespace content |
| OLD | NEW |