Skip to content
Permalink
Browse files

Select proper features in filtered feature list

  • Loading branch information
m-kuhn committed Apr 16, 2013
1 parent 7f158b8 commit 1208051b2413252d31089d687c467aa10e25c488
@@ -100,7 +100,7 @@ void QgsFeatureListView::mousePressEvent( QMouseEvent *event )
{
QPoint pos = event->pos();

QModelIndex index = mModel->mapToMaster( indexAt( pos ) );
QModelIndex index = indexAt( pos );

if ( QgsFeatureListViewDelegate::EditElement == mItemDelegate->positionToElement( event->pos() ) )
{
@@ -111,6 +111,7 @@ void QgsFeatureListView::mousePressEvent( QMouseEvent *event )
{
mFeatureSelectionModel->enableSync( false );
selectRow( index, true );
repaintRequested();
}
}

@@ -176,7 +177,7 @@ void QgsFeatureListView::mouseMoveEvent( QMouseEvent *event )
{
QPoint pos = event->pos();

QModelIndex index = mModel->mapToMaster( indexAt( pos ) );
QModelIndex index = indexAt( pos );

if ( mEditSelectionDrag )
{
@@ -44,7 +44,7 @@ bool QgsFeatureSelectionModel::isSelected( QgsFeatureId fid )
if ( mDeselectedBuffer.contains( fid ) )
return false;

if ( mLayer->selectedFeaturesIds().contains( fid ) )
if ( !mClearAndSelectBuffer && mLayer->selectedFeaturesIds().contains( fid ) )
return true;

return false;

0 comments on commit 1208051

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