diff options
author | neb@chromium.org <neb@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-12-15 20:52:45 +0000 |
---|---|---|
committer | neb@chromium.org <neb@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-12-15 20:52:45 +0000 |
commit | 22611c632574687325aa2ebeea896594fb83fbc3 (patch) | |
tree | 96371512316efd1b73a8ed3b0291fbc314f1ea6e | |
parent | ed875647795b7886bb90d2e289492df1c7da1cec (diff) | |
download | chromium_src-22611c632574687325aa2ebeea896594fb83fbc3.zip chromium_src-22611c632574687325aa2ebeea896594fb83fbc3.tar.gz chromium_src-22611c632574687325aa2ebeea896594fb83fbc3.tar.bz2 |
Resource width 64->32 change.
Mostly done by bbudge.
BUG=none
TEST=ppapi_include_tests.py
Review URL: http://codereview.chromium.org/5837001
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@69309 0039d316-1c4b-4281-b951-d872f2087c98
49 files changed, 66 insertions, 69 deletions
diff --git a/ppapi/c/dev/pp_video_dev.h b/ppapi/c/dev/pp_video_dev.h index adef7be..6f67c1e 100644 --- a/ppapi/c/dev/pp_video_dev.h +++ b/ppapi/c/dev/pp_video_dev.h @@ -223,6 +223,11 @@ struct PP_VideoCompressedDataBuffer_Dev { // Bit mask of PP_VideoFrameInfoFlag. uint32_t flags; + // Padding to ensure the PP_Resource is 8-byte aligned relative to the + // start of the struct. This helps ensure PP_VideoFrameBuffer_Dev has + // consistent size and alignment across compilers. + int32_t padding; + // Time stamp of the frame in microsecond. uint64_t time_stamp_us; }; @@ -236,11 +241,6 @@ struct PP_VideoFrameBuffer_Dev { int32_t height; int32_t stride; - // Padding to ensure the PP_Resource is 8-byte aligned relative to the - // start of the struct. This helps ensure PP_VideoFrameBuffer_Dev has - // consistent size and alignment across compilers. - int32_t padding; - // TODO(wjia): uint8* would be better for some cases. PP_Resource buffer; } data_plane[PP_VIDEOFRAMEBUFFER_MAXNUMBERPLANES]; diff --git a/ppapi/c/dev/ppb_audio_config_dev.h b/ppapi/c/dev/ppb_audio_config_dev.h index 07c7824..411ad76 100644 --- a/ppapi/c/dev/ppb_audio_config_dev.h +++ b/ppapi/c/dev/ppb_audio_config_dev.h @@ -11,7 +11,7 @@ #include "ppapi/c/pp_resource.h" #include "ppapi/c/pp_stdint.h" -#define PPB_AUDIO_CONFIG_DEV_INTERFACE "PPB_AudioConfig(Dev);0.3" +#define PPB_AUDIO_CONFIG_DEV_INTERFACE "PPB_AudioConfig(Dev);0.4" enum { PP_AUDIOMINSAMPLEFRAMECOUNT = 64, diff --git a/ppapi/c/dev/ppb_audio_dev.h b/ppapi/c/dev/ppb_audio_dev.h index 667371c..f298302 100644 --- a/ppapi/c/dev/ppb_audio_dev.h +++ b/ppapi/c/dev/ppb_audio_dev.h @@ -11,7 +11,7 @@ #include "ppapi/c/pp_resource.h" #include "ppapi/c/pp_stdint.h" -#define PPB_AUDIO_DEV_INTERFACE "PPB_Audio(Dev);0.3" +#define PPB_AUDIO_DEV_INTERFACE "PPB_Audio(Dev);0.4" // Callback function type for SetCallback. typedef void (*PPB_Audio_Callback)(void* sample_buffer, diff --git a/ppapi/c/dev/ppb_audio_trusted_dev.h b/ppapi/c/dev/ppb_audio_trusted_dev.h index aab83fe..0bada36 100644 --- a/ppapi/c/dev/ppb_audio_trusted_dev.h +++ b/ppapi/c/dev/ppb_audio_trusted_dev.h @@ -9,7 +9,7 @@ #include "ppapi/c/pp_instance.h" #include "ppapi/c/pp_resource.h" -#define PPB_AUDIO_TRUSTED_DEV_INTERFACE "PPB_AudioTrusted(Dev);0.2" +#define PPB_AUDIO_TRUSTED_DEV_INTERFACE "PPB_AudioTrusted(Dev);0.3" /** * This interface is to be used by proxy implementations. All diff --git a/ppapi/c/dev/ppb_buffer_dev.h b/ppapi/c/dev/ppb_buffer_dev.h index 9906967..c750190 100644 --- a/ppapi/c/dev/ppb_buffer_dev.h +++ b/ppapi/c/dev/ppb_buffer_dev.h @@ -10,7 +10,7 @@ #include "ppapi/c/pp_resource.h" #include "ppapi/c/pp_stdint.h" -#define PPB_BUFFER_DEV_INTERFACE "PPB_Buffer(Dev);0.3" +#define PPB_BUFFER_DEV_INTERFACE "PPB_Buffer(Dev);0.4" struct PPB_Buffer_Dev { // Allocates a buffer of the given size in bytes. The return value will have diff --git a/ppapi/c/dev/ppb_char_set_dev.h b/ppapi/c/dev/ppb_char_set_dev.h index ac1ad96..03cfa87a 100644 --- a/ppapi/c/dev/ppb_char_set_dev.h +++ b/ppapi/c/dev/ppb_char_set_dev.h @@ -10,7 +10,7 @@ #include "ppapi/c/pp_stdint.h" #include "ppapi/c/pp_var.h" -#define PPB_CHAR_SET_DEV_INTERFACE "PPB_CharSet(Dev);0.3" +#define PPB_CHAR_SET_DEV_INTERFACE "PPB_CharSet(Dev);0.4" // Specifies the error behavior for the character set conversion functions. // This will affect two cases: where the input is not encoded correctly, and diff --git a/ppapi/c/dev/ppb_cursor_control_dev.h b/ppapi/c/dev/ppb_cursor_control_dev.h index 45b37e2..c515af7 100644 --- a/ppapi/c/dev/ppb_cursor_control_dev.h +++ b/ppapi/c/dev/ppb_cursor_control_dev.h @@ -11,7 +11,7 @@ #include "ppapi/c/pp_point.h" #include "ppapi/c/pp_resource.h" -#define PPB_CURSOR_CONTROL_DEV_INTERFACE "PPB_CursorControl(Dev);0.2" +#define PPB_CURSOR_CONTROL_DEV_INTERFACE "PPB_CursorControl(Dev);0.3" struct PPB_CursorControl_Dev { // Set a cursor. If "type" is PP_CURSOR_TYPE_CUSTOM, then "custom_image" diff --git a/ppapi/c/dev/ppb_directory_reader_dev.h b/ppapi/c/dev/ppb_directory_reader_dev.h index 8dc0f6a..74a92ef 100644 --- a/ppapi/c/dev/ppb_directory_reader_dev.h +++ b/ppapi/c/dev/ppb_directory_reader_dev.h @@ -16,17 +16,10 @@ struct PP_CompletionCallback; struct PP_DirectoryEntry_Dev { PP_Resource file_ref; PP_FileType_Dev file_type; - - /** Ensure that this struct is 16-bytes wide by padding the end. Because - * PP_Resource is an 8-byte type, some compilers align this struct on 8-byte - * boundaries and pad it to 16 bytes even without @a padding. This makes its - * size consistent across compilers. - */ - int32_t padding; }; -PP_COMPILE_ASSERT_STRUCT_SIZE_IN_BYTES(PP_DirectoryEntry_Dev, 16); +PP_COMPILE_ASSERT_STRUCT_SIZE_IN_BYTES(PP_DirectoryEntry_Dev, 8); -#define PPB_DIRECTORYREADER_DEV_INTERFACE "PPB_DirectoryReader(Dev);0.3" +#define PPB_DIRECTORYREADER_DEV_INTERFACE "PPB_DirectoryReader(Dev);0.4" struct PPB_DirectoryReader_Dev { // Creates a DirectoryReader for the given directory. Upon success, the diff --git a/ppapi/c/dev/ppb_file_chooser_dev.h b/ppapi/c/dev/ppb_file_chooser_dev.h index b63a930..e807f38 100644 --- a/ppapi/c/dev/ppb_file_chooser_dev.h +++ b/ppapi/c/dev/ppb_file_chooser_dev.h @@ -30,7 +30,7 @@ struct PP_FileChooserOptions_Dev { const char* accept_mime_types; }; -#define PPB_FILECHOOSER_DEV_INTERFACE "PPB_FileChooser(Dev);0.2" +#define PPB_FILECHOOSER_DEV_INTERFACE "PPB_FileChooser(Dev);0.3" struct PPB_FileChooser_Dev { // Creates a file chooser dialog with the specified options. The chooser is diff --git a/ppapi/c/dev/ppb_file_io_dev.h b/ppapi/c/dev/ppb_file_io_dev.h index 1264599..64f47c0 100644 --- a/ppapi/c/dev/ppb_file_io_dev.h +++ b/ppapi/c/dev/ppb_file_io_dev.h @@ -39,7 +39,7 @@ typedef enum { } PP_FileOpenFlags_Dev; PP_COMPILE_ASSERT_SIZE_IN_BYTES(PP_FileOpenFlags_Dev, 4); -#define PPB_FILEIO_DEV_INTERFACE "PPB_FileIO(Dev);0.2" +#define PPB_FILEIO_DEV_INTERFACE "PPB_FileIO(Dev);0.3" // Use this interface to operate on a regular file (PP_FileType_Regular). struct PPB_FileIO_Dev { diff --git a/ppapi/c/dev/ppb_file_io_trusted_dev.h b/ppapi/c/dev/ppb_file_io_trusted_dev.h index f4915fa..ef6715b 100644 --- a/ppapi/c/dev/ppb_file_io_trusted_dev.h +++ b/ppapi/c/dev/ppb_file_io_trusted_dev.h @@ -10,7 +10,7 @@ struct PP_CompletionCallback; -#define PPB_FILEIOTRUSTED_DEV_INTERFACE "PPB_FileIOTrusted(Dev);0.1" +#define PPB_FILEIOTRUSTED_DEV_INTERFACE "PPB_FileIOTrusted(Dev);0.2" // Available only to trusted implementations. struct PPB_FileIOTrusted_Dev { diff --git a/ppapi/c/dev/ppb_file_ref_dev.h b/ppapi/c/dev/ppb_file_ref_dev.h index 210ddbd..e56fa1c 100644 --- a/ppapi/c/dev/ppb_file_ref_dev.h +++ b/ppapi/c/dev/ppb_file_ref_dev.h @@ -11,7 +11,7 @@ #include "ppapi/c/pp_resource.h" #include "ppapi/c/pp_var.h" -#define PPB_FILEREF_DEV_INTERFACE "PPB_FileRef(Dev);0.4" +#define PPB_FILEREF_DEV_INTERFACE "PPB_FileRef(Dev);0.5" // A FileRef is a "weak pointer" to a file in a file system. It contains a // PP_FileSystemType identifier and a file path string. diff --git a/ppapi/c/dev/ppb_file_system_dev.h b/ppapi/c/dev/ppb_file_system_dev.h index 9f93a1a..2a8dbf3 100644 --- a/ppapi/c/dev/ppb_file_system_dev.h +++ b/ppapi/c/dev/ppb_file_system_dev.h @@ -13,7 +13,7 @@ struct PP_CompletionCallback; -#define PPB_FILESYSTEM_DEV_INTERFACE "PPB_FileSystem(Dev);0.2" +#define PPB_FILESYSTEM_DEV_INTERFACE "PPB_FileSystem(Dev);0.3" struct PPB_FileSystem_Dev { // Creates a weak pointer to the filesystem of the given type. diff --git a/ppapi/c/dev/ppb_find_dev.h b/ppapi/c/dev/ppb_find_dev.h index b74416e..972c3d8 100644 --- a/ppapi/c/dev/ppb_find_dev.h +++ b/ppapi/c/dev/ppb_find_dev.h @@ -9,7 +9,7 @@ #include "ppapi/c/pp_instance.h" #include "ppapi/c/pp_stdint.h" -#define PPB_FIND_DEV_INTERFACE "PPB_Find(Dev);0.2" +#define PPB_FIND_DEV_INTERFACE "PPB_Find(Dev);0.3" struct PPB_Find_Dev { // Updates the number of find results for the current search term. If diff --git a/ppapi/c/dev/ppb_font_dev.h b/ppapi/c/dev/ppb_font_dev.h index 8056d95..747cb7c 100644 --- a/ppapi/c/dev/ppb_font_dev.h +++ b/ppapi/c/dev/ppb_font_dev.h @@ -12,7 +12,7 @@ #include "ppapi/c/pp_stdint.h" #include "ppapi/c/pp_var.h" -#define PPB_FONT_DEV_INTERFACE "PPB_Font(Dev);0.4" +#define PPB_FONT_DEV_INTERFACE "PPB_Font(Dev);0.5" struct PP_Point; struct PP_Rect; diff --git a/ppapi/c/dev/ppb_fullscreen_dev.h b/ppapi/c/dev/ppb_fullscreen_dev.h index 3166eb9..22b19df 100644 --- a/ppapi/c/dev/ppb_fullscreen_dev.h +++ b/ppapi/c/dev/ppb_fullscreen_dev.h @@ -9,7 +9,7 @@ #include "ppapi/c/pp_instance.h" #include "ppapi/c/pp_stdint.h" -#define PPB_FULLSCREEN_DEV_INTERFACE "PPB_Fullscreen(Dev);0.2" +#define PPB_FULLSCREEN_DEV_INTERFACE "PPB_Fullscreen(Dev);0.3" // Use this interface to change a plugin instance to fullscreen mode. struct PPB_Fullscreen_Dev { diff --git a/ppapi/c/dev/ppb_graphics_3d_dev.h b/ppapi/c/dev/ppb_graphics_3d_dev.h index 27793c1..7bd739b 100644 --- a/ppapi/c/dev/ppb_graphics_3d_dev.h +++ b/ppapi/c/dev/ppb_graphics_3d_dev.h @@ -25,7 +25,7 @@ // // Shutdown. // core->ReleaseResource(context); -#define PPB_GRAPHICS_3D_DEV_INTERFACE "PPB_Graphics3D(Dev);0.2" +#define PPB_GRAPHICS_3D_DEV_INTERFACE "PPB_Graphics3D(Dev);0.3" // These are the same error codes as used by EGL. enum { diff --git a/ppapi/c/dev/ppb_scrollbar_dev.h b/ppapi/c/dev/ppb_scrollbar_dev.h index 25cf0e7..4166840 100644 --- a/ppapi/c/dev/ppb_scrollbar_dev.h +++ b/ppapi/c/dev/ppb_scrollbar_dev.h @@ -21,7 +21,7 @@ typedef enum { } PP_ScrollBy_Dev; PP_COMPILE_ASSERT_SIZE_IN_BYTES(PP_ScrollBy_Dev, 4); -#define PPB_SCROLLBAR_DEV_INTERFACE "PPB_Scrollbar(Dev);0.2" +#define PPB_SCROLLBAR_DEV_INTERFACE "PPB_Scrollbar(Dev);0.3" // The interface for a scrollbar. A scrollbar is a widget, so the functions // in PPB_Widget can also be used with scrollbar objects. diff --git a/ppapi/c/dev/ppb_testing_dev.h b/ppapi/c/dev/ppb_testing_dev.h index 5606ca6..fa193569 100644 --- a/ppapi/c/dev/ppb_testing_dev.h +++ b/ppapi/c/dev/ppb_testing_dev.h @@ -12,7 +12,7 @@ struct PP_Point; -#define PPB_TESTING_DEV_INTERFACE "PPB_Testing(Dev);0.3" +#define PPB_TESTING_DEV_INTERFACE "PPB_Testing(Dev);0.4" // This interface contains functions used for unit testing. Do not use in // production code. They are not guaranteed to be available in normal plugin diff --git a/ppapi/c/dev/ppb_transport_dev.h b/ppapi/c/dev/ppb_transport_dev.h index 33dbf57..ee4fcaf 100644 --- a/ppapi/c/dev/ppb_transport_dev.h +++ b/ppapi/c/dev/ppb_transport_dev.h @@ -13,7 +13,7 @@ #include "ppapi/c/pp_stdint.h" #include "ppapi/c/pp_var.h" -#define PPB_TRANSPORT_DEV_INTERFACE "PPB_Transport;0.3" +#define PPB_TRANSPORT_DEV_INTERFACE "PPB_Transport;0.4" struct PPB_Transport_Dev { // Creates a new transport object with the specified name diff --git a/ppapi/c/dev/ppb_url_util_dev.h b/ppapi/c/dev/ppb_url_util_dev.h index 49bcc18..394ad87 100644 --- a/ppapi/c/dev/ppb_url_util_dev.h +++ b/ppapi/c/dev/ppb_url_util_dev.h @@ -11,7 +11,7 @@ #include "ppapi/c/pp_stdint.h" #include "ppapi/c/pp_var.h" -#define PPB_URLUTIL_DEV_INTERFACE "PPB_UrlUtil(Dev);0.3" +#define PPB_URLUTIL_DEV_INTERFACE "PPB_UrlUtil(Dev);0.4" // A component specifies the range of the part of the URL. The begin specifies // the index into the string of the first character of that component. The len diff --git a/ppapi/c/dev/ppb_var_deprecated.h b/ppapi/c/dev/ppb_var_deprecated.h index e71ba9f..6dba7a0 100644 --- a/ppapi/c/dev/ppb_var_deprecated.h +++ b/ppapi/c/dev/ppb_var_deprecated.h @@ -12,7 +12,7 @@ struct PPP_Class_Deprecated; -#define PPB_VAR_DEPRECATED_INTERFACE "PPB_Var(Deprecated);0.2" +#define PPB_VAR_DEPRECATED_INTERFACE "PPB_Var(Deprecated);0.3" /** * @file diff --git a/ppapi/c/dev/ppb_video_decoder_dev.h b/ppapi/c/dev/ppb_video_decoder_dev.h index 975e68b..1e93780 100644 --- a/ppapi/c/dev/ppb_video_decoder_dev.h +++ b/ppapi/c/dev/ppb_video_decoder_dev.h @@ -12,7 +12,7 @@ #include "ppapi/c/pp_stdint.h" #include "ppapi/c/pp_completion_callback.h" -#define PPB_VIDEODECODER_DEV_INTERFACE "PPB_VideoDecoder(Dev);0.3" +#define PPB_VIDEODECODER_DEV_INTERFACE "PPB_VideoDecoder(Dev);0.4" struct PPB_VideoDecoder_Dev { // Queries capability of the decoder for |codec|. diff --git a/ppapi/c/dev/ppb_zoom_dev.h b/ppapi/c/dev/ppb_zoom_dev.h index e6046e1..c44e8c5 100644 --- a/ppapi/c/dev/ppb_zoom_dev.h +++ b/ppapi/c/dev/ppb_zoom_dev.h @@ -8,7 +8,7 @@ #include "ppapi/c/pp_instance.h" // Zoom interface should only apply to those full-page "plugin-document". -#define PPB_ZOOM_DEV_INTERFACE "PPB_Zoom(Dev);0.1" +#define PPB_ZOOM_DEV_INTERFACE "PPB_Zoom(Dev);0.2" struct PPB_Zoom_Dev { // Informs the browser about the new zoom factor for the plugin (see diff --git a/ppapi/c/dev/ppp_cursor_control_dev.h b/ppapi/c/dev/ppp_cursor_control_dev.h index b9403f4..81a1a88 100644 --- a/ppapi/c/dev/ppp_cursor_control_dev.h +++ b/ppapi/c/dev/ppp_cursor_control_dev.h @@ -7,7 +7,7 @@ #include "ppapi/c/pp_instance.h" -#define PPP_CURSOR_CONTROL_DEV_INTERFACE "PPP_CursorControl(Dev);0.1" +#define PPP_CURSOR_CONTROL_DEV_INTERFACE "PPP_CursorControl(Dev);0.2" struct PPP_CursorControl_Dev { // Called when the instance looses the cursor lock, e.g. because the user diff --git a/ppapi/c/dev/ppp_find_dev.h b/ppapi/c/dev/ppp_find_dev.h index c20f699..02c6a15 100644 --- a/ppapi/c/dev/ppp_find_dev.h +++ b/ppapi/c/dev/ppp_find_dev.h @@ -8,7 +8,7 @@ #include "ppapi/c/pp_bool.h" #include "ppapi/c/pp_instance.h" -#define PPP_FIND_DEV_INTERFACE "PPP_Find(Dev);0.2" +#define PPP_FIND_DEV_INTERFACE "PPP_Find(Dev);0.3" struct PPP_Find_Dev { // Finds the given UTF-8 text starting at the current selection. The number of diff --git a/ppapi/c/dev/ppp_graphics_3d_dev.h b/ppapi/c/dev/ppp_graphics_3d_dev.h index 2dc4402..ac1de8d 100644 --- a/ppapi/c/dev/ppp_graphics_3d_dev.h +++ b/ppapi/c/dev/ppp_graphics_3d_dev.h @@ -7,7 +7,7 @@ #include "ppapi/c/pp_instance.h" -#define PPP_GRAPHICS_3D_DEV_INTERFACE "PPP_Graphics_3D(Dev);0.1" +#define PPP_GRAPHICS_3D_DEV_INTERFACE "PPP_Graphics_3D(Dev);0.2" struct PPP_Graphics3D_Dev { // Called when the OpenGL ES window is invalidated and needs to be repainted. diff --git a/ppapi/c/dev/ppp_printing_dev.h b/ppapi/c/dev/ppp_printing_dev.h index 00b5e6b..dce201b 100644 --- a/ppapi/c/dev/ppp_printing_dev.h +++ b/ppapi/c/dev/ppp_printing_dev.h @@ -46,7 +46,7 @@ struct PP_PrintPageNumberRange_Dev { PP_COMPILE_ASSERT_STRUCT_SIZE_IN_BYTES(PP_PrintPageNumberRange_Dev, 8); // Interface for the plugin to implement printing. -#define PPP_PRINTING_DEV_INTERFACE "PPP_Printing(Dev);0.2" +#define PPP_PRINTING_DEV_INTERFACE "PPP_Printing(Dev);0.3" struct PPP_Printing_Dev { // Returns array of supported print output formats. The array is allocated diff --git a/ppapi/c/dev/ppp_scrollbar_dev.h b/ppapi/c/dev/ppp_scrollbar_dev.h index b032a2a..ba39bd6 100644 --- a/ppapi/c/dev/ppp_scrollbar_dev.h +++ b/ppapi/c/dev/ppp_scrollbar_dev.h @@ -10,7 +10,7 @@ #include "ppapi/c/pp_stdint.h" // Interface for the plugin to implement when using a scrollbar widget. -#define PPP_SCROLLBAR_DEV_INTERFACE "PPP_Scrollbar(Dev);0.1" +#define PPP_SCROLLBAR_DEV_INTERFACE "PPP_Scrollbar(Dev);0.2" struct PPP_Scrollbar_Dev { // Informs the instance that the scrollbar's value has changed. diff --git a/ppapi/c/dev/ppp_selection_dev.h b/ppapi/c/dev/ppp_selection_dev.h index 834b4ed..d2f3f1a 100644 --- a/ppapi/c/dev/ppp_selection_dev.h +++ b/ppapi/c/dev/ppp_selection_dev.h @@ -9,7 +9,7 @@ #include "ppapi/c/pp_instance.h" #include "ppapi/c/pp_var.h" -#define PPP_SELECTION_DEV_INTERFACE "PPP_Selection(Dev);0.2" +#define PPP_SELECTION_DEV_INTERFACE "PPP_Selection(Dev);0.3" struct PPP_Selection_Dev { /** diff --git a/ppapi/c/dev/ppp_widget_dev.h b/ppapi/c/dev/ppp_widget_dev.h index 26a4847..27c7794 100644 --- a/ppapi/c/dev/ppp_widget_dev.h +++ b/ppapi/c/dev/ppp_widget_dev.h @@ -10,7 +10,7 @@ #include "ppapi/c/pp_rect.h" // Interface for the plugin to implement when using a widget. -#define PPP_WIDGET_DEV_INTERFACE "PPP_Widget(Dev);0.1" +#define PPP_WIDGET_DEV_INTERFACE "PPP_Widget(Dev);0.2" struct PPP_Widget_Dev { // Informs the instance that the given rectangle needs to be repainted. diff --git a/ppapi/c/dev/ppp_zoom_dev.h b/ppapi/c/dev/ppp_zoom_dev.h index 90c8be9..c7dd849 100644 --- a/ppapi/c/dev/ppp_zoom_dev.h +++ b/ppapi/c/dev/ppp_zoom_dev.h @@ -9,7 +9,7 @@ #include "ppapi/c/pp_instance.h" // Zoom interface should only apply to those full-page "plugin-document". -#define PPP_ZOOM_DEV_INTERFACE "PPP_Zoom(Dev);0.2" +#define PPP_ZOOM_DEV_INTERFACE "PPP_Zoom(Dev);0.3" struct PPP_Zoom_Dev { // Instruct plug-in to zoom according to the given factor and whether the zoom diff --git a/ppapi/c/pp_instance.h b/ppapi/c/pp_instance.h index f061ceb..788000b 100644 --- a/ppapi/c/pp_instance.h +++ b/ppapi/c/pp_instance.h @@ -24,8 +24,8 @@ * is guaranteed never to be 0, so a plugin can initialize it to 0 to * indicate a "NULL handle." */ -typedef int64_t PP_Instance; -PP_COMPILE_ASSERT_SIZE_IN_BYTES(PP_Instance, 8); +typedef int32_t PP_Instance; +PP_COMPILE_ASSERT_SIZE_IN_BYTES(PP_Instance, 4); /** * @} diff --git a/ppapi/c/pp_module.h b/ppapi/c/pp_module.h index f62337b..420f51d 100644 --- a/ppapi/c/pp_module.h +++ b/ppapi/c/pp_module.h @@ -21,8 +21,8 @@ * handle assigned by the browser to the plugin. It is guaranteed never to be * 0, so a plugin can initialize it to 0 to indicate a "NULL handle." */ -typedef int64_t PP_Module; -PP_COMPILE_ASSERT_SIZE_IN_BYTES(PP_Module, 8); +typedef int32_t PP_Module; +PP_COMPILE_ASSERT_SIZE_IN_BYTES(PP_Module, 4); /** * @} diff --git a/ppapi/c/pp_resource.h b/ppapi/c/pp_resource.h index c3d1aca..e81780e 100644 --- a/ppapi/c/pp_resource.h +++ b/ppapi/c/pp_resource.h @@ -30,8 +30,8 @@ * it to 0 to indicate a "NULL handle." Some interfaces may return a NULL * resource to indicate failure. */ -typedef int64_t PP_Resource; -PP_COMPILE_ASSERT_SIZE_IN_BYTES(PP_Resource, 8); +typedef int32_t PP_Resource; +PP_COMPILE_ASSERT_SIZE_IN_BYTES(PP_Resource, 4); /** * @} diff --git a/ppapi/c/ppb_class.h b/ppapi/c/ppb_class.h index 0cb249c..bd0d8ef 100644 --- a/ppapi/c/ppb_class.h +++ b/ppapi/c/ppb_class.h @@ -11,7 +11,7 @@ #include "ppapi/c/pp_var.h" #include "ppapi/c/ppb_var.h" -#define PPB_CLASS_INTERFACE "PPB_Class;0.3" +#define PPB_CLASS_INTERFACE "PPB_Class;0.4" /** * @file diff --git a/ppapi/c/ppb_core.h b/ppapi/c/ppb_core.h index 471322a..b26e25f 100644 --- a/ppapi/c/ppb_core.h +++ b/ppapi/c/ppb_core.h @@ -13,7 +13,7 @@ struct PP_CompletionCallback; -#define PPB_CORE_INTERFACE "PPB_Core;0.2" +#define PPB_CORE_INTERFACE "PPB_Core;0.3" /** * @file diff --git a/ppapi/c/ppb_graphics_2d.h b/ppapi/c/ppb_graphics_2d.h index 8f152d33..d5b7ad0 100644 --- a/ppapi/c/ppb_graphics_2d.h +++ b/ppapi/c/ppb_graphics_2d.h @@ -15,7 +15,7 @@ struct PP_Point; struct PP_Rect; struct PP_Size; -#define PPB_GRAPHICS_2D_INTERFACE "PPB_Graphics2D;0.2" +#define PPB_GRAPHICS_2D_INTERFACE "PPB_Graphics2D;0.3" /** * @file diff --git a/ppapi/c/ppb_image_data.h b/ppapi/c/ppb_image_data.h index ce9356f..cb852b6 100644 --- a/ppapi/c/ppb_image_data.h +++ b/ppapi/c/ppb_image_data.h @@ -30,7 +30,7 @@ struct PP_ImageDataDesc { }; PP_COMPILE_ASSERT_STRUCT_SIZE_IN_BYTES(PP_ImageDataDesc, 16); -#define PPB_IMAGEDATA_INTERFACE "PPB_ImageData;0.2" +#define PPB_IMAGEDATA_INTERFACE "PPB_ImageData;0.3" /** * @file diff --git a/ppapi/c/ppb_instance.h b/ppapi/c/ppb_instance.h index f7f137f..6a3588f 100644 --- a/ppapi/c/ppb_instance.h +++ b/ppapi/c/ppb_instance.h @@ -10,7 +10,7 @@ #include "ppapi/c/pp_resource.h" #include "ppapi/c/pp_var.h" -#define PPB_INSTANCE_INTERFACE "PPB_Instance;0.3" +#define PPB_INSTANCE_INTERFACE "PPB_Instance;0.4" /** * @file diff --git a/ppapi/c/ppb_url_loader.h b/ppapi/c/ppb_url_loader.h index 7d039d6..2386470 100644 --- a/ppapi/c/ppb_url_loader.h +++ b/ppapi/c/ppb_url_loader.h @@ -12,7 +12,7 @@ struct PP_CompletionCallback; -#define PPB_URLLOADER_INTERFACE "PPB_URLLoader;1" +#define PPB_URLLOADER_INTERFACE "PPB_URLLoader;0.1" // The interface for loading URLs. // diff --git a/ppapi/c/ppb_url_request_info.h b/ppapi/c/ppb_url_request_info.h index 5a8c1f2..0282313 100644 --- a/ppapi/c/ppb_url_request_info.h +++ b/ppapi/c/ppb_url_request_info.h @@ -35,7 +35,7 @@ typedef enum { } PP_URLRequestProperty; PP_COMPILE_ASSERT_SIZE_IN_BYTES(PP_URLRequestProperty, 4); -#define PPB_URLREQUESTINFO_INTERFACE "PPB_URLRequestInfo;1.1" +#define PPB_URLREQUESTINFO_INTERFACE "PPB_URLRequestInfo;0.1" struct PPB_URLRequestInfo { // Create a new URLRequestInfo object. Returns 0 if the module is invalid. diff --git a/ppapi/c/ppb_url_response_info.h b/ppapi/c/ppb_url_response_info.h index e9cec29..f64e598 100644 --- a/ppapi/c/ppb_url_response_info.h +++ b/ppapi/c/ppb_url_response_info.h @@ -20,7 +20,7 @@ typedef enum { } PP_URLResponseProperty; PP_COMPILE_ASSERT_SIZE_IN_BYTES(PP_URLResponseProperty, 4); -#define PPB_URLRESPONSEINFO_INTERFACE "PPB_URLResponseInfo;1.1" +#define PPB_URLRESPONSEINFO_INTERFACE "PPB_URLResponseInfo;0.1" struct PPB_URLResponseInfo { // Returns PP_TRUE if the given resource is an URLResponseInfo. Returns diff --git a/ppapi/c/ppb_var.h b/ppapi/c/ppb_var.h index a4a1f25..0041b73 100644 --- a/ppapi/c/ppb_var.h +++ b/ppapi/c/ppb_var.h @@ -13,7 +13,7 @@ #include "ppapi/c/pp_stdint.h" #include "ppapi/c/pp_var.h" -#define PPB_VAR_INTERFACE "PPB_Var;0.3" +#define PPB_VAR_INTERFACE "PPB_Var;0.4" /** * @file diff --git a/ppapi/c/trusted/ppb_image_data_trusted.h b/ppapi/c/trusted/ppb_image_data_trusted.h index bbc944d..9d2f3a7 100644 --- a/ppapi/c/trusted/ppb_image_data_trusted.h +++ b/ppapi/c/trusted/ppb_image_data_trusted.h @@ -8,7 +8,7 @@ #include "ppapi/c/pp_stdint.h" #include "ppapi/c/pp_resource.h" -#define PPB_IMAGEDATA_TRUSTED_INTERFACE "PPB_ImageDataTrusted;0.3" +#define PPB_IMAGEDATA_TRUSTED_INTERFACE "PPB_ImageDataTrusted;0.4" struct PPB_ImageDataTrusted { /** diff --git a/ppapi/c/trusted/ppb_url_loader_trusted.h b/ppapi/c/trusted/ppb_url_loader_trusted.h index 4e027f9..a9b15cf 100644 --- a/ppapi/c/trusted/ppb_url_loader_trusted.h +++ b/ppapi/c/trusted/ppb_url_loader_trusted.h @@ -9,7 +9,7 @@ #include "ppapi/c/pp_resource.h" #include "ppapi/c/pp_stdint.h" -#define PPB_URLLOADERTRUSTED_INTERFACE "PPB_URLLoaderTrusted;0.2" +#define PPB_URLLOADERTRUSTED_INTERFACE "PPB_URLLoaderTrusted;0.3" // Callback that indicates the status of the download and upload for the // given URLLoader resource. diff --git a/ppapi/tests/arch_dependent_sizes_32.h b/ppapi/tests/arch_dependent_sizes_32.h index 971279c..fb18237 100644 --- a/ppapi/tests/arch_dependent_sizes_32.h +++ b/ppapi/tests/arch_dependent_sizes_32.h @@ -25,7 +25,7 @@ PP_COMPILE_ASSERT_STRUCT_SIZE_IN_BYTES(PP_ClassProperty, 20); PP_COMPILE_ASSERT_STRUCT_SIZE_IN_BYTES(PP_CompletionCallback, 8); PP_COMPILE_ASSERT_STRUCT_SIZE_IN_BYTES(PP_FileChooserOptions_Dev, 8); PP_COMPILE_ASSERT_STRUCT_SIZE_IN_BYTES(PP_VideoDecoderConfig_Dev, 20); -PP_COMPILE_ASSERT_STRUCT_SIZE_IN_BYTES(PP_VideoFrameBuffer_Dev, 112); -PP_COMPILE_ASSERT_STRUCT_SIZE_IN_BYTES(PP_VideoUncompressedDataBuffer_Dev, 136); +PP_COMPILE_ASSERT_STRUCT_SIZE_IN_BYTES(PP_VideoFrameBuffer_Dev, 80); +PP_COMPILE_ASSERT_STRUCT_SIZE_IN_BYTES(PP_VideoUncompressedDataBuffer_Dev, 104); #endif /* PPAPI_TESTS_ARCH_DEPENDENT_SIZES_32_H_ */ diff --git a/ppapi/tests/arch_dependent_sizes_64.h b/ppapi/tests/arch_dependent_sizes_64.h index e70b420..3a63ab2 100644 --- a/ppapi/tests/arch_dependent_sizes_64.h +++ b/ppapi/tests/arch_dependent_sizes_64.h @@ -25,7 +25,7 @@ PP_COMPILE_ASSERT_STRUCT_SIZE_IN_BYTES(PP_ClassProperty, 40); PP_COMPILE_ASSERT_STRUCT_SIZE_IN_BYTES(PP_CompletionCallback, 16); PP_COMPILE_ASSERT_STRUCT_SIZE_IN_BYTES(PP_FileChooserOptions_Dev, 16); PP_COMPILE_ASSERT_STRUCT_SIZE_IN_BYTES(PP_VideoDecoderConfig_Dev, 40); -PP_COMPILE_ASSERT_STRUCT_SIZE_IN_BYTES(PP_VideoFrameBuffer_Dev, 120); -PP_COMPILE_ASSERT_STRUCT_SIZE_IN_BYTES(PP_VideoUncompressedDataBuffer_Dev, 152); +PP_COMPILE_ASSERT_STRUCT_SIZE_IN_BYTES(PP_VideoFrameBuffer_Dev, 88); +PP_COMPILE_ASSERT_STRUCT_SIZE_IN_BYTES(PP_VideoUncompressedDataBuffer_Dev, 120); #endif /* PPAPI_TESTS_ARCH_DEPENDENT_SIZES_64_H_ */ diff --git a/webkit/glue/plugins/pepper_var.cc b/webkit/glue/plugins/pepper_var.cc index 24fa2c3..c9c354c 100644 --- a/webkit/glue/plugins/pepper_var.cc +++ b/webkit/glue/plugins/pepper_var.cc @@ -714,7 +714,8 @@ void Var::PluginAddRefPPVar(PP_Var var) { if (var.type == PP_VARTYPE_STRING || var.type == PP_VARTYPE_OBJECT) { // TODO(brettw) consider checking that the ID is actually a var ID rather // than some random other resource ID. - if (!ResourceTracker::Get()->AddRefResource(var.value.as_id)) + PP_Resource resource = static_cast<PP_Resource>(var.value.as_id); + if (!ResourceTracker::Get()->AddRefResource(resource)) DLOG(WARNING) << "AddRefVar()ing a nonexistant string/object var."; } } @@ -724,7 +725,8 @@ void Var::PluginReleasePPVar(PP_Var var) { if (var.type == PP_VARTYPE_STRING || var.type == PP_VARTYPE_OBJECT) { // TODO(brettw) consider checking that the ID is actually a var ID rather // than some random other resource ID. - if (!ResourceTracker::Get()->UnrefResource(var.value.as_id)) + PP_Resource resource = static_cast<PP_Resource>(var.value.as_id); + if (!ResourceTracker::Get()->UnrefResource(resource)) DLOG(WARNING) << "ReleaseVar()ing a nonexistant string/object var."; } } @@ -776,7 +778,8 @@ PP_Var StringVar::StringToPPVar(PluginModule* module, scoped_refptr<StringVar> StringVar::FromPPVar(PP_Var var) { if (var.type != PP_VARTYPE_STRING) return scoped_refptr<StringVar>(NULL); - return Resource::GetAs<StringVar>(var.value.as_id); + PP_Resource resource = static_cast<PP_Resource>(var.value.as_id); + return Resource::GetAs<StringVar>(resource); } // ObjectVar ------------------------------------------------------------- @@ -817,7 +820,8 @@ PP_Var ObjectVar::NPObjectToPPVar(PluginModule* module, NPObject* object) { scoped_refptr<ObjectVar> ObjectVar::FromPPVar(PP_Var var) { if (var.type != PP_VARTYPE_OBJECT) return scoped_refptr<ObjectVar>(NULL); - return Resource::GetAs<ObjectVar>(var.value.as_id); + PP_Resource resource = static_cast<PP_Resource>(var.value.as_id); + return Resource::GetAs<ObjectVar>(resource); } // TryCatch -------------------------------------------------------------------- |