X-Git-Url: https://git.street.me.uk/andy/viking.git/blobdiff_plain/184ec0fa6d4d729b602292f158840bc000e3e117..f77bbb5e54216f967848bf6806a341be8b83d41c:/src/viktrwlayer.h diff --git a/src/viktrwlayer.h b/src/viktrwlayer.h index ae0e8315..2b324e4d 100644 --- a/src/viktrwlayer.h +++ b/src/viktrwlayer.h @@ -2,7 +2,7 @@ * viking -- GPS Data and Topo Analyzer, Explorer, and Manager * * Copyright (C) 2003-2005, Evan Battaglia - * Copyright (c) 2011, Rob Norris + * Copyright (c) 2011-2013, Rob Norris * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -106,20 +106,53 @@ typedef struct { typedef GList* (*VikTrwlayerGetTracksAndLayersFunc) (VikLayer*, gpointer); GList *vik_trw_layer_build_track_list_t ( VikTrwLayer *vtl, GList *tracks ); +// For creating a list of waypoints with the corresponding layer it is in +// (thus a selection of waypoints may be from differing layers) +typedef struct { + VikWaypoint *wpt; + VikTrwLayer *vtl; +} vik_trw_waypoint_list_t; + +typedef GList* (*VikTrwlayerGetWaypointsAndLayersFunc) (VikLayer*, gpointer); +GList *vik_trw_layer_build_waypoint_list_t ( VikTrwLayer *vtl, GList *waypoints ); + +GdkPixbuf* get_wp_sym_small ( gchar *symbol ); + /* Exposed Layer Interface function definitions */ // Intended only for use by other trw_layer subwindows void trw_layer_verify_thumbnails ( VikTrwLayer *vtl, GtkWidget *vp ); // Other functions only for use by other trw_layer subwindows gchar *trw_layer_new_unique_sublayer_name ( VikTrwLayer *vtl, gint sublayer_type, const gchar *name ); +void trw_layer_waypoint_rename ( VikTrwLayer *vtl, VikWaypoint *wp, const gchar *new_name ); +void trw_layer_waypoint_reset_icon ( VikTrwLayer *vtl, VikWaypoint *wp ); +void trw_layer_calculate_bounds_waypoints ( VikTrwLayer *vtl ); gboolean vik_trw_layer_get_tracks_visibility ( VikTrwLayer *vtl ); gboolean vik_trw_layer_get_routes_visibility ( VikTrwLayer *vtl ); gboolean vik_trw_layer_get_waypoints_visibility ( VikTrwLayer *vtl ); -void trw_layer_update_treeview ( VikTrwLayer *vtl, VikTrack *trk, gpointer *trk_id ); +void trw_layer_update_treeview ( VikTrwLayer *vtl, VikTrack *trk ); void trw_layer_dialog_shift ( VikTrwLayer *vtl, GtkWindow *dialog, VikCoord *coord, gboolean vertical ); +typedef struct { + VikTrack *trk; // input + gpointer uuid; // output +} trku_udata; +gboolean trw_layer_track_find_uuid ( const gpointer id, const VikTrack *trk, gpointer udata ); + +typedef struct { + VikWaypoint *wp; // input + gpointer uuid; // output +} wpu_udata; +gboolean trw_layer_waypoint_find_uuid ( const gpointer id, const VikWaypoint *wp, gpointer udata ); + +void trw_layer_zoom_to_show_latlons ( VikTrwLayer *vtl, VikViewport *vvp, struct LatLon maxmin[2] ); + +GHashTable *vik_trw_layer_get_tracks_iters ( VikTrwLayer *vtl ); +GHashTable *vik_trw_layer_get_routes_iters ( VikTrwLayer *vtl ); +GHashTable *vik_trw_layer_get_waypoints_iters ( VikTrwLayer *vtl ); + G_END_DECLS #endif