mirror of
https://github.com/qgis/QGIS.git
synced 2025-10-06 00:07:29 -04:00
fix #1564
git-svn-id: http://svn.osgeo.org/qgis/trunk@10263 c8812cc2-4d05-0410-92ff-de0c093fc19c
This commit is contained in:
parent
73715607eb
commit
86adf97cc7
@ -512,15 +512,16 @@ void QgsVectorLayerProperties::apply()
|
||||
QgsVectorLayer::EditType editType = ( QgsVectorLayer::EditType ) cb->itemData( cb->currentIndex() ).toInt();
|
||||
layer->setEditType( idx, editType );
|
||||
|
||||
QString value = tblAttributes->item( i, 7 ) ? tblAttributes->item( i, 7 )->text() : QString::null;
|
||||
|
||||
if ( editType == QgsVectorLayer::ValueMap )
|
||||
{
|
||||
QMap<QString, QVariant> &map = layer->valueMap( idx );
|
||||
map.clear();
|
||||
|
||||
QString value = tblAttributes->item( i, 7 )->text();
|
||||
if ( !value.isEmpty() )
|
||||
{
|
||||
QStringList values = tblAttributes->item( i, 7 )->text().split( ";" );
|
||||
QStringList values = value.split( ";" );
|
||||
for ( int j = 0; j < values.size(); j++ )
|
||||
{
|
||||
QStringList args = values[j].split( "=" );
|
||||
@ -548,7 +549,7 @@ void QgsVectorLayerProperties::apply()
|
||||
else if ( editType == QgsVectorLayer::EditRange ||
|
||||
editType == QgsVectorLayer::SliderRange )
|
||||
{
|
||||
QStringList values = tblAttributes->item( i, 7 )->text().split( ";" );
|
||||
QStringList values = value.split( ";" );
|
||||
|
||||
if ( values.size() == 3 )
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user