examples/: Sync with the X server before giving an XID to our sink with a different display connection. This avoids s...

Original commit message from CVS:
* examples/play.py:
* examples/remuxer.py:
* examples/switch.py:
* examples/synchronizer.py:
Sync with the X server before giving an XID to our sink with a different
display connection. This avoids spurious X servers where the sink's
display connection doesn't know the XID that the GDK thread's does.
This commit is contained in:
Jan Schmidt 2008-04-24 11:35:38 +00:00
parent 18e711131e
commit 839bc5b0d4
6 changed files with 19 additions and 1 deletions

View file

@ -1,3 +1,13 @@
2008-04-24 Jan Schmidt <Jan.Schmidt@sun.com>
* examples/play.py:
* examples/remuxer.py:
* examples/switch.py:
* examples/synchronizer.py:
Sync with the X server before giving an XID to our sink with a different
display connection. This avoids spurious X servers where the sink's
display connection doesn't know the XID that the GDK thread's does.
2008-04-06 Sebastian Dröge <slomo@circular-chaos.org>
Patch by: Damien Lespiau <damien dot lespiau at gmail dot com>

2
common

@ -1 +1 @@
Subproject commit fda6da5f2b9b000f7e1df8ffb44a6185ffd9799b
Subproject commit f6fc3fa7643c03eb912f4e259d48c99b0e8d0aca

View file

@ -32,6 +32,8 @@ class GstPlayer:
if message.structure is None:
return
if message.structure.get_name() == 'prepare-xwindow-id':
# Sync with the X server before giving the X-id to the sink
gtk.gdk.display_get_default().sync()
self.videowidget.set_sink(message.src)
message.src.set_property('force-aspect-ratio', True)

View file

@ -32,6 +32,8 @@ class GstPlayer:
if message.structure is None:
return
if message.structure.get_name() == 'prepare-xwindow-id':
# Sync with the X server before giving the X-id to the sink
gtk.gdk.display_get_default().sync()
self.videowidget.set_sink(message.src)
message.src.set_property('force-aspect-ratio', True)

View file

@ -35,6 +35,8 @@ class SwitchTest:
if message.structure is None:
return
if message.structure.get_name() == 'prepare-xwindow-id':
# Sync with the X server before giving the X-id to the sink
gtk.gdk.display_get_default().sync()
self.videowidget.set_sink(message.src)
message.src.set_property('force-aspect-ratio', True)

View file

@ -32,6 +32,8 @@ class GstPlayer:
if message.structure is None:
return
if message.structure.get_name() == 'prepare-xwindow-id':
# Sync with the X server before giving the X-id to the sink
gtk.gdk.display_get_default().sync()
self.videowidget.set_sink(message.src)
message.src.set_property('force-aspect-ratio', True)