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

Unified Diff: chrome/browser/resources/chromeos/login/oobe_screen_reset.js

Issue 11421111: Fixed button focusing in OOBE screens. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Addressed comments. Created 8 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/resources/chromeos/login/oobe_screen_network.js ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/resources/chromeos/login/oobe_screen_reset.js
diff --git a/chrome/browser/resources/chromeos/login/oobe_screen_reset.js b/chrome/browser/resources/chromeos/login/oobe_screen_reset.js
index a73b11bbe46307850089ee5b009d66a6dc55eb5d..22f0e08d319f856d8e44ba60a5068dad1b1b42bf 100644
--- a/chrome/browser/resources/chromeos/login/oobe_screen_reset.js
+++ b/chrome/browser/resources/chromeos/login/oobe_screen_reset.js
@@ -57,6 +57,7 @@ cr.define('oobe', function() {
var cancelButton = this.ownerDocument.createElement('button');
cancelButton.id = 'reset-cancel-button';
cancelButton.textContent = localStrings.getString('cancelButton');
+ cancelButton.autofocus = true;
Nikita (slow) 2012/11/30 14:47:05 nit: is this still needed?
mtomasz 2012/11/30 18:35:31 Done.
cancelButton.addEventListener('click', function(e) {
chrome.send('resetOnCancel');
e.stopPropagation();
@@ -67,6 +68,13 @@ cr.define('oobe', function() {
},
/**
+ * Returns a control which should receive an initial focus.
+ */
+ get defaultControl() {
+ return $('reset-cancel-button');
+ },
+
+ /**
* Cancels the reset and drops the user back to the login screen.
*/
cancel: function() {
« no previous file with comments | « chrome/browser/resources/chromeos/login/oobe_screen_network.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698