[QGIS Commit] r12814 - in trunk/qgis: python/gui src/app/legend src/gui

svn_qgis at osgeo.org svn_qgis at osgeo.org
Thu Jan 21 15:17:30 EST 2010


Author: jef
Date: 2010-01-21 15:17:29 -0500 (Thu, 21 Jan 2010)
New Revision: 12814

Modified:
   trunk/qgis/python/gui/qgslegendinterface.sip
   trunk/qgis/src/app/legend/qgsapplegendinterface.cpp
   trunk/qgis/src/app/legend/qgsapplegendinterface.h
   trunk/qgis/src/gui/qgslegendinterface.h
Log:
[FEATURE] allow opening layer properties from plugins

Modified: trunk/qgis/python/gui/qgslegendinterface.sip
===================================================================
--- trunk/qgis/python/gui/qgslegendinterface.sip	2010-01-21 16:21:56 UTC (rev 12813)
+++ trunk/qgis/python/gui/qgslegendinterface.sip	2010-01-21 20:17:29 UTC (rev 12814)
@@ -33,5 +33,9 @@
 
     //! Move a layer to a group
     virtual void moveLayer( QgsMapLayer * layer, int groupIndex ) =0;
+
+    //! show layer propeties
+    //! @note added in 1.5
+    virtual void legendLayerShowProperties() =0;
 };
 

Modified: trunk/qgis/src/app/legend/qgsapplegendinterface.cpp
===================================================================
--- trunk/qgis/src/app/legend/qgsapplegendinterface.cpp	2010-01-21 16:21:56 UTC (rev 12813)
+++ trunk/qgis/src/app/legend/qgsapplegendinterface.cpp	2010-01-21 20:17:29 UTC (rev 12814)
@@ -57,3 +57,8 @@
 {
   return mLegend->groups();
 }
+
+void QgsAppLegendInterface::legendLayerShowProperties()
+{
+  mLegend->legendLayerShowProperties();
+}

Modified: trunk/qgis/src/app/legend/qgsapplegendinterface.h
===================================================================
--- trunk/qgis/src/app/legend/qgsapplegendinterface.h	2010-01-21 16:21:56 UTC (rev 12813)
+++ trunk/qgis/src/app/legend/qgsapplegendinterface.h	2010-01-21 20:17:29 UTC (rev 12814)
@@ -58,6 +58,9 @@
     //! Update an index
     void updateIndex( QModelIndex oldIndex, QModelIndex newIndex );
 
+    //! Show layer properties
+    void legendLayerShowProperties();
+
   private:
 
     //! Pointer to QgsLegend object

Modified: trunk/qgis/src/gui/qgslegendinterface.h
===================================================================
--- trunk/qgis/src/gui/qgslegendinterface.h	2010-01-21 16:21:56 UTC (rev 12813)
+++ trunk/qgis/src/gui/qgslegendinterface.h	2010-01-21 20:17:29 UTC (rev 12814)
@@ -59,6 +59,10 @@
 
     //! Move a layer to a group
     virtual void moveLayer( QgsMapLayer * ml, int groupIndex ) = 0;
+
+    //! Show layer properties dialog
+    // @note added in 1.5
+    virtual void legendLayerShowProperties() = 0;
 };
 
 #endif



More information about the QGIS-commit mailing list