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

Side by Side Diff: content/browser/browser_main_loop.cc

Issue 11347004: content/browser: Move speech code into content namespace. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 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 | Annotate | Revision Log
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/browser/browser_main_loop.h" 5 #include "content/browser/browser_main_loop.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/debug/trace_event.h" 9 #include "base/debug/trace_event.h"
10 #include "base/hi_res_timer_manager.h" 10 #include "base/hi_res_timer_manager.h"
(...skipping 645 matching lines...) Expand 10 before | Expand all | Expand 10 after
656 656
657 // RDH needs the IO thread to be created. 657 // RDH needs the IO thread to be created.
658 resource_dispatcher_host_.reset(new ResourceDispatcherHostImpl()); 658 resource_dispatcher_host_.reset(new ResourceDispatcherHostImpl());
659 659
660 // Initialize the GpuDataManager before we set up the MessageLoops because 660 // Initialize the GpuDataManager before we set up the MessageLoops because
661 // otherwise we'll trigger the assertion about doing IO on the UI thread. 661 // otherwise we'll trigger the assertion about doing IO on the UI thread.
662 GpuDataManagerImpl::GetInstance()->Initialize(); 662 GpuDataManagerImpl::GetInstance()->Initialize();
663 #endif // !OS_IOS 663 #endif // !OS_IOS
664 664
665 #if defined(ENABLE_INPUT_SPEECH) 665 #if defined(ENABLE_INPUT_SPEECH)
666 speech_recognition_manager_.reset(new speech::SpeechRecognitionManagerImpl()); 666 speech_recognition_manager_.reset(new SpeechRecognitionManagerImpl());
667 #endif 667 #endif
668 668
669 #if !defined(OS_IOS) 669 #if !defined(OS_IOS)
670 // Alert the clipboard class to which threads are allowed to access the 670 // Alert the clipboard class to which threads are allowed to access the
671 // clipboard: 671 // clipboard:
672 std::vector<base::PlatformThreadId> allowed_clipboard_threads; 672 std::vector<base::PlatformThreadId> allowed_clipboard_threads;
673 // The current thread is the UI thread. 673 // The current thread is the UI thread.
674 allowed_clipboard_threads.push_back(base::PlatformThread::CurrentId()); 674 allowed_clipboard_threads.push_back(base::PlatformThread::CurrentId());
675 #if defined(OS_WIN) 675 #if defined(OS_WIN)
676 // On Windows, clipboards are also used on the File or IO threads. 676 // On Windows, clipboards are also used on the File or IO threads.
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
729 DCHECK_EQ(MessageLoop::TYPE_UI, MessageLoop::current()->type()); 729 DCHECK_EQ(MessageLoop::TYPE_UI, MessageLoop::current()->type());
730 if (parameters_.ui_task) 730 if (parameters_.ui_task)
731 MessageLoopForUI::current()->PostTask(FROM_HERE, *parameters_.ui_task); 731 MessageLoopForUI::current()->PostTask(FROM_HERE, *parameters_.ui_task);
732 732
733 base::RunLoop run_loop; 733 base::RunLoop run_loop;
734 run_loop.Run(); 734 run_loop.Run();
735 #endif 735 #endif
736 } 736 }
737 737
738 } // namespace content 738 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698