Use TexturedImage in MediaCache
Signed-off-by: kernelkind <kernelkind@gmail.com>
This commit is contained in:
@@ -13,9 +13,13 @@ use std::path;
|
||||
use std::path::PathBuf;
|
||||
use tracing::warn;
|
||||
|
||||
pub type MediaCacheValue = Promise<Result<TextureHandle>>;
|
||||
pub type MediaCacheValue = Promise<Result<TexturedImage>>;
|
||||
pub type MediaCacheMap = HashMap<String, MediaCacheValue>;
|
||||
|
||||
pub enum TexturedImage {
|
||||
Static(TextureHandle),
|
||||
}
|
||||
|
||||
pub struct MediaCache {
|
||||
pub cache_dir: path::PathBuf,
|
||||
url_imgs: MediaCacheMap,
|
||||
|
||||
@@ -31,7 +31,7 @@ pub use context::AppContext;
|
||||
pub use error::{Error, FilterError};
|
||||
pub use filter::{FilterState, FilterStates, UnifiedSubscription};
|
||||
pub use fonts::NamedFontFamily;
|
||||
pub use imgcache::MediaCache;
|
||||
pub use imgcache::{MediaCache, TexturedImage};
|
||||
pub use muted::{MuteFun, Muted};
|
||||
pub use note::{NoteRef, RootIdError, RootNoteId, RootNoteIdBuf};
|
||||
pub use notecache::{CachedNote, NoteCache};
|
||||
|
||||
Reference in New Issue
Block a user