From 0b09461dead9b99b33257580ebb5a86995ad562b Mon Sep 17 00:00:00 2001 From: Levi Neely Date: Fri, 9 Oct 2026 10:54:51 +0200 Subject: [PATCH] kate: expose context actions as Q_INVOKABLE for cross-plugin triggering Make the six context-menu action methods (askAboutFile, explainSelection, submitSelectionPrompt, sendVerbatim, reviewDiff, startSession) public Q_INVOKABLE so sibling plugins can trigger them by name via QMetaObject::invokeMethod. The Deft radial menu uses this to offer an 'Ollie' submenu when this plugin is enabled. No behaviour change for existing callers. --- kde/kate/ollie_kate.h | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) diff --git a/kde/kate/ollie_kate.h b/kde/kate/ollie_kate.h index f27b36a..044e89d 100644 --- a/kde/kate/ollie_kate.h +++ b/kde/kate/ollie_kate.h @@ -65,14 +65,19 @@ private slots: void onWidgetAdded(QWidget *widget); void onGitTreeContextMenu(const QPoint &pos); +public: + // Context actions, exposed for meta-invocation so sibling plugins (e.g. the + // Deft radial menu) can trigger them by name via QMetaObject::invokeMethod + // when the Ollie plugin is enabled. + Q_INVOKABLE void askAboutFile(); + Q_INVOKABLE void explainSelection(); + Q_INVOKABLE void submitSelectionPrompt(const QString &action); + Q_INVOKABLE void sendVerbatim(); + Q_INVOKABLE void reviewDiff(); + Q_INVOKABLE void startSession(); + private: // Actions - void askAboutFile(); - void explainSelection(); - void submitSelectionPrompt(const QString &action); - void sendVerbatim(); - void reviewDiff(); - void startSession(); void reviewStagedChanges(); void reviewUnstagedChanges(); void askAboutGitSelection();