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

Unified Diff: services/keyboard_native/view_observer_delegate.h

Issue 1247903003: Add spellcheck and word suggestion to the prediction service (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Created 5 years, 5 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: services/keyboard_native/view_observer_delegate.h
diff --git a/services/keyboard_native/view_observer_delegate.h b/services/keyboard_native/view_observer_delegate.h
index 33c313c872fce354f828219bb4b8ebd65972568b..9e9fa653e31a1d968889561b8008ee820325b29e 100644
--- a/services/keyboard_native/view_observer_delegate.h
+++ b/services/keyboard_native/view_observer_delegate.h
@@ -19,6 +19,7 @@
namespace keyboard {
class KeyboardServiceImpl;
+class Predictor;
struct PointerState {
KeyLayout::Key* last_key;
@@ -39,6 +40,8 @@ class ViewObserverDelegate : public mojo::ViewObserver {
void OnFrameComplete();
void OnText(const std::string& text);
void OnDelete();
+ void OnSuggestText(const std::string& text);
+ void OnUpdateSuggestion();
void DrawState();
void DrawKeysToCanvas(const gfx::RectF& key_area, SkCanvas* canvas);
void DrawAnimations(SkCanvas* canvas, const base::TimeTicks& current_ticks);
@@ -58,6 +61,7 @@ class ViewObserverDelegate : public mojo::ViewObserver {
void OnViewInputEvent(mojo::View* view, const mojo::EventPtr& event) override;
KeyboardServiceImpl* keyboard_service_impl_;
+ Predictor* predictor_;
mojo::View* view_;
uint32_t id_namespace_;
uint32_t surface_id_;

Powered by Google App Engine
This is Rietveld 408576698