summaryrefslogtreecommitdiffstats
path: root/graphics/src/cached.rs
diff options
context:
space:
mode:
authorLibravatar Héctor Ramón Jiménez <hector@hecrj.dev>2024-04-09 22:25:16 +0200
committerLibravatar Héctor Ramón Jiménez <hector@hecrj.dev>2024-04-09 22:25:16 +0200
commit6ad5bb3597f640ac329801adf735d633bf0a512f (patch)
treef0928edacd09d6537878d22b00ad7ed7829c9ac0 /graphics/src/cached.rs
parent2c6fd9ac14c5d270e05b97b7a7fab811d25834c4 (diff)
downloadiced-6ad5bb3597f640ac329801adf735d633bf0a512f.tar.gz
iced-6ad5bb3597f640ac329801adf735d633bf0a512f.tar.bz2
iced-6ad5bb3597f640ac329801adf735d633bf0a512f.zip
Port `iced_tiny_skia` to new layering architecture
Diffstat (limited to 'graphics/src/cached.rs')
-rw-r--r--graphics/src/cached.rs18
1 files changed, 0 insertions, 18 deletions
diff --git a/graphics/src/cached.rs b/graphics/src/cached.rs
index 1ba82f9f..c0e4e029 100644
--- a/graphics/src/cached.rs
+++ b/graphics/src/cached.rs
@@ -1,7 +1,3 @@
-use crate::Primitive;
-
-use std::sync::Arc;
-
/// A piece of data that can be cached.
pub trait Cached: Sized {
/// The type of cache produced.
@@ -18,20 +14,6 @@ pub trait Cached: Sized {
fn cache(self, previous: Option<Self::Cache>) -> Self::Cache;
}
-impl<T> Cached for Primitive<T> {
- type Cache = Arc<Self>;
-
- fn load(cache: &Arc<Self>) -> Self {
- Self::Cache {
- content: cache.clone(),
- }
- }
-
- fn cache(self, _previous: Option<Arc<Self>>) -> Arc<Self> {
- Arc::new(self)
- }
-}
-
#[cfg(debug_assertions)]
impl Cached for () {
type Cache = ();