Make editor::AcceptPartialCopilotSuggestion
a deprecated alias (#35507)
This is consistent with there being no copilot expecific variant of `editor::AcceptEditPrediction`. It also fixes a case where the `disable_ai: true` has effects at init time that aren't undone when changed, added in #35327. Release Notes: - N/A
This commit is contained in:
parent
a8422d4f77
commit
a50d0f2586
2 changed files with 3 additions and 16 deletions
|
@ -1,10 +1,10 @@
|
|||
use client::{Client, DisableAiSettings, UserStore};
|
||||
use client::{Client, UserStore};
|
||||
use collections::HashMap;
|
||||
use copilot::{Copilot, CopilotCompletionProvider};
|
||||
use editor::Editor;
|
||||
use gpui::{AnyWindowHandle, App, AppContext as _, Context, Entity, WeakEntity};
|
||||
use language::language_settings::{EditPredictionProvider, all_language_settings};
|
||||
use settings::{Settings as _, SettingsStore};
|
||||
use settings::SettingsStore;
|
||||
use smol::stream::StreamExt;
|
||||
use std::{cell::RefCell, rc::Rc, sync::Arc};
|
||||
use supermaven::{Supermaven, SupermavenCompletionProvider};
|
||||
|
@ -192,18 +192,6 @@ fn register_backward_compatible_actions(editor: &mut Editor, cx: &mut Context<Ed
|
|||
},
|
||||
))
|
||||
.detach();
|
||||
if !DisableAiSettings::get_global(cx).disable_ai {
|
||||
editor
|
||||
.register_action(cx.listener(
|
||||
|editor,
|
||||
_: &editor::actions::AcceptPartialCopilotSuggestion,
|
||||
window: &mut Window,
|
||||
cx: &mut Context<Editor>| {
|
||||
editor.accept_partial_inline_completion(&Default::default(), window, cx);
|
||||
},
|
||||
))
|
||||
.detach();
|
||||
}
|
||||
}
|
||||
|
||||
fn assign_edit_prediction_provider(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue