Delete unused code
This commit is contained in:
parent
0efce8f70a
commit
a691c2fbdb
2 changed files with 3 additions and 16 deletions
|
@ -1,10 +1,10 @@
|
||||||
use crate::{Autoscroll, Editor, Event, MultiBuffer, NavigationData, ToOffset, ToPoint as _};
|
use crate::{Autoscroll, Editor, Event, NavigationData, ToOffset, ToPoint as _};
|
||||||
use anyhow::Result;
|
use anyhow::Result;
|
||||||
use gpui::{
|
use gpui::{
|
||||||
elements::*, AppContext, Entity, ModelHandle, RenderContext, Subscription, Task, View,
|
elements::*, AppContext, Entity, ModelHandle, RenderContext, Subscription, Task, View,
|
||||||
ViewContext, ViewHandle, WeakModelHandle,
|
ViewContext, ViewHandle,
|
||||||
};
|
};
|
||||||
use language::{Bias, Buffer, Diagnostic, File as _};
|
use language::{Bias, Diagnostic, File as _};
|
||||||
use project::{File, Project, ProjectPath};
|
use project::{File, Project, ProjectPath};
|
||||||
use std::fmt::Write;
|
use std::fmt::Write;
|
||||||
use std::path::PathBuf;
|
use std::path::PathBuf;
|
||||||
|
@ -12,18 +12,6 @@ use text::{Point, Selection};
|
||||||
use util::ResultExt;
|
use util::ResultExt;
|
||||||
use workspace::{Item, ItemHandle, ItemNavHistory, Settings, StatusItemView};
|
use workspace::{Item, ItemHandle, ItemNavHistory, Settings, StatusItemView};
|
||||||
|
|
||||||
#[derive(Clone)]
|
|
||||||
pub struct BufferItemHandle(pub ModelHandle<Buffer>);
|
|
||||||
|
|
||||||
#[derive(Clone)]
|
|
||||||
struct WeakBufferItemHandle(WeakModelHandle<Buffer>);
|
|
||||||
|
|
||||||
#[derive(Clone)]
|
|
||||||
pub struct MultiBufferItemHandle(pub ModelHandle<MultiBuffer>);
|
|
||||||
|
|
||||||
#[derive(Clone)]
|
|
||||||
struct WeakMultiBufferItemHandle(WeakModelHandle<MultiBuffer>);
|
|
||||||
|
|
||||||
impl Item for Editor {
|
impl Item for Editor {
|
||||||
fn navigate(&mut self, data: Box<dyn std::any::Any>, cx: &mut ViewContext<Self>) {
|
fn navigate(&mut self, data: Box<dyn std::any::Any>, cx: &mut ViewContext<Self>) {
|
||||||
if let Some(data) = data.downcast_ref::<NavigationData>() {
|
if let Some(data) = data.downcast_ref::<NavigationData>() {
|
||||||
|
|
|
@ -430,7 +430,6 @@ pub struct Workspace {
|
||||||
active_pane: ViewHandle<Pane>,
|
active_pane: ViewHandle<Pane>,
|
||||||
status_bar: ViewHandle<StatusBar>,
|
status_bar: ViewHandle<StatusBar>,
|
||||||
project: ModelHandle<Project>,
|
project: ModelHandle<Project>,
|
||||||
// items: BTreeMap<Reverse<usize>, Box<dyn WeakItemHandle>>,
|
|
||||||
_observe_current_user: Task<()>,
|
_observe_current_user: Task<()>,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue