Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 55969
Collapse All | Expand All

(-)MPlayer-1.0pre4.orig/help/help_mp-en.h (+3 lines)
Lines 360-365 Link Here
360
#define MSGTR_MovieAspectIsSet "Movie-Aspect is %.2f:1 - prescaling to correct movie aspect.\n"
360
#define MSGTR_MovieAspectIsSet "Movie-Aspect is %.2f:1 - prescaling to correct movie aspect.\n"
361
#define MSGTR_MovieAspectUndefined "Movie-Aspect is undefined - no prescaling applied.\n"
361
#define MSGTR_MovieAspectUndefined "Movie-Aspect is undefined - no prescaling applied.\n"
362
362
363
// x11_common.c
364
#define MSGTR_EwmhFullscreenStateFailed "\nX11: Couldn't send EWMH fullscreen Event!\n"
365
363
// ====================== GUI messages/buttons ========================
366
// ====================== GUI messages/buttons ========================
364
367
365
#ifdef HAVE_NEW_GUI
368
#ifdef HAVE_NEW_GUI
(-)MPlayer-1.0pre4.orig/libvo/x11_common.c (+45 lines)
Lines 14-19 Link Here
14
#include <unistd.h>
14
#include <unistd.h>
15
#include <sys/mman.h>
15
#include <sys/mman.h>
16
#include <signal.h>
16
#include <signal.h>
17
#include <assert.h>
17
18
18
#include "video_out.h"
19
#include "video_out.h"
19
#include "aspect.h"
20
#include "aspect.h"
Lines 117-122 Link Here
117
118
118
static int vo_x11_get_fs_type(int supported);
119
static int vo_x11_get_fs_type(int supported);
119
120
121
/*
122
 * Sends the EWMH fullscreen state event.
123
 *
124
 * action: could be on of _NET_WM_STATE_REMOVE -- remove state
125
 *                        _NET_WM_STATE_ADD    -- add state
126
 *                        _NET_WM_STATE_TOGGLE -- toggle
127
 */
128
void vo_x11_ewmh_fullscreen( int action )
129
{
130
     assert( action == _NET_WM_STATE_REMOVE ||
131
	     action == _NET_WM_STATE_ADD ||
132
	     action == _NET_WM_STATE_TOGGLE    );
133
     
134
     if ( vo_fs_type & vo_wm_FULLSCREEN )
135
     {
136
	  XEvent xev;
137
	  
138
	  /* init X event structure for _NET_WM_FULLSCREEN client msg */
139
	  xev.xclient.type = ClientMessage;
140
	  xev.xclient.serial = 0;
141
	  xev.xclient.send_event = True;
142
	  xev.xclient.message_type = XInternAtom( mDisplay,
143
						  "_NET_WM_STATE", False );
144
	  xev.xclient.window = vo_window;
145
	  xev.xclient.format = 32;
146
	  xev.xclient.data.l[0] = action;
147
	  xev.xclient.data.l[1] = XInternAtom( mDisplay,
148
					       "_NET_WM_STATE_FULLSCREEN", False );
149
	  xev.xclient.data.l[2] = 0;
150
	  xev.xclient.data.l[3] = 0;
151
	  xev.xclient.data.l[4] = 0;    
152
	  
153
	  /* finally send that damn thing */
154
	  if ( !XSendEvent( mDisplay, DefaultRootWindow( mDisplay ), False,
155
			    SubstructureRedirectMask | SubstructureNotifyMask, &xev ) )
156
	  {
157
 	       mp_msg( MSGT_VO,MSGL_ERR, MSGTR_EwmhFullscreenStateFailed );
158
	  }
159
     }
160
}
161
120
void vo_hidecursor ( Display *disp , Window win )
162
void vo_hidecursor ( Display *disp , Window win )
121
{
163
{
122
	Cursor no_ptr;
164
	Cursor no_ptr;
Lines 1062-1072 Link Here
1062
1104
1063
 if ( vo_fs ){
1105
 if ( vo_fs ){
1064
   // fs->win
1106
   // fs->win
1107
   vo_x11_ewmh_fullscreen( _NET_WM_STATE_REMOVE ); // removes fullscreen state if wm supports EWMH
1108
1065
   if(vo_dwidth != vo_screenwidth && vo_dheight != vo_screenheight) return;
1109
   if(vo_dwidth != vo_screenwidth && vo_dheight != vo_screenheight) return;
1066
   vo_fs=VO_FALSE;
1110
   vo_fs=VO_FALSE;
1067
   x=vo_old_x; y=vo_old_y; w=vo_old_width; h=vo_old_height;
1111
   x=vo_old_x; y=vo_old_y; w=vo_old_width; h=vo_old_height;
1068
 } else {
1112
 } else {
1069
   // win->fs
1113
   // win->fs
1114
   vo_x11_ewmh_fullscreen( _NET_WM_STATE_ADD ); // sends fullscreen state to be added if wm supports EWMH
1070
   if(vo_old_width && 
1115
   if(vo_old_width && 
1071
     (vo_dwidth==vo_screenwidth && vo_dwidth!=vo_old_width) &&
1116
     (vo_dwidth==vo_screenwidth && vo_dwidth!=vo_old_width) &&
1072
     (vo_dheight==vo_screenheight && vo_dheight!=vo_old_height) ) return;
1117
     (vo_dheight==vo_screenheight && vo_dheight!=vo_old_height) ) return;
(-)MPlayer-1.0pre4.orig/libvo/x11_common.h (+7 lines)
Lines 14-19 Link Here
14
#define vo_wm_BELOW 16
14
#define vo_wm_BELOW 16
15
#define vo_wm_NETWM (vo_wm_FULLSCREEN | vo_wm_STAYS_ON_TOP | vo_wm_ABOVE | vo_wm_BELOW)
15
#define vo_wm_NETWM (vo_wm_FULLSCREEN | vo_wm_STAYS_ON_TOP | vo_wm_ABOVE | vo_wm_BELOW)
16
16
17
/* EWMH state actions, see
18
   http://freedesktop.org/Standards/wm-spec/index.html#id2768769 */
19
#define _NET_WM_STATE_REMOVE        0    /* remove/unset property */
20
#define _NET_WM_STATE_ADD           1    /* add/set property */
21
#define _NET_WM_STATE_TOGGLE        2    /* toggle property  */
22
17
extern int metacity_hack;
23
extern int metacity_hack;
18
extern int vo_fsmode;
24
extern int vo_fsmode;
19
25
Lines 62-67 Link Here
62
	int img_width, int img_height, int use_fs);
68
	int img_width, int img_height, int use_fs);
63
extern void vo_x11_clearwindow( Display *mDisplay, Window vo_window );
69
extern void vo_x11_clearwindow( Display *mDisplay, Window vo_window );
64
extern void vo_x11_ontop();
70
extern void vo_x11_ontop();
71
extern void vo_x11_ewmh_fullscreen( int action );
65
72
66
#endif
73
#endif
67
74

Return to bug 55969