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

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..9063b8401aab116561ccaa8d768b574f58f5e453
--- /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 "chrome/browser/ui/views/payments/payment_request_sheet_controller.h"
+
+#include "ui/views/controls/button/button.h"
+
+namespace views {
+class View;
+}
+
+namespace payments {
+
+// 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 {}
sky 2016/12/15 16:49:44 Don't inline the destructor (I'm surprised you did
anthonyvd 2016/12/15 17:37:41 Done.
+
+ std::unique_ptr<views::View> CreateView() override;
sky 2016/12/15 16:49:44 Prefix with where override is from (like you have
anthonyvd 2016/12/15 17:37:41 Done.
+
+ 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