| 21 | using namespace dpfservice; |
| 22 | |
| 23 | Copilot::Copilot(QObject *parent) |
| 24 | : QObject(parent) |
| 25 | { |
| 26 | editorService = dpfGetService(EditorService); |
| 27 | if (!editorService) { |
| 28 | qFatal("Editor service is null!"); |
| 29 | } |
| 30 | |
| 31 | QAction *lineChatAct = new QAction(tr("Inline Chat"), this); |
| 32 | lineChatCmd = ActionManager::instance()->registerAction(lineChatAct, "Chat.InlineChat"); |
| 33 | lineChatCmd->setDefaultKeySequence(Qt::CTRL + Qt::Key_T); |
| 34 | connect(lineChatAct, &QAction::triggered, this, &Copilot::startInlineChat); |
| 35 | } |
| 36 | |
| 37 | QString Copilot::selectedText() const |
| 38 | { |
nothing calls this directly
no test coverage detected