mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Cleanup: fix include weirdness concerning string_to_*() functions
The string_to_*() functions were declared in dive.h and qthelper.h. Moreover in one file they were declared with C in the other with C++ linkage. This only works because qthelper.h includes dive.h first. Fix this anomaly by declaring the functions only in qthelper.h, but moving them from the C++ to the C part. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
parent
b862e028c6
commit
b720f36978
2 changed files with 5 additions and 10 deletions
|
|
@ -530,11 +530,6 @@ extern void set_git_prefs(const char *prefs);
|
||||||
extern char *get_dive_date_c_string(timestamp_t when);
|
extern char *get_dive_date_c_string(timestamp_t when);
|
||||||
extern void update_setpoint_events(const struct dive *dive, struct divecomputer *dc);
|
extern void update_setpoint_events(const struct dive *dive, struct divecomputer *dc);
|
||||||
|
|
||||||
extern weight_t string_to_weight(const char *str);
|
|
||||||
extern depth_t string_to_depth(const char *str);
|
|
||||||
extern pressure_t string_to_pressure(const char *str);
|
|
||||||
extern volume_t string_to_volume(const char *str, pressure_t workp);
|
|
||||||
extern fraction_t string_to_fraction(const char *str);
|
|
||||||
extern void average_max_depth(struct diveplan *dive, int *avg_depth, int *max_depth);
|
extern void average_max_depth(struct diveplan *dive, int *avg_depth, int *max_depth);
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
|
|
|
||||||
|
|
@ -33,11 +33,6 @@ void write_hashes();
|
||||||
QString thumbnailFileName(const QString &filename);
|
QString thumbnailFileName(const QString &filename);
|
||||||
void learnPictureFilename(const QString &originalName, const QString &localName);
|
void learnPictureFilename(const QString &originalName, const QString &localName);
|
||||||
QString localFilePath(const QString &originalFilename);
|
QString localFilePath(const QString &originalFilename);
|
||||||
weight_t string_to_weight(const char *str);
|
|
||||||
depth_t string_to_depth(const char *str);
|
|
||||||
pressure_t string_to_pressure(const char *str);
|
|
||||||
volume_t string_to_volume(const char *str, pressure_t workp);
|
|
||||||
fraction_t string_to_fraction(const char *str);
|
|
||||||
int getCloudURL(QString &filename);
|
int getCloudURL(QString &filename);
|
||||||
bool parseGpsText(const QString &gps_text, double *latitude, double *longitude);
|
bool parseGpsText(const QString &gps_text, double *latitude, double *longitude);
|
||||||
void init_proxy();
|
void init_proxy();
|
||||||
|
|
@ -162,6 +157,11 @@ void print_qt_versions();
|
||||||
void lock_planner();
|
void lock_planner();
|
||||||
void unlock_planner();
|
void unlock_planner();
|
||||||
xsltStylesheetPtr get_stylesheet(const char *name);
|
xsltStylesheetPtr get_stylesheet(const char *name);
|
||||||
|
weight_t string_to_weight(const char *str);
|
||||||
|
depth_t string_to_depth(const char *str);
|
||||||
|
pressure_t string_to_pressure(const char *str);
|
||||||
|
volume_t string_to_volume(const char *str, pressure_t workp);
|
||||||
|
fraction_t string_to_fraction(const char *str);
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue