Skip to content
Permalink
Browse files
changes to allow vertex editing of not commited features
git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@5359 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
mhugent committed Apr 24, 2006
1 parent 639f9a0 commit 3a9d82fa679032b3a0fc7960bea14a211f1ee6b9
Showing with 9 additions and 2 deletions.
  1. +3 −1 src/gui/qgsmaptoolvertexedit.cpp
  2. +6 −1 src/gui/qgsvectorlayer.cpp
@@ -241,7 +241,9 @@ bool QgsMapToolVertexEdit::snapVertexWithContext(QgsPoint& point)
void QgsMapToolVertexEdit::canvasReleaseEvent(QMouseEvent * e)
{
if (mSnappedAtFeatureId == -1)
return;
{
return;
}

QgsVectorLayer* vlayer = dynamic_cast<QgsVectorLayer*>(mCanvas->currentLayer());

@@ -896,6 +896,11 @@ void QgsVectorLayer::draw(QPainter * p, QgsRect * viewExtent, QgsMapToPixel * th
m_renderer->renderFeature(p, *it, &marker, &markerScaleFactor,
sel, widthScale);
double scale = markerScaleFactor * symbolScale;
if (mChangedGeometries.find((*it)->featureId()) != mChangedGeometries.end())
{
(*it)->setGeometry( mChangedGeometries[(*it)->featureId() ] );
}
mCachedGeometries[(*it)->featureId()] = (*it)->geometryAndOwnership();
drawFeature(p,*it,theMapToPixelTransform,&marker,scale,
projectionsEnabledFlag);
}
@@ -1571,7 +1576,7 @@ std::vector<QgsField> const& QgsVectorLayer::fields() const

bool QgsVectorLayer::addFeature(QgsFeature* f, bool alsoUpdateExtent)
{
static int addedIdLowWaterMark = 0;
static int addedIdLowWaterMark = -1;

if(dataProvider)
{

0 comments on commit 3a9d82f

Please sign in to comment.