Show "tab Accept" only for zeta (#23463)
#23460 brought up we are showing the new "tab Accept" marker for single line suggestions for non-zeta providers. We think this might be valid for any provider, but we only want to enable it for zeta initially so it doesn't affect an existing user base. Release Notes: - N/A
This commit is contained in:
parent
1e88e2924c
commit
95cde129af
5 changed files with 85 additions and 53 deletions
|
@ -22,6 +22,9 @@ pub trait InlineCompletionProvider: 'static + Sized {
|
|||
fn display_name() -> &'static str;
|
||||
fn show_completions_in_menu() -> bool;
|
||||
fn show_completions_in_normal_mode() -> bool;
|
||||
fn show_tab_accept_marker() -> bool {
|
||||
false
|
||||
}
|
||||
fn is_enabled(
|
||||
&self,
|
||||
buffer: &Model<Buffer>,
|
||||
|
@ -67,6 +70,7 @@ pub trait InlineCompletionProviderHandle {
|
|||
) -> bool;
|
||||
fn show_completions_in_menu(&self) -> bool;
|
||||
fn show_completions_in_normal_mode(&self) -> bool;
|
||||
fn show_tab_accept_marker(&self) -> bool;
|
||||
fn needs_terms_acceptance(&self, cx: &AppContext) -> bool;
|
||||
fn is_refreshing(&self, cx: &AppContext) -> bool;
|
||||
fn refresh(
|
||||
|
@ -113,6 +117,10 @@ where
|
|||
T::show_completions_in_normal_mode()
|
||||
}
|
||||
|
||||
fn show_tab_accept_marker(&self) -> bool {
|
||||
T::show_tab_accept_marker()
|
||||
}
|
||||
|
||||
fn is_enabled(
|
||||
&self,
|
||||
buffer: &Model<Buffer>,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue