Barebones project search (no UI, but the crate compiles)
This commit is contained in:
parent
ea708c50f0
commit
0c23e6738b
5 changed files with 759 additions and 750 deletions
1
Cargo.lock
generated
1
Cargo.lock
generated
|
@ -8252,6 +8252,7 @@ dependencies = [
|
|||
"menu2",
|
||||
"postage",
|
||||
"project2",
|
||||
"semantic_index2",
|
||||
"serde",
|
||||
"serde_derive",
|
||||
"serde_json",
|
||||
|
|
|
@ -8682,13 +8682,13 @@ impl Editor {
|
|||
);
|
||||
}
|
||||
|
||||
// pub fn set_searchable(&mut self, searchable: bool) {
|
||||
// self.searchable = searchable;
|
||||
// }
|
||||
pub fn set_searchable(&mut self, searchable: bool) {
|
||||
self.searchable = searchable;
|
||||
}
|
||||
|
||||
// pub fn searchable(&self) -> bool {
|
||||
// self.searchable
|
||||
// }
|
||||
pub fn searchable(&self) -> bool {
|
||||
self.searchable
|
||||
}
|
||||
|
||||
fn open_excerpts(&mut self, _: &OpenExcerpts, cx: &mut ViewContext<Self>) {
|
||||
let buffer = self.buffer.read(cx);
|
||||
|
|
|
@ -21,7 +21,7 @@ theme = { package = "theme2", path = "../theme2" }
|
|||
util = { path = "../util" }
|
||||
ui = {package = "ui2", path = "../ui2"}
|
||||
workspace = { package = "workspace2", path = "../workspace2" }
|
||||
#semantic_index = { path = "../semantic_index" }
|
||||
semantic_index = { package = "semantic_index2", path = "../semantic_index2" }
|
||||
anyhow.workspace = true
|
||||
futures.workspace = true
|
||||
log.workspace = true
|
||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -13,12 +13,12 @@ use ui::{ButtonStyle, Icon, IconButton};
|
|||
pub mod buffer_search;
|
||||
mod history;
|
||||
mod mode;
|
||||
//pub mod project_search;
|
||||
pub mod project_search;
|
||||
pub(crate) mod search_bar;
|
||||
|
||||
pub fn init(cx: &mut AppContext) {
|
||||
buffer_search::init(cx);
|
||||
//project_search::init(cx);
|
||||
project_search::init(cx);
|
||||
}
|
||||
|
||||
actions!(
|
||||
|
@ -44,6 +44,7 @@ bitflags! {
|
|||
const NONE = 0b000;
|
||||
const WHOLE_WORD = 0b001;
|
||||
const CASE_SENSITIVE = 0b010;
|
||||
const INCLUDE_IGNORED = 0b100;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue