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

Side by Side Diff: components/autofill/content/renderer/autofill_agent.cc

Issue 867963005: Add missing comment from 354304bc08fc69 (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 11 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 #include "components/autofill/content/renderer/autofill_agent.h" 5 #include "components/autofill/content/renderer/autofill_agent.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/message_loop/message_loop.h" 9 #include "base/message_loop/message_loop.h"
10 #include "base/strings/string_split.h" 10 #include "base/strings/string_split.h"
(...skipping 291 matching lines...) Expand 10 before | Expand all | Expand 10 after
302 302
303 const WebInputElement* input_element = toWebInputElement(&element); 303 const WebInputElement* input_element = toWebInputElement(&element);
304 if (!input_element && !IsTextAreaElement(element)) 304 if (!input_element && !IsTextAreaElement(element))
305 return; 305 return;
306 306
307 ShowSuggestionsOptions options; 307 ShowSuggestionsOptions options;
308 options.autofill_on_empty_values = true; 308 options.autofill_on_empty_values = true;
309 options.display_warning_if_disabled = true; 309 options.display_warning_if_disabled = true;
310 options.show_full_suggestion_list = element.isAutofilled(); 310 options.show_full_suggestion_list = element.isAutofilled();
311 311
312 // On Android, default to showing the dropdown on field focus.
313 // On desktop, require an extra click after field focus.
314 // See http://crbug.com/427660
312 #if defined(OS_ANDROID) 315 #if defined(OS_ANDROID)
313 bool single_click_autofill = 316 bool single_click_autofill =
314 !base::CommandLine::ForCurrentProcess()->HasSwitch( 317 !base::CommandLine::ForCurrentProcess()->HasSwitch(
315 switches::kDisableSingleClickAutofill); 318 switches::kDisableSingleClickAutofill);
316 #else 319 #else
317 bool single_click_autofill = 320 bool single_click_autofill =
318 base::CommandLine::ForCurrentProcess()->HasSwitch( 321 base::CommandLine::ForCurrentProcess()->HasSwitch(
319 switches::kEnableSingleClickAutofill); 322 switches::kEnableSingleClickAutofill);
320 #endif 323 #endif
321 324
(...skipping 463 matching lines...) Expand 10 before | Expand all | Expand 10 after
785 788
786 void AutofillAgent::LegacyAutofillAgent::OnDestruct() { 789 void AutofillAgent::LegacyAutofillAgent::OnDestruct() {
787 // No-op. Don't delete |this|. 790 // No-op. Don't delete |this|.
788 } 791 }
789 792
790 void AutofillAgent::LegacyAutofillAgent::FocusChangeComplete() { 793 void AutofillAgent::LegacyAutofillAgent::FocusChangeComplete() {
791 agent_->FocusChangeComplete(); 794 agent_->FocusChangeComplete();
792 } 795 }
793 796
794 } // namespace autofill 797 } // namespace autofill
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698