File tree 1 file changed +19
-2
lines changed
1 file changed +19
-2
lines changed Original file line number Diff line number Diff line change @@ -2305,9 +2305,27 @@ void QgisApp::createToolBars()
2305
2305
selectActions << mActionSelectByForm << mActionSelectByExpression << mActionSelectAll
2306
2306
<< mActionInvertSelection ;
2307
2307
bt->addActions ( selectActions );
2308
- bt->setDefaultAction ( mActionSelectByForm );
2308
+
2309
+ QAction *defSelectionAction = mActionSelectByForm ;
2310
+ switch ( settings.value ( QStringLiteral ( " UI/selectionTool" ), 0 ).toInt () )
2311
+ {
2312
+ case 0 :
2313
+ defSelectionAction = mActionSelectByForm ;
2314
+ break ;
2315
+ case 1 :
2316
+ defSelectionAction = mActionSelectByExpression ;
2317
+ break ;
2318
+ case 2 :
2319
+ defSelectionAction = mActionSelectAll ;
2320
+ break ;
2321
+ case 3 :
2322
+ defSelectionAction = mActionInvertSelection ;
2323
+ break ;
2324
+ }
2325
+ bt->setDefaultAction ( defSelectionAction );
2309
2326
QAction *selectionAction = mAttributesToolBar ->insertWidget ( mActionDeselectAll , bt );
2310
2327
selectionAction->setObjectName ( QStringLiteral ( " ActionSelection" ) );
2328
+ connect ( bt, &QToolButton::triggered, this , &QgisApp::toolButtonActionTriggered );
2311
2329
2312
2330
// select tool button
2313
2331
@@ -2409,7 +2427,6 @@ void QgisApp::createToolBars()
2409
2427
case 4 :
2410
2428
defAnnotationAction = mActionAnnotation ;
2411
2429
break ;
2412
-
2413
2430
}
2414
2431
bt->setDefaultAction ( defAnnotationAction );
2415
2432
QAction *annotationAction = mAttributesToolBar ->addWidget ( bt );
You can’t perform that action at this time.
0 commit comments