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

Unified Diff: chrome/browser/ui/views/payments/profile_list_view_controller.cc

Issue 2789093002: [Payments] Desktop: implement shipping address/option change (Closed)
Patch Set: compile fix Created 3 years, 9 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
Index: chrome/browser/ui/views/payments/profile_list_view_controller.cc
diff --git a/chrome/browser/ui/views/payments/profile_list_view_controller.cc b/chrome/browser/ui/views/payments/profile_list_view_controller.cc
index fa6cf938fdb683fe385b49beda760855718d0a3e..8accd9e08c96baddda2d28de116e8d45f3fa98b4 100644
--- a/chrome/browser/ui/views/payments/profile_list_view_controller.cc
+++ b/chrome/browser/ui/views/payments/profile_list_view_controller.cc
@@ -121,6 +121,10 @@ class ShippingProfileViewController : public ProfileListViewController {
return state()->shipping_profiles();
}
+ DialogViewID GetDialogViewId() override {
+ return DialogViewID::SHIPPING_ADDRESS_SHEET_LIST_VIEW;
+ }
+
base::string16 GetSheetTitle() override {
return GetShippingAddressSectionString(spec()->shipping_type());
}
@@ -177,6 +181,10 @@ class ContactProfileViewController : public ProfileListViewController {
return state()->contact_profiles();
}
+ DialogViewID GetDialogViewId() override {
+ return DialogViewID::CONTACT_INFO_SHEET_LIST_VIEW;
+ }
+
base::string16 GetSheetTitle() override {
return l10n_util::GetStringUTF16(
IDS_PAYMENT_REQUEST_CONTACT_INFO_SECTION_NAME);
@@ -245,7 +253,9 @@ void ProfileListViewController::PopulateList() {
void ProfileListViewController::FillContentView(views::View* content_view) {
content_view->SetLayoutManager(new views::FillLayout);
- content_view->AddChildView(list_.CreateListView().release());
+ std::unique_ptr<views::View> list_view = list_.CreateListView();
+ list_view->set_id(static_cast<int>(GetDialogViewId()));
+ content_view->AddChildView(list_view.release());
}
std::unique_ptr<views::View>

Powered by Google App Engine
This is Rietveld 408576698