1 // Copyright (c) 2011 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_SPELLCHECKER_SPELLCHECK_PROFILE_PROVIDER_H_
6 #define CHROME_BROWSER_SPELLCHECKER_SPELLCHECK_PROFILE_PROVIDER_H_
12 // A user profile provider and state notification receiver for the
14 class SpellCheckProfileProvider
{
16 typedef std::vector
<std::string
> CustomWordList
;
18 // Invoked on the UI thread when SpellCheckHost is initialized.
19 virtual void SpellCheckHostInitialized(
20 CustomWordList
* custom_words
) = 0;
22 // Returns in-memory cache of custom word list.
23 virtual const CustomWordList
& GetCustomWords() const = 0;
25 // Invoked on the Ui thread when new custom word is registered.
26 virtual void CustomWordAddedLocally(const std::string
& word
) = 0;
28 // Loads the custom dictionary associated with this profile
29 virtual void LoadCustomDictionary(CustomWordList
* custom_words
) = 0;
31 // Writes a word to the custom dictionary associated with this profile.
32 virtual void WriteWordToCustomDictionary(const std::string
& word
) = 0;
35 virtual ~SpellCheckProfileProvider() {}
38 #endif // CHROME_BROWSER_SPELLCHECKER_SPELLCHECK_PROFILE_PROVIDER_H_