Load JSON themes (#6893)
This PR changes the theme loading to use the JSON themes bundled with the binary rather then the Rust theme definitions. ### Performance I profiled this using `cargo run --release` to see what the speed differences would be now that we're deserializing JSON: **Before:** `ThemeRegistry::load_user_themes` took 16.656666ms **After:** `ThemeRegistry::load_user_themes` took 18.784875ms It's slightly slower, but not by much. There is probably some work we could do here to bring down the theme loading time in general. Release Notes: - N/A
This commit is contained in:
parent
f7fc4ffbe5
commit
5f1dcb76fe
7 changed files with 133 additions and 48 deletions
|
@ -69,7 +69,7 @@ fn main() {
|
|||
.unwrap();
|
||||
cx.set_global(store);
|
||||
|
||||
theme::init(theme::LoadThemes::All, cx);
|
||||
theme::init(theme::LoadThemes::All(Box::new(Assets)), cx);
|
||||
|
||||
let selector = story_selector;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue