Index: chrome/browser/notifications/notification_object_proxy.h |
diff --git a/chrome/browser/notifications/notification_object_proxy.h b/chrome/browser/notifications/notification_object_proxy.h |
index 9870ac10e3de40266392f50e78a87bcbc3961638..c123e9a8d5046189a87bfde797e034b7cda17442 100644 |
--- a/chrome/browser/notifications/notification_object_proxy.h |
+++ b/chrome/browser/notifications/notification_object_proxy.h |
@@ -7,6 +7,7 @@ |
#include <string> |
+#include "base/memory/scoped_ptr.h" |
#include "chrome/browser/notifications/notification_delegate.h" |
namespace content { |
@@ -21,7 +22,8 @@ class RenderFrameHost; |
class NotificationObjectProxy |
: public NotificationDelegate { |
public: |
- // Creates a Proxy object with the necessary callback information. |
+ // Creates a Proxy object with the necessary callback information. The Proxy |
+ // will take ownership of |delegate|. |
NotificationObjectProxy(content::RenderFrameHost* render_frame_host, |
content::DesktopNotificationDelegate* delegate); |
jochen (gone - plz use gerrit)
2014/08/04 09:11:24
you could make the parameter a scoped_ptr<> to mak
Peter Beverloo
2014/08/04 11:33:34
Done. Plumbed through the ContentBrowserClient as
|
@@ -37,13 +39,13 @@ class NotificationObjectProxy |
protected: |
friend class base::RefCountedThreadSafe<NotificationObjectProxy>; |
- virtual ~NotificationObjectProxy() {} |
+ virtual ~NotificationObjectProxy(); |
private: |
// Callback information to find the JS Notification object where it lives. |
int render_process_id_; |
int render_frame_id_; |
- content::DesktopNotificationDelegate* delegate_; |
+ scoped_ptr<content::DesktopNotificationDelegate> delegate_; |
bool displayed_; |
std::string id_; |
}; |