Mercurial > mplayer.hg
comparison libvo/vo_xv.c @ 844:108ea5157cbc
didn't handle flags parameter correctly
author | arpi_esp |
---|---|
date | Sun, 20 May 2001 21:49:45 +0000 |
parents | c3e0bdb64027 |
children | db06ae8967eb |
comparison
equal
deleted
inserted
replaced
843:a88b87750b8a | 844:108ea5157cbc |
---|---|
91 | 91 |
92 /* | 92 /* |
93 * connect to server, create and map window, | 93 * connect to server, create and map window, |
94 * allocate colors and (shared) memory | 94 * allocate colors and (shared) memory |
95 */ | 95 */ |
96 static uint32_t init(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t fullscreen, char *title, uint32_t format) | 96 static uint32_t init(uint32_t width, uint32_t height, uint32_t d_width, uint32_t d_height, uint32_t flags, char *title, uint32_t format) |
97 { | 97 { |
98 int screen; | 98 int screen; |
99 char *hello = (title == NULL) ? "Xv render" : title; | 99 char *hello = (title == NULL) ? "Xv render" : title; |
100 char *name = ":0.0"; | 100 char *name = ":0.0"; |
101 XSizeHints hint; | 101 XSizeHints hint; |
108 | 108 |
109 image_height = height; | 109 image_height = height; |
110 image_width = width; | 110 image_width = width; |
111 image_format=format; | 111 image_format=format; |
112 | 112 |
113 mFullscreen=fullscreen; | 113 mFullscreen=flags&1; |
114 dwidth=d_width; dheight=d_height; | 114 dwidth=d_width; dheight=d_height; |
115 | 115 |
116 if(getenv("DISPLAY")) name = getenv("DISPLAY"); | 116 if(getenv("DISPLAY")) name = getenv("DISPLAY"); |
117 | 117 |
118 mydisplay = XOpenDisplay(name); | 118 mydisplay = XOpenDisplay(name); |
131 #endif | 131 #endif |
132 hint.x = 0; | 132 hint.x = 0; |
133 hint.y = 0; | 133 hint.y = 0; |
134 hint.width = d_width; | 134 hint.width = d_width; |
135 hint.height = d_height; | 135 hint.height = d_height; |
136 if ( fullscreen ) | 136 if ( mFullscreen ) |
137 { | 137 { |
138 hint.width=vo_screenwidth; | 138 hint.width=vo_screenwidth; |
139 hint.height=vo_screenheight; | 139 hint.height=vo_screenheight; |
140 } | 140 } |
141 hint.flags = PPosition | PSize; | 141 hint.flags = PPosition | PSize; |
153 0, depth,CopyFromParent,vinfo.visual,xswamask,&xswa); | 153 0, depth,CopyFromParent,vinfo.visual,xswamask,&xswa); |
154 vo_hidecursor(mydisplay,mywindow); | 154 vo_hidecursor(mydisplay,mywindow); |
155 | 155 |
156 XSelectInput(mydisplay, mywindow, StructureNotifyMask | KeyPressMask ); | 156 XSelectInput(mydisplay, mywindow, StructureNotifyMask | KeyPressMask ); |
157 XSetStandardProperties(mydisplay, mywindow, hello, hello, None, NULL, 0, &hint); | 157 XSetStandardProperties(mydisplay, mywindow, hello, hello, None, NULL, 0, &hint); |
158 if ( fullscreen ) vo_x11_decoration( mydisplay,mywindow,0 ); | 158 if ( mFullscreen ) vo_x11_decoration( mydisplay,mywindow,0 ); |
159 XMapWindow(mydisplay, mywindow); | 159 XMapWindow(mydisplay, mywindow); |
160 XFlush(mydisplay); | 160 XFlush(mydisplay); |
161 XSync(mydisplay, False); | 161 XSync(mydisplay, False); |
162 #ifdef HAVE_GUI | 162 #ifdef HAVE_GUI |
163 } | 163 } |