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

Unified Diff: ui/base/ime/dummy_text_input_client.cc

Issue 1780523006: Add tests for input.ime.* APIs. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 9 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: ui/base/ime/dummy_text_input_client.cc
diff --git a/ui/base/ime/dummy_text_input_client.cc b/ui/base/ime/dummy_text_input_client.cc
index ac9b97343ab9eb0203d80adf36b6900156d60973..d386bba4f14767caa118e3c3ce345c6b4986ea73 100644
--- a/ui/base/ime/dummy_text_input_client.cc
+++ b/ui/base/ime/dummy_text_input_client.cc
@@ -9,10 +9,14 @@
namespace ui {
DummyTextInputClient::DummyTextInputClient()
- : text_input_type_(TEXT_INPUT_TYPE_NONE), insert_char_count_(0) {}
+ : text_input_type_(TEXT_INPUT_TYPE_NONE),
+ insert_char_count_(0),
+ insert_text_count_(0) {}
DummyTextInputClient::DummyTextInputClient(TextInputType text_input_type)
- : text_input_type_(text_input_type), insert_char_count_(0) {}
+ : text_input_type_(text_input_type),
+ insert_char_count_(0),
+ insert_text_count_(0) {}
DummyTextInputClient::~DummyTextInputClient() {
}
@@ -28,6 +32,8 @@ void DummyTextInputClient::ClearCompositionText() {
}
void DummyTextInputClient::InsertText(const base::string16& text) {
+ ++insert_text_count_;
+ last_insert_text_ = text;
}
void DummyTextInputClient::InsertChar(const KeyEvent& event) {

Powered by Google App Engine
This is Rietveld 408576698