summaryrefslogtreecommitdiff
path: root/src/controls/Private/qquicksceneposlistener.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/controls/Private/qquicksceneposlistener.cpp')
-rw-r--r--src/controls/Private/qquicksceneposlistener.cpp57
1 files changed, 30 insertions, 27 deletions
diff --git a/src/controls/Private/qquicksceneposlistener.cpp b/src/controls/Private/qquicksceneposlistener.cpp
index 6bcc1deb..4e5a4a5e 100644
--- a/src/controls/Private/qquicksceneposlistener.cpp
+++ b/src/controls/Private/qquicksceneposlistener.cpp
@@ -1,34 +1,37 @@
/****************************************************************************
**
-** Copyright (C) 2015 The Qt Company Ltd.
-** Contact: http://www.qt.io/licensing/
+** Copyright (C) 2016 The Qt Company Ltd.
+** Contact: https://www.qt.io/licensing/
**
** This file is part of the Qt Quick Controls module of the Qt Toolkit.
**
-** $QT_BEGIN_LICENSE:LGPL3$
+** $QT_BEGIN_LICENSE:LGPL$
** Commercial License Usage
** Licensees holding valid commercial Qt licenses may use this file in
** accordance with the commercial license agreement provided with the
** Software or, alternatively, in accordance with the terms contained in
** a written agreement between you and The Qt Company. For licensing terms
-** and conditions see http://www.qt.io/terms-conditions. For further
-** information use the contact form at http://www.qt.io/contact-us.
+** and conditions see https://www.qt.io/terms-conditions. For further
+** information use the contact form at https://www.qt.io/contact-us.
**
** GNU Lesser General Public License Usage
** Alternatively, this file may be used under the terms of the GNU Lesser
** General Public License version 3 as published by the Free Software
-** Foundation and appearing in the file LICENSE.LGPLv3 included in the
+** Foundation and appearing in the file LICENSE.LGPL3 included in the
** packaging of this file. Please review the following information to
** ensure the GNU Lesser General Public License version 3 requirements
-** will be met: https://www.gnu.org/licenses/lgpl.html.
+** will be met: https://www.gnu.org/licenses/lgpl-3.0.html.
**
** GNU General Public License Usage
** Alternatively, this file may be used under the terms of the GNU
-** General Public License version 2.0 or later 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 2.0 requirements will be
-** met: http://www.gnu.org/licenses/gpl-2.0.html.
+** General Public License version 2.0 or (at your option) the GNU General
+** Public license version 3 or any later version approved by the KDE Free
+** Qt Foundation. The licenses are as published by the Free Software
+** Foundation and appearing in the file LICENSE.GPL2 and LICENSE.GPL3
+** included in the packaging of this file. Please review the following
+** information to ensure the GNU General Public License requirements will
+** be met: https://www.gnu.org/licenses/gpl-2.0.html and
+** https://www.gnu.org/licenses/gpl-3.0.html.
**
** $QT_END_LICENSE$
**
@@ -47,14 +50,14 @@ static const QQuickItemPrivate::ChangeTypes ItemChangeTypes = QQuickItemPrivate:
| QQuickItemPrivate::Parent
| QQuickItemPrivate::Destroyed;
-QQuickScenePosListener::QQuickScenePosListener(QObject *parent)
+QQuickScenePosListener1::QQuickScenePosListener1(QObject *parent)
: QObject(parent)
, m_enabled(false)
, m_item(0)
{
}
-QQuickScenePosListener::~QQuickScenePosListener()
+QQuickScenePosListener1::~QQuickScenePosListener1()
{
if (m_item == 0)
return;
@@ -63,12 +66,12 @@ QQuickScenePosListener::~QQuickScenePosListener()
removeAncestorListeners(m_item->parentItem());
}
-QQuickItem *QQuickScenePosListener::item() const
+QQuickItem *QQuickScenePosListener1::item() const
{
return m_item;
}
-void QQuickScenePosListener::setItem(QQuickItem *item)
+void QQuickScenePosListener1::setItem(QQuickItem *item)
{
if (m_item == item)
return;
@@ -91,17 +94,17 @@ void QQuickScenePosListener::setItem(QQuickItem *item)
updateScenePos();
}
-QPointF QQuickScenePosListener::scenePos() const
+QPointF QQuickScenePosListener1::scenePos() const
{
return m_scenePos;
}
-bool QQuickScenePosListener::isEnabled() const
+bool QQuickScenePosListener1::isEnabled() const
{
return m_enabled;
}
-void QQuickScenePosListener::setEnabled(bool enabled)
+void QQuickScenePosListener1::setEnabled(bool enabled)
{
if (m_enabled == enabled)
return;
@@ -121,23 +124,23 @@ void QQuickScenePosListener::setEnabled(bool enabled)
emit enabledChanged();
}
-void QQuickScenePosListener::itemGeometryChanged(QQuickItem *, const QRectF &, const QRectF &)
+void QQuickScenePosListener1::itemGeometryChanged(QQuickItem *, const QRectF &, const QRectF &)
{
updateScenePos();
}
-void QQuickScenePosListener::itemParentChanged(QQuickItem *, QQuickItem *parent)
+void QQuickScenePosListener1::itemParentChanged(QQuickItem *, QQuickItem *parent)
{
addAncestorListeners(parent);
}
-void QQuickScenePosListener::itemChildRemoved(QQuickItem *, QQuickItem *child)
+void QQuickScenePosListener1::itemChildRemoved(QQuickItem *, QQuickItem *child)
{
if (isAncestor(child))
removeAncestorListeners(child);
}
-void QQuickScenePosListener::itemDestroyed(QQuickItem *item)
+void QQuickScenePosListener1::itemDestroyed(QQuickItem *item)
{
Q_ASSERT(m_item == item);
@@ -147,7 +150,7 @@ void QQuickScenePosListener::itemDestroyed(QQuickItem *item)
removeAncestorListeners(item->parentItem());
}
-void QQuickScenePosListener::updateScenePos()
+void QQuickScenePosListener1::updateScenePos()
{
const QPointF &scenePos = m_item->mapToScene(QPointF(0, 0));
if (m_scenePos != scenePos) {
@@ -161,7 +164,7 @@ void QQuickScenePosListener::updateScenePos()
Remove this listener from \a item and all its ancestors.
*/
-void QQuickScenePosListener::removeAncestorListeners(QQuickItem *item)
+void QQuickScenePosListener1::removeAncestorListeners(QQuickItem *item)
{
if (item == m_item)
return;
@@ -178,7 +181,7 @@ void QQuickScenePosListener::removeAncestorListeners(QQuickItem *item)
Injects this as a listener to \a item and all its ancestors.
*/
-void QQuickScenePosListener::addAncestorListeners(QQuickItem *item)
+void QQuickScenePosListener1::addAncestorListeners(QQuickItem *item)
{
if (item == m_item)
return;
@@ -190,7 +193,7 @@ void QQuickScenePosListener::addAncestorListeners(QQuickItem *item)
}
}
-bool QQuickScenePosListener::isAncestor(QQuickItem *item) const
+bool QQuickScenePosListener1::isAncestor(QQuickItem *item) const
{
if (!m_item)
return false;