| 1 | // Copyright (C) 2023 The Qt Company Ltd. |
|---|---|
| 2 | // SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only |
| 3 | |
| 4 | #include "qquickgraphscolor_p.h" |
| 5 | |
| 6 | QT_BEGIN_NAMESPACE |
| 7 | |
| 8 | QQuickGraphsColor::QQuickGraphsColor(QObject *parent) |
| 9 | : QObject(parent) |
| 10 | {} |
| 11 | |
| 12 | QQuickGraphsColor::~QQuickGraphsColor() {} |
| 13 | |
| 14 | void QQuickGraphsColor::setColor(QColor color) |
| 15 | { |
| 16 | if (m_color != color) { |
| 17 | m_color = color; |
| 18 | emit colorChanged(color); |
| 19 | } |
| 20 | } |
| 21 | |
| 22 | QColor QQuickGraphsColor::color() const |
| 23 | { |
| 24 | return m_color; |
| 25 | } |
| 26 | |
| 27 | QT_END_NAMESPACE |
| 28 |
