Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-2-2
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc-2-2
Commits
df9d73dd
Commit
df9d73dd
authored
Aug 29, 2006
by
Damien Fouilleul
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
- compatibility fixes for FireFox, Safari and Opera 9
- fixed a couple of crashes on MacOS X
parent
4902ffc9
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
120 additions
and
121 deletions
+120
-121
mozilla/control/npolibvlc.cpp
mozilla/control/npolibvlc.cpp
+40
-44
mozilla/support/npmac.cpp
mozilla/support/npmac.cpp
+60
-60
mozilla/test.html
mozilla/test.html
+16
-14
mozilla/vlcshell.cpp
mozilla/vlcshell.cpp
+4
-3
No files found.
mozilla/control/npolibvlc.cpp
View file @
df9d73dd
...
@@ -494,7 +494,7 @@ const NPUTF8 * const LibvlcPlaylistNPObject::methodNames[] =
...
@@ -494,7 +494,7 @@ const NPUTF8 * const LibvlcPlaylistNPObject::methodNames[] =
{
{
"add"
,
"add"
,
"play"
,
"play"
,
"togglepause"
"togglepause"
,
"stop"
,
"stop"
,
"next"
,
"next"
,
"prev"
,
"prev"
,
...
@@ -811,12 +811,13 @@ void LibvlcPlaylistNPObject::parseOptions(const NPString &s, int *i_options, cha
...
@@ -811,12 +811,13 @@ void LibvlcPlaylistNPObject::parseOptions(const NPString &s, int *i_options, cha
void
LibvlcPlaylistNPObject
::
parseOptions
(
NPObject
*
obj
,
int
*
i_options
,
char
***
ppsz_options
)
void
LibvlcPlaylistNPObject
::
parseOptions
(
NPObject
*
obj
,
int
*
i_options
,
char
***
ppsz_options
)
{
{
/* we are expecting to have a Javascript Array object */
/* WARNING: Safari does not implement NPN_HasProperty/NPN_HasMethod */
NPIdentifier
name
=
NPN_GetStringIdentifier
(
"length"
);
if
(
NPN_HasProperty
(
_instance
,
obj
,
name
)
)
{
NPVariant
value
;
NPVariant
value
;
if
(
NPN_GetProperty
(
_instance
,
obj
,
name
,
&
value
)
)
/* we are expecting to have a Javascript Array object */
NPIdentifier
propId
=
NPN_GetStringIdentifier
(
"length"
);
if
(
NPN_GetProperty
(
_instance
,
obj
,
propId
,
&
value
)
)
{
{
int
count
=
numberValue
(
value
);
int
count
=
numberValue
(
value
);
NPN_ReleaseVariantValue
(
&
value
);
NPN_ReleaseVariantValue
(
&
value
);
...
@@ -831,12 +832,8 @@ void LibvlcPlaylistNPObject::parseOptions(NPObject *obj, int *i_options, char***
...
@@ -831,12 +832,8 @@ void LibvlcPlaylistNPObject::parseOptions(NPObject *obj, int *i_options, char***
while
(
nOptions
<
count
)
while
(
nOptions
<
count
)
{
{
name
=
NPN_GetIntIdentifier
(
nOptions
);
propId
=
NPN_GetIntIdentifier
(
nOptions
);
if
(
!
NPN_HasProperty
(
_instance
,
obj
,
name
)
)
if
(
!
NPN_GetProperty
(
_instance
,
obj
,
propId
,
&
value
)
)
/* return what we got so far */
break
;
if
(
!
NPN_GetProperty
(
_instance
,
obj
,
name
,
&
value
)
)
/* return what we got so far */
/* return what we got so far */
break
;
break
;
...
@@ -870,7 +867,6 @@ void LibvlcPlaylistNPObject::parseOptions(NPObject *obj, int *i_options, char***
...
@@ -870,7 +867,6 @@ void LibvlcPlaylistNPObject::parseOptions(NPObject *obj, int *i_options, char***
}
}
}
}
}
}
}
}
}
/*
/*
...
...
mozilla/support/npmac.cpp
View file @
df9d73dd
mozilla/test.html
View file @
df9d73dd
...
@@ -19,20 +19,20 @@ MRL:
...
@@ -19,20 +19,20 @@ MRL:
</TD></TR>
</TD></TR>
<TR><TD
colspan=
"2"
>
<TR><TD
colspan=
"2"
>
<INPUT
type=
button
id=
"PlayOrPause"
value=
" Play "
onClick=
'doPlayOrPause()'
>
<INPUT
type=
button
id=
"PlayOrPause"
value=
" Play "
onClick=
'doPlayOrPause()'
>
<INPUT
type=
button
value=
"Stop"
onClick=
'document.
vlc
.playlist.stop();'
>
<INPUT
type=
button
value=
"Stop"
onClick=
'document.
getElementById("vlc")
.playlist.stop();'
>
<INPUT
type=
button
value=
" << "
onClick=
'document.
vlc
.playlist.playSlower();'
>
<INPUT
type=
button
value=
" << "
onClick=
'document.
getElementById("vlc")
.playlist.playSlower();'
>
<INPUT
type=
button
value=
" >> "
onClick=
'document.
vlc
.playlist.playFaster();'
>
<INPUT
type=
button
value=
" >> "
onClick=
'document.
getElementById("vlc")
.playlist.playFaster();'
>
<INPUT
type=
button
value=
"Show"
onClick=
'document.
vlc
.visible = true;'
>
<INPUT
type=
button
value=
"Show"
onClick=
'document.
getElementById("vlc")
.visible = true;'
>
<INPUT
type=
button
value=
"Hide"
onClick=
'document.
vlc
.visible = false;'
>
<INPUT
type=
button
value=
"Hide"
onClick=
'document.
getElementById("vlc")
.visible = false;'
>
<INPUT
type=
button
value=
"Version"
onClick=
'alert(document.
vlc
.VersionInfo);'
>
<INPUT
type=
button
value=
"Version"
onClick=
'alert(document.
getElementById("vlc")
.VersionInfo);'
>
<SPAN
style=
"text-align:center"
>
Volume:
</SPAN>
<SPAN
style=
"text-align:center"
>
Volume:
</SPAN>
<INPUT
type=
button
value=
" - "
onClick=
'updateVolume(-10)'
>
<INPUT
type=
button
value=
" - "
onClick=
'updateVolume(-10)'
>
<SPAN
id=
"volumeTextField"
style=
"text-align: center"
>
--
</SPAN>
<SPAN
id=
"volumeTextField"
style=
"text-align: center"
>
--
</SPAN>
<INPUT
type=
button
value=
" + "
onClick=
'updateVolume(+10)'
>
<INPUT
type=
button
value=
" + "
onClick=
'updateVolume(+10)'
>
<INPUT
type=
button
value=
"Mute"
onClick=
'document.
vlc
.audio.togglemute();'
>
<INPUT
type=
button
value=
"Mute"
onClick=
'document.
getElementById("vlc")
.audio.togglemute();'
>
</TD>
</TD>
</TR>
</TR>
</TABLE>
</TABLE>
...
@@ -42,9 +42,9 @@ var timerId = 0;
...
@@ -42,9 +42,9 @@ var timerId = 0;
function updateVolume(deltaVol)
function updateVolume(deltaVol)
{
{
var
plugin = document.getElementById('vlc'
);
var
vlc = document.getElementById("vlc"
);
plugin
.audio.volume += deltaVol;
vlc
.audio.volume += deltaVol;
volumeTextField.innerText =
plugin
.audio.volume+"%";
volumeTextField.innerText =
vlc
.audio.volume+"%";
};
};
function formatTime(timeVal)
function formatTime(timeVal)
{
{
...
@@ -80,6 +80,7 @@ var liveFeedRoll = 0;
...
@@ -80,6 +80,7 @@ var liveFeedRoll = 0;
function doUpdate()
function doUpdate()
{
{
var vlc = document.getElementById("vlc");
if( vlc.playlist.isplaying )
if( vlc.playlist.isplaying )
{
{
if( vlc.input.length > 0 )
if( vlc.input.length > 0 )
...
@@ -103,17 +104,18 @@ function doUpdate()
...
@@ -103,17 +104,18 @@ function doUpdate()
function doGo(targetURL)
function doGo(targetURL)
{
{
var options = new Array(":vout-filter=deinterlace", ":deinterlace-mode=linear");
var options = new Array(":vout-filter=deinterlace", ":deinterlace-mode=linear");
document.
vlc
.playlist.add(targetURL, null, options);
document.
getElementById("vlc")
.playlist.add(targetURL, null, options);
};
};
function doPlayOrPause()
function doPlayOrPause()
{
{
if( document.vlc.playlist.isplaying )
var vlc = document.getElementById("vlc");
if( vlc.playlist.isplaying )
{
{
document.
vlc.playlist.pause();
vlc.playlist.pause();
}
}
else
else
{
{
document.
vlc.playlist.play();
vlc.playlist.play();
}
}
};
};
function vlcPlayEvent()
function vlcPlayEvent()
...
...
mozilla/vlcshell.cpp
View file @
df9d73dd
...
@@ -176,10 +176,11 @@ int16 NPP_HandleEvent( NPP instance, void * event )
...
@@ -176,10 +176,11 @@ int16 NPP_HandleEvent( NPP instance, void * event )
}
}
}
}
}
}
if
(
needsDisplay
)
{
const
NPWindow
*
npwindow
=
p_plugin
->
getWindow
();
const
NPWindow
*
npwindow
=
p_plugin
->
getWindow
();
if
(
needsDisplay
&&
npwindow
->
window
)
{
/* draw the beautiful "No Picture" */
/* draw the beautiful "No Picture" */
ForeColor
(
blackColor
);
ForeColor
(
blackColor
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment