fix filename entry and range specification for vector attributes

git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@9451 c8812cc2-4d05-0410-92ff-de0c093fc19c
This commit is contained in:
jef 2008-10-07 13:46:34 +00:00
parent e0663b46a7
commit d9e0946a5b
2 changed files with 4 additions and 3 deletions

View File

@ -370,7 +370,7 @@ void QgsAttributeDialog::accept()
myFieldValue = QString::number( dsb->value() ); myFieldValue = QString::number( dsb->value() );
} }
le = mpWidgets.value( myIndex )->findChild<QLineEdit *>( "lineEdit" ); le = mpWidgets.value( myIndex )->findChild<QLineEdit *>();
if ( le ) if ( le )
{ {
myFieldValue = le->text(); myFieldValue = le->text();

View File

@ -501,12 +501,13 @@ void QgsVectorLayerProperties::apply()
{ {
int idx = tblAttributes->item( i, 0 )->text().toInt(); int idx = tblAttributes->item( i, 0 )->text().toInt();
const QgsField &field = layer->pendingFields()[idx]; const QgsField &field = layer->pendingFields()[idx];
QgsVectorLayer::EditType editType = layer->editType( idx );
QComboBox *cb = dynamic_cast<QComboBox*>( tblAttributes->cellWidget( i, 6 ) ); QComboBox *cb = dynamic_cast<QComboBox*>( tblAttributes->cellWidget( i, 6 ) );
if ( !cb ) if ( !cb )
continue; continue;
layer->setEditType( idx, ( QgsVectorLayer::EditType ) cb->itemData( cb->currentIndex() ).toInt() );
QgsVectorLayer::EditType editType = ( QgsVectorLayer::EditType ) cb->itemData( cb->currentIndex() ).toInt();
layer->setEditType( idx, editType );
if ( editType == QgsVectorLayer::ValueMap ) if ( editType == QgsVectorLayer::ValueMap )
{ {