@@ -373,12 +373,6 @@ QgsProjectProperties::QgsProjectProperties( QgsMapCanvas* mapCanvas, QWidget *pa
373
373
374
374
QSignalMapper *smPublied = new QSignalMapper ( this );
375
375
connect ( smPublied, SIGNAL ( mapped ( int ) ), this , SLOT ( cbxWFSPubliedStateChanged ( int ) ) );
376
- QSignalMapper *smUpdate = new QSignalMapper ( this );
377
- connect ( smUpdate, SIGNAL ( mapped ( int ) ), this , SLOT ( cbxWFSUpdateStateChanged ( int ) ) );
378
- QSignalMapper *smInsert = new QSignalMapper ( this );
379
- connect ( smInsert, SIGNAL ( mapped ( int ) ), this , SLOT ( cbxWFSInsertStateChanged ( int ) ) );
380
- QSignalMapper *smDelete = new QSignalMapper ( this );
381
- connect ( smDelete, SIGNAL ( mapped ( int ) ), this , SLOT ( cbxWFSDeleteStateChanged ( int ) ) );
382
376
383
377
twWFSLayers->setColumnCount ( 6 );
384
378
twWFSLayers->horizontalHeader ()->setVisible ( true );
@@ -418,27 +412,18 @@ QgsProjectProperties::QgsProjectProperties( QgsMapCanvas* mapCanvas, QWidget *pa
418
412
QCheckBox* cbu = new QCheckBox ();
419
413
cbu->setChecked ( wfstUpdateLayerIdList.contains ( currentLayer->id () ) );
420
414
twWFSLayers->setCellWidget ( j, 3 , cbu );
421
-
422
- smUpdate->setMapping ( cbu, j );
423
- connect ( cbu, SIGNAL ( stateChanged ( int ) ), smUpdate, SLOT ( map () ) );
424
415
}
425
416
if (( provider->capabilities () & QgsVectorDataProvider::AddFeatures ) )
426
417
{
427
418
QCheckBox* cbi = new QCheckBox ();
428
419
cbi->setChecked ( wfstInsertLayerIdList.contains ( currentLayer->id () ) );
429
420
twWFSLayers->setCellWidget ( j, 4 , cbi );
430
-
431
- smInsert->setMapping ( cbi, j );
432
- connect ( cbi, SIGNAL ( stateChanged ( int ) ), smInsert, SLOT ( map () ) );
433
421
}
434
422
if (( provider->capabilities () & QgsVectorDataProvider::DeleteFeatures ) )
435
423
{
436
424
QCheckBox* cbd = new QCheckBox ();
437
425
cbd->setChecked ( wfstDeleteLayerIdList.contains ( currentLayer->id () ) );
438
426
twWFSLayers->setCellWidget ( j, 5 , cbd );
439
-
440
- smDelete->setMapping ( cbd, j );
441
- connect ( cbd, SIGNAL ( stateChanged ( int ) ), smDelete, SLOT ( map () ) );
442
427
}
443
428
444
429
j++;
@@ -1010,54 +995,21 @@ void QgsProjectProperties::cbxWFSPubliedStateChanged( int aIdx )
1010
995
QCheckBox* cb = qobject_cast<QCheckBox *>( twWFSLayers->cellWidget ( aIdx, 1 ) );
1011
996
if ( cb && !cb->isChecked () )
1012
997
{
1013
- QCheckBox* cbn = qobject_cast<QCheckBox *>( twWFSLayers->cellWidget ( aIdx, 2 ) );
1014
- if ( cbn )
1015
- cbn->setChecked ( false );
1016
- }
1017
- }
1018
-
1019
- void QgsProjectProperties::cbxWFSUpdateStateChanged ( int aIdx )
1020
- {
1021
- QCheckBox* cb = qobject_cast<QCheckBox *>( twWFSLayers->cellWidget ( aIdx, 2 ) );
1022
- if ( cb && cb->isChecked () )
1023
- {
1024
- QCheckBox* cbn = qobject_cast<QCheckBox *>( twWFSLayers->cellWidget ( aIdx, 1 ) );
1025
- if ( cbn )
1026
- cbn->setChecked ( true );
1027
- }
1028
- else if ( cb && !cb->isChecked () )
1029
- {
1030
- QCheckBox* cbn = qobject_cast<QCheckBox *>( twWFSLayers->cellWidget ( aIdx, 3 ) );
1031
- if ( cbn )
1032
- cbn->setChecked ( false );
1033
- }
1034
- }
1035
-
1036
- void QgsProjectProperties::cbxWFSInsertStateChanged ( int aIdx )
1037
- {
1038
- QCheckBox* cb = qobject_cast<QCheckBox *>( twWFSLayers->cellWidget ( aIdx, 3 ) );
1039
- if ( cb && cb->isChecked () )
1040
- {
1041
- QCheckBox* cbn = qobject_cast<QCheckBox *>( twWFSLayers->cellWidget ( aIdx, 2 ) );
1042
- if ( cbn )
1043
- cbn->setChecked ( true );
1044
- }
1045
- else if ( cb && !cb->isChecked () )
1046
- {
1047
- QCheckBox* cbn = qobject_cast<QCheckBox *>( twWFSLayers->cellWidget ( aIdx, 4 ) );
1048
- if ( cbn )
1049
- cbn->setChecked ( false );
1050
- }
1051
- }
1052
-
1053
- void QgsProjectProperties::cbxWFSDeleteStateChanged ( int aIdx )
1054
- {
1055
- QCheckBox* cb = qobject_cast<QCheckBox *>( twWFSLayers->cellWidget ( aIdx, 4 ) );
1056
- if ( cb && cb->isChecked () )
1057
- {
1058
- QCheckBox* cbn = qobject_cast<QCheckBox *>( twWFSLayers->cellWidget ( aIdx, 3 ) );
1059
- if ( cbn )
1060
- cbn->setChecked ( true );
998
+ QCheckBox* cbUpdate = qobject_cast<QCheckBox *>( twWFSLayers->cellWidget ( aIdx, 3 ) );
999
+ if ( cbUpdate )
1000
+ {
1001
+ cbUpdate->setChecked ( false );
1002
+ }
1003
+ QCheckBox* cbInsert = qobject_cast<QCheckBox *>( twWFSLayers->cellWidget ( aIdx, 4 ) );
1004
+ if ( cbInsert )
1005
+ {
1006
+ cbInsert->setChecked ( false );
1007
+ }
1008
+ QCheckBox* cbDelete = qobject_cast<QCheckBox *>( twWFSLayers->cellWidget ( aIdx, 5 ) );
1009
+ if ( cbDelete )
1010
+ {
1011
+ cbDelete->setChecked ( false );
1012
+ }
1061
1013
}
1062
1014
}
1063
1015
0 commit comments