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

Side by Side Diff: extensions/common/api/printer_provider_internal.idl

Issue 1148383002: Add onGetUsbPrinterInfoRequested event to printerProvider API. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebased. Created 5 years, 6 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
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 // printerProviderInternal 5 // printerProviderInternal
6 // Internal API used to run callbacks passed to chrome.printerProvider API 6 // Internal API used to run callbacks passed to chrome.printerProvider API
7 // events. 7 // events.
8 // When dispatching a chrome.printerProvider API event, its arguments will be 8 // When dispatching a chrome.printerProvider API event, its arguments will be
9 // massaged in custom bindings so a callback is added. The callback uses 9 // massaged in custom bindings so a callback is added. The callback uses
10 // chrome.printerProviderInternal API to report the event results. 10 // chrome.printerProviderInternal API to report the event results.
(...skipping 21 matching lines...) Expand all
32 callback BlobCallback = void(BlobInfo blobInfo); 32 callback BlobCallback = void(BlobInfo blobInfo);
33 33
34 interface Functions { 34 interface Functions {
35 // Runs callback to printerProvider.onGetPrintersRequested event. 35 // Runs callback to printerProvider.onGetPrintersRequested event.
36 // |requestId|: Parameter identifying the event instance for which the 36 // |requestId|: Parameter identifying the event instance for which the
37 // callback is run. 37 // callback is run.
38 // |printers|: List of printers reported by the extension. 38 // |printers|: List of printers reported by the extension.
39 void reportPrinters(long requestId, 39 void reportPrinters(long requestId,
40 optional printerProvider.PrinterInfo[] printers); 40 optional printerProvider.PrinterInfo[] printers);
41 41
42 // Runs callback to printerProvider.onUsbAccessGranted event.
43 // |requestId|: Parameter identifying the event instance for which the
44 // callback is run.
45 // |printerInfo|: Printer information reported by the extension.
46 void reportUsbPrinterInfo(long requestId,
47 optional printerProvider.PrinterInfo printerInfo);
48
42 // Runs callback to printerProvider.onGetCapabilityRequested event. 49 // Runs callback to printerProvider.onGetCapabilityRequested event.
43 // |requestId|: Parameter identifying the event instance for which the 50 // |requestId|: Parameter identifying the event instance for which the
44 // callback is run. 51 // callback is run.
45 // |error|: The printer capability returned by the extension. 52 // |error|: The printer capability returned by the extension.
46 void reportPrinterCapability(long request_id, optional object capability); 53 void reportPrinterCapability(long request_id, optional object capability);
47 54
48 // Runs callback to printerProvider.onPrintRequested event. 55 // Runs callback to printerProvider.onPrintRequested event.
49 // |requestId|: Parameter identifying the event instance for which the 56 // |requestId|: Parameter identifying the event instance for which the
50 // callback is run. 57 // callback is run.
51 // |error|: The requested print job result. 58 // |error|: The requested print job result.
52 void reportPrintResult(long request_id, optional PrintError error); 59 void reportPrintResult(long request_id, optional PrintError error);
53 60
54 // Gets information needed to create a print data blob for a print request. 61 // Gets information needed to create a print data blob for a print request.
55 // The blob will be dispatched to the extension via 62 // The blob will be dispatched to the extension via
56 // printerProvider.onPrintRequested event. 63 // printerProvider.onPrintRequested event.
57 // |requestId|: The request id for the print request for which data is 64 // |requestId|: The request id for the print request for which data is
58 // needed. 65 // needed.
59 // |callback|: Callback called with the information needed to create a blob 66 // |callback|: Callback called with the information needed to create a blob
60 // of print data. 67 // of print data.
61 void getPrintData(long requestId, BlobCallback callback); 68 void getPrintData(long requestId, BlobCallback callback);
62 }; 69 };
63 }; 70 };
64 71
OLDNEW
« no previous file with comments | « extensions/common/api/printer_provider.idl ('k') | extensions/renderer/resources/printer_provider_custom_bindings.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698