mirror of
https://github.com/mpv-player/mpv
synced 2025-01-20 06:11:10 +00:00
dvd playing bug fixed
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@2995 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
parent
f90a25b600
commit
8948893119
@ -225,52 +225,43 @@ void mplMsgHandle( int msg,float param )
|
|||||||
{
|
{
|
||||||
// --- user events
|
// --- user events
|
||||||
case evExit:
|
case evExit:
|
||||||
// IZE("evExit");
|
|
||||||
wsDoExit(); // sets wsTrue=False;
|
wsDoExit(); // sets wsTrue=False;
|
||||||
exit_player( "Exit" );
|
exit_player( "Exit" );
|
||||||
break;
|
break;
|
||||||
case evIconify:
|
|
||||||
switch ( (int)param )
|
|
||||||
{
|
|
||||||
case 0: wsIconify( appMPlayer.mainWindow ); break;
|
|
||||||
case 1: wsIconify( appMPlayer.subWindow ); break;
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
case evFullScreen:
|
|
||||||
IZE("evFullS");
|
|
||||||
for ( j=0;j<appMPlayer.NumberOfItems + 1;j++ )
|
|
||||||
{
|
|
||||||
if ( appMPlayer.Items[j].msg == evFullScreen )
|
|
||||||
{
|
|
||||||
appMPlayer.Items[j].tmp=!appMPlayer.Items[j].tmp;
|
|
||||||
appMPlayer.Items[j].pressed=appMPlayer.Items[j].tmp;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
mplMainRender=1;
|
|
||||||
mplFullScreen();
|
|
||||||
break;
|
|
||||||
|
|
||||||
case evPlaySwitchToPause:
|
case evPlayDVD:
|
||||||
IZE("evPlay->Pause");
|
mplShMem->StreamType=STREAMTYPE_DVD;
|
||||||
if ( Filename )
|
|
||||||
{
|
|
||||||
btnModify( evPlaySwitchToPause,btnDisabled );
|
|
||||||
btnModify( evPauseSwitchToPlay,btnReleased );
|
|
||||||
}
|
|
||||||
if ( mplShMem->Playing == 1 ) goto NoPause;
|
|
||||||
case evPlay:
|
case evPlay:
|
||||||
IZE("evPlay");
|
case evPlaySwitchToPause:
|
||||||
|
btnModify( evPlaySwitchToPause,btnDisabled );
|
||||||
|
btnModify( evPauseSwitchToPlay,btnReleased );
|
||||||
|
if ( ( msg == evPlaySwitchToPause )&( mplShMem->Playing == 1 ) ) goto NoPause;
|
||||||
mplMainRender=1;
|
mplMainRender=1;
|
||||||
|
|
||||||
|
switch ( mplShMem->StreamType )
|
||||||
|
{
|
||||||
|
// case STREAMTYPE_FILE: strcat( trbuf,"f" ); break;
|
||||||
|
// case STREAMTYPE_STREAM: strcat( trbuf,"u" ); break;
|
||||||
|
// case STREAMTYPE_VCD: strcat( trbuf,"v" ); break;
|
||||||
|
case STREAMTYPE_DVD:
|
||||||
|
dvd_title=1;
|
||||||
|
dvd_chapter=1;
|
||||||
|
dvd_angle=1;
|
||||||
|
strcpy( mplShMem->Filename,"/dev/dvd" );
|
||||||
|
break;
|
||||||
|
}
|
||||||
mplPlay();
|
mplPlay();
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
// break;
|
||||||
|
|
||||||
|
case evPause:
|
||||||
case evPauseSwitchToPlay:
|
case evPauseSwitchToPlay:
|
||||||
IZE("evPause->Play");
|
Pause:
|
||||||
btnModify( evPlaySwitchToPause,btnReleased );
|
btnModify( evPlaySwitchToPause,btnReleased );
|
||||||
btnModify( evPauseSwitchToPlay,btnDisabled );
|
btnModify( evPauseSwitchToPlay,btnDisabled );
|
||||||
case evPause:
|
|
||||||
NoPause:
|
NoPause:
|
||||||
IZE("evPause");
|
|
||||||
mplMainRender=1;
|
mplMainRender=1;
|
||||||
mplPause();
|
mplPause();
|
||||||
break;
|
break;
|
||||||
@ -284,10 +275,8 @@ NoPause:
|
|||||||
break;
|
break;
|
||||||
|
|
||||||
case evLoadPlay:
|
case evLoadPlay:
|
||||||
IZE("evLoadPlay");
|
|
||||||
mplMainAutoPlay=1;
|
mplMainAutoPlay=1;
|
||||||
case evLoad:
|
case evLoad:
|
||||||
IZE("evLoad");
|
|
||||||
mplMainRender=1;
|
mplMainRender=1;
|
||||||
gtkSendMessage( evLoad );
|
gtkSendMessage( evLoad );
|
||||||
break;
|
break;
|
||||||
@ -341,6 +330,13 @@ NoPause:
|
|||||||
case evSetBalance: mplShMem->VolumeChanged=1; break;
|
case evSetBalance: mplShMem->VolumeChanged=1; break;
|
||||||
|
|
||||||
|
|
||||||
|
case evIconify:
|
||||||
|
switch ( (int)param )
|
||||||
|
{
|
||||||
|
case 0: wsIconify( appMPlayer.mainWindow ); break;
|
||||||
|
case 1: wsIconify( appMPlayer.subWindow ); break;
|
||||||
|
}
|
||||||
|
break;
|
||||||
case evNormalSize:
|
case evNormalSize:
|
||||||
if ( mplShMem->Playing )
|
if ( mplShMem->Playing )
|
||||||
{
|
{
|
||||||
@ -363,6 +359,19 @@ NoPause:
|
|||||||
mplResize( appMPlayer.subWindow.X,appMPlayer.subWindow.Y,moviewidth,movieheight );
|
mplResize( appMPlayer.subWindow.X,appMPlayer.subWindow.Y,moviewidth,movieheight );
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
case evFullScreen:
|
||||||
|
IZE("evFullS");
|
||||||
|
for ( j=0;j<appMPlayer.NumberOfItems + 1;j++ )
|
||||||
|
{
|
||||||
|
if ( appMPlayer.Items[j].msg == evFullScreen )
|
||||||
|
{
|
||||||
|
appMPlayer.Items[j].tmp=!appMPlayer.Items[j].tmp;
|
||||||
|
appMPlayer.Items[j].pressed=appMPlayer.Items[j].tmp;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
mplMainRender=1;
|
||||||
|
mplFullScreen();
|
||||||
|
break;
|
||||||
|
|
||||||
// --- timer events
|
// --- timer events
|
||||||
case evHideMouseCursor:
|
case evHideMouseCursor:
|
||||||
@ -382,13 +391,11 @@ NoPause:
|
|||||||
mplMainRender=1;
|
mplMainRender=1;
|
||||||
mplMainAutoPlay=0;
|
mplMainAutoPlay=0;
|
||||||
mplPlay();
|
mplPlay();
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
if ( mplMiddleMenu )
|
if ( mplMiddleMenu )
|
||||||
{
|
{
|
||||||
mplMiddleMenu=0;
|
mplMiddleMenu=0;
|
||||||
mplMsgHandle( gtkShMem->popupmenu,0 );
|
mplMsgHandle( gtkShMem->popupmenu,0 );
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
// --- system events
|
// --- system events
|
||||||
|
Loading…
Reference in New Issue
Block a user