[QGIS Commit] r12218 - trunk/qgis/src/app

svn_qgis at osgeo.org svn_qgis at osgeo.org
Sat Nov 21 15:50:15 EST 2009


Author: jef
Date: 2009-11-21 15:50:14 -0500 (Sat, 21 Nov 2009)
New Revision: 12218

Modified:
   trunk/qgis/src/app/qgsidentifyresults.cpp
Log:
bind actions to push buttons in feature forms

Modified: trunk/qgis/src/app/qgsidentifyresults.cpp
===================================================================
--- trunk/qgis/src/app/qgsidentifyresults.cpp	2009-11-21 20:48:49 UTC (rev 12217)
+++ trunk/qgis/src/app/qgsidentifyresults.cpp	2009-11-21 20:50:14 UTC (rev 12218)
@@ -38,6 +38,7 @@
 #include <QClipboard>
 #include <QDockWidget>
 #include <QMenuBar>
+#include <QPushButton>
 
 #include "qgslogger.h"
 
@@ -733,6 +734,10 @@
       QgsFeatureAction *a = new QgsFeatureAction( action.name(), this, vlayer, i, featItem );
       ad->dialog()->addAction( a );
       connect( a, SIGNAL( triggered() ), a, SLOT( execute() ) );
+
+      QPushButton *pb = ad->dialog()->findChild<QPushButton *>( action.name() );
+      if ( pb )
+        connect( pb, SIGNAL( clicked() ), a, SLOT( execute() ) );
     }
   }
 



More information about the QGIS-commit mailing list