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

Unified Diff: chrome/browser/policy/resources/enrollment.js

Issue 8436002: [cros] Remove Views implementation for login/OOBE. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: merge Created 9 years, 1 month 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/policy/resources/enrollment.html ('k') | chrome/browser/resources/chromeos/login/oobe.html » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/policy/resources/enrollment.js
diff --git a/chrome/browser/policy/resources/enrollment.js b/chrome/browser/policy/resources/enrollment.js
deleted file mode 100644
index 250515140b5a6427aa9231b3a476b417d92dd2a0..0000000000000000000000000000000000000000
--- a/chrome/browser/policy/resources/enrollment.js
+++ /dev/null
@@ -1,67 +0,0 @@
-// Copyright (c) 2011 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.
-
-cr.define('enterpriseEnrollment', function() {
-
- function showScreen(screen) {
- var screens = ['login-screen', 'confirmation-screen'];
- for (var i = 0; i < screens.length; i++) {
- $(screens[i]).hidden = screens[i] != screen;
-
- // Hiding an iframe unfortunately doesn't remove it or its contents from
- // tabbing order. To hack around this:
- // - Hide the content document (if it exists), so nested elements won't
- // receive focus and relinquish focus if they already have it.
- // - Set tabIndex = -1 on the iframe, so it doesn't get focused itself.
- //
- // See https://bugs.webkit.org/show_bug.cgi?id=55861
- iframes = $(screens[i]).getElementsByTagName('iframe');
- for (var j = 0; j < iframes.length; j++) {
- var display = '';
- if (screens[i] != screen) {
- display = 'none';
- iframes[j].tabIndex = -1;
- } else {
- display = 'block';
- iframes[j].removeAttribute('tabIndex');
- }
- if (iframes[j].contentDocument && iframes[j].contentDocument.body) {
- iframes[j].contentDocument.body.style.display = display;
- }
- }
- }
-
- if (screen === 'confirmation-screen') {
- // Focus on the submit button when showing the confirmation-screen.
- $('close').focus();
- }
- }
-
- function showInitialScreen() {
- showScreen('login-screen');
- document.addEventListener('keydown', onKeydown);
- $('gaialogin').contentWindow.addEventListener('keydown', onKeydown);
- }
-
- function onKeydown(e) {
- // Handle ESC key.
- if (e.keyIdentifier === 'U+001B') {
- e.stopPropagation();
- chrome.send("DialogClose", [""]);
- }
- }
-
- function onLoad() {
- chrome.send('enrollmentScreenReady', []);
- }
-
- return {
- showScreen: showScreen,
- showInitialScreen: showInitialScreen,
- onLoad: onLoad
- };
-});
-
-document.addEventListener('DOMContentLoaded',
- enterpriseEnrollment.onLoad);
« no previous file with comments | « chrome/browser/policy/resources/enrollment.html ('k') | chrome/browser/resources/chromeos/login/oobe.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698