MCPcopy Create free account
hub / github.com/Codeya-IDE/deepin-ide / onReferenceBtnClicked

Method onReferenceBtnClicked

src/plugins/chat/widgets/inputeditwidget.cpp:453–463  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

451}
452
453void InputEditWidget::onReferenceBtnClicked()
454{
455 auto cursor = d->edit->textCursor();
456 cursor.movePosition(QTextCursor::Left, QTextCursor::KeepAnchor);
457 auto charBeforeCursor = cursor.selectedText();
458 if (charBeforeCursor != "@")
459 cursor.insertText("@");
460 else if (!d->referencePopup->isVisible())
461 d->referencePopup->show();
462 d->edit->setFocus();
463}
464
465void InputEditWidget::onCodeBaseBtnClicked()
466{

Callers

nothing calls this directly

Calls 6

textCursorMethod · 0.80
isVisibleMethod · 0.80
setFocusMethod · 0.80
selectedTextMethod · 0.45
insertTextMethod · 0.45
showMethod · 0.45

Tested by

no test coverage detected