diff options
-rw-r--r-- | src/GipfelWidget.cxx | 12 | ||||
-rw-r--r-- | src/Hill.H | 2 | ||||
-rw-r--r-- | src/Hill.cxx | 4 | ||||
-rw-r--r-- | src/Panorama.cxx | 4 | ||||
-rw-r--r-- | src/choose_hill.cxx | 2 |
5 files changed, 12 insertions, 12 deletions
diff --git a/src/GipfelWidget.cxx b/src/GipfelWidget.cxx index aa5c2ca..cb381d3 100644 --- a/src/GipfelWidget.cxx +++ b/src/GipfelWidget.cxx @@ -244,7 +244,7 @@ GipfelWidget::draw() { int m_x = w() / 2 + x() + (int) rint(m->x); int m_y = h() / 2 + y() + (int) rint(m->y); - if ((m->flags & (Hill::DUPLICATE|Hill::TRACK_POINT)) || + if ((m->flags & (Hill::DUPLIC|Hill::TRACK_POINT)) || (!show_hidden && (m->flags & Hill::HIDDEN)) || known_hills->contains(m) || m == focused_mountain) continue; @@ -259,7 +259,7 @@ GipfelWidget::draw() { int m_x = w() / 2 + x() + (int) rint(m->x); int m_y = h() / 2 + y() + (int) rint(m->y); - if ((m->flags & (Hill::DUPLICATE|Hill::TRACK_POINT)) || + if ((m->flags & (Hill::DUPLIC|Hill::TRACK_POINT)) || (!show_hidden && (m->flags & Hill::HIDDEN)) || m == focused_mountain) continue; @@ -346,7 +346,7 @@ GipfelWidget::set_labels(Hills *v) { Hill *m = v->get(i); Hills colliding; - if (m->flags & (Hill::DUPLICATE | Hill::TRACK_POINT)) + if (m->flags & (Hill::DUPLIC | Hill::TRACK_POINT)) continue; if (!show_hidden && (m->flags & Hill::HIDDEN)) @@ -358,7 +358,7 @@ GipfelWidget::set_labels(Hills *v) { for (int j = i - 1; j >= 0; j--) { Hill *n = v->get(j); - if (n->flags & (Hill::DUPLICATE | Hill::TRACK_POINT)) + if (n->flags & (Hill::DUPLIC | Hill::TRACK_POINT)) continue; if (!show_hidden && (n->flags & Hill::HIDDEN)) @@ -414,7 +414,7 @@ GipfelWidget::toggle_known_mountain(int m_x, int m_y) { for (int i = 0; i < mnts->get_num(); i++) { Hill *m = mnts->get(i); - if (m->flags & (Hill::DUPLICATE | Hill::TRACK_POINT)) + if (m->flags & (Hill::DUPLIC | Hill::TRACK_POINT)) continue; if (m_x - center_x >= m->x - 2 && m_x - center_x < m->x + 2 && @@ -692,7 +692,7 @@ GipfelWidget::export_hills(const char *file, FILE *fp) { int _x = (int) rint(m->x) + w() / 2; int _y = (int) rint(m->y) + h() / 2; - if (m->flags & Hill::DUPLICATE || m->flags & Hill::HIDDEN || + if (m->flags & Hill::DUPLIC || m->flags & Hill::HIDDEN || file && !(m->flags & Hill::EXPORT)) { continue; } @@ -12,7 +12,7 @@ class Hill; class Hill { public: typedef enum { - DUPLICATE = 0x01, + DUPLIC = 0x01, TRACK_POINT = 0x02, VISIBLE = 0x04, HIDDEN = 0x08, diff --git a/src/Hill.cxx b/src/Hill.cxx index b053568..d57c576 100644 --- a/src/Hill.cxx +++ b/src/Hill.cxx @@ -140,10 +140,10 @@ void Hills::mark_duplicates(double dist) { j = i + 1; n = get(j); while (n && fabs(n->phi - m->phi) <= dist) { - if (! n->flags & Hill::DUPLICATE) { + if (! n->flags & Hill::DUPLIC) { if (fabs(n->lam - m->lam) <= dist && fabs(n->height - m->height) <= 50.0 ) { - n->flags |= Hill::DUPLICATE; + n->flags |= Hill::DUPLIC; } } j = j + 1; diff --git a/src/Panorama.cxx b/src/Panorama.cxx index 7c4124f..e340599 100644 --- a/src/Panorama.cxx +++ b/src/Panorama.cxx @@ -317,13 +317,13 @@ Panorama::mark_hidden(Hills *hills) { m->flags &= ~Hill::HIDDEN; - if (m->flags & Hill::DUPLICATE) + if (m->flags & Hill::DUPLIC) continue; for (int j = 0; j < hills->get_num(); j++) { Hill *n = hills->get(j); - if (n->flags & Hill::DUPLICATE || n->flags & Hill::TRACK_POINT) + if (n->flags & Hill::DUPLIC || n->flags & Hill::TRACK_POINT) continue; if (m == n || fabs(m->alph - n->alph > pi_d / 2.0)) diff --git a/src/choose_hill.cxx b/src/choose_hill.cxx index c83d8b1..48e44d5 100644 --- a/src/choose_hill.cxx +++ b/src/choose_hill.cxx @@ -21,7 +21,7 @@ choose_hill(const Hills *hills, const char *l) { char buf[256]; Hill *m = h_sort->get(i); - if (m->flags & (Hill::DUPLICATE | Hill::TRACK_POINT)) + if (m->flags & (Hill::DUPLIC | Hill::TRACK_POINT)) continue; snprintf(buf, sizeof(buf) - 1, "%s (%dm)", m->name, (int) m->height); |