Adapt to API change with IPlugin::contextMenuExtension

parent a60c36a9
......@@ -70,14 +70,14 @@ namespace Python
{
LanguageSupport* LanguageSupport::m_self = nullptr;
KDevelop::ContextMenuExtension LanguageSupport::contextMenuExtension(KDevelop::Context* context)
ContextMenuExtension LanguageSupport::contextMenuExtension(Context* context, QWidget* parent)
{
ContextMenuExtension cm;
EditorContext *ec = dynamic_cast<KDevelop::EditorContext *>(context);
if (ec && ICore::self()->languageController()->languagesForUrl(ec->url()).contains(this)) {
// It's a Python file, let's add our context menu.
m_refactoring->fillContextMenu(cm, context);
m_refactoring->fillContextMenu(cm, context, parent);
TypeCorrection::self().doContextMenu(cm, context);
}
return cm;
......
......@@ -63,7 +63,7 @@ public:
KDevelop::ICodeHighlighting* codeHighlighting() const override;
KDevelop::BasicRefactoring* refactoring() const override;
KDevelop::ContextMenuExtension contextMenuExtension(KDevelop::Context* context) override;
KDevelop::ContextMenuExtension contextMenuExtension(KDevelop::Context* context, QWidget* parent) override;
static LanguageSupport* self();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment