Skip to content

Commit 5ec236c

Browse files
author
jef
committed
fix symbol selection
git-svn-id: http://svn.osgeo.org/qgis/trunk@14478 c8812cc2-4d05-0410-92ff-de0c093fc19c
1 parent 675a3a5 commit 5ec236c

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

src/app/qgssinglesymboldialog.cpp

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -108,8 +108,6 @@ QgsSingleSymbolDialog::QgsSingleSymbolDialog( QgsVectorLayer * layer, bool disab
108108
connect( btnFillColor, SIGNAL( clicked() ), this, SLOT( selectFillColor() ) );
109109
connect( outlinewidthspinbox, SIGNAL( valueChanged( double ) ), this, SLOT( resendSettingsChanged() ) );
110110
connect( mLabelEdit, SIGNAL( textChanged( const QString& ) ), this, SLOT( resendSettingsChanged() ) );
111-
connect( lstSymbols, SIGNAL( currentChanged( const QModelIndex & , const QModelIndex & ) ),
112-
this, SLOT( symbolChanged( const QModelIndex & , const QModelIndex & ) ) );
113111
connect( mPointSizeSpinBox, SIGNAL( valueChanged( double ) ), this, SLOT( resendSettingsChanged() ) );
114112
connect( mPointSizeUnitsCheckBox, SIGNAL( toggled( bool ) ), this, SLOT( resendSettingsChanged() ) );
115113
connect( mRotationClassificationComboBox, SIGNAL( currentIndexChanged( const QString & ) ),
@@ -135,6 +133,9 @@ void QgsSingleSymbolDialog::refreshMarkers()
135133
QgsMarkerListModel *m = new QgsMarkerListModel( lstSymbols );
136134
lstSymbols->setModel( m );
137135

136+
connect( lstSymbols->selectionModel(), SIGNAL( currentChanged( const QModelIndex &, const QModelIndex & ) ),
137+
this, SLOT( symbolChanged( const QModelIndex &, const QModelIndex & ) ) );
138+
138139
// Find out the numerical fields of mVectorLayer, and populate the ComboBoxes
139140
QgsVectorDataProvider *provider = mVectorLayer->dataProvider();
140141
if ( provider )
@@ -639,7 +640,7 @@ void QgsSingleSymbolDialog::symbolChanged( const QModelIndex &current, const QMo
639640
QAbstractItemModel *m = lstSymbols->model();
640641
QgsDebugMsg( QString( "symbol changed to %1:%2" ).arg( current.row() ).arg( m->data( current, Qt::UserRole ).toString() ) );
641642
// m->setData( current, Qt::UserRole+1, Qt::cyan );
642-
// m->setData( prev, Qt::UserRole+1, Qt::white );
643+
// m->setData( previous, Qt::UserRole+1, Qt::white );
643644
emit settingsChanged();
644645
}
645646

0 commit comments

Comments
 (0)