Index: content/browser/renderer_host/render_widget_host_view_aura_unittest.cc |
diff --git a/content/browser/renderer_host/render_widget_host_view_aura_unittest.cc b/content/browser/renderer_host/render_widget_host_view_aura_unittest.cc |
index da4428671807336de7bb83b6b9ffba3cc7e72f5f..e743f1a432e62ce9a319c8f755154fc5eaf955c4 100644 |
--- a/content/browser/renderer_host/render_widget_host_view_aura_unittest.cc |
+++ b/content/browser/renderer_host/render_widget_host_view_aura_unittest.cc |
@@ -41,6 +41,7 @@ |
#include "content/common/input/input_event_utils.h" |
#include "content/common/input/synthetic_web_input_event_builders.h" |
#include "content/common/input_messages.h" |
+#include "content/common/text_input_state.h" |
#include "content/common/view_messages.h" |
#include "content/public/browser/render_widget_host_view.h" |
#include "content/public/browser/render_widget_host_view_frame_subscriber.h" |
@@ -152,7 +153,8 @@ class TestOverscrollDelegate : public OverscrollControllerDelegate { |
class MockRenderWidgetHostDelegate : public RenderWidgetHostDelegate { |
public: |
- MockRenderWidgetHostDelegate() : rwh_(nullptr) {} |
+ MockRenderWidgetHostDelegate() |
+ : rwh_(nullptr), text_input_state_(new TextInputState()) {} |
~MockRenderWidgetHostDelegate() override {} |
const NativeWebKeyboardEvent* last_event() const { return last_event_.get(); } |
void set_widget_host(RenderWidgetHostImpl* rwh) { rwh_ = rwh; } |
@@ -164,6 +166,11 @@ class MockRenderWidgetHostDelegate : public RenderWidgetHostDelegate { |
last_event_.reset(new NativeWebKeyboardEvent(event)); |
return true; |
} |
+ |
+ const TextInputState* GetTextInputState() override { |
+ return text_input_state_.get(); |
+ } |
+ |
void Cut() override {} |
void Copy() override {} |
void Paste() override {} |
@@ -176,6 +183,8 @@ class MockRenderWidgetHostDelegate : public RenderWidgetHostDelegate { |
private: |
scoped_ptr<NativeWebKeyboardEvent> last_event_; |
RenderWidgetHostImpl* rwh_; |
+ scoped_ptr<TextInputState> text_input_state_; |
+ |
DISALLOW_COPY_AND_ASSIGN(MockRenderWidgetHostDelegate); |
}; |