BookmarkManager: Fix 'new folder text field size changes on clicking it' issue.
[chromium-blink-merge.git] / chrome / browser / translate / translate_accept_languages_factory.h
blob7215da3be28d720bc48e6c73a122a212a7609a44
1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef CHROME_BROWSER_TRANSLATE_TRANSLATE_ACCEPT_LANGUAGES_FACTORY_H_
6 #define CHROME_BROWSER_TRANSLATE_TRANSLATE_ACCEPT_LANGUAGES_FACTORY_H_
8 #include "base/basictypes.h"
9 #include "base/memory/singleton.h"
10 #include "components/keyed_service/content/browser_context_keyed_service_factory.h"
12 namespace translate {
13 class TranslateAcceptLanguages;
16 // TranslateAcceptLanguagesFactory is a way to associate a
17 // TranslateAcceptLanguages instance to a BrowserContext.
18 class TranslateAcceptLanguagesFactory
19 : public BrowserContextKeyedServiceFactory {
20 public:
21 static translate::TranslateAcceptLanguages* GetForBrowserContext(
22 content::BrowserContext* browser_context);
23 static TranslateAcceptLanguagesFactory* GetInstance();
25 private:
26 friend struct base::DefaultSingletonTraits<TranslateAcceptLanguagesFactory>;
28 TranslateAcceptLanguagesFactory();
29 ~TranslateAcceptLanguagesFactory() override;
31 // BrowserContextKeyedServiceFactory:
32 KeyedService* BuildServiceInstanceFor(
33 content::BrowserContext* profile) const override;
34 content::BrowserContext* GetBrowserContextToUse(
35 content::BrowserContext* context) const override;
37 DISALLOW_COPY_AND_ASSIGN(TranslateAcceptLanguagesFactory);
40 #endif // CHROME_BROWSER_TRANSLATE_TRANSLATE_ACCEPT_LANGUAGES_FACTORY_H_