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

Side by Side Diff: chrome/renderer/spellchecker/hunspell_engine.h

Issue 105493002: Use base namespace for string16 in chrome/renderer. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years 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 #ifndef CHROME_RENDERER_SPELLCHECKER_HUNSPELL_ENGINE_H_ 5 #ifndef CHROME_RENDERER_SPELLCHECKER_HUNSPELL_ENGINE_H_
6 #define CHROME_RENDERER_SPELLCHECKER_HUNSPELL_ENGINE_H_ 6 #define CHROME_RENDERER_SPELLCHECKER_HUNSPELL_ENGINE_H_
7 7
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 11 matching lines...) Expand all
22 22
23 class HunspellEngine : public SpellingEngine { 23 class HunspellEngine : public SpellingEngine {
24 public: 24 public:
25 HunspellEngine(); 25 HunspellEngine();
26 virtual ~HunspellEngine(); 26 virtual ~HunspellEngine();
27 27
28 virtual void Init(base::PlatformFile file) OVERRIDE; 28 virtual void Init(base::PlatformFile file) OVERRIDE;
29 29
30 virtual bool InitializeIfNeeded() OVERRIDE; 30 virtual bool InitializeIfNeeded() OVERRIDE;
31 virtual bool IsEnabled() OVERRIDE; 31 virtual bool IsEnabled() OVERRIDE;
32 virtual bool CheckSpelling(const string16& word_to_check, int tag) OVERRIDE; 32 virtual bool CheckSpelling(const base::string16& word_to_check,
33 virtual void FillSuggestionList(const string16& wrong_word, 33 int tag) OVERRIDE;
34 std::vector<string16>* optional_suggestions) OVERRIDE; 34 virtual void FillSuggestionList(
35 const base::string16& wrong_word,
36 std::vector<base::string16>* optional_suggestions) OVERRIDE;
35 37
36 private: 38 private:
37 // Initializes the Hunspell dictionary, or does nothing if |hunspell_| is 39 // Initializes the Hunspell dictionary, or does nothing if |hunspell_| is
38 // non-null. This blocks. 40 // non-null. This blocks.
39 void InitializeHunspell(); 41 void InitializeHunspell();
40 42
41 // We memory-map the BDict file. 43 // We memory-map the BDict file.
42 scoped_ptr<base::MemoryMappedFile> bdict_file_; 44 scoped_ptr<base::MemoryMappedFile> bdict_file_;
43 45
44 // The hunspell dictionary in use. 46 // The hunspell dictionary in use.
45 scoped_ptr<Hunspell> hunspell_; 47 scoped_ptr<Hunspell> hunspell_;
46 48
47 base::PlatformFile file_; 49 base::PlatformFile file_;
48 50
49 // This flags is true if we have been initialized. 51 // This flags is true if we have been initialized.
50 // The value indicates whether we should request a 52 // The value indicates whether we should request a
51 // dictionary from the browser when the render view asks us to check the 53 // dictionary from the browser when the render view asks us to check the
52 // spelling of a word. 54 // spelling of a word.
53 bool initialized_; 55 bool initialized_;
54 56
55 // This flags is true if we have requested dictionary. 57 // This flags is true if we have requested dictionary.
56 bool dictionary_requested_; 58 bool dictionary_requested_;
57 }; 59 };
58 60
59 #endif // CHROME_RENDERER_SPELLCHECKER_HUNSPELL_ENGINE_H_ 61 #endif // CHROME_RENDERER_SPELLCHECKER_HUNSPELL_ENGINE_H_
OLDNEW
« no previous file with comments | « chrome/renderer/spellchecker/custom_dictionary_engine_unittest.cc ('k') | chrome/renderer/spellchecker/hunspell_engine.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698