diff --git a/src/backend/pwnodemodel.rs b/src/backend/pwnodemodel.rs index 92957a7..a254fb9 100644 --- a/src/backend/pwnodemodel.rs +++ b/src/backend/pwnodemodel.rs @@ -74,26 +74,6 @@ impl PwNodeModel { } - pub fn get_node(&self, id: u32) -> Result { - let imp = self.imp(); - let vector = imp.0.borrow(); - if let Some(v) = vector.iter().find(|p|id == p.boundid()) { - return Ok(v.clone()); - } - Err(()) - } - - pub fn get_node_pos_from_id(&self, id: u32) -> Option { - let imp = self.imp(); - let vector = imp.0.borrow(); - for (i, v) in vector.iter().enumerate() { - if v.boundid() == id { - return Some(i as u32); - } - } - None - } - } impl Default for PwNodeModel { diff --git a/src/backend/pwnodeobject.rs b/src/backend/pwnodeobject.rs index d73f8d0..7345dbd 100644 --- a/src/backend/pwnodeobject.rs +++ b/src/backend/pwnodeobject.rs @@ -10,8 +10,7 @@ use std::cell::{Cell, RefCell}; use glib::{self, clone, subclass::{prelude::*, Signal}, ObjectExt, ParamSpec, Properties, Value, CastNone}; use once_cell::sync::{Lazy, OnceCell}; use gtk::{gio, prelude::ListModelExt}; -use crate::backend::PwChannelObject; -use super::{PwDeviceObject, PwRouteObject, PwvucontrolManager}; +use super::{PwDeviceObject, PwRouteObject, PwChannelObject, PwvucontrolManager}; use crate::macros::*; mod mixerapi;