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/utf_string_conversions.h" | 10 #include "base/utf_string_conversions.h" |
(...skipping 1546 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1557 | 1557 |
1558 const bool has_menu = !!controller_->MenuModelForSection(group.section); | 1558 const bool has_menu = !!controller_->MenuModelForSection(group.section); |
1559 | 1559 |
1560 if (group.suggested_button) | 1560 if (group.suggested_button) |
1561 group.suggested_button->SetVisible(has_menu); | 1561 group.suggested_button->SetVisible(has_menu); |
1562 | 1562 |
1563 if (group.container) { | 1563 if (group.container) { |
1564 group.container->SetForwardMouseEvents(has_menu && show_suggestions); | 1564 group.container->SetForwardMouseEvents(has_menu && show_suggestions); |
1565 group.container->SetVisible(controller_->SectionIsActive(group.section)); | 1565 group.container->SetVisible(controller_->SectionIsActive(group.section)); |
1566 if (group.container->visible()) | 1566 if (group.container->visible()) |
1567 ValidateGroup(group, AutofillDialogController::VALIDATE_EDIT); | 1567 ValidateGroup(group, AutofillDialogController::VALIDATE_SELECT); |
1568 } | 1568 } |
1569 | 1569 |
1570 ContentsPreferredSizeChanged(); | 1570 ContentsPreferredSizeChanged(); |
1571 } | 1571 } |
1572 | 1572 |
1573 template<class T> | 1573 template<class T> |
1574 void AutofillDialogViews::SetValidityForInput( | 1574 void AutofillDialogViews::SetValidityForInput( |
1575 T* input, | 1575 T* input, |
1576 const string16& message) { | 1576 const string16& message) { |
1577 bool invalid = !message.empty(); | 1577 bool invalid = !message.empty(); |
(...skipping 248 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1826 AutofillDialogViews::DetailsGroup::DetailsGroup(DialogSection section) | 1826 AutofillDialogViews::DetailsGroup::DetailsGroup(DialogSection section) |
1827 : section(section), | 1827 : section(section), |
1828 container(NULL), | 1828 container(NULL), |
1829 manual_input(NULL), | 1829 manual_input(NULL), |
1830 suggested_info(NULL), | 1830 suggested_info(NULL), |
1831 suggested_button(NULL) {} | 1831 suggested_button(NULL) {} |
1832 | 1832 |
1833 AutofillDialogViews::DetailsGroup::~DetailsGroup() {} | 1833 AutofillDialogViews::DetailsGroup::~DetailsGroup() {} |
1834 | 1834 |
1835 } // namespace autofill | 1835 } // namespace autofill |
OLD | NEW |