1
0
mirror of https://github.com/tumic0/GPXSee.git synced 2024-10-06 14:53:21 +02:00

Fixed "Show POI laels" setting

This commit is contained in:
Martin Tůma 2021-05-09 22:36:37 +02:00
parent cbaecee4a8
commit 64aa44d09b
2 changed files with 7 additions and 3 deletions

View File

@ -2072,6 +2072,9 @@ void GUI::writeSettings()
settings.setValue(SHOW_POI_SETTING, _showPOIAction->isChecked());
if (_overlapPOIAction->isChecked() != OVERLAP_POI_DEFAULT)
settings.setValue(OVERLAP_POI_SETTING, _overlapPOIAction->isChecked());
if (_showPOILabelsAction->isChecked() != SHOW_POI_LABELS_DEFAULT)
settings.setValue(SHOW_POI_LABELS_SETTING,
_showPOILabelsAction->isChecked());
int j = 0;
QList<QAction*> poiActions(_poisActionGroup->actions());
@ -2350,7 +2353,8 @@ void GUI::readSettings()
_mapView->showOverlappedPOIs(false);
else
_overlapPOIAction->setChecked(true);
if (!settings.value(LABELS_POI_SETTING, LABELS_POI_DEFAULT).toBool())
if (!settings.value(SHOW_POI_LABELS_SETTING, SHOW_POI_LABELS_DEFAULT)
.toBool())
_mapView->showPOILabels(false);
else
_showPOILabelsAction->setChecked(true);

View File

@ -40,8 +40,8 @@
#define POI_SETTINGS_GROUP "POI"
#define OVERLAP_POI_SETTING "overlap"
#define OVERLAP_POI_DEFAULT false
#define LABELS_POI_SETTING "labels"
#define LABELS_POI_DEFAULT true
#define SHOW_POI_LABELS_SETTING "labels"
#define SHOW_POI_LABELS_DEFAULT true
#define SHOW_POI_SETTING "show"
#define SHOW_POI_DEFAULT false
#define DISABLED_POI_FILE_SETTINGS_PREFIX "disabled"