mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer-rs.git
synced 2024-11-05 17:19:42 +00:00
Replace Foo::from_instance(foo)
with foo.imp()
This commit is contained in:
parent
d778be0e5d
commit
1fbb6a3a1c
3 changed files with 3 additions and 3 deletions
|
@ -236,7 +236,7 @@ mod fir_filter {
|
|||
// Sets the coefficients by getting access to the private
|
||||
// struct and simply setting them
|
||||
pub fn set_coeffs(&self, coeffs: Vec<f32>) {
|
||||
let imp = imp::FirFilter::from_instance(self);
|
||||
let imp = self.imp();
|
||||
*imp.coeffs.lock().unwrap() = coeffs;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -821,7 +821,7 @@ mod tests {
|
|||
|
||||
pipeline.set_state(crate::State::Null).unwrap();
|
||||
|
||||
let imp = imp::TestElement::from_instance(&element);
|
||||
let imp = element.imp();
|
||||
assert_eq!(imp.n_buffers.load(atomic::Ordering::SeqCst), 100);
|
||||
assert!(imp.reached_playing.load(atomic::Ordering::SeqCst));
|
||||
}
|
||||
|
|
|
@ -150,7 +150,7 @@ mod tests {
|
|||
pad.link(&otherpad).unwrap();
|
||||
pad.unlink(&otherpad).unwrap();
|
||||
|
||||
let imp = imp::TestPad::from_instance(&pad);
|
||||
let imp = pad.imp();
|
||||
assert!(imp.linked.load(atomic::Ordering::SeqCst));
|
||||
assert!(imp.unlinked.load(atomic::Ordering::SeqCst));
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue