diff options
Diffstat (limited to 'src/imports/location/qdeclarativegeomappolygonobject_p.h')
-rw-r--r-- | src/imports/location/qdeclarativegeomappolygonobject_p.h | 110 |
1 files changed, 0 insertions, 110 deletions
diff --git a/src/imports/location/qdeclarativegeomappolygonobject_p.h b/src/imports/location/qdeclarativegeomappolygonobject_p.h deleted file mode 100644 index d7e26206..00000000 --- a/src/imports/location/qdeclarativegeomappolygonobject_p.h +++ /dev/null @@ -1,110 +0,0 @@ -/**************************************************************************** -** -** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). -** All rights reserved. -** Contact: Nokia Corporation (qt-info@nokia.com) -** -** This file is part of the Qt Mobility Components. -** -** $QT_BEGIN_LICENSE:LGPL$ -** GNU Lesser General Public License Usage -** This file may be used under the terms of the GNU Lesser General Public -** License version 2.1 as published by the Free Software Foundation and -** appearing in the file LICENSE.LGPL included in the packaging of this -** file. Please review the following information to ensure the GNU Lesser -** General Public License version 2.1 requirements will be met: -** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. -** -** In addition, as a special exception, Nokia gives you certain additional -** rights. These rights are described in the Nokia Qt LGPL Exception -** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. -** -** GNU General Public License Usage -** Alternatively, this file may be used under the terms of the GNU General -** Public License version 3.0 as published by the Free Software Foundation -** and appearing in the file LICENSE.GPL included in the packaging of this -** file. Please review the following information to ensure the GNU General -** Public License version 3.0 requirements will be met: -** http://www.gnu.org/copyleft/gpl.html. -** -** Other Usage -** Alternatively, this file may be used in accordance with the terms and -** conditions contained in a signed written agreement between you and Nokia. -** -** -** -** -** -** $QT_END_LICENSE$ -** -****************************************************************************/ - -#ifndef QDECLARATIVEGEOMAPPOLYGONOBJECT_H -#define QDECLARATIVEGEOMAPPOLYGONOBJECT_H - -#include "qdeclarativegeomapobject_p.h" -#include "qdeclarativecoordinate_p.h" -#include "qdeclarativegeomapobjectborder_p.h" -#include "qgeomappolygonobject.h" - -#include <QDeclarativeListProperty> - -class QColor; -class QBrush; - -QT_BEGIN_NAMESPACE - -class QDeclarativeGeoMapPolygonObject : public QDeclarativeGeoMapObject -{ - Q_OBJECT - - Q_PROPERTY(QDeclarativeListProperty<QDeclarativeCoordinate> path READ declarativePath NOTIFY pathChanged) - Q_PROPERTY(QColor color READ color WRITE setColor NOTIFY colorChanged) - Q_PROPERTY(QDeclarativeGeoMapObjectBorder* border READ border CONSTANT) - -public: - QDeclarativeGeoMapPolygonObject(QSGItem *parent = 0); - ~QDeclarativeGeoMapPolygonObject(); - - QDeclarativeListProperty<QDeclarativeCoordinate> declarativePath(); - - Q_INVOKABLE void addCoordinate(QDeclarativeCoordinate* coordinate); - Q_INVOKABLE void removeCoordinate(QDeclarativeCoordinate* coordinate); - Q_INVOKABLE void clearCoordinates(); - - QColor color() const; - void setColor(const QColor &color); - - // From QDeclarativeParserStatus - virtual void classBegin() {} - virtual void componentComplete(); - - QDeclarativeGeoMapObjectBorder* border(); - -Q_SIGNALS: - void colorChanged(const QColor &color); - void pathChanged(); - -private Q_SLOTS: - void borderColorChanged(const QColor &color); - void borderWidthChanged(int width); - -private: - static void path_append(QDeclarativeListProperty<QDeclarativeCoordinate> *prop, QDeclarativeCoordinate *coordinate); - static int path_count(QDeclarativeListProperty<QDeclarativeCoordinate> *prop); - static QDeclarativeCoordinate* path_at(QDeclarativeListProperty<QDeclarativeCoordinate> *prop, int index); - static void path_clear(QDeclarativeListProperty<QDeclarativeCoordinate> *prop); - void pathPropertyChanged(); - - QPointer<QGeoMapPolygonObject> polygon_; - QList<QDeclarativeCoordinate*> path_; - QColor color_; - QDeclarativeGeoMapObjectBorder border_; - bool componentCompleted_; -}; - -QT_END_NAMESPACE - -QML_DECLARE_TYPE(QT_PREPEND_NAMESPACE(QDeclarativeGeoMapPolygonObject)); - -#endif |