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

Unified Diff: chrome/browser/chromeos/launcher_search_provider/error_reporter.cc

Issue 1060733003: Support custom icon in search result. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix comment. Created 5 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: chrome/browser/chromeos/launcher_search_provider/error_reporter.cc
diff --git a/chrome/browser/chromeos/launcher_search_provider/error_reporter.cc b/chrome/browser/chromeos/launcher_search_provider/error_reporter.cc
new file mode 100644
index 0000000000000000000000000000000000000000..99237afcf943c959a03e046d7c49d09d24cee673
--- /dev/null
+++ b/chrome/browser/chromeos/launcher_search_provider/error_reporter.cc
@@ -0,0 +1,30 @@
+// Copyright 2015 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "chrome/browser/chromeos/launcher_search_provider/error_reporter.h"
+
+#include "content/public/common/console_message_level.h"
+#include "extensions/common/extension_messages.h"
+
+namespace chromeos {
+namespace launcher_search_provider {
+
+ErrorReporter::ErrorReporter(IPC::Sender* sender, const int routing_id)
+ : sender_(sender), routing_id_(routing_id) {
+}
+
+ErrorReporter::~ErrorReporter() {
+}
+
+void ErrorReporter::Warn(const std::string& message) {
+ if (sender_ == nullptr)
Matt Giuca 2015/05/05 04:25:30 DCHECK(sender); The only time sender should be nu
yawano 2015/05/07 06:24:55 Done.
+ return;
+
+ sender_->Send(new ExtensionMsg_AddMessageToConsole(
+ routing_id_, content::ConsoleMessageLevel::CONSOLE_MESSAGE_LEVEL_WARNING,
+ message));
+}
+
+} // namespace launcher_search_provider
+} // namespace chromeos

Powered by Google App Engine
This is Rietveld 408576698