Cleanup: remove dive_table and dive_site_table Q_METATYPEs

These are not passed through QML anymore.

Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
Berthold Stoeger 2019-09-25 21:28:46 +02:00 committed by Dirk Hohndel
parent 7615e71760
commit a1a2492438
2 changed files with 3 additions and 8 deletions

View file

@ -436,15 +436,11 @@ extern void update_setpoint_events(const struct dive *dive, struct divecomputer
#ifdef __cplusplus #ifdef __cplusplus
} }
/* Make pointers to dive, dive_trip, dive_table, trip_table and dive_site_table /* Make pointers to dive and dive_trip "Qt metatypes" so that they can be passed through
* "Qt metatypes" so that they can be passed through QVariants and through QML. * QVariants and through QML.
* Note: we have to use the typedef "dive_table_t" instead of "struct dive_table", */
* because MOC removes the "struct", but dive_table is already the name of a global
* variable, leading to compilation errors. Likewise for "struct trip_table" and
* "struct dive_site_table" (defined in "dive.h" and "divesite.h"). */
#include <QObject> #include <QObject>
Q_DECLARE_METATYPE(struct dive *); Q_DECLARE_METATYPE(struct dive *);
Q_DECLARE_METATYPE(dive_table_t *);
#endif #endif

View file

@ -81,7 +81,6 @@ QString constructLocationTags(struct taxonomy_data *taxonomy, bool for_maintab);
/* Make pointer-to-dive_site a "Qt metatype" so that we can pass it through QVariants */ /* Make pointer-to-dive_site a "Qt metatype" so that we can pass it through QVariants */
Q_DECLARE_METATYPE(dive_site *); Q_DECLARE_METATYPE(dive_site *);
Q_DECLARE_METATYPE(dive_site_table_t *);
#endif #endif