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

Unified Diff: chrome/renderer/spellchecker/custom_dictionary_engine.h

Issue 2198143002: Componentize spellcheck [3]: move renderer/ files to component. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 4 years, 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/renderer/spellchecker/OWNERS ('k') | chrome/renderer/spellchecker/custom_dictionary_engine.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/renderer/spellchecker/custom_dictionary_engine.h
diff --git a/chrome/renderer/spellchecker/custom_dictionary_engine.h b/chrome/renderer/spellchecker/custom_dictionary_engine.h
deleted file mode 100644
index be594bb1fa67621e9541dcc3e112505a115a524a..0000000000000000000000000000000000000000
--- a/chrome/renderer/spellchecker/custom_dictionary_engine.h
+++ /dev/null
@@ -1,43 +0,0 @@
-// Copyright (c) 2012 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#ifndef CHROME_RENDERER_SPELLCHECKER_CUSTOM_DICTIONARY_ENGINE_H_
-#define CHROME_RENDERER_SPELLCHECKER_CUSTOM_DICTIONARY_ENGINE_H_
-
-#include <set>
-#include <string>
-
-#include "base/macros.h"
-#include "base/strings/string16.h"
-
-// Custom spellcheck dictionary. Words in this dictionary are always correctly
-// spelled. Words that are not in this dictionary may or may not be correctly
-// spelled.
-class CustomDictionaryEngine {
- public:
- CustomDictionaryEngine();
- ~CustomDictionaryEngine();
-
- // Initialize the custom dictionary engine.
- void Init(const std::set<std::string>& words);
-
- // Spellcheck |text|. Assumes that another spelling engine has set
- // |misspelling_start| and |misspelling_len| to indicate a misspelling.
- // Returns true if there are no misspellings, otherwise returns false.
- bool SpellCheckWord(const base::string16& text,
- int misspelling_start,
- int misspelling_len);
-
- // Update custom dictionary words.
- void OnCustomDictionaryChanged(const std::set<std::string>& words_added,
- const std::set<std::string>& words_removed);
-
- private:
- // Correctly spelled words.
- std::set<base::string16> dictionary_;
-
- DISALLOW_COPY_AND_ASSIGN(CustomDictionaryEngine);
-};
-
-#endif // CHROME_RENDERER_SPELLCHECKER_CUSTOM_DICTIONARY_ENGINE_H_
« no previous file with comments | « chrome/renderer/spellchecker/OWNERS ('k') | chrome/renderer/spellchecker/custom_dictionary_engine.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698