Index: chrome/browser/resources/options/managed_user_settings.js |
diff --git a/chrome/browser/resources/options/managed_user_settings.js b/chrome/browser/resources/options/managed_user_settings.js |
new file mode 100644 |
index 0000000000000000000000000000000000000000..04322632128ed069927a43cefe3698e8e90cd0f4 |
--- /dev/null |
+++ b/chrome/browser/resources/options/managed_user_settings.js |
@@ -0,0 +1,60 @@ |
+// Copyright (c) 2012 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. |
+ |
+if (loadTimeData.getBoolean('managedUsersEnabled')) { |
+ |
+cr.define('options', function() { |
+ /** @const */ var OptionsPage = options.OptionsPage; |
+ |
+ ////////////////////////////////////////////////////////////////////////////// |
+ // ManagedUserSettings class: |
+ |
+ /** |
+ * Encapsulated handling of the Managed User Settings page. |
+ * @constructor |
+ * @class |
+ */ |
+ function ManagedUserSettings() { |
+ OptionsPage.call( |
+ this, |
+ 'manageduser', |
+ loadTimeData.getString('managedUserSettingsPageTabTitle'), |
+ 'managed-user-settings-page'); |
+ } |
+ |
+ cr.addSingletonGetter(ManagedUserSettings); |
+ |
+ ManagedUserSettings.prototype = { |
+ // Inherit from OptionsPage. |
+ __proto__: OptionsPage.prototype, |
+ |
+ /** |
+ * Initialize the page. |
+ * @override |
+ */ |
+ initializePage: function() { |
+ // Call base class implementation to start preference initialization. |
+ OptionsPage.prototype.initializePage.call(this); |
+ |
+ $('get-content-packs-button').onclick = function(event) { |
+ window.open(loadTimeData.getString('getContentPacksURL')); |
+ }; |
+ |
+ $('managed-user-settings-confirm').onclick = function() { |
+ OptionsPage.closeOverlay(); |
+ }; |
+ |
+ $('set-passphrase').onclick = function() { |
+ // TODO(bauerb): Set passphrase |
+ }; |
+ }, |
+ }; |
+ |
+ // Export |
+ return { |
+ ManagedUserSettings: ManagedUserSettings |
+ }; |
+}); |
+ |
+} |