This commit is contained in:
Nathan Sobo
2023-04-12 12:13:35 -06:00
parent 40896352ff
commit a25f962185
90 changed files with 587 additions and 501 deletions
+3 -3
View File
@@ -1,7 +1,7 @@
use fuzzy::{match_strings, StringMatch, StringMatchCandidate};
use gpui::{
actions,
elements::{ChildView, Element as _, Label},
elements::{ChildView, Drawable as _, Label},
AnyViewHandle, AppContext, Entity, View, ViewContext, ViewHandle,
};
use picker::{Picker, PickerDelegate};
@@ -74,7 +74,7 @@ impl View for BaseKeymapSelector {
"BaseKeymapSelector"
}
fn render(&mut self, cx: &mut gpui::ViewContext<Self>) -> gpui::ElementBox<Self> {
fn render(&mut self, cx: &mut gpui::ViewContext<Self>) -> gpui::Element<Self> {
ChildView::new(&self.picker, cx).boxed()
}
@@ -161,7 +161,7 @@ impl PickerDelegate for BaseKeymapSelector {
mouse_state: &mut gpui::MouseState,
selected: bool,
cx: &gpui::AppContext,
) -> gpui::ElementBox<Picker<Self>> {
) -> gpui::Element<Picker<Self>> {
let theme = &cx.global::<Settings>().theme;
let keymap_match = &self.matches[ix];
let style = theme.picker.item.style_for(mouse_state, selected);
+3 -3
View File
@@ -5,7 +5,7 @@ use std::sync::Arc;
use db::kvp::KEY_VALUE_STORE;
use gpui::{
elements::{Flex, Label, ParentElement},
AppContext, Element, ElementBox, Entity, Subscription, View, ViewContext,
AppContext, Drawable, Element, Entity, Subscription, View, ViewContext,
};
use settings::{settings_file::SettingsFile, Settings};
@@ -55,7 +55,7 @@ impl View for WelcomePage {
"WelcomePage"
}
fn render(&mut self, cx: &mut gpui::ViewContext<Self>) -> ElementBox<Self> {
fn render(&mut self, cx: &mut gpui::ViewContext<Self>) -> Element<Self> {
let self_handle = cx.handle();
let settings = cx.global::<Settings>();
let theme = settings.theme.clone();
@@ -203,7 +203,7 @@ impl Item for WelcomePage {
_detail: Option<usize>,
style: &theme::Tab,
_cx: &gpui::AppContext,
) -> ElementBox<Pane> {
) -> Element<Pane> {
Flex::row()
.with_child(
Label::new("Welcome to Zed!", style.label.clone())