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

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

Issue 1566083002: Makes sure the keyboard typing isn't blocked when InputMethod::OnFocus() is not correctly called. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: compiled. Created 4 years, 11 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/input_method_log_collector.cc
diff --git a/ui/base/ime/input_method_log_collector.cc b/ui/base/ime/input_method_log_collector.cc
new file mode 100644
index 0000000000000000000000000000000000000000..93a95088c97c816e7b8b97fd019ecfd96430dec5
--- /dev/null
+++ b/ui/base/ime/input_method_log_collector.cc
@@ -0,0 +1,31 @@
+// Copyright (c) 2016 The Chromium Authors. All rights reserved.
sky 2016/01/08 16:51:57 or here.
Shu Chen 2016/01/09 01:46:02 Done.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "ui/base/ime/input_method_log_collector.h"
+
+#include "base/logging.h"
+
+namespace ui {
+
+InputMethodLogCollector::InputMethodLogCollector() {}
+
+InputMethodLogCollector::~InputMethodLogCollector() {}
+
+void InputMethodLogCollector::AddLog(const std::string& log_string) {
+ logs_.push_back(log_string);
+}
+
+void InputMethodLogCollector::OutputLogs() {
+ if (logs_.empty())
+ return;
+ for (size_t i = 0; i < logs_.size(); ++i)
+ LOG(ERROR) << " " << logs_[i];
+ logs_.clear();
+}
+
+void InputMethodLogCollector::ClearLogs() {
+ logs_.clear();
+}
+
+} // namespace ui

Powered by Google App Engine
This is Rietveld 408576698