Fix runtime errors

This commit is contained in:
Nathan Sobo
2023-10-23 11:34:35 +02:00
parent 5247f217fd
commit da8919002f
7 changed files with 31 additions and 20 deletions
+5 -1
View File
@@ -1,9 +1,13 @@
use std::ops::Deref;
use gpui2::{rems, AbsoluteLength, WindowContext};
use gpui2::{rems, AbsoluteLength, AppContext, WindowContext};
use crate::prelude::*;
pub fn init(cx: &mut AppContext) {
cx.set_global(FakeSettings::default());
}
/// Returns the user settings.
pub fn user_settings(cx: &WindowContext) -> FakeSettings {
cx.global::<FakeSettings>().clone()