OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 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 | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "modules/payments/PaymentAppRequestConversion.h" | 5 #include "modules/payments/PaymentAppRequestConversion.h" |
6 | 6 |
7 #include "bindings/core/v8/ScriptState.h" | 7 #include "bindings/core/v8/ScriptState.h" |
8 #include "bindings/core/v8/ToV8.h" | 8 #include "bindings/core/v8/ToV8ForCore.h" |
9 #include "modules/payments/PaymentAppRequest.h" | 9 #include "modules/payments/PaymentAppRequest.h" |
10 #include "modules/payments/PaymentCurrencyAmount.h" | 10 #include "modules/payments/PaymentCurrencyAmount.h" |
11 #include "modules/payments/PaymentDetailsModifier.h" | 11 #include "modules/payments/PaymentDetailsModifier.h" |
12 #include "modules/payments/PaymentItem.h" | 12 #include "modules/payments/PaymentItem.h" |
13 #include "modules/payments/PaymentMethodData.h" | 13 #include "modules/payments/PaymentMethodData.h" |
14 #include "public/platform/modules/payments/WebPaymentAppRequest.h" | 14 #include "public/platform/modules/payments/WebPaymentAppRequest.h" |
15 #include "public/platform/modules/payments/WebPaymentMethodData.h" | 15 #include "public/platform/modules/payments/WebPaymentMethodData.h" |
16 | 16 |
17 namespace blink { | 17 namespace blink { |
18 namespace { | 18 namespace { |
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
103 app_request.setTotal(ToPaymentItem(web_app_request.total)); | 103 app_request.setTotal(ToPaymentItem(web_app_request.total)); |
104 HeapVector<PaymentDetailsModifier> modifiers; | 104 HeapVector<PaymentDetailsModifier> modifiers; |
105 for (const auto& modifier : web_app_request.modifiers) { | 105 for (const auto& modifier : web_app_request.modifiers) { |
106 modifiers.push_back(ToPaymentDetailsModifier(script_state, modifier)); | 106 modifiers.push_back(ToPaymentDetailsModifier(script_state, modifier)); |
107 } | 107 } |
108 app_request.setOptionId(web_app_request.option_id); | 108 app_request.setOptionId(web_app_request.option_id); |
109 return app_request; | 109 return app_request; |
110 } | 110 } |
111 | 111 |
112 } // namespace blink | 112 } // namespace blink |
OLD | NEW |