mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-27 12:11:13 +00:00
examples: Call gst_ensure_native_window() for gst-camera
Fixes spurious SEGVs due to multithreading conflicts in client-side-window Gtk versions.
This commit is contained in:
parent
a04c2db340
commit
e54cbf7850
2 changed files with 9 additions and 0 deletions
|
@ -832,6 +832,14 @@ on_buttonPause_clicked (GtkButton * button, gpointer user_data)
|
|||
}
|
||||
}
|
||||
|
||||
void
|
||||
on_drawingareaView_realize (GtkWidget * widget, gpointer data)
|
||||
{
|
||||
#if GTK_CHECK_VERSION (2, 18, 0)
|
||||
gdk_window_ensure_native (widget->window);
|
||||
#endif
|
||||
}
|
||||
|
||||
gboolean
|
||||
on_drawingareaView_configure_event (GtkWidget * widget,
|
||||
GdkEventConfigure * event, gpointer data)
|
||||
|
|
|
@ -374,6 +374,7 @@
|
|||
<property name="visible">True</property>
|
||||
<property name="events">GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK</property>
|
||||
<signal name="configure_event" handler="on_drawingareaView_configure_event"/>
|
||||
<signal name="realize" handler="on_drawingareaView_realize"/>
|
||||
</object>
|
||||
</child>
|
||||
</object>
|
||||
|
|
Loading…
Reference in a new issue