diff options
author | Marc Mutz <marc.mutz@kdab.com> | 2016-10-10 19:26:59 +0200 |
---|---|---|
committer | Friedemann Kleint <Friedemann.Kleint@qt.io> | 2016-10-11 06:20:49 +0000 |
commit | 17ac3b2c146d1f48b88dbdc09927ddc3dd3aef81 (patch) | |
tree | 6ba6a70db80d1cb059e99a5077899ffec0699e4d /src | |
parent | 5c652cb6aa11d508236f80cfdb0ac7cf25fcda70 (diff) |
QColor: unbreak mingw build
The usual: inline functions not declared inline, but defined as such
give mingw errors:
qcolor.h:280:8: error: 'QColor::QColor(QLatin1String)' redeclared without dllimport attribute after being referenced with dll linkage [-Werror]
Fix by declaring the functions inline, not only at the definition.
Task-number: QTBUG-56459
Change-Id: I3f05e5e3597f6aa0ed318c7e7a11afdefc4c1d2f
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Diffstat (limited to 'src')
-rw-r--r-- | src/gui/painting/qcolor.h | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/gui/painting/qcolor.h b/src/gui/painting/qcolor.h index db6eb92916..22fcbcb2a8 100644 --- a/src/gui/painting/qcolor.h +++ b/src/gui/painting/qcolor.h @@ -67,18 +67,18 @@ public: enum Spec { Invalid, Rgb, Hsv, Cmyk, Hsl }; enum NameFormat { HexRgb, HexArgb }; - QColor() Q_DECL_NOTHROW; + inline QColor() Q_DECL_NOTHROW; QColor(Qt::GlobalColor color) Q_DECL_NOTHROW; - QColor(int r, int g, int b, int a = 255); + inline QColor(int r, int g, int b, int a = 255); QColor(QRgb rgb) Q_DECL_NOTHROW; QColor(QRgba64 rgba64) Q_DECL_NOTHROW; - QColor(const QString& name); - QColor(const char *aname) : QColor(QLatin1String(aname)) {} - QColor(QLatin1String name); + inline QColor(const QString& name); + inline QColor(const char *aname) : QColor(QLatin1String(aname)) {} + inline QColor(QLatin1String name); QColor(Spec spec) Q_DECL_NOTHROW; #if QT_VERSION < QT_VERSION_CHECK(6,0,0) - QColor(const QColor &color) Q_DECL_NOTHROW; // ### Qt 6: remove all of these, the trivial ones are fine. + inline QColor(const QColor &color) Q_DECL_NOTHROW; // ### Qt 6: remove all of these, the trivial ones are fine. # ifdef Q_COMPILER_RVALUE_REFS QColor(QColor &&other) Q_DECL_NOTHROW : cspec(other.cspec), ct(other.ct) {} QColor &operator=(QColor &&other) Q_DECL_NOTHROW |