Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
qwindowsdropdataobject.h
Go to the documentation of this file.
1// Copyright (C) 2017 The Qt Company Ltd.
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
3
4#ifndef QWINDOWSDROPDATAOBJECT_H
5#define QWINDOWSDROPDATAOBJECT_H
6
7#include "qwindowsole.h"
8
10
12{
13public:
14 explicit QWindowsDropDataObject(QMimeData *mimeData);
16
17 // overridden IDataObject methods
18 STDMETHOD(GetData)(LPFORMATETC pformatetcIn, LPSTGMEDIUM pmedium) noexcept override;
19 STDMETHOD(QueryGetData)(LPFORMATETC pformatetc) noexcept override;
20
21private:
22 bool shouldIgnore(LPFORMATETC pformatetc) const;
23};
24
25QT_END_NAMESPACE
26
27#endif // QWINDOWSDROPDATAOBJECT_H
\inmodule QtCore\reentrant
Definition qpoint.h:29
Singleton container for all relevant information.
QWindowsScreenManager & screenManager()
static QWindowsContext * instance()
Platform cursor implementation.
static QPoint mousePosition()
static State cursorState()
A toplevel window showing the drag icon in case of touch drag.
void setPixmap(const QPixmap &p)
void paintEvent(QPaintEvent *) override
Handles paint events passed in the event parameter.
QWindowsDragCursorWindow(QWindow *parent=nullptr)
Windows drag implementation.
IDataObject * dropDataObject() const
virtual ~QWindowsDrag()
static bool isCanceled()
QMimeData * dropData()
Return data for a drop in process.
void setDropDataObject(IDataObject *dataObject)
static QWindowsDrag * instance()
void releaseDropDataObject()
IDropTargetHelper * dropHelper()
May be used to handle extended cursors functionality for drags from outside the app.
Qt::DropAction drag(QDrag *drag) override
void cancelDrag() override
Cancels the currently active drag (only for drags of the current application initiated by QPlatformDr...
QWindowsOleDataObject subclass specialized for handling Drag&Drop.
STDMETHOD GetData(LPFORMATETC pformatetcIn, LPSTGMEDIUM pmedium) noexcept override
STDMETHOD QueryGetData(LPFORMATETC pformatetc) noexcept override
QWindowsDropDataObject(QMimeData *mimeData)
~QWindowsDropDataObject() override
Special mime data class for data retrieval from Drag operations.
QWindowsDropMimeData()=default
IDataObject * retrieveDataObject() const override
static QWindowsIntegration * instance()
OLE data container.
Definition qwindowsole.h:22
Implementation of IDropSource.
STDMETHOD GiveFeedback(DWORD dwEffect) noexcept override
Give feedback: Change cursor according to action.
~QWindowsOleDropSource() override
void createCursors()
Blend custom pixmap with cursors.
QWindowsOleDropSource(QWindowsDrag *drag)
STDMETHOD QueryContinueDrag(BOOL fEscapePressed, DWORD grfKeyState) noexcept override
Check for cancel.
Implementation of IDropTarget.
~QWindowsOleDropTarget() override
LPDATAOBJECT DWORD grfKeyState
STDMETHOD DragLeave() noexcept override
LPDATAOBJECT DWORD POINTL pt
QWindowsOleDropTarget(QWindow *w)
STDMETHOD DragOver(DWORD grfKeyState, POINTL pt, LPDWORD pdwEffect) noexcept override
LPDATAOBJECT pDataObj
const QWindowsScreen * screenAtDp(const QPoint &p) const
Raster or OpenGL Window.
bool hasMouseCapture() const
#define WM_POINTERUPDATE
#define WM_POINTERLEAVE
static HRESULT startDoDragDrop(LPDATAOBJECT pDataObj, LPDROPSOURCE pDropSource, DWORD dwOKEffects, LPDWORD pdwEffect)
static Qt::DropActions translateToQDragDropActions(DWORD pdwEffects)
static Qt::KeyboardModifiers toQtKeyboardModifiers(DWORD keyState)
static Qt::MouseButtons lastButtons
static Qt::DropAction translateToQDragDropAction(DWORD pdwEffect)
static DWORD translateToWinDragEffects(Qt::DropActions action)
static Qt::KeyboardModifiers lastModifiers