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

Unified Diff: ui/message_center/dummy_message_center.cc

Issue 15025002: Remove ENABLE_MESSAGE_CENTER (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: try bots love work Created 7 years, 7 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/message_center/dummy_message_center.cc
diff --git a/ui/message_center/dummy_message_center.cc b/ui/message_center/dummy_message_center.cc
new file mode 100644
index 0000000000000000000000000000000000000000..e9d30d66694bff977ba61a96999cc2dff724d9f3
--- /dev/null
+++ b/ui/message_center/dummy_message_center.cc
@@ -0,0 +1,50 @@
+// Copyright (c) 2013 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 "ui/message_center/message_center.h"
+#include "ui/message_center/message_center_switches.h"
+#include "ui/message_center/message_center_util.h"
+
+// This file contains dummy implementation of MessageCenter and used to compile
+// and link with Android and iOS implementations of Chrome which do not have
+// notification systems yet. This is to avoid spreading compile-time flags
+// everywhere in the code.
+#if !defined(OS_ANDROID) && !defined(OS_IOS)
+//#error This file should only be used in Android or iOS builds.
dewittj 2013/05/08 18:53:01 should this be commented out?
Dmitry Titov 2013/05/08 23:03:26 Yes! Thanks, done.
+#endif
+
+namespace message_center {
+
+bool IsRichNotificationEnabled() {
+ return false;
+}
+
+namespace switches {
+const char kDisableRichNotifications[] = "disable-rich-notifications";
dewittj 2013/05/08 18:53:01 Can we just include messag_center_switches.h/cc in
Dmitry Titov 2013/05/08 23:03:26 Done.
+const char kEnableRichNotifications[] = "enable-rich-notifications";
+} // namespace switches
+
+// static
+void MessageCenter::Initialize() {
+}
+
+// static
+MessageCenter* MessageCenter::Get() {
+ return NULL;
+}
+
+// static
+void MessageCenter::Shutdown() {
+}
+
+MessageCenter::MessageCenter() {
+}
+
+MessageCenter::~MessageCenter() {
+}
+
+MessageCenter::Delegate::~Delegate() {
+}
+
+} // namespace message_center

Powered by Google App Engine
This is Rietveld 408576698