Cargo fmt

This commit is contained in:
mgsloan@gmail.com 2024-12-19 15:47:52 -07:00
parent dab518f010
commit 33dae9b4f2
96 changed files with 178 additions and 154 deletions

View file

@ -4,8 +4,8 @@ use extension_host::ExtensionStore;
use futures::StreamExt;
use gpui::{
actions, percentage, Animation, AnimationExt as _, AppContext, CursorStyle, EventEmitter,
InteractiveElement as _, Model, ParentElement as _, Render, SharedString,
StatefulInteractiveElement, Styled, Transformation, Model, ViewContext, VisualContext as _,
InteractiveElement as _, Model, Model, ParentElement as _, Render, SharedString,
StatefulInteractiveElement, Styled, Transformation, ViewContext, VisualContext as _,
};
use language::{LanguageRegistry, LanguageServerBinaryStatus, LanguageServerId};
use lsp::LanguageServerName;

View file

@ -11,8 +11,8 @@ use futures::{
use fuzzy::StringMatchCandidate;
use gpui::{
actions, point, size, transparent_black, Action, AppContext, BackgroundExecutor, Bounds,
EventEmitter, Global, PromptLevel, ReadGlobal, Subscription, Task, TextStyle, TitlebarOptions,
UpdateGlobal, Model, WindowBounds, WindowHandle, WindowOptions,
EventEmitter, Global, Model, PromptLevel, ReadGlobal, Subscription, Task, TextStyle,
TitlebarOptions, UpdateGlobal, WindowBounds, WindowHandle, WindowOptions,
};
use heed::{
types::{SerdeBincode, SerdeJson, Str},

View file

@ -4,7 +4,7 @@ use assistant_slash_command::{
SlashCommandResult,
};
use fuzzy::{PathMatch, StringMatchCandidate};
use gpui::{AppContext, Model, Task, Model, WeakModel};
use gpui::{AppContext, Model, Model, Task, WeakModel};
use language::{
Anchor, BufferSnapshot, DiagnosticEntry, DiagnosticSeverity, LspAdapterDelegate,
OffsetRangeExt, ToOffset,

View file

@ -6,7 +6,7 @@ use assistant_slash_command::{
ArgumentCompletion, SlashCommand, SlashCommandOutput, SlashCommandOutputSection,
SlashCommandResult,
};
use gpui::{AppContext, Task, Model, WeakModel};
use gpui::{AppContext, Model, Task, WeakModel};
use language::{BufferSnapshot, CodeLabel, LspAdapterDelegate};
use terminal_view::{terminal_panel::TerminalPanel, TerminalView};
use ui::prelude::*;

View file

@ -6,7 +6,7 @@ use client::zed_urls;
use fs::Fs;
use gpui::{
prelude::*, px, svg, Action, AnyElement, AppContext, AsyncWindowContext, EventEmitter,
FocusHandle, FocusableView, FontWeight, Model, Pixels, Task, Model, ViewContext, WeakModel,
FocusHandle, FocusableView, FontWeight, Model, Model, Pixels, Task, ViewContext, WeakModel,
WindowContext,
};
use language::LanguageRegistry;

View file

@ -4,7 +4,9 @@
use std::sync::Arc;
use fuzzy::PathMatch;
use gpui::{AppContext, DismissEvent, FocusHandle, FocusableView, Task, Model, WeakModel, WeakModel};
use gpui::{
AppContext, DismissEvent, FocusHandle, FocusableView, Model, Task, WeakModel, WeakModel,
};
use picker::{Picker, PickerDelegate};
use project::{PathMatchCandidateSet, WorktreeId};
use ui::{prelude::*, ListItem};

View file

@ -4,7 +4,9 @@ use std::sync::Arc;
use anyhow::{bail, Context as _, Result};
use futures::AsyncReadExt as _;
use gpui::{AppContext, DismissEvent, FocusHandle, FocusableView, Task, Model, WeakModel, WeakModel};
use gpui::{
AppContext, DismissEvent, FocusHandle, FocusableView, Model, Task, WeakModel, WeakModel,
};
use html_to_markdown::{convert_html_to_markdown, markdown, TagHandler};
use http_client::{AsyncBody, HttpClientWithUrl};
use picker::{Picker, PickerDelegate};

View file

@ -1,7 +1,9 @@
use std::sync::Arc;
use fuzzy::StringMatchCandidate;
use gpui::{AppContext, DismissEvent, FocusHandle, FocusableView, Task, Model, WeakModel, WeakModel};
use gpui::{
AppContext, DismissEvent, FocusHandle, FocusableView, Model, Task, WeakModel, WeakModel,
};
use picker::{Picker, PickerDelegate};
use ui::{prelude::*, ListItem};

View file

@ -18,7 +18,7 @@ use feature_flags::{FeatureFlagAppExt as _, ZedPro};
use fs::Fs;
use gpui::{
anchored, deferred, point, AnyElement, AppContext, ClickEvent, CursorStyle, EventEmitter,
FocusHandle, FocusableView, FontWeight, Model, Subscription, TextStyle, Model, ViewContext,
FocusHandle, FocusableView, FontWeight, Model, Model, Subscription, TextStyle, ViewContext,
WeakModel, WeakModel, WindowContext,
};
use language_model::{LanguageModel, LanguageModelRegistry};

View file

@ -2,7 +2,7 @@ mod update_notification;
use auto_update::AutoUpdater;
use editor::{Editor, MultiBuffer};
use gpui::{actions, prelude::*, AppContext, SharedString, Model, ViewContext};
use gpui::{actions, prelude::*, AppContext, Model, SharedString, ViewContext};
use http_client::HttpClient;
use markdown_preview::markdown_preview_view::{MarkdownPreviewMode, MarkdownPreviewView};
use release_channel::{AppVersion, ReleaseChannel};

View file

@ -8,8 +8,8 @@ use collab_ui::{
};
use editor::{Editor, ExcerptRange, MultiBuffer};
use gpui::{
point, BackgroundExecutor, BorrowAppContext, Context, Entity, SharedString, TestAppContext,
Model, VisualContext, VisualTestContext,
point, BackgroundExecutor, BorrowAppContext, Context, Entity, Model, SharedString,
TestAppContext, VisualContext, VisualTestContext,
};
use language::Capability;
use project::WorktreeSettings;

View file

@ -17,7 +17,7 @@ use collections::{HashMap, HashSet};
use fs::FakeFs;
use futures::{channel::oneshot, StreamExt as _};
use git::GitHostingProviderRegistry;
use gpui::{BackgroundExecutor, Context, Model, Task, TestAppContext, Model, VisualTestContext};
use gpui::{BackgroundExecutor, Context, Model, Model, Task, TestAppContext, VisualTestContext};
use http_client::FakeHttpClient;
use language::LanguageRegistry;
use node_runtime::NodeRuntime;

View file

@ -12,7 +12,7 @@ use editor::{
};
use gpui::{
actions, AnyView, AppContext, ClipboardItem, Entity as _, EventEmitter, FocusableView, Model,
Pixels, Point, Render, Subscription, Task, Model, ViewContext, VisualContext as _, WeakModel,
Model, Pixels, Point, Render, Subscription, Task, ViewContext, VisualContext as _, WeakModel,
WindowContext,
};
use project::Project;

View file

@ -9,8 +9,8 @@ use editor::{actions, Editor};
use gpui::{
actions, div, list, prelude::*, px, Action, AppContext, AsyncWindowContext, ClipboardItem,
CursorStyle, DismissEvent, ElementId, EventEmitter, FocusHandle, FocusableView, FontWeight,
HighlightStyle, ListOffset, ListScrollEvent, ListState, Model, Render, Stateful, Subscription,
Task, Model, ViewContext, VisualContext, WeakModel,
HighlightStyle, ListOffset, ListScrollEvent, ListState, Model, Model, Render, Stateful,
Subscription, Task, ViewContext, VisualContext, WeakModel,
};
use language::LanguageRegistry;
use menu::Confirm;

View file

@ -14,8 +14,8 @@ use gpui::{
actions, anchored, canvas, deferred, div, fill, list, point, prelude::*, px, AnyElement,
AppContext, AsyncWindowContext, Bounds, ClickEvent, ClipboardItem, DismissEvent, Div,
EventEmitter, FocusHandle, FocusableView, FontStyle, InteractiveElement, IntoElement,
ListOffset, ListState, Model, MouseDownEvent, ParentElement, Pixels, Point, PromptLevel,
Render, SharedString, Styled, Subscription, Task, TextStyle, Model, ViewContext, VisualContext,
ListOffset, ListState, Model, Model, MouseDownEvent, ParentElement, Pixels, Point, PromptLevel,
Render, SharedString, Styled, Subscription, Task, TextStyle, ViewContext, VisualContext,
WeakModel,
};
use menu::{Cancel, Confirm, SecondaryConfirm, SelectNext, SelectPrev};

View file

@ -1,7 +1,7 @@
use client::{ContactRequestStatus, User, UserStore};
use gpui::{
AppContext, DismissEvent, EventEmitter, FocusHandle, FocusableView, Model, ParentElement as _,
Render, Styled, Task, Model, ViewContext, VisualContext, WeakModel,
AppContext, DismissEvent, EventEmitter, FocusHandle, FocusableView, Model, Model,
ParentElement as _, Render, Styled, Task, ViewContext, VisualContext, WeakModel,
};
use picker::{Picker, PickerDelegate};
use std::sync::Arc;

View file

@ -8,9 +8,8 @@ use futures::StreamExt;
use gpui::{
actions, div, img, list, px, AnyElement, AppContext, AsyncWindowContext, CursorStyle,
DismissEvent, Element, EventEmitter, FocusHandle, FocusableView, InteractiveElement,
IntoElement, ListAlignment, ListScrollEvent, ListState, Model, ParentElement, Render,
StatefulInteractiveElement, Styled, Task, Model, ViewContext, VisualContext, WeakModel,
WindowContext,
IntoElement, ListAlignment, ListScrollEvent, ListState, Model, Model, ParentElement, Render,
StatefulInteractiveElement, Styled, Task, ViewContext, VisualContext, WeakModel, WindowContext,
};
use notifications::{NotificationEntry, NotificationEvent, NotificationStore};
use project::Fs;

View file

@ -16,9 +16,9 @@ use editor::{
};
use gpui::{
actions, div, svg, AnyElement, AnyView, AppContext, Context, EventEmitter, FocusHandle,
FocusableView, Global, HighlightStyle, InteractiveElement, IntoElement, Model, ParentElement,
Render, SharedString, Styled, StyledText, Subscription, Task, Model, ViewContext, VisualContext,
WeakModel, WindowContext,
FocusableView, Global, HighlightStyle, InteractiveElement, IntoElement, Model, Model,
ParentElement, Render, SharedString, Styled, StyledText, Subscription, Task, ViewContext,
VisualContext, WeakModel, WindowContext,
};
use language::{
Bias, Buffer, Diagnostic, DiagnosticEntry, DiagnosticSeverity, Point, Selection, SelectionGoal,

View file

@ -1,5 +1,5 @@
use crate::ProjectDiagnosticsEditor;
use gpui::{EventEmitter, ParentElement, Render, Model, ViewContext, WeakModel};
use gpui::{EventEmitter, Model, ParentElement, Render, ViewContext, WeakModel};
use ui::prelude::*;
use ui::{IconButton, IconButtonShape, IconName, Tooltip};
use workspace::{item::ItemHandle, ToolbarItemEvent, ToolbarItemLocation, ToolbarItemView};

View file

@ -80,11 +80,11 @@ use gpui::{
div, impl_actions, point, prelude::*, px, relative, size, Action, AnyElement, AppContext,
AsyncWindowContext, AvailableSpace, Bounds, ClipboardEntry, ClipboardItem, Context,
DispatchPhase, ElementId, EventEmitter, FocusHandle, FocusOutEvent, FocusableView, FontId,
FontWeight, Global, HighlightStyle, Hsla, InteractiveText, KeyContext, Model, ModelContext,
MouseButton, PaintQuad, ParentElement, Pixels, Render, SharedString, Size, Styled, StyledText,
Subscription, Task, TextStyle, TextStyleRefinement, UTF16Selection, UnderlineStyle,
UniformListScrollHandle, Model, ViewContext, ViewInputHandler, VisualContext, WeakFocusHandle,
WeakModel, WindowContext,
FontWeight, Global, HighlightStyle, Hsla, InteractiveText, KeyContext, Model, Model,
ModelContext, MouseButton, PaintQuad, ParentElement, Pixels, Render, SharedString, Size,
Styled, StyledText, Subscription, Task, TextStyle, TextStyleRefinement, UTF16Selection,
UnderlineStyle, UniformListScrollHandle, ViewContext, ViewInputHandler, VisualContext,
WeakFocusHandle, WeakModel, WindowContext,
};
use highlight_matching_bracket::refresh_matching_bracket_highlights;
use hover_popover::{hide_hover, HoverState};
@ -679,7 +679,11 @@ pub struct Editor {
custom_context_menu: Option<
Box<
dyn 'static
+ Fn(&mut Self, DisplayPoint, &mut ViewContext<Self>) -> Option<Model<ui::ContextMenu>>,
+ Fn(
&mut Self,
DisplayPoint,
&mut ViewContext<Self>,
) -> Option<Model<ui::ContextMenu>>,
>,
>,
last_bounds: Option<Bounds<Pixels>>,

View file

@ -15,7 +15,7 @@ use git::{
};
use gpui::{
actions, AnyElement, AnyView, AppContext, EventEmitter, FocusHandle, FocusableView,
InteractiveElement, Model, Render, Subscription, Task, Model, WeakModel,
InteractiveElement, Model, Model, Render, Subscription, Task, WeakModel,
};
use language::{Buffer, BufferRow};
use multi_buffer::{ExcerptId, ExcerptRange, ExpandExcerptDirection, MultiBuffer};

View file

@ -7,8 +7,8 @@ use crate::{
};
use gpui::{
div, px, AnyElement, AsyncWindowContext, FontWeight, Hsla, InteractiveElement, IntoElement,
MouseButton, ParentElement, Pixels, ScrollHandle, Size, Stateful, StatefulInteractiveElement,
StyleRefinement, Styled, Task, TextStyleRefinement, Model, ViewContext,
Model, MouseButton, ParentElement, Pixels, ScrollHandle, Size, Stateful,
StatefulInteractiveElement, StyleRefinement, Styled, Task, TextStyleRefinement, ViewContext,
};
use itertools::Itertools;
use language::{Diagnostic, DiagnosticEntry, Language, LanguageRegistry};

View file

@ -1,7 +1,7 @@
use collections::{HashMap, HashSet};
use git::diff::DiffHunkStatus;
use gpui::{
Action, AppContext, Corner, CursorStyle, Hsla, Model, MouseButton, Subscription, Task, Model,
Action, AppContext, Corner, CursorStyle, Hsla, Model, Model, MouseButton, Subscription, Task,
};
use language::{Buffer, BufferId, Point};
use multi_buffer::{

View file

@ -6,7 +6,7 @@ use crate::{
SelectMode, ToDisplayPoint, ToggleCodeActions,
};
use gpui::prelude::FluentBuilder;
use gpui::{DismissEvent, Pixels, Point, Subscription, Model, ViewContext};
use gpui::{DismissEvent, Model, Pixels, Point, Subscription, ViewContext};
use std::ops::Range;
use text::PointUtf16;
use workspace::OpenInTerminal;

View file

@ -1,7 +1,7 @@
use crate::{ApplyAllDiffHunks, Editor, EditorEvent, SemanticsProvider};
use collections::HashSet;
use futures::{channel::mpsc, future::join_all};
use gpui::{AppContext, EventEmitter, FocusableView, Model, Render, Subscription, Task, Model};
use gpui::{AppContext, EventEmitter, FocusableView, Model, Model, Render, Subscription, Task};
use language::{Buffer, BufferEvent, Capability};
use multi_buffer::{ExcerptRange, MultiBuffer};
use project::{buffer_store::BufferChangeSet, Project};

View file

@ -6,7 +6,7 @@ use collections::BTreeMap;
use futures::Future;
use git::diff::DiffHunkStatus;
use gpui::{
prelude::*, AnyWindowHandle, AppContext, Keystroke, ModelContext, Pixels, Point, Model,
prelude::*, AnyWindowHandle, AppContext, Keystroke, Model, ModelContext, Pixels, Point,
ViewContext, VisualTestContext, WindowHandle,
};
use itertools::Itertools;

View file

@ -6,7 +6,7 @@ use extension_host::{ExtensionSettings, ExtensionStore};
use fs::Fs;
use fuzzy::{match_strings, StringMatch, StringMatchCandidate};
use gpui::{
prelude::*, AppContext, DismissEvent, EventEmitter, FocusableView, Task, Model, WeakModel,
prelude::*, AppContext, DismissEvent, EventEmitter, FocusableView, Model, Task, WeakModel,
};
use picker::{Picker, PickerDelegate};
use release_channel::ReleaseChannel;

View file

@ -14,8 +14,8 @@ use extension_host::{ExtensionManifest, ExtensionOperation, ExtensionStore};
use fuzzy::{match_strings, StringMatchCandidate};
use gpui::{
actions, uniform_list, Action, AppContext, ClipboardItem, EventEmitter, Flatten, FocusableView,
InteractiveElement, KeyContext, ParentElement, Render, Styled, Task, TextStyle,
UniformListScrollHandle, Model, ViewContext, VisualContext, WeakModel, WindowContext,
InteractiveElement, KeyContext, Model, ParentElement, Render, Styled, Task, TextStyle,
UniformListScrollHandle, ViewContext, VisualContext, WeakModel, WindowContext,
};
use num_format::{Locale, ToFormattedString};
use project::DirectoryLister;
@ -802,7 +802,11 @@ impl ExtensionsPage {
)
}
fn render_text_input(&self, editor: &Model<Editor>, cx: &ViewContext<Self>) -> impl IntoElement {
fn render_text_input(
&self,
editor: &Model<Editor>,
cx: &ViewContext<Self>,
) -> impl IntoElement {
let settings = ThemeSettings::get_global(cx);
let text_style = TextStyle {
color: if editor.read(cx).read_only(cx) {

View file

@ -107,7 +107,7 @@ impl FeatureFlag for AutoCommand {
pub trait FeatureFlagViewExt<V: 'static> {
fn observe_flag<T: FeatureFlag, F>(&mut self, callback: F) -> Subscription
where
F: for<'f> Fn(bool, &mut V, & mut ModelContext<'f, V>) + Send + Sync + 'static;
F: for<'f> Fn(bool, &mut V, &mut ModelContext<'f, V>) + Send + Sync + 'static;
}
impl<V> FeatureFlagViewExt<V> for ViewContext<'_, V>
@ -116,7 +116,7 @@ where
{
fn observe_flag<T: FeatureFlag, F>(&mut self, callback: F) -> Subscription
where
F: for<'f> Fn(bool, &mut V, & mut ModelContext<'f, V>) + 'static,
F: for<'f> Fn(bool, &mut V, &mut ModelContext<'f, V>) + 'static,
{
self.observe_global::<FeatureFlags>(move |v, cx| {
let feature_flags = cx.global::<FeatureFlags>();

View file

@ -11,8 +11,8 @@ use db::kvp::KEY_VALUE_STORE;
use editor::{Editor, EditorEvent};
use futures::AsyncReadExt;
use gpui::{
div, rems, AppContext, DismissEvent, EventEmitter, FocusHandle, FocusableView, Model,
PromptLevel, Render, Task, Model, ViewContext,
div, rems, AppContext, DismissEvent, EventEmitter, FocusHandle, FocusableView, Model, Model,
PromptLevel, Render, Task, ViewContext,
};
use http_client::HttpClient;
use language::Buffer;

View file

@ -15,8 +15,8 @@ use file_icons::FileIcons;
use fuzzy::{CharBag, PathMatch, PathMatchCandidate};
use gpui::{
actions, Action, AnyElement, AppContext, DismissEvent, EventEmitter, FocusHandle,
FocusableView, KeyContext, Model, Modifiers, ModifiersChangedEvent, ParentElement, Render,
Styled, Task, Model, ViewContext, VisualContext, WeakModel,
FocusableView, KeyContext, Model, Model, Modifiers, ModifiersChangedEvent, ParentElement,
Render, Styled, Task, ViewContext, VisualContext, WeakModel,
};
use new_path_prompt::NewPathPrompt;
use open_path_prompt::OpenPathPrompt;

View file

@ -1,5 +1,5 @@
use editor::{Editor, ToPoint};
use gpui::{AppContext, FocusHandle, FocusableView, Subscription, Task, Model, WeakModel};
use gpui::{AppContext, FocusHandle, FocusableView, Model, Subscription, Task, WeakModel};
use schemars::JsonSchema;
use serde::{Deserialize, Serialize};
use settings::{Settings, SettingsSources};

View file

@ -4,7 +4,7 @@ use cursor_position::LineIndicatorFormat;
use editor::{scroll::Autoscroll, Editor};
use gpui::{
div, prelude::*, AnyWindowHandle, AppContext, DismissEvent, EventEmitter, FocusHandle,
FocusableView, Render, SharedString, Styled, Subscription, Model, ViewContext, VisualContext,
FocusableView, Model, Render, SharedString, Styled, Subscription, ViewContext, VisualContext,
};
use settings::Settings;
use text::{Bias, Point};

View file

@ -4,8 +4,8 @@ use anyhow::Context as _;
use editor::items::entry_git_aware_label_color;
use gpui::{
canvas, div, fill, img, opaque_grey, point, size, AnyElement, AppContext, Bounds, EventEmitter,
FocusHandle, FocusableView, InteractiveElement, IntoElement, Model, ObjectFit, ParentElement,
Render, Styled, Task, Model, ViewContext, VisualContext, WeakModel, WindowContext,
FocusHandle, FocusableView, InteractiveElement, IntoElement, Model, Model, ObjectFit,
ParentElement, Render, Styled, Task, ViewContext, VisualContext, WeakModel, WindowContext,
};
use persistence::IMAGE_VIEWER;
use theme::Theme;

View file

@ -4,8 +4,8 @@ use editor::{scroll::Autoscroll, Editor};
use feature_flags::{FeatureFlagAppExt, ZetaFeatureFlag};
use fs::Fs;
use gpui::{
actions, div, Action, AppContext, AsyncWindowContext, Corner, Entity, IntoElement,
ParentElement, Render, Subscription, Model, ViewContext, WeakModel, WindowContext,
actions, div, Action, AppContext, AsyncWindowContext, Corner, Entity, IntoElement, Model,
ParentElement, Render, Subscription, ViewContext, WeakModel, WindowContext,
};
use language::{
language_settings::{

View file

@ -2,8 +2,8 @@ use std::sync::Arc;
use feature_flags::ZedPro;
use gpui::{
Action, AnyElement, AppContext, DismissEvent, EventEmitter, FocusHandle, FocusableView, Task,
Model, WeakModel,
Action, AnyElement, AppContext, DismissEvent, EventEmitter, FocusHandle, FocusableView, Model,
Task, WeakModel,
};
use language_model::{LanguageModel, LanguageModelAvailability, LanguageModelRegistry};
use picker::{Picker, PickerDelegate};

View file

@ -6,8 +6,8 @@ use editor::{Editor, EditorElement, EditorStyle};
use futures::Stream;
use futures::{future::BoxFuture, stream::BoxStream, FutureExt, StreamExt, TryStreamExt as _};
use gpui::{
AnyView, AppContext, AsyncAppContext, FontStyle, ModelContext, Subscription, Task, TextStyle,
Model, WhiteSpace,
AnyView, AppContext, AsyncAppContext, FontStyle, Model, ModelContext, Subscription, Task,
TextStyle, WhiteSpace,
};
use http_client::HttpClient;
use language_model::{

View file

@ -4,8 +4,8 @@ use editor::{Editor, EditorElement, EditorStyle};
use futures::{future::BoxFuture, FutureExt, StreamExt};
use google_ai::stream_generate_content;
use gpui::{
AnyView, AppContext, AsyncAppContext, FontStyle, ModelContext, Subscription, Task, TextStyle,
Model, WhiteSpace,
AnyView, AppContext, AsyncAppContext, FontStyle, Model, ModelContext, Subscription, Task,
TextStyle, WhiteSpace,
};
use http_client::HttpClient;
use language_model::LanguageModelCompletionEvent;

View file

@ -3,8 +3,8 @@ use collections::BTreeMap;
use editor::{Editor, EditorElement, EditorStyle};
use futures::{future::BoxFuture, FutureExt, StreamExt};
use gpui::{
AnyView, AppContext, AsyncAppContext, FontStyle, ModelContext, Subscription, Task, TextStyle,
Model, WhiteSpace,
AnyView, AppContext, AsyncAppContext, FontStyle, Model, ModelContext, Subscription, Task,
TextStyle, WhiteSpace,
};
use http_client::HttpClient;
use language_model::{

View file

@ -1,5 +1,5 @@
use editor::Editor;
use gpui::{div, IntoElement, ParentElement, Render, Subscription, Model, ViewContext, WeakModel};
use gpui::{div, IntoElement, Model, ParentElement, Render, Subscription, ViewContext, WeakModel};
use language::LanguageName;
use ui::{Button, ButtonCommon, Clickable, FluentBuilder, LabelSize, Tooltip};
use workspace::{item::ItemHandle, StatusItemView, Workspace};

View file

@ -7,8 +7,8 @@ use file_finder::file_finder_settings::FileFinderSettings;
use file_icons::FileIcons;
use fuzzy::{match_strings, StringMatch, StringMatchCandidate};
use gpui::{
actions, AppContext, DismissEvent, EventEmitter, FocusHandle, FocusableView, Model,
ParentElement, Render, Styled, Model, ViewContext, VisualContext, WeakModel,
actions, AppContext, DismissEvent, EventEmitter, FocusHandle, FocusableView, Model, Model,
ParentElement, Render, Styled, ViewContext, VisualContext, WeakModel,
};
use language::{Buffer, LanguageMatcher, LanguageName, LanguageRegistry};
use picker::{Picker, PickerDelegate};

View file

@ -4,7 +4,7 @@ use editor::{actions::MoveToEnd, Editor, EditorEvent};
use futures::{channel::mpsc, StreamExt};
use gpui::{
actions, div, AppContext, Context, Corner, EventEmitter, FocusHandle, FocusableView,
IntoElement, Model, ModelContext, ParentElement, Render, Styled, Subscription, Model,
IntoElement, Model, Model, ModelContext, ParentElement, Render, Styled, Subscription,
ViewContext, VisualContext, WeakModel, WindowContext,
};
use language::LanguageServerId;

View file

@ -6,9 +6,9 @@
use gpui::{
actions, bounds, div, point,
prelude::{FluentBuilder as _, IntoElement},
px, rgb, size, AsyncAppContext, Bounds, InteractiveElement, KeyBinding, Menu, MenuItem,
px, rgb, size, AsyncAppContext, Bounds, InteractiveElement, KeyBinding, Menu, MenuItem, Model,
ParentElement, Pixels, Render, ScreenCaptureStream, SharedString,
StatefulInteractiveElement as _, Styled, Task, Model, ViewContext, VisualContext, WindowBounds,
StatefulInteractiveElement as _, Styled, Task, ViewContext, VisualContext, WindowBounds,
WindowHandle, WindowOptions,
};
#[cfg(not(target_os = "windows"))]

View file

@ -1,5 +1,5 @@
use assets::Assets;
use gpui::{prelude::*, rgb, App, KeyBinding, StyleRefinement, Model, WindowOptions};
use gpui::{prelude::*, rgb, App, KeyBinding, Model, StyleRefinement, WindowOptions};
use language::{language_settings::AllLanguageSettings, LanguageRegistry};
use markdown::{Markdown, MarkdownStyle};
use node_runtime::NodeRuntime;

View file

@ -5,9 +5,9 @@ use futures::FutureExt;
use gpui::{
actions, point, quad, AnyElement, AppContext, Bounds, ClipboardItem, CursorStyle,
DispatchPhase, Edges, FocusHandle, FocusableView, FontStyle, FontWeight, GlobalElementId,
Hitbox, Hsla, KeyContext, Length, MouseDownEvent, MouseEvent, MouseMoveEvent, MouseUpEvent,
Point, Render, StrikethroughStyle, StyleRefinement, StyledText, Task, TextLayout, TextRun,
TextStyle, TextStyleRefinement, Model,
Hitbox, Hsla, KeyContext, Length, Model, MouseDownEvent, MouseEvent, MouseMoveEvent,
MouseUpEvent, Point, Render, StrikethroughStyle, StyleRefinement, StyledText, Task, TextLayout,
TextRun, TextStyle, TextStyleRefinement,
};
use language::{Language, LanguageRegistry, Rope};
use parser::{parse_links_only, parse_markdown, MarkdownEvent, MarkdownTag, MarkdownTagEnd};

View file

@ -7,7 +7,7 @@ use crate::markdown_elements::{
use gpui::{
div, img, px, rems, AbsoluteLength, AnyElement, ClipboardItem, DefiniteLength, Div, Element,
ElementId, HighlightStyle, Hsla, ImageSource, InteractiveText, IntoElement, Keystroke, Length,
Modifiers, ParentElement, Render, Resource, SharedString, Styled, StyledText, TextStyle, Model,
Model, Modifiers, ParentElement, Render, Resource, SharedString, Styled, StyledText, TextStyle,
WeakModel, WindowContext,
};
use settings::Settings;

View file

@ -10,7 +10,7 @@ use editor::{
use fuzzy::StringMatch;
use gpui::{
div, rems, AppContext, DismissEvent, EventEmitter, FocusHandle, FocusableView, HighlightStyle,
ParentElement, Point, Render, Styled, StyledText, Task, TextStyle, Model, ViewContext,
Model, ParentElement, Point, Render, Styled, StyledText, Task, TextStyle, ViewContext,
VisualContext, WeakModel, WindowContext,
};
use language::{Outline, OutlineItem};

View file

@ -3,7 +3,7 @@ use editor::{scroll::Autoscroll, Editor};
use gpui::{
actions, div, impl_actions, list, prelude::*, uniform_list, AnyElement, AppContext, ClickEvent,
DismissEvent, EventEmitter, FocusHandle, FocusableView, Length, ListSizingBehavior, ListState,
MouseButton, MouseUpEvent, Render, ScrollStrategy, Task, UniformListScrollHandle, Model,
Model, MouseButton, MouseUpEvent, Render, ScrollStrategy, Task, UniformListScrollHandle,
ViewContext, WindowContext,
};
use head::Head;

View file

@ -6,8 +6,8 @@ pub use ssh_connections::{is_connecting_over_ssh, open_ssh_project};
use disconnected_overlay::DisconnectedOverlay;
use fuzzy::{StringMatch, StringMatchCandidate};
use gpui::{
Action, AnyElement, AppContext, DismissEvent, EventEmitter, FocusHandle, FocusableView,
Subscription, Task, Model, ViewContext, WeakModel,
Action, AnyElement, AppContext, DismissEvent, EventEmitter, FocusHandle, FocusableView, Model,
Subscription, Task, ViewContext, WeakModel,
};
use itertools::Itertools;
use ordered_float::OrderedFloat;

View file

@ -5,7 +5,7 @@ use futures::{
stream::{SelectAll, StreamExt},
AsyncBufReadExt as _, SinkExt as _,
};
use gpui::{EntityId, Task, Model, WindowContext};
use gpui::{EntityId, Model, Task, WindowContext};
use jupyter_protocol::{
connection_info::{ConnectionInfo, Transport},
ExecutionState, JupyterKernelspec, JupyterMessage, JupyterMessageContent, KernelInfoReply,

View file

@ -1,5 +1,5 @@
use futures::{channel::mpsc, SinkExt as _};
use gpui::{Task, Model, WindowContext};
use gpui::{Model, Task, WindowContext};
use http_client::{AsyncBody, HttpClient, Request};
use jupyter_protocol::{ExecutionState, JupyterKernelspec, JupyterMessage, KernelInfoReply};

View file

@ -3,7 +3,7 @@ use std::sync::Arc;
use editor::{Editor, EditorMode, MultiBuffer};
use futures::future::Shared;
use gpui::{prelude::*, AppContext, Hsla, Task, TextStyleRefinement, Model};
use gpui::{prelude::*, AppContext, Hsla, Model, Task, TextStyleRefinement};
use language::{Buffer, Language, LanguageRegistry};
use markdown_preview::{markdown_parser::parse_markdown, markdown_renderer::render_markdown_block};
use nbformat::v4::{CellId, CellMetadata, CellType};

View file

@ -10,7 +10,7 @@ use futures::future::Shared;
use futures::FutureExt;
use gpui::{
actions, list, prelude::*, AnyElement, AppContext, EventEmitter, FocusHandle, FocusableView,
ListScrollEvent, ListState, Model, Point, Task, Model,
ListScrollEvent, ListState, Model, Model, Point, Task,
};
use language::{Language, LanguageRegistry};
use project::{Project, ProjectEntryId, ProjectPath};

View file

@ -1,7 +1,7 @@
use editor::Editor;
use gpui::{
actions, prelude::*, AnyElement, AppContext, EventEmitter, FocusHandle, FocusableView,
Subscription, Model,
actions, prelude::*, AnyElement, AppContext, EventEmitter, FocusHandle, FocusableView, Model,
Subscription,
};
use project::ProjectItem as _;
use ui::{prelude::*, ButtonLike, ElevationIndex, KeyBinding};

View file

@ -4,7 +4,7 @@ use anyhow::Result;
use collections::HashMap;
use command_palette_hooks::CommandPaletteFilter;
use gpui::{
prelude::*, AppContext, EntityId, Global, Model, ModelContext, Subscription, Task, Model,
prelude::*, AppContext, EntityId, Global, Model, Model, ModelContext, Subscription, Task,
};
use jupyter_websocket_client::RemoteServer;
use language::Language;

View file

@ -14,8 +14,8 @@ use editor::{
use futures::channel::oneshot;
use gpui::{
actions, div, impl_actions, Action, AppContext, ClickEvent, EventEmitter, FocusHandle,
FocusableView, Hsla, InteractiveElement as _, IntoElement, KeyContext, ParentElement as _,
Render, ScrollHandle, Styled, Subscription, Task, TextStyle, Model, ViewContext,
FocusableView, Hsla, InteractiveElement as _, IntoElement, KeyContext, Model,
ParentElement as _, Render, ScrollHandle, Styled, Subscription, Task, TextStyle, ViewContext,
VisualContext as _, WindowContext,
};
use project::{
@ -1312,7 +1312,11 @@ mod tests {
fn init_test(
cx: &mut TestAppContext,
) -> (Model<Editor>, Model<BufferSearchBar>, &mut VisualTestContext) {
) -> (
Model<Editor>,
Model<BufferSearchBar>,
&mut VisualTestContext,
) {
init_globals(cx);
let buffer = cx.new_model(|cx| {
Buffer::local(

View file

@ -12,9 +12,9 @@ use futures::StreamExt;
use gpui::{
actions, div, Action, AnyElement, AnyView, AppContext, Axis, Context as _, EntityId,
EventEmitter, FocusHandle, FocusableView, Global, Hsla, InteractiveElement, IntoElement,
KeyContext, Model, ModelContext, ParentElement, Point, Render, SharedString, Styled,
Subscription, Task, TextStyle, UpdateGlobal, Model, ViewContext, VisualContext, WeakModel,
WeakModel, WindowContext,
KeyContext, Model, Model, ModelContext, ParentElement, Point, Render, SharedString, Styled,
Subscription, Task, TextStyle, UpdateGlobal, ViewContext, VisualContext, WeakModel, WeakModel,
WindowContext,
};
use language::Buffer;
use menu::Confirm;
@ -1551,7 +1551,11 @@ impl ProjectSearchBar {
}
}
fn render_text_input(&self, editor: &Model<Editor>, cx: &ViewContext<Self>) -> impl IntoElement {
fn render_text_input(
&self,
editor: &Model<Editor>,
cx: &ViewContext<Self>,
) -> impl IntoElement {
let settings = ThemeSettings::get_global(cx);
let text_style = TextStyle {
color: if editor.read(cx).read_only(cx) {

View file

@ -1,8 +1,8 @@
use crate::ProjectIndex;
use gpui::{
canvas, div, list, uniform_list, AnyElement, AppContext, CursorStyle, EventEmitter,
FocusHandle, FocusableView, IntoElement, ListOffset, ListState, Model, MouseMoveEvent, Render,
UniformListScrollHandle, Model,
FocusHandle, FocusableView, IntoElement, ListOffset, ListState, Model, Model, MouseMoveEvent,
Render, UniformListScrollHandle,
};
use project::WorktreeId;
use settings::Settings;

View file

@ -1,6 +1,6 @@
use editor::Editor;
use gpui::{
div, white, IntoElement, KeyBinding, ParentElement, Render, Styled, Model, ViewContext,
div, white, IntoElement, KeyBinding, Model, ParentElement, Render, Styled, ViewContext,
VisualContext, WindowContext,
};

View file

@ -1,6 +1,6 @@
use gpui::{
colors, div, prelude::*, DefaultColor, DefaultThemeAppearance, Hsla, Render, Model, ViewContext,
WindowContext,
colors, div, prelude::*, DefaultColor, DefaultThemeAppearance, Hsla, Model, Render,
ViewContext, WindowContext,
};
use story::Story;
use strum::IntoEnumIterator;

View file

@ -1,5 +1,5 @@
use gpui::{
actions, div, prelude::*, FocusHandle, KeyBinding, Render, Subscription, Model, WindowContext,
actions, div, prelude::*, FocusHandle, KeyBinding, Model, Render, Subscription, WindowContext,
};
use ui::prelude::*;

View file

@ -1,4 +1,4 @@
use gpui::{prelude::*, Render, Model};
use gpui::{prelude::*, Model, Render};
use story::Story;
use strum::IntoEnumIterator;
use ui::prelude::*;

View file

@ -1,5 +1,5 @@
use fuzzy::StringMatchCandidate;
use gpui::{div, prelude::*, KeyBinding, Render, SharedString, Styled, Task, Model, WindowContext};
use gpui::{div, prelude::*, KeyBinding, Model, Render, SharedString, Styled, Task, WindowContext};
use picker::{Picker, PickerDelegate};
use std::sync::Arc;
use ui::{prelude::*, ListItemSpacing};

View file

@ -1,4 +1,4 @@
use gpui::{div, prelude::*, px, Render, SharedString, Styled, Model, WindowContext};
use gpui::{div, prelude::*, px, Model, Render, SharedString, Styled, WindowContext};
use ui::prelude::*;
use ui::Tooltip;

View file

@ -1,6 +1,6 @@
use gpui::{
div, green, red, HighlightStyle, InteractiveText, IntoElement, ParentElement, Render, Styled,
StyledText, Model, VisualContext, WindowContext,
div, green, red, HighlightStyle, InteractiveText, IntoElement, Model, ParentElement, Render,
Styled, StyledText, VisualContext, WindowContext,
};
use indoc::indoc;
use story::*;

View file

@ -4,8 +4,8 @@ use crate::active_item_selection_properties;
use fuzzy::{StringMatch, StringMatchCandidate};
use gpui::{
rems, Action, AnyElement, AppContext, DismissEvent, EventEmitter, FocusableView,
InteractiveElement, Model, ParentElement, Render, SharedString, Styled, Subscription, Task,
Model, ViewContext, VisualContext, WeakModel,
InteractiveElement, Model, Model, ParentElement, Render, SharedString, Styled, Subscription,
Task, ViewContext, VisualContext, WeakModel,
};
use picker::{highlighted_match_with_paths::HighlightedText, Picker, PickerDelegate};
use project::{task_store::TaskStore, TaskSourceKind};
@ -1048,7 +1048,10 @@ mod tests {
})
}
fn query(spawn_tasks: &Model<Picker<TasksModalDelegate>>, cx: &mut VisualTestContext) -> String {
fn query(
spawn_tasks: &Model<Picker<TasksModalDelegate>>,
cx: &mut VisualTestContext,
) -> String {
spawn_tasks.update(cx, |spawn_tasks, cx| spawn_tasks.query(cx))
}

View file

@ -3,9 +3,10 @@ use gpui::{
div, fill, point, px, relative, size, AnyElement, AvailableSpace, Bounds, ContentMask,
DispatchPhase, Element, ElementId, FocusHandle, Font, FontStyle, FontWeight, GlobalElementId,
HighlightStyle, Hitbox, Hsla, InputHandler, InteractiveElement, Interactivity, IntoElement,
LayoutId, Model, ModelContext, ModifiersChangedEvent, MouseButton, MouseMoveEvent, Pixels,
Point, ShapedLine, StatefulInteractiveElement, StrikethroughStyle, Styled, TextRun, TextStyle,
UTF16Selection, UnderlineStyle, Model, WeakModel, WhiteSpace, WindowContext, WindowTextSystem,
LayoutId, Model, Model, ModelContext, ModifiersChangedEvent, MouseButton, MouseMoveEvent,
Pixels, Point, ShapedLine, StatefulInteractiveElement, StrikethroughStyle, Styled, TextRun,
TextStyle, UTF16Selection, UnderlineStyle, WeakModel, WhiteSpace, WindowContext,
WindowTextSystem,
};
use itertools::Itertools;
use language::CursorShape;

View file

@ -7,9 +7,9 @@ use editor::{actions::SelectAll, scroll::Autoscroll, Editor};
use futures::{stream::FuturesUnordered, StreamExt};
use gpui::{
anchored, deferred, div, impl_actions, AnyElement, AppContext, DismissEvent, EventEmitter,
FocusHandle, FocusableView, KeyContext, KeyDownEvent, Keystroke, Model, MouseButton,
MouseDownEvent, Pixels, Render, ScrollWheelEvent, Styled, Subscription, Task, Model,
VisualContext, WeakModel, WeakModel,
FocusHandle, FocusableView, KeyContext, KeyDownEvent, Keystroke, Model, Model, MouseButton,
MouseDownEvent, Pixels, Render, ScrollWheelEvent, Styled, Subscription, Task, VisualContext,
WeakModel, WeakModel,
};
use language::Bias;
use persistence::TERMINAL_DB;

View file

@ -1,7 +1,7 @@
use fs::Fs;
use fuzzy::{match_strings, StringMatch, StringMatchCandidate};
use gpui::{
actions, AppContext, DismissEvent, EventEmitter, FocusableView, Render, UpdateGlobal, Model,
actions, AppContext, DismissEvent, EventEmitter, FocusableView, Model, Render, UpdateGlobal,
ViewContext, VisualContext, WeakModel,
};
use picker::{Picker, PickerDelegate};

View file

@ -1,4 +1,4 @@
use gpui::{OwnedMenu, OwnedMenuItem, Model};
use gpui::{Model, OwnedMenu, OwnedMenuItem};
use smallvec::SmallVec;
use ui::{prelude::*, ContextMenu, PopoverMenu, PopoverMenuHandle, Tooltip};

View file

@ -1,4 +1,4 @@
use gpui::{Render, Model};
use gpui::{Model, Render};
use story::{Story, StoryItem, StorySection};
use ui::prelude::*;

View file

@ -14,8 +14,8 @@ use client::{Client, UserStore};
use feature_flags::{FeatureFlagAppExt, ZedPro};
use gpui::{
actions, div, px, Action, AnyElement, AppContext, Decorations, Element, InteractiveElement,
Interactivity, IntoElement, Model, MouseButton, ParentElement, Render, Stateful,
StatefulInteractiveElement, Styled, Subscription, Model, ViewContext, VisualContext, WeakModel,
Interactivity, IntoElement, Model, Model, MouseButton, ParentElement, Render, Stateful,
StatefulInteractiveElement, Styled, Subscription, ViewContext, VisualContext, WeakModel,
};
use project::{Project, RepositoryEntry};
use rpc::proto;

View file

@ -1,6 +1,6 @@
use editor::Editor;
use gpui::{
div, AsyncWindowContext, IntoElement, ParentElement, Render, Subscription, Task, Model,
div, AsyncWindowContext, IntoElement, Model, ParentElement, Render, Subscription, Task,
ViewContext, WeakModel, WeakModel,
};
use language::{Buffer, BufferEvent, LanguageName, Toolchain};

View file

@ -4,8 +4,8 @@ pub use active_toolchain::ActiveToolchain;
use editor::Editor;
use fuzzy::{match_strings, StringMatch, StringMatchCandidate};
use gpui::{
actions, AppContext, DismissEvent, EventEmitter, FocusHandle, FocusableView, Model,
ParentElement, Render, Styled, Task, Model, ViewContext, VisualContext, WeakModel,
actions, AppContext, DismissEvent, EventEmitter, FocusHandle, FocusableView, Model, Model,
ParentElement, Render, Styled, Task, ViewContext, VisualContext, WeakModel,
};
use language::{LanguageName, Toolchain, ToolchainList};
use picker::{Picker, PickerDelegate};

View file

@ -1,5 +1,5 @@
#![allow(missing_docs)]
use gpui::{ClickEvent, Corner, CursorStyle, MouseButton, Model};
use gpui::{ClickEvent, Corner, CursorStyle, Model, MouseButton};
use crate::{prelude::*, ContextMenu, PopoverMenu};

View file

@ -2,7 +2,7 @@
use std::{cmp::Ordering, ops::Range, rc::Rc};
use gpui::{
fill, point, size, AnyElement, AppContext, Bounds, Hsla, Point, UniformListDecoration, Model,
fill, point, size, AnyElement, AppContext, Bounds, Hsla, Model, Point, UniformListDecoration,
};
use smallvec::SmallVec;

View file

@ -5,8 +5,8 @@ use std::{cell::RefCell, rc::Rc};
use gpui::{
anchored, deferred, div, point, prelude::FluentBuilder, px, size, AnyElement, Bounds, Corner,
DismissEvent, DispatchPhase, Element, ElementId, GlobalElementId, HitboxId, InteractiveElement,
IntoElement, LayoutId, Length, ManagedView, MouseDownEvent, ParentElement, Pixels, Point,
Style, Model, VisualContext, WindowContext,
IntoElement, LayoutId, Length, ManagedView, Model, MouseDownEvent, ParentElement, Pixels,
Point, Style, VisualContext, WindowContext,
};
use crate::prelude::*;

View file

@ -5,7 +5,7 @@ use std::{cell::RefCell, rc::Rc};
use gpui::{
anchored, deferred, div, px, AnyElement, Bounds, Corner, DismissEvent, DispatchPhase, Element,
ElementId, GlobalElementId, Hitbox, InteractiveElement, IntoElement, LayoutId, ManagedView,
MouseButton, MouseDownEvent, ParentElement, Pixels, Point, Model, VisualContext, WindowContext,
Model, MouseButton, MouseDownEvent, ParentElement, Pixels, Point, VisualContext, WindowContext,
};
pub struct RightClickMenu<M: ManagedView> {

View file

@ -4,9 +4,9 @@ use std::{cell::Cell, ops::Range, rc::Rc};
use crate::{prelude::*, px, relative, IntoElement};
use gpui::{
point, quad, Along, Axis as ScrollbarAxis, Bounds, ContentMask, Corners, Edges, Element,
ElementId, Entity, EntityId, GlobalElementId, Hitbox, Hsla, LayoutId, MouseDownEvent,
ElementId, Entity, EntityId, GlobalElementId, Hitbox, Hsla, LayoutId, Model, MouseDownEvent,
MouseMoveEvent, MouseUpEvent, Pixels, Point, ScrollHandle, ScrollWheelEvent, Size, Style,
UniformListScrollHandle, Model, WindowContext,
UniformListScrollHandle, WindowContext,
};
pub struct Scrollbar {

View file

@ -1,4 +1,4 @@
use gpui::{actions, Corner, Render, Model};
use gpui::{actions, Corner, Model, Render};
use story::Story;
use crate::prelude::*;

View file

@ -3,8 +3,8 @@ use fuzzy::{StringMatch, StringMatchCandidate};
use git::repository::Branch;
use gpui::{
rems, AnyElement, AppContext, AsyncAppContext, DismissEvent, EventEmitter, FocusHandle,
FocusableView, InteractiveElement, IntoElement, ParentElement, Render, SharedString, Styled,
Subscription, Task, Model, ViewContext, VisualContext, WeakModel, WindowContext,
FocusableView, InteractiveElement, IntoElement, Model, ParentElement, Render, SharedString,
Styled, Subscription, Task, ViewContext, VisualContext, WeakModel, WindowContext,
};
use picker::{Picker, PickerDelegate};
use project::ProjectPath;

View file

@ -1,4 +1,4 @@
use gpui::{div, Element, Render, Subscription, Model, ViewContext, WeakModel};
use gpui::{div, Element, Model, Render, Subscription, ViewContext, WeakModel};
use itertools::Itertools;
use workspace::{item::ItemHandle, ui::prelude::*, StatusItemView};

View file

@ -1,7 +1,7 @@
use std::ops::{Deref, DerefMut};
use editor::test::editor_lsp_test_context::EditorLspTestContext;
use gpui::{Context, SemanticVersion, UpdateGlobal, Model, VisualContext};
use gpui::{Context, Model, SemanticVersion, UpdateGlobal, VisualContext};
use search::{project_search::ProjectSearchBar, BufferSearchBar};
use crate::{state::Operator, *};

View file

@ -27,7 +27,7 @@ use editor::{
};
use gpui::{
actions, impl_actions, Action, AppContext, Axis, Entity, EventEmitter, KeyContext,
KeystrokeEvent, Render, Subscription, Model, ViewContext, WeakModel,
KeystrokeEvent, Model, Render, Subscription, ViewContext, WeakModel,
};
use insert::{NormalBefore, TemporaryNormal};
use language::{CursorShape, Point, Selection, SelectionGoal, TransactionId};

View file

@ -1,7 +1,7 @@
use super::base_keymap_setting::BaseKeymap;
use fuzzy::{match_strings, StringMatch, StringMatchCandidate};
use gpui::{
actions, AppContext, DismissEvent, EventEmitter, FocusableView, Render, Task, Model,
actions, AppContext, DismissEvent, EventEmitter, FocusableView, Model, Render, Task,
ViewContext, VisualContext, WeakModel,
};
use picker::{Picker, PickerDelegate};

View file

@ -6,8 +6,8 @@ use client::{telemetry::Telemetry, TelemetrySettings};
use db::kvp::KEY_VALUE_STORE;
use gpui::{
actions, svg, Action, AppContext, EventEmitter, FocusHandle, FocusableView, InteractiveElement,
ParentElement, Render, Styled, Subscription, Task, Model, ViewContext, VisualContext, WeakModel,
WindowContext,
Model, ParentElement, Render, Styled, Subscription, Task, ViewContext, VisualContext,
WeakModel, WindowContext,
};
use settings::{Settings, SettingsStore};
use std::sync::Arc;

View file

@ -1,4 +1,4 @@
use gpui::{AnyView, DismissEvent, FocusHandle, ManagedView, Subscription, Model};
use gpui::{AnyView, DismissEvent, FocusHandle, ManagedView, Model, Subscription};
use ui::prelude::*;
pub enum DismissDecision {

View file

@ -2,7 +2,7 @@ use crate::{Toast, Workspace};
use collections::HashMap;
use gpui::{
svg, AnyView, AppContext, AsyncWindowContext, ClipboardItem, DismissEvent, Entity, EntityId,
EventEmitter, Global, PromptLevel, Render, ScrollHandle, Task, Model, ViewContext,
EventEmitter, Global, Model, PromptLevel, Render, ScrollHandle, Task, ViewContext,
VisualContext, WindowContext,
};
use language::DiagnosticSeverity;

View file

@ -2,7 +2,7 @@ use std::{any::Any, sync::Arc};
use any_vec::AnyVec;
use gpui::{
AnyView, AnyWeakView, AppContext, EventEmitter, Subscription, Task, Model, ViewContext,
AnyView, AnyWeakView, AppContext, EventEmitter, Model, Subscription, Task, ViewContext,
WeakModel, WindowContext,
};
use project::search::SearchQuery;

View file

@ -7,9 +7,8 @@ use call::participant::{Frame, RemoteVideoTrack};
use client::{proto::PeerId, User};
use futures::StreamExt;
use gpui::{
div, surface, AppContext, EventEmitter, FocusHandle, FocusableView, InteractiveElement,
ParentElement, Render, SharedString, Styled, Task, Model, ViewContext, VisualContext,
WindowContext,
div, surface, AppContext, EventEmitter, FocusHandle, FocusableView, InteractiveElement, Model,
ParentElement, Render, SharedString, Styled, Task, ViewContext, VisualContext, WindowContext,
};
use std::sync::{Arc, Weak};
use ui::{prelude::*, Icon, IconName};

View file

@ -1,6 +1,6 @@
use crate::{ItemHandle, Pane};
use gpui::{
AnyView, Decorations, IntoElement, ParentElement, Render, Styled, Subscription, Model,
AnyView, Decorations, IntoElement, Model, ParentElement, Render, Styled, Subscription,
ViewContext, WindowContext,
};
use std::any::TypeId;

View file

@ -1,7 +1,7 @@
use crate::ItemHandle;
use gpui::{
AnyView, Entity, EntityId, EventEmitter, ParentElement as _, Render, Styled, Model, ViewContext,
WindowContext,
AnyView, Entity, EntityId, EventEmitter, Model, ParentElement as _, Render, Styled,
ViewContext, WindowContext,
};
use ui::prelude::*;
use ui::{h_flex, v_flex};

View file

@ -22,9 +22,9 @@ use editor::{scroll::Autoscroll, Editor, MultiBuffer};
use feature_flags::FeatureFlagAppExt;
use futures::{channel::mpsc, select_biased, StreamExt};
use gpui::{
actions, point, px, AppContext, AsyncAppContext, Context, FocusableView, MenuItem,
PathPromptOptions, PromptLevel, ReadGlobal, Task, TitlebarOptions, Model, ViewContext,
VisualContext, WindowKind, WindowOptions,
actions, point, px, AppContext, AsyncAppContext, Context, FocusableView, MenuItem, Model,
PathPromptOptions, PromptLevel, ReadGlobal, Task, TitlebarOptions, ViewContext, VisualContext,
WindowKind, WindowOptions,
};
pub use open_listener::*;
use outline_panel::OutlinePanel;

View file

@ -11,7 +11,7 @@ use editor::actions::{
use editor::{Editor, EditorSettings};
use gpui::{
Action, ClickEvent, Corner, ElementId, EventEmitter, FocusHandle, FocusableView,
InteractiveElement, ParentElement, Render, Styled, Subscription, Model, ViewContext, WeakModel,
InteractiveElement, Model, ParentElement, Render, Styled, Subscription, ViewContext, WeakModel,
};
use search::{buffer_search, BufferSearchBar};
use settings::{Settings, SettingsStore};

View file

@ -1,7 +1,7 @@
use std::time::Duration;
use gpui::ElementId;
use gpui::{percentage, Animation, AnimationExt, AnyElement, Transformation, Model};
use gpui::{percentage, Animation, AnimationExt, AnyElement, Model, Transformation};
use picker::Picker;
use repl::{
components::{KernelPickerDelegate, KernelSelector},

View file

@ -2,7 +2,7 @@ use crate::{InlineCompletion, InlineCompletionRating, Zeta};
use editor::Editor;
use gpui::{
actions, prelude::*, AppContext, DismissEvent, EventEmitter, FocusHandle, FocusableView,
HighlightStyle, Model, StyledText, TextStyle, Model, ViewContext,
HighlightStyle, Model, Model, StyledText, TextStyle, ViewContext,
};
use language::{language_settings, OffsetRangeExt};
use settings::Settings;