diff options
Diffstat (limited to 'webkit')
-rw-r--r-- | webkit/default_plugin/plugin_main.cc | 20 | ||||
-rw-r--r-- | webkit/default_plugin/plugin_main.h | 10 | ||||
-rw-r--r-- | webkit/tools/npapi_layout_test_plugin/PluginObject.cpp | 1 | ||||
-rw-r--r-- | webkit/tools/npapi_layout_test_plugin/TestObject.cpp | 1 | ||||
-rw-r--r-- | webkit/tools/npapi_layout_test_plugin/main.cpp | 5 |
5 files changed, 20 insertions, 17 deletions
diff --git a/webkit/default_plugin/plugin_main.cc b/webkit/default_plugin/plugin_main.cc index 4d0fd5b..16f0f6b 100644 --- a/webkit/default_plugin/plugin_main.cc +++ b/webkit/default_plugin/plugin_main.cc @@ -101,7 +101,7 @@ bool NegotiateModels(NPP instance) { #if defined(OS_MACOSX) NPError err; // Set drawing model to core graphics - NPBool supportsCoreGraphics = FALSE; + NPBool supportsCoreGraphics = false; err = g_browser->getvalue(instance, NPNVsupportsCoreGraphicsBool, &supportsCoreGraphics); @@ -118,7 +118,7 @@ bool NegotiateModels(NPP instance) { } // Set event model to cocoa - NPBool supportsCocoaEvents = FALSE; + NPBool supportsCocoaEvents = false; err = g_browser->getvalue(instance, NPNVsupportsCocoaBool, &supportsCocoaEvents); @@ -136,7 +136,7 @@ bool NegotiateModels(NPP instance) { #elif defined(OS_POSIX) NPError err; // Check that chrome still supports xembed. - NPBool supportsXEmbed = FALSE; + NPBool supportsXEmbed = false; err = g_browser->getvalue(instance, NPNVSupportsXEmbedBool, &supportsXEmbed); @@ -158,7 +158,7 @@ bool NegotiateModels(NPP instance) { return true; } -NPError NPP_New(NPMIMEType plugin_type, NPP instance, uint16 mode, int16 argc, +NPError NPP_New(NPMIMEType plugin_type, NPP instance, uint16_t mode, int16_t argc, char* argn[], char* argv[], NPSavedData* saved) { if (instance == NULL) return NPERR_INVALID_INSTANCE_ERROR; @@ -172,7 +172,7 @@ NPError NPP_New(NPMIMEType plugin_type, NPP instance, uint16 mode, int16 argc, if (!NegotiateModels(instance)) return NPERR_INCOMPATIBLE_VERSION_ERROR; - + PluginInstallerImpl* plugin_impl = new PluginInstallerImpl(mode); plugin_impl->Initialize( #if defined(OS_WIN) @@ -231,7 +231,7 @@ NPError NPP_SetWindow(NPP instance, NPWindow* window_info) { } NPError NPP_NewStream(NPP instance, NPMIMEType type, NPStream* stream, - NPBool seekable, uint16* stype) { + NPBool seekable, uint16_t* stype) { if (instance == NULL) return NPERR_INVALID_INSTANCE_ERROR; @@ -263,7 +263,7 @@ NPError NPP_DestroyStream(NPP instance, NPStream* stream, NPReason reason) { return NPERR_NO_ERROR; } -int32 NPP_WriteReady(NPP instance, NPStream* stream) { +int32_t NPP_WriteReady(NPP instance, NPStream* stream) { if (instance == NULL) return 0; @@ -280,7 +280,7 @@ int32 NPP_WriteReady(NPP instance, NPStream* stream) { return 0; } -int32 NPP_Write(NPP instance, NPStream* stream, int32 offset, int32 len, +int32_t NPP_Write(NPP instance, NPStream* stream, int32_t offset, int32_t len, void* buffer) { if (instance == NULL) return 0; @@ -315,7 +315,7 @@ void NPP_URLNotify(NPP instance, const char* url, NPReason reason, NPError NPP_GetValue(NPP instance, NPPVariable variable, void* value) { switch (variable) { case NPPVpluginNeedsXEmbed: - *static_cast<NPBool*>(value) = TRUE; + *static_cast<NPBool*>(value) = true; return NPERR_NO_ERROR; default: return NPERR_INVALID_PARAM; @@ -323,7 +323,7 @@ NPError NPP_GetValue(NPP instance, NPPVariable variable, void* value) { } #endif -int16 NPP_HandleEvent(NPP instance, void* event) { +int16_t NPP_HandleEvent(NPP instance, void* event) { if (instance == NULL) return 0; diff --git a/webkit/default_plugin/plugin_main.h b/webkit/default_plugin/plugin_main.h index dc1e071..50f3009 100644 --- a/webkit/default_plugin/plugin_main.h +++ b/webkit/default_plugin/plugin_main.h @@ -13,22 +13,22 @@ namespace default_plugin { extern NPNetscapeFuncs* g_browser; // Standard NPAPI functions. -NPError NPP_New(NPMIMEType pluginType, NPP instance, uint16 mode, int16 argc, +NPError NPP_New(NPMIMEType pluginType, NPP instance, uint16_t mode, int16_t argc, char* argn[], char* argv[], NPSavedData* saved); NPError NPP_Destroy(NPP instance, NPSavedData** save); NPError NPP_SetWindow(NPP instance, NPWindow* window); NPError NPP_NewStream(NPP instance, NPMIMEType type, NPStream* stream, - NPBool seekable, uint16* stype); + NPBool seekable, uint16_t* stype); NPError NPP_DestroyStream(NPP instance, NPStream* stream, NPReason reason); -int32 NPP_WriteReady(NPP instance, NPStream* stream); -int32 NPP_Write(NPP instance, NPStream* stream, int32 offset, int32 len, +int32_t NPP_WriteReady(NPP instance, NPStream* stream); +int32_t NPP_Write(NPP instance, NPStream* stream, int32_t offset, int32_t len, void* buffer); #if defined(OS_POSIX) && !defined(OS_MACOSX) NPError NPP_GetValue(NPP instance, NPPVariable variable, void* value); #endif void NPP_URLNotify(NPP instance, const char* url, NPReason reason, void* notifyData); -int16 NPP_HandleEvent(NPP instance, void* event); +int16_t NPP_HandleEvent(NPP instance, void* event); #if defined(OS_POSIX) && !defined(OS_MACOSX) NPError API_CALL NP_Initialize(NPNetscapeFuncs* funcs, NPPluginFuncs* p_funcs); diff --git a/webkit/tools/npapi_layout_test_plugin/PluginObject.cpp b/webkit/tools/npapi_layout_test_plugin/PluginObject.cpp index 390f9ec..43bc616 100644 --- a/webkit/tools/npapi_layout_test_plugin/PluginObject.cpp +++ b/webkit/tools/npapi_layout_test_plugin/PluginObject.cpp @@ -29,6 +29,7 @@ #include <assert.h> #include <stdlib.h> #include <stdio.h> +#include <string.h> #ifdef WIN32 #define snprintf sprintf_s #endif diff --git a/webkit/tools/npapi_layout_test_plugin/TestObject.cpp b/webkit/tools/npapi_layout_test_plugin/TestObject.cpp index 0f7bbd1..170335a 100644 --- a/webkit/tools/npapi_layout_test_plugin/TestObject.cpp +++ b/webkit/tools/npapi_layout_test_plugin/TestObject.cpp @@ -27,6 +27,7 @@ #include "PluginObject.h" #include <stdlib.h> +#include <string.h> static bool testEnumerate(NPObject*, NPIdentifier **value, uint32_t *count); static bool testHasMethod(NPObject*, NPIdentifier name); diff --git a/webkit/tools/npapi_layout_test_plugin/main.cpp b/webkit/tools/npapi_layout_test_plugin/main.cpp index 94abff7..c061adb 100644 --- a/webkit/tools/npapi_layout_test_plugin/main.cpp +++ b/webkit/tools/npapi_layout_test_plugin/main.cpp @@ -33,6 +33,7 @@ #include <stdlib.h> #include <stdio.h> +#include <string.h> #include <wtf/Platform.h> #include "PluginObject.h" @@ -111,7 +112,7 @@ EXPORT void NPAPI NP_Shutdown(void) static void executeScript(const PluginObject* obj, const char* script); -NPError NPP_New(NPMIMEType pluginType, NPP instance, uint16 mode, int16_t argc, char *argn[], char *argv[], NPSavedData *saved) +NPError NPP_New(NPMIMEType pluginType, NPP instance, uint16_t mode, int16_t argc, char *argn[], char *argv[], NPSavedData *saved) { if (browser->version >= 14) { PluginObject* obj = (PluginObject*)browser->createobject(instance, getPluginClass()); @@ -214,7 +215,7 @@ static void executeScript(const PluginObject* obj, const char* script) browser->releasevariantvalue(&browserResult); } -NPError NPP_NewStream(NPP instance, NPMIMEType type, NPStream *stream, NPBool seekable, uint16 *stype) +NPError NPP_NewStream(NPP instance, NPMIMEType type, NPStream *stream, NPBool seekable, uint16_t *stype) { PluginObject* obj = static_cast<PluginObject*>(instance->pdata); |