1 /* Copyright (c) 2012 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.
6 /* From dev/ppb_printing_dev.idl modified Fri Apr 19 10:45:09 2013. */
8 #ifndef PPAPI_C_DEV_PPB_PRINTING_DEV_H_
9 #define PPAPI_C_DEV_PPB_PRINTING_DEV_H_
11 #include "ppapi/c/dev/pp_print_settings_dev.h"
12 #include "ppapi/c/pp_bool.h"
13 #include "ppapi/c/pp_completion_callback.h"
14 #include "ppapi/c/pp_instance.h"
15 #include "ppapi/c/pp_macros.h"
16 #include "ppapi/c/pp_point.h"
17 #include "ppapi/c/pp_rect.h"
18 #include "ppapi/c/pp_resource.h"
19 #include "ppapi/c/pp_size.h"
20 #include "ppapi/c/pp_stdint.h"
22 #define PPB_PRINTING_DEV_INTERFACE_0_7 "PPB_Printing(Dev);0.7"
23 #define PPB_PRINTING_DEV_INTERFACE PPB_PRINTING_DEV_INTERFACE_0_7
27 * Definition of the PPB_Printing interface.
32 * @addtogroup Interfaces
35 struct PPB_Printing_Dev_0_7
{
36 /** Create a resource for accessing printing functionality.
38 * @param[in] instance A <code>PP_Instance</code> identifying one instance
41 * @return A <code>PP_Resource</code> containing the printing resource if
42 * successful or 0 if it could not be created.
44 PP_Resource (*Create
)(PP_Instance instance
);
46 * Outputs the default print settings for the default printer into
47 * <code>print_settings</code>. The callback is called with
48 * <code>PP_OK</code> when the settings have been retrieved successfully.
50 * @param[in] resource The printing resource.
52 * @param[in] callback A <code>CompletionCallback</code> to be called when
53 * <code>print_settings</code> have been retrieved.
55 * @return PP_OK_COMPLETIONPENDING if request for the default print settings
56 * was successful, another error code from pp_errors.h on failure.
58 int32_t (*GetDefaultPrintSettings
)(
60 struct PP_PrintSettings_Dev
* print_settings
,
61 struct PP_CompletionCallback callback
);
64 typedef struct PPB_Printing_Dev_0_7 PPB_Printing_Dev
;
69 #endif /* PPAPI_C_DEV_PPB_PRINTING_DEV_H_ */