mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Fix build error on Windows with Qt5.5
I'm not quite sure why this works, but it appears to do the trick. Apparently you are supposed not to have the meta type declaration in a shared header file. Also, with Qt5.5 you can't have the declaration for QBluetoothDeviceInfo, not even on Windows. This may need more tweaking to make sure it works on all combinations of OS and Qt version. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
d0fba482b7
commit
04773705e3
2 changed files with 7 additions and 7 deletions
|
@ -6,6 +6,13 @@
|
|||
#include "ui_btdeviceselectiondialog.h"
|
||||
#include "btdeviceselectiondialog.h"
|
||||
|
||||
#if defined(Q_OS_WIN)
|
||||
Q_DECLARE_METATYPE(QBluetoothDeviceDiscoveryAgent::Error)
|
||||
#endif
|
||||
#if QT_VERSION < 0x050500
|
||||
Q_DECLARE_METATYPE(QBluetoothDeviceInfo)
|
||||
#endif
|
||||
|
||||
BtDeviceSelectionDialog::BtDeviceSelectionDialog(QWidget *parent) :
|
||||
QDialog(parent),
|
||||
ui(new Ui::BtDeviceSelectionDialog),
|
||||
|
|
|
@ -22,13 +22,6 @@
|
|||
#undef DC_VERSION // this is already declared in libdivecomputer header
|
||||
#endif
|
||||
|
||||
#if defined(Q_OS_WIN)
|
||||
Q_DECLARE_METATYPE(QBluetoothDeviceInfo)
|
||||
Q_DECLARE_METATYPE(QBluetoothDeviceDiscoveryAgent::Error)
|
||||
#elif QT_VERSION < 0x050500
|
||||
Q_DECLARE_METATYPE(QBluetoothDeviceInfo)
|
||||
#endif
|
||||
|
||||
namespace Ui {
|
||||
class BtDeviceSelectionDialog;
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue