| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 "chrome/browser/ui/views/autofill/autofill_dialog_views.h" | 5 #include "chrome/browser/ui/views/autofill/autofill_dialog_views.h" |
| 6 | 6 |
| 7 #include <utility> | 7 #include <utility> |
| 8 | 8 |
| 9 #include "base/bind.h" | 9 #include "base/bind.h" |
| 10 #include "base/location.h" | 10 #include "base/location.h" |
| (...skipping 1713 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1724 | 1724 |
| 1725 // Show an error bubble when the user focuses the input. | 1725 // Show an error bubble when the user focuses the input. |
| 1726 if (focused_now) { | 1726 if (focused_now) { |
| 1727 focused_now->ScrollRectToVisible(focused_now->GetLocalBounds()); | 1727 focused_now->ScrollRectToVisible(focused_now->GetLocalBounds()); |
| 1728 ShowErrorBubbleForViewIfNecessary(focused_now); | 1728 ShowErrorBubbleForViewIfNecessary(focused_now); |
| 1729 } | 1729 } |
| 1730 } | 1730 } |
| 1731 | 1731 |
| 1732 void AutofillDialogViews::OnSelectedIndexChanged(views::Combobox* combobox) { | 1732 void AutofillDialogViews::OnSelectedIndexChanged(views::Combobox* combobox) { |
| 1733 DetailsGroup* group = GroupForView(combobox); | 1733 DetailsGroup* group = GroupForView(combobox); |
| 1734 int index = combobox->selected_index(); |
| 1735 delegate_->ComboboxItemSelected(combobox->model(), group->section, index); |
| 1734 ValidateGroup(*group, VALIDATE_EDIT); | 1736 ValidateGroup(*group, VALIDATE_EDIT); |
| 1735 SetEditabilityForSection(group->section); | 1737 SetEditabilityForSection(group->section); |
| 1736 } | 1738 } |
| 1737 | 1739 |
| 1738 void AutofillDialogViews::StyledLabelLinkClicked(const gfx::Range& range, | 1740 void AutofillDialogViews::StyledLabelLinkClicked(const gfx::Range& range, |
| 1739 int event_flags) { | 1741 int event_flags) { |
| 1740 delegate_->LegalDocumentLinkClicked(range); | 1742 delegate_->LegalDocumentLinkClicked(range); |
| 1741 } | 1743 } |
| 1742 | 1744 |
| 1743 void AutofillDialogViews::OnMenuButtonClicked(views::View* source, | 1745 void AutofillDialogViews::OnMenuButtonClicked(views::View* source, |
| (...skipping 703 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2447 AutofillDialogViews::DetailsGroup::DetailsGroup(DialogSection section) | 2449 AutofillDialogViews::DetailsGroup::DetailsGroup(DialogSection section) |
| 2448 : section(section), | 2450 : section(section), |
| 2449 container(NULL), | 2451 container(NULL), |
| 2450 manual_input(NULL), | 2452 manual_input(NULL), |
| 2451 suggested_info(NULL), | 2453 suggested_info(NULL), |
| 2452 suggested_button(NULL) {} | 2454 suggested_button(NULL) {} |
| 2453 | 2455 |
| 2454 AutofillDialogViews::DetailsGroup::~DetailsGroup() {} | 2456 AutofillDialogViews::DetailsGroup::~DetailsGroup() {} |
| 2455 | 2457 |
| 2456 } // namespace autofill | 2458 } // namespace autofill |
| OLD | NEW |