if (event->button()==Qt::RightButton){
qDebug() << Qt::RightButton << pos();
QPoint Mpush = pos();
QTest::mouseMove(this->m_button,Mpush);
QTest::mouseClick(this->m_button, Qt::LeftButton,0,Mpush,-1);}
in this code, when I Rightclicked on button, the position of cursor places in Mpush and then lift click is simulated. it doesn't emit pushbutton(m_button) signal.
Bookmarks