Merge branch 'main' into core-actions
This commit is contained in:
commit
caa0bae04f
30 changed files with 1156 additions and 1031 deletions
|
@ -17,6 +17,7 @@ pub use only_instance::*;
|
|||
pub use open_listener::*;
|
||||
|
||||
use anyhow::{anyhow, Context as _, Result};
|
||||
use project_panel::ProjectPanel;
|
||||
use settings::{initial_local_settings_content, Settings};
|
||||
use std::{borrow::Cow, ops::Deref, sync::Arc};
|
||||
use util::{
|
||||
|
@ -27,8 +28,9 @@ use util::{
|
|||
};
|
||||
use uuid::Uuid;
|
||||
use workspace::{
|
||||
create_and_open_local_file, notifications::simple_message_notification::MessageNotification,
|
||||
open_new, AppState, NewFile, NewWindow, Workspace, WorkspaceSettings,
|
||||
create_and_open_local_file, dock::PanelHandle,
|
||||
notifications::simple_message_notification::MessageNotification, open_new, AppState, NewFile,
|
||||
NewWindow, Workspace, WorkspaceSettings,
|
||||
};
|
||||
use zed_actions::{OpenBrowser, OpenZedURL};
|
||||
|
||||
|
@ -380,49 +382,38 @@ pub fn initialize_workspace(
|
|||
// }
|
||||
// false
|
||||
// });
|
||||
// })?;
|
||||
})?;
|
||||
|
||||
// let project_panel = ProjectPanel::load(workspace_handle.clone(), cx.clone());
|
||||
// let terminal_panel = TerminalPanel::load(workspace_handle.clone(), cx.clone());
|
||||
// let assistant_panel = AssistantPanel::load(workspace_handle.clone(), cx.clone());
|
||||
// let channels_panel =
|
||||
// collab_ui::collab_panel::CollabPanel::load(workspace_handle.clone(), cx.clone());
|
||||
// let chat_panel =
|
||||
// collab_ui::chat_panel::ChatPanel::load(workspace_handle.clone(), cx.clone());
|
||||
// let notification_panel = collab_ui::notification_panel::NotificationPanel::load(
|
||||
// workspace_handle.clone(),
|
||||
// cx.clone(),
|
||||
// );
|
||||
// let (
|
||||
// project_panel,
|
||||
let project_panel = ProjectPanel::load(workspace_handle.clone(), cx.clone());
|
||||
// let terminal_panel = TerminalPanel::load(workspace_handle.clone(), cx.clone());
|
||||
// let assistant_panel = AssistantPanel::load(workspace_handle.clone(), cx.clone());
|
||||
// let channels_panel =
|
||||
// collab_ui::collab_panel::CollabPanel::load(workspace_handle.clone(), cx.clone());
|
||||
// let chat_panel =
|
||||
// collab_ui::chat_panel::ChatPanel::load(workspace_handle.clone(), cx.clone());
|
||||
// let notification_panel = collab_ui::notification_panel::NotificationPanel::load(
|
||||
// workspace_handle.clone(),
|
||||
// cx.clone(),
|
||||
// );
|
||||
let (
|
||||
project_panel,
|
||||
// terminal_panel,
|
||||
// assistant_panel,
|
||||
// channels_panel,
|
||||
// chat_panel,
|
||||
// notification_panel,
|
||||
// ) = futures::try_join!(
|
||||
// project_panel,
|
||||
) = futures::try_join!(
|
||||
project_panel,
|
||||
// terminal_panel,
|
||||
// assistant_panel,
|
||||
// channels_panel,
|
||||
// chat_panel,
|
||||
// notification_panel,
|
||||
// )?;
|
||||
// workspace_handle.update(&mut cx, |workspace, cx| {
|
||||
// let project_panel_position = project_panel.position(cx);
|
||||
// workspace.add_panel_with_extra_event_handler(
|
||||
// project_panel,
|
||||
// cx,
|
||||
// |workspace, _, event, cx| match event {
|
||||
// project_panel::Event::NewSearchInDirectory { dir_entry } => {
|
||||
// search::ProjectSearchView::new_search_in_directory(workspace, dir_entry, cx)
|
||||
// }
|
||||
// project_panel::Event::ActivatePanel => {
|
||||
// workspace.focus_panel::<ProjectPanel>(cx);
|
||||
// }
|
||||
// _ => {}
|
||||
// },
|
||||
// );
|
||||
)?;
|
||||
|
||||
workspace_handle.update(&mut cx, |workspace, cx| {
|
||||
let project_panel_position = project_panel.position(cx);
|
||||
workspace.add_panel(project_panel, cx);
|
||||
// workspace.add_panel(terminal_panel, cx);
|
||||
// workspace.add_panel(assistant_panel, cx);
|
||||
// workspace.add_panel(channels_panel, cx);
|
||||
|
@ -440,9 +431,9 @@ pub fn initialize_workspace(
|
|||
// .map_or(false, |entry| entry.is_dir())
|
||||
// })
|
||||
// {
|
||||
// workspace.toggle_dock(project_panel_position, cx);
|
||||
workspace.toggle_dock(project_panel_position, cx);
|
||||
// }
|
||||
// cx.focus_self();
|
||||
// cx.focus_self();
|
||||
})?;
|
||||
Ok(())
|
||||
})
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue