Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.freedesktop.org/gstreamer/gst-plugins-rs.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'generic/file/src/filesrc/imp.rs')
-rw-r--r--generic/file/src/filesrc/imp.rs15
1 files changed, 7 insertions, 8 deletions
diff --git a/generic/file/src/filesrc/imp.rs b/generic/file/src/filesrc/imp.rs
index cc7969aa1..0eb0aa2e6 100644
--- a/generic/file/src/filesrc/imp.rs
+++ b/generic/file/src/filesrc/imp.rs
@@ -7,13 +7,11 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
-use glib;
use glib::subclass;
use glib::subclass::prelude::*;
-use gst;
use gst::prelude::*;
use gst::subclass::prelude::*;
-use gst_base;
+use gst::{gst_debug, gst_element_error, gst_error, gst_error_msg, gst_info};
use gst_base::prelude::*;
use gst_base::subclass::prelude::*;
@@ -66,13 +64,14 @@ pub struct FileSrc {
state: Mutex<State>,
}
-lazy_static! {
- static ref CAT: gst::DebugCategory = gst::DebugCategory::new(
+use once_cell::sync::Lazy;
+static CAT: Lazy<gst::DebugCategory> = Lazy::new(|| {
+ gst::DebugCategory::new(
"rsfilesrc",
gst::DebugColorFlags::empty(),
Some("File Source"),
- );
-}
+ )
+});
impl FileSrc {
fn set_location(
@@ -138,7 +137,7 @@ impl ObjectSubclass for FileSrc {
type Instance = gst::subclass::ElementInstanceStruct<Self>;
type Class = subclass::simple::ClassStruct<Self>;
- glib_object_subclass!();
+ glib::glib_object_subclass!();
fn new() -> Self {
Self {