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

Unified Diff: content/browser/android/text_suggestion_host_impl.h

Issue 2931443003: Add support for Android spellcheck menu in Chrome/WebViews (Closed)
Patch Set: Created 3 years, 6 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
Index: content/browser/android/text_suggestion_host_impl.h
diff --git a/content/browser/android/text_suggestion_host_impl.h b/content/browser/android/text_suggestion_host_impl.h
new file mode 100644
index 0000000000000000000000000000000000000000..4f244046a2eb0db89c1a3228a7326ce970b6e6c6
--- /dev/null
+++ b/content/browser/android/text_suggestion_host_impl.h
@@ -0,0 +1,40 @@
+// Copyright 2017 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 TEXT_SUGGESTION_HOST_IMPL_H_
+#define TEXT_SUGGESTION_HOST_IMPL_H_
+
+#include "third_party/WebKit/public/platform/input_host.mojom.h"
+
+namespace service_manager {
+struct BindSourceInfo;
+}
+
+namespace content {
+
+class ImeAdapterAndroid;
+
+class TextSuggestionHostImpl : public blink::mojom::TextSuggestionHost {
yosin_UTC9 2017/06/07 01:34:15 Could you add class level comment? Is this |final|
+ public:
+ explicit TextSuggestionHostImpl(ImeAdapterAndroid*);
+
+ static void Create(ImeAdapterAndroid*,
+ const service_manager::BindSourceInfo& source_info,
+ blink::mojom::TextSuggestionHostRequest request);
+
+ void StartSpellCheckMenuTimer();
+
+ void ShowSpellCheckSuggestionMenu(
+ double caret_x,
+ double caret_y,
+ const std::string& marked_text,
+ std::vector<blink::mojom::SpellCheckSuggestionPtr> suggestions) override;
+
+ private:
+ ImeAdapterAndroid* ime_adapter_android_;
yosin_UTC9 2017/06/07 01:34:15 nit: s/ImeAdapterAndroid*/ImeAdapterAndroid* const
+};
yosin_UTC9 2017/06/07 01:34:15 Please add DISALLOW_COPY_AND_ASSIGN(...)
+
+} // namespace content
+
+#endif // TEXT_SUGGESTION_HOST_IMPL_H_

Powered by Google App Engine
This is Rietveld 408576698