Skip to content

Commit 5747767

Browse files
committed
Adds fqfn to file being changed
1 parent 7e7f260 commit 5747767

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

plugin/src/software/aws/toolkits/eclipse/amazonq/views/AmazonQCodeReferenceView.java

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,11 @@ public void createPartControl(final Composite parent) {
2828
}
2929

3030
QInvocationSession qInvocationSessionInstance = QInvocationSession.getInstance();
31+
3132
qInvocationSessionInstance.registerCallbackForCodeReference((item, startLine) -> {
3233
var references = item.getReferences();
34+
var editor = qInvocationSessionInstance.getEditor();
35+
String fqfn = editor.getTitle();
3336
if (references != null && references.length > 0) {
3437
LocalDateTime now = LocalDateTime.now();
3538
DateTimeFormatter formatter = DateTimeFormatter.ofPattern("dd/MM/yyyy, HH:mm:ss a");
@@ -38,7 +41,7 @@ public void createPartControl(final Composite parent) {
3841
for (var reference : references) {
3942
String itemToShow = String.format(CR_TEMPLATE, formattedDateTime, item.getInsertText(),
4043
reference.getLicenseName(), reference.getReferenceUrl(),
41-
"Still have to figure out how to get FQFN", startLine, startLine + suggestionTextDepth);
44+
fqfn, startLine, startLine + suggestionTextDepth);
4245
int boldStart = textArea.getCharCount();
4346
int boldLength = itemToShow.split("\n", 2)[0].length();
4447

0 commit comments

Comments
 (0)