56 #include "QtCore/qobject.h" 57 #include "QtCore/qmap.h" 58 #include "QtGui/qmime.h" 59 #include "QtGui/qdrag.h" 60 #include "QtGui/qpixmap.h" 61 #include "QtGui/qcursor.h" 62 #include "QtCore/qpoint.h" 63 #include "private/qobject_p.h" 65 # include "private/qt_mac_p.h" 77 #if !(defined(QT_NO_DRAGANDDROP) && defined(QT_NO_CLIPBOARD)) 88 static bool canReadData(
const QString &mimeType);
98 virtual bool hasFormat_sys(
const QString &mimeType)
const = 0;
112 DWORD reportedPerformedEffect()
const;
115 STDMETHOD(QueryInterface)(REFIID riid,
void FAR* FAR* ppvObj);
116 STDMETHOD_(ULONG,AddRef)(void);
117 STDMETHOD_(ULONG,
Release)(void);
120 STDMETHOD(GetData)(LPFORMATETC pformatetcIn, LPSTGMEDIUM pmedium);
121 STDMETHOD(GetDataHere)(LPFORMATETC pformatetc, LPSTGMEDIUM pmedium);
122 STDMETHOD(QueryGetData)(LPFORMATETC pformatetc);
123 STDMETHOD(GetCanonicalFormatEtc)(LPFORMATETC pformatetc, LPFORMATETC pformatetcOut);
124 STDMETHOD(SetData)(LPFORMATETC pformatetc,
STGMEDIUM FAR * pmedium,
126 STDMETHOD(EnumFormatEtc)(DWORD dwDirection, LPENUMFORMATETC FAR* ppenumFormatEtc);
127 STDMETHOD(DAdvise)(
FORMATETC FAR* pFormatetc, DWORD advf,
128 LPADVISESINK pAdvSink, DWORD FAR* pdwConnection);
129 STDMETHOD(DUnadvise)(DWORD dwConnection);
130 STDMETHOD(EnumDAdvise)(LPENUMSTATDATA FAR* ppenumAdvise);
149 STDMETHOD(QueryInterface)(REFIID riid,
void FAR* FAR* ppvObj);
150 STDMETHOD_(ULONG,AddRef)(void);
151 STDMETHOD_(ULONG,
Release)(void);
154 STDMETHOD(Next)(ULONG celt, LPFORMATETC rgelt, ULONG FAR* pceltFetched);
155 STDMETHOD(Skip)(ULONG celt);
156 STDMETHOD(Reset)(void);
157 STDMETHOD(Clone)(LPENUMFORMATETC FAR* newEnum);
160 bool copyFormatEtc(LPFORMATETC dest, LPFORMATETC src)
const;
170 #endif //QT_NO_DRAGANDDROP && QT_NO_CLIPBOARD 172 #ifndef QT_NO_DRAGANDDROP 196 bool hasFormat_sys(
const QString &mimeType)
const;
200 #if defined(Q_WS_WIN) 226 void cancel(
bool deleteSource =
true);
227 void move(
const QPoint &);
234 static QDragManager *
self();
236 Qt::KeyboardModifiers modifiers)
const;
249 bool hasCustomDragCursors()
const;
255 void setCurrentTarget(
QWidget *target,
bool dropped =
false);
264 #if defined(Q_WS_QWS) || defined(Q_WS_QPA) 279 #if defined(Q_WS_WIN) 290 STDMETHOD(QueryInterface)(REFIID riid,
void FAR* FAR* ppvObj);
291 STDMETHOD_(ULONG, AddRef)(void);
292 STDMETHOD_(ULONG,
Release)(void);
295 STDMETHOD(DragEnter)(LPDATAOBJECT pDataObj, DWORD grfKeyState, POINTL pt, LPDWORD pdwEffect);
296 STDMETHOD(DragOver)(DWORD grfKeyState, POINTL pt, LPDWORD pdwEffect);
297 STDMETHOD(DragLeave)();
298 STDMETHOD(Drop)(LPDATAOBJECT pDataObj, DWORD grfKeyState, POINTL pt, LPDWORD pdwEffect);
309 void sendDragEnterEvent(
QWidget *to, DWORD grfKeyState, POINTL pt, LPDWORD pdwEffect);
314 #if defined (Q_WS_MAC) 323 bool hasFormat_sys(
const QString &mimeType)
const;
331 #endif // !QT_NO_DRAGANDDROP The QVariant class acts like a union for the most common Qt data types.
const struct __CFString * CFStringRef
The QApplication class manages the GUI application's control flow and main settings.
Qt::DropActions possible_actions
The QCursor class provides a mouse cursor with an arbitrary shape.
#define QT_END_NAMESPACE
This macro expands to.
QPointer< QWidget > currentWidget
virtual QStringList formats() const
Returns a list of formats supported by the object.
The QDrag class provides support for MIME-based drag and drop data transfer.
The QByteArray class provides an array of bytes.
Qt::DropAction currentActionForOverrideCursor
QPointer< QMimeData > data
QMap< Qt::DropAction, QPixmap > customCursors
#define Q_DISABLE_COPY(Class)
Disables the use of copy constructors and assignment operators for the given Class.
struct tagFORMATETC FORMATETC
The QString class provides a Unicode character string.
QVector< LPFORMATETC > m_lpfmtetcs
The QDragMoveEvent class provides an event which is sent while a drag and drop action is in progress...
void emitActionChanged(Qt::DropAction newAction)
The QVector class is a template class that provides a dynamic array.
The QObject class is the base class of all Qt objects.
virtual ~QOleDropTarget()
#define QT_BEGIN_NAMESPACE
This macro expands to.
CFStringRef dropPasteboard
The QEventLoop class provides a means of entering and leaving an event loop.
int CF_PERFORMEDDROPEFFECT
The QStringList class provides a list of strings.
static const char * data(const QByteArray &arr)
Type
This enum type defines the types of variable that a QVariant can contain.
struct tagSTGMEDIUM STGMEDIUM
The QMimeData class provides a container for data that records information about its MIME type...
virtual bool hasFormat(const QString &mimetype) const
Returns true if the object can return data for the MIME type specified by mimeType; otherwise returns...
static QDragPrivate * dragPrivate(QDrag *drag)
The QDropEvent class provides an event which is sent when a drag and drop action is completed...
The QTimerEvent class contains parameters that describe a timer event.
LPDATAOBJECT currentDataObject
virtual QVariant retrieveData(const QString &mimetype, QVariant::Type preferredType) const
Returns a variant with the given type containing data for the MIME type specified by mimeType...
Qt::DropAction executed_action
The QPoint class defines a point in the plane using integer precision.
The QRect class defines a rectangle in the plane using integer precision.
The QPixmap class is an off-screen image representation that can be used as a paint device...
QWidget * currentDropTarget
The QEvent class is the base class of all event classes.
QDragPrivate * dragPrivate() const
int xdndMimeTransferedPixmapIndex
static QDragManager * instance
static bool isNull(const QVariant::Private *d)
Qt::DropAction defaultDropAction