diff --git a/components/gfx/font_context.rs b/components/gfx/font_context.rs index e27c4d0bef4..f5aa46edc34 100644 --- a/components/gfx/font_context.rs +++ b/components/gfx/font_context.rs @@ -35,8 +35,6 @@ use crate::font_cache_thread::{ }; use crate::font_store::{CrossThreadFontStore, CrossThreadWebRenderFontStore}; use crate::font_template::{FontTemplate, FontTemplateRef, FontTemplateRefMethods}; -#[cfg(target_os = "macos")] -use crate::platform::core_text_font_cache::CoreTextFontCache; static SMALL_CAPS_SCALE_FACTOR: f32 = 0.8; // Matches FireFox (see gfxFont.h) diff --git a/components/gfx/platform/macos/core_text_font_cache.rs b/components/gfx/platform/macos/core_text_font_cache.rs index 4232b3f375d..bd59550d45e 100644 --- a/components/gfx/platform/macos/core_text_font_cache.rs +++ b/components/gfx/platform/macos/core_text_font_cache.rs @@ -98,9 +98,4 @@ impl CoreTextFontCache { identifier_cache.insert(au_size, core_text_font.clone()); Some(core_text_font) } - - pub(crate) fn clear_core_text_font_cache() { - let cache = CACHE.0.get_or_init(Default::default); - cache.write().clear(); - } }