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

Unified Diff: chrome/browser/spellchecker/spellcheck_message_filter.cc

Issue 8890022: Remove Hunspell on OS X - step 2 (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Fix rename in unittest Created 9 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/spellchecker/spellcheck_message_filter.cc
diff --git a/chrome/browser/spellchecker/spellcheck_message_filter.cc b/chrome/browser/spellchecker/spellcheck_message_filter.cc
index 622995e1599decd76ae42cfc845af0973e8ecf79..bfd0282c4c07d5a16a0b7e20f2f57a867e479990 100644
--- a/chrome/browser/spellchecker/spellcheck_message_filter.cc
+++ b/chrome/browser/spellchecker/spellcheck_message_filter.cc
@@ -8,7 +8,7 @@
#include "chrome/browser/profiles/profile.h"
#include "chrome/browser/spellchecker/spellcheck_host.h"
#include "chrome/browser/spellchecker/spellcheck_host_metrics.h"
-#include "chrome/browser/spellchecker/spellchecker_platform_engine.h"
+#include "chrome/browser/spellchecker/spellcheck_platform_mac.h"
#include "chrome/common/spellcheck_messages.h"
#include "content/public/browser/render_process_host.h"
@@ -57,30 +57,42 @@ bool SpellCheckMessageFilter::OnMessageReceived(const IPC::Message& message,
void SpellCheckMessageFilter::OnPlatformCheckSpelling(const string16& word,
int tag,
bool* correct) {
- *correct = SpellCheckerPlatform::CheckSpelling(word, tag);
+#if defined(OS_MACOSX)
+ *correct = spellcheck_mac::CheckSpelling(word, tag);
+#endif
}
void SpellCheckMessageFilter::OnPlatformFillSuggestionList(
const string16& word,
std::vector<string16>* suggestions) {
- SpellCheckerPlatform::FillSuggestionList(word, suggestions);
+#if defined(OS_MACOSX)
+ spellcheck_mac::FillSuggestionList(word, suggestions);
+#endif
}
void SpellCheckMessageFilter::OnGetDocumentTag(int* tag) {
- *tag = SpellCheckerPlatform::GetDocumentTag();
+#if defined(OS_MACOSX)
+ *tag = spellcheck_mac::GetDocumentTag();
+#endif
}
void SpellCheckMessageFilter::OnDocumentWithTagClosed(int tag) {
- SpellCheckerPlatform::CloseDocumentWithTag(tag);
+#if defined(OS_MACOSX)
+ spellcheck_mac::CloseDocumentWithTag(tag);
+#endif
}
void SpellCheckMessageFilter::OnShowSpellingPanel(bool show) {
- SpellCheckerPlatform::ShowSpellingPanel(show);
+#if defined(OS_MACOSX)
+ spellcheck_mac::ShowSpellingPanel(show);
+#endif
}
void SpellCheckMessageFilter::OnUpdateSpellingPanelWithMisspelledWord(
const string16& word) {
- SpellCheckerPlatform::UpdateSpellingPanelWithMisspelledWord(word);
+#if defined(OS_MACOSX)
+ spellcheck_mac::UpdateSpellingPanelWithMisspelledWord(word);
+#endif
}
void SpellCheckMessageFilter::OnPlatformRequestTextCheck(
@@ -88,8 +100,10 @@ void SpellCheckMessageFilter::OnPlatformRequestTextCheck(
int identifier,
int document_tag,
const string16& text) {
- SpellCheckerPlatform::RequestTextCheck(
+#if defined(OS_MACOSX)
+ spellcheck_mac::RequestTextCheck(
route_id, identifier, document_tag, text, this);
+#endif
}
void SpellCheckMessageFilter::OnSpellCheckerRequestDictionary() {
« no previous file with comments | « chrome/browser/spellchecker/spellcheck_host_impl.cc ('k') | chrome/browser/spellchecker/spellcheck_platform_mac.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698