You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: plugins/amazonq/codewhisperer/jetbrains-community/src/software/aws/toolkits/jetbrains/services/codewhisperer/inlay/CodeWhispererInlayManager.kt
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -22,7 +22,7 @@ class CodeWhispererInlayManager {
Copy file name to clipboardExpand all lines: plugins/amazonq/codewhisperer/jetbrains-community/src/software/aws/toolkits/jetbrains/services/codewhisperer/model/CodeWhispererModel.kt
Copy file name to clipboardExpand all lines: plugins/amazonq/codewhisperer/jetbrains-community/src/software/aws/toolkits/jetbrains/services/codewhisperer/popup/CodeWhispererPopupManager.kt
+13-13Lines changed: 13 additions & 13 deletions
Original file line number
Diff line number
Diff line change
@@ -141,15 +141,15 @@ class CodeWhispererPopupManager {
141
141
val startOffset = states.requestContext.caretPosition.offset
142
142
val currOffset = states.requestContext.editor.caretModel.offset
143
143
if (startOffset > currOffset) {
144
-
cancelPopup(popup)
144
+
popup?.let { cancelPopup(popup) }
145
145
return
146
146
}
147
147
148
148
// userInput + typeahead
149
149
val prefix = states.requestContext.editor.document.charsSequence
150
150
.substring(startOffset, currOffset)
151
151
if (prefix.length < userInputOriginal.length) {
152
-
cancelPopup(popup)
152
+
popup?.let { cancelPopup(popup) }
153
153
return
154
154
} else {
155
155
prefix.substring(userInputOriginal.length)
@@ -172,7 +172,7 @@ class CodeWhispererPopupManager {
172
172
)
173
173
if (selectedIndex ==-1||!isValidRecommendation(details[selectedIndex], userInput, typeaheadOriginal)) {
174
174
LOG.debug { "None of the recommendation is valid at this point, cancelling the popup" }
175
-
cancelPopup(popup)
175
+
popup?.let { cancelPopup(popup) }
176
176
return
177
177
}
178
178
val typeahead = resolveTypeahead(states, selectedIndex, typeaheadOriginal)
@@ -245,7 +245,7 @@ class CodeWhispererPopupManager {
Copy file name to clipboardExpand all lines: plugins/amazonq/codewhisperer/jetbrains-community/src/software/aws/toolkits/jetbrains/services/codewhisperer/popup/CodeWhispererUIChangeListener.kt
+4-2Lines changed: 4 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -61,8 +61,10 @@ class CodeWhispererUIChangeListener : CodeWhispererPopupStateChangeListener {
Copy file name to clipboardExpand all lines: plugins/amazonq/codewhisperer/jetbrains-community/src/software/aws/toolkits/jetbrains/services/codewhisperer/popup/handlers/CodeWhispererPopupEscHandler.kt
Copy file name to clipboardExpand all lines: plugins/amazonq/codewhisperer/jetbrains-community/src/software/aws/toolkits/jetbrains/services/codewhisperer/service/CodeWhispererService.kt
0 commit comments