#include "qquickdroparea_p.h"
#include "qquickdrag_p.h"
#include "qquickitem_p.h"
-#include "qquickcanvas.h"
+#include "qquickwindow.h"
#include <private/qqmlengine_p.h>
+#ifndef QT_NO_DRAGANDDROP
+
QT_BEGIN_NAMESPACE
QQuickDropAreaDrag::QQuickDropAreaDrag(QQuickDropAreaPrivate *d, QObject *parent)
/*!
\qmlclass DropArea QQuickDropArea
\inqmlmodule QtQuick 2
- \brief The DropArea item provides drag and drop handling.
+ \ingroup qtquick-input
+ \brief For specifying drag and drop handling in an area
A DropArea is an invisible item which receives events when other items are
dragged over it.
if (keyRegExp.isEmpty())
return true;
+ QRegExp copy = keyRegExp;
foreach (const QString &key, keys) {
- if (keyRegExp.exactMatch(key))
+ if (copy.exactMatch(key))
return true;
}
return false;
/*!
\qmlclass DragEvent QQuickDragEvent
\inqmlmodule QtQuick 2
- \brief The DragEvent object provides information about a drag event.
+ \ingroup qtquick-input-events
+ \brief Provides information about a drag event
The position of the drag event can be obtained from the \l x and \l y
properties, and the \l keys property identifies the drag keys of the event
}
/*!
- \qmlproperty enum QtQuick2::DragEvent::action
+ \qmlproperty enumeration QtQuick2::DragEvent::action
This property holds the action that the \l source is to perform on an accepted drop.
The drop action may be one of:
\list
- \o Qt.CopyAction Copy the data to the target
- \o Qt.MoveAction Move the data from the source to the target
- \o Qt.LinkAction Create a link from the source to the target.
- \o Qt.IgnoreAction Ignore the action (do nothing with the data).
+ \li Qt.CopyAction Copy the data to the target
+ \li Qt.MoveAction Move the data from the source to the target
+ \li Qt.LinkAction Create a link from the source to the target.
+ \li Qt.IgnoreAction Ignore the action (do nothing with the data).
\endlist
*/
/*!
\qmlmethod void QtQuick2::DragEvent::accept()
- \qmlmethod void QtQuick2::DragEvent::accept(enum action)
+ \qmlmethod void QtQuick2::DragEvent::accept(enumeration action)
Accepts the drag event.
QT_END_NAMESPACE
+#endif // QT_NO_DRAGANDDROP