title: How to find item selected from customContextMenuRequested() on QTreeView item?
body: <p>I have implemented contextual menus in QTreeView items with the following code</p>
  
  <pre><code>MyDerivedQTreeView-&gt;setModel(MyDerivedQAbstractItemModel);
  MyDerivedQTreeView-&gt;setContextMenuPolicy(Qt::CustomContextMenu);  
  connect(MyDerivedQTreeView,   
          SIGNAL(customContextMenuRequested(const QPoint &amp;)),   
          MyDerivedQAbstractItemModel(),   
          SLOT(contextualMenu(const QPoint &amp;)));
  
  void MyDerivedQAbstractItemModel::contextualMenu(const QPoint&amp; point)
  {
      QMenu *menu = new QMenu;
      menu-&gt;addAction(QString("Test Item"), this, SLOT(test_slot()));
      menu-&gt;exec(MyDerivedQTreeView-&gt;mapToGlobal(point));
  }
  </code></pre>
  
  <p>MyDerivedQAbstractItemModel::contextualMenu() gets called and I can see the contextual menu.</p>
  
  <p>Problem is contextual menu should be visible only if user right-clicks on an item and it should be customized as per the item selected.</p>
  
  <p>How do I get whether/which item is selected from QPoint information? I am on Qt 4.5.3.</p>