From fe12aaa20a8327bd0473dc39c5a742d0cc8a19ba Mon Sep 17 00:00:00 2001 From: "stevenjb@google.com" Date: Thu, 14 Jun 2012 18:10:36 +0000 Subject: Add support for Ash to Notifications * Adds BalloonViewAsh and moves/renames related classes. * Adds support for image icons to Notification class * Adds GetRenderViewHost() method to NotificationDelegate for fetching images BUG=124914 TEST=Tests pass. No visual changes to notifications on non-ash platforms. Web notifications show up in new tray on Ash with --ash-notify. For CloudPrintProxyService: TBR=scottbyer@chromium.org Review URL: https://chromiumcodereview.appspot.com/10537158 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@142172 0039d316-1c4b-4281-b951-d872f2087c98 --- chrome/browser/notifications/notification_test_util.h | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) (limited to 'chrome/browser/notifications/notification_test_util.h') diff --git a/chrome/browser/notifications/notification_test_util.h b/chrome/browser/notifications/notification_test_util.h index 7ea3ac7..418f672 100644 --- a/chrome/browser/notifications/notification_test_util.h +++ b/chrome/browser/notifications/notification_test_util.h @@ -24,6 +24,7 @@ class MockNotificationDelegate : public NotificationDelegate { virtual void Close(bool by_user) OVERRIDE {} virtual void Click() OVERRIDE {} virtual std::string id() const OVERRIDE; + virtual content::RenderViewHost* GetRenderViewHost() const OVERRIDE; private: virtual ~MockNotificationDelegate(); @@ -47,24 +48,28 @@ class LoggingNotificationDelegate : public NotificationDelegate { } // NotificationObjectProxy override - virtual void Display() { + virtual void Display() OVERRIDE { Logger::log("notification displayed\n"); } - virtual void Error() { + virtual void Error() OVERRIDE { Logger::log("notification error\n"); } - virtual void Click() { + virtual void Click() OVERRIDE { Logger::log("notification clicked\n"); } - virtual void Close(bool by_user) { + virtual void Close(bool by_user) OVERRIDE { if (by_user) Logger::log("notification closed by user\n"); else Logger::log("notification closed by script\n"); } - virtual std::string id() const { + virtual std::string id() const OVERRIDE { return notification_id_; } + virtual content::RenderViewHost* GetRenderViewHost() const OVERRIDE { + return NULL; + } + private: std::string notification_id_; -- cgit v1.1