/*****************************************************************************
- * vlcplugin.cpp: a VideoLAN Client plugin for Mozilla
+ * vlcplugin.cpp: a VLC plugin for Mozilla
*****************************************************************************
- * Copyright (C) 2002 VideoLAN
- * $Id: vlcplugin.cpp,v 1.2 2002/09/30 11:05:41 sam Exp $
+ * Copyright (C) 2002-2005 the VideoLAN team
+ * $Id$
*
* Authors: Samuel Hocevar <sam@zoy.org>
*
/*****************************************************************************
* Preamble
*****************************************************************************/
+#include "config.h"
+
#include <vlc/vlc.h>
+#ifdef HAVE_MOZILLA_CONFIG_H
+# include <mozilla-config.h>
+#endif
+#include <nsISupports.h>
+#include <nsMemory.h>
#include <npapi.h>
+#if !defined(XP_MACOSX) && !defined(XP_UNIX) && !defined(XP_WIN)
+#define XP_UNIX 1
+#elif defined(XP_MACOSX)
+#undef XP_UNIX
+#endif
+
#include "vlcpeer.h"
#include "vlcplugin.h"
*****************************************************************************/
VlcPlugin::VlcPlugin( NPP instance )
{
- p_instance = instance;
+ p_instance = instance;
p_peer = NULL;
}
if( !p_peer )
{
p_peer = new VlcPeer( this );
- if( p_peer == NULL )
+ if( p_peer == NULL )
{
return NULL;
}
-
+
NS_ADDREF( p_peer );
}
fclose (fh);
fprintf(stderr, "File loaded\n");
#endif
- return;
+ return;
}