diff options
author | pontscho <pontscho@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2003-01-09 20:47:14 +0000 |
---|---|---|
committer | pontscho <pontscho@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2003-01-09 20:47:14 +0000 |
commit | 52a7bad9a6b5240797ba9780e182a31caf3e79d4 (patch) | |
tree | 41c7ff8cc73c61efce83a7c721a0fa352a940e8a /Gui/mplayer | |
parent | 8c30a49e223eebe3f20a522b66dc32e120024853 (diff) | |
download | mpv-52a7bad9a6b5240797ba9780e182a31caf3e79d4.tar.bz2 mpv-52a7bad9a6b5240797ba9780e182a31caf3e79d4.tar.xz |
- sync with x11_common
- half rewrited font render engine (disabled by default)
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@8865 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'Gui/mplayer')
-rw-r--r-- | Gui/mplayer/mw.c | 8 | ||||
-rw-r--r-- | Gui/mplayer/play.c | 2 | ||||
-rw-r--r-- | Gui/mplayer/sw.c | 9 | ||||
-rw-r--r-- | Gui/mplayer/widgets.c | 6 |
4 files changed, 16 insertions, 9 deletions
diff --git a/Gui/mplayer/mw.c b/Gui/mplayer/mw.c index 040e51cf94..e0b6f13012 100644 --- a/Gui/mplayer/mw.c +++ b/Gui/mplayer/mw.c @@ -218,20 +218,20 @@ void mplMainDraw( void ) PutImage( &item->Mask,item->x + (int)( ( item->width - item->psx ) * item->value / 100.0f ),item->y,3,item->pressed ); break; case itSLabel: - image=fntRender( item->fontid,0,item->width,"%s",item->label ); + image=fntRender( item,0,"%s",item->label ); goto drawrenderedtext; case itDLabel: { char * t = Translate( item->label ); int l = fntTextWidth( item->fontid,t ); - image=fntRender( item->fontid,(GetTimerMS() / 20)%(l?l:item->width),item->width,"%s",t ); + image=fntRender( item,(GetTimerMS() / 20)%(l?l:item->width),"%s",t ); } drawrenderedtext: if ( image ) { PutImage( image,item->x,item->y,1,0 ); - if ( image->Image ) free( image->Image ); - free( image ); +// if ( image->Image ) free( image->Image ); +// free( image ); } break; } diff --git a/Gui/mplayer/play.c b/Gui/mplayer/play.c index 66b96f11dd..92bcdd968a 100644 --- a/Gui/mplayer/play.c +++ b/Gui/mplayer/play.c @@ -238,7 +238,7 @@ void ChangeSkin( char * name ) if ( ( mplDrawBuffer = (unsigned char *)calloc( 1,appMPlayer.main.Bitmap.ImageSize ) ) == NULL ) { mp_msg( MSGT_GPLAYER,MSGL_STATUS,MSGTR_NEMDB ); return; } - if ( wsWMType == wsWMUnknown ) wsVisibleWindow( &appMPlayer.mainWindow,wsHideWindow ); + if ( vo_wm_type == vo_wm_Unknown ) wsVisibleWindow( &appMPlayer.mainWindow,wsHideWindow ); wsResizeWindow( &appMPlayer.mainWindow,appMPlayer.main.width,appMPlayer.main.height ); wsMoveWindow( &appMPlayer.mainWindow,True,appMPlayer.main.x,appMPlayer.main.y ); wsResizeImage( &appMPlayer.mainWindow,appMPlayer.main.width,appMPlayer.main.height ); diff --git a/Gui/mplayer/sw.c b/Gui/mplayer/sw.c index ac0f9b8901..21191b4fb2 100644 --- a/Gui/mplayer/sw.c +++ b/Gui/mplayer/sw.c @@ -1,6 +1,11 @@ // sub window +#include <inttypes.h> + +#include "../../config.h" +#include "../../libvo/x11_common.h" + #include "../app.h" #include "../interface.h" #include "../../help_mp.h" @@ -18,7 +23,7 @@ void mplSubDraw( void ) if ( appMPlayer.subWindow.State == wsWindowClosed ) exit_player( MSGTR_Exit_quit ); if ( appMPlayer.subWindow.State == wsWindowFocusIn ) SubVisible++; - if ( appMPlayer.subWindow.State == wsWindowFocusOut && wsWMType != wsWMKDE && wsWMType != wsWMIceWM ) SubVisible--; + if ( appMPlayer.subWindow.State == wsWindowFocusOut && metacity_hack != 3 ) SubVisible--; if ( !appMPlayer.subWindow.Mapped || appMPlayer.subWindow.Visible == wsWindowNotVisible ) return; @@ -74,7 +79,7 @@ void mplSubMouseHandle( int Button,int X,int Y,int RX,int RY ) if ( ( !mplSubMoved )&&( appMPlayer.subWindow.isFullScreen ) ) { if( SubVisible++%2 ) wsMoveTopWindow( wsDisplay,appMPlayer.mainWindow.WindowID ); - else if ( wsWMType != wsWMNetWM && wsWMType != wsWMKDE ) wsMoveTopWindow( wsDisplay,appMPlayer.subWindow.WindowID ); + else wsMoveTopWindow( wsDisplay,appMPlayer.subWindow.WindowID ); } msButton=0; mplSubMoved=0; diff --git a/Gui/mplayer/widgets.c b/Gui/mplayer/widgets.c index e11b909b77..206c3f25f0 100644 --- a/Gui/mplayer/widgets.c +++ b/Gui/mplayer/widgets.c @@ -144,13 +144,15 @@ void gtkMessageBox( int type,gchar * str ) } gtk_widget_show( MessageBox ); gtkSetLayer( MessageBox ); - gtkActive( MessageBox ); if ( type == GTK_MB_FATAL ) while ( MessageBox ) gtk_main_iteration_do( 0 ); } void gtkSetLayer( GtkWidget * wdg ) -{ wsSetLayer( gdk_display,GDK_WINDOW_XWINDOW( wdg->window ),appMPlayer.subWindow.isFullScreen ); } +{ + wsSetLayer( gdk_display,GDK_WINDOW_XWINDOW( wdg->window ),appMPlayer.subWindow.isFullScreen ); + gtkActive( wdg ); +} void gtkActive( GtkWidget * wdg ) { wsMoveTopWindow( gdk_display,GDK_WINDOW_XWINDOW( wdg->window )); } |