summaryrefslogtreecommitdiffstats
path: root/divelist.c
diff options
context:
space:
mode:
authorGravatar Dirk Hohndel <dirk@hohndel.org>2013-01-17 10:59:43 -0800
committerGravatar Dirk Hohndel <dirk@hohndel.org>2013-01-17 11:17:48 -0800
commitd0d4bbece7e0a304a3e1f1fcea3608f3d741e8fa (patch)
tree3b2588afc37b40b49c5173921f8c871bb1024479 /divelist.c
parent91d6d12416086e08f97dece728ec9a6d08554230 (diff)
downloadsubsurface-d0d4bbece7e0a304a3e1f1fcea3608f3d741e8fa.tar.gz
Hack Makefile, gtk-gui.c and divelist.c to allow building w/o osm-gps-map
While we are waiting for an autotools generated Makefile, this should allow people to build that don't have osm-gps-map. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'divelist.c')
-rw-r--r--divelist.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/divelist.c b/divelist.c
index 3705c62ad..554fb8869 100644
--- a/divelist.c
+++ b/divelist.c
@@ -1659,10 +1659,12 @@ void edit_dive_when_cb(GtkWidget *menuitem, struct dive *dive)
}
}
+#if HAVE_OSM_GPS_MAP
static void show_gps_location_cb(GtkWidget *menuitem, struct dive *dive)
{
show_gps_location(dive);
}
+#endif
static void expand_all_cb(GtkWidget *menuitem, GtkTreeView *tree_view)
{
@@ -2475,14 +2477,14 @@ static void popup_divelist_menu(GtkTreeView *tree_view, GtkTreeModel *model, int
g_signal_connect(menuitem, "activate", G_CALLBACK(edit_dive_from_path_cb), path);
gtk_menu_shell_append(GTK_MENU_SHELL(menu), menuitem);
}
-
+#if HAVE_OSM_GPS_MAP
/* Only offer to show on map if it has a location. */
if (dive_has_location(dive)) {
menuitem = gtk_menu_item_new_with_label(_("Show in map"));
g_signal_connect(menuitem, "activate", G_CALLBACK(show_gps_location_cb), dive);
gtk_menu_shell_append(GTK_MENU_SHELL(menu), menuitem);
}
-
+#endif
/* only offer trip editing options when we are displaying the tree model */
if (dive_list.model == dive_list.treemodel) {
int depth = gtk_tree_path_get_depth(path);