Fix QMenuItem connections
Don't emit twice textChanged when changed. checkableChanged signal doesn't exist anymore. Use changed instead as suggested by the Q_PROPERTY
This commit is contained in:
parent
3feb6ac3ae
commit
e1a868e4f6
@ -43,9 +43,8 @@ void QMenuItem::setAction(QAction* a)
|
|||||||
}
|
}
|
||||||
m_action = a;
|
m_action = a;
|
||||||
connect(m_action, &QAction::changed, this, &QMenuItem::textChanged);
|
connect(m_action, &QAction::changed, this, &QMenuItem::textChanged);
|
||||||
connect(m_action, &QAction::changed, this, &QMenuItem::textChanged);
|
connect(m_action, &QAction::changed, this, &QMenuItem::checkableChanged);
|
||||||
connect(m_action, SIGNAL(toggled(bool)), this, SIGNAL(toggled(bool)));
|
connect(m_action, SIGNAL(toggled(bool)), this, SIGNAL(toggled(bool)));
|
||||||
connect(m_action, SIGNAL(checkableChanged()), this, SIGNAL(checkableChanged()));
|
|
||||||
emit actionChanged();
|
emit actionChanged();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user