mirror of
https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs.git
synced 2025-01-01 23:08:42 +00:00
examples: Update for glib API changes
Timeouts now use std::time::Duration instead of plain integers.
This commit is contained in:
parent
dc8b722f72
commit
3b5d9b7392
2 changed files with 2 additions and 2 deletions
|
@ -126,7 +126,7 @@ fn create_ui(app: >k::Application) {
|
||||||
app.add_window(&window);
|
app.add_window(&window);
|
||||||
|
|
||||||
let video_sink_weak = video_sink.downgrade();
|
let video_sink_weak = video_sink.downgrade();
|
||||||
let timeout_id = glib::timeout_add_local(100, move || {
|
let timeout_id = glib::timeout_add_local(std::time::Duration::from_millis(100), move || {
|
||||||
let video_sink = match video_sink_weak.upgrade() {
|
let video_sink = match video_sink_weak.upgrade() {
|
||||||
Some(video_sink) => video_sink,
|
Some(video_sink) => video_sink,
|
||||||
None => return glib::Continue(true),
|
None => return glib::Continue(true),
|
||||||
|
|
|
@ -232,7 +232,7 @@ fn create_ui(app: >k::Application) {
|
||||||
|
|
||||||
let video_sink_weak = video_sink.downgrade();
|
let video_sink_weak = video_sink.downgrade();
|
||||||
let togglerecord_weak = togglerecord.downgrade();
|
let togglerecord_weak = togglerecord.downgrade();
|
||||||
let timeout_id = glib::timeout_add_local(100, move || {
|
let timeout_id = glib::timeout_add_local(std::time::Duration::from_millis(100), move || {
|
||||||
let video_sink = match video_sink_weak.upgrade() {
|
let video_sink = match video_sink_weak.upgrade() {
|
||||||
Some(video_sink) => video_sink,
|
Some(video_sink) => video_sink,
|
||||||
None => return glib::Continue(true),
|
None => return glib::Continue(true),
|
||||||
|
|
Loading…
Reference in a new issue