From 2cc98bf410f687a1779edb86dd259f377cca1c7b Mon Sep 17 00:00:00 2001 From: Bilal Elmoussaoui Date: Thu, 6 Jul 2023 15:27:28 +0200 Subject: Adapt to glib::Continue rename Part-of: --- generic/threadshare/examples/benchmark.rs | 2 +- generic/threadshare/examples/standalone/main.rs | 10 +++++----- generic/threadshare/examples/udpsrc_benchmark_sender.rs | 6 +++--- generic/threadshare/tests/pipeline.rs | 16 ++++++++-------- 4 files changed, 17 insertions(+), 17 deletions(-) (limited to 'generic') diff --git a/generic/threadshare/examples/benchmark.rs b/generic/threadshare/examples/benchmark.rs index 3d8a893ce..7f75c6e9f 100644 --- a/generic/threadshare/examples/benchmark.rs +++ b/generic/threadshare/examples/benchmark.rs @@ -211,7 +211,7 @@ fn main() { _ => (), }; - glib::Continue(true) + glib::ControlFlow::Continue }) .expect("Failed to add bus watch"); diff --git a/generic/threadshare/examples/standalone/main.rs b/generic/threadshare/examples/standalone/main.rs index 7498b6536..1cc43e298 100644 --- a/generic/threadshare/examples/standalone/main.rs +++ b/generic/threadshare/examples/standalone/main.rs @@ -116,7 +116,7 @@ fn main() { gst::info!(CAT, "Received eos"); l_clone.quit(); - glib::Continue(false) + glib::ControlFlow::Break } MessageView::Error(msg) => { if let gst::MessageView::Error(msg) = msg.message().view() { @@ -125,9 +125,9 @@ fn main() { gst::info!(CAT, "Received all shutdown requests"); l_clone.quit(); - return glib::Continue(false); + return glib::ControlFlow::Break; } else { - return glib::Continue(true); + return glib::ControlFlow::Continue; } } } @@ -141,9 +141,9 @@ fn main() { ); l_clone.quit(); - glib::Continue(false) + glib::ControlFlow::Break } - _ => glib::Continue(true), + _ => glib::ControlFlow::Continue, } }) .expect("Failed to add bus watch"); diff --git a/generic/threadshare/examples/udpsrc_benchmark_sender.rs b/generic/threadshare/examples/udpsrc_benchmark_sender.rs index bb7ce23fb..42130ba47 100644 --- a/generic/threadshare/examples/udpsrc_benchmark_sender.rs +++ b/generic/threadshare/examples/udpsrc_benchmark_sender.rs @@ -178,7 +178,7 @@ fn run(pipeline: gst::Pipeline) { gst::info!(CAT, "Received eos"); l_clone.quit(); - glib::Continue(false) + glib::ControlFlow::Break } MessageView::Error(msg) => { gst::error!( @@ -190,9 +190,9 @@ fn run(pipeline: gst::Pipeline) { ); l_clone.quit(); - glib::Continue(false) + glib::ControlFlow::Break } - _ => glib::Continue(true), + _ => glib::ControlFlow::Continue, } }) .expect("Failed to add bus watch"); diff --git a/generic/threadshare/tests/pipeline.rs b/generic/threadshare/tests/pipeline.rs index d27eef6e9..5e12d6b38 100644 --- a/generic/threadshare/tests/pipeline.rs +++ b/generic/threadshare/tests/pipeline.rs @@ -165,7 +165,7 @@ fn multiple_contexts_queue() { _ => (), }; - glib::Continue(true) + glib::ControlFlow::Continue }) .unwrap(); @@ -312,7 +312,7 @@ fn multiple_contexts_proxy() { _ => (), }; - glib::Continue(true) + glib::ControlFlow::Continue }) .unwrap(); @@ -417,7 +417,7 @@ fn eos() { MessageView::StateChanged(state_changed) => { if let Some(source) = state_changed.src() { if source.type_() != gst::Pipeline::static_type() { - return glib::Continue(true); + return glib::ControlFlow::Continue; } if state_changed.old() == gst::State::Paused && state_changed.current() == gst::State::Playing @@ -441,7 +441,7 @@ fn eos() { _ => (), }; - glib::Continue(true) + glib::ControlFlow::Continue }) .unwrap(); @@ -573,7 +573,7 @@ fn premature_shutdown() { MessageView::StateChanged(state_changed) => { if let Some(source) = state_changed.src() { if source.type_() != gst::Pipeline::static_type() { - return glib::Continue(true); + return glib::ControlFlow::Continue; } if state_changed.old() == gst::State::Paused && state_changed.current() == gst::State::Playing @@ -597,7 +597,7 @@ fn premature_shutdown() { _ => (), }; - glib::Continue(true) + glib::ControlFlow::Continue }) .unwrap(); @@ -669,7 +669,7 @@ fn socket_play_null_play() { MessageView::StateChanged(state_changed) => { if let Some(source) = state_changed.src() { if source.type_() != gst::Pipeline::static_type() { - return glib::Continue(true); + return glib::ControlFlow::Continue; } if state_changed.old() == gst::State::Paused && state_changed.current() == gst::State::Playing @@ -694,7 +694,7 @@ fn socket_play_null_play() { _ => (), }; - glib::Continue(true) + glib::ControlFlow::Continue }) .unwrap(); -- cgit v1.2.3