Index: components/payments/content/payment_request.h |
diff --git a/components/payments/content/payment_request.h b/components/payments/content/payment_request.h |
index 2a20d68267e7744bc118c385ebb1765b97846dcb..fdb0e169f6dfda178d6713d1daba083817619516 100644 |
--- a/components/payments/content/payment_request.h |
+++ b/components/payments/content/payment_request.h |
@@ -14,6 +14,7 @@ |
#include "components/payments/content/payment_request.mojom.h" |
#include "components/payments/content/payment_request_delegate.h" |
#include "mojo/public/cpp/bindings/binding.h" |
+#include "mojo/public/cpp/bindings/interface_request.h" |
namespace autofill { |
class AutofillProfile; |
@@ -30,7 +31,7 @@ namespace payments { |
class CurrencyFormatter; |
class PaymentRequestWebContentsManager; |
-class PaymentRequest : payments::mojom::PaymentRequest { |
+class PaymentRequest : public mojom::PaymentRequest { |
public: |
class Observer { |
public: |
@@ -42,22 +43,21 @@ class PaymentRequest : payments::mojom::PaymentRequest { |
virtual ~Observer() {} |
}; |
- PaymentRequest( |
- content::WebContents* web_contents, |
- std::unique_ptr<PaymentRequestDelegate> delegate, |
- PaymentRequestWebContentsManager* manager, |
- mojo::InterfaceRequest<payments::mojom::PaymentRequest> request); |
+ PaymentRequest(content::WebContents* web_contents, |
+ std::unique_ptr<PaymentRequestDelegate> delegate, |
+ PaymentRequestWebContentsManager* manager, |
+ mojo::InterfaceRequest<mojom::PaymentRequest> request); |
~PaymentRequest() override; |
- // payments::mojom::PaymentRequest "stub" |
- void Init(payments::mojom::PaymentRequestClientPtr client, |
- std::vector<payments::mojom::PaymentMethodDataPtr> method_data, |
- payments::mojom::PaymentDetailsPtr details, |
- payments::mojom::PaymentOptionsPtr options) override; |
+ // mojom::PaymentRequest |
+ void Init(mojom::PaymentRequestClientPtr client, |
+ std::vector<mojom::PaymentMethodDataPtr> method_data, |
+ mojom::PaymentDetailsPtr details, |
+ mojom::PaymentOptionsPtr options) override; |
void Show() override; |
- void UpdateWith(payments::mojom::PaymentDetailsPtr details) override {} |
+ void UpdateWith(mojom::PaymentDetailsPtr details) override {} |
void Abort() override; |
- void Complete(payments::mojom::PaymentComplete result) override {} |
+ void Complete(mojom::PaymentComplete result) override {} |
void CanMakePayment() override {} |
// Called when the user explicitely cancelled the flow. Will send a message |
@@ -124,7 +124,7 @@ class PaymentRequest : payments::mojom::PaymentRequest { |
return delegate_->GetPersonalDataManager(); |
} |
- payments::mojom::PaymentDetails* details() { return details_.get(); } |
+ mojom::PaymentDetails* details() { return details_.get(); } |
const std::vector<std::string>& supported_card_networks() { |
return supported_card_networks_; |
} |
@@ -143,7 +143,7 @@ class PaymentRequest : payments::mojom::PaymentRequest { |
// Validates the |method_data| and fills |supported_card_networks_|. |
void PopulateValidatedMethodData( |
- const std::vector<payments::mojom::PaymentMethodDataPtr>& method_data); |
+ const std::vector<mojom::PaymentMethodDataPtr>& method_data); |
// Updates |is_ready_to_pay_| with the current state, by validating that all |
// the required information is available and notify observers. |
@@ -163,10 +163,10 @@ class PaymentRequest : payments::mojom::PaymentRequest { |
std::unique_ptr<PaymentRequestDelegate> delegate_; |
// |manager_| owns this PaymentRequest. |
PaymentRequestWebContentsManager* manager_; |
- mojo::Binding<payments::mojom::PaymentRequest> binding_; |
- payments::mojom::PaymentRequestClientPtr client_; |
- payments::mojom::PaymentDetailsPtr details_; |
- payments::mojom::PaymentOptionsPtr options_; |
+ mojo::Binding<mojom::PaymentRequest> binding_; |
+ mojom::PaymentRequestClientPtr client_; |
+ mojom::PaymentDetailsPtr details_; |
+ mojom::PaymentOptionsPtr options_; |
std::unique_ptr<CurrencyFormatter> currency_formatter_; |
// A set of supported basic card networks. |
std::vector<std::string> supported_card_networks_; |