diff options
author | 2024-04-03 21:09:59 +0200 | |
---|---|---|
committer | 2024-04-03 21:09:59 +0200 | |
commit | 09af6773bdfe3039f6bf1720da945ae874496b81 (patch) | |
tree | 812f4be27cdf684868de700fe8a5f9da71d97359 /graphics | |
parent | b05e61f5c8ae61c9f3c7cc08cded53901ebbccfd (diff) | |
download | iced-09af6773bdfe3039f6bf1720da945ae874496b81.tar.gz iced-09af6773bdfe3039f6bf1720da945ae874496b81.tar.bz2 iced-09af6773bdfe3039f6bf1720da945ae874496b81.zip |
Remove unused `layer` module in `iced_graphics`
Diffstat (limited to 'graphics')
-rw-r--r-- | graphics/src/layer.rs | 47 |
1 files changed, 0 insertions, 47 deletions
diff --git a/graphics/src/layer.rs b/graphics/src/layer.rs deleted file mode 100644 index 5b8aacab..00000000 --- a/graphics/src/layer.rs +++ /dev/null @@ -1,47 +0,0 @@ -pub trait Layer { - type Cache; - - fn new() -> Self; - - fn clear(&mut self); -} - -pub struct Recorder<T: Layer> { - layers: Vec<T>, - caches: Vec<T::Cache>, - stack: Vec<Kind>, - current: usize, -} - -enum Kind { - Fresh(usize), - Cache(usize), -} - -impl<T: Layer> Recorder<T> { - pub fn new() -> Self { - Self { - layers: vec![Layer::new()], - caches: Vec::new(), - stack: Vec::new(), - current: 0, - } - } - - pub fn fill_quad(&mut self) {} - - pub fn push_cache(&mut self, cache: T::Cache) { - self.caches.push(cache); - } - - pub fn clear(&mut self) { - self.caches.clear(); - self.stack.clear(); - - for mut layer in self.layers { - layer.clear(); - } - - self.current = 0; - } -} |