Pass the relevant serial when setting the selection
This fixes copying in Weston. Change-Id: Icbdb81078e8df4575bbe440321773131ba27ebbf Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
This commit is contained in:
parent
838501541a
commit
eac16a7b28
@ -60,6 +60,7 @@
|
||||
QWaylandDataDevice::QWaylandDataDevice(QWaylandDataDeviceManager *manager, QWaylandInputDevice *inputDevice)
|
||||
: QtWayland::wl_data_device(manager->get_data_device(inputDevice->wl_seat()))
|
||||
, m_display(manager->display())
|
||||
, m_inputDevice(inputDevice)
|
||||
, m_enterSerial(0)
|
||||
, m_dragWindow(0)
|
||||
, m_dragPoint()
|
||||
@ -92,7 +93,7 @@ void QWaylandDataDevice::setSelectionSource(QWaylandDataSource *source)
|
||||
m_selectionSource.reset(source);
|
||||
if (source)
|
||||
connect(source, &QWaylandDataSource::cancelled, this, &QWaylandDataDevice::selectionSourceCancelled);
|
||||
set_selection(source ? source->object() : 0, 0 /* TODO m_display->serial() */);
|
||||
set_selection(source ? source->object() : Q_NULLPTR, m_inputDevice->serial());
|
||||
}
|
||||
|
||||
QWaylandDataOffer *QWaylandDataDevice::dragOffer() const
|
||||
|
@ -88,7 +88,7 @@ private Q_SLOTS:
|
||||
|
||||
private:
|
||||
QWaylandDisplay *m_display;
|
||||
|
||||
QWaylandInputDevice *m_inputDevice;
|
||||
uint32_t m_enterSerial;
|
||||
QWindow *m_dragWindow;
|
||||
QPoint m_dragPoint;
|
||||
|
Loading…
x
Reference in New Issue
Block a user