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

svn_qgis at osgeo.org svn_qgis at osgeo.org
Mon Nov 1 08:30:35 EDT 2010


Author: jef
Date: 2010-11-01 05:30:35 -0700 (Mon, 01 Nov 2010)
New Revision: 14478

Modified:
   trunk/qgis/src/app/qgssinglesymboldialog.cpp
Log:
fix symbol selection

Modified: trunk/qgis/src/app/qgssinglesymboldialog.cpp
===================================================================
--- trunk/qgis/src/app/qgssinglesymboldialog.cpp	2010-11-01 12:29:50 UTC (rev 14477)
+++ trunk/qgis/src/app/qgssinglesymboldialog.cpp	2010-11-01 12:30:35 UTC (rev 14478)
@@ -108,8 +108,6 @@
   connect( btnFillColor, SIGNAL( clicked() ), this, SLOT( selectFillColor() ) );
   connect( outlinewidthspinbox, SIGNAL( valueChanged( double ) ), this, SLOT( resendSettingsChanged() ) );
   connect( mLabelEdit, SIGNAL( textChanged( const QString& ) ), this, SLOT( resendSettingsChanged() ) );
-  connect( lstSymbols, SIGNAL( currentChanged( const QModelIndex & , const QModelIndex & ) ),
-           this, SLOT( symbolChanged( const QModelIndex & , const QModelIndex & ) ) );
   connect( mPointSizeSpinBox, SIGNAL( valueChanged( double ) ), this, SLOT( resendSettingsChanged() ) );
   connect( mPointSizeUnitsCheckBox, SIGNAL( toggled( bool ) ), this, SLOT( resendSettingsChanged() ) );
   connect( mRotationClassificationComboBox, SIGNAL( currentIndexChanged( const QString & ) ),
@@ -135,6 +133,9 @@
   QgsMarkerListModel *m = new QgsMarkerListModel( lstSymbols );
   lstSymbols->setModel( m );
 
+  connect( lstSymbols->selectionModel(), SIGNAL( currentChanged( const QModelIndex &, const QModelIndex & ) ),
+           this, SLOT( symbolChanged( const QModelIndex &, const QModelIndex & ) ) );
+
   // Find out the numerical fields of mVectorLayer, and populate the ComboBoxes
   QgsVectorDataProvider *provider = mVectorLayer->dataProvider();
   if ( provider )
@@ -639,7 +640,7 @@
   QAbstractItemModel *m = lstSymbols->model();
   QgsDebugMsg( QString( "symbol changed to %1:%2" ).arg( current.row() ).arg( m->data( current, Qt::UserRole ).toString() ) );
   // m->setData( current, Qt::UserRole+1, Qt::cyan );
-  // m->setData( prev, Qt::UserRole+1, Qt::white );
+  // m->setData( previous, Qt::UserRole+1, Qt::white );
   emit settingsChanged();
 }
 



More information about the QGIS-commit mailing list