Clean to prepare -rc4

el8
Nicolas Chauvet 16 years ago
parent dfc669d1cf
commit d11f1acbeb

@ -1,27 +0,0 @@
From 4717657053a13d69d48dc82dbc5402f6712f66ea Mon Sep 17 00:00:00 2001
From: Erwan Tulou <brezhoneg1@yahoo.fr>
Date: Fri, 5 Jun 2009 09:55:09 +0200
Subject: [PATCH] QT4 menus : remove previous signal-slot connection(s) if any (correct trac #2818)
---
modules/gui/qt4/menus.cpp | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/modules/gui/qt4/menus.cpp b/modules/gui/qt4/menus.cpp
index 0a12c20..9304752 100644
--- a/modules/gui/qt4/menus.cpp
+++ b/modules/gui/qt4/menus.cpp
@@ -1386,6 +1386,10 @@ void QVLCMenu::CreateAndConnect( QMenu *menu, const char *psz_var,
MenuItemData *itemData = new MenuItemData( THEDP->menusMapper, p_obj, i_val_type,
val, psz_var );
+
+ /* remove previous signal-slot connection(s) if any */
+ action->disconnect( );
+
CONNECT( action, triggered(), THEDP->menusMapper, map() );
THEDP->menusMapper->setMapping( action, itemData );
--
1.5.6.5

@ -1,25 +0,0 @@
From dce1b815f87daef89715c9e5bec7ee78a69df79f Mon Sep 17 00:00:00 2001
From: Nicolas Chauvet (kwizart) <kwizart@gmail.com>
Date: Thu, 4 Jun 2009 15:18:40 +0200
Subject: [PATCH] Improve compatibility with PA when the vlc alsa output is used.
---
modules/audio_output/alsa.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/modules/audio_output/alsa.c b/modules/audio_output/alsa.c
index 2d03d1d..dd33f31 100644
--- a/modules/audio_output/alsa.c
+++ b/modules/audio_output/alsa.c
@@ -78,7 +78,7 @@ struct aout_sys_t
number of channel(s) (eg. 2 for stereo) and the size of a sample (eg.
2 for int16_t). */
#define ALSA_DEFAULT_PERIOD_SIZE 1024
-#define ALSA_DEFAULT_BUFFER_SIZE ( ALSA_DEFAULT_PERIOD_SIZE << 8 )
+#define ALSA_DEFAULT_BUFFER_SIZE ( ALSA_DEFAULT_PERIOD_SIZE << 4 )
#define ALSA_SPDIF_PERIOD_SIZE A52_FRAME_NB
#define ALSA_SPDIF_BUFFER_SIZE ( ALSA_SPDIF_PERIOD_SIZE << 4 )
/* Why << 4 ? --Meuuh */
--
1.6.0.6

@ -1,494 +0,0 @@
From: Pavlov Konstantin <thresh@altlinux.ru>
Date: Wed, 25 Mar 2009 14:28:20 +0000 (+0000)
Subject: Fix mozilla plugin with xulrunner-1.9.1. Patch from Alexey Gladkov
X-Git-Tag: 1.0.0-alt0.pre1^0
X-Git-Url: http://git.altlinux.org/people/thresh/packages/vlc.git?p=vlc.git;a=commitdiff_plain;h=1e8df789f39d5d4c09bf48935ace087e5e5867bd;hp=94de3abc393d1c684fb9129210ecfbc5462b293e
Fix mozilla plugin with xulrunner-1.9.1. Patch from Alexey Gladkov
(legion at altlinux ru)
---
diff --git a/projects/mozilla/support/npmac.cpp b/projects/mozilla/support/npmac.cpp
index e9ffdc5..a6ca2e4 100644
--- a/projects/mozilla/support/npmac.cpp
+++ b/projects/mozilla/support/npmac.cpp
@@ -1017,20 +1017,20 @@ DEFINE_API_C(NPError) main(NPNetscapeFuncs* nsTable, NPPluginFuncs* pluginFuncs,
//
pluginFuncs->version = (NP_VERSION_MAJOR << 8) + NP_VERSION_MINOR;
pluginFuncs->size = sizeof(NPPluginFuncs);
- 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));
- pluginFuncs->newstream = NewNPP_NewStreamProc(PLUGIN_TO_HOST_GLUE(newstream, Private_NewStream));
- pluginFuncs->destroystream = NewNPP_DestroyStreamProc(PLUGIN_TO_HOST_GLUE(destroystream, Private_DestroyStream));
- pluginFuncs->asfile = NewNPP_StreamAsFileProc(PLUGIN_TO_HOST_GLUE(asfile, Private_StreamAsFile));
- pluginFuncs->writeready = NewNPP_WriteReadyProc(PLUGIN_TO_HOST_GLUE(writeready, Private_WriteReady));
- pluginFuncs->write = NewNPP_WriteProc(PLUGIN_TO_HOST_GLUE(write, Private_Write));
- 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));
+ 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));
if( navMinorVers >= NPVERS_HAS_NOTIFICATION )
{
- pluginFuncs->urlnotify = NewNPP_URLNotifyProc(PLUGIN_TO_HOST_GLUE(urlnotify, Private_URLNotify));
+ pluginFuncs->urlnotify = (NPP_URLNotifyProcPtr)(PLUGIN_TO_HOST_GLUE(urlnotify, Private_URLNotify));
}
#ifdef OJI
if( navMinorVers >= NPVERS_HAS_LIVECONNECT )
@@ -1040,7 +1040,7 @@ DEFINE_API_C(NPError) main(NPNetscapeFuncs* nsTable, NPPluginFuncs* pluginFuncs,
#else
pluginFuncs->javaClass = NULL;
#endif
- *unloadUpp = NewNPP_ShutdownProc(PLUGIN_TO_HOST_GLUE(shutdown, Private_Shutdown));
+ *unloadUpp = (NPP_ShutdownProcPtr)(PLUGIN_TO_HOST_GLUE(shutdown, Private_Shutdown));
SetUpQD();
err = Private_Initialize();
@@ -1176,18 +1176,18 @@ NPError NP_GetEntryPoints(NPPluginFuncs* pluginFuncs)
pluginFuncs->version = (NP_VERSION_MAJOR << 8) + NP_VERSION_MINOR;
pluginFuncs->size = sizeof(NPPluginFuncs);
- pluginFuncs->newp = NewNPP_NewProc(Private_New);
- pluginFuncs->destroy = NewNPP_DestroyProc(Private_Destroy);
- pluginFuncs->setwindow = NewNPP_SetWindowProc(Private_SetWindow);
- pluginFuncs->newstream = NewNPP_NewStreamProc(Private_NewStream);
- pluginFuncs->destroystream = NewNPP_DestroyStreamProc(Private_DestroyStream);
- pluginFuncs->asfile = NewNPP_StreamAsFileProc(Private_StreamAsFile);
- pluginFuncs->writeready = NewNPP_WriteReadyProc(Private_WriteReady);
- pluginFuncs->write = NewNPP_WriteProc(Private_Write);
- pluginFuncs->print = NewNPP_PrintProc(Private_Print);
- pluginFuncs->event = NewNPP_HandleEventProc(Private_HandleEvent);
- pluginFuncs->getvalue = NewNPP_GetValueProc(Private_GetValue);
- pluginFuncs->setvalue = NewNPP_SetValueProc(Private_SetValue);
+ 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);
if( navMinorVers >= NPVERS_HAS_NOTIFICATION )
{
pluginFuncs->urlnotify = Private_URLNotify;
diff --git a/projects/mozilla/support/npunix.c b/projects/mozilla/support/npunix.c
index 0f6efc0..9ad454c 100644
--- a/projects/mozilla/support/npunix.c
+++ b/projects/mozilla/support/npunix.c
@@ -103,149 +103,136 @@ NPN_Version(int* plugin_major, int* plugin_minor,
NPError
NPN_GetValue(NPP instance, NPNVariable variable, void *r_value)
{
- return CallNPN_GetValueProc(gNetscapeFuncs.getvalue,
- instance, variable, r_value);
+ return (*gNetscapeFuncs.getvalue)(instance, variable, r_value);
}
NPError
NPN_SetValue(NPP instance, NPPVariable variable, void *value)
{
- return CallNPN_SetValueProc(gNetscapeFuncs.setvalue,
- instance, variable, value);
+ return (*gNetscapeFuncs.setvalue)(instance, variable, value);
}
NPError
NPN_GetURL(NPP instance, const char* url, const char* window)
{
- return CallNPN_GetURLProc(gNetscapeFuncs.geturl, instance, url, window);
+ return (*gNetscapeFuncs.geturl)(instance, url, window);
}
NPError
NPN_GetURLNotify(NPP instance, const char* url, const char* window, void* notifyData)
{
- return CallNPN_GetURLNotifyProc(gNetscapeFuncs.geturlnotify, instance, url, window, notifyData);
+ return (*gNetscapeFuncs.geturlnotify)(instance, url, window, notifyData);
}
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);
+ return (*gNetscapeFuncs.posturl)(instance, url, window, len, buf, file);
}
NPError
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,
- instance, url, window, len, buf, file, notifyData);
+ return (*gNetscapeFuncs.posturlnotify)(instance, url, window, len, buf, file, notifyData);
}
NPError
NPN_RequestRead(NPStream* stream, NPByteRange* rangeList)
{
- return CallNPN_RequestReadProc(gNetscapeFuncs.requestread,
- stream, rangeList);
+ return (*gNetscapeFuncs.requestread)(stream, rangeList);
}
NPError
NPN_NewStream(NPP instance, NPMIMEType type, const char *window,
NPStream** stream_ptr)
{
- return CallNPN_NewStreamProc(gNetscapeFuncs.newstream, instance,
- type, window, stream_ptr);
+ return (*gNetscapeFuncs.newstream)(instance, type, window, stream_ptr);
}
int32_t
NPN_Write(NPP instance, NPStream* stream, int32_t len, void* buffer)
{
- return CallNPN_WriteProc(gNetscapeFuncs.write, instance,
- stream, len, buffer);
+ return (*gNetscapeFuncs.write)(instance, stream, len, buffer);
}
NPError
NPN_DestroyStream(NPP instance, NPStream* stream, NPError reason)
{
- return CallNPN_DestroyStreamProc(gNetscapeFuncs.destroystream,
- instance, stream, reason);
+ return (*gNetscapeFuncs.destroystream)(instance, stream, reason);
}
void
NPN_Status(NPP instance, const char* message)
{
- CallNPN_StatusProc(gNetscapeFuncs.status, instance, message);
+ (*gNetscapeFuncs.status)(instance, message);
}
const char*
NPN_UserAgent(NPP instance)
{
- return CallNPN_UserAgentProc(gNetscapeFuncs.uagent, instance);
+ return (*gNetscapeFuncs.uagent)(instance);
}
void *NPN_MemAlloc(uint32_t size)
{
- return CallNPN_MemAllocProc(gNetscapeFuncs.memalloc, size);
+ return (*gNetscapeFuncs.memalloc)(size);
}
void NPN_MemFree(void* ptr)
{
- CallNPN_MemFreeProc(gNetscapeFuncs.memfree, ptr);
+ (*gNetscapeFuncs.memfree)(ptr);
}
uint32_t NPN_MemFlush(uint32_t size)
{
- return CallNPN_MemFlushProc(gNetscapeFuncs.memflush, size);
+ return (*gNetscapeFuncs.memflush)(size);
}
void NPN_ReloadPlugins(NPBool reloadPages)
{
- CallNPN_ReloadPluginsProc(gNetscapeFuncs.reloadplugins, reloadPages);
+ (*gNetscapeFuncs.reloadplugins)(reloadPages);
}
#ifdef OJI
JRIEnv* NPN_GetJavaEnv()
{
- return CallNPN_GetJavaEnvProc(gNetscapeFuncs.getJavaEnv);
+ return (*gNetscapeFuncs.getJavaEnv);
}
jref NPN_GetJavaPeer(NPP instance)
{
- return CallNPN_GetJavaPeerProc(gNetscapeFuncs.getJavaPeer,
- instance);
+ return (*gNetscapeFuncs.getJavaPeer)(instance);
}
#endif
void
NPN_InvalidateRect(NPP instance, NPRect *invalidRect)
{
- CallNPN_InvalidateRectProc(gNetscapeFuncs.invalidaterect, instance,
- invalidRect);
+ (*gNetscapeFuncs.invalidaterect)(instance, invalidRect);
}
void
NPN_InvalidateRegion(NPP instance, NPRegion invalidRegion)
{
- CallNPN_InvalidateRegionProc(gNetscapeFuncs.invalidateregion, instance,
- invalidRegion);
+ (*gNetscapeFuncs.invalidateregion)(instance, invalidRegion);
}
void
NPN_ForceRedraw(NPP instance)
{
- CallNPN_ForceRedrawProc(gNetscapeFuncs.forceredraw, instance);
+ (*gNetscapeFuncs.forceredraw)(instance);
}
void NPN_PushPopupsEnabledState(NPP instance, NPBool enabled)
{
- CallNPN_PushPopupsEnabledStateProc(gNetscapeFuncs.pushpopupsenabledstate,
- instance, enabled);
+ (*gNetscapeFuncs.pushpopupsenabledstate)(instance, enabled);
}
void NPN_PopPopupsEnabledState(NPP instance)
{
- CallNPN_PopPopupsEnabledStateProc(gNetscapeFuncs.poppopupsenabledstate,
- instance);
+ (*gNetscapeFuncs.poppopupsenabledstate)(instance);
}
NPIdentifier NPN_GetStringIdentifier(const NPUTF8 *name)
@@ -253,8 +240,7 @@ NPIdentifier NPN_GetStringIdentifier(const NPUTF8 *name)
int minor = gNetscapeFuncs.version & 0xFF;
if( minor >= 14 )
{
- return CallNPN_GetStringIdentifierProc(
- gNetscapeFuncs.getstringidentifier, name);
+ return (*gNetscapeFuncs.getstringidentifier)(name);
}
return NULL;
}
@@ -264,19 +250,14 @@ void NPN_GetStringIdentifiers(const NPUTF8 **names, int32_t nameCount,
{
int minor = gNetscapeFuncs.version & 0xFF;
if( minor >= 14 )
- {
- CallNPN_GetStringIdentifiersProc(gNetscapeFuncs.getstringidentifiers,
- names, nameCount, identifiers);
- }
+ (*gNetscapeFuncs.getstringidentifiers)(names, nameCount, identifiers);
}
NPIdentifier NPN_GetIntIdentifier(int32_t intid)
{
int minor = gNetscapeFuncs.version & 0xFF;
if( minor >= 14 )
- {
- return CallNPN_GetIntIdentifierProc(gNetscapeFuncs.getintidentifier, intid);
- }
+ return (*gNetscapeFuncs.getintidentifier)(intid);
return NULL;
}
@@ -284,11 +265,7 @@ bool NPN_IdentifierIsString(NPIdentifier identifier)
{
int minor = gNetscapeFuncs.version & 0xFF;
if( minor >= 14 )
- {
- return CallNPN_IdentifierIsStringProc(
- gNetscapeFuncs.identifierisstring,
- identifier);
- }
+ return (*gNetscapeFuncs.identifierisstring)(identifier);
return false;
}
@@ -296,11 +273,7 @@ NPUTF8 *NPN_UTF8FromIdentifier(NPIdentifier identifier)
{
int minor = gNetscapeFuncs.version & 0xFF;
if( minor >= 14 )
- {
- return CallNPN_UTF8FromIdentifierProc(
- gNetscapeFuncs.utf8fromidentifier,
- identifier);
- }
+ return (*gNetscapeFuncs.utf8fromidentifier)(identifier);
return NULL;
}
@@ -308,11 +281,7 @@ int32_t NPN_IntFromIdentifier(NPIdentifier identifier)
{
int minor = gNetscapeFuncs.version & 0xFF;
if( minor >= 14 )
- {
- return CallNPN_IntFromIdentifierProc(
- gNetscapeFuncs.intfromidentifier,
- identifier);
- }
+ return (*gNetscapeFuncs.intfromidentifier)(identifier);
return 0;
}
@@ -320,7 +289,7 @@ NPObject *NPN_CreateObject(NPP npp, NPClass *aClass)
{
int minor = gNetscapeFuncs.version & 0xFF;
if( minor >= 14 )
- return CallNPN_CreateObjectProc(gNetscapeFuncs.createobject, npp, aClass);
+ return (*gNetscapeFuncs.createobject)(npp, aClass);
return NULL;
}
@@ -328,7 +297,7 @@ NPObject *NPN_RetainObject(NPObject *obj)
{
int minor = gNetscapeFuncs.version & 0xFF;
if( minor >= 14 )
- return CallNPN_RetainObjectProc(gNetscapeFuncs.retainobject, obj);
+ return (*gNetscapeFuncs.retainobject)(obj);
return NULL;
}
@@ -336,7 +305,7 @@ void NPN_ReleaseObject(NPObject *obj)
{
int minor = gNetscapeFuncs.version & 0xFF;
if( minor >= 14 )
- CallNPN_ReleaseObjectProc(gNetscapeFuncs.releaseobject, obj);
+ (*gNetscapeFuncs.releaseobject)(obj);
}
bool NPN_Invoke(NPP npp, NPObject* obj, NPIdentifier methodName,
@@ -344,8 +313,7 @@ bool NPN_Invoke(NPP npp, NPObject* obj, NPIdentifier methodName,
{
int minor = gNetscapeFuncs.version & 0xFF;
if( minor >= 14 )
- return CallNPN_InvokeProc(gNetscapeFuncs.invoke, npp, obj, methodName,
- args, argCount, result);
+ return (*gNetscapeFuncs.invoke)(npp, obj, methodName, args, argCount, result);
return false;
}
@@ -354,8 +322,7 @@ bool NPN_InvokeDefault(NPP npp, NPObject* obj, const NPVariant *args,
{
int minor = gNetscapeFuncs.version & 0xFF;
if( minor >= 14 )
- return CallNPN_InvokeDefaultProc(gNetscapeFuncs.invokeDefault, npp, obj,
- args, argCount, result);
+ return (*gNetscapeFuncs.invokeDefault)(npp, obj, args, argCount, result);
return false;
}
@@ -364,8 +331,7 @@ bool NPN_Evaluate(NPP npp, NPObject* obj, NPString *script,
{
int minor = gNetscapeFuncs.version & 0xFF;
if( minor >= 14 )
- return CallNPN_EvaluateProc(gNetscapeFuncs.evaluate, npp, obj,
- script, result);
+ return (*gNetscapeFuncs.evaluate)(npp, obj, script, result);
return false;
}
@@ -374,8 +340,7 @@ bool NPN_GetProperty(NPP npp, NPObject* obj, NPIdentifier propertyName,
{
int minor = gNetscapeFuncs.version & 0xFF;
if( minor >= 14 )
- return CallNPN_GetPropertyProc(gNetscapeFuncs.getproperty, npp, obj,
- propertyName, result);
+ return (*gNetscapeFuncs.getproperty)(npp, obj, propertyName, result);
return false;
}
@@ -384,8 +349,7 @@ bool NPN_SetProperty(NPP npp, NPObject* obj, NPIdentifier propertyName,
{
int minor = gNetscapeFuncs.version & 0xFF;
if( minor >= 14 )
- return CallNPN_SetPropertyProc(gNetscapeFuncs.setproperty, npp, obj,
- propertyName, value);
+ return (*gNetscapeFuncs.setproperty)(npp, obj, propertyName, value);
return false;
}
@@ -393,8 +357,7 @@ bool NPN_RemoveProperty(NPP npp, NPObject* obj, NPIdentifier propertyName)
{
int minor = gNetscapeFuncs.version & 0xFF;
if( minor >= 14 )
- return CallNPN_RemovePropertyProc(gNetscapeFuncs.removeproperty, npp, obj,
- propertyName);
+ return (*gNetscapeFuncs.removeproperty)(npp, obj, propertyName);
return false;
}
@@ -402,8 +365,7 @@ bool NPN_HasProperty(NPP npp, NPObject* obj, NPIdentifier propertyName)
{
int minor = gNetscapeFuncs.version & 0xFF;
if( minor >= 14 )
- return CallNPN_HasPropertyProc(gNetscapeFuncs.hasproperty, npp, obj,
- propertyName);
+ return (*gNetscapeFuncs.hasproperty)(npp, obj, propertyName);
return false;
}
@@ -411,8 +373,7 @@ bool NPN_HasMethod(NPP npp, NPObject* obj, NPIdentifier methodName)
{
int minor = gNetscapeFuncs.version & 0xFF;
if( minor >= 14 )
- return CallNPN_HasMethodProc(gNetscapeFuncs.hasmethod, npp,
- obj, methodName);
+ return (*gNetscapeFuncs.hasmethod)(npp, obj, methodName);
return false;
}
@@ -420,14 +381,14 @@ void NPN_ReleaseVariantValue(NPVariant *variant)
{
int minor = gNetscapeFuncs.version & 0xFF;
if( minor >= 14 )
- CallNPN_ReleaseVariantValueProc(gNetscapeFuncs.releasevariantvalue, variant);
+ (*gNetscapeFuncs.releasevariantvalue)(variant);
}
void NPN_SetException(NPObject* obj, const NPUTF8 *message)
{
int minor = gNetscapeFuncs.version & 0xFF;
if( minor >= 14 )
- CallNPN_SetExceptionProc(gNetscapeFuncs.setexception, obj, message);
+ (*gNetscapeFuncs.setexception)(obj, message);
}
/***********************************************************************
@@ -766,22 +727,22 @@ NP_Initialize(NPNetscapeFuncs* nsTable, NPPluginFuncs* pluginFuncs)
*/
pluginFuncs->version = (NP_VERSION_MAJOR << 8) + NP_VERSION_MINOR;
pluginFuncs->size = sizeof(NPPluginFuncs);
- pluginFuncs->newp = NewNPP_NewProc(Private_New);
- pluginFuncs->destroy = NewNPP_DestroyProc(Private_Destroy);
- pluginFuncs->setwindow = NewNPP_SetWindowProc(Private_SetWindow);
- pluginFuncs->newstream = NewNPP_NewStreamProc(Private_NewStream);
- pluginFuncs->destroystream = NewNPP_DestroyStreamProc(Private_DestroyStream);
- pluginFuncs->asfile = NewNPP_StreamAsFileProc(Private_StreamAsFile);
- pluginFuncs->writeready = NewNPP_WriteReadyProc(Private_WriteReady);
- pluginFuncs->write = NewNPP_WriteProc(Private_Write);
- pluginFuncs->print = NewNPP_PrintProc(Private_Print);
- pluginFuncs->getvalue = NewNPP_GetValueProc(Private_GetValue);
- pluginFuncs->setvalue = NewNPP_SetValueProc(Private_SetValue);
+ 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->getvalue = (NPP_GetValueProcPtr)(Private_GetValue);
+ pluginFuncs->setvalue = (NPP_SetValueProcPtr)(Private_SetValue);
pluginFuncs->event = NULL;
if( minor >= NPVERS_HAS_NOTIFICATION )
{
- pluginFuncs->urlnotify = NewNPP_URLNotifyProc(Private_URLNotify);
+ pluginFuncs->urlnotify = (NPP_URLNotifyProcPtr)(Private_URLNotify);
}
#ifdef OJI
if( minor >= NPVERS_HAS_LIVECONNECT )

@ -1,66 +0,0 @@
diff --git a/modules/audio_output/pulse.c b/modules/audio_output/pulse.c
index 86bd6dd..ce133f9 100644
--- a/modules/audio_output/pulse.c
+++ b/modules/audio_output/pulse.c
@@ -175,16 +175,17 @@ static int Open ( vlc_object_t *p_this )
msg_Err(p_aout,"Invalid sample spec");
goto fail;
}
+
+ a.maxlength = pa_bytes_per_second(&ss)/4/pa_frame_size(&ss);
+ a.tlength = a.maxlength*9/10;
+ a.prebuf = a.tlength/2;
+ a.minreq = a.tlength/10;
- /* Reduce overall latency to 200mS to reduce audible clicks
- * Also pulse minreq and internal buffers are now 20mS which reduces resampling
- */
- a.tlength = pa_bytes_per_second(&ss)/5;
- a.maxlength = a.tlength * 2;
- a.prebuf = a.tlength;
- a.minreq = a.tlength / 10;
+ a.maxlength *= pa_frame_size(&ss);
+ a.tlength *= pa_frame_size(&ss);
+ a.prebuf *= pa_frame_size(&ss);
+ a.minreq *= pa_frame_size(&ss);
- /* Buffer size is 20mS */
p_sys->buffer_size = a.minreq;
/* Initialise the speaker map setup above */
@@ -212,7 +213,7 @@ static int Open ( vlc_object_t *p_this )
PULSE_DEBUG( "Pulse after context connect");
pa_threaded_mainloop_lock(p_sys->mainloop);
-
+
if (pa_threaded_mainloop_start(p_sys->mainloop) < 0) {
msg_Err(p_aout, "Failed to start main loop");
goto unlock_and_fail;
@@ -239,7 +240,7 @@ static int Open ( vlc_object_t *p_this )
pa_stream_set_write_callback(p_sys->stream, stream_request_cb, p_aout);
pa_stream_set_latency_update_callback(p_sys->stream, stream_latency_update_cb, p_aout);
- if (pa_stream_connect_playback(p_sys->stream, NULL, &a, PA_STREAM_INTERPOLATE_TIMING|PA_STREAM_AUTO_TIMING_UPDATE|PA_STREAM_ADJUST_LATENCY, NULL, NULL) < 0) {
+ if (pa_stream_connect_playback(p_sys->stream, NULL, &a, PA_STREAM_INTERPOLATE_TIMING|PA_STREAM_AUTO_TIMING_UPDATE, NULL, NULL) < 0) {
msg_Err(p_aout, "Failed to connect stream: %s", pa_strerror(pa_context_errno(p_sys->context)));
goto unlock_and_fail;
}
@@ -447,11 +448,16 @@ static void stream_request_cb(pa_stream *s, size_t length, void *userdata) {
latency = 0;
}
-
PULSE_DEBUG( "Pulse stream request latency=%"PRId64"", latency);
next_date = mdate() + latency;
+
if(p_sys->start_date < next_date + AOUT_PTS_TOLERANCE ){
+ /*
+ vlc_mutex_lock( &p_aout->output_fifo_lock );
+ p_buffer = aout_FifoPop( p_aout, &p_aout->output.fifo );
+ vlc_mutex_unlock( &p_aout->output_fifo_lock );
+ */
p_buffer = aout_OutputNextBuffer( p_aout, next_date, 0);
}
}
Loading…
Cancel
Save