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

Side by Side Diff: components/payments/content/payment_app.mojom

Issue 2811593009: [Payments] move //components/payments/content/*.mojom files to //components/payments/mojom (Closed)
Patch Set: Reland after updating chrome_content_browser_client.cc to fix android build Created 3 years, 8 months 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 unified diff | Download patch
OLDNEW
(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 module payments.mojom;
6
7 import "components/payments/content/payment_request.mojom";
8 import "mojo/common/time.mojom";
9 import "url/mojo/url.mojom";
10
11 enum PaymentAppManifestError {
12 NONE,
13 NOT_IMPLEMENTED,
14 NO_ACTIVE_WORKER,
15 MANIFEST_STORAGE_OPERATION_FAILED,
16 };
17
18 struct PaymentAppOption {
19 string name;
20 string? icon;
21 string id;
22 array<string> enabled_methods;
23 };
24
25 struct PaymentAppManifest {
26 string name;
27 string? icon;
28 array<PaymentAppOption> options;
29 };
30
31 interface PaymentManager {
32 Init(string service_worker_scope);
33 SetManifest(PaymentAppManifest payment_app_manifest)
34 => (PaymentAppManifestError error);
35 GetManifest()
36 => (PaymentAppManifest payment_app_manifest, PaymentAppManifestError error );
37 };
38
39 struct PaymentAppRequest {
40 url.mojom.Url origin;
41 array<PaymentMethodData> methodData;
42 PaymentItem total;
43 array<PaymentDetailsModifier> modifiers;
44 string optionId;
45 };
46
47 struct PaymentAppResponse {
48 string method_name;
49 string stringified_details;
50 };
51
52 // This interface is provided to pass a payment app response from payment
53 // request event in renderer side to browser side by calling respondWith().
54 interface PaymentAppResponseCallback {
55 OnPaymentAppResponse(PaymentAppResponse response,
56 mojo.common.mojom.Time dispatch_event_time);
57 };
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698