mirror of
https://github.com/hannobraun/Fornjot
synced 2025-05-10 21:08:27 +00:00
Remove unused code
This commit is contained in:
parent
e103fe7555
commit
639996caf1
@ -2,8 +2,4 @@ mod handle;
|
|||||||
mod handle_any;
|
mod handle_any;
|
||||||
mod traits;
|
mod traits;
|
||||||
|
|
||||||
pub use self::{
|
pub use self::{handle::Handle, handle_any::HandleAny, traits::Operation};
|
||||||
handle::Handle,
|
|
||||||
handle_any::HandleAny,
|
|
||||||
traits::{Operation, OperationOutput},
|
|
||||||
};
|
|
||||||
|
@ -17,11 +17,6 @@ pub trait Operation {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
pub trait OperationOutput<Output = Self>: Operation {
|
|
||||||
#[allow(unused)] // ongoing cleanup
|
|
||||||
fn output(&self) -> &Output;
|
|
||||||
}
|
|
||||||
|
|
||||||
pub struct OperationDisplay<'r> {
|
pub struct OperationDisplay<'r> {
|
||||||
pub op: &'r dyn Operation,
|
pub op: &'r dyn Operation,
|
||||||
}
|
}
|
||||||
|
@ -6,7 +6,7 @@ use spade::Triangulation;
|
|||||||
use crate::{
|
use crate::{
|
||||||
geometry::{TriMesh, Triangle},
|
geometry::{TriMesh, Triangle},
|
||||||
math::{Plane, Point},
|
math::{Plane, Point},
|
||||||
operation::{Handle, HandleAny, Operation, OperationOutput},
|
operation::{Handle, HandleAny, Operation},
|
||||||
};
|
};
|
||||||
|
|
||||||
use super::vertex::Vertex;
|
use super::vertex::Vertex;
|
||||||
@ -104,12 +104,6 @@ impl Operation for Face {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
impl OperationOutput for Face {
|
|
||||||
fn output(&self) -> &Self {
|
|
||||||
self
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
struct TriangulationPoint {
|
struct TriangulationPoint {
|
||||||
point_surface: Point<2>,
|
point_surface: Point<2>,
|
||||||
point_vertex: Point<3>,
|
point_vertex: Point<3>,
|
||||||
|
@ -2,7 +2,7 @@ use std::fmt;
|
|||||||
|
|
||||||
use crate::{
|
use crate::{
|
||||||
geometry::TriMesh,
|
geometry::TriMesh,
|
||||||
operation::{Handle, HandleAny, Operation, OperationOutput},
|
operation::{Handle, HandleAny, Operation},
|
||||||
};
|
};
|
||||||
|
|
||||||
use super::face::Face;
|
use super::face::Face;
|
||||||
@ -39,8 +39,3 @@ impl Operation for Solid {
|
|||||||
self.faces.iter().map(|face| face.to_any()).collect()
|
self.faces.iter().map(|face| face.to_any()).collect()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
impl OperationOutput for Solid {
|
|
||||||
fn output(&self) -> &Self {
|
|
||||||
self
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
@ -3,7 +3,7 @@ use std::fmt;
|
|||||||
use crate::{
|
use crate::{
|
||||||
geometry::TriMesh,
|
geometry::TriMesh,
|
||||||
math::{Point, Vector},
|
math::{Point, Vector},
|
||||||
operation::{HandleAny, Operation, OperationOutput},
|
operation::{HandleAny, Operation},
|
||||||
};
|
};
|
||||||
|
|
||||||
#[derive(Clone, Copy, Debug, Eq, Ord, PartialEq, PartialOrd)]
|
#[derive(Clone, Copy, Debug, Eq, Ord, PartialEq, PartialOrd)]
|
||||||
@ -43,9 +43,3 @@ impl Operation for Vertex {
|
|||||||
Vec::new()
|
Vec::new()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
impl OperationOutput for Vertex {
|
|
||||||
fn output(&self) -> &Self {
|
|
||||||
self
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
@ -2,7 +2,7 @@ use std::{fmt, iter};
|
|||||||
|
|
||||||
use crate::{
|
use crate::{
|
||||||
geometry::TriMesh,
|
geometry::TriMesh,
|
||||||
operation::{HandleAny, Operation, OperationOutput},
|
operation::{HandleAny, Operation},
|
||||||
};
|
};
|
||||||
|
|
||||||
#[derive(Clone)]
|
#[derive(Clone)]
|
||||||
@ -134,9 +134,3 @@ impl Operation for OperationView {
|
|||||||
self.operation.children()
|
self.operation.children()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
impl OperationOutput for OperationView {
|
|
||||||
fn output(&self) -> &Self {
|
|
||||||
self
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
Loading…
Reference in New Issue
Block a user