summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorMichael Brasser <michael.brasser@nokia.com>2009-07-30 06:03:49 (GMT)
committerMichael Brasser <michael.brasser@nokia.com>2009-07-30 06:03:49 (GMT)
commita70f8a2b0966420e1911554a117e066592b1822c (patch)
tree13aa04aaf99584475d2f4aa449711c7692d84325 /src
parented8136de5f00a69b398a62a1cce7f0c5ba8868ed (diff)
downloadQt-a70f8a2b0966420e1911554a117e066592b1822c.zip
Qt-a70f8a2b0966420e1911554a117e066592b1822c.tar.gz
Qt-a70f8a2b0966420e1911554a117e066592b1822c.tar.bz2
More QFxItem cleanup.
Diffstat (limited to 'src')
-rw-r--r--src/declarative/fx/qfxitem.cpp40
-rw-r--r--src/declarative/fx/qfxitem.h3
-rw-r--r--src/declarative/fx/qfxitem_p.h3
3 files changed, 0 insertions, 46 deletions
diff --git a/src/declarative/fx/qfxitem.cpp b/src/declarative/fx/qfxitem.cpp
index 569af43..6df538e 100644
--- a/src/declarative/fx/qfxitem.cpp
+++ b/src/declarative/fx/qfxitem.cpp
@@ -1592,18 +1592,6 @@ QmlList<QmlTransition *>* QFxItem::transitions()
*/
/*!
- Returns the state with \a name. Returns 0 if no matching state is found.
-*/
-QmlState *QFxItem::findState(const QString &name) const
-{
- Q_D(const QFxItem);
- if (!d->_stateGroup)
- return 0;
- else
- return d->_stateGroup->findState(name);
-}
-
-/*!
\qmlproperty string Item::state
This property holds the name of the current state of the item.
@@ -1809,14 +1797,7 @@ QVariant QFxItem::itemChange(GraphicsItemChange change,
{
Q_D(QFxItem);
if (change == ItemSceneHasChanged) {
- if (options() & QFxItem::MouseFilter)
- d->gvRemoveMouseFilter();
-
d->canvas = qvariant_cast<QGraphicsScene *>(value);
-
- if (options() & QFxItem::MouseFilter)
- d->gvAddMouseFilter();
-
} else if (change == ItemChildAddedChange ||
change == ItemChildRemovedChange) {
childrenChanged();
@@ -2082,13 +2063,6 @@ void QFxItem::setOptions(Options options, bool set)
setFiltersChildEvents(d->options & ChildMouseFilter);
setFlag(QGraphicsItem::ItemAutoDetectsFocusProxy, d->options & IsFocusRealm);
-
- if ((old & MouseFilter) != (d->options & MouseFilter)) {
- if (d->options & MouseFilter)
- d->gvAddMouseFilter();
- else
- d->gvRemoveMouseFilter();
- }
}
void QFxItem::paint(QPainter *p, const QStyleOptionGraphicsItem *, QWidget *)
@@ -2096,18 +2070,4 @@ void QFxItem::paint(QPainter *p, const QStyleOptionGraphicsItem *, QWidget *)
paintContents(*p);
}
-void QFxItemPrivate::gvRemoveMouseFilter()
-{
- Q_Q(QFxItem);
- if (q->scene())
- q->removeSceneEventFilter(q);
-}
-
-void QFxItemPrivate::gvAddMouseFilter()
-{
- Q_Q(QFxItem);
- if (q->scene())
- q->installSceneEventFilter(q);
-}
-
QT_END_NAMESPACE
diff --git a/src/declarative/fx/qfxitem.h b/src/declarative/fx/qfxitem.h
index ba3ab4f..c31b8bb 100644
--- a/src/declarative/fx/qfxitem.h
+++ b/src/declarative/fx/qfxitem.h
@@ -154,7 +154,6 @@ class Q_DECLARATIVE_EXPORT QFxItem : public QGraphicsObject, public QmlParserSta
public:
enum Option { NoOption = 0x00000000,
- MouseFilter = 0x00000001,
ChildMouseFilter = 0x00000002,
IsFocusRealm = 0x00000080 };
Q_DECLARE_FLAGS(Options, Option)
@@ -183,8 +182,6 @@ public:
void setClip(bool);
QmlList<QmlState *>* states();
- QmlState *findState(const QString &name) const;
-
QmlList<QmlTransition *>* transitions();
QString state() const;
diff --git a/src/declarative/fx/qfxitem_p.h b/src/declarative/fx/qfxitem_p.h
index a013897..181c91d 100644
--- a/src/declarative/fx/qfxitem_p.h
+++ b/src/declarative/fx/qfxitem_p.h
@@ -196,9 +196,6 @@ public:
QPointF computeTransformOrigin() const;
- void gvRemoveMouseFilter();
- void gvAddMouseFilter();
-
virtual void setPosHelper(const QPointF &pos)
{
Q_Q(QFxItem);