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

source code of qtdatavis3d/src/datavisualizationqml/declarativecolor.cpp