Resolve errors
Co-Authored-By: Marshall Bowers <1486634+maxdeviant@users.noreply.github.com>
This commit is contained in:
parent
f6c54b8043
commit
8432b713cc
3 changed files with 11 additions and 4 deletions
|
@ -2,11 +2,14 @@ use collections::{CommandPaletteFilter, HashMap};
|
||||||
use fuzzy::{StringMatch, StringMatchCandidate};
|
use fuzzy::{StringMatch, StringMatchCandidate};
|
||||||
use gpui::{
|
use gpui::{
|
||||||
actions, div, Action, AppContext, Component, Div, EventEmitter, FocusHandle, Keystroke,
|
actions, div, Action, AppContext, Component, Div, EventEmitter, FocusHandle, Keystroke,
|
||||||
ParentElement, Render, SharedString, StatelessInteractive, Styled, View, ViewContext,
|
ParentElement, Render, StatelessInteractive, Styled, View, ViewContext, VisualContext,
|
||||||
VisualContext, WeakView, WindowContext,
|
WeakView, WindowContext,
|
||||||
};
|
};
|
||||||
use picker::{Picker, PickerDelegate};
|
use picker::{Picker, PickerDelegate};
|
||||||
use std::cmp::{self, Reverse};
|
use std::{
|
||||||
|
cmp::{self, Reverse},
|
||||||
|
sync::Arc,
|
||||||
|
};
|
||||||
use theme::ActiveTheme;
|
use theme::ActiveTheme;
|
||||||
use ui::{v_stack, HighlightedLabel, StyledExt};
|
use ui::{v_stack, HighlightedLabel, StyledExt};
|
||||||
use util::{
|
use util::{
|
||||||
|
|
|
@ -4,7 +4,7 @@ use gpui::{
|
||||||
StatelessInteractive, Styled, Task, UniformListScrollHandle, View, ViewContext, VisualContext,
|
StatelessInteractive, Styled, Task, UniformListScrollHandle, View, ViewContext, VisualContext,
|
||||||
WindowContext,
|
WindowContext,
|
||||||
};
|
};
|
||||||
use std::cmp;
|
use std::{cmp, sync::Arc};
|
||||||
use ui::{prelude::*, v_stack, Divider, Label, LabelColor};
|
use ui::{prelude::*, v_stack, Divider, Label, LabelColor};
|
||||||
|
|
||||||
pub struct Picker<D: PickerDelegate> {
|
pub struct Picker<D: PickerDelegate> {
|
||||||
|
|
|
@ -44,6 +44,10 @@ impl PickerDelegate for Delegate {
|
||||||
self.candidates.len()
|
self.candidates.len()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
fn placeholder_text(&self) -> Arc<str> {
|
||||||
|
"Test".into()
|
||||||
|
}
|
||||||
|
|
||||||
fn render_match(
|
fn render_match(
|
||||||
&self,
|
&self,
|
||||||
ix: usize,
|
ix: usize,
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue