Index: chrome/browser/ui/webui/signin/sync_confirmation_handler.cc |
diff --git a/chrome/browser/ui/webui/signin/sync_confirmation_handler.cc b/chrome/browser/ui/webui/signin/sync_confirmation_handler.cc |
index 9cf12ca051312b3a44083a2ad79c7dc4684868d4..b3356871215acc22eff7145cb8231953339cd09d 100644 |
--- a/chrome/browser/ui/webui/signin/sync_confirmation_handler.cc |
+++ b/chrome/browser/ui/webui/signin/sync_confirmation_handler.cc |
@@ -121,4 +121,11 @@ void SyncConfirmationHandler::HandleInitializedWithSize( |
browser->signin_view_controller()->delegate()->ResizeNativeView( |
static_cast<int>(height)); |
+ |
+ // After the dialog is shown, some platforms might have an element focused. |
+ // To be consistent, clear the focused element on all platforms. |
+ // TODO(anthonyvd): Figure out why this is needed on Mac and not other |
+ // platforms and if there's a way to start unfocused while avoiding this |
+ // workaround. |
+ web_ui()->CallJavascriptFunction("sync.confirmation.clearFocus"); |
} |