summaryrefslogtreecommitdiff
path: root/Userland/Libraries/LibWeb/FontCache.cpp
diff options
context:
space:
mode:
authorAndreas Kling <kling@serenityos.org>2023-02-20 18:56:08 +0100
committerAndreas Kling <kling@serenityos.org>2023-02-21 00:54:04 +0100
commitf11899f885c18390fa17aebe1ef77b733a81fcaf (patch)
treed267dd8f55f9625312a69f1d630b8b70cefb0a0d /Userland/Libraries/LibWeb/FontCache.cpp
parent68b5df6bf17c55af258f44a18d0ddd41c660d38d (diff)
downloadserenity-f11899f885c18390fa17aebe1ef77b733a81fcaf.zip
LibWeb+LibIDL: Fix (or paper over) various const-correctness issues
There's definitely stuff to iterate on here, but this takes care of making the libraries compile with stricter RP and NNRP.
Diffstat (limited to 'Userland/Libraries/LibWeb/FontCache.cpp')
-rw-r--r--Userland/Libraries/LibWeb/FontCache.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/Userland/Libraries/LibWeb/FontCache.cpp b/Userland/Libraries/LibWeb/FontCache.cpp
index 30b93f641f..b37bf8e553 100644
--- a/Userland/Libraries/LibWeb/FontCache.cpp
+++ b/Userland/Libraries/LibWeb/FontCache.cpp
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2018-2020, Andreas Kling <kling@serenityos.org>
+ * Copyright (c) 2018-2023, Andreas Kling <kling@serenityos.org>
*
* SPDX-License-Identifier: BSD-2-Clause
*/
@@ -13,7 +13,7 @@ FontCache& FontCache::the()
return cache;
}
-RefPtr<Gfx::Font> FontCache::get(FontSelector const& font_selector) const
+RefPtr<Gfx::Font const> FontCache::get(FontSelector const& font_selector) const
{
auto cached_font = m_fonts.get(font_selector);
if (cached_font.has_value())
@@ -21,7 +21,7 @@ RefPtr<Gfx::Font> FontCache::get(FontSelector const& font_selector) const
return nullptr;
}
-void FontCache::set(FontSelector const& font_selector, NonnullRefPtr<Gfx::Font> font)
+void FontCache::set(FontSelector const& font_selector, NonnullRefPtr<Gfx::Font const> font)
{
m_fonts.set(font_selector, move(font));
}