mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer-rs.git
synced 2024-12-28 19:10:34 +00:00
Make use of Bus::add_watch_local()
This commit is contained in:
parent
e6992345cc
commit
f2d79fb352
2 changed files with 4 additions and 4 deletions
|
@ -112,8 +112,8 @@ fn create_ui(app: >k::Application) {
|
|||
.set_state(gst::State::Playing)
|
||||
.expect("Unable to set the pipeline to the `Playing` state");
|
||||
|
||||
let app_weak = glib::SendWeakRef::from(app.downgrade());
|
||||
bus.add_watch(move |_, msg| {
|
||||
let app_weak = app.downgrade();
|
||||
bus.add_watch_local(move |_, msg| {
|
||||
use gst::MessageView;
|
||||
|
||||
let app = match app_weak.upgrade() {
|
||||
|
|
|
@ -215,8 +215,8 @@ fn create_ui(app: >k::Application) {
|
|||
.set_state(gst::State::Playing)
|
||||
.expect("Unable to set the pipeline to the `Playing` state");
|
||||
|
||||
let app_weak = glib::SendWeakRef::from(app.downgrade());
|
||||
bus.add_watch(move |_, msg| {
|
||||
let app_weak = app.downgrade();
|
||||
bus.add_watch_local(move |_, msg| {
|
||||
use gst::MessageView;
|
||||
|
||||
let app = match app_weak.upgrade() {
|
||||
|
|
Loading…
Reference in a new issue