Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.freedesktop.org/gstreamer/gst-plugins-rs.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/video
diff options
context:
space:
mode:
authorBilal Elmoussaoui <belmouss@redhat.com>2023-07-06 16:27:28 +0300
committerSebastian Dröge <sebastian@centricular.com>2023-07-06 17:50:49 +0300
commit2cc98bf410f687a1779edb86dd259f377cca1c7b (patch)
treedf2485024782e1ad972415a5ae43d807132fa8fe /video
parent64151790d0a8b1d0594b6740ff43bf85504c32aa (diff)
Adapt to glib::Continue rename
Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs/-/merge_requests/1268>
Diffstat (limited to 'video')
-rw-r--r--video/gtk4/examples/gtksink.rs8
-rw-r--r--video/gtk4/src/sink/imp.rs8
2 files changed, 8 insertions, 8 deletions
diff --git a/video/gtk4/examples/gtksink.rs b/video/gtk4/examples/gtksink.rs
index 2346a8cd3..aadc9205c 100644
--- a/video/gtk4/examples/gtksink.rs
+++ b/video/gtk4/examples/gtksink.rs
@@ -77,12 +77,12 @@ fn create_ui(app: &gtk::Application) {
let timeout_id = glib::timeout_add_local(std::time::Duration::from_millis(500), move || {
let pipeline = match pipeline_weak.upgrade() {
Some(pipeline) => pipeline,
- None => return glib::Continue(true),
+ None => return glib::ControlFlow::Continue,
};
let position = pipeline.query_position::<gst::ClockTime>();
label.set_text(&format!("Position: {:.0}", position.display()));
- glib::Continue(true)
+ glib::ControlFlow::Continue
});
let bus = pipeline.bus().unwrap();
@@ -98,7 +98,7 @@ fn create_ui(app: &gtk::Application) {
let app = match app_weak.upgrade() {
Some(app) => app,
- None => return glib::Continue(false),
+ None => return glib::ControlFlow::Break,
};
match msg.view() {
@@ -115,7 +115,7 @@ fn create_ui(app: &gtk::Application) {
_ => (),
};
- glib::Continue(true)
+ glib::ControlFlow::Continue
})
.expect("Failed to add bus watch");
diff --git a/video/gtk4/src/sink/imp.rs b/video/gtk4/src/sink/imp.rs
index 4d66d4a47..b74b8d7e5 100644
--- a/video/gtk4/src/sink/imp.rs
+++ b/video/gtk4/src/sink/imp.rs
@@ -452,11 +452,11 @@ impl PaintableSink {
self.pending_frame.lock().unwrap().take()
}
- fn do_action(&self, action: SinkEvent) -> glib::Continue {
+ fn do_action(&self, action: SinkEvent) -> glib::ControlFlow {
let paintable = self.paintable.lock().unwrap();
let paintable = match &*paintable {
Some(paintable) => paintable,
- None => return glib::Continue(false),
+ None => return glib::ControlFlow::Break,
};
match action {
@@ -468,7 +468,7 @@ impl PaintableSink {
}
}
- glib::Continue(true)
+ glib::ControlFlow::Continue
}
fn configure_caps(&self) {
@@ -519,7 +519,7 @@ impl PaintableSink {
receiver.attach(
Some(&glib::MainContext::default()),
glib::clone!(
- @weak self_ => @default-return glib::Continue(false),
+ @weak self_ => @default-return glib::ControlFlow::Break,
move |action| self_.do_action(action)
),
);