| OLD | NEW |
| (Empty) | |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef CHROME_BROWSER_PAYMENTS_PAYMENT_REQUEST_IMPL_H_ |
| 6 #define CHROME_BROWSER_PAYMENTS_PAYMENT_REQUEST_IMPL_H_ |
| 7 |
| 8 #include "components/payments/payment_request.mojom.h" |
| 9 #include "mojo/public/cpp/bindings/binding.h" |
| 10 |
| 11 namespace content { |
| 12 class WebContents; |
| 13 } |
| 14 |
| 15 namespace payments { |
| 16 |
| 17 class PaymentRequestImpl : payments::mojom::PaymentRequest { |
| 18 public: |
| 19 PaymentRequestImpl( |
| 20 content::WebContents* web_contents, |
| 21 mojo::InterfaceRequest<payments::mojom::PaymentRequest> request); |
| 22 ~PaymentRequestImpl() override; |
| 23 |
| 24 // payments::mojom::PaymentRequest "stub" |
| 25 void Init(payments::mojom::PaymentRequestClientPtr client, |
| 26 std::vector<payments::mojom::PaymentMethodDataPtr> methodData, |
| 27 payments::mojom::PaymentDetailsPtr details, |
| 28 payments::mojom::PaymentOptionsPtr options) override; |
| 29 void Show() override {} |
| 30 void UpdateWith(payments::mojom::PaymentDetailsPtr details) override {} |
| 31 void Abort() override {} |
| 32 void Complete(payments::mojom::PaymentComplete result) override {} |
| 33 |
| 34 private: |
| 35 content::WebContents* web_contents_; |
| 36 mojo::Binding<payments::mojom::PaymentRequest> binding_; |
| 37 DISALLOW_COPY_AND_ASSIGN(PaymentRequestImpl); |
| 38 }; |
| 39 |
| 40 } // namespace payments |
| 41 |
| 42 void CreatePaymentRequestHandler( |
| 43 content::WebContents* web_contents, |
| 44 mojo::InterfaceRequest<payments::mojom::PaymentRequest> request); |
| 45 |
| 46 #endif // CHROME_BROWSER_PAYMENTS_PAYMENT_REQUEST_IMPL_H_ |
| OLD | NEW |