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

Unified Diff: chrome/browser/resources/ntp4/apps_page.js

Issue 8382010: Some fixups for app notifications: (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 years, 2 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
« no previous file with comments | « chrome/browser/extensions/extension_app_api.cc ('k') | chrome/browser/ui/webui/ntp/app_launcher_handler.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/resources/ntp4/apps_page.js
===================================================================
--- chrome/browser/resources/ntp4/apps_page.js (revision 106989)
+++ chrome/browser/resources/ntp4/apps_page.js (working copy)
@@ -301,7 +301,7 @@
// text.
setupNotification_: function(notification) {
// Remove the old notification from this node (if any).
- if (this.appNotification_)
+ if (this.appNotification_ && this.appNotification_.parentNode)
this.appNotification_.parentNode.removeChild(this.appNotification_);
if (notification) {
@@ -455,8 +455,13 @@
}
var infoBubble = new cr.ui.Bubble;
+ infoBubble.appId = this.appData_.id;
infoBubble.anchorNode = e.target;
infoBubble.content = container;
+ infoBubble.handleCloseEvent = function() {
+ chrome.send('closeNotification', [this.appId]);
+ this.hide();
+ };
infoBubble.show();
},
« no previous file with comments | « chrome/browser/extensions/extension_app_api.cc ('k') | chrome/browser/ui/webui/ntp/app_launcher_handler.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698