summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJohannes Hofmann <Johannes.Hofmann@gmx.de>2009-03-27 10:20:46 +0100
committerJohannes Hofmann <Johannes.Hofmann@gmx.de>2009-03-27 10:20:46 +0100
commit7706e347215a26fa40b8fd086cea8d34b10001b3 (patch)
tree07fb27ca0265249e80c4a6f861d027994b0f41d0 /src
parent1e931fc5ca3a378fcf8eb42837ee1912c10a165a (diff)
more int->bool
Diffstat (limited to 'src')
-rw-r--r--src/GipfelWidget.H2
-rw-r--r--src/GipfelWidget.cxx16
-rw-r--r--src/gipfel.cxx2
3 files changed, 10 insertions, 10 deletions
diff --git a/src/GipfelWidget.H b/src/GipfelWidget.H
index 57ce337..24d0bb6 100644
--- a/src/GipfelWidget.H
+++ b/src/GipfelWidget.H
@@ -67,7 +67,7 @@ class GipfelWidget : public Fl_Group {
void set_focal_length_35mm(double s);
void set_height_dist_ratio(double r);
void set_hide_value(double h);
- void set_show_hidden(int h);
+ void set_show_hidden(bool h);
void set_view_lat(double v);
void set_view_long(double v);
void set_view_height(double v);
diff --git a/src/GipfelWidget.cxx b/src/GipfelWidget.cxx
index 9fc56d6..2ed55c1 100644
--- a/src/GipfelWidget.cxx
+++ b/src/GipfelWidget.cxx
@@ -43,8 +43,8 @@ GipfelWidget::GipfelWidget(int X,int Y,int W, int H): Fl_Group(X, Y, W, H) {
known_hills = new Hills();
img_file = NULL;
track_width = 200.0;
- show_hidden = 0;
- have_gipfel_info = 0;
+ show_hidden = false;
+ have_gipfel_info = false;
md = new ImageMetaData();
track_points = NULL;
fl_register_images();
@@ -83,11 +83,11 @@ GipfelWidget::load_image(char *file) {
set_view_height(md->height());
projection((ProjectionLSQ::Projection_t) md->projection_type());
- have_gipfel_info = 1;
+ have_gipfel_info = true;
direction = md->direction();
if (isnan(direction)) {
set_center_angle(0.0);
- have_gipfel_info = 0;
+ have_gipfel_info = false;
} else {
set_center_angle(direction);
}
@@ -95,7 +95,7 @@ GipfelWidget::load_image(char *file) {
nick = md->nick();
if (isnan(nick)) {
set_nick_angle(0.0);
- have_gipfel_info = 0;
+ have_gipfel_info = false;
} else {
set_nick_angle(nick);
}
@@ -103,7 +103,7 @@ GipfelWidget::load_image(char *file) {
tilt = md->tilt();
if (isnan(tilt)) {
set_tilt_angle(0.0);
- have_gipfel_info = 0;
+ have_gipfel_info = false;
} else {
set_tilt_angle(tilt);
}
@@ -111,7 +111,7 @@ GipfelWidget::load_image(char *file) {
fl = md->focal_length_35mm();
if (isnan(fl) || fl == 0.0) {
set_focal_length_35mm(35.0);
- have_gipfel_info = 0;
+ have_gipfel_info = false;
} else {
set_focal_length_35mm(fl);
}
@@ -544,7 +544,7 @@ GipfelWidget::set_hide_value(double h) {
}
void
-GipfelWidget::set_show_hidden(int h) {
+GipfelWidget::set_show_hidden(bool h) {
show_hidden = h;
set_labels(pan->get_visible_mountains());
redraw();
diff --git a/src/gipfel.cxx b/src/gipfel.cxx
index 4c76e40..879a60a 100644
--- a/src/gipfel.cxx
+++ b/src/gipfel.cxx
@@ -199,7 +199,7 @@ void proj_cb(Fl_Value_Input* o, void*d) {
}
void hidden_cb(Fl_Menu_* o, void*d) {
- gipf->set_show_hidden(o->mvalue()->value());
+ gipf->set_show_hidden(o->mvalue()->value() != 0);
}
void comp_cb(Fl_Widget *, void *) {