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

Unified Diff: content/browser/renderer_host/render_widget_host_view_mac_unittest.mm

Issue 1652483002: Browser Side Text Input State Tracking for OOPIF. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Merged Created 4 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
Index: content/browser/renderer_host/render_widget_host_view_mac_unittest.mm
diff --git a/content/browser/renderer_host/render_widget_host_view_mac_unittest.mm b/content/browser/renderer_host/render_widget_host_view_mac_unittest.mm
index 5cc1841dbd618de1b3a90b6e10fbc98cd7c64121..c94bcf393f4a95d6cc904e0964792d10e195d7ca 100644
--- a/content/browser/renderer_host/render_widget_host_view_mac_unittest.mm
+++ b/content/browser/renderer_host/render_widget_host_view_mac_unittest.mm
@@ -20,6 +20,7 @@
#include "content/browser/gpu/compositor_util.h"
#include "content/browser/renderer_host/render_widget_host_delegate.h"
#include "content/common/input_messages.h"
+#include "content/common/text_input_state.h"
#include "content/common/view_messages.h"
#include "content/public/browser/notification_types.h"
#include "content/public/browser/render_widget_host_view_mac_delegate.h"
@@ -142,14 +143,20 @@ id MockGestureEvent(NSEventType type, double magnification) {
class MockRenderWidgetHostDelegate : public RenderWidgetHostDelegate {
public:
- MockRenderWidgetHostDelegate() {}
+ MockRenderWidgetHostDelegate() : text_input_state_(new TextInputState()) {}
~MockRenderWidgetHostDelegate() override {}
+ const TextInputState* GetTextInputState() override {
+ return text_input_state_.get();
+ }
+
private:
void Cut() override {}
void Copy() override {}
void Paste() override {}
void SelectAll() override {}
+
+ scoped_ptr<TextInputState> text_input_state_;
};
class MockRenderWidgetHostImpl : public RenderWidgetHostImpl {

Powered by Google App Engine
This is Rietveld 408576698