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

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

Issue 2579513002: [WebPayments] Factor out sheet-specific logic in Controllers. (Closed)
Patch Set: Address comments. Created 4 years 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/order_summary_view_controller.h
diff --git a/chrome/browser/ui/views/payments/order_summary_view_controller.h b/chrome/browser/ui/views/payments/order_summary_view_controller.h
new file mode 100644
index 0000000000000000000000000000000000000000..1f4328d4f907cfeaafd5b00762b045d7c02d69d0
--- /dev/null
+++ b/chrome/browser/ui/views/payments/order_summary_view_controller.h
@@ -0,0 +1,38 @@
+// Copyright 2016 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef CHROME_BROWSER_UI_VIEWS_PAYMENTS_ORDER_SUMMARY_VIEW_CONTROLLER_H_
+#define CHROME_BROWSER_UI_VIEWS_PAYMENTS_ORDER_SUMMARY_VIEW_CONTROLLER_H_
+
+#include "base/macros.h"
+#include "chrome/browser/ui/views/payments/payment_request_sheet_controller.h"
+#include "ui/views/controls/button/button.h"
+
+namespace payments {
+
+class PaymentRequestImpl;
+class PaymentRequestDialog;
+
+// The PaymentRequestSheetController subtype for the Order Summary screen of the
+// Payment Request flow.
+class OrderSummaryViewController : public PaymentRequestSheetController,
+ public views::ButtonListener {
+ public:
+ OrderSummaryViewController(PaymentRequestImpl* impl,
+ PaymentRequestDialog* dialog);
+ ~OrderSummaryViewController() override;
+
+ // PaymentRequestSheetController:
+ std::unique_ptr<views::View> CreateView() override;
+
+ private:
+ // views::ButtonListener:
+ void ButtonPressed(views::Button* sender, const ui::Event& event) override;
+
+ DISALLOW_COPY_AND_ASSIGN(OrderSummaryViewController);
+};
+
+} // namespace payments
+
+#endif // CHROME_BROWSER_UI_VIEWS_PAYMENTS_ORDER_SUMMARY_VIEW_CONTROLLER_H_

Powered by Google App Engine
This is Rietveld 408576698