gstreamer: Use obj() instead of instance() in the remaining places

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-rs/-/merge_requests/1196>
This commit is contained in:
Sebastian Dröge 2023-01-21 20:58:06 +02:00
parent 257a049673
commit 38dd1f462b

View file

@ -39,10 +39,7 @@ impl<T: AllocatorImpl> AllocatorImplExt for T {
if let Some(f) = (*parent_class).alloc {
from_glib_full::<*mut ffi::GstMemory, Option<_>>(f(
self.instance()
.unsafe_cast_ref::<Allocator>()
.to_glib_none()
.0,
self.obj().unsafe_cast_ref::<Allocator>().to_glib_none().0,
size,
mut_override(params.to_glib_none().0),
))
@ -60,10 +57,7 @@ impl<T: AllocatorImpl> AllocatorImplExt for T {
if let Some(f) = (*parent_class).free {
f(
self.instance()
.unsafe_cast_ref::<Allocator>()
.to_glib_none()
.0,
self.obj().unsafe_cast_ref::<Allocator>().to_glib_none().0,
memory.into_glib_ptr(),
)
}