summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--graphics/src/image/vector.rs8
1 files changed, 4 insertions, 4 deletions
diff --git a/graphics/src/image/vector.rs b/graphics/src/image/vector.rs
index 0af5be01..82d77aff 100644
--- a/graphics/src/image/vector.rs
+++ b/graphics/src/image/vector.rs
@@ -8,8 +8,6 @@ use iced_native::Size;
use std::collections::{HashMap, HashSet};
use std::fs;
-type Fill = Option<[u8; 4]>;
-
/// Entry in cache corresponding to an svg handle
pub enum Svg {
/// Parsed svg
@@ -36,11 +34,13 @@ impl Svg {
#[derive(Debug)]
pub struct Cache<T: Storage> {
svgs: HashMap<u64, Svg>,
- rasterized: HashMap<(u64, u32, u32, Fill), T::Entry>,
+ rasterized: HashMap<(u64, u32, u32, ColorFilter), T::Entry>,
svg_hits: HashSet<u64>,
- rasterized_hits: HashSet<(u64, u32, u32, Fill)>,
+ rasterized_hits: HashSet<(u64, u32, u32, ColorFilter)>,
}
+type ColorFilter = Option<[u8; 4]>;
+
impl<T: Storage> Cache<T> {
/// Load svg
pub fn load(&mut self, handle: &svg::Handle) -> &Svg {