Skip to content

Commit 51f75d9

Browse files
committed
feat(amazonq): basic paginated suggestions using language server
1 parent ba33860 commit 51f75d9

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

packages/amazonq/src/app/inline/completion.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -131,24 +131,24 @@ export class InlineCompletionManager implements Disposable {
131131

132132
const prevCommand = Commands.declare('editor.action.inlineSuggest.showPrevious', () => async () => {
133133
SessionManager.instance.decrementActiveIndex()
134+
await commands.executeCommand('editor.action.inlineSuggest.hide')
134135
this.disposable.dispose()
135136
this.disposable = languages.registerInlineCompletionItemProvider(
136137
CodewhispererInlineCompletionLanguages,
137138
new AmazonQInlineCompletionItemProvider(this.languageClient, false)
138139
)
139-
await commands.executeCommand('editor.action.inlineSuggest.hide')
140140
await commands.executeCommand('editor.action.inlineSuggest.trigger')
141141
})
142142
prevCommand.register()
143143

144144
const nextCommand = Commands.declare('editor.action.inlineSuggest.showNext', () => async () => {
145145
SessionManager.instance.incrementActiveIndex()
146+
await commands.executeCommand('editor.action.inlineSuggest.hide')
146147
this.disposable.dispose()
147148
this.disposable = languages.registerInlineCompletionItemProvider(
148149
CodewhispererInlineCompletionLanguages,
149150
new AmazonQInlineCompletionItemProvider(this.languageClient, false)
150151
)
151-
await commands.executeCommand('editor.action.inlineSuggest.hide')
152152
await commands.executeCommand('editor.action.inlineSuggest.trigger')
153153
})
154154
nextCommand.register()

0 commit comments

Comments
 (0)