Skip to content

Commit c72418d

Browse files
author
jef
committed
fix #1179
git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@8946 c8812cc2-4d05-0410-92ff-de0c093fc19c
1 parent dda7ab3 commit c72418d

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

src/app/qgsattributetable.cpp

+1-3
Original file line numberDiff line numberDiff line change
@@ -395,11 +395,9 @@ bool QgsAttributeTable::addAttribute(const QString& name, const QString& type)
395395
mAddedAttributes.insert(name,type);
396396

397397
QgsDebugMsg("inserting attribute " + name + " of type " + type + ", numCols: " + QString::number(columnCount()) );
398-
399398
//add a new column at the end of the table
400-
401399
insertColumn(columnCount());
402-
horizontalHeaderItem(columnCount()-1)->setText(name);
400+
setHorizontalHeaderItem(columnCount()-1, new QTableWidgetItem(name));
403401
mEdited=true;
404402
return true;
405403
}

0 commit comments

Comments
 (0)