Update for GLib ParamSpec builder API changes

This commit is contained in:
Sebastian Dröge 2022-09-05 11:45:47 +03:00
parent 3924e2e563
commit 1a40186485
32 changed files with 75 additions and 93 deletions

View file

@ -144,10 +144,10 @@ impl ObjectImpl for EbuR128Level {
fn properties() -> &'static [glib::ParamSpec] { fn properties() -> &'static [glib::ParamSpec] {
static PROPERTIES: Lazy<Vec<glib::ParamSpec>> = Lazy::new(|| { static PROPERTIES: Lazy<Vec<glib::ParamSpec>> = Lazy::new(|| {
vec![ vec![
glib::ParamSpecFlags::builder("mode", Mode::static_type()) glib::ParamSpecFlags::builder::<Mode>("mode")
.nick("Mode") .nick("Mode")
.blurb("Selection of metrics to calculate") .blurb("Selection of metrics to calculate")
.default_value(DEFAULT_MODE.bits() as u32) .default_value(DEFAULT_MODE)
.mutable_ready() .mutable_ready()
.build(), .build(),
glib::ParamSpecBoolean::builder("post-messages") glib::ParamSpecBoolean::builder("post-messages")

View file

@ -404,7 +404,7 @@ impl ObjectImpl for HrtfRender {
fn properties() -> &'static [glib::ParamSpec] { fn properties() -> &'static [glib::ParamSpec] {
static PROPERTIES: Lazy<Vec<glib::ParamSpec>> = Lazy::new(|| { static PROPERTIES: Lazy<Vec<glib::ParamSpec>> = Lazy::new(|| {
vec![ vec![
glib::ParamSpecBoxed::builder("hrir-raw", glib::Bytes::static_type()) glib::ParamSpecBoxed::builder::<glib::Bytes>("hrir-raw")
.nick("Head Transform Impulse Response") .nick("Head Transform Impulse Response")
.blurb("Head Transform Impulse Response raw bytes") .blurb("Head Transform Impulse Response raw bytes")
.mutable_ready() .mutable_ready()
@ -430,13 +430,10 @@ impl ObjectImpl for HrtfRender {
.build(), .build(),
gst::ParamSpecArray::builder("spatial-objects") gst::ParamSpecArray::builder("spatial-objects")
.element_spec( .element_spec(
&glib::ParamSpecBoxed::builder( &glib::ParamSpecBoxed::builder::<gst::Structure>("spatial-object")
"spatial-object", .nick("Spatial Object")
gst::Structure::static_type(), .blurb("Spatial Object Metadata")
) .build(),
.nick("Spatial Object")
.blurb("Spatial Object Metadata")
.build(),
) )
.nick("Spatial Objects") .nick("Spatial Objects")
.blurb("Spatial object Metadata to apply on input channels") .blurb("Spatial object Metadata to apply on input channels")

View file

@ -1550,10 +1550,9 @@ impl ObjectImpl for FMP4Mux {
.default_value(DEFAULT_FRAGMENT_DURATION.nseconds()) .default_value(DEFAULT_FRAGMENT_DURATION.nseconds())
.mutable_ready() .mutable_ready()
.build(), .build(),
glib::ParamSpecEnum::builder("header-update-mode", super::HeaderUpdateMode::static_type()) glib::ParamSpecEnum::builder::<super::HeaderUpdateMode>("header-update-mode", DEFAULT_HEADER_UPDATE_MODE)
.nick("Header update mode") .nick("Header update mode")
.blurb("Mode for updating the header at the end of the stream") .blurb("Mode for updating the header at the end of the stream")
.default_value(DEFAULT_HEADER_UPDATE_MODE as i32)
.mutable_ready() .mutable_ready()
.build(), .build(),
glib::ParamSpecBoolean::builder("write-mfra") glib::ParamSpecBoolean::builder("write-mfra")

View file

@ -597,11 +597,11 @@ impl ObjectImpl for Decrypter {
fn properties() -> &'static [glib::ParamSpec] { fn properties() -> &'static [glib::ParamSpec] {
static PROPERTIES: Lazy<Vec<glib::ParamSpec>> = Lazy::new(|| { static PROPERTIES: Lazy<Vec<glib::ParamSpec>> = Lazy::new(|| {
vec![ vec![
glib::ParamSpecBoxed::builder("receiver-key", glib::Bytes::static_type()) glib::ParamSpecBoxed::builder::<glib::Bytes>("receiver-key")
.nick("Receiver Key") .nick("Receiver Key")
.blurb("The private key of the Receiver") .blurb("The private key of the Receiver")
.build(), .build(),
glib::ParamSpecBoxed::builder("sender-key", glib::Bytes::static_type()) glib::ParamSpecBoxed::builder::<glib::Bytes>("sender-key")
.nick("Sender Key") .nick("Sender Key")
.blurb("The public key of the Sender") .blurb("The public key of the Sender")
.write_only() .write_only()

View file

@ -389,11 +389,11 @@ impl ObjectImpl for Encrypter {
fn properties() -> &'static [glib::ParamSpec] { fn properties() -> &'static [glib::ParamSpec] {
static PROPERTIES: Lazy<Vec<glib::ParamSpec>> = Lazy::new(|| { static PROPERTIES: Lazy<Vec<glib::ParamSpec>> = Lazy::new(|| {
vec![ vec![
glib::ParamSpecBoxed::builder("receiver-key", glib::Bytes::static_type()) glib::ParamSpecBoxed::builder::<glib::Bytes>("receiver-key")
.nick("Receiver Key") .nick("Receiver Key")
.blurb("The public key of the Receiver") .blurb("The public key of the Receiver")
.build(), .build(),
glib::ParamSpecBoxed::builder("sender-key", glib::Bytes::static_type()) glib::ParamSpecBoxed::builder::<glib::Bytes>("sender-key")
.nick("Sender Key") .nick("Sender Key")
.blurb("The private key of the Sender") .blurb("The private key of the Sender")
.write_only() .write_only()

View file

@ -476,7 +476,7 @@ impl ObjectImpl for AppSrc {
.minimum(1) .minimum(1)
.default_value(DEFAULT_MAX_BUFFERS) .default_value(DEFAULT_MAX_BUFFERS)
.build(), .build(),
glib::ParamSpecBoxed::builder("caps", gst::Caps::static_type()) glib::ParamSpecBoxed::builder::<gst::Caps>("caps")
.nick("Caps") .nick("Caps")
.blurb("Caps to use") .blurb("Caps to use")
.build(), .build(),

View file

@ -419,7 +419,7 @@ impl ObjectImpl for InputSelector {
.default_value(DEFAULT_CONTEXT_WAIT.as_millis() as u32) .default_value(DEFAULT_CONTEXT_WAIT.as_millis() as u32)
.readwrite() .readwrite()
.build(), .build(),
glib::ParamSpecObject::builder("active-pad", gst::Pad::static_type()) glib::ParamSpecObject::builder::<gst::Pad>("active-pad")
.nick("Active Pad") .nick("Active Pad")
.blurb("Currently active pad") .blurb("Currently active pad")
.readwrite() .readwrite()

View file

@ -1393,7 +1393,7 @@ impl ObjectImpl for JitterBuffer {
.blurb("The maximum time (milliseconds) of misordered packets tolerated.") .blurb("The maximum time (milliseconds) of misordered packets tolerated.")
.default_value(DEFAULT_MAX_MISORDER_TIME) .default_value(DEFAULT_MAX_MISORDER_TIME)
.build(), .build(),
glib::ParamSpecBoxed::builder("stats", gst::Structure::static_type()) glib::ParamSpecBoxed::builder::<gst::Structure>("stats")
.nick("Statistics") .nick("Statistics")
.blurb("Various statistics") .blurb("Various statistics")
.read_only() .read_only()

View file

@ -543,7 +543,7 @@ impl ObjectImpl for TcpClientSrc {
.maximum(u16::MAX as i32) .maximum(u16::MAX as i32)
.default_value(DEFAULT_PORT) .default_value(DEFAULT_PORT)
.build(), .build(),
glib::ParamSpecBoxed::builder("caps", gst::Caps::static_type()) glib::ParamSpecBoxed::builder::<gst::Caps>("caps")
.nick("Caps") .nick("Caps")
.blurb("Caps to use") .blurb("Caps to use")
.build(), .build(),

View file

@ -1003,20 +1003,20 @@ impl ObjectImpl for UdpSink {
.maximum(u16::MAX as i32) .maximum(u16::MAX as i32)
.default_value(DEFAULT_BIND_PORT_V6) .default_value(DEFAULT_BIND_PORT_V6)
.build(), .build(),
glib::ParamSpecObject::builder("socket", gio::Socket::static_type()) glib::ParamSpecObject::builder::<gio::Socket>("socket")
.nick("Socket") .nick("Socket")
.blurb("Socket to use for UDP transmission. (None == allocate)") .blurb("Socket to use for UDP transmission. (None == allocate)")
.build(), .build(),
glib::ParamSpecObject::builder("used-socket", gio::Socket::static_type()) glib::ParamSpecObject::builder::<gio::Socket>("used-socket")
.nick("Used Socket") .nick("Used Socket")
.blurb("Socket currently in use for UDP transmission. (None = no socket)") .blurb("Socket currently in use for UDP transmission. (None = no socket)")
.read_only() .read_only()
.build(), .build(),
glib::ParamSpecObject::builder("socket-v6", gio::Socket::static_type()) glib::ParamSpecObject::builder::<gio::Socket>("socket-v6")
.nick("Socket V6") .nick("Socket V6")
.blurb("IPV6 Socket to use for UDP transmission. (None == allocate)") .blurb("IPV6 Socket to use for UDP transmission. (None == allocate)")
.build(), .build(),
glib::ParamSpecObject::builder("used-socket-v6", gio::Socket::static_type()) glib::ParamSpecObject::builder::<gio::Socket>("used-socket-v6")
.nick("Used Socket V6") .nick("Used Socket V6")
.blurb("V6 Socket currently in use for UDP transmission. (None = no socket)") .blurb("V6 Socket currently in use for UDP transmission. (None = no socket)")
.read_only() .read_only()

View file

@ -676,7 +676,7 @@ impl ObjectImpl for UdpSrc {
.blurb("Allow reuse of the port") .blurb("Allow reuse of the port")
.default_value(DEFAULT_REUSE) .default_value(DEFAULT_REUSE)
.build(), .build(),
glib::ParamSpecBoxed::builder("caps", gst::Caps::static_type()) glib::ParamSpecBoxed::builder::<gst::Caps>("caps")
.nick("Caps") .nick("Caps")
.blurb("Caps to use") .blurb("Caps to use")
.build(), .build(),
@ -696,13 +696,13 @@ impl ObjectImpl for UdpSrc {
#[cfg(not(windows))] #[cfg(not(windows))]
{ {
properties.push( properties.push(
glib::ParamSpecObject::builder("socket", gio::Socket::static_type()) glib::ParamSpecObject::builder::<gio::Socket>("socket")
.nick("Socket") .nick("Socket")
.blurb("Socket to use for UDP reception. (None == allocate)") .blurb("Socket to use for UDP reception. (None == allocate)")
.build(), .build(),
); );
properties.push( properties.push(
glib::ParamSpecObject::builder("used-socket", gio::Socket::static_type()) glib::ParamSpecObject::builder::<gio::Socket>("used-socket")
.nick("Used Socket") .nick("Used Socket")
.blurb("Socket currently in use for UDP reception. (None = no socket)") .blurb("Socket currently in use for UDP reception. (None = no socket)")
.read_only() .read_only()

View file

@ -636,14 +636,12 @@ mod imp_sink {
impl ObjectImpl for ElementSinkTest { impl ObjectImpl for ElementSinkTest {
fn properties() -> &'static [glib::ParamSpec] { fn properties() -> &'static [glib::ParamSpec] {
static PROPERTIES: Lazy<Vec<glib::ParamSpec>> = Lazy::new(|| { static PROPERTIES: Lazy<Vec<glib::ParamSpec>> = Lazy::new(|| {
vec![ vec![glib::ParamSpecBoxed::builder::<ItemSender>("sender")
glib::ParamSpecBoxed::builder("sender", ItemSender::static_type()) .nick("Sender")
.nick("Sender") .blurb("Channel sender to forward the incoming items to")
.blurb("Channel sender to forward the incoming items to") .write_only()
.write_only() .construct_only()
.construct_only() .build()]
.build(),
]
}); });
PROPERTIES.as_ref() PROPERTIES.as_ref()

View file

@ -1210,10 +1210,9 @@ impl ObjectImpl for Transcriber {
.blurb("The ID of the transcription session, must be length 36") .blurb("The ID of the transcription session, must be length 36")
.mutable_ready() .mutable_ready()
.build(), .build(),
glib::ParamSpecEnum::builder("results-stability", AwsTranscriberResultStability::static_type()) glib::ParamSpecEnum::builder::<AwsTranscriberResultStability>("results-stability", DEFAULT_STABILITY)
.nick("Results stability") .nick("Results stability")
.blurb("Defines how fast results should stabilize") .blurb("Defines how fast results should stabilize")
.default_value(DEFAULT_STABILITY as i32)
.mutable_ready() .mutable_ready()
.build(), .build(),
glib::ParamSpecString::builder("access-key") glib::ParamSpecString::builder("access-key")
@ -1238,10 +1237,9 @@ impl ObjectImpl for Transcriber {
for more information") for more information")
.mutable_ready() .mutable_ready()
.build(), .build(),
glib::ParamSpecEnum::builder("vocabulary-filter-method", AwsTranscriberVocabularyFilterMethod::static_type()) glib::ParamSpecEnum::builder::<AwsTranscriberVocabularyFilterMethod>("vocabulary-filter-method", DEFAULT_VOCABULARY_FILTER_METHOD)
.nick("Vocabulary Filter Method") .nick("Vocabulary Filter Method")
.blurb("Defines how filtered words will be edited, has no effect when vocabulary-filter-name isn't set") .blurb("Defines how filtered words will be edited, has no effect when vocabulary-filter-name isn't set")
.default_value(DEFAULT_VOCABULARY_FILTER_METHOD as i32)
.mutable_ready() .mutable_ready()
.build(), .build(),
] ]

View file

@ -463,7 +463,7 @@ impl ObjectImpl for S3HlsSink {
.blurb("The AWS region for the S3 bucket (e.g. eu-west-2).") .blurb("The AWS region for the S3 bucket (e.g. eu-west-2).")
.mutable_ready() .mutable_ready()
.build(), .build(),
glib::ParamSpecObject::builder("hlssink", gst::Element::static_type()) glib::ParamSpecObject::builder::<gst::Element>("hlssink")
.nick("HLS Sink") .nick("HLS Sink")
.blurb("The underlying HLS sink being used") .blurb("The underlying HLS sink being used")
.read_only() .read_only()

View file

@ -701,15 +701,14 @@ impl ObjectImpl for S3Sink {
.blurb("AWS temporary Session Token from STS") .blurb("AWS temporary Session Token from STS")
.mutable_ready() .mutable_ready()
.build(), .build(),
glib::ParamSpecBoxed::builder("metadata", gst::Structure::static_type()) glib::ParamSpecBoxed::builder::<gst::Structure>("metadata")
.nick("Metadata") .nick("Metadata")
.blurb("A map of metadata to store with the object in S3; field values need to be convertible to strings.") .blurb("A map of metadata to store with the object in S3; field values need to be convertible to strings.")
.mutable_ready() .mutable_ready()
.build(), .build(),
glib::ParamSpecEnum::builder("on-error", OnError::static_type()) glib::ParamSpecEnum::builder::<OnError>("on-error", DEFAULT_MULTIPART_UPLOAD_ON_ERROR)
.nick("Whether to upload or complete the multipart upload on error") .nick("Whether to upload or complete the multipart upload on error")
.blurb("Do nothing, abort or complete a multipart upload request on error") .blurb("Do nothing, abort or complete a multipart upload request on error")
.default_value(DEFAULT_MULTIPART_UPLOAD_ON_ERROR as i32)
.mutable_ready() .mutable_ready()
.build(), .build(),
glib::ParamSpecUInt::builder("retry-attempts") glib::ParamSpecUInt::builder("retry-attempts")

View file

@ -456,10 +456,9 @@ impl ObjectImpl for HlsSink3 {
.blurb("Length of HLS playlist. To allow players to conform to section 6.3.3 of the HLS specification, this should be at least 3. If set to 0, the playlist will be infinite.") .blurb("Length of HLS playlist. To allow players to conform to section 6.3.3 of the HLS specification, this should be at least 3. If set to 0, the playlist will be infinite.")
.default_value(DEFAULT_PLAYLIST_LENGTH) .default_value(DEFAULT_PLAYLIST_LENGTH)
.build(), .build(),
glib::ParamSpecEnum::builder("playlist-type", HlsSink3PlaylistType::static_type()) glib::ParamSpecEnum::builder::<HlsSink3PlaylistType>("playlist-type", DEFAULT_PLAYLIST_TYPE)
.nick("Playlist Type") .nick("Playlist Type")
.blurb("The type of the playlist to use. When VOD type is set, the playlist will be live until the pipeline ends execution.") .blurb("The type of the playlist to use. When VOD type is set, the playlist will be live until the pipeline ends execution.")
.default_value(DEFAULT_PLAYLIST_TYPE as i32)
.build(), .build(),
glib::ParamSpecBoolean::builder("send-keyframe-requests") glib::ParamSpecBoolean::builder("send-keyframe-requests")
.nick("Send Keyframe Requests") .nick("Send Keyframe Requests")

View file

@ -677,7 +677,7 @@ impl ObjectImpl for RaptorqDec {
.default_value(DEFAULT_MEDIA_PACKETS_RESET_THRESHOLD) .default_value(DEFAULT_MEDIA_PACKETS_RESET_THRESHOLD)
.mutable_ready() .mutable_ready()
.build(), .build(),
glib::ParamSpecBoxed::builder("stats", gst::Structure::static_type()) glib::ParamSpecBoxed::builder::<gst::Structure>("stats")
.nick("Statistics") .nick("Statistics")
.blurb("Various statistics") .blurb("Various statistics")
.read_only() .read_only()

View file

@ -674,7 +674,7 @@ impl ObjectImpl for ReqwestHttpSrc {
let mut user_agent_pspec = glib::ParamSpecString::builder("user-agent") let mut user_agent_pspec = glib::ParamSpecString::builder("user-agent")
.nick("User-Agent") .nick("User-Agent")
.blurb("Value of the User-Agent HTTP request header field") .blurb("Value of the User-Agent HTTP request header field")
.default_value("GStreamer reqwesthttpsrc".into()) .default_value("GStreamer reqwesthttpsrc")
.readwrite() .readwrite()
.readwrite() .readwrite()
.mutable_ready(); .mutable_ready();
@ -726,13 +726,13 @@ impl ObjectImpl for ReqwestHttpSrc {
.readwrite() .readwrite()
.mutable_ready() .mutable_ready()
.build(), .build(),
glib::ParamSpecBoxed::builder("extra-headers", gst::Structure::static_type()) glib::ParamSpecBoxed::builder::<gst::Structure>("extra-headers")
.nick("Extra Headers") .nick("Extra Headers")
.blurb("Extra headers to append to the HTTP request") .blurb("Extra headers to append to the HTTP request")
.readwrite() .readwrite()
.mutable_ready() .mutable_ready()
.build(), .build(),
glib::ParamSpecBoxed::builder("cookies", Vec::<String>::static_type()) glib::ParamSpecBoxed::builder::<Vec<String>>("cookies")
.nick("Cookies") .nick("Cookies")
.nick("HTTP request cookies") .nick("HTTP request cookies")
.readwrite() .readwrite()

View file

@ -116,20 +116,20 @@ impl ObjectImpl for TextAhead {
glib::ParamSpecString::builder("separator") glib::ParamSpecString::builder("separator")
.nick("Separator") .nick("Separator")
.blurb("Text inserted between each text buffers") .blurb("Text inserted between each text buffers")
.default_value(Some(&default.separator)) .default_value(&*default.separator)
.mutable_playing() .mutable_playing()
.build(), .build(),
// See https://developer.gimp.org/api/2.0/pango/PangoMarkupFormat.html for pango attributes // See https://developer.gimp.org/api/2.0/pango/PangoMarkupFormat.html for pango attributes
glib::ParamSpecString::builder("current-attributes") glib::ParamSpecString::builder("current-attributes")
.nick("Current attributes") .nick("Current attributes")
.blurb("Pango span attributes to set on the text from the current buffer") .blurb("Pango span attributes to set on the text from the current buffer")
.default_value(Some(&default.current_attributes)) .default_value(&*default.current_attributes)
.mutable_playing() .mutable_playing()
.build(), .build(),
glib::ParamSpecString::builder("ahead-attributes") glib::ParamSpecString::builder("ahead-attributes")
.nick("Ahead attributes") .nick("Ahead attributes")
.blurb("Pango span attributes to set on the ahead text") .blurb("Pango span attributes to set on the ahead text")
.default_value(Some(&default.ahead_attributes)) .default_value(&*default.ahead_attributes)
.mutable_playing() .mutable_playing()
.build(), .build(),
glib::ParamSpecBoolean::builder("buffer-start-segment") glib::ParamSpecBoolean::builder("buffer-start-segment")

View file

@ -145,7 +145,7 @@ impl ObjectImpl for RegEx {
.nick("Commands") .nick("Commands")
.blurb("A set of commands to apply on input text") .blurb("A set of commands to apply on input text")
.element_spec( .element_spec(
&glib::ParamSpecBoxed::builder("command", gst::Structure::static_type()) &glib::ParamSpecBoxed::builder::<gst::Structure>("command")
.nick("Command") .nick("Command")
.blurb("A command to apply on input text") .blurb("A command to apply on input text")
.build(), .build(),

View file

@ -83,10 +83,9 @@ impl ObjectImpl for ProgressBin {
fn properties() -> &'static [glib::ParamSpec] { fn properties() -> &'static [glib::ParamSpec] {
static PROPERTIES: Lazy<Vec<glib::ParamSpec>> = Lazy::new(|| { static PROPERTIES: Lazy<Vec<glib::ParamSpec>> = Lazy::new(|| {
vec![ vec![
glib::ParamSpecEnum::builder("output", ProgressBinOutput::static_type()) glib::ParamSpecEnum::builder::<ProgressBinOutput>("output", DEFAULT_OUTPUT_TYPE)
.nick("Output") .nick("Output")
.blurb("Defines the output type of the progressbin") .blurb("Defines the output type of the progressbin")
.default_value(DEFAULT_OUTPUT_TYPE as i32)
.mutable_playing() .mutable_playing()
.build(), .build(),
] ]

View file

@ -57,14 +57,12 @@ impl ObjectSubclass for CustomSource {
impl ObjectImpl for CustomSource { impl ObjectImpl for CustomSource {
fn properties() -> &'static [glib::ParamSpec] { fn properties() -> &'static [glib::ParamSpec] {
static PROPERTIES: Lazy<Vec<glib::ParamSpec>> = Lazy::new(|| { static PROPERTIES: Lazy<Vec<glib::ParamSpec>> = Lazy::new(|| {
vec![ vec![glib::ParamSpecObject::builder::<gst::Element>("source")
glib::ParamSpecObject::builder("source", gst::Element::static_type()) .nick("Source")
.nick("Source") .blurb("Source")
.blurb("Source") .write_only()
.write_only() .construct_only()
.construct_only() .build()]
.build(),
]
}); });
PROPERTIES.as_ref() PROPERTIES.as_ref()

View file

@ -215,7 +215,7 @@ impl ObjectImpl for FallbackSrc {
.blurb("URI to use") .blurb("URI to use")
.mutable_ready() .mutable_ready()
.build(), .build(),
glib::ParamSpecObject::builder("source", gst::Element::static_type()) glib::ParamSpecObject::builder::<gst::Element>("source")
.nick("Source") .nick("Source")
.blurb("Source to use instead of the URI") .blurb("Source to use instead of the URI")
.mutable_ready() .mutable_ready()
@ -252,10 +252,9 @@ impl ObjectImpl for FallbackSrc {
.default_value(false) .default_value(false)
.mutable_ready() .mutable_ready()
.build(), .build(),
glib::ParamSpecEnum::builder("status", Status::static_type()) glib::ParamSpecEnum::builder::<Status>("status", Status::Stopped)
.nick("Status") .nick("Status")
.blurb("Current source status") .blurb("Current source status")
.default_value(Status::Stopped as i32)
.read_only() .read_only()
.build(), .build(),
glib::ParamSpecUInt64::builder("min-latency") glib::ParamSpecUInt64::builder("min-latency")
@ -274,7 +273,7 @@ impl ObjectImpl for FallbackSrc {
.default_value(-1) .default_value(-1)
.mutable_ready() .mutable_ready()
.build(), .build(),
glib::ParamSpecBoxed::builder("statistics", gst::Structure::static_type()) glib::ParamSpecBoxed::builder::<gst::Structure>("statistics")
.nick("Statistics") .nick("Statistics")
.blurb("Various statistics") .blurb("Various statistics")
.read_only() .read_only()
@ -291,12 +290,12 @@ impl ObjectImpl for FallbackSrc {
.default_value(false) .default_value(false)
.mutable_ready() .mutable_ready()
.build(), .build(),
glib::ParamSpecBoxed::builder("fallback-video-caps", gst::Caps::static_type()) glib::ParamSpecBoxed::builder::<gst::Caps>("fallback-video-caps")
.nick("Fallback Video Caps") .nick("Fallback Video Caps")
.blurb("Raw video caps for fallback stream") .blurb("Raw video caps for fallback stream")
.mutable_ready() .mutable_ready()
.build(), .build(),
glib::ParamSpecBoxed::builder("fallback-audio-caps", gst::Caps::static_type()) glib::ParamSpecBoxed::builder::<gst::Caps>("fallback-audio-caps")
.nick("Fallback Audio Caps") .nick("Fallback Audio Caps")
.blurb("Raw audio caps for fallback stream") .blurb("Raw audio caps for fallback stream")
.mutable_ready() .mutable_ready()

View file

@ -1068,7 +1068,7 @@ impl ObjectImpl for FallbackSwitch {
fn properties() -> &'static [glib::ParamSpec] { fn properties() -> &'static [glib::ParamSpec] {
static PROPERTIES: Lazy<Vec<glib::ParamSpec>> = Lazy::new(|| { static PROPERTIES: Lazy<Vec<glib::ParamSpec>> = Lazy::new(|| {
vec![ vec![
glib::ParamSpecObject::builder(PROP_ACTIVE_PAD, gst::Pad::static_type()) glib::ParamSpecObject::builder::<gst::Pad>(PROP_ACTIVE_PAD)
.nick("Active Pad") .nick("Active Pad")
.blurb("Currently active pad") .blurb("Currently active pad")
.mutable_playing() .mutable_playing()

View file

@ -737,7 +737,7 @@ impl ObjectImpl for UriPlaylistBin {
fn properties() -> &'static [glib::ParamSpec] { fn properties() -> &'static [glib::ParamSpec] {
static PROPERTIES: Lazy<Vec<glib::ParamSpec>> = Lazy::new(|| { static PROPERTIES: Lazy<Vec<glib::ParamSpec>> = Lazy::new(|| {
vec![ vec![
glib::ParamSpecBoxed::builder("uris", Vec::<String>::static_type()) glib::ParamSpecBoxed::builder::<Vec<String>>("uris")
.nick("URIs") .nick("URIs")
.blurb("URIs of the medias to play") .blurb("URIs of the medias to play")
.mutable_ready() .mutable_ready()

View file

@ -481,7 +481,7 @@ impl ObjectImpl for MccEnc {
.blurb("UUID for the output file") .blurb("UUID for the output file")
.mutable_ready() .mutable_ready()
.build(), .build(),
glib::ParamSpecBoxed::builder("creation-date", glib::DateTime::static_type()) glib::ParamSpecBoxed::builder::<glib::DateTime>("creation-date")
.nick("Creation Date") .nick("Creation Date")
.blurb("Creation date for the output file") .blurb("Creation date for the output file")
.mutable_ready() .mutable_ready()

View file

@ -616,28 +616,26 @@ impl ObjectImpl for TranscriberBin {
.default_value(DEFAULT_ACCUMULATE.mseconds() as u32) .default_value(DEFAULT_ACCUMULATE.mseconds() as u32)
.mutable_ready() .mutable_ready()
.build(), .build(),
glib::ParamSpecEnum::builder("mode", Cea608Mode::static_type()) glib::ParamSpecEnum::builder::<Cea608Mode>("mode", DEFAULT_MODE)
.nick("Mode") .nick("Mode")
.blurb("Which closed caption mode to operate in") .blurb("Which closed caption mode to operate in")
.default_value(DEFAULT_MODE as i32)
.mutable_playing() .mutable_playing()
.build(), .build(),
glib::ParamSpecBoxed::builder("cc-caps", gst::Caps::static_type()) glib::ParamSpecBoxed::builder::<gst::Caps>("cc-caps")
.nick("Closed Caption caps") .nick("Closed Caption caps")
.blurb("The expected format of the closed captions") .blurb("The expected format of the closed captions")
.mutable_ready() .mutable_ready()
.build(), .build(),
glib::ParamSpecObject::builder("transcriber", gst::Element::static_type()) glib::ParamSpecObject::builder::<gst::Element>("transcriber")
.nick("Transcriber") .nick("Transcriber")
.blurb("The transcriber element to use") .blurb("The transcriber element to use")
.mutable_ready() .mutable_ready()
.build(), .build(),
glib::ParamSpecEnum::builder("caption-source", CaptionSource::static_type()) glib::ParamSpecEnum::builder::<CaptionSource>("caption-source", DEFAULT_CAPTION_SOURCE)
.nick("Caption source") .nick("Caption source")
.blurb("Caption source to use. \ .blurb("Caption source to use. \
If \"Transcription\" or \"Inband\" is selected, the caption meta \ If \"Transcription\" or \"Inband\" is selected, the caption meta \
of the other source will be dropped by transcriberbin") of the other source will be dropped by transcriberbin")
.default_value(DEFAULT_CAPTION_SOURCE as i32)
.mutable_playing() .mutable_playing()
.build(), .build(),
] ]

View file

@ -1061,10 +1061,9 @@ impl ObjectImpl for TtToCea608 {
fn properties() -> &'static [glib::ParamSpec] { fn properties() -> &'static [glib::ParamSpec] {
static PROPERTIES: Lazy<Vec<glib::ParamSpec>> = Lazy::new(|| { static PROPERTIES: Lazy<Vec<glib::ParamSpec>> = Lazy::new(|| {
vec![ vec![
glib::ParamSpecEnum::builder("mode", Cea608Mode::static_type()) glib::ParamSpecEnum::builder::<Cea608Mode>("mode", DEFAULT_MODE)
.nick("Mode") .nick("Mode")
.blurb("Which mode to operate in") .blurb("Which mode to operate in")
.default_value(DEFAULT_MODE as i32)
.mutable_playing() .mutable_playing()
.build(), .build(),
glib::ParamSpecInt::builder("origin-row") glib::ParamSpecInt::builder("origin-row")

View file

@ -224,10 +224,9 @@ impl ObjectImpl for TtToJson {
fn properties() -> &'static [glib::ParamSpec] { fn properties() -> &'static [glib::ParamSpec] {
static PROPERTIES: Lazy<Vec<glib::ParamSpec>> = Lazy::new(|| { static PROPERTIES: Lazy<Vec<glib::ParamSpec>> = Lazy::new(|| {
vec![ vec![
glib::ParamSpecEnum::builder("mode", Cea608Mode::static_type()) glib::ParamSpecEnum::builder::<Cea608Mode>("mode", DEFAULT_MODE)
.nick("Mode") .nick("Mode")
.blurb("Which mode to operate in") .blurb("Which mode to operate in")
.default_value(DEFAULT_MODE as i32)
.mutable_ready() .mutable_ready()
.build(), .build(),
] ]

View file

@ -69,7 +69,7 @@ impl ObjectImpl for PaintableSink {
fn properties() -> &'static [glib::ParamSpec] { fn properties() -> &'static [glib::ParamSpec] {
static PROPERTIES: Lazy<Vec<glib::ParamSpec>> = Lazy::new(|| { static PROPERTIES: Lazy<Vec<glib::ParamSpec>> = Lazy::new(|| {
vec![ vec![
glib::ParamSpecObject::builder("paintable", gtk::gdk::Paintable::static_type()) glib::ParamSpecObject::builder::<gtk::gdk::Paintable>("paintable")
.nick("Paintable") .nick("Paintable")
.blurb("The Paintable the sink renders to") .blurb("The Paintable the sink renders to")
.read_only() .read_only()

View file

@ -319,10 +319,9 @@ impl ObjectImpl for Rav1Enc {
.default_value(DEFAULT_RDO_LOOKAHEAD_FRAMES) .default_value(DEFAULT_RDO_LOOKAHEAD_FRAMES)
.mutable_ready() .mutable_ready()
.build(), .build(),
glib::ParamSpecEnum::builder("tune", Tune::static_type()) glib::ParamSpecEnum::builder::<Tune>("tune", DEFAULT_TUNE)
.nick("Tune") .nick("Tune")
.blurb("Tune") .blurb("Tune")
.default_value(DEFAULT_TUNE as i32)
.mutable_ready() .mutable_ready()
.build(), .build(),
glib::ParamSpecInt::builder("reservoir-frame-delay") glib::ParamSpecInt::builder("reservoir-frame-delay")

View file

@ -176,16 +176,17 @@ impl ObjectImpl for PngEncoder {
fn properties() -> &'static [glib::ParamSpec] { fn properties() -> &'static [glib::ParamSpec] {
static PROPERTIES: Lazy<Vec<glib::ParamSpec>> = Lazy::new(|| { static PROPERTIES: Lazy<Vec<glib::ParamSpec>> = Lazy::new(|| {
vec![ vec![
glib::ParamSpecEnum::builder("compression-level", CompressionLevel::static_type()) glib::ParamSpecEnum::builder::<CompressionLevel>(
.nick("Compression level") "compression-level",
.blurb("Selects the compression algorithm to use") DEFAULT_COMPRESSION_LEVEL,
.default_value(DEFAULT_COMPRESSION_LEVEL as i32) )
.mutable_ready() .nick("Compression level")
.build(), .blurb("Selects the compression algorithm to use")
glib::ParamSpecEnum::builder("filter", FilterType::static_type()) .mutable_ready()
.build(),
glib::ParamSpecEnum::builder::<FilterType>("filter", DEFAULT_FILTER_TYPE)
.nick("Filter") .nick("Filter")
.blurb("Selects the filter type to applied") .blurb("Selects the filter type to applied")
.default_value(DEFAULT_FILTER_TYPE as i32)
.mutable_ready() .mutable_ready()
.build(), .build(),
] ]