| 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 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 71 #include "content/renderer/render_process_impl.h" | 71 #include "content/renderer/render_process_impl.h" |
| 72 #include "content/renderer/render_view_impl.h" | 72 #include "content/renderer/render_view_impl.h" |
| 73 #include "content/renderer/renderer_webkitplatformsupport_impl.h" | 73 #include "content/renderer/renderer_webkitplatformsupport_impl.h" |
| 74 #include "content/renderer/skia_benchmarking_extension.h" | 74 #include "content/renderer/skia_benchmarking_extension.h" |
| 75 #include "grit/content_resources.h" | 75 #include "grit/content_resources.h" |
| 76 #include "ipc/ipc_channel_handle.h" | 76 #include "ipc/ipc_channel_handle.h" |
| 77 #include "ipc/ipc_forwarding_message_filter.h" | 77 #include "ipc/ipc_forwarding_message_filter.h" |
| 78 #include "ipc/ipc_platform_file.h" | 78 #include "ipc/ipc_platform_file.h" |
| 79 #include "media/base/audio_hardware_config.h" | 79 #include "media/base/audio_hardware_config.h" |
| 80 #include "media/base/media.h" | 80 #include "media/base/media.h" |
| 81 #include "media/base/media_switches.h" | |
| 82 #include "net/base/net_errors.h" | 81 #include "net/base/net_errors.h" |
| 83 #include "net/base/net_util.h" | 82 #include "net/base/net_util.h" |
| 84 #include "third_party/WebKit/Source/Platform/chromium/public/WebString.h" | 83 #include "third_party/WebKit/Source/Platform/chromium/public/WebString.h" |
| 85 #include "third_party/WebKit/Source/WebKit/chromium/public/WebColorName.h" | 84 #include "third_party/WebKit/Source/WebKit/chromium/public/WebColorName.h" |
| 86 #include "third_party/WebKit/Source/WebKit/chromium/public/WebDatabase.h" | 85 #include "third_party/WebKit/Source/WebKit/chromium/public/WebDatabase.h" |
| 87 #include "third_party/WebKit/Source/WebKit/chromium/public/WebDocument.h" | 86 #include "third_party/WebKit/Source/WebKit/chromium/public/WebDocument.h" |
| 88 #include "third_party/WebKit/Source/WebKit/chromium/public/WebFrame.h" | 87 #include "third_party/WebKit/Source/WebKit/chromium/public/WebFrame.h" |
| 89 #include "third_party/WebKit/Source/WebKit/chromium/public/WebKit.h" | 88 #include "third_party/WebKit/Source/WebKit/chromium/public/WebKit.h" |
| 90 #include "third_party/WebKit/Source/WebKit/chromium/public/WebNetworkStateNotifi
er.h" | 89 #include "third_party/WebKit/Source/WebKit/chromium/public/WebNetworkStateNotifi
er.h" |
| 91 #include "third_party/WebKit/Source/WebKit/chromium/public/WebPopupMenu.h" | 90 #include "third_party/WebKit/Source/WebKit/chromium/public/WebPopupMenu.h" |
| (...skipping 539 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 631 if (!GetContentClient()->renderer()->RunIdleHandlerWhenWidgetsHidden()) { | 630 if (!GetContentClient()->renderer()->RunIdleHandlerWhenWidgetsHidden()) { |
| 632 return; | 631 return; |
| 633 } | 632 } |
| 634 | 633 |
| 635 ScheduleIdleHandler(kLongIdleHandlerDelayMs); | 634 ScheduleIdleHandler(kLongIdleHandlerDelayMs); |
| 636 } | 635 } |
| 637 | 636 |
| 638 static void AdjustRuntimeFeatureDefaultsForPlatform() { | 637 static void AdjustRuntimeFeatureDefaultsForPlatform() { |
| 639 #if defined(OS_ANDROID) && !defined(GOOGLE_TV) | 638 #if defined(OS_ANDROID) && !defined(GOOGLE_TV) |
| 640 WebRuntimeFeatures::enableWebKitMediaSource(false); | 639 WebRuntimeFeatures::enableWebKitMediaSource(false); |
| 640 WebRuntimeFeatures::enableLegacyEncryptedMedia(false); |
| 641 WebRuntimeFeatures::enableEncryptedMedia(false); |
| 641 #endif | 642 #endif |
| 642 | 643 |
| 643 #if defined(OS_ANDROID) | 644 #if defined(OS_ANDROID) |
| 644 WebRuntimeFeatures::enableWebAudio(false); | 645 WebRuntimeFeatures::enableWebAudio(false); |
| 645 // Web Speech API Speech recognition is not implemented on Android yet. | 646 // Web Speech API Speech recognition is not implemented on Android yet. |
| 646 WebRuntimeFeatures::enableScriptedSpeech(false); | 647 WebRuntimeFeatures::enableScriptedSpeech(false); |
| 647 // Android does not support the Gamepad API. | 648 // Android does not support the Gamepad API. |
| 648 WebRuntimeFeatures::enableGamepad(false); | 649 WebRuntimeFeatures::enableGamepad(false); |
| 649 // input[type=week] in Android is incomplete. crbug.com/135938 | 650 // input[type=week] in Android is incomplete. crbug.com/135938 |
| 650 WebRuntimeFeatures::enableInputTypeWeek(false); | 651 WebRuntimeFeatures::enableInputTypeWeek(false); |
| (...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 683 #endif | 684 #endif |
| 684 | 685 |
| 685 #if defined(OS_ANDROID) | 686 #if defined(OS_ANDROID) |
| 686 if (command_line.HasSwitch(switches::kDisableWebRTC)) | 687 if (command_line.HasSwitch(switches::kDisableWebRTC)) |
| 687 WebRuntimeFeatures::enablePeerConnection(false); | 688 WebRuntimeFeatures::enablePeerConnection(false); |
| 688 #endif | 689 #endif |
| 689 | 690 |
| 690 if (command_line.HasSwitch(switches::kDisableFullScreen)) | 691 if (command_line.HasSwitch(switches::kDisableFullScreen)) |
| 691 WebRuntimeFeatures::enableFullscreen(false); | 692 WebRuntimeFeatures::enableFullscreen(false); |
| 692 | 693 |
| 693 if (command_line.HasSwitch(switches::kDisableEncryptedMedia)) | 694 if (command_line.HasSwitch(switches::kEnableEncryptedMedia)) |
| 694 WebRuntimeFeatures::enableEncryptedMedia(false); | 695 WebRuntimeFeatures::enableEncryptedMedia(true); |
| 696 |
| 697 if (command_line.HasSwitch(switches::kDisableLegacyEncryptedMedia)) |
| 698 WebRuntimeFeatures::enableLegacyEncryptedMedia(false); |
| 695 | 699 |
| 696 #if defined(OS_ANDROID) | 700 #if defined(OS_ANDROID) |
| 697 if (command_line.HasSwitch(switches::kEnableWebAudio)) | 701 if (command_line.HasSwitch(switches::kEnableWebAudio)) |
| 698 WebRuntimeFeatures::enableWebAudio(true); | 702 WebRuntimeFeatures::enableWebAudio(true); |
| 699 #else | 703 #else |
| 700 if (command_line.HasSwitch(switches::kDisableWebAudio)) | 704 if (command_line.HasSwitch(switches::kDisableWebAudio)) |
| 701 WebRuntimeFeatures::enableWebAudio(false); | 705 WebRuntimeFeatures::enableWebAudio(false); |
| 702 #endif | 706 #endif |
| 703 | 707 |
| 704 if (command_line.HasSwitch(switches::kEnableWebMIDI)) | 708 if (command_line.HasSwitch(switches::kEnableWebMIDI)) |
| (...skipping 612 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1317 | 1321 |
| 1318 void RenderThreadImpl::SetFlingCurveParameters( | 1322 void RenderThreadImpl::SetFlingCurveParameters( |
| 1319 const std::vector<float>& new_touchpad, | 1323 const std::vector<float>& new_touchpad, |
| 1320 const std::vector<float>& new_touchscreen) { | 1324 const std::vector<float>& new_touchscreen) { |
| 1321 webkit_platform_support_->SetFlingCurveParameters(new_touchpad, | 1325 webkit_platform_support_->SetFlingCurveParameters(new_touchpad, |
| 1322 new_touchscreen); | 1326 new_touchscreen); |
| 1323 | 1327 |
| 1324 } | 1328 } |
| 1325 | 1329 |
| 1326 } // namespace content | 1330 } // namespace content |
| OLD | NEW |