mirror of
https://github.com/nestriness/nestri.git
synced 2025-12-12 08:45:38 +02:00
## Description - Updates to latest Rust 2024 🎉 - Make DataChannel messages ordered on nestri-server side - Bugfixes and code improvements + formatting ## Type of Change - [x] Bug fix (non-breaking change) - [x] New feature (non-breaking change) ## Checklist - [x] I have updated relevant documentation - [x] My code follows the project's coding style - [x] My changes generate no new warnings/errors --------- Co-authored-by: DatCaptainHorse <DatCaptainHorse@users.noreply.github.com> Co-authored-by: Wanjohi <elviswanjohi47@gmail.com>
26 lines
670 B
Rust
26 lines
670 B
Rust
use crate::websocket::NestriWebSocket;
|
|
use gst::glib;
|
|
use gst::subclass::prelude::*;
|
|
use gstrswebrtc::signaller::Signallable;
|
|
use std::sync::Arc;
|
|
|
|
mod imp;
|
|
|
|
glib::wrapper! {
|
|
pub struct NestriSignaller(ObjectSubclass<imp::Signaller>) @implements Signallable;
|
|
}
|
|
|
|
impl NestriSignaller {
|
|
pub fn new(nestri_ws: Arc<NestriWebSocket>, pipeline: Arc<gst::Pipeline>) -> Self {
|
|
let obj: Self = glib::Object::new();
|
|
obj.imp().set_nestri_ws(nestri_ws);
|
|
obj.imp().set_pipeline(pipeline);
|
|
obj
|
|
}
|
|
}
|
|
impl Default for NestriSignaller {
|
|
fn default() -> Self {
|
|
panic!("Cannot create NestriSignaller without NestriWebSocket");
|
|
}
|
|
}
|