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

Side by Side Diff: chrome/browser/search/hotword_service_factory.h

Issue 554603002: Fix a browser crash on opening 'chrome://voicesearch' in guest mode. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 3 months 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
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 #ifndef CHROME_BROWSER_SEARCH_HOTWORD_SERVICE_FACTORY_H_ 5 #ifndef CHROME_BROWSER_SEARCH_HOTWORD_SERVICE_FACTORY_H_
6 #define CHROME_BROWSER_SEARCH_HOTWORD_SERVICE_FACTORY_H_ 6 #define CHROME_BROWSER_SEARCH_HOTWORD_SERVICE_FACTORY_H_
7 7
8 #include "base/memory/singleton.h" 8 #include "base/memory/singleton.h"
9 #include "chrome/browser/media/media_capture_devices_dispatcher.h" 9 #include "chrome/browser/media/media_capture_devices_dispatcher.h"
10 #include "components/keyed_service/content/browser_context_keyed_service_factory .h" 10 #include "components/keyed_service/content/browser_context_keyed_service_factory .h"
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
51 friend struct DefaultSingletonTraits<HotwordServiceFactory>; 51 friend struct DefaultSingletonTraits<HotwordServiceFactory>;
52 52
53 HotwordServiceFactory(); 53 HotwordServiceFactory();
54 virtual ~HotwordServiceFactory(); 54 virtual ~HotwordServiceFactory();
55 55
56 // Overrides from BrowserContextKeyedServiceFactory: 56 // Overrides from BrowserContextKeyedServiceFactory:
57 virtual void RegisterProfilePrefs( 57 virtual void RegisterProfilePrefs(
58 user_prefs::PrefRegistrySyncable* registry) OVERRIDE; 58 user_prefs::PrefRegistrySyncable* registry) OVERRIDE;
59 virtual KeyedService* BuildServiceInstanceFor( 59 virtual KeyedService* BuildServiceInstanceFor(
60 content::BrowserContext* context) const OVERRIDE; 60 content::BrowserContext* context) const OVERRIDE;
61 virtual content::BrowserContext* GetBrowserContextToUse(
62 content::BrowserContext* context) const OVERRIDE;
61 63
62 // Must be called from the UI thread since the instance of 64 // Must be called from the UI thread since the instance of
63 // MediaCaptureDevicesDispatcher can only be accessed on the UI thread. 65 // MediaCaptureDevicesDispatcher can only be accessed on the UI thread.
64 void InitializeMicrophoneObserver(); 66 void InitializeMicrophoneObserver();
65 67
66 bool microphone_available() { return microphone_available_; } 68 bool microphone_available() { return microphone_available_; }
67 69
68 bool microphone_available_; 70 bool microphone_available_;
69 71
70 DISALLOW_COPY_AND_ASSIGN(HotwordServiceFactory); 72 DISALLOW_COPY_AND_ASSIGN(HotwordServiceFactory);
71 }; 73 };
72 74
73 #endif // CHROME_BROWSER_SEARCH_HOTWORD_SERVICE_FACTORY_H_ 75 #endif // CHROME_BROWSER_SEARCH_HOTWORD_SERVICE_FACTORY_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/search/hotword_service_factory.cc » ('j') | chrome/browser/search/hotword_service_factory.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698