diff options
author | Sebastian Dröge <sebastian@centricular.com> | 2021-03-07 19:22:24 +0300 |
---|---|---|
committer | Sebastian Dröge <sebastian@centricular.com> | 2021-03-07 19:27:00 +0300 |
commit | dc0c5f7611d5896f9fcfa9e141fabe02dea16ea6 (patch) | |
tree | 74d3f6c20a64a3e5fa9c1f4fcff6efb8a1d694d4 /generic/threadshare/src | |
parent | 5dd0a23986352fa363b002c8495951e6a3593673 (diff) |
Update for new #[glib::object_subclass] attribute macro
Diffstat (limited to 'generic/threadshare/src')
-rw-r--r-- | generic/threadshare/src/appsrc/imp.rs | 6 | ||||
-rw-r--r-- | generic/threadshare/src/inputselector/imp.rs | 6 | ||||
-rw-r--r-- | generic/threadshare/src/jitterbuffer/imp.rs | 6 | ||||
-rw-r--r-- | generic/threadshare/src/proxy/imp.rs | 15 | ||||
-rw-r--r-- | generic/threadshare/src/queue/imp.rs | 6 | ||||
-rw-r--r-- | generic/threadshare/src/tcpclientsrc/imp.rs | 6 | ||||
-rw-r--r-- | generic/threadshare/src/udpsink/imp.rs | 6 | ||||
-rw-r--r-- | generic/threadshare/src/udpsrc/imp.rs | 6 |
8 files changed, 9 insertions, 48 deletions
diff --git a/generic/threadshare/src/appsrc/imp.rs b/generic/threadshare/src/appsrc/imp.rs index f264bb30b..c44c659d7 100644 --- a/generic/threadshare/src/appsrc/imp.rs +++ b/generic/threadshare/src/appsrc/imp.rs @@ -22,7 +22,6 @@ use futures::lock::Mutex as FutMutex; use futures::prelude::*; use glib::prelude::*; -use glib::subclass; use glib::subclass::prelude::*; use gst::prelude::*; @@ -504,15 +503,12 @@ impl AppSrc { } } +#[glib::object_subclass] impl ObjectSubclass for AppSrc { const NAME: &'static str = "RsTsAppSrc"; type Type = super::AppSrc; type ParentType = gst::Element; - type Interfaces = (); type Instance = gst::subclass::ElementInstanceStruct<Self>; - type Class = subclass::simple::ClassStruct<Self>; - - glib::object_subclass!(); fn with_class(klass: &Self::Class) -> Self { let src_pad_handler = AppSrcPadHandler::default(); diff --git a/generic/threadshare/src/inputselector/imp.rs b/generic/threadshare/src/inputselector/imp.rs index a490a4641..c625886c3 100644 --- a/generic/threadshare/src/inputselector/imp.rs +++ b/generic/threadshare/src/inputselector/imp.rs @@ -20,7 +20,6 @@ use futures::future::{abortable, AbortHandle}; use futures::prelude::*; use glib::prelude::*; -use glib::subclass; use glib::subclass::prelude::*; use gst::prelude::*; @@ -391,15 +390,12 @@ impl InputSelector { } } +#[glib::object_subclass] impl ObjectSubclass for InputSelector { const NAME: &'static str = "RsTsInputSelector"; type Type = super::InputSelector; type ParentType = gst::Element; - type Interfaces = (); type Instance = gst::subclass::ElementInstanceStruct<Self>; - type Class = subclass::simple::ClassStruct<Self>; - - glib::object_subclass!(); fn with_class(klass: &Self::Class) -> Self { Self { diff --git a/generic/threadshare/src/jitterbuffer/imp.rs b/generic/threadshare/src/jitterbuffer/imp.rs index f679a03b9..1c679ea62 100644 --- a/generic/threadshare/src/jitterbuffer/imp.rs +++ b/generic/threadshare/src/jitterbuffer/imp.rs @@ -20,7 +20,6 @@ use futures::future::{abortable, AbortHandle, Aborted}; use futures::prelude::*; use glib::prelude::*; -use glib::subclass; use glib::subclass::prelude::*; use gst::prelude::*; @@ -1335,15 +1334,12 @@ impl JitterBuffer { } } +#[glib::object_subclass] impl ObjectSubclass for JitterBuffer { const NAME: &'static str = "RsTsJitterBuffer"; type Type = super::JitterBuffer; type ParentType = gst::Element; - type Interfaces = (); type Instance = gst::subclass::ElementInstanceStruct<Self>; - type Class = subclass::simple::ClassStruct<Self>; - - glib::object_subclass!(); fn with_class(klass: &Self::Class) -> Self { let sink_pad_handler = SinkHandler::default(); diff --git a/generic/threadshare/src/proxy/imp.rs b/generic/threadshare/src/proxy/imp.rs index bc13654d4..15e5e1ba6 100644 --- a/generic/threadshare/src/proxy/imp.rs +++ b/generic/threadshare/src/proxy/imp.rs @@ -20,7 +20,6 @@ use futures::future::BoxFuture; use futures::prelude::*; use glib::prelude::*; -use glib::subclass; use glib::subclass::prelude::*; use gst::prelude::*; @@ -572,15 +571,12 @@ impl ProxySink { } } +#[glib::object_subclass] impl ObjectSubclass for ProxySink { const NAME: &'static str = "RsTsProxySink"; type Type = super::ProxySink; - type Interfaces = (); type ParentType = gst::Element; type Instance = gst::subclass::ElementInstanceStruct<Self>; - type Class = subclass::simple::ClassStruct<Self>; - - glib::object_subclass!(); fn with_class(klass: &Self::Class) -> Self { Self { @@ -1113,19 +1109,12 @@ impl ProxySrc { } } +#[glib::object_subclass] impl ObjectSubclass for ProxySrc { const NAME: &'static str = "RsTsProxySrc"; type Type = super::ProxySrc; type ParentType = gst::Element; - type Interfaces = (); type Instance = gst::subclass::ElementInstanceStruct<Self>; - type Class = subclass::simple::ClassStruct<Self>; - - glib::object_subclass!(); - - fn new() -> Self { - unreachable!() - } fn with_class(klass: &Self::Class) -> Self { Self { diff --git a/generic/threadshare/src/queue/imp.rs b/generic/threadshare/src/queue/imp.rs index dd257cadc..3426b3c65 100644 --- a/generic/threadshare/src/queue/imp.rs +++ b/generic/threadshare/src/queue/imp.rs @@ -20,7 +20,6 @@ use futures::future::BoxFuture; use futures::prelude::*; use glib::prelude::*; -use glib::subclass; use glib::subclass::prelude::*; use gst::prelude::*; @@ -692,15 +691,12 @@ impl Queue { } } +#[glib::object_subclass] impl ObjectSubclass for Queue { const NAME: &'static str = "RsTsQueue"; type Type = super::Queue; type ParentType = gst::Element; - type Interfaces = (); type Instance = gst::subclass::ElementInstanceStruct<Self>; - type Class = subclass::simple::ClassStruct<Self>; - - glib::object_subclass!(); fn with_class(klass: &Self::Class) -> Self { Self { diff --git a/generic/threadshare/src/tcpclientsrc/imp.rs b/generic/threadshare/src/tcpclientsrc/imp.rs index 4b584b07e..331dbaa7e 100644 --- a/generic/threadshare/src/tcpclientsrc/imp.rs +++ b/generic/threadshare/src/tcpclientsrc/imp.rs @@ -21,7 +21,6 @@ use futures::lock::Mutex as FutMutex; use futures::prelude::*; use glib::prelude::*; -use glib::subclass; use glib::subclass::prelude::*; use gst::prelude::*; @@ -545,15 +544,12 @@ impl TcpClientSrc { } } +#[glib::object_subclass] impl ObjectSubclass for TcpClientSrc { const NAME: &'static str = "RsTsTcpClientSrc"; type Type = super::TcpClientSrc; type ParentType = gst::Element; - type Interfaces = (); type Instance = gst::subclass::ElementInstanceStruct<Self>; - type Class = subclass::simple::ClassStruct<Self>; - - glib::object_subclass!(); fn with_class(klass: &Self::Class) -> Self { let src_pad_handler = TcpClientSrcPadHandler::default(); diff --git a/generic/threadshare/src/udpsink/imp.rs b/generic/threadshare/src/udpsink/imp.rs index ad1333bfc..477f27b84 100644 --- a/generic/threadshare/src/udpsink/imp.rs +++ b/generic/threadshare/src/udpsink/imp.rs @@ -21,7 +21,6 @@ use futures::lock::Mutex; use futures::prelude::*; use glib::prelude::*; -use glib::subclass; use glib::subclass::prelude::*; use gst::prelude::*; @@ -944,15 +943,12 @@ fn try_into_socket_addr(element: &super::UdpSink, host: &str, port: i32) -> Resu Ok(SocketAddr::new(addr, port)) } +#[glib::object_subclass] impl ObjectSubclass for UdpSink { const NAME: &'static str = "RsTsUdpSink"; type Type = super::UdpSink; type ParentType = gst::Element; - type Interfaces = (); type Instance = gst::subclass::ElementInstanceStruct<Self>; - type Class = subclass::simple::ClassStruct<Self>; - - glib::object_subclass!(); fn with_class(klass: &Self::Class) -> Self { let settings = Arc::new(StdMutex::new(Settings::default())); diff --git a/generic/threadshare/src/udpsrc/imp.rs b/generic/threadshare/src/udpsrc/imp.rs index b8d92e143..07e9d1362 100644 --- a/generic/threadshare/src/udpsrc/imp.rs +++ b/generic/threadshare/src/udpsrc/imp.rs @@ -20,7 +20,6 @@ use futures::lock::Mutex as FutMutex; use futures::prelude::*; use glib::prelude::*; -use glib::subclass; use glib::subclass::prelude::*; use gst::prelude::*; @@ -686,15 +685,12 @@ impl UdpSrc { } } +#[glib::object_subclass] impl ObjectSubclass for UdpSrc { const NAME: &'static str = "RsTsUdpSrc"; type Type = super::UdpSrc; type ParentType = gst::Element; - type Interfaces = (); type Instance = gst::subclass::ElementInstanceStruct<Self>; - type Class = subclass::simple::ClassStruct<Self>; - - glib::object_subclass!(); fn with_class(klass: &Self::Class) -> Self { let src_pad_handler = UdpSrcPadHandler::default(); |