Skip to content
Permalink
Browse files

fix #2516

git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@13016 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
jef
jef committed Mar 7, 2010
1 parent f0ff168 commit 82764c60b9446c35bfd99e5c93a8a8c91eb80b83
Showing with 12 additions and 5 deletions.
  1. +12 −5 src/app/qgsidentifyresults.cpp
@@ -356,11 +356,16 @@ void QgsIdentifyResults::contextMenuEvent( QContextMenuEvent* event )

mActionPopup = new QMenu();

mActionPopup->addAction( vlayer->isEditable() ? tr( "Edit feature form" ) : tr( "View feature form" ), this, SLOT( featureForm() ) );
mActionPopup->addAction( tr( "Zoom to feature" ), this, SLOT( zoomToFeature() ) );
mActionPopup->addAction( tr( "Copy attribute value" ), this, SLOT( copyAttributeValue() ) );
mActionPopup->addAction( tr( "Copy feature attributes" ), this, SLOT( copyFeatureAttributes() ) );
mActionPopup->addSeparator();
QTreeWidgetItem *featItem = featureItem( item );
if ( featItem )
{
mActionPopup->addAction( vlayer->isEditable() ? tr( "Edit feature form" ) : tr( "View feature form" ), this, SLOT( featureForm() ) );
mActionPopup->addAction( tr( "Zoom to feature" ), this, SLOT( zoomToFeature() ) );
mActionPopup->addAction( tr( "Copy attribute value" ), this, SLOT( copyAttributeValue() ) );
mActionPopup->addAction( tr( "Copy feature attributes" ), this, SLOT( copyFeatureAttributes() ) );
mActionPopup->addSeparator();
}

mActionPopup->addAction( tr( "Clear results" ), this, SLOT( clear() ) );
mActionPopup->addAction( tr( "Clear highlights" ), this, SLOT( clearRubberbands() ) );
mActionPopup->addAction( tr( "Highlight all" ), this, SLOT( highlightAll() ) );
@@ -558,6 +563,8 @@ QgsVectorLayer *QgsIdentifyResults::vectorLayer( QTreeWidgetItem *item )
QTreeWidgetItem *QgsIdentifyResults::retrieveAttributes( QTreeWidgetItem *item, QList< QPair<QString, QString> > &attributes, int &idx )
{
QTreeWidgetItem *featItem = featureItem( item );
if ( !featItem )
return 0;

idx = -1;

0 comments on commit 82764c6

Please sign in to comment.
You can’t perform that action at this time.