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

Issue 512933004: mac: Don't show "Access Address Book" prompt if Autofill is disabled. (Closed)

Created:
6 years, 3 months ago by erikchen
Modified:
6 years, 3 months ago
CC:
chromium-reviews, benquan, browser-components-watch_chromium.org, Dane Wallinga, dyu1, estade+watch_chromium.org, rouslan+autofillwatch_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Project:
chromium
Visibility:
Public.

Description

mac: Fix 2 bugs where "Access Address Book" prompt is incorrectly shown. Don't show "Access Address Book" prompt if Autofill is disabled, the form has the attribute autocomplete="off", or if Chrome doesn't think the form is Autofillable. BUG=398476 Committed: https://crrev.com/d4dd2df0e956f0ba64e988d48acc3d81c02aad35 Cr-Commit-Position: refs/heads/master@{#292538}

Patch Set 1 #

Patch Set 2 : Require forms be autofillable. #

Total comments: 7

Patch Set 3 : Fix logic in autofill manager. #

Total comments: 2

Patch Set 4 : Respond to estade's style suggestion. #

Total comments: 4

Patch Set 5 : Add virtual/OVERRIDE. #

Patch Set 6 : Respond to comments from estade (remove mock function). #

Total comments: 2

Patch Set 7 : Check for form autofillability. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+40 lines, -1 line) Patch
M components/autofill/core/browser/autofill_manager.cc View 1 2 3 4 5 6 1 chunk +5 lines, -1 line 0 comments Download
M components/autofill/core/browser/autofill_manager_unittest.cc View 1 2 3 4 5 1 chunk +18 lines, -0 lines 0 comments Download
M components/autofill/core/browser/personal_data_manager_mac.mm View 1 chunk +3 lines, -0 lines 0 comments Download
M components/autofill/core/browser/personal_data_manager_unittest.cc View 1 2 1 chunk +14 lines, -0 lines 0 comments Download

Messages

Total messages: 42 (0 generated)
erikchen
erikchen@chromium.org changed reviewers: + isherman@chromium.org
6 years, 3 months ago (2014-08-27 23:09:27 UTC) #1
erikchen
isherman: Please review. Are there any obvious logic mistakes that we should be looking out ...
6 years, 3 months ago (2014-08-27 23:09:27 UTC) #2
Ilya Sherman
LGTM
6 years, 3 months ago (2014-08-27 23:28:16 UTC) #3
Ilya Sherman
On 2014/08/27 23:09:27, erikchen wrote: > Are there any obvious logic mistakes that we should ...
6 years, 3 months ago (2014-08-27 23:29:08 UTC) #4
erikchen
No we do not, I'm glad I asked. Updated the CL. PTAL.
6 years, 3 months ago (2014-08-28 00:00:06 UTC) #5
Evan Stade
estade@chromium.org changed reviewers: + estade@chromium.org
6 years, 3 months ago (2014-08-28 00:33:16 UTC) #6
Evan Stade
https://codereview.chromium.org/512933004/diff/20001/components/autofill/core/browser/autofill_manager.cc File components/autofill/core/browser/autofill_manager.cc (right): https://codereview.chromium.org/512933004/diff/20001/components/autofill/core/browser/autofill_manager.cc#newcode295 components/autofill/core/browser/autofill_manager.cc:295: if (!form_structure->IsAutofillable()) why are we even getting to this ...
6 years, 3 months ago (2014-08-28 00:33:16 UTC) #7
Ilya Sherman
https://codereview.chromium.org/512933004/diff/20001/components/autofill/core/browser/autofill_manager.cc File components/autofill/core/browser/autofill_manager.cc (right): https://codereview.chromium.org/512933004/diff/20001/components/autofill/core/browser/autofill_manager.cc#newcode296 components/autofill/core/browser/autofill_manager.cc:296: return false; Could you add test coverage for this ...
6 years, 3 months ago (2014-08-28 00:34:19 UTC) #8
Evan Stade
Come to think of it, I don't think we should show ever show the form ...
6 years, 3 months ago (2014-08-28 00:35:40 UTC) #9
Ilya Sherman
On 2014/08/28 00:35:40, Evan Stade wrote: > Come to think of it, I don't think ...
6 years, 3 months ago (2014-08-28 00:38:38 UTC) #10
erikchen
https://codereview.chromium.org/512933004/diff/20001/components/autofill/core/browser/autofill_manager.cc File components/autofill/core/browser/autofill_manager.cc (right): https://codereview.chromium.org/512933004/diff/20001/components/autofill/core/browser/autofill_manager.cc#newcode295 components/autofill/core/browser/autofill_manager.cc:295: if (!form_structure->IsAutofillable()) On 2014/08/28 00:33:16, Evan Stade wrote: > ...
6 years, 3 months ago (2014-08-28 00:39:37 UTC) #11
Evan Stade
I don't think IsAutofillable() is the right method here... // Runs a quick heuristic to ...
6 years, 3 months ago (2014-08-28 00:51:42 UTC) #12
erikchen
On 2014/08/28 00:51:42, Evan Stade wrote: > I don't think IsAutofillable() is the right method ...
6 years, 3 months ago (2014-08-28 01:47:12 UTC) #13
Evan Stade
On 2014/08/28 01:47:12, erikchen wrote: > On 2014/08/28 00:51:42, Evan Stade wrote: > > I ...
6 years, 3 months ago (2014-08-28 01:54:53 UTC) #14
erikchen
Patchset #3 (id:40001) has been deleted
6 years, 3 months ago (2014-08-28 16:59:52 UTC) #15
erikchen
isherman: PTAL estade: Thanks for the explanation! https://codereview.chromium.org/512933004/diff/20001/components/autofill/core/browser/autofill_manager.cc File components/autofill/core/browser/autofill_manager.cc (right): https://codereview.chromium.org/512933004/diff/20001/components/autofill/core/browser/autofill_manager.cc#newcode296 components/autofill/core/browser/autofill_manager.cc:296: return false; ...
6 years, 3 months ago (2014-08-28 17:01:17 UTC) #16
Evan Stade
your CL description confuses me. "Disabling" Autofill implies that a user went to chrome://settings and ...
6 years, 3 months ago (2014-08-28 17:18:58 UTC) #17
Evan Stade
On 2014/08/28 17:18:58, Evan Stade wrote: > your CL description confuses me. "Disabling" Autofill implies ...
6 years, 3 months ago (2014-08-28 17:21:10 UTC) #18
erikchen
estade: PTAL I modified the CL description's title to be slightly more generic, and then ...
6 years, 3 months ago (2014-08-28 17:28:46 UTC) #19
Evan Stade
https://codereview.chromium.org/512933004/diff/80001/components/autofill/core/browser/autofill_manager_unittest.cc File components/autofill/core/browser/autofill_manager_unittest.cc (right): https://codereview.chromium.org/512933004/diff/80001/components/autofill/core/browser/autofill_manager_unittest.cc#newcode137 components/autofill/core/browser/autofill_manager_unittest.cc:137: bool ShouldShowAccessAddressBookSuggestion(AutofillType type) { return true; } where is ...
6 years, 3 months ago (2014-08-28 17:31:55 UTC) #20
erikchen
https://codereview.chromium.org/512933004/diff/80001/components/autofill/core/browser/autofill_manager_unittest.cc File components/autofill/core/browser/autofill_manager_unittest.cc (right): https://codereview.chromium.org/512933004/diff/80001/components/autofill/core/browser/autofill_manager_unittest.cc#newcode137 components/autofill/core/browser/autofill_manager_unittest.cc:137: bool ShouldShowAccessAddressBookSuggestion(AutofillType type) { return true; } On 2014/08/28 ...
6 years, 3 months ago (2014-08-28 17:37:56 UTC) #21
Evan Stade
https://codereview.chromium.org/512933004/diff/80001/components/autofill/core/browser/autofill_manager_unittest.cc File components/autofill/core/browser/autofill_manager_unittest.cc (right): https://codereview.chromium.org/512933004/diff/80001/components/autofill/core/browser/autofill_manager_unittest.cc#newcode137 components/autofill/core/browser/autofill_manager_unittest.cc:137: bool ShouldShowAccessAddressBookSuggestion(AutofillType type) { return true; } On 2014/08/28 ...
6 years, 3 months ago (2014-08-28 17:42:32 UTC) #22
erikchen
I would prefer to not do that, since it would make a unit test for ...
6 years, 3 months ago (2014-08-28 17:44:55 UTC) #23
Evan Stade
On 2014/08/28 17:44:55, erikchen wrote: > I would prefer to not do that, since it ...
6 years, 3 months ago (2014-08-28 18:07:42 UTC) #24
erikchen
estade: I have done as you suggested. https://codereview.chromium.org/512933004/diff/80001/components/autofill/core/browser/autofill_manager_unittest.cc File components/autofill/core/browser/autofill_manager_unittest.cc (right): https://codereview.chromium.org/512933004/diff/80001/components/autofill/core/browser/autofill_manager_unittest.cc#newcode137 components/autofill/core/browser/autofill_manager_unittest.cc:137: bool ShouldShowAccessAddressBookSuggestion(AutofillType ...
6 years, 3 months ago (2014-08-28 18:14:46 UTC) #25
Evan Stade
lgtm
6 years, 3 months ago (2014-08-28 18:21:56 UTC) #26
erikchen
The CQ bit was checked by erikchen@chromium.org
6 years, 3 months ago (2014-08-28 18:22:55 UTC) #27
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/erikchen@chromium.org/512933004/120001
6 years, 3 months ago (2014-08-28 18:23:49 UTC) #28
Ilya Sherman
https://codereview.chromium.org/512933004/diff/120001/components/autofill/core/browser/autofill_manager.cc File components/autofill/core/browser/autofill_manager.cc (right): https://codereview.chromium.org/512933004/diff/120001/components/autofill/core/browser/autofill_manager.cc#newcode290 components/autofill/core/browser/autofill_manager.cc:290: We still shouldn't be showing these suggestions for forms ...
6 years, 3 months ago (2014-08-28 18:40:49 UTC) #29
erikchen
my understanding of comment #12 from estade is that the check already happens earlier.
6 years, 3 months ago (2014-08-28 18:42:54 UTC) #30
Ilya Sherman
On 2014/08/28 18:42:54, erikchen wrote: > my understanding of comment #12 from estade is that ...
6 years, 3 months ago (2014-08-28 18:47:40 UTC) #31
erikchen
The CQ bit was unchecked by erikchen@chromium.org
6 years, 3 months ago (2014-08-28 18:55:53 UTC) #32
erikchen
No, I'm checking now.
6 years, 3 months ago (2014-08-28 18:56:01 UTC) #33
erikchen
There are 4 reasons why we shouldn't show the prompt: 1. The form has attribute ...
6 years, 3 months ago (2014-08-28 20:52:55 UTC) #34
erikchen
https://codereview.chromium.org/512933004/diff/120001/components/autofill/core/browser/autofill_manager.cc File components/autofill/core/browser/autofill_manager.cc (right): https://codereview.chromium.org/512933004/diff/120001/components/autofill/core/browser/autofill_manager.cc#newcode290 components/autofill/core/browser/autofill_manager.cc:290: On 2014/08/28 18:40:49, Ilya Sherman wrote: > We still ...
6 years, 3 months ago (2014-08-28 20:57:34 UTC) #35
Evan Stade
On 2014/08/28 20:52:55, erikchen wrote: > There are 4 reasons why we shouldn't show the ...
6 years, 3 months ago (2014-08-28 21:01:44 UTC) #36
erikchen
Isn't this the same code path that is responsible for showing the "form disabled warning" ...
6 years, 3 months ago (2014-08-28 21:24:41 UTC) #37
Evan Stade
ok, lgtm
6 years, 3 months ago (2014-08-28 23:56:50 UTC) #38
erikchen
The CQ bit was checked by erikchen@chromium.org
6 years, 3 months ago (2014-08-28 23:58:39 UTC) #39
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/erikchen@chromium.org/512933004/140001
6 years, 3 months ago (2014-08-29 00:01:07 UTC) #40
commit-bot: I haz the power
Committed patchset #7 (id:140001) as 29e9af1e7eb0edb5db92ab35bee20793ba23ed9c
6 years, 3 months ago (2014-08-29 01:30:00 UTC) #41
commit-bot: I haz the power
6 years, 3 months ago (2014-09-10 03:04:54 UTC) #42
Message was sent while issue was closed.
Patchset 7 (id:??) landed as
https://crrev.com/d4dd2df0e956f0ba64e988d48acc3d81c02aad35
Cr-Commit-Position: refs/heads/master@{#292538}

Powered by Google App Engine
This is Rietveld 408576698