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 #ifndef CHROME_BROWSER_SPELLCHECKER_SPELLCHECK_HUNSPELL_DICTIONARY_H_ | 5 #ifndef CHROME_BROWSER_SPELLCHECKER_SPELLCHECK_HUNSPELL_DICTIONARY_H_ |
6 #define CHROME_BROWSER_SPELLCHECKER_SPELLCHECK_HUNSPELL_DICTIONARY_H_ | 6 #define CHROME_BROWSER_SPELLCHECKER_SPELLCHECK_HUNSPELL_DICTIONARY_H_ |
7 | 7 |
8 #include "chrome/browser/spellchecker/spellcheck_dictionary.h" | 8 #include "chrome/browser/spellchecker/spellcheck_dictionary.h" |
9 | 9 |
10 #include "base/file_path.h" | 10 #include "base/file_path.h" |
11 #include "base/platform_file.h" | 11 #include "base/platform_file.h" |
12 #include "base/memory/scoped_ptr.h" | 12 #include "base/memory/scoped_ptr.h" |
13 #include "base/memory/weak_ptr.h" | 13 #include "base/memory/weak_ptr.h" |
14 #include "net/url_request/url_fetcher_delegate.h" | 14 #include "net/url_request/url_fetcher_delegate.h" |
15 | 15 |
16 class Profile; | 16 class Profile; |
17 class SpellcheckService; | 17 class SpellcheckService; |
18 | 18 |
19 namespace net { | 19 namespace net { |
20 class URLFetcher; | 20 class URLFetcher; |
21 class URLRequestContextGetter; | 21 class URLRequestContextGetter; |
22 } // namespace net | 22 } // namespace net |
23 | 23 |
24 // Defines a the browser-side hunspell dictionary and provides access to it. | 24 // Defines the browser-side hunspell dictionary and provides access to it. |
25 class SpellcheckHunspellDictionary | 25 class SpellcheckHunspellDictionary |
26 : public SpellcheckDictionary, | 26 : public SpellcheckDictionary, |
27 public net::URLFetcherDelegate { | 27 public net::URLFetcherDelegate { |
28 public: | 28 public: |
29 // TODO(rlp): Passing in the host is very temporary. In the next CL this | 29 // TODO(rlp): Passing in the host is very temporary. In the next CL this |
30 // will be removed. | 30 // will be removed. |
31 SpellcheckHunspellDictionary( | 31 SpellcheckHunspellDictionary( |
32 Profile* profile, | 32 Profile* profile, |
33 const std::string& language, | 33 const std::string& language, |
34 net::URLRequestContextGetter* request_context_getter, | 34 net::URLRequestContextGetter* request_context_getter, |
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
103 scoped_ptr<net::URLFetcher> fetcher_; | 103 scoped_ptr<net::URLFetcher> fetcher_; |
104 | 104 |
105 base::WeakPtrFactory<SpellcheckHunspellDictionary> weak_ptr_factory_; | 105 base::WeakPtrFactory<SpellcheckHunspellDictionary> weak_ptr_factory_; |
106 | 106 |
107 SpellcheckService* spellcheck_service_; | 107 SpellcheckService* spellcheck_service_; |
108 | 108 |
109 DISALLOW_COPY_AND_ASSIGN(SpellcheckHunspellDictionary); | 109 DISALLOW_COPY_AND_ASSIGN(SpellcheckHunspellDictionary); |
110 }; | 110 }; |
111 | 111 |
112 #endif // CHROME_BROWSER_SPELLCHECKER_SPELLCHECK_HUNSPELL_DICTIONARY_H_ | 112 #endif // CHROME_BROWSER_SPELLCHECKER_SPELLCHECK_HUNSPELL_DICTIONARY_H_ |
OLD | NEW |