diff options
author | Marc Mutz <marc.mutz@qt.io> | 2022-02-15 10:13:46 +0100 |
---|---|---|
committer | Marc Mutz <marc.mutz@qt.io> | 2022-03-11 20:15:49 +0100 |
commit | 61e3fe7fd903981a75951ab360b37d186335afcb (patch) | |
tree | 1fde7a232f9ade0d2c7f69dcb7ab81c794a91dc4 /examples | |
parent | abe3b4c9b947de5e55085b37840e0d1d6f3aae42 (diff) |
Do not assume implicit string-ish → QColor conversion
We want to mark the corresponding QColor ctor(s) explicit.
Use Qt::GlobalColor or the new QColor::fromString() instead.
Change-Id: I68bf75a094e6821b97682de5a0ffd975834d22d0
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
Diffstat (limited to 'examples')
-rw-r--r-- | examples/embedded/flickable/main.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/examples/embedded/flickable/main.cpp b/examples/embedded/flickable/main.cpp index 139baa6ba7..cb3920d428 100644 --- a/examples/embedded/flickable/main.cpp +++ b/examples/embedded/flickable/main.cpp @@ -101,8 +101,8 @@ public: m_colorNames << (str + " " + c); QStringList duet = c.split(' '); - m_firstColor << duet[0]; - m_secondColor << duet[1]; + m_firstColor << QColor::fromString(duet[0]); + m_secondColor << QColor::fromString(duet[1]); } setAttribute(Qt::WA_OpaquePaintEvent, true); |