From 72fc892792565ef39fcae6b7d2a19006dc3a3238 Mon Sep 17 00:00:00 2001 From: crupest Date: Thu, 21 Oct 2021 17:44:56 +0800 Subject: ... --- src/ui/ThemeManager.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'src/ui/ThemeManager.cpp') diff --git a/src/ui/ThemeManager.cpp b/src/ui/ThemeManager.cpp index be986bb5..4a0e08a5 100644 --- a/src/ui/ThemeManager.cpp +++ b/src/ui/ThemeManager.cpp @@ -16,7 +16,7 @@ ThemeManager::ThemeManager() { Init(); } void ThemeManager::Init() { theme_tree_.put("scrollbar.collapse-thumb.color", - colors::gray.WithAlpha(128).ToUtf8String()); + colors::gray.WithAlpha(128).ToString().ToUtf8()); theme_tree_.put("scrollbar.arrow.normal.color", "#505050"); theme_tree_.put("scrollbar.arrow.hover.color", "#505050"); theme_tree_.put("scrollbar.arrow.press.color", "#ffffff"); @@ -43,11 +43,12 @@ ThemeManager::GetBrush(std::u16string key) { return cached_brush_iter->second; } - auto color_string = ToUtf16(theme_tree_.get(ToUtf8(key))); + auto color_string = + String::FromUtf8(theme_tree_.get(ToUtf8(key))); auto color = Color::Parse(color_string); if (!color) throw BadThemeResourceException("Value is not a valid color."); std::shared_ptr brush = - GetUiApplication()->GetGraphFactory()->CreateSolidColorBrush(*color); + GetUiApplication()->GetGraphicsFactory()->CreateSolidColorBrush(*color); brushes_[k] = brush; return brush; } -- cgit v1.2.3