rpms/vlc/devel 0001-Mozilla-SDK-libxul-1.9.1-support.patch,1.4,1.5

NicolasChauvet kwizart at rpmfusion.org
Fri Feb 27 10:01:02 CET 2009


Author: kwizart

Update of /cvs/free/rpms/vlc/devel
In directory se02.es.rpmfusion.net:/tmp/cvs-serv18956

Modified Files:
	0001-Mozilla-SDK-libxul-1.9.1-support.patch 
Log Message:
rebuild for new font name


0001-Mozilla-SDK-libxul-1.9.1-support.patch:

Index: 0001-Mozilla-SDK-libxul-1.9.1-support.patch
===================================================================
RCS file: /cvs/free/rpms/vlc/devel/0001-Mozilla-SDK-libxul-1.9.1-support.patch,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- 0001-Mozilla-SDK-libxul-1.9.1-support.patch	16 Feb 2009 10:11:51 -0000	1.4
+++ 0001-Mozilla-SDK-libxul-1.9.1-support.patch	27 Feb 2009 09:01:02 -0000	1.5
@@ -1,8 +1,229 @@
+diff --git a/projects/mozilla/support/npmac.cpp b/projects/mozilla/support/npmac.cpp
+index ccc3945..43466c0 100644
+--- a/projects/mozilla/support/npmac.cpp
++++ b/projects/mozilla/support/npmac.cpp
+@@ -54,7 +54,11 @@
+ #undef XP_UNIX
+ #endif
+ 
++#if (((NP_VERSION_MAJOR << 8) + NP_VERSION_MINOR) < 20)
+ #include "npupp.h"
++#else
++#include "npfunctions.h"
++#endif
+ 
+ #ifdef __MWERKS__
+ #ifndef powerc
+@@ -130,7 +134,7 @@ static inline void* SetupFPtoTVGlue(TFPtoTVGlue* functionGlue, void* fp)
+ 
+ // glue for mapping netscape TVectors to Macho function pointers
+ struct TTVtoFPGlue {
+-    uint32 glue[6];
++    uint32_t glue[6];
+ };
+ 
+ static struct {
+@@ -252,7 +256,7 @@ NPError NPN_GetURL(NPP instance, const char* url, const char* window)
+     return CallNPN_GetURLProc(gNetscapeFuncs.geturl, instance, url, window);
+ }
+ 
+-NPError NPN_PostURLNotify(NPP instance, const char* url, const char* window, uint32 len, const char* buf, NPBool file, void* notifyData)
++NPError NPN_PostURLNotify(NPP instance, const char* url, const char* window, uint32_t len, const char* buf, NPBool file, void* notifyData)
+ {
+     int navMinorVers = gNetscapeFuncs.version & 0xFF;
+     NPError err;
+@@ -269,7 +273,7 @@ NPError NPN_PostURLNotify(NPP instance, const char* url, const char* window, uin
+     return err;
+ }
+ 
+-NPError NPN_PostURL(NPP instance, const char* url, const char* window, uint32 len, const char* buf, NPBool file)
++NPError NPN_PostURL(NPP instance, const char* url, const char* window, uint32_t len, const char* buf, NPBool file)
+ {
+     return CallNPN_PostURLProc(gNetscapeFuncs.posturl, instance, url, window, len, buf, file);
+ }
+@@ -295,7 +299,7 @@ NPError NPN_NewStream(NPP instance, NPMIMEType type, const char* window, NPStrea
+     return err;
+ }
+ 
+-int32 NPN_Write(NPP instance, NPStream* stream, int32 len, void* buffer)
++int32_t NPN_Write(NPP instance, NPStream* stream, int32_t len, void* buffer)
+ {
+     int navMinorVers = gNetscapeFuncs.version & 0xFF;
+     NPError err;
+@@ -337,7 +341,7 @@ const char* NPN_UserAgent(NPP instance)
+     return CallNPN_UserAgentProc(gNetscapeFuncs.uagent, instance);
+ }
+ 
+-void* NPN_MemAlloc(uint32 size)
++void* NPN_MemAlloc(uint32_t size)
+ {
+     return CallNPN_MemAllocProc(gNetscapeFuncs.memalloc, size);
+ }
+@@ -347,7 +351,7 @@ void NPN_MemFree(void* ptr)
+     CallNPN_MemFreeProc(gNetscapeFuncs.memfree, ptr);
+ }
+ 
+-uint32 NPN_MemFlush(uint32 size)
++uint32_t NPN_MemFlush(uint32_t size)
+ {
+     return CallNPN_MemFlushProc(gNetscapeFuncs.memflush, size);
+ }
+@@ -594,18 +598,18 @@ void NPN_SetException(NPObject *npobj, const NPUTF8 *message)
+ 
+ NPError     Private_Initialize(void);
+ void        Private_Shutdown(void);
+-NPError     Private_New(NPMIMEType pluginType, NPP instance, uint16 mode, int16 argc, char* argn[], char* argv[], NPSavedData* saved);
++NPError     Private_New(NPMIMEType pluginType, NPP instance, uint16_t mode, int16_t argc, char* argn[], char* argv[], NPSavedData* saved);
+ NPError     Private_Destroy(NPP instance, NPSavedData** save);
+ NPError     Private_SetWindow(NPP instance, NPWindow* window);
+ NPError     Private_GetValue( NPP instance, NPPVariable variable, void *value );
+ NPError     Private_SetValue( NPP instance, NPPVariable variable, void *value );
+ NPError     Private_NewStream(NPP instance, NPMIMEType type, NPStream* stream, NPBool seekable, uint16* stype);
+ NPError     Private_DestroyStream(NPP instance, NPStream* stream, NPError reason);
+-int32       Private_WriteReady(NPP instance, NPStream* stream);
+-int32       Private_Write(NPP instance, NPStream* stream, int32 offset, int32 len, void* buffer);
++int32_t     Private_WriteReady(NPP instance, NPStream* stream);
++int32_t     Private_Write(NPP instance, NPStream* stream, int32_t offset, int32_t len, void* buffer);
+ void        Private_StreamAsFile(NPP instance, NPStream* stream, const char* fname);
+ void        Private_Print(NPP instance, NPPrint* platformPrint);
+-int16       Private_HandleEvent(NPP instance, void* event);
++int16_t     Private_HandleEvent(NPP instance, void* event);
+ void        Private_URLNotify(NPP instance, const char* url, NPReason reason, void* notifyData);
+ jobject     Private_GetJavaClass(void);
+ 
+@@ -633,7 +637,7 @@ void Private_Shutdown(void)
+     ExitCodeResource();
+ }
+ 
+-NPError    Private_New(NPMIMEType pluginType, NPP instance, uint16 mode, int16 argc, char* argn[], char* argv[], NPSavedData* saved)
++NPError    Private_New(NPMIMEType pluginType, NPP instance, uint16_t mode, int16_t argc, char* argn[], char* argv[], NPSavedData* saved)
+ {
+     EnterCodeResource();
+     NPError ret = NPP_New(pluginType, instance, mode, argc, argn, argv, saved);
+@@ -692,9 +696,9 @@ NPError Private_NewStream(NPP instance, NPMIMEType type, NPStream* stream, NPBoo
+     return err;
+ }
+ 
+-int32 Private_WriteReady(NPP instance, NPStream* stream)
++int32_t Private_WriteReady(NPP instance, NPStream* stream)
+ {
+-    int32 result;
++    int32_t result;
+     EnterCodeResource();
+     PLUGINDEBUGSTR("\pWriteReady;g;");
+     result = NPP_WriteReady(instance, stream);
+@@ -702,9 +706,9 @@ int32 Private_WriteReady(NPP instance, NPStream* stream)
+     return result;
+ }
+ 
+-int32 Private_Write(NPP instance, NPStream* stream, int32 offset, int32 len, void* buffer)
++int32_t Private_Write(NPP instance, NPStream* stream, int32_t offset, int32_t len, void* buffer)
+ {
+-    int32 result;
++    int32_t result;
+     EnterCodeResource();
+     PLUGINDEBUGSTR("\pWrite;g;");
+     result = NPP_Write(instance, stream, offset, len, buffer);
+@@ -730,9 +734,9 @@ NPError Private_DestroyStream(NPP instance, NPStream* stream, NPError reason)
+     return err;
+ }
+ 
+-int16 Private_HandleEvent(NPP instance, void* event)
++int16_t Private_HandleEvent(NPP instance, void* event)
+ {
+-    int16 result;
++    int16_t result;
+     EnterCodeResource();
+     PLUGINDEBUGSTR("\pHandleEvent;g;");
+     result = NPP_HandleEvent(instance, event);
+@@ -993,6 +997,7 @@ DEFINE_API_C(NPError) main(NPNetscapeFuncs* nsTable, NPPluginFuncs* pluginFuncs,
+         //
+         pluginFuncs->version        = (NP_VERSION_MAJOR << 8) + NP_VERSION_MINOR;
+         pluginFuncs->size           = sizeof(NPPluginFuncs);
++#if (((NP_VERSION_MAJOR << 8) + NP_VERSION_MINOR) < 20)
+         pluginFuncs->newp           = NewNPP_NewProc(PLUGIN_TO_HOST_GLUE(newp, Private_New));
+         pluginFuncs->destroy        = NewNPP_DestroyProc(PLUGIN_TO_HOST_GLUE(destroy, Private_Destroy));
+         pluginFuncs->setwindow      = NewNPP_SetWindowProc(PLUGIN_TO_HOST_GLUE(setwindow, Private_SetWindow));
+@@ -1004,9 +1009,26 @@ DEFINE_API_C(NPError) main(NPNetscapeFuncs* nsTable, NPPluginFuncs* pluginFuncs,
+         pluginFuncs->print          = NewNPP_PrintProc(PLUGIN_TO_HOST_GLUE(print, Private_Print));
+         pluginFuncs->event          = NewNPP_HandleEventProc(PLUGIN_TO_HOST_GLUE(event, Private_HandleEvent));
+         pluginFuncs->getvalue       = NewNPP_GetValueProc(PLUGIN_TO_HOST_GLUE(getvalue, Private_GetValue));
++#else
++        pluginFuncs->newp           = (NPP_NewProcPtr)(PLUGIN_TO_HOST_GLUE(newp, Private_New));
++        pluginFuncs->destroy        = (NPP_DestroyProcPtr)(PLUGIN_TO_HOST_GLUE(destroy, Private_Destroy));
++        pluginFuncs->setwindow      = (NPP_SetWindowProcPtr)(PLUGIN_TO_HOST_GLUE(setwindow, Private_SetWindow));
++        pluginFuncs->newstream      = (NPP_NewStreamProcPtr)(PLUGIN_TO_HOST_GLUE(newstream, Private_NewStream));
++        pluginFuncs->destroystream  = (NPP_DestroyStreamProcPtr)(PLUGIN_TO_HOST_GLUE(destroystream, Private_DestroyStream));
++        pluginFuncs->asfile         = (NPP_StreamAsFileProcPtr)(PLUGIN_TO_HOST_GLUE(asfile, Private_StreamAsFile));
++        pluginFuncs->writeready     = (NPP_WriteReadyProcPtr)(PLUGIN_TO_HOST_GLUE(writeready, Private_WriteReady));
++        pluginFuncs->write          = (NPP_WriteProcPtr)(PLUGIN_TO_HOST_GLUE(write, Private_Write));
++        pluginFuncs->print          = (NPP_PrintProcPtr)(PLUGIN_TO_HOST_GLUE(print, Private_Print));
++        pluginFuncs->event          = (NPP_HandleEventProcPtr)(PLUGIN_TO_HOST_GLUE(event, Private_HandleEvent));
++        pluginFuncs->getvalue       = (NPP_GetValueProcPtr)(PLUGIN_TO_HOST_GLUE(getvalue, Private_GetValue));
++#endif
+         if( navMinorVers >= NPVERS_HAS_NOTIFICATION )
+         {
++#if (((NP_VERSION_MAJOR << 8) + NP_VERSION_MINOR) < 20)
+             pluginFuncs->urlnotify = NewNPP_URLNotifyProc(PLUGIN_TO_HOST_GLUE(urlnotify, Private_URLNotify));
++#else
++            pluginFuncs->urlnotify = (NPP_URLNotifyProcPtr)(PLUGIN_TO_HOST_GLUE(urlnotify, Private_URLNotify));
++#endif
+         }
+ #ifdef OJI
+         if( navMinorVers >= NPVERS_HAS_LIVECONNECT )
+@@ -1016,7 +1038,11 @@ DEFINE_API_C(NPError) main(NPNetscapeFuncs* nsTable, NPPluginFuncs* pluginFuncs,
+ #else
+         pluginFuncs->javaClass = NULL;
+ #endif
++#if (((NP_VERSION_MAJOR << 8) + NP_VERSION_MINOR) < 20)
+         *unloadUpp = NewNPP_ShutdownProc(PLUGIN_TO_HOST_GLUE(shutdown, Private_Shutdown));
++#else
++        *unloadUpp = (NPP_ShutdownProcPtr)(PLUGIN_TO_HOST_GLUE(shutdown, Private_Shutdown));
++#endif
+ 
+         SetUpQD();
+         err = Private_Initialize();
+@@ -1152,6 +1178,7 @@ NPError NP_GetEntryPoints(NPPluginFuncs* pluginFuncs)
+ 
+     pluginFuncs->version    = (NP_VERSION_MAJOR << 8) + NP_VERSION_MINOR;
+     pluginFuncs->size       = sizeof(NPPluginFuncs);
++#if (((NP_VERSION_MAJOR << 8) + NP_VERSION_MINOR) < 20)
+     pluginFuncs->newp       = NewNPP_NewProc(Private_New);
+     pluginFuncs->destroy    = NewNPP_DestroyProc(Private_Destroy);
+     pluginFuncs->setwindow  = NewNPP_SetWindowProc(Private_SetWindow);
+@@ -1164,6 +1191,27 @@ NPError NP_GetEntryPoints(NPPluginFuncs* pluginFuncs)
+     pluginFuncs->event      = NewNPP_HandleEventProc(Private_HandleEvent);
+     pluginFuncs->getvalue   = NewNPP_GetValueProc(Private_GetValue);
+     pluginFuncs->setvalue   = NewNPP_SetValueProc(Private_SetValue);
++#else
++    pluginFuncs->newp       = (NPP_NewProcPtr)(Private_New);
++    pluginFuncs->destroy    = (NPP_DestroyProcPtr)(Private_Destroy);
++    pluginFuncs->setwindow  = (NPP_SetWindowProcPtr)(Private_SetWindow);
++    pluginFuncs->newstream  = (NPP_NewStreamProcPtr)(Private_NewStream);
++    pluginFuncs->destroystream = (NPP_DestroyStreamProcPtr)(Private_DestroyStream);
++    pluginFuncs->asfile     = (NPP_StreamAsFileProcPtr)(Private_StreamAsFile);
++    pluginFuncs->writeready = (NPP_WriteReadyProcPtr)(Private_WriteReady);
++    pluginFuncs->write      = (NPP_WriteProcPtr)(Private_Write);
++    pluginFuncs->print      = (NPP_PrintProcPtr)(Private_Print);
++    pluginFuncs->event      = (NPP_HandleEventProcPtr)(Private_HandleEvent);
++    pluginFuncs->getvalue   = (NPP_GetValueProcPtr)(Private_GetValue);
++    pluginFuncs->setvalue   = (NPP_SetValueProcPtr)(Private_SetValue);
++#endif
++    if( navMinorVers >= NPVERS_HAS_NOTIFICATION )
++    {
++#if (((NP_VERSION_MAJOR << 8) + NP_VERSION_MINOR) < 20)
++        pluginFuncs->urlnotify = NewNPP_URLNotifyProc(PLUGIN_TO_HOST_GLUE(urlnotify, Private_URLNotify));
++#else
++        pluginFuncs->urlnotify = (NPP_URLNotifyProcPtr)(PLUGIN_TO_HOST_GLUE(urlnotify, Private_URLNotify));
++#endif
+     if( navMinorVers >= NPVERS_HAS_NOTIFICATION )
+     {
+         pluginFuncs->urlnotify = Private_URLNotify;
 diff --git a/projects/mozilla/support/npunix.c b/projects/mozilla/support/npunix.c
-index 26c6736..b27b20d 100644
+index 26c6736..450d627 100644
 --- a/projects/mozilla/support/npunix.c
 +++ b/projects/mozilla/support/npunix.c
-@@ -43,7 +43,11 @@
+@@ -43,7 +43,132 @@
  
  #include <stdio.h>
  #include <npapi.h>
@@ -10,11 +231,196 @@
  #include <npupp.h>
 +#else
 +#include <npfunctions.h>
++// For 1.9 compatibility
++// ------------------------------------------------
++typedef NPError (*NPN_GetValueUPP)(NPP instance, NPNVariable variable, void *ret_alue);
++#define NewNPN_GetValueProc(FUNC)   \
++    ((NPN_GetValueUPP) (FUNC))
++#define CallNPN_GetValueProc(FUNC, ARG1, ARG2, ARG3)    \
++    (*(FUNC))((ARG1), (ARG2), (ARG3))
++
++typedef NPError (*NPN_SetValueUPP)(NPP instance, NPPVariable variable, void *ret_alue);
++#define NewNPN_SetValueProc(FUNC)   \
++    ((NPN_SetValueUPP) (FUNC))
++#define CallNPN_SetValueProc(FUNC, ARG1, ARG2, ARG3)    \
++    (*(FUNC))((ARG1), (ARG2), (ARG3))
++
++typedef NPError (*NPN_GetURLUPP)(NPP instance, const char* url, const char* window);
++#define NewNPN_GetURLProc(FUNC)   \
++    ((NPN_GetURLUPP) (FUNC))
++#define CallNPN_GetURLProc(FUNC, ARG1, ARG2, ARG3)    \
++    (*(FUNC))((ARG1), (ARG2), (ARG3))
++
++typedef NPError (*NPN_GetURLNotifyUPP)(NPP instance, const char* url, const char* window, void* notifyData);
++#define NewNPN_GetURLNotifyProc(FUNC)   \
++    ((NPN_GetURLNotifyUPP) (FUNC))
++#define CallNPN_GetURLNotifyProc(FUNC, ARG1, ARG2, ARG3, ARG4)    \
++    (*(FUNC))((ARG1), (ARG2), (ARG3), (ARG4))
++
++typedef NPError (*NPN_PostURLUPP)(NPP instance, const char* url, const char* window, uint32_t len, const char* buf, NPBool file);
++#define NewNPN_PostURLProc(FUNC)    \
++    ((NPN_PostURLUPP) (FUNC))
++#define CallNPN_PostURLProc(FUNC, ARG1, ARG2, ARG3, ARG4, ARG5, ARG6) \
++    (*(FUNC))((ARG1), (ARG2), (ARG3), (ARG4), (ARG5), (ARG6))
++
++typedef NPError (*NPN_PostURLNotifyUPP)(NPP instance, const char* url, const char* window, uint32_t len, const char* buf, NPBool file, void* notifyData);
++#define NewNPN_PostURLNotifyProc(FUNC)    \
++    ((NPN_PostURLNotifyUPP) (FUNC))
++#define CallNPN_PostURLNotifyProc(FUNC, ARG1, ARG2, ARG3, ARG4, ARG5, ARG6, ARG7) \
++    (*(FUNC))((ARG1), (ARG2), (ARG3), (ARG4), (ARG5), (ARG6), (ARG7))
++
++typedef NPError (*NPN_RequestReadUPP)(NPStream* stream, NPByteRange* rangeList);
++#define NewNPN_RequestReadProc(FUNC)    \
++    ((NPN_RequestReadUPP) (FUNC))
++#define CallNPN_RequestReadProc(FUNC, stream, range)    \
++    (*(FUNC))((stream), (range))
++
++typedef NPError (*NPN_NewStreamUPP)(NPP instance, NPMIMEType type, const char* window, NPStream** stream);
++#define NewNPN_NewStreamProc(FUNC)    \
++    ((NPN_NewStreamUPP) (FUNC))
++#define CallNPN_NewStreamProc(FUNC, npp, type, window, stream)    \
++    (*(FUNC))((npp), (type), (window), (stream))
++
++typedef int32_t (*NPN_WriteUPP)(NPP instance, NPStream* stream, int32_t len, void* buffer);
++#define NewNPN_WriteProc(FUNC)    \
++    ((NPN_WriteUPP) (FUNC))
++#define CallNPN_WriteProc(FUNC, npp, stream, len, buffer)   \
++    (*(FUNC))((npp), (stream), (len), (buffer))
++
++typedef NPError (*NPN_DestroyStreamUPP)(NPP instance, NPStream* stream, NPReason reason);
++#define NewNPN_DestroyStreamProc(FUNC)    \
++    ((NPN_DestroyStreamUPP) (FUNC))
++#define CallNPN_DestroyStreamProc(FUNC, npp, stream, reason)    \
++    (*(FUNC))((npp), (stream), (reason))
++
++typedef void (*NPN_StatusUPP)(NPP instance, const char* message);
++#define NewNPN_StatusProc(FUNC)   \
++    ((NPN_StatusUPP) (FUNC))
++#define CallNPN_StatusProc(FUNC, npp, msg)    \
++    (*(FUNC))((npp), (msg)) 
++
++typedef const char* (*NPN_UserAgentUPP)(NPP instance);
++#define NewNPN_UserAgentProc(FUNC)              \
++                ((NPN_UserAgentUPP) (FUNC))
++#define CallNPN_UserAgentProc(FUNC, ARG1)               \
++                (*(FUNC))((ARG1))
++
++typedef void* (*NPN_MemAllocUPP)(uint32_t size);
++#define NewNPN_MemAllocProc(FUNC)   \
++    ((NPN_MemAllocUPP) (FUNC))
++#define CallNPN_MemAllocProc(FUNC, ARG1)    \
++    (*(FUNC))((ARG1)) 
++
++typedef void (*NPN_MemFreeUPP)(void* ptr);
++#define NewNPN_MemFreeProc(FUNC)    \
++    ((NPN_MemFreeUPP) (FUNC))
++#define CallNPN_MemFreeProc(FUNC, ARG1)   \
++    (*(FUNC))((ARG1)) 
++
++typedef uint32_t (*NPN_MemFlushUPP)(uint32_t size);
++#define NewNPN_MemFlushProc(FUNC)   \
++    ((NPN_MemFlushUPP) (FUNC))
++#define CallNPN_MemFlushProc(FUNC, ARG1)    \
++    (*(FUNC))((ARG1)) 
++
++typedef void (*NPN_ReloadPluginsUPP)(NPBool reloadPages);
++#define NewNPN_ReloadPluginsProc(FUNC)    \
++    ((NPN_ReloadPluginsUPP) (FUNC))
++#define CallNPN_ReloadPluginsProc(FUNC, ARG1)   \
++    (*(FUNC))((ARG1)) 
++
++//NPN_GetJavaEnv NPN_GetJavaPeer
++
++typedef void (*NPN_InvalidateRectUPP)(NPP instance, NPRect *rect);
++#define NewNPN_InvalidateRectProc(FUNC)   \
++    ((NPN_InvalidateRectUPP) (FUNC))
++#define CallNPN_InvalidateRectProc(FUNC, ARG1, ARG2)    \
++    (*(FUNC))((ARG1), (ARG2)) 
++
++typedef void (*NPN_InvalidateRegionUPP)(NPP instance, NPRegion region);
++#define NewNPN_InvalidateRegionProc(FUNC)   \
++    ((NPN_InvalidateRegionUPP) (FUNC))
++#define CallNPN_InvalidateRegionProc(FUNC, ARG1, ARG2)    \
++    (*(FUNC))((ARG1), (ARG2)) 
++
++typedef void (*NPN_ForceRedrawUPP)(NPP instance);
++#define NewNPN_ForceRedrawProc(FUNC)    \
++    ((NPN_ForceRedrawUPP) (FUNC))
++#define CallNPN_ForceRedrawProc(FUNC, ARG1)   \
++    (*(FUNC))((ARG1)) 
++
++//NPN_GetStringIdentifier NPN_GetStringIdentifiers NPN_GetIntIdentifier NPN_IdentifierIsString
++//NPN_UTF8FromIdentifier NPN_IntFromIdentifier NPN_CreateObject
++
 +#endif
  
  /*
   * Define PLUGIN_TRACE to have the wrapper functions print
-@@ -685,6 +689,7 @@ NP_Initialize(NPNetscapeFuncs* nsTable, NPPluginFuncs* pluginFuncs)
+@@ -117,14 +242,14 @@ NPN_GetURLNotify(NPP instance, const char* url, const char* window, void* notify
+ 
+ NPError
+ NPN_PostURL(NPP instance, const char* url, const char* window,
+-         uint32 len, const char* buf, NPBool file)
++         uint32_t len, const char* buf, NPBool file)
+ {
+     return CallNPN_PostURLProc(gNetscapeFuncs.posturl, instance,
+                     url, window, len, buf, file);
+ }
+ 
+ NPError
+-NPN_PostURLNotify(NPP instance, const char* url, const char* window, uint32 len,
++NPN_PostURLNotify(NPP instance, const char* url, const char* window, uint32_t len,
+                   const char* buf, NPBool file, void* notifyData)
+ {
+     return CallNPN_PostURLNotifyProc(gNetscapeFuncs.posturlnotify,
+@@ -147,7 +272,7 @@ NPN_NewStream(NPP instance, NPMIMEType type, const char *window,
+ }
+ 
+ int32
+-NPN_Write(NPP instance, NPStream* stream, int32 len, void* buffer)
++NPN_Write(NPP instance, NPStream* stream, int32_t len, void* buffer)
+ {
+     return CallNPN_WriteProc(gNetscapeFuncs.write, instance,
+                     stream, len, buffer);
+@@ -173,7 +298,7 @@ NPN_UserAgent(NPP instance)
+ }
+ 
+ void*
+-NPN_MemAlloc(uint32 size)
++NPN_MemAlloc(uint32_t size)
+ {
+     return CallNPN_MemAllocProc(gNetscapeFuncs.memalloc, size);
+ }
+@@ -183,7 +308,7 @@ void NPN_MemFree(void* ptr)
+     CallNPN_MemFreeProc(gNetscapeFuncs.memfree, ptr);
+ }
+ 
+-uint32 NPN_MemFlush(uint32 size)
++uint32_t NPN_MemFlush(uint32_t size)
+ {
+     return CallNPN_MemFlushProc(gNetscapeFuncs.memflush, size);
+ }
+@@ -423,8 +548,8 @@ void NPN_SetException(NPObject *npobj, const NPUTF8 *message)
+  ***********************************************************************/
+ 
+ NPError
+-Private_New(NPMIMEType pluginType, NPP instance, uint16 mode,
+-        int16 argc, char* argn[], char* argv[], NPSavedData* saved)
++Private_New(NPMIMEType pluginType, NPP instance, uint16_t mode,
++        int16_t argc, char* argn[], char* argv[], NPSavedData* saved)
+ {
+     NPError ret;
+     PLUGINDEBUGSTR("New");
+@@ -468,7 +593,7 @@ Private_WriteReady(NPP instance, NPStream* stream)
+ }
+ 
+ int32
+-Private_Write(NPP instance, NPStream* stream, int32 offset, int32 len,
++Private_Write(NPP instance, NPStream* stream, int32_t offset, int32_t len,
+         void* buffer)
+ {
+     unsigned int result;
+@@ -685,6 +810,7 @@ NP_Initialize(NPNetscapeFuncs* nsTable, NPPluginFuncs* pluginFuncs)
           */
          pluginFuncs->version    = (NP_VERSION_MAJOR << 8) + NP_VERSION_MINOR;
          pluginFuncs->size       = sizeof(NPPluginFuncs);
@@ -22,7 +428,7 @@
          pluginFuncs->newp       = NewNPP_NewProc(Private_New);
          pluginFuncs->destroy    = NewNPP_DestroyProc(Private_Destroy);
          pluginFuncs->setwindow  = NewNPP_SetWindowProc(Private_SetWindow);
-@@ -697,9 +702,27 @@ NP_Initialize(NPNetscapeFuncs* nsTable, NPPluginFuncs* pluginFuncs)
+@@ -697,9 +823,27 @@ NP_Initialize(NPNetscapeFuncs* nsTable, NPPluginFuncs* pluginFuncs)
          pluginFuncs->event      = NULL;
          pluginFuncs->getvalue   = NewNPP_GetValueProc(Private_GetValue);
          pluginFuncs->setvalue   = NewNPP_SetValueProc(Private_SetValue);
@@ -50,3 +456,61 @@
          }
  #ifdef OJI
          if( navMinorVers >= NPVERS_HAS_LIVECONNECT )
+diff --git a/projects/mozilla/support/npwin.cpp b/projects/mozilla/support/npwin.cpp
+index c277f84..2d08805 100644
+--- a/projects/mozilla/support/npwin.cpp
++++ b/projects/mozilla/support/npwin.cpp
+@@ -42,7 +42,11 @@
+ #endif
+ 
+ #include "npapi.h"
++#if (((NP_VERSION_MAJOR << 8) + NP_VERSION_MINOR) < 20)
+ #include "npupp.h"
++#else
++#include "npfunctions.h"
++#endif
+ 
+ //\\// DEFINE
+ #define NP_EXPORT
+@@ -228,7 +232,7 @@ NPError NPN_GetURL(NPP instance, const char *url, const char *target)
+     return g_pNavigatorFuncs->geturl(instance, url, target);
+ }
+ 
+-NPError NPN_PostURLNotify(NPP instance, const char* url, const char* window, uint32 len, const char* buf, NPBool file, void* notifyData)
++NPError NPN_PostURLNotify(NPP instance, const char* url, const char* window, uint32_t len, const char* buf, NPBool file, void* notifyData)
+ {
+     int navMinorVers = g_pNavigatorFuncs->version & 0xFF;
+     NPError err;
+@@ -242,7 +246,7 @@ NPError NPN_PostURLNotify(NPP instance, const char* url, const char* window, uin
+ }
+ 
+ 
+-NPError NPN_PostURL(NPP instance, const char* url, const char* window, uint32 len, const char* buf, NPBool file)
++NPError NPN_PostURL(NPP instance, const char* url, const char* window, uint32_t len, const char* buf, NPBool file)
+ {
+     return g_pNavigatorFuncs->posturl(instance, url, window, len, buf, file);
+ }
+@@ -276,11 +280,11 @@ NPError NPN_NewStream(NPP instance, NPMIMEType type,
+ 
+ /* Provides len bytes of data.
+ */
+-int32 NPN_Write(NPP instance, NPStream *stream,
+-                int32 len, void *buffer)
++int32_t NPN_Write(NPP instance, NPStream *stream,
++                int32_t len, void *buffer)
+ {
+     int navMinorVersion = g_pNavigatorFuncs->version & 0xFF;
+-    int32 result;
++    int32_t result;
+ 
+     if( navMinorVersion >= NPVERS_HAS_STREAMOUTPUT ) {
+         result = g_pNavigatorFuncs->write(instance, stream, len, buffer);
+@@ -327,7 +331,7 @@ const char* NPN_UserAgent(NPP instance)
+ */
+ 
+ 
+-void* NPN_MemAlloc(uint32 size)
++void* NPN_MemAlloc(uint32_t size)
+ {
+     return g_pNavigatorFuncs->memalloc(size);
+ }



More information about the rpmfusion-commits mailing list