PDA

View Full Version : Qt creator mobile: how to disable object selection



qtkid
3rd June 2011, 03:33
Hi everyone, i am currently doing a mobile game that is played via the accelerator. However, my character can be moved via drag. How do i stop my character to be movable via touch? Is there a way to disable the screen's touch event once the app is started? Or do i disable the object via its properties? Thanks! :)

Lykurg
3rd June 2011, 06:53
Use the objects properties. Disable the touch on a global level is bad...

qtkid
3rd June 2011, 07:03
Use the objects properties. Disable the touch on a global level is bad...

thanks for replying! But how do i disable it via the objects properties?

Lykurg
8th June 2011, 06:41
I assume you are using QGraphicsView and your character is a QGraphicsItem: Disable the QGraphicsItem::ItemIsMovable flag and your character can't be moved anymore.