Windows下如何用Qt实现虚拟鼠标点击事件
qDebug()<<"mouse?clicked";
QPoint?pos(403,34);
QMouseEvent?event0(QEvent::MouseButtonPress,?pos,?Qt::LeftButton,?Qt::LeftButton,?Qt::NoModifier);
QApplication::sendEvent(view->page(),?&event0);
QMouseEvent?event1(QEvent::MouseButtonRelease,?pos,?Qt::LeftButton,?Qt::LeftButton,?Qt::NoModifier);
QApplication::sendEvent(view->page(),?&event1);