【问题标题】:How to receive gesture events on a QGraphicsItem?如何在 QGraphicsItem 上接收手势事件?
【发布时间】:2013-09-16 18:07:45
【问题描述】:

我已经设置好了:

graphicsView->setAttribute(Qt::WA_AcceptTouchEvents);
graphicsView->viewport()->setAttribute(Qt::WA_AcceptTouchEvents);
graphicsView->grabGesture(Qt::PinchGesture);
graphicsView->viewport()->grabGesture(Qt::PinchGesture);

我仍然无法在使用 Qt 5.1 的 QGraphicsItemsceneEvent 方法上接收手势,有人知道为什么吗?

【问题讨论】:

    标签: c++ qt qgraphicsview


    【解决方案1】:

    回答我自己的问题来解决这个问题:http://qt-project.org/forums/viewthread/32600/

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2018-01-12
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2013-06-23
      • 2011-09-05
      • 1970-01-01
      相关资源
      最近更新 更多