X-Git-Url: https://git.street.me.uk/andy/viking.git/blobdiff_plain/b0252b2e1eca9711751ed3ea621657f452781c70..4f14a010d0a7d09721c32f0d35ffbeae05ea994c:/src/file.h?ds=inline diff --git a/src/file.h b/src/file.h index bbaf230e..b03ebcd0 100644 --- a/src/file.h +++ b/src/file.h @@ -28,9 +28,11 @@ #include "viktrwlayer.h" #include "vikviewport.h" -#define FILE_TYPE_GPSPOINT 1 -#define FILE_TYPE_GPSMAPPER 2 -#define FILE_TYPE_GPX 3 +typedef enum { +FILE_TYPE_GPSPOINT=1, +FILE_TYPE_GPSMAPPER=2, +FILE_TYPE_GPX=3, +} VikFileType_t; const gchar *a_file_basename ( const gchar *filename ); gboolean check_file_ext ( const gchar *filename, const gchar *fileext ); @@ -38,7 +40,8 @@ gboolean check_file_ext ( const gchar *filename, const gchar *fileext ); /* 0 on failure, 1 on success (vik file) 2 on success (other file) */ gshort a_file_load ( VikAggregateLayer *top, VikViewport *vp, const gchar *filename ); gboolean a_file_save ( VikAggregateLayer *top, gpointer vp, const gchar *filename ); -gboolean a_file_export ( VikTrwLayer *vtl, const gchar *filename, gshort file_type ); +/* Only need to define VikTrack and trackname if the file type is FILE_TYPE_GPX_TRACK */ +gboolean a_file_export ( VikTrwLayer *vtl, const gchar *filename, VikFileType_t file_type, const gchar *trackname ); const gchar *a_get_viking_dir(); void file_write_layer_param ( FILE *f, const gchar *name, guint8 type, VikLayerParamData data );