10#include <QtCore/QFile>
12#include <QtCore/QDebug>
23 :
QtWayland::wl_data_source(dataDeviceManager->create_data_source())
50 struct sigaction action, oldAction;
51 action.sa_handler = SIG_IGN;
52 sigemptyset (&action.sa_mask);
55 sigaction(SIGPIPE, &action, &oldAction);
62 fcntl(
fd, F_SETFL, O_WRONLY);
65 sigaction(SIGPIPE, &oldAction,
nullptr);
72 m_accepted = !mime_type.
isEmpty();
80 if (action == WL_DATA_DEVICE_MANAGER_DND_ACTION_MOVE)
82 else if (action == WL_DATA_DEVICE_MANAGER_DND_ACTION_COPY)
85 m_dropAction = qtAction;
104#include "moc_qwaylanddatasource_p.cpp"
qsizetype size() const noexcept
Returns the number of bytes in this byte array.
const char * constData() const noexcept
Returns a pointer to the const data stored in the byte array.
bool isEmpty() const noexcept
Returns true if the byte array has size 0; otherwise returns false.
static QStringList formatsHelper(const QMimeData *data)
\macro QT_RESTRICTED_CAST_FROM_ASCII
bool isEmpty() const
Returns true if the string has no characters; otherwise returns false.
static QByteArray getByteArray(QMimeData *mimeData, const QString &mimeType)
void dndDropped(bool accepted, Qt::DropAction action)
void data_source_cancelled() override
void data_source_target(const QString &mime_type) override
void data_source_dnd_finished() override
void data_source_action(uint32_t action) override
void dndResponseUpdated(bool accepted, Qt::DropAction action)
void data_source_dnd_drop_performed() override
QWaylandDataSource(QWaylandDataDeviceManager *dataDeviceManager, QMimeData *mimeData)
void data_source_send(const QString &mime_type, int32_t fd) override
~QWaylandDataSource() override
Combined button and popup list for selecting options.
GLint GLsizei GLsizei GLenum format
gzip write("uncompressed data")