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

Side by Side Diff: chrome/browser/resources/options/browser_options.js

Issue 235943011: Add a checkbox on stop-sync dialog to allow user to choose whether to delete (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: comments Created 6 years, 8 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 cr.define('options', function() { 5 cr.define('options', function() {
6 var OptionsPage = options.OptionsPage; 6 var OptionsPage = options.OptionsPage;
7 var ArrayDataModel = cr.ui.ArrayDataModel; 7 var ArrayDataModel = cr.ui.ArrayDataModel;
8 var RepeatingButton = cr.ui.RepeatingButton; 8 var RepeatingButton = cr.ui.RepeatingButton;
9 var HotwordSearchSettingIndicator = options.HotwordSearchSettingIndicator; 9 var HotwordSearchSettingIndicator = options.HotwordSearchSettingIndicator;
10 10
(...skipping 1267 matching lines...) Expand 10 before | Expand all | Expand 10 after
1278 for (var i = 0; i < $('profiles-list').dataModel.length; i++) { 1278 for (var i = 0; i < $('profiles-list').dataModel.length; i++) {
1279 var profile = $('profiles-list').dataModel.item(i); 1279 var profile = $('profiles-list').dataModel.item(i);
1280 if (profile.isCurrentProfile) 1280 if (profile.isCurrentProfile)
1281 return profile; 1281 return profile;
1282 } 1282 }
1283 1283
1284 assert(false, 1284 assert(false,
1285 'There should always be a current profile, but none found.'); 1285 'There should always be a current profile, but none found.');
1286 }, 1286 },
1287 1287
1288 /**
1289 * Propmpts user to confirm deletion of the profile for this browser
1290 * window.
1291 * @private
1292 */
1293 deleteCurrentProfile_: function() {
1294 ManageProfileOverlay.showDeleteDialog(this.getCurrentProfile_());
1295 },
1296
1288 setNativeThemeButtonEnabled_: function(enabled) { 1297 setNativeThemeButtonEnabled_: function(enabled) {
1289 var button = $('themes-native-button'); 1298 var button = $('themes-native-button');
1290 if (button) 1299 if (button)
1291 button.disabled = !enabled; 1300 button.disabled = !enabled;
1292 }, 1301 },
1293 1302
1294 setThemesResetButtonEnabled_: function(enabled) { 1303 setThemesResetButtonEnabled_: function(enabled) {
1295 $('themes-reset').disabled = !enabled; 1304 $('themes-reset').disabled = !enabled;
1296 }, 1305 },
1297 1306
(...skipping 428 matching lines...) Expand 10 before | Expand all | Expand 10 after
1726 $('sync-users-section').hidden = 1735 $('sync-users-section').hidden =
1727 $('profiles-section').hidden && 1736 $('profiles-section').hidden &&
1728 $('sync-section').hidden && 1737 $('sync-section').hidden &&
1729 $('profiles-supervised-dashboard-tip').hidden; 1738 $('profiles-supervised-dashboard-tip').hidden;
1730 } 1739 }
1731 }; 1740 };
1732 1741
1733 //Forward public APIs to private implementations. 1742 //Forward public APIs to private implementations.
1734 [ 1743 [
1735 'addBluetoothDevice', 1744 'addBluetoothDevice',
1745 'deleteCurrentProfile',
1736 'enableCertificateButton', 1746 'enableCertificateButton',
1737 'enableFactoryResetSection', 1747 'enableFactoryResetSection',
1738 'getCurrentProfile', 1748 'getCurrentProfile',
1739 'getStartStopSyncButton', 1749 'getStartStopSyncButton',
1740 'hideBluetoothSettings', 1750 'hideBluetoothSettings',
1741 'notifyInitializationComplete', 1751 'notifyInitializationComplete',
1742 'removeBluetoothDevice', 1752 'removeBluetoothDevice',
1743 'scrollToSection', 1753 'scrollToSection',
1744 'setAccountPictureManaged', 1754 'setAccountPictureManaged',
1745 'setWallpaperManaged', 1755 'setWallpaperManaged',
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
1792 BrowserOptions.getLoggedInUsername = function() { 1802 BrowserOptions.getLoggedInUsername = function() {
1793 return BrowserOptions.getInstance().username_; 1803 return BrowserOptions.getInstance().username_;
1794 }; 1804 };
1795 } 1805 }
1796 1806
1797 // Export 1807 // Export
1798 return { 1808 return {
1799 BrowserOptions: BrowserOptions 1809 BrowserOptions: BrowserOptions
1800 }; 1810 };
1801 }); 1811 });
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698