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

Unified Diff: chrome/browser/ui/autofill/password_generation_popup_controller_impl.cc

Issue 282093006: [Mac] Unselect generated password when mouse leaves password bounds. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/autofill/password_generation_popup_controller_impl.cc
diff --git a/chrome/browser/ui/autofill/password_generation_popup_controller_impl.cc b/chrome/browser/ui/autofill/password_generation_popup_controller_impl.cc
index 6db0c28136e2a497308e7552f17147189aafac02..d946711d78758bd168cc69f858252c4d2900a8f5 100644
--- a/chrome/browser/ui/autofill/password_generation_popup_controller_impl.cc
+++ b/chrome/browser/ui/autofill/password_generation_popup_controller_impl.cc
@@ -137,7 +137,7 @@ bool PasswordGenerationPopupControllerImpl::PossiblyAcceptPassword() {
}
void PasswordGenerationPopupControllerImpl::PasswordSelected(bool selected) {
- if (!display_password_)
+ if (!display_password_ || selected == password_selected_)
return;
password_selected_ = selected;
@@ -289,8 +289,7 @@ void PasswordGenerationPopupControllerImpl::OnSavedPasswordsLinkClicked() {
void PasswordGenerationPopupControllerImpl::SetSelectionAtPoint(
const gfx::Point& point) {
- if (password_bounds_.Contains(point))
- PasswordSelected(true);
+ PasswordSelected(password_bounds_.Contains(point));
}
bool PasswordGenerationPopupControllerImpl::AcceptSelectedLine() {
« 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