Use the same InlineAssist
action between both assistant
and assistant2
(#22126)
This PR makes it so `assistant` and `assistant2` both use the same action for inline assist (`zed_actions::InlineAssist`). This makes it so the keybindings to deploy the inline assist seamlessly swap based on the feature flag without needing to rebind them. One minor caveat: if you're using `assistant2` the action name in the command palette will be `assistant: inline assist`. Release Notes: - N/A
This commit is contained in:
parent
80431e5518
commit
3052fc2565
5 changed files with 29 additions and 11 deletions
|
@ -314,12 +314,13 @@ pub fn initialize_workspace(
|
|||
workspace_handle.update(&mut cx, |workspace, cx| {
|
||||
if let Some(assistant_panel) = assistant_panel {
|
||||
workspace.add_panel(assistant_panel, cx);
|
||||
workspace.register_action(assistant::AssistantPanel::inline_assist);
|
||||
}
|
||||
|
||||
if let Some(assistant2_panel) = assistant2_panel {
|
||||
workspace.add_panel(assistant2_panel, cx);
|
||||
workspace.register_action(assistant2::InlineAssistant::inline_assist);
|
||||
}
|
||||
|
||||
})
|
||||
})
|
||||
.detach();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue