Commit f7de8c93 authored by Lorenz Haas's avatar Lorenz Haas Committed by Erik Verbruggen
Browse files

Hide 'Refactor -> Add Definition in ...' for signals

Since signals don't have a definition there is no need to show that
action under 'Refactor'.

Change-Id: Ic4d65b56c9197e2dbce5cedd5c760faea14d920d
Reviewed-by: default avatarOrgad Shaneh <>
Reviewed-by: default avatarhjk <>
Reviewed-by: default avatarErik Verbruggen <>
parent 0042175e
......@@ -299,7 +299,9 @@ void InsertDefFromDecl::match(const CppQuickFixInterface &interface, QuickFixOpe
if (simpleDecl->symbols && ! simpleDecl->symbols->next) {
if (Symbol *symbol = simpleDecl->symbols->value) {
if (Declaration *decl = symbol->asDeclaration()) {
if (decl->type()->isFunctionType()) {
if (Function *func = decl->type()->asFunctionType()) {
if (func->isSignal())
CppRefactoringChanges refactoring(interface->snapshot());
InsertionPointLocator locator(refactoring);
foreach (const InsertionLocation &loc, locator.methodDefinition(decl)) {
Supports Markdown
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