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

Unified Diff: chrome/browser/resources/options/stop_syncing_overlay.js

Issue 3052022: add files (Closed)
Patch Set: Created 10 years, 5 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/resources/options/stop_syncing_overlay.html ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/resources/options/stop_syncing_overlay.js
diff --git a/chrome/browser/resources/options/stop_syncing_overlay.js b/chrome/browser/resources/options/stop_syncing_overlay.js
new file mode 100644
index 0000000000000000000000000000000000000000..07dbca0d003fa8e119baee3255d213de14b0fac0
--- /dev/null
+++ b/chrome/browser/resources/options/stop_syncing_overlay.js
@@ -0,0 +1,38 @@
+// Copyright (c) 2010 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.
+
+/**
+ * StopSyncingOverlay class
+ * Encapsulated handling of the 'Stop Syncing This Account' overlay page.
+ * @class
+ */
+function StopSyncingOverlay() {
+ OptionsPage.call(this, 'stopSyncingOverlay',
+ templateData.stop_syncing_title,
+ 'stopSyncingOverlay');
+}
+
+cr.addSingletonGetter(StopSyncingOverlay);
+
+StopSyncingOverlay.prototype = {
+ // Inherit StopSyncingOverlay from OptionsPage.
+ __proto__: OptionsPage.prototype,
+
+ /**
+ * Initialize the page.
+ */
+ initializePage: function() {
+ // Call base class implementation to starts preference initialization.
+ OptionsPage.prototype.initializePage.call(this);
+
+ $('stop-syncing-cancel').onclick = function(e) {
+ OptionsPage.clearOverlays();
+ }
+
+ $('stop-syncing-confirm').onclick = function(e) {
+ chrome.send('stopSyncing');
+ OptionsPage.clearOverlays();
+ }
+ }
+};
« no previous file with comments | « chrome/browser/resources/options/stop_syncing_overlay.html ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698