diff options
Diffstat (limited to 'src/core/web_contents_view_qt.cpp')
-rw-r--r-- | src/core/web_contents_view_qt.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/core/web_contents_view_qt.cpp b/src/core/web_contents_view_qt.cpp index daf2d48b4..4f921bd07 100644 --- a/src/core/web_contents_view_qt.cpp +++ b/src/core/web_contents_view_qt.cpp @@ -46,6 +46,7 @@ #include "web_contents_adapter.h" #include "web_engine_context.h" +#include "components/spellcheck/spellcheck_build_features.h" #include "content/browser/renderer_host/render_view_host_impl.h" #include "content/public/common/context_menu_params.h" #include <ui/gfx/image/image_skia.h> @@ -168,7 +169,7 @@ static inline WebEngineContextMenuData fromParams(const content::ContextMenuPara ret.setMediaFlags((WebEngineContextMenuData::MediaFlags)params.media_flags); ret.setSuggestedFileName(toQt(params.suggested_filename.data())); ret.setIsEditable(params.is_editable); -#if defined(ENABLE_SPELLCHECK) +#if BUILDFLAG(ENABLE_SPELLCHECK) ret.setMisspelledWord(toQt(params.misspelled_word)); ret.setSpellCheckerSuggestions(fromVector(params.dictionary_suggestions)); #endif @@ -178,7 +179,7 @@ static inline WebEngineContextMenuData fromParams(const content::ContextMenuPara void WebContentsViewQt::ShowContextMenu(content::RenderFrameHost *, const content::ContextMenuParams ¶ms) { WebEngineContextMenuData contextMenuData(fromParams(params)); -#if defined(ENABLE_SPELLCHECK) +#if BUILDFLAG(ENABLE_SPELLCHECK) // Do not use params.spellcheck_enabled, since it is never // correctly initialized for chrome asynchronous spellchecking. // Even fixing the initialization in ContextMenuClientImpl::showContextMenu |