I have a aplication with a mainwindow created with the designer. The central widget is a QListWidget. But the mouse pressevent doesnt work inside the listwidget, only outside. Why ???

Also I have 2 signal slot connections when a item is clicked or doubleclicked.

If I put in comment the doubleclick connection, the click connection works fine. If I put in comment the click connection, the doubleclick connection works fine. But if I use the 2 connections at the same time, the doubleclick connection isnt triggered. Any ideas ???
My code:

Qt Code:
  1. connect(ui.listWidget,SIGNAL(itemClicked(QListWidgetItem*)),
  2. this,SLOT(ListaSlot()));
  3.  
  4. connect(ui.listWidget,SIGNAL(itemDoubleClicked(QListWidgetItem*)),
  5. this,SLOT(ListaSlot2Click()));
To copy to clipboard, switch view to plain text mode