1
0
mirror of https://github.com/mpv-player/mpv synced 2025-03-01 11:50:48 +00:00

fix fucking icewm fullscreen bug.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@2030 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
pontscho 2001-10-01 12:28:39 +00:00
parent a25b2273f8
commit bc2edd4346
4 changed files with 25 additions and 16 deletions

View File

@ -104,6 +104,7 @@ void mplInit( int argc,char* argv[], char *envp[], void* disp )
appMPlayer.subWindow.KeyHandler=mplMainKeyHandle;
appMPlayer.subWindow.ReSize=mplResize;
wsSetBackgroundRGB( &appMPlayer.subWindow,appMPlayer.subR,appMPlayer.subG,appMPlayer.subB );
if ( appMPlayer.sub.Bitmap.Image ) wsConvert( &appMPlayer.subWindow,appMPlayer.sub.Bitmap.Image,appMPlayer.sub.Bitmap.ImageSize );
wsPostRedisplay( &appMPlayer.mainWindow );

View File

@ -35,10 +35,24 @@ extern int abs_seek_pos;
void mplFullScreen( void )
{
// if ( appMPlayer.subWindow.isFullScreen )
// {
// }
wsFullScreen( &appMPlayer.subWindow );
static int sx,sy;
wsVisibleWindow( &appMPlayer.subWindow,wsHideWindow );
if ( appMPlayer.subWindow.isFullScreen )
{
wsResizeWindow( &appMPlayer.subWindow,sx,sy );
wsMoveWindow( &appMPlayer.subWindow,appMPlayer.sub.x,appMPlayer.sub.y );
wsWindowDecoration( &appMPlayer.subWindow,appMPlayer.subWindow.Decorations );
appMPlayer.subWindow.isFullScreen=0;
}
else
{
sx=appMPlayer.subWindow.Width; sy=appMPlayer.subWindow.Height;
wsResizeWindow( &appMPlayer.subWindow,wsMaxX,wsMaxY );
wsMoveWindow( &appMPlayer.subWindow,0,0 );
wsWindowDecoration( &appMPlayer.subWindow,0 );
appMPlayer.subWindow.isFullScreen=1;
}
wsVisibleWindow( &appMPlayer.subWindow,wsShowWindow );
mplResize( 0,0,appMPlayer.subWindow.Width,appMPlayer.subWindow.Height );
}

View File

@ -13,20 +13,13 @@ void mplSubDraw( wsParamDisplay )
if ( mplShMem->Playing )
{
// wsSetBackgroundRGB( &appMPlayer.subWindow,0,0,0 );
// wsClearWindow( appMPlayer.subWindow );
vo_expose=1;
mplSubRender=0;
}
if ( mplSubRender )
{
// wsSetBackgroundRGB( &appMPlayer.subWindow,appMPlayer.subR,appMPlayer.subG,appMPlayer.subB );
if ( appMPlayer.sub.Bitmap.Image )
{
// wsConvert( &appMPlayer.subWindow,appMPlayer.sub.Bitmap.Image,appMPlayer.sub.Bitmap.ImageSize );
wsPutImage( &appMPlayer.subWindow );
}
if ( appMPlayer.sub.Bitmap.Image ) wsPutImage( &appMPlayer.subWindow );
// XFlush( wsDisplay );
}
appMPlayer.subWindow.State=0;

View File

@ -193,9 +193,10 @@ if(mDisplay){
{
int minor,major,shp;
fprintf( stderr,"[ws] Screen depth: %d\n",wsDepthOnScreen );
fprintf( stderr,"[ws] red mask: 0x%x\n",wsRedMask );
fprintf( stderr,"[ws] green mask: 0x%x\n",wsGreenMask );
fprintf( stderr,"[ws] blue mask: 0x%x\n",wsBlueMask );
fprintf( stderr,"[ws] size: %dx%d\n",wsMaxX,wsMaxY );
fprintf( stderr,"[ws] red mask: 0x%x\n",wsRedMask );
fprintf( stderr,"[ws] green mask: 0x%x\n",wsGreenMask );
fprintf( stderr,"[ws] blue mask: 0x%x\n",wsBlueMask );
if ( wsUseXShm )
{
XShmQueryVersion( wsDisplay,&major,&minor,&shp );
@ -366,7 +367,7 @@ void wsCreateWindow( wsTWindow * win,int X,int Y,int wX,int hY,int bW,int cV,uns
win->WindowMask,&win->WindowAttrib );
wsClassHint.res_name=label;
wsClassHint.res_class="mPlayer";
wsClassHint.res_class="MPlayer";
XSetClassHint( wsDisplay,win->WindowID,&wsClassHint );
win->SizeHint.flags=PPosition | PSize | PResizeInc; // | PBaseSize