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

Unified Diff: chrome/renderer/chrome_content_renderer_client.cc

Issue 2818043002: Make SpellCheckPanel compiled and used only on Mac (Closed)
Patch Set: Created 3 years, 8 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 | « no previous file | components/spellcheck/BUILD.gn » ('j') | components/spellcheck/renderer/BUILD.gn » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/renderer/chrome_content_renderer_client.cc
diff --git a/chrome/renderer/chrome_content_renderer_client.cc b/chrome/renderer/chrome_content_renderer_client.cc
index 6323036503bc8aea513bf7b928abd32d94b5de08..6183e98894f5539d3034669c7f805173abdcc2ca 100644
--- a/chrome/renderer/chrome_content_renderer_client.cc
+++ b/chrome/renderer/chrome_content_renderer_client.cc
@@ -164,8 +164,11 @@
#if BUILDFLAG(ENABLE_SPELLCHECK)
#include "components/spellcheck/renderer/spellcheck.h"
-#include "components/spellcheck/renderer/spellcheck_panel.h"
#include "components/spellcheck/renderer/spellcheck_provider.h"
+
+#if BUILDFLAG(HAS_SPELLCHECK_PANEL)
+#include "components/spellcheck/renderer/spellcheck_panel.h"
+#endif
Lei Zhang 2017/04/14 00:55:38 Which #endif is which? Once you have nested #ifs,
Xiaocheng 2017/04/14 01:20:18 Done.
#endif
#if BUILDFLAG(ENABLE_WEBRTC)
@@ -596,8 +599,11 @@ void ChromeContentRendererClient::RenderViewCreated(
if (SpellCheckProvider* provider =
SpellCheckProvider::Get(render_view->GetMainRenderFrame()))
provider->EnableSpellcheck(spellcheck_->IsSpellcheckEnabled());
+
+#if BUILDFLAG(HAS_SPELLCHECK_PANEL)
new SpellCheckPanel(render_view);
#endif
+#endif
new prerender::PrerendererClient(render_view);
new ChromeRenderViewObserver(render_view, web_cache_impl_.get());
« no previous file with comments | « no previous file | components/spellcheck/BUILD.gn » ('j') | components/spellcheck/renderer/BUILD.gn » ('J')

Powered by Google App Engine
This is Rietveld 408576698