January 28, 2012

rendyfaqot rendyfaqot
Lab Rat
3 posts

How to Adding event onClick in MapImage element in QML?

 

Hi developers..

I create an application that using Ovi Maps (Map Element). I put some MapImage element on the maps. I want to add Event Handling (like a button) in MapImage element. I try to put MouseArea in MapImage but it doesn’t work. Anybody can help? Have another solutions?

3 replies

January 31, 2012

deimos deimos
Hobby Entomologist
110 posts

Hi,

you should use MapMouseArea [doc.qt.nokia.com]

January 31, 2012

rendyfaqot rendyfaqot
Lab Rat
3 posts

Yeah I’ve found it. Thanks. But the problem is, when I implemet onClicked, it doesn’t works with left-click on my mouse, but it works with right-click. I try deploy the application onto device and not running properly. What should I do?

February 1, 2012

deimos deimos
Hobby Entomologist
110 posts

It sounds odd. The default mouse button is the left. Stating on docs you can try with:

  1. acceptedButtons: Qt.LeftButton

 
  ‹‹ Getting the Gallery Imagepath in Phone to save image in QML      accessing attributes of qml elements from c++ ››

You must log in to post a reply. Not a member yet? Register here!