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

Unified Diff: ui/file_manager/file_manager/background/js/device_handler.js

Issue 345553006: Files.app: Remove the "Got it" button from the hard unplugged nortification. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 6 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/chromeos/extensions/file_manager/private_api_strings.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/file_manager/file_manager/background/js/device_handler.js
diff --git a/ui/file_manager/file_manager/background/js/device_handler.js b/ui/file_manager/file_manager/background/js/device_handler.js
index fa098d1f58b149b49bce3f6eb1d38b821a3e64d7..14ca49e38f87e76b6f7385b1e46a292095460dcb 100644
--- a/ui/file_manager/file_manager/background/js/device_handler.js
+++ b/ui/file_manager/file_manager/background/js/device_handler.js
@@ -16,19 +16,10 @@ function DeviceHandler() {
*/
this.mountStatus_ = {};
- /**
- * List of ID of notifications that have a button.
- * @type {Array.<string>}
- * @private
- */
- this.buttonNotifications_ = [];
-
chrome.fileBrowserPrivate.onDeviceChanged.addListener(
this.onDeviceChanged_.bind(this));
chrome.fileBrowserPrivate.onMountCompleted.addListener(
this.onMountCompleted_.bind(this));
- chrome.notifications.onButtonClicked.addListener(
- this.onNotificationButtonClicked_.bind(this));
Object.seal(this);
}
@@ -119,8 +110,7 @@ DeviceHandler.Notification.DEVICE_HARD_UNPLUGGED =
new DeviceHandler.Notification(
'deviceFail',
'DEVICE_HARD_UNPLUGGED_TITLE',
- 'DEVICE_HARD_UNPLUGGED_MESSAGE',
- 'DEVICE_HARD_UNPLUGGED_BUTTON_LABEL');
+ 'DEVICE_HARD_UNPLUGGED_MESSAGE');
/**
* @type {DeviceHandler.Notification}
@@ -244,7 +234,6 @@ DeviceHandler.prototype.onDeviceChanged_ = function(event) {
case 'hard_unplugged':
var id = DeviceHandler.Notification.DEVICE_HARD_UNPLUGGED.show(
event.devicePath);
- this.buttonNotifications_.push(id);
break;
case 'format_start':
DeviceHandler.Notification.FORMAT_START.show(event.devicePath);
@@ -366,16 +355,3 @@ DeviceHandler.prototype.onMountCompleted_ = function(event) {
DeviceHandler.Notification.DEVICE_FAIL.show(volume.devicePath, message);
}
};
-
-/**
- * Handles notification button click.
- * @param {string} id ID of the notification.
- * @private
- */
-DeviceHandler.prototype.onNotificationButtonClicked_ = function(id) {
- var index = this.buttonNotifications_.indexOf(id);
- if (index !== -1) {
- chrome.notifications.clear(id, function() {});
- this.buttonNotifications_.splice(index, 1);
- }
-};
« no previous file with comments | « chrome/browser/chromeos/extensions/file_manager/private_api_strings.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698