Commit 53cf6704 authored by Sebastian Dröge's avatar Sebastian Dröge 🍵

Remove EncodingTarget::add_profile() and consider it immutable

parent 70fde430
......@@ -193,8 +193,9 @@ status = "generate"
[[object.function]]
name = "add_profile"
[object.function.return]
bool_return_is_error = "Failed to add profile"
# can be provided on constructor and we better
# consider this immutable
ignore = true
[[object.function]]
name = "get_category"
......
......@@ -5,7 +5,6 @@
use EncodingProfile;
use Error;
use ffi;
use glib;
use glib::object::IsA;
use glib::translate::*;
use glib_ffi;
......@@ -55,8 +54,6 @@ unsafe impl Send for EncodingTarget {}
unsafe impl Sync for EncodingTarget {}
pub trait EncodingTargetExt {
fn add_profile<P: IsA<EncodingProfile>>(&self, profile: &P) -> Result<(), glib::error::BoolError>;
fn get_category(&self) -> String;
fn get_description(&self) -> String;
......@@ -73,12 +70,6 @@ pub trait EncodingTargetExt {
}
impl<O: IsA<EncodingTarget>> EncodingTargetExt for O {
fn add_profile<P: IsA<EncodingProfile>>(&self, profile: &P) -> Result<(), glib::error::BoolError> {
unsafe {
glib::error::BoolError::from_glib(ffi::gst_encoding_target_add_profile(self.to_glib_none().0, profile.to_glib_full()), "Failed to add profile")
}
}
fn get_category(&self) -> String {
unsafe {
from_glib_none(ffi::gst_encoding_target_get_category(self.to_glib_none().0))
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment