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

Unified Diff: chrome/browser/ui/views/payments/payment_request_sheet_controller.h

Issue 2695653004: [Web Payments] Add a mechanism to build item lists in the PR dialog. (Closed)
Patch Set: Address comments. Created 3 years, 10 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/payment_request_sheet_controller.h
diff --git a/chrome/browser/ui/views/payments/payment_request_sheet_controller.h b/chrome/browser/ui/views/payments/payment_request_sheet_controller.h
index d7c73e7f60f20b8224ca6e4684f44c2af80d1eeb..2ccdf3314aeeb3f40e846252bc8d9df98a5bde13 100644
--- a/chrome/browser/ui/views/payments/payment_request_sheet_controller.h
+++ b/chrome/browser/ui/views/payments/payment_request_sheet_controller.h
@@ -52,9 +52,19 @@ class PaymentRequestSheetController : public views::VectorIconButtonDelegate {
// button should be displayed. The caller takes ownership of the button but
// the view is guaranteed to be outlived by the controller so subclasses may
// retain a raw pointer to the returned button (for example to control its
- // enabled state).
+ // enabled state). See comment on CreatePaymentView for an illustration of the
please use gerrit instead 2017/02/22 20:26:28 To ease the job of readers of code, it's a good id
anthonyvd 2017/02/22 20:55:06 Done.
+ // layout.
virtual std::unique_ptr<views::Button> CreatePrimaryButton();
+ // Creates and returns the view to be displayed next to the "Pay" and "Cancel"
+ // buttons. May return an empty std::unique_ptr (nullptr) to indicate that no
+ // extra view is to be displayed.The caller takes ownership of the view but
+ // the view is guaranteed to be outlived by the controller so subclasses may
+ // retain a raw pointer to the returned view (for example to control its
+ // enabled state). See comment on CreatePaymentView for an illustration of the
+ // layout.
please use gerrit instead 2017/02/22 20:26:28 In the spirit of making this method understable as
anthonyvd 2017/02/22 20:55:06 Done.
+ virtual std::unique_ptr<views::View> CreateExtraView();
+
// views::VectorIconButtonDelegate:
void ButtonPressed(views::Button* sender, const ui::Event& event) override;
@@ -71,7 +81,7 @@ class PaymentRequestSheetController : public views::VectorIconButtonDelegate {
// | CONTENT |
// | VIEW |
// +---------------------------+
- // | | CANCEL | PAY | <-- footer
+ // | EXTRA VIEW | PAY | CANCEL | <-- footer
// +---------------------------+
std::unique_ptr<views::View> CreatePaymentView(
std::unique_ptr<views::View> header_view,

Powered by Google App Engine
This is Rietveld 408576698