OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 485 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
496 WebRuntimeFeatures::enableWebAudio( | 496 WebRuntimeFeatures::enableWebAudio( |
497 !command_line.HasSwitch(switches::kDisableWebAudio)); | 497 !command_line.HasSwitch(switches::kDisableWebAudio)); |
498 #endif | 498 #endif |
499 | 499 |
500 WebRuntimeFeatures::enablePushState(true); | 500 WebRuntimeFeatures::enablePushState(true); |
501 | 501 |
502 #ifdef TOUCH_UI | 502 #ifdef TOUCH_UI |
503 WebRuntimeFeatures::enableTouch(true); | 503 WebRuntimeFeatures::enableTouch(true); |
504 WebKit::WebPopupMenu::setMinimumRowHeight(kPopupListBoxMinimumRowHeight); | 504 WebKit::WebPopupMenu::setMinimumRowHeight(kPopupListBoxMinimumRowHeight); |
505 #else | 505 #else |
506 // TODO(saintlou): in the future touch should always be enabled | |
507 WebRuntimeFeatures::enableTouch(false); | 506 WebRuntimeFeatures::enableTouch(false); |
508 #endif | 507 #endif |
509 | 508 |
510 WebRuntimeFeatures::enableDeviceMotion( | 509 WebRuntimeFeatures::enableDeviceMotion( |
511 command_line.HasSwitch(switches::kEnableDeviceMotion)); | 510 command_line.HasSwitch(switches::kEnableDeviceMotion)); |
512 | 511 |
513 WebRuntimeFeatures::enableDeviceOrientation( | 512 WebRuntimeFeatures::enableDeviceOrientation( |
514 !command_line.HasSwitch(switches::kDisableDeviceOrientation)); | 513 !command_line.HasSwitch(switches::kDisableDeviceOrientation)); |
515 | 514 |
516 WebRuntimeFeatures::enableSpeechInput( | 515 WebRuntimeFeatures::enableSpeechInput( |
(...skipping 265 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
782 | 781 |
783 scoped_refptr<base::MessageLoopProxy> | 782 scoped_refptr<base::MessageLoopProxy> |
784 RenderThreadImpl::GetFileThreadMessageLoopProxy() { | 783 RenderThreadImpl::GetFileThreadMessageLoopProxy() { |
785 DCHECK(message_loop() == MessageLoop::current()); | 784 DCHECK(message_loop() == MessageLoop::current()); |
786 if (!file_thread_.get()) { | 785 if (!file_thread_.get()) { |
787 file_thread_.reset(new base::Thread("Renderer::FILE")); | 786 file_thread_.reset(new base::Thread("Renderer::FILE")); |
788 file_thread_->Start(); | 787 file_thread_->Start(); |
789 } | 788 } |
790 return file_thread_->message_loop_proxy(); | 789 return file_thread_->message_loop_proxy(); |
791 } | 790 } |
OLD | NEW |